9. (11th "Hope Cup" Senior High School Competition Question) The function $f(x)$ is a periodic function with a period of 2 defined on $\mathbf{R}$, and it is an even function. When $x \in [2,3]$, $f(x) = x$. Then, when $x \in [-2,0]$, the analytical expression of $f(x)$ in the form of a piecewise function is $\qquad$, and in a unified form is $\qquad$.


9. From the translation and reflection of the graph, it is not difficult to obtain
$$
f(x)=\left\{\begin{array}{ll}
x+4, & x \in[-2,-1], \\
-x+2, & x \in(-1,0] .
\end{array}\right.
$$

Thus, $f(x)=\left\{\begin{array}{ll}3+(x+1), & x+1 \in[-1,0], \\ 3-(x+1), & x+1 \in(0,1] .\end{array}\right.$
Therefore, $f(x)=3-|x+1|, x \in[-2,0]$.