Summation of Infinity Terms
Show older comments
I have this question to solve :

Then I have written the code below but it does not work. The main problem is three on index numbers. How to use in MATLAB ? Also I would like to calculate the value of it, not symbolic.

2 Comments
David Goodmanson
on 25 Oct 2017
Hi Berkcan,
since sin(m*pi) = 0 for all integer m, every term in this series is zero. Something has to be wrong here.
Roger Stafford
on 25 Oct 2017
Edited: Roger Stafford
on 25 Oct 2017
@David. I agree. I didn't notice that.
Answers (1)
Roger Stafford
on 25 Oct 2017
Edited: Roger Stafford
on 25 Oct 2017
In the summation symbol ‘m’ is supposed to range over only the odd positive integers. You have it ranging over all positive integers. Try this:
D = 400/pi*symsum(1/(2*p-1)*sinh((2*p-1)*pi/4)/sinh((2*p-1)*pi)*sin((2*p-1)*pi),p,1,inf);
5 Comments
David Goodmanson
on 25 Oct 2017
Hi Roger, see comment above.
Berkcan Oz
on 26 Oct 2017
Roger Stafford
on 26 Oct 2017
@Berkcan: What I did was to replace each p in your expression by 2*p-1. That way as p advances through all possible positive integers, 1, 2, 3, ..., then 2*p-1 will advance through the odd-valued positive integers, 1,, 3, 5, ...
However, you will first have to address the problem pointed out by David, namely that sin(p*pi) is identically zero for all integer-valued p. As it stands, the value of V would be zero.
Berkcan Oz
on 26 Oct 2017
Roger Stafford
on 26 Oct 2017
You can only fix the problem pointed out by David by correcting the function you wrote originally. Make sure you have it right.
Categories
Find more on Logical in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!