| 884 | // already been computed. Useful when doing many transforms in a row. |
| 885 | |
| 886 | void CoorXformFast(real *azi, real *alt, real sinazi, real cosazi, |
| 887 | real sinalt, real cosalt, real sintilt, real costilt) |
| 888 | { |
| 889 | real x, y, a1, l1; |
| 890 | |
| 891 | x = cosalt * sinazi * costilt - sinalt * sintilt; |
| 892 | y = cosalt * cosazi; |
| 893 | l1 = RAngle(y, x); |
| 894 | a1 = cosalt * sinazi * sintilt + sinalt * costilt; |
| 895 | a1 = RAsin(a1); |
| 896 | *azi = DFromR(l1); *alt = DFromR(a1); |
| 897 | } |
| 898 | |
| 899 | |
| 900 | // Convert an ecliptic position to equatorial, or vice versa. Unlike |