The Algorithm Description
The Computation Process
Let the Space Shuttle attitude angles be defined as Y=yaw, P=pitch, R=roll.
M =
cos(P)*cos(Y) | sin(Y)*cos(P) | -sin(P) |
cos(Y)*sin(P)*sin(R)-sin(Y)*cos(R) | sin(Y)*sin(P)*sin(R)+cos(Y)*cos(R) | cos(P)*sin(R) |
cos(Y)*sin(P)*cos(R)+sin(Y)*sin(R) | sin(Y)*sin(P)*cos(R)-cos(Y)*sin(R) | cos(P)*cos(R) |
GTOD_pv = M * LITE_pv.
NOTES:
The iteration is complete when the return_radius is within a user specified tolerance of the geoid_radius.
Initialize the following working parameters:
range_value = 0.0
x_pos = GTOD X position
y_pos = GTOD Y position
z_pos = GTOD Z position
new_pv = range_value * GTOD_pv.
x_new = x_pos + new_pv_x
y_new = y_pos + new_pv_y
z_new = z_pos + new_pv_z
return_radius = sqrt(x_new*x_new + y_new*y_new + z_new*z_new)
declination = z_new/return_radius
geoid_radius = ellipsoid_radius + undulation
x_vector = x_surface - x_pos,
y_vector = y_surface - y_pos,
z_vector = z_surface - z_pos.
The magnitude of the altitude vector, alt_mag, is defined as
alt_mag = sqrt(x_vector*x_vector+y_vector*y_vector+z_vector*z_vector),
and the off-nadir angle is defined as
off-nadir angle = acosd( (x_vector*GTOD_pv_x+y_vector*GTOD_pv_y+z_vector*GTOD_pv_z)/alt_mag ).