Error with multiplication, it saids that matrix dimensions must be equal, How do I multiply in my formulas?
Afficher commentaires plus anciens
Every time I run the program, I get an error when the program calculates Vc. The error states the matrix dimensions must agree, I was wondering how to fix this so my formula works correctly. Error still happens when I remove the dot from multiplication sign. I've asked my professor but he doesn't recognize why the error is happening. Respond ASAP please, as I was given this friday and the report is due sunday.
%time the switch is closed for
t = 0:1:10;
%User enters the values for E, R, C.
e = exp(-t/R*C);
dvc = E - VcO; %Vc then letter "O"
%Formulas for Vc, ic, Vr
Vc = E + ((VcO - E).* e);
ic = (dvc/R).*e;
Vr = dvc .* e;
Réponse acceptée
Plus de réponses (1)
Adam
le 9 Nov 2014
0 votes
Catégories
En savoir plus sur Loops and Conditional Statements dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!