Suppose $t\in\mathbb{R_+}$ - some parameter, $V: \mathbb{R}\to\mathbb{R}$ - some function. I have an operator $S:f\mapsto S[f]$ that maps a function $f$ to a function $S[f]$: $$ S[f](x) = f(x+\sqrt{t})+2f(x)+f(x-\sqrt{t})-\arctan(tV(x))f(x) $$ My goal is to find a formula for power $S^n$ of the operator $S$, and I wonder if Mathematica can help here. To find a general formula I first decided to compute some of the powers $S^2, S^3,...$ and look for a pattern. But doing so on paper is very tedious process. How can I input this formula to Mathematica and use its ability of symbolic computation to get formal representation (with like terms collected) for $S^2[f]=S[S[f]]$, $S^3[f]=S[S[S[f]]]$?
For example, formula for $S^2$ would look like this: $$ f(x+2\sqrt{t})+4f(x+\sqrt{t})+6f(x)+4f(x-\sqrt{t})+f(x-2\sqrt{t})-\arctan(tV(x+\sqrt{t}))f(x+\sqrt{t}) -4\arctan(tV(x))f(x)-\arctan(tV(x-\sqrt{t}))f(x-\sqrt{t}))-\arctan(tV(x))f(x+\sqrt{t})-\arctan(tV(x))f(x-\sqrt{t})+\arctan(tV(x))^2 $$
Simpler example: let $K[f][x] = f[x+t]+f[x]$. Then $$K^2[f][x] = K[f][x+t]+K[f][x] = f[x+2t]+2f[x+t]+f[x]$$ $$K^3[f][x] = K^2[f][x+t]+K^2[f][x] = f[x+3t]+3f[x+2t]+3f[x+t]+f[x]$$
So by inputing $K[f][x] = f[x+t]+f[x]$ and 3-rd power I would like to get the output $$f[x+3t]+3f[x+2t]+3f[x+t]+f[x]$$
Nest
: reference.wolfram.com/language/ref/Nest.html#32108 $\endgroup$S[f_][x_]
, and then applyNest
(orFold
) toS[f][x]
for the "powers" of $S[f]$. $\endgroup$