HOW TO WRITE SUMMATION FORM ∑_(i=1) (L-1)

2 Ansichten (letzte 30 Tage)
sheeba
sheeba am 4 Sep. 2013
LOWER LIMIT IS i=0, upper limit is L-1(L=256)

Antworten (2)

Laurent
Laurent am 4 Sep. 2013
Make an appropriate vector with the values that you want to sum (or select the values from an array containing them) and use the command 'sum'.

Matt J
Matt J am 4 Sep. 2013
Bearbeitet: Matt J am 4 Sep. 2013
Are you trying to sum the first 256 elements of an array? If so, you would do as follows
sum(x(1:256))
Or, if length(x) is 256, then you would just do
sum(x)

Kategorien

Mehr zu Resizing and Reshaping Matrices finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by