Is Sun distance wrong?

Report bugs, bug fixes and workarounds here.
Topic author
makc
Posts: 18
Joined: 09.01.2007
With us: 17 years 10 months

Is Sun distance wrong?

Post #1by makc » 21.01.2007, 02:07

It comes from buildstardb.cpp, function HipparcosStar TheSun(), where parallax is set to 1000000.0f; this causes sun to be listed with distance 0.00326167 ly in data/stars.txt and data/nearstars.stc :O Compare that to astro::AUtoLightYears(1), which gives 1.580302e-5.

I wonder if it is even used...

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 2 months
Location: NY, USA

Post #2by selden » 21.01.2007, 13:04

In older versions of Celestia, the Sun is offset from [0,0,0] in order to avoid problems caused by division by zero.

This has been changed in v1.5.0 (currently in prerelease) so that the Solar System's barycenter is at the origin and the Sun correctly orbits around it. The Sun's orbital path looks quirky in v1.5.0 because the Sun's orbit does not follow an ellipse due to the motions of the major planets.
Selden


Return to “Bugs”