Info
Cette question est clôturée. Rouvrir pour modifier ou répondre.
A for loop need help ASAP
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I have a loop and I want to collect the output?
A are arrays 0:300
for i = 0:3:300
Fi = atan(-(A5(1,1+i)/A5(1,2+i)));
Theta = acos(A5(1,3+i));
Psi = atan(A3(1,3+1)/A4(1,3+i));
end
1 commentaire
Réponses (1)
Torsten
le 30 Avr 2019
Modifié(e) : Torsten
le 30 Avr 2019
for i = 0:3:300
j = i/3 + 1;
Fi(j)= atan(-(A5(1,1+i)/A5(1,2+i)));
Theta(j) = acos(A5(1,3+i));
Psi(j)= atan(A3(1,3+i)/A4(1,3+i));
end
2 commentaires
Torsten
le 30 Avr 2019
j = 0;
for i = 0:3:300
j = j + 1;
Fi(j)= atan(-(A5(1,1+i)/A5(1,2+i)));
Theta(j) = acos(A5(1,3+i));
Psi(j)= atan(A3(1,3+i)/A4(1,3+i));
end
Cette question est clôturée.
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!