Orbit.cpp   Orbit.cpp 
skipping to change at line 132 skipping to change at line 132
rotateToVsop87[4] = -s_nod*sj+c_nod*c_obl*cj; rotateToVsop87[4] = -s_nod*sj+c_nod*c_obl*cj;
rotateToVsop87[5] = -c_nod*s_obl; rotateToVsop87[5] = -c_nod*s_obl;
rotateToVsop87[6] = s_obl*sj; rotateToVsop87[6] = s_obl*sj;
rotateToVsop87[7] = s_obl*cj; rotateToVsop87[7] = s_obl*cj;
rotateToVsop87[8] = c_obl; rotateToVsop87[8] = c_obl;
} }
void CometOrbit::positionAtTimevInVSOP87Coordinates(double JD,double *v) co nst { void CometOrbit::positionAtTimevInVSOP87Coordinates(double JD,double *v) co nst {
JD -= t0; JD -= t0;
double a1,a2; double a1,a2;
if (e < 1.0) InitEll(q,n,e,JD,a1,a2); // temporary solve freezes for near-parabolic comets - using (e < 0.9999)
for elliptical orbits
// TODO: improve calculations orbits for near-parabolic comets --AW
if (e < 0.9999) InitEll(q,n,e,JD,a1,a2);
else if (e > 1.0) InitHyp(q,n,e,JD,a1,a2); else if (e > 1.0) InitHyp(q,n,e,JD,a1,a2);
else InitPar(q,n,JD,a1,a2); else InitPar(q,n,JD,a1,a2);
double p0,p1,p2; double p0,p1,p2;
Init3D(i,Om,o,a1,a2,p0,p1,p2); Init3D(i,Om,o,a1,a2,p0,p1,p2);
v[0] = rotateToVsop87[0]*p0 + rotateToVsop87[1]*p1 + rotateToVsop87[2]*p2 ; v[0] = rotateToVsop87[0]*p0 + rotateToVsop87[1]*p1 + rotateToVsop87[2]*p2 ;
v[1] = rotateToVsop87[3]*p0 + rotateToVsop87[4]*p1 + rotateToVsop87[5]*p2 ; v[1] = rotateToVsop87[3]*p0 + rotateToVsop87[4]*p1 + rotateToVsop87[5]*p2 ;
v[2] = rotateToVsop87[6]*p0 + rotateToVsop87[7]*p1 + rotateToVsop87[8]*p2 ; v[2] = rotateToVsop87[6]*p0 + rotateToVsop87[7]*p1 + rotateToVsop87[8]*p2 ;
} }
EllipticalOrbit::EllipticalOrbit(double pericenterDistance, EllipticalOrbit::EllipticalOrbit(double pericenterDistance,
 End of changes. 1 change blocks. 
1 lines changed or deleted 4 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/