We have
\begin{equation}
\begin{cases}
u_{tt} = c^2 u_{xx} \ \ & \text{for} \ -\infty < x < \infty, \ 0 \leq t < \infty\\
u(x,0) = \phi(x) \ \ & \text{for} \ -\infty < x < \infty\\
u_t(x,0) = \psi(x) \ \ & \text{for} \ -\infty < x < \infty
\end{cases}
\end{equation}
Therefore
\begin{equation}
\phi(x) = 0 \ \ \ \text{and} \ \ \ \psi(x) = 0
\end{equation}
and
\begin{equation}
KE = \frac{1}{2}\int_{-\infty}^{\infty} \rho u_t^{2} dx
\end{equation}
\begin{equation}
PE = \frac{1}{2} \int_{-\infty}^{\infty} T u_x^{2} dx
\end{equation}
From equation $(1)$ $u_{tt} = c^2 u_{xx}$ then
\begin{equation}
u_{tt} - c^2 u_{xx} = 0
\end{equation}
Here, $A = -c^2, B = 0$, and $C = 1$. Thus
\begin{equation}
B^2 - 4AC = 4C^2 > 0
\end{equation}
So the equation is hyperbolic. The equation characteristics are
\begin{equation}
\frac{dt}{dx} = \pm\frac{1}{C}
\end{equation}
or $$\xi = x - ct = \ \text{const} \ \ \ \text{and} \ \ \ \eta = x + ct = \ \text{const}$$
Now, in terms of new coordinates $\xi$ and $\eta$ then $$u_{xx} = u_{\xi \xi} + 2u_{\xi \eta} + u_{\eta \eta} \ \ \ u_{tt} = c^2(u_{\xi\xi} - 2 u_{\xi\eta + u_{\eta\eta}}$$
Thus, equation $(1)$ becomes
\begin{equation}
-4c^2 u_{\xi\eta} = 0
\end{equation}
Therefore $c\neq 0$,
\begin{equation}
u_{\xi \eta} = 0
\end{equation}
So, integrating $u_{\xi\eta} = 0$ twice we then get the solution
\begin{equation}
u(\xi \eta) = \phi(\xi) + \psi(\eta)
\end{equation}
where $\phi$ and $\psi$ are arbitrary functions. So, in terms of $x$ and $t$
\begin{equation}
u(x,t) = \phi(x - ct) + \psi(x + ct)
\end{equation}
Now from
\begin{equation}
u(x,0) = \phi(x) \ \ \ \text{and} \ \ \ u_t(x,0) = \psi(x)
\end{equation}
So,
\begin{equation}
\phi(x) + \psi(x) = \phi(x)
\end{equation}
and
\begin{equation}
-c \phi^{\prime}(x) + c\psi^{\prime}(x) = \psi(x)
\end{equation}
Integrating equation $(14)$
\begin{equation}
-c \phi(x) + c\phi(x) = \int_{x_0}^{x}\psi(\tau)d\tau
\end{equation}
where $x_0$ is an arbitrary constant. Now equation $(13)$ and $(15)$ becomes
$$\phi(x) = \frac{1}{2}\phi(x) - \frac{1}{2c}\int_{x_0}^{x}\psi(\tau)d\tau$$
and
$$\psi(x) = \frac{1}{2}\psi(x) + \frac{1}{2c}\int_{x_0}^{x}\psi(\tau)d\tau$$
Thus, equation $(11)$ gives the solution (D'Alembert solution) of the Cauchy problem as
$$u(x,t) = \frac{1}{2}\left[ \phi(x - ct) + \phi(x + ct) \right] + \frac{1}{2c}\int_{x-ct}^{x+ct}\psi(\tau)d\tau$$
So we have
$$u_t(x,t) = \frac{1}{2}\frac{\partial}{\partial t}\left[ \phi(x - ct) + \phi(x + ct) \right] + \frac{1}{2c}\frac{\partial}{\partial t}\left[ \int_{x-ct}^{x+ct} \psi(\tau)d\tau \right]$$
and
$$u_{x}(x,t) = \frac{1}{2}\frac{\partial}{\partial x}\left[ \phi(x-ct) + \phi(x+ct) \right] + \frac{1}{2c}\frac{\partial}{\partial x}\left[ \int_{x - ct}^{x+ct}\psi(\tau)d\tau \right]$$
therefore
$$KE = \frac{1}{2}\int_{-\infty}^{\infty}\rho u_{t}^{2}dx$$
So,
$$KE = \frac{1}{2}\int_{-\infty}^{\infty}\rho\left[ \frac{1}{2}\frac{\partial}{\partial t} \left[ \phi(x-ct) + \phi(x + ct) \right] \right] + \frac{1}{2c}\frac{\partial}{\partial t}\left[\int_{x - ct}^{x+ct}\psi(\tau)d\tau \right]^2dx$$
and $$PE = \frac{1}{2} \int_{-\infty}^{\infty} T u_x^{2} dx$$
So,
$$PE = \frac{1}{2}\int_{-\infty}^{\infty}T\left[ \frac{1}{2}\frac{\partial}{\partial x}\left[ \phi(x - ct) + \phi(x + ct) \right] + \frac{1}{2c}\frac{\partial}{\partial x}\left[ \int_{x-ct}^{x+ct} \psi(\tau)d\tau \right] \right]^2dx$$
Thus from above, we can see that for $t > 0$, $KE$ and $PE$ is constant thus $KE = PE$ at some stage.