- #1
sara_87
- 763
- 0
Homework Statement
I want to calculate a sum (where the end value is in the sum), eg:
[tex]\sum^{n-1}_{i=1}{2i+n}[/tex]
Homework Equations
I don't want to 'split' the sum, i just want to write this.
The Attempt at a Solution
syms i n
for n=1:5
for i=1:n-1
symsum((2*i+n),i,1,n-1)
end
end
i get the error: ? Undefined function or method 'symsum' for input arguments of type 'double'.
i think my code is wrong.