How do I calculate the position of the Earth in a 3d engine?

31 Views Asked by At

If I place the Sun at the center of a 3d engine (0,0,0), how do I calculate the position of the Earth ?

What about calculating how complete the Earths' rotational period is at any given time? (Ex: at this instant is the Earth half-way through its rotation period? a quarter? three-quarters? etc.)

I don't need the distance to be to scale.

Thanks