

Private Member Functions | |
| Point3d | computePosition (double jd) const |
| double | getBoundingRadius () const |
| double | getPeriod () const |
|
|
Implements CachingOrbit. Definition at line 384 of file customorbit.cpp. References computePlanetCoords(), computePlanetElements(), cos(), degToRad(), distance(), gPlanetElements, PI, and sin(). 00385 {
00386 const int p = 0; //Planet 0
00387 vector<int> pList;
00388 double t;
00389 double map[4];
00390 double dl, dr, dml, ds, dm, da, dhl;
00391 double eclLong, eclLat, distance; //heliocentric longitude, latitude, distance
00392
00393 dl = dr = dml = ds = dm = da = dhl = 0.0;
00394
00395 // Calculate the Julian centuries elapsed since 1900
00396 t = (jd - 2415020.0)/36525.0;
00397
00398 // Specify which planets we must compute elements for
00399 pList.push_back(0);
00400 pList.push_back(1);
00401 pList.push_back(3);
00402 computePlanetElements(t, pList);
00403
00404 // Compute necessary planet mean anomalies
00405 map[0] = degToRad(gPlanetElements[0][0] - gPlanetElements[0][2]);
00406 map[1] = degToRad(gPlanetElements[1][0] - gPlanetElements[1][2]);
00407 map[2] = 0.0;
00408 map[3] = degToRad(gPlanetElements[3][0] - gPlanetElements[3][2]);
00409
00410 // Compute perturbations
00411 dl = 2.04e-3*cos(5*map[1]-2*map[0]+2.1328e-1)+
00412 1.03e-3*cos(2*map[1]-map[0]-2.8046)+
00413 9.1e-4*cos(2*map[3]-map[0]-6.4582e-1)+
00414 7.8e-4*cos(5*map[1]-3*map[0]+1.7692e-1);
00415
00416 dr = 7.525e-6*cos(2*map[3]-map[0]+9.25251e-1)+
00417 6.802e-6*cos(5*map[1]-3*map[0]-4.53642)+
00418 5.457e-6*cos(2*map[1]-2*map[0]-1.24246)+
00419 3.569e-6*cos(5*map[1]-map[0]-1.35699);
00420
00421 computePlanetCoords(p, map[p], da, dhl, dl, dm, dml, dr, ds,
00422 eclLong, eclLat, distance);
00423
00424 // Corrections for internal coordinate system
00425 eclLat -= (PI/2);
00426 eclLong += PI;
00427
00428 return Point3d(cos(eclLong) * sin(eclLat) * distance,
00429 cos(eclLat) * distance,
00430 -sin(eclLong) * sin(eclLat) * distance);
00431 };
|
|
|
Implements CachingOrbit. Definition at line 438 of file customorbit.cpp. References BoundingRadiusSlack. 00439 {
00440 return 6.98e+7 * BoundingRadiusSlack;
00441 };
|
|
|
Implements CachingOrbit. Definition at line 433 of file customorbit.cpp. 00434 {
00435 return 87.9522;
00436 };
|
1.4.1