[Kstars-devel] branches/kstars/unfrozen/kstars/kstars/tools
Jason Harris
kstars at 30doradus.org
Tue Jul 1 07:37:31 CEST 2008
SVN commit 826613 by harris:
One more port from trunk, revision 826203. Quoting original commit message:
Forcing the algorithm to find conjunctions take finer steps when
dealing with the Moon, Venus and Mars, than before.
Also removing the condition on prevSign to check for a minimum. This
condition was probably incorrect, and removing it seems to produce
more (correct) results.
These fixes certainly make the conjunction tool slower, but more
exhaustive in listing out conjunctions.
CCMAIL: kstars-devel at kde.org
M +6 -6 ksconjunct.cpp
--- branches/kstars/unfrozen/kstars/kstars/tools/ksconjunct.cpp #826612:826613
@@ -50,14 +50,14 @@
step = (stopJD - startJD) / 4.0;
if(Object1.name() == "Mars" || Object2.name() == "Mars")
- if (step > 30.0)
- step = 30.0;
+ if (step > 10.0)
+ step = 10.0;
if(Object1.name() == "Venus" || Object1.name() == "Mercury" || Object2.name() == "Mercury" || Object2.name() == "Venus")
- if (step > 15.0)
- step = 15.0;
- if(Object1.name() == "Moon" || Object2.name() == "Moon")
if (step > 5.0)
step = 5.0;
+ if(Object1.name() == "Moon" || Object2.name() == "Moon")
+ if (step > 0.25)
+ step = 0.25;
// kDebug() << "Initial Separation between " << Object1.name() << " and " << Object2.name() << " = " << (prevDist.toDMSString());
@@ -66,7 +66,7 @@
// kDebug() << "Dist = " << Dist.toDMSString() << "; prevDist = " << prevDist.toDMSString() << "; Difference = " << (Dist - prevDist).toDMSString();
Sign = sgn(Dist.Degrees() - prevDist.Degrees());
- if(Sign != prevSign && prevSign == 1) { // The prevSign == 1 ensures that we pick up only minima and don't waste time finding maxima
+ if( Sign != prevSign ) {
// kDebug() << "Sign = " << Sign << " and " << "prevSign = " << prevSign << ": Entering findPrecise()\n";
if(findPrecise(&extremum, &Object1, &Object2, jd, step, prevSign))
if(extremum.second.radians() < maxSeparation.radians())
More information about the Kstars-devel
mailing list