Iterations in an equation
Afficher commentaires plus anciens
Hi, how do I use my iterations with delta z for example. z = [0:0.1:100] and I need to have the z prior to the one I would use.
3 commentaires
Mili Goyal
le 5 Juil 2021
Could you give more clarity as to what is required maybe via an example?
Christian Joshua Lee
le 7 Juil 2021
Christian Joshua Lee
le 7 Juil 2021
Réponses (1)
KSSV
le 5 Juil 2021
z = [0:0.1:100] ;
nz = length(z) ;
for i = 2:n
dz = z(n-1)-z(n)
end
The above can also be achieved using:
dz = diff(z) ;
Catégories
En savoir plus sur Startup and Shutdown 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!
