![photo](/responsive_image/150/150/0/0/0/cache/matlabcentral/profiles/19833842_1601894384308_DEF.jpg)
Daniel Pollard
Followers: 0 Following: 0
Feeds
답변 있음
why do I receive "Index in position 1 is invalid. Array indices must be positive integers or logical values"
i and j in MATLAB both have the default value of the complex unit. When you say for i = 1:26 you override this, so now i take...
why do I receive "Index in position 1 is invalid. Array indices must be positive integers or logical values"
i and j in MATLAB both have the default value of the complex unit. When you say for i = 1:26 you override this, so now i take...
거의 3년 전 | 0
| 수락됨
답변 있음
Why vector created by colon have improper values
I'm struggling a bit to understand exactly what your question is but I think what you're asking is why the value 0.8 is not in y...
Why vector created by colon have improper values
I'm struggling a bit to understand exactly what your question is but I think what you're asking is why the value 0.8 is not in y...
대략 3년 전 | 1
답변 있음
why when i use find command to find the index i face problem
I had a play with my version of Matlab and found the same result. I think what you've stumbled on is a floating point error. The...
why when i use find command to find the index i face problem
I had a play with my version of Matlab and found the same result. I think what you've stumbled on is a floating point error. The...
대략 3년 전 | 0
답변 있음
All possible combination based on 2^n but with 1 and -1
You could take the answer from your previous question, subtract 0.5 and multiply by 2. Your accepted answer was n = 3; m = dec...
All possible combination based on 2^n but with 1 and -1
You could take the answer from your previous question, subtract 0.5 and multiply by 2. Your accepted answer was n = 3; m = dec...
대략 3년 전 | 0
답변 있음
How do I delete the last dimension of a 256*256*3 matrix?
Is Ii your 256x256x3 array? An image of 256x256 pixels will have 256x256x3 elements because of the red, green and blue elements....
How do I delete the last dimension of a 256*256*3 matrix?
Is Ii your 256x256x3 array? An image of 256x256 pixels will have 256x256x3 elements because of the red, green and blue elements....
대략 3년 전 | 0
| 수락됨
질문
Is there a way to vectorise this vector/matrix product?
I have a piece of code inside a for loop, which looks like for k = 1:size(G, 1) G(k) = real(W(:,k)' * R * W(:,k)) end G ...
대략 3년 전 | 답변 수: 2 | 0
2
답변답변 있음
Calculate power of exponential
Deleted my previous answer as I hadn't seen your edit so gave a wrong answer. You need a . before the multiplication symbol. Tr...
Calculate power of exponential
Deleted my previous answer as I hadn't seen your edit so gave a wrong answer. You need a . before the multiplication symbol. Tr...
3년 초과 전 | 1
| 수락됨
답변 있음
I want my solution as a Vector
Does this work? X(z) = R/N; instead of X = R/N
I want my solution as a Vector
Does this work? X(z) = R/N; instead of X = R/N
3년 초과 전 | 0
| 수락됨
답변 있음
Unable to perform assignment because the size of the left side is 1-by-1 and the size of the right side is 1-by-1-by-2.
I haven't run it, but I think your code will error on the line deltaxj(i,ii,iii)=sum1+(x1-x1New)*(k.*(Rn+Rp)-dn)./dn; because...
Unable to perform assignment because the size of the left side is 1-by-1 and the size of the right side is 1-by-1-by-2.
I haven't run it, but I think your code will error on the line deltaxj(i,ii,iii)=sum1+(x1-x1New)*(k.*(Rn+Rp)-dn)./dn; because...
3년 초과 전 | 0
| 수락됨
답변 있음
How to error check a number for strings and blank inputs?
Are you looking for validateattributes or assert? For example, assert(menu == 1 || menu == 2) will throw an error if menu is n...
How to error check a number for strings and blank inputs?
Are you looking for validateattributes or assert? For example, assert(menu == 1 || menu == 2) will throw an error if menu is n...
3년 초과 전 | 0
답변 있음
FOR LOOP , beginner question.
Your code is d = []; for x=[0.1000,0.1500,0.2000] d=[d ((34.63/x)-5.126)/2.54]; disp ("ANSWER"); end x=[0.1000 0.1...
FOR LOOP , beginner question.
Your code is d = []; for x=[0.1000,0.1500,0.2000] d=[d ((34.63/x)-5.126)/2.54]; disp ("ANSWER"); end x=[0.1000 0.1...
3년 초과 전 | 0
| 수락됨
답변 있음
Can't calculate angle a, when 𝑠𝑖𝑛(𝑎)=2.
If a is a real number, then sin(a) must be between -1 and 1. Calling asin(2) returns 1.5708 - 1.3170i which is a complex num...
Can't calculate angle a, when 𝑠𝑖𝑛(𝑎)=2.
If a is a real number, then sin(a) must be between -1 and 1. Calling asin(2) returns 1.5708 - 1.3170i which is a complex num...
3년 초과 전 | 2
| 수락됨
답변 있음
Array indices must be positive integers or logical values
You wrote psi(i,j) = ((U0*V0)./W)*cos(W(t-YY(i,j)./V0))-V0*XX(i,j); Try psi(i,j) = ((U0*V0)./W)*cos(W*(t-YY(i,j)./V0))-V0*XX(...
Array indices must be positive integers or logical values
You wrote psi(i,j) = ((U0*V0)./W)*cos(W(t-YY(i,j)./V0))-V0*XX(i,j); Try psi(i,j) = ((U0*V0)./W)*cos(W*(t-YY(i,j)./V0))-V0*XX(...
3년 초과 전 | 0
| 수락됨
문제를 풀었습니다
Find the largest number
Find the largest number |x| among 4 numbers given as variables |a|, |b|, |c|, and |d|. Example: Input: a = 4; b = 7; c ...
3년 초과 전
답변 있음
How to combine multiple curve fits in one plot?
https://www.mathworks.com/help/matlab/creating_plots/combine-multiple-plots.html This was literally the top result when I googl...
How to combine multiple curve fits in one plot?
https://www.mathworks.com/help/matlab/creating_plots/combine-multiple-plots.html This was literally the top result when I googl...
3년 초과 전 | 0
답변 있음
Why is validateattributes returning me a Not enough inputs error only in this context?
I was assigning the class to a vector in reverse order, using a loop like for k = 16:-1:1 lsqsin(k) = LsqSinusoid(N_sample...
Why is validateattributes returning me a Not enough inputs error only in this context?
I was assigning the class to a vector in reverse order, using a loop like for k = 16:-1:1 lsqsin(k) = LsqSinusoid(N_sample...
3년 초과 전 | 0
| 수락됨
질문
Why is validateattributes returning me a Not enough inputs error only in this context?
I have a class definition called LsqSinusoid(n_samples, f, Fs). The constructor for that class takes three inputs - n_samples, t...
3년 초과 전 | 답변 수: 1 | 0
1
답변답변 있음
While loop for testing the end of vector (Matlab)
If you know that it's 1-dimensional, you can use numel(vector) which returns the length of your vector. Also useful to know i...
While loop for testing the end of vector (Matlab)
If you know that it's 1-dimensional, you can use numel(vector) which returns the length of your vector. Also useful to know i...
3년 초과 전 | 1
답변 있음
Finding numChanges in array
Replace for i=1;length(V) with for ii = 1:length(V) The semicolon -> colon is a typo I suspect, and i has a built in value s...
Finding numChanges in array
Replace for i=1;length(V) with for ii = 1:length(V) The semicolon -> colon is a typo I suspect, and i has a built in value s...
3년 초과 전 | 2
| 수락됨
답변 있음
How to plot a graph in nm
Your method works perfectly well. An alternative option would be theta = 10 wavelength = [500:10:700] m = 1 d = (m.*waveleng...
How to plot a graph in nm
Your method works perfectly well. An alternative option would be theta = 10 wavelength = [500:10:700] m = 1 d = (m.*waveleng...
3년 초과 전 | 1
| 수락됨
답변 있음
Unable to perform assignment because the size of the left side is 1-by-1 and the size of the right side is 10-by-10. not sure why i am getting this error
Biot_top is size 10x10. dtMat(1,j) is size 1x1. This means the LHS of your line is 1x1, and the RHS is 10x10, so you can't make ...
Unable to perform assignment because the size of the left side is 1-by-1 and the size of the right side is 10-by-10. not sure why i am getting this error
Biot_top is size 10x10. dtMat(1,j) is size 1x1. This means the LHS of your line is 1x1, and the RHS is 10x10, so you can't make ...
3년 초과 전 | 0
| 수락됨
답변 있음
How to create one errorbar for multiple data points?
If I understand you right, could you do something like figure; hold on plot(x, y, 'bx') errorbar(mean(x), mean(y), std(y), 'k...
How to create one errorbar for multiple data points?
If I understand you right, could you do something like figure; hold on plot(x, y, 'bx') errorbar(mean(x), mean(y), std(y), 'k...
3년 초과 전 | 1
| 수락됨
답변 있음
Graph with similar axis value with the value given
You want xticks and yticks. As a note: you need the vectors to be in ascending order, and your second tickmark vector isn't. so...
Graph with similar axis value with the value given
You want xticks and yticks. As a note: you need the vectors to be in ascending order, and your second tickmark vector isn't. so...
3년 초과 전 | 0
답변 있음
Does MathWorks have software for rocket trajectory modeling at supersonic speed?
The Aerospace toolbox is likely to be the closest to what you want. I don't use it so don't know much about it, but it seems to ...
Does MathWorks have software for rocket trajectory modeling at supersonic speed?
The Aerospace toolbox is likely to be the closest to what you want. I don't use it so don't know much about it, but it seems to ...
3년 초과 전 | 0
답변 있음
converting degrees and radian
Something like option = input("Type A for degree to radians, and B for radians to degrees: ", 's') if option == "A" degs ...
converting degrees and radian
Something like option = input("Type A for degree to radians, and B for radians to degrees: ", 's') if option == "A" degs ...
3년 초과 전 | 0
답변 있음
How can I plot histogram?
Simply googling "matlab histogram" would have answered your question. That link is for the documentation for histogram. histog...
How can I plot histogram?
Simply googling "matlab histogram" would have answered your question. That link is for the documentation for histogram. histog...
3년 초과 전 | 0
답변 있음
Double for loop is not working properly
k will take the values [1 2]. For the first iteration of k, it stores data{1,1}(:,14) in ch{1,n}. The second time around, it wil...
Double for loop is not working properly
k will take the values [1 2]. For the first iteration of k, it stores data{1,1}(:,14) in ch{1,n}. The second time around, it wil...
3년 초과 전 | 0
| 수락됨
답변 있음
Uneven linspacing of an array
If I understand right, you have a vector len, and you want to have a vector x such that diff(x)=len. In that case, you can use t...
Uneven linspacing of an array
If I understand right, you have a vector len, and you want to have a vector x such that diff(x)=len. In that case, you can use t...
3년 초과 전 | 0
답변 있음
Problem with running a Matlab code.
Clear your variables by putting the command clear at the start of your programme. It's almost certainly holding onto variable...
Problem with running a Matlab code.
Clear your variables by putting the command clear at the start of your programme. It's almost certainly holding onto variable...
3년 초과 전 | 0
| 수락됨