[Kstars-devel] KDE/kdeedu/kstars/kstars

Jason Harris kstars at 30doradus.org
Thu Jan 3 06:55:38 CET 2008


SVN commit 756316 by harris:

Use the real instantaneous earth-sun separation, rather than 1.0 AU,
when computing the phase of a solar system body in
KSPlanetBase::findMagnitude().  Amazingly, this small fix can have a
huge impact on the final magnitude.  As an asteroid moves near the Sun
in the sky, its magnitude suddenly would get set to 0.0, so the Sun
looked like it had a "cloud" of asteeroids around it (if you used a
magnitude limit for asteroids in the options).  This fix removes the
cloud of asteroids.

CCMAIL: kstars-devel at kde.org



 M  +1 -1      ksplanetbase.cpp  


--- trunk/KDE/kdeedu/kstars/kstars/ksplanetbase.cpp #756315:756316
@@ -235,7 +235,7 @@
     dec()->SinCos(cosDec, sinDec);
 
     /* Phase of the planet in degrees */
-    double earthSun = 1.;
+    double earthSun = data->skyComposite()->earth()->rsun();
     double cosPhase = (rsun()*rsun() + rearth()*rearth() - earthSun*earthSun)
                       / (2 * rsun() * rearth() );
     double phase_rad = acos ( cosPhase ); // Phase in radian - used for asteroid magnitudes


More information about the Kstars-devel mailing list