How does gravity keep a planet moving in an orbit around the sun?
In Newtonian mechanics, the gravity is a central force attractive. Then the planet and the Sun attract each other.
In a system with initial conditions with zero speed, the two object will collapse together because the force moves the planet and the Sun along a line. If the planet has an initial velocity with a component orthogonal with respect to the line between the planet and the Sun, it exists the possibility that the planet will start to rotate around the Sun. In particular the gravity will be balanced by the centrifugal force keeping the planet orbiting.
We can try to calculate this.
The gravitational force is given by
The centrifugal force in the approximation of a planet rotating in a circle is
The balance of the two is:
I substitute the values for
This means that the product between the distance and the square of the velocity required to balance the motion is a constant. It is interesting to notice that there is no dependency from the mass of the planet. So the distance of the planets from the Sun depends only on the velocity.
Let's calculate the distance of Earth. The velocity is space divided by time. The length of a circle around the Sun (we approximate with a circle the orbit) is
I plug this in the equation of the orbit:
If we search on Wikipedia the distance of Earth from Sun we have 149.59787 million kilometers. Pretty close!