Answered
Why do I get "Array indices must be positive integers or logical values" error
Because you are defining an array using negetive indexes. > h3=u(t)-u(t-5); %u is undefined in your code As you have defined ...

6 mois ago | 1

Question


Smallest positive number in MATLAB
I recently stumbled upon a question on Cody (#1874), which asked the user to input the smallest in MATLAB. As per my knowledge,...

6 mois ago | 1 answer | 0

1

answer

Answered
draw 30 cycles of sinusoid oscillating at 10^6 hz
The reason no graph appears is because your variable tt contains only one element (0). The value of 30*T is 3*10^-5, so you ne...

6 mois ago | 0

Question


Error while using Polyval
While solving a problem using polyval, I encountered an error. Here is the screenshot of the code attached (just the part which ...

10 mois ago | 1 answer | 0

1

answer

Question


Precision problem while solving Cody Problems
While solving Cody problems, I have often encountered that my answer is not accepted because of the precision doesn't match the ...

environ un an ago | 1 answer | 0

1

answer

Answered
How to remodify matrix
You can use following commands. Let the 6x4 matrix be 'xyz'. file1 = xyz(1,:;4,:) file2 = xyz(2,:;5,:) file3 = xyz(3,:;6,:)

presque 2 ans ago | 1

| accepted

Answered
How can delete specific values from below matrix?
To delete elements(columns here) from a matrix(distance) that don't meet a condition (distance>=50), you can do this distance(d...

presque 2 ans ago | 0

Answered
How do you crete a function file?
Write the code, for e.g. function y=plot(A) x=0:pi/A:2*pi; plot(x, sin(x)) hold on plot(x, sin(2*x)) hold off end Call t...

presque 2 ans ago | 0

| accepted

Answered
how to calculate the partial derivatives for a given function of two variable ?
Hello, You can use diff function operator to obtain partial derivatives as follows: 1- Define a function using syms function. (...

presque 2 ans ago | 1