Consider the following simple Atwood machine with an ideal pulley and an ideal string
According to my textbook, the tension on the clamp that holds the machine to the wall equals $2T$. I don't understand why that is. The tension in $T$ in the string is equal in magnitude to $m_1g + m_1a = m_2g - m_2a$, assuming that $m_1$ is accelerating upwards.
Also, the acceleration of masses in an atwood machine is given by
$$a = \frac{(m_2 - m_1)g}{m_1 + m_2}$$
Substituting this in, we get the tension equal to
$$T = m_1g + m_1\frac{(m_2 - m_1)g}{m_1 + m_2} = m_1g\left(1 + \frac{m_2 - m_1}{m_2 + m_1}\right) = \frac{2m_2m_1g}{m_1 + m_2}$$
So, according to my textbook, the tension on the pulley clamp should be:
$$2T = \frac{4m_1m_2g}{m_1 + m_2}$$
But, aren't all these forces internal forces? If we consider the whole atwood machine as the system (excluding the clamp), the only forces acting on it are the force of gravity, $(m_1 + m_2)g$ and the tension in the clamp, $T_c$. Since the system is at rest
$$T_c = (m_1 + m_2)g$$
Am I right, or is there a flaw in my argument?