Réponse apportée
Need help creating simple plot (3d plot?)
Ulrik, one option would be a surface plot: n = 100; x = linspace(0,4,n); y = linspace(0,4,n); [X,Y] = meshgrid(x,y); ...

plus de 11 ans il y a | 1

| A accepté

Réponse apportée
Change elements by a set amount.
Justin, do you mean delta = delta - delta/2 + 1 ?

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
Find value of x, from max y (graph)
Andrew, check out x = 0:0.1:6; y = sin(x + 0.5); vel = diff(y)./diff(x); plot(x(1:end-1), vel,x(vel == max(vel)),m...

plus de 11 ans il y a | 0

Réponse apportée
Row and column lsim error?
Hello Raymond, the system has two inputs, therefore the input signal needs to be a 2-by-n vector. Use, e.g. ... t = 0:0.01...

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
Problem using Left Hand Division in MATLAB
Michael, the answer (zero-vector) is correct. If you do rank(sysEq) you'll see that the matrix has full rank (= 3). This ...

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
Repeating triangular block in Simulink
Chess, how about using the <http://www.mathworks.com/help/simulink/slref/signalbuilder.html Signal Builder> block?

plus de 11 ans il y a | 0

Réponse apportée
Indexing cannot yield multiple results error
Ole, the problem is in this statement vx = vx + ax*dt vy = vy + ay*dt These should be two separate statements. Change it ...

plus de 11 ans il y a | 0

Réponse apportée
Lego mindstorms NXT support package
Nauman, in MATLAB simply go to |Resources > Add-Ons > Add Hardware Support Packages|, select and download the NXT package for fr...

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
How do I plot this function in MATLAB?
Michael, use something like [x,y] = meshgrid(0:0.1:5,0:0.1:5); Z = sin(sqrt(x.^2 + y.^2))./(sqrt(x.^2 + y.^2)) ; surf(x,...

plus de 11 ans il y a | 0

Réponse apportée
Second Y-axis on the figure window
Aftab, use |<http://www.mathworks.com/help/matlab/ref/plotyy.html plotyy>|. Alternatively, use <http://www.mathworks.com/help/ma...

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
Problem with using lsim which lead to row and column error ?
Hello Raymond, your system has two inputs, therefore |w| needs to be a 2-by-n array, rather than a 1-by-n. Use instead: ... ...

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
How to move a circle on a sine curve?
Airas, use something like ... h = fill(x,y,'y'); axis ([0,200,0,50]) axis equal axis manual for ii = 0:200 ...

plus de 11 ans il y a | 1

Réponse apportée
Plotting multiple graphs in one plot.
Hello anton, there is no attachment. But if you can plot one curve, you can do several as well: t = 0:0.1:1; a1 = rand(...

plus de 11 ans il y a | 0

Réponse apportée
Error occurs while executing state space parameters using idss?
PARASSURAM, check the size of the matrices. It looks like your |D| matrix needs to be a 1-by-2 (rather than a 1-by-1). |K| sh...

plus de 11 ans il y a | 1

| A accepté

Réponse apportée
Getting a mean of only the numbers
Evelyn, use mean(data(~isnan(data)))

plus de 11 ans il y a | 1

| A accepté

Réponse apportée
Bug in R2014b? Markersize specifier resets marker type
Hello Wouter, the default <http://www.mathworks.com/help/matlab/ref/plot.html#inputarg_LineSpec marker size> is 6. So you probab...

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
Why isn't this plot looking correct?
Tyler, I am not sure what you are looking for. However, it seems like you did get what the exercise is asking for. Note, that th...

plus de 11 ans il y a | 1

Réponse apportée
Why is laplace not working?
Hilary, you probaby do not have the Symbolic Math Toolbox installed and/or licensed. At the MATLAB command prompt type which...

plus de 11 ans il y a | 0

Réponse apportée
How to define which variable is x and which variable is y axis?
John, simply use plot(b,c) The first argument is the |x| the second the |y| axis. Or, if you want to show both solution b...

plus de 11 ans il y a | 1

Réponse apportée
i am getting an error as Attempt to call constructor image with incorrect letter case.
Vetri, see this <http://www.mathworks.com/matlabcentral/answers/38498#answer_47982 answer> reference.

plus de 11 ans il y a | 0

Réponse apportée
How to print the second largest of a group of the numbers
Rodrigo, you could use a = [1 2 3 4 5 6 7 8 9 10]; b = max(setxor(a,max(a)));

plus de 11 ans il y a | 1

Réponse apportée
Matlab questions from newbies.
Eugene, MATLAB does not know about units and only takes care of the numerics. In other words, you need to make sure that the uni...

plus de 11 ans il y a | 2

| A accepté

Réponse apportée
How can I use greek symbols in plot labels?
Merve, you mean something like lambda = 20:5:40; y = 1./lambda; plot(lambda,y) xlabel('{\lambda}') set(gca,... ...

plus de 11 ans il y a | 7

| A accepté

Réponse apportée
i want to use fonction(unique) to get un string ,but it awlays shows Error using cell/unique?Can anyone tell me what I am doing wrong here? thank you
pengcheng, use P = [pa(1),pa(2),pa(3),pa(4),pa(5)]; H = unique(P); instead.

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
How can I write this function so I can use it on multiple values?
Use bmi = (w*4.88)./h.^2 instead. Note the dot in front of the forward slash.

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
Latex Interpreter - mean bar with subscripts
Use ylabel('$\bar{C}_{p_{A_L}}$','FontAngle','italic','Interpreter','Latex')

plus de 11 ans il y a | 2

| A accepté

Réponse apportée
getting wrong values when coding
Guan-Yu, use instead scale = 0; quiver(x,y,u,v,scale) This turns off the automatic scaling of the arrows.

plus de 11 ans il y a | 0

Réponse apportée
approximating pi with taylor series expansion to the 10,000th term
charlotte, you are almost there: l = 1; for ii = 1:10000 l = l + ((-1)^ii)/(2*ii + 1); end x = 4*l; * If the n...

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
Is it possible to check which part of the script is taking longer time for execuation ?
Prathamesh, you are looking for the <http://www.mathworks.com/help/matlab/matlab_prog/profiling-for-improving-performance.html P...

plus de 11 ans il y a | 2

Réponse apportée
please explain this error
dav, I believe what you are trying to do is the following max([-3/2, 7, 1.4]) The values you want to find the maximum of ...

plus de 11 ans il y a | 3

| A accepté

Charger plus