A Space & astronomy forum. SpaceBanter.com

Go Back   Home » SpaceBanter.com forum » Others » UK Astronomy
Site Map Home Authors List Search Today's Posts Mark Forums Read Web Partners

Orbital elements



 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old April 8th 04, 06:23 PM
james
external usenet poster
 
Posts: n/a
Default Orbital elements

Hello

Ok this is a difficult one (well for me any way)

How do you calculate an objects heilocentric co-ordinates (x,y,z with
the sun at the center) of an object given its Epoch,a,e,i,w,Node,M
values ?

Any pointers will help even if its just a weblink


This is what I have so far in c++

double T,au,e,i,omega,n,w,M,F,G,H,P,Q,R,A,B,C,a,b,c = 0.0;

CString temp;
m_a.GetWindowText(temp);
au = atof(temp);
m_t.GetWindowText(temp);
T = atof(temp);
m_e.GetWindowText(temp);
e = atof(temp);
m_i.GetWindowText(temp);
i = atof(temp);
m_omega.GetWindowText(temp);
omega = atof(temp);
m_w.GetWindowText(temp);
w = atof(temp);
m_n.GetWindowText(temp);
n = atof(temp);

F = cos(omega * DegRad);
G = (sin(omega * DegRad) * 0.917482062);
H = (sin(omega * DegRad) * 0.397777156);

P = -sin(omega * DegRad) * cos(i * DegRad);
Q = (cos(omega * DegRad) * cos(i * DegRad) * 0.917482062) - (sin(i *
DegRad) * 0.397777156);
R = (cos(omega * DegRad) * cos(i * DegRad) * 0.397777156) + (sin(i *
DegRad) * 0.917482062);

A = rev(atan2(F,P) * RadDeg);
B = rev(atan2(G,Q) * RadDeg);
C = rev(atan2(H,R) * RadDeg);

a = sqrt(F*F + P*P);
b = sqrt(G*G + Q*Q);
c = sqrt(H*H + R*R);

n = 0.9856076696 / (au * sqrt(au));

M = T * n;

double E0 = M;
double E1 = E0 + ((M + (e * RadDeg) * sin(E0 * DegRad) - E0) / (1 - e
* cos(E0 * DegRad)));
double E2 = E1 + ((M + (e * RadDeg) * sin(E1 * DegRad) - E1) / (1 - e
* cos(E1 * DegRad)));
double E3 = E2 + ((M + (e * RadDeg) * sin(E2 * DegRad) - E2) / (1 - e
* cos(E2 * DegRad)));
double E4 = E3 + ((M + (e * RadDeg) * sin(E3 * DegRad) - E3) / (1 - e
* cos(E3 * DegRad)));

double x = au * (cos(E4 * DegRad) - e);
double y = au * sqrt(1 - e*e) * sin(E4 *DegRad);
double v = atan2(y,x);
v = v * RadDeg;

double r = au * ( 1 - e * cos(E4 * DegRad) );

double X = r * a * sin((A + w + v) * DegRad);
double Y = r * b * sin((B + w + v) * DegRad);
double Z = r * c * sin((C + w + v) * DegRad);

temp.Format("%f",X);
m_x.SetWindowText(temp);
temp.Format("%f",Y);
m_y.SetWindowText(temp);
temp.Format("%f",Z);
m_z.SetWindowText(temp);
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Hans Moravec's Original Rotovator Paper James Bowery Policy 0 July 6th 04 07:45 AM
Need orbital elements at ET sep Ian J. E. Jordan Space Shuttle 1 April 2nd 04 07:38 PM
Natural Satellites Orbital Elements Pasquale Tricarico Astronomy Misc 0 November 30th 03 12:50 AM
Three aerospace innovators Lockheed Martin, Northrop Grumman and Orbital Sciences Combine strengths to design and build NASA's Orbital Space Plane Jacques van Oene Space Shuttle 1 October 15th 03 12:21 AM
Three aerospace innovators Lockheed Martin, Northrop Grumman and Orbital Sciences Combine strengths to design and build NASA's Orbital Space Plane Jacques van Oene Space Station 0 October 14th 03 03:31 PM


All times are GMT +1. The time now is 09:27 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 SpaceBanter.com.
The comments are property of their posters.