I want to sum as follows, where j is from 1 to n in each sum (if s is added to 2 when j is not added to n, then j does not need to be n):
$$Table[\sum_{s=k,j=1}^{n}(s+j),\lbrace{k,0,n\rbrace}]$$ We should get the following results (if n = 2):
{9,6,3}
I can achieve this goal like this, but is there any better way?
Table[(j = 0; Sum[(j = j + 1; (s + j)), {s, k, 2}]), {k, 0, 2}]
In fact, I have to use the sum symbol sum to do something similar to the following figure:
I deal with it like this, but I wonder if there is any other way:
boundaryD[kernelF_, x_, f_, n_: 1] :=
Module[{j},
Table[(j = 0;
Sum[(j = j + 1; (-1)^(j - 1)
D[D[kernelF, D[f[x], {x, s}]], {x, j - 1}]), {s, k, n}]), {k,
1, n}]]
boundaryD[F[x, y[x], y'[x], y''[x]], x, y, 2]