Cannot compute the following expression using "Symsum"

1 visualizzazione (ultimi 30 giorni)
B is a Vector which is 1 x 29 ......
I need a row vector which is [B(1), B(1)+B(2) , B(1)+B(2)+B(3) , ........ ]
I am using Symsum /// But i am getting error....

Risposta accettata

Zoltán Csáti
Zoltán Csáti il 25 Ott 2014
Since B is a vector not a function, you can use cumsum. That is
a = cumsum(B);

Più risposte (0)

Categorie

Scopri di più su 2-D and 3-D Plots in Help Center e File Exchange

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by