I'm a newbie in string theory and I'm trying to get some insights about Polyakov action for the bosonic closed string, although my question isn't uniquely related with string theory: it is about counting the degrees of freedom of a field theory.
In conformal gauge the equation of motion for the string plus the condition $T_{ab}=0$ give three equations to be satisfied:
$$\begin{cases}
\partial^{a}\partial_{a}X^{\mu}=0 \\
T_{11} = T_{00} = \dfrac{1}{2} \left( (\partial_{0}X)^2 + (\partial_{1}X)^2 \right)=0 \\
T_{10}=T_{01}= (\partial_{0}X^{\mu})(\partial_{1}X_{\mu}) = 0
\end{cases}
$$
Here's my reasoning:
The first equation allows me to write $X_{\mu}$ in the same way we write the Fourier expansion for the electromagnetic field $A_{\mu}$ s.t. $\square A_{\mu}=0 $; therefore we do not have any constraint on the Fourier coefficients, the only condition we have is the on shell condition. Here I would conclude that - before considering the other two equations - I have $D$ degrees of freedom where $D$ is the target spacetime dimension $\mu = 0,...,D-1$. Now imposing the other two equations I reduce by $2$ the number of independent Fourier coefficients (or indepenent components or degrees of freedom DOF). Eventually conformal invariance reduces by another $2$ the number of DOF, so that I get
$$ DOF = D-4$$
This reasoning seems correct when we're dealing with the electromagnetic field, indeed in that case $D=4$ and gauge invariance reduces by two the number of DOF, ending up with $DOF=2$ which are the two transverse polarizations.
But, following Tong's lectures (at the end of chapter one), going through lightcones coordinates, one ends up with $$DOF = 2D-4$$ It seems that I was wrong in the first part of my reasoning when I stated that $\partial^{a}\partial_{a}X^{\mu}=0$ implies DOF = D. But why? I mean, it works for the electromagnetic potential, why shouldn't it work here?