5. The minimum value of the function $y=\left(\mathrm{e}^{x}-a\right)^{2}+\left(\mathrm{e}^{-x}-a\right)^{2}(0<a<2)$ is
5. $2(a-1)^{2}$.
$f(x)=\left[\left(e^{x}+e^{-x}\right)-a\right]^{2}+a^{2}-2$. Since $e^{x}+e^{-x} \geqslant 2,0<a<2$, when $e^{x}+e^{-x}=2$ at $x=0$, $f_{\text {min }}=2(a-1)^{2}$.