Go to the documentation of this file.
21 int orb2lla(
int nRecords,
double orb[],
double lon[],
double lat[],
double alt[]) {
25 double f = 1.0 / 298.257;
28 double omf2, omf2p, rad, pxy, temp, rl;
29 omf2 = (1.0 -
f)*(1.0 -
f);
31 for (
i = 0;
i < nRecords;
i++) {
33 lon[
i] = (180.0 /
M_PI) * atan2(orb[1 +
i * 6], orb[0 +
i * 6]);
36 rad = sqrt(orb[0 +
i * 6] * orb[0 +
i * 6] + orb[1 +
i * 6] * orb[1 +
i * 6] + orb[2 +
i * 6] * orb[2 +
i * 6]);
37 omf2p = (
omf2 * rem + rad - rem) / rad;
38 pxy = orb[0 +
i * 6] * orb[0 +
i * 6] + orb[1 +
i * 6] * orb[1 +
i * 6];
39 temp = sqrt(orb[2 +
i * 6] * orb[2 +
i * 6] + omf2p * omf2p * pxy);
40 lat[
i] = (180.0 /
M_PI) * asin(orb[2 +
i * 6] / temp);
43 rl =
re * (1.0 -
f) / sqrt(1.0 - (2.0 -
f) *
f * pxy / (rad * rad));
double precision function f(R1)
int orb2lla(int nRecords, double orb[], double lon[], double lat[], double alt[])