I keep getting an error saying index exceeds matrix dimensions
Mostrar comentarios más antiguos
if true
% code
end
n=1;
t(1)=0;
T(1)=50;
Tout=375;
k=0.0035;
time=[0.0,0.5,2.0];
temps=[106,96,102];
h=30;
while T<160
n=n+1;
slope=-k*(T(n)-Tout);
t(n+1)=t(n)+h;
T(n+1)=T(n)+h*slope;
end
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Matrix Indexing en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!