Answered
Multiplying elements of a vector
Use *prod()* to perform multiplication within a vector. function area = area_calculator(vector, num) switch num ...

6 years ago | 0

| accepted

Answered
How to map a matrix based on values from another matrix
You could *sort(...)* and use it’s second output to index (which satisfies the data points needed under needed tolerance) to get...

6 years ago | 0

Answered
[DEPRECATED] What frustrates you about MATLAB?
The error message generated during a call to a specific function in a specific toolbox is misleading. If there’s an error messag...

6 years ago | 0

Answered
How can I make a new vector by applying operations from an old vector?
Simply use *diff(...)*

6 years ago | 0

Answered
Undefined function 'cos' for input arguments of type 'char'. Error in solution (line 14)
str2double(location_filename(:,2))

6 years ago | 0

Answered
[DISCONTINUED] MATLAB Answers Wish-list #5 (and bug reports)
It would be pretty useful to make *Release* field mandatory to submit a question.

6 years ago | 0

Answered
bar not more working
Remove x from *bar(...)* and use it as *xticklabels(...)*.

6 years ago | 1

| accepted

Answered
Why do I get an error with the fit function even though I'm following at MATLAB tutorial?
Works fine for me. Probably you made a custom file *fit.m* . which fit -all % what does it show?

6 years ago | 0

Answered
Invalid syntax for calling function 'db' on the path. CAN SOMEBODY HELP ME WITH THIS ERROR :(
Please use a different name for "db", you're shadowing the inbuilt function db(...) doc db

6 years ago | 0

Answered
How to put range limit in input Theta between 0 to 90?
for theta = theta % before if statement ... end % at the very end

6 years ago | 1

Answered
Add from different array's using for loop
Aix = [0, 40:40:120]; ; %120 is numel(A) Bix = [0, 30:30:90]; %90 is numel(B) n = numel(Aix); c = cell(n-1, 1); assert(isequ...

6 years ago | 0

Answered
I am trying to find the average of a 58 x 1000 matrix and the result should be a 58 X 48 matrix.
mean(...) along the rows of temperature matrix.

6 years ago | 0

| accepted

Answered
matrix dimension mismatch problem
d = (1:4).';

6 years ago | 0

Answered
How can I set the range of inital value if there are more than one.
Loop the function for VI0. https://www.mathworks.com/help/matlab/math/parameterizing-functions.html Naming a variable times i...

6 years ago | 2

| accepted

Answered
How to skip certain index numbers in row vector in matlab
indices = setdiff(1:50, [11,21,31,41])

6 years ago | 1

Answered
how can i define two series of number in one coloumn?
a = [1:10 , 62:73]

6 years ago | 0

| accepted

Answered
How to store plot function in one single variable
C = {a, b, c, d, e, f}; plot(C{:})

6 years ago | 0

Answered
How to handle functions with multiple outputs
[~, f2] = multfunc(x1, x2)

6 years ago | 0

Answered
t를 어떻게 선언해야하는지 모르겠습니다ㅠㅠ
[t,y]=ode45(@seir,[0,300],[47041334,0,100,0]) plot(t,y) % :( legend('S','E','I','R') function dydt = seir(t,...

6 years ago | 2

| accepted

Answered
2x2 matrix that changes with iteration of for loop
s1 = reshape(s1,1,1,[]); s12 = reshape(s12,1,1,[]); c1 = reshape(c1,1,1,[]); c12 = reshape(c12,1,1,[]); J = [-L...

6 years ago | 1

| accepted

Answered
How can i extract string of a cell array with an indexing in a for loop ?
list = webcamlist; [Rangenumb,Colnumb]= size(webcamlist); x = cell(1, Rangenumb); for ii = 1 : Rangenumb; x{ii} =...

6 years ago | 0

| accepted

Answered
How to download folder from MATLAB Drive
You can right click the root folder -> create Zip File

6 years ago | 1

Answered
Elements of Array Should not be the Same
for k = 1:d for l =1:d A(:,:,1,k) = repmat(projectors_of_sigma_x(:,k), 1, d); end end I sugge...

6 years ago | 1

| accepted

Answered
Second Element is not 1 but It is coming as 1
>> B=zeros(2,2,2,2); projectors_of_sigma_x_minus_sigma_z = [[(sqrt(2)-1);1],[(-sqrt(2)-1);1]] B(:,:,2,1) = projectors_of...

6 years ago | 0

| accepted

Answered
[DISCONTINUED] MATLAB Answers Wish-list #5 (and bug reports)
What's happening in mobile versions of MATLAB Answers?? I just a blank space to type something without the code button and the o...

6 years ago | 0

Answered
Replacing Values in Matrix with NaN's based on Row and Column
matrix(ismember(matrix, [3,7,1])) = nan % an example of replacing numbers 3,7 & 9 with nans % or matrix = rand(5); % an exam...

6 years ago | 1

| accepted

Answered
join string FileName without spaces
regexprep(FileSave," ","") % or strrep(FileSave," ","")

6 years ago | 0

| accepted

Answered
how to sketch domain D f(x,y)<=0 on Oxy
doc fsurf

6 years ago | 1

Answered
positive solutions error when solving eqn
Sol_z(double(Sol_z) > 0)

6 years ago | 1

| accepted

Answered
how to find 'n' number and split vector in to two ?
X = A(A <= 20) Y = A(A > 20) You just needed to save the result in each iteration ;)

6 years ago | 1

| accepted

Load more