<s>[INST] Let $f(x) = |x+1|-|x-1|$, find $f \circ f\circ f\circ f ... \circ f(x)$ (n times). Let $f(x) = |x+1|-|x-1|$, find $f \circ f\circ f\circ f ... \circ f(x)$  (n times). I don't know where to start... Should I use mathematical induction? But what should be my hypothesis? Should I calculate for n = 1, n = 2?
 [/INST] First note
$$f(x) = |x+1| - |x-1|\\
= \begin{cases}
-2, & x< -1\\
2x, &  x\in [-1, 1] \\
2, &  x>1\\
\end{cases}$$
Proposition: $$\color{red}{f^{n+1}(x) = \left|2^nx+1\right| - \left| 2^nx-1\right|}$$.
Note: this is exactly equivalent to
$$f^{n+1}(x) = \begin{cases}
-2, & x< -\frac1{2^n}\\
2^{n+1}x, &  x\in [-\frac1{2^n}, \frac1{2^n}] \\
2, &  x>\frac1{2^n}\\
\end{cases}$$
Clearly true for $n=0$.  Assuming it holds for $n$, the inductive step is
$$f^{n+2}x = f\circ f^{n+1} (x)= \begin{cases}
f(-2), & x < -\frac1{2^n}\\
f(2^{n+1}x), &x\in [-\frac1{2^n}, \frac1{2^n}] \\
f(2), &  x>\frac1{2^n}\\  
\end{cases}\\
=\begin{cases}
-2, & x < -\frac1{2^n}\\
-2, &x\in [-\frac1{2^n}, -\frac1{2^{n+1}}) \\
f(2^{n+1}x), &x\in [-\frac1{2^{n+1}}, \frac1{2^{n+1}}] \\
2, &x\in (\frac1{2^{n+1}}, \frac1{2^n}] \\
2, &  x>\frac1{2^n}\\  
\end{cases}$$
$$=\begin{cases}
-2, & x < -\frac1{2^{n+1}} \\
2^{n+2}x, &x\in [-\frac1{2^{n+1}}, \frac1{2^{n+1}}] \\
2, &x > \frac1{2^{n+1}}\\  
\end{cases}\\
= |2^{n+1}x+1| - |2^{n+1}x-1|$$
</s>