I am trying to determine the series
$\qquad \sum_{k=0}^\infty {\rm myCsc}(x,\,\epsilon)\,{\sin(k\,m_C + a_C+\frac\pi 4)}$
where
$\qquad {\rm myCsc}(x,\epsilon))=\begin{cases}i\,\epsilon & 0\leq x\mod\pi<\epsilon\vee\pi-epsilon<x\mod\pi\leq\pi \\\csc(x) & \rm{otherwise}\end{cases}$
and
$\qquad x=\sin(k\,m_M+a_M+\frac\pi 4)$$
$
The Mathematica code is
ClearAll[mM, aM, mC, aC, k, eps];
x[k_] := k*mM + aM + Pi/4;
myCsc[k_] :=
If[(0 <= Mod[x[k], Pi] < eps) || (Pi - eps <
Mod[x[k], Pi] <= Pi), I*eps, Csc[x[k]]];
myProduct[k_] := myCsc[k]* Sin[k*mC + aC + Pi/4];
Assuming[0 <= eps < Pi/2 && mM > 0 && aM > 0 && mC > 0 &&
aC > 0, Sum[myProduct[k], {k, 0, Infinity},
Regularization -> "Cesaro"]]
The code above yields the result
0
When I remove both
$\frac{\pi}{4}$ from myCsc
and the sinus, I get as result the last line of the code
Sum[If[0 <= Mod[aM + k mM, Pi] < eps || Pi - eps <
Mod[aM + k mM, Pi] <= Pi, I eps, Csc[x[k]]] Sin[aC + k mC],
{k, 0,Infinity}, Regularization -> "Cesaro"]
My question
Why does the result depend on the (mathematically) redundant summand
$\frac{\pi}{4}$?
My concern
Since the parameters
$a_M$ and
$a_C$ can be chosen arbitrarily, they may well contain the "additional" summand
$\frac{\pi}{4}$ and the summation result should be the same.
- I am not sure of what it means when Mathematica simply rewrites the sum (the last line of the code above) into its output. It might be that the sum diverges, that Cesaro is not the correct regularization or simply that Mathematica does not find the result_.
- In either case however the result with and without the summands
$\frac{\pi}{4}$, should be the same._
Some more findings across different versions
I have posted this elsewhere already and got an concerning message that on Mathematica version 12, the output of the code above (with the summands
$\frac{\pi}{4}$) is the returned input (i.e. not zero as on my machine - I am using Mathematica home edition, version 11.0.1.0).
The fact that 2 different versions yield different results leaves me flabbergasted and I realize that without being able to run different versions on my machine, I have to unfortunately end of what I am trying to do.
NB: both codes have been copy pasted from the same publication (I do not know which version to "trust").
The very same Mathematica code (above) can be written also by replacing the functions of k by simple egalities (i.e. instead of the f[k_]:= one can simply write f=); the result I get with my version 11 is the same (zero with the summands
$\frac{\pi}{4}$) and input returned without).
Background information on the context of what I am trying to do:
The overal sum is part of a thermal conductance along an array of cyclinders.
I am trying to take the sum over a cosecant and am therefore defining that rather misbehaving myCsc
function to avoid the singularities by splitting the cosecant into the two cases.
In the hope to be able to take the limit with
$\epsilon\rightarrow$ 0 after the summation, the result eventually being zero is indeed promising. Although this being a bit cowboy mathematics, my question is about the Mathematica result being different with and without the summand
$\frac{\pi}{4}$.