回答済み
How to stock a previously calculated variables so I can reuse them to draw a curve?
Hi, this should do the job: %Read color image and convert it to gray level image %Display the original image image...

7年以上 前 | 1

| 採用済み

回答済み
how to set the amplitude of the exponential sequence to 1
Hi, you could use a normalization like: N=10; %Number of samples A=0.0001; t=0:0.1:N; x=A.*exp(t); x1 = x...

7年以上 前 | 0

回答済み
How to make a function operate on a vector of arbitrary length
function s = sfactorial(x) if x < 0 error('x must be positive') elseif floor(x) ~= x error('x must...

7年以上 前 | 0

| 採用済み

回答済み
Create a sample of 1000 values from a normal distribution
Hi, use: yNormal1 = randn(1,1000) + 1; or - if you have Statisitcs an Machine Learning Toolbox you can also use: ...

7年以上 前 | 1

| 採用済み

回答済み
Trouble Solving for Variables Using 3 Separate Numbers
Hi, vectors are defined by square brackets. Then additionally use the colon operator ':' since your result gets a matrix: ...

7年以上 前 | 0

回答済み
How to visualize the voltage in function of time
Hi, you should use the PS->S converter instead of the S->PS converter. After fixing this try: <</matlabcentral/answers/upl...

7年以上 前 | 0

| 採用済み

回答済み
How to cross two 2d plots in a 3d view?
Hi, try: surf(x1,y1,reshape(z1,100,100)) hold on surf(x2,y2,reshape(z2,100,100)) that give the following re...

7年以上 前 | 0

回答済み
Integrating second order differential equation BVP error
Hi, i dont think that there is a analytical solution to this problem. You can solve this numeric by using symbolic Toolbox fo...

7年以上 前 | 0

| 採用済み

回答済み
Can somebody help me with my forecasting model?
Hi, the import of the file _Wetterdaten_kurz.xls_ gives a table which has 38554 rows. But in your Excel file there are only 3...

7年以上 前 | 1

| 採用済み

回答済み
How can I solve a Ax=b using lsqnonlin with constraints (x(1)>x(2)>...>x(6)>x(7))?
Hi, the way <https://de.mathworks.com/help/optim/ug/lsqnonlin.html *|lsqnonlin|*> is called is: x = lsqnonlin(fun,x0,lb,...

7年以上 前 | 0

回答済み
How do i assign a random element of an array a new value
Hi, try: maze(randi(numel(maze))) = 'P'; Best regards Stephan

7年以上 前 | 0

回答済み
Why Struct contents reference from a non-struct array object occurs?
Hi, since you give very little information use: <https://de.mathworks.com/matlabcentral/answers/?language=de%2Cen&sort=rel...

7年以上 前 | 0

回答済み
i need help figuring out the code to solve 6 non linear equation
Hi, your code is ok - just convert the symbolic results to numeric: syms a b c d e f oBal=(-a*2) + c*2 + d*2 + e*2+f*...

7年以上 前 | 0

| 採用済み

回答済み
“A=[A,B{i}];”
Try to understand what the following code does: A = [1, 2] % define a vector of dimension 1x2 B = {[3, 4],...

7年以上 前 | 0

| 採用済み

回答済み
How can I connect a transformer to a IGBT in simulink?
Hi, i guess you are mixing 2 different physical Domains - try this: <https://de.mathworks.com/help/releases/R2018b/physmod...

7年以上 前 | 0

回答済み
Can anyone explain this output of 1d conv() function?
Hi, using: conv([1,2,3],[1,2,3]) is the equivalent to multiply two polynomials: (1*x^2 + 2*x + 3) * (1*x^2 + 2*x...

7年以上 前 | 0

回答済み
Finding the root of an equation using iteration
Hi, you miss to the actualize the value for _cval_ in your |while| loop - Try: xVal = input('Enter a value for x:');...

7年以上 前 | 0

回答済み
which plotting function can give me this curve
Hi, i think <https://de.mathworks.com/help/matlab/ref/plot.html *|plot|*> is a good choice. You can change line style and col...

7年以上 前 | 0

| 採用済み

回答済み
Hie, Please, how do i remove the error tha arises from running this code?
Hi, there are 2 Problems in your code: 1. The Integration with |ode45| leads to different lengths for the entries in GS{ii...

7年以上 前 | 0

回答済み
Second order differential equation graphing
Hi, to get different plots you need to change the initial conditions - try this: clear all close all clc sy...

7年以上 前 | 0

| 採用済み

回答済み
How to solve this ODE
Hi, numeric solution you get by choosing values for A-D and the initial conditions. Then use for example: syms y(t) A...

7年以上 前 | 0

回答済み
Which algorithm does MATLAB eig() use to diagonalize a complex symmetric matrix?
Hi, Maybe you are looking for this: <https://de.mathworks.com/help/releases/R2018a/matlab/ref/eig.html?s_tid=doc_ta#btgapg...

7年以上 前 | 0

| 採用済み

回答済み
How can I add titles to column vector output using disp or fprintf or some other labeling tool
Hi, try this example and adapt it for your purpose: x=rand(10,1) for k = 1:numel(x) fprintf('the value of numb...

7年以上 前 | 0

| 採用済み

回答済み
Help with using arrays to create variables
Hi, try: %%Relevant parameters timestep = 600; G = 6.67408*10^-11; % Mars data Mars.m = 6.39*10^23; ...

7年以上 前 | 0

| 採用済み

回答済み
How can i find example code?
Hi, since you are using R2018a, you should use the corresponding <https://de.mathworks.com/help/releases/R2018a/index.html *d...

7年以上 前 | 2

回答済み
how to make random vector?
Hi, use x = (2*rand(1,100)-1)/10; Best regards Stephan

7年以上 前 | 0

| 採用済み

回答済み
How can I enter a transfer function without writing down the exponents?
Hi, i think you made a mistake by multiplying the denumerator - When i calculate by hand i get: num=[35 3.5 8.75] de...

7年以上 前 | 1

| 採用済み

回答済み
Finding the upper limit of an integral.
Hi, you are trying to subtract a value from a function handle. Use: G1 = @(x)(fun2(x) - 0.05); Best regards Stepha...

7年以上 前 | 0

| 採用済み

回答済み
How to solve simultaneous second order differential equations
Hi, i think an analytical solution wil be hard to find (perhaps impossible) - for numerical solution you can do this: ...

7年以上 前 | 0

回答済み
Why is my code running for forever?
Hi, your code is much too complicated: # You can calculate the values of all the Transfer functions in one step, by vector...

7年以上 前 | 0

さらに読み込む