11. Given
$$
f(x)=\cos 2x + p|\cos x| + p \quad (x \in \mathbf{R}) \text{.}
$$

Let the maximum value of $f(x)$ be $h(p)$. Then the expression for $h(p)$ is $\qquad$ .
11. $\left\{\begin{array}{ll}p-1, & p\frac{1}{2}\end{array}\right.$
Therefore, $h(\dot{p})=\left\{\begin{array}{ll}p-1, & p<-2 ; \\ 2 p+1, & p \geqslant-2 .\end{array}\right.$