0
$\begingroup$

I need to plot the following sum, but I don´t know if I have a mistake in the code,

enter image description here

enter image description here

$\endgroup$

closed as off-topic by george2079, David G. Stork, m_goldberg, Jens, Kuba Jun 2 '17 at 9:13

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This question arises due to a simple mistake such as a trivial syntax error, incorrect capitalization, spelling mistake, or other typographical error and is unlikely to help any future visitors, or else it is easily found in the documentation." – m_goldberg, Jens, Kuba
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 4
    $\begingroup$ So we should retype it? That's kind of you. $\endgroup$ – Kuba Jun 1 '17 at 20:27
  • 4
    $\begingroup$ did you realise none of your function arguments actually appear in the function. If that sum converges the plot will just be a constant. $\endgroup$ – george2079 Jun 1 '17 at 20:39
  • $\begingroup$ Please post your actual Mathematica code, not an image of it. Without real code no one will be able to work with it to see what you might have done wrong, nor will they be able to experiment with possible repairs. $\endgroup$ – m_goldberg Jun 2 '17 at 1:30
  • $\begingroup$ You have mistakes. Your function definition makes no sense. Plot does not plot lists returned by Table (look at ListPlot). There may be others. $\endgroup$ – m_goldberg Jun 2 '17 at 1:37
1
$\begingroup$
expr = (-200 (-1)^n + 200)/(n Pi Sinh[n Pi])*Sinh[n Pi/2]*Sin[n Pi/2] // 
  Simplify[#, Element[n, Integers] && n > 0] &

(*  -((100*(-1 + (-1)^n)*Sech[(n*Pi)/2]*
         Sin[(n*Pi)/2])/(n*Pi))  *)

If you use Regularization the Sum is a constant 25

Sum[expr, {n, 1, Infinity}, Regularization -> #] & /@
 {"Abel", "Borel", "Cesaro", "Dirichlet", "Euler"}

(*  {25, 25, 25, 25, 25}  *)

Using NSum

Block[{$MaxExtraPrecision = 200},
 NSum[expr, {n, 1, Infinity},
  Method -> "AlternatingSigns",
  WorkingPrecision -> 30]]

enter image description here

$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.