tT=zeros(285,3);
Wnlms=zeros(3,285);
est_yn(n)= tT * WnlmsT;
whats wrong with the 3rd statement, why i cant perform this multiplication. don't confuse it that i initialize these two arrays as having zeroes on all positions, but while my algorithm will run then these both arrays have values.i just stuck at this 3rd statement. it says have this error {In an assignment A(I) = B, the number of elements in B and I must be the same.
Error in Tying_To_ReadFromFile (line 34) est_yn(n)= tT * Wnlms;}

 Réponse acceptée

Jan
Jan le 12 Avr 2017
Modifié(e) : Jan le 12 Avr 2017
You assume, that the multiplication is the problem, buit the error message tells you, that the assignment ist the problem.
Use the debugger to find out, what happens. Set a breakpoint in the line. Then start the code and when it stops check the sizes of the variables:
size(tT)
size(WnlmsT)
size(tT * WnlmsT);
size(est_yn(n)) % assuming that est_yn is pre-allocated
You will see, that the right hand side of this assignment is a matrix, while the left hand side is an scalar.

Plus de réponses (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by