Orbits are conic sections so the formula for the distance of a body for a given angle is given as,
r = ƿ / (1 + ecosƟ)
where,
ƿ = h2 / µ
µ= called the gravitational parameter
h = the specific angular momentum of object 2 with respect to object 1
Ɵ = known as the true anomaly
ƿ = the semi-latus rectum
e = the orbital eccentricity