Why does the following error come up for this short piece of code?
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Kiran Prasad
il 25 Giu 2017
Commentato: Kiran Prasad
il 25 Giu 2017
Hi, Whenever I try to run this code:
for i=1:3
H=hilb(n);
x = ones (n(i),1);
b=H*x;
y=mldivide(H,b);
disp(y);
end
I get the following error: "Subscripted assignment dimension mismatch". I'm not really sure why since as far as I can see and when I set debug stops b is 5x1 and H is 5x5 on the first loop. Any help would be appreciated, Kiran
0 Commenti
Risposta accettata
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Logical in Help Center e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!