The equation is
$$10X+0.07\cdot X\cdot \sum_{k=1}^{10} \frac{1-1.06^k}{1-1.06}=50,000$$
You have already found out that $X$ is invested ten times.
The last period one interest payment is made due the last investment, but not compounded ($k=0$, the fraction is 1).
The period before another investment is made. The interest for the last period are $0.07X$ (not compounded). The interest of the interest of the period before are $0.07X\cdot 1.06$ ($k=1$). You can go on backward like this.
The equation can be simplified to
$$10X+\frac{0.07}{0.06}\cdot X\cdot (1.06\cdot \frac{1.06^{10}-1}{0.06}-10)=50,000$$