Page 1 of 1

Help with ::cachingorbit

Posted: 23.11.2008, 17:56
by MARKS
Hello all, I would like to put an object inside celestia, using a new class which inherits cachingOrbit, as IoOrbit do. I took as a model IoOrbit, but I can't understand how to link ComputeGalileanElements and their variables(gamma, phi, psi, sigma, etc) with the Elliptical Orbit elements, and I don't know what mean the angles gamma, phi, psi, sigma and the calculation of sigma, B and R.

// Calculate periodic terms for longitude
sigma = 0.47259*sin(2*(l1 - l2)) - 0.03478*sin(p3 - p4)
+ 0.01081*sin(l2 - 2*l3 + p3) + 7.38e-3*sin(phi)
+ 7.13e-3*sin(l2 - 2*l3 + p2) - 6.74e-3*sin(p1 + p3 - 2*LPEJ - 2*G)
+ 6.66e-3*sin(l2 - 2*l3 + p4) + 4.45e-3*sin(l1 - p3)
- 3.54e-3*sin(l1 - l2) - 3.17e-3*sin(2*(psi - LPEJ))
+ 2.65e-3*sin(l1 - p4) - 1.86e-3*sin(G)
+ 1.62e-3*sin(p2 - p3) + 1.58e-3*sin(4*(l1 - l2))
- 1.55e-3*sin(l1 - l3) - 1.38e-3*sin(psi + w3 - 2*LPEJ - 2*G)
- 1.15e-3*sin(2*(l1 - 2*l2 + w2)) + 8.9e-4*sin(p2 - p4)
+ 8.5e-4*sin(l1 + p3 - 2*LPEJ - 2*G) + 8.3e-4*sin(w2 - w3)
+ 5.3e-4*sin(psi - w2);
sigma = pfmod(sigma, 360.0);
sigma = degToRad(sigma);
L = l1 + sigma;

// Calculate periodic terms for the tangent of the latitude
B = 6.393e-4*sin(L - w1) + 1.825e-4*sin(L - w2)
+ 3.29e-5*sin(L - w3) - 3.11e-5*sin(L - psi)
+ 9.3e-6*sin(L - w4) + 7.5e-6*sin(3*L - 4*l2 - 1.9927*sigma + w2)
+ 4.6e-6*sin(L + psi - 2*LPEJ - 2*G);
B = atan(B);

// Calculate the periodic terms for distance
R = -4.1339e-3*cos(2*(l1 - l2)) - 3.87e-5*cos(l1 - p3)
- 2.14e-5*cos(l1 - p4) + 1.7e-5*cos(l1 - l2)
- 1.31e-5*cos(4*(l1 - l2)) + 1.06e-5*cos(l1 - l3)
- 6.6e-6*cos(l1 + p3 - 2*LPEJ - 2*G);
R = 5.90569 * JupiterRadius * (1 + R);

Is there any document I can read to understand how works this classes and how calculate Point3d??
Thanks for your help.