A real GS formula from TAS takes into account two velocity triangles: one with the vertical velocity, and one with the wind velocity.
- Vertical velocity. Here's the velocity triangle. With no wind, we get:
$$ cos(\Phi) = \frac {GS}{TAS} \tag{1}$$
$$ sin(\Phi) = \frac{V_C}{TAS} \tag {2}$$
And we know from math lessons that $sin^2(\Phi)$ + $cos^2(\Phi)$ = 1, so:
$$\frac {GS^2}{TAS^2} + \frac{V_C^2}{TAS^2} = 1 => GS^2 + V_C^2 = TAS^2 => $$
$$GS = \sqrt{TAS^2 - V_C^2} \tag{3}$$.
- Wind speed. The equation in the OP just adds wind speed to the TAS, and this is only valid if the wind direction is the same as the flight direction. This is usually not the case, and we will need to consider another velocity triangle, this time from the viewpoint of looking down on the plane:
In this example, $\Phi$ = 70-30 = 40°. The cosine of the wind speed we can add directly to the ground speed, the sine component will need to be added in a Pythagoras way.
$${V_{TOT}}^2 = (V + V_W \cdot cos (\Phi))^2 + (V_W \cdot sin (\Phi))^2$$
=> $$ {V_{TOT}}^2 = V^2 + 2 \cdot V \cdot V_W \cdot cos(\Phi)+ {V_W}^2 \cdot cos^2(\Phi) + {V_W}^2 \cdot sin^2(\Phi)$$
and again since $sin^2(\Phi)$ + $cos^2(\Phi)$ = 1
$$ {V_{TOT}}^2 = V^2 + {V_W}^2 + 2 \cdot V \cdot V_W \cdot cos(\Phi) \tag{4}$$
- Combine equations (3) and (4)
$$ GS = \sqrt{TAS^2 - {V_C}^2 + {V_W}^2 + 2 \cdot \sqrt{TAS^2 - {V_C}^2}\cdot V_W \cdot cos(\Phi)} \tag{5}$$