![]() |
libTheSky
Routines to compute sky positions of Sun, Moon, planets and more
|
Procedures for coordinates. More...
Functions/Subroutines | |
| subroutine | hc_spher_2_gc_rect (l, b, r, l0, b0, r0, x, y, z) |
| Compute the geocentric rectangular coordinates of a planet, from its and the Earth's heliocentric spherical position. | |
| subroutine | ecl_spher_2_eq_rect (l, b, r, eps, x, y, z) |
| Convert spherical, ecliptical coordinates to rectangular, equatorial coordinates of an object - both geocentric. | |
| subroutine | calcsunxyz (t1, l0, b0, r0, x, y, z) |
| Compute the geocentric equatorial rectangular coordinates of the Sun, from Earth's heliocentric, spherical position. | |
| subroutine | precess_xyz (jd1, jd2, x, y, z) |
| Compute the precession of the equinoxes in rectangular coordinates, from jd1 to jd2. | |
| subroutine | precess_eq (jd1, jd2, a1, d1) |
| Compute the precession of the equinoxes in equatorial coordinates, from jd1 to jd2. | |
| subroutine | precess_eq_yr (yr1, yr2, a1, d1) |
| Compute the precession of the equinoxes in equatorial coordinates, from yr1 to yr2. | |
| subroutine | precess_ecl (jd1, jd2, l, b) |
| Compute the precession of the equinoxes in geocentric ecliptical coordinates. | |
| subroutine | precess_orb (jd1, jd2, i, o1, o2) |
| Compute the precession of the equinoxes in orbital elements. | |
| subroutine | rect_2_spher (x, y, z, l, b, r) |
| Convert rectangular coordinates x,y,z to spherical coordinates l,b,r. | |
| subroutine | aberration_ecl (t, l0, l, b) |
| Correct ecliptic longitude and latitiude for annual aberration. | |
| subroutine | aberration_eq (jd, ra, dec, dra, ddec, eps0) |
| Correct equatorial coordinates for annual aberration - moderate accuracy, use for stars. | |
| subroutine | fk5 (t, l, b) |
| Convert coordinates to the FK5 system. | |
| subroutine | ecl_2_eq (l, b, eps, ra, dec) |
| Convert (geocentric) spherical ecliptical coordinates l,b (and eps) to spherical equatorial coordinates RA, Dec. | |
| subroutine | eq_2_ecl (ra, dec, eps, l, b) |
| Convert (geocentric) spherical equatorial coordinates RA, Dec (and eps) to spherical ecliptical coordinates l,b. | |
| subroutine | eq2horiz (ra, dec, agst, hh, az, alt, lat, lon) |
| Convert spherical equatorial coordinates (RA, dec, agst) to spherical horizontal coordinates (hh, az, alt) | |
| subroutine | horiz2eq (az, alt, agst, hh, ra, dec, lat, lon) |
| Convert spherical horizontal coordinates (az, alt, agst) to spherical equatorial coordinates (hh, RA, dec) | |
| subroutine | eq2gal (ra, dec, l, b) |
| Convert spherical equatorial coordinates (RA, dec) to spherical galactic coordinates (l,b), for J2000.0!!! | |
| subroutine | gal2eq (l, b, ra, dec) |
| Convert spherical galactic coordinates (l,b) to spherical equatorial coordinates (RA, dec), for J2000.0!!! | |
| subroutine | geoc2topoc_ecl (gcl, gcb, gcr, gcs, eps, lst, tcl, tcb, tcs, lat, hgt) |
| Convert spherical ecliptical coordinates from the geocentric to the topocentric system. | |
| subroutine | geoc2topoc_eq (gcra, gcd, gcr, gch, tcra, tcd, lat, hgt) |
| Convert geocentric equatorial coordinates to topocentric. | |
| real(double) function | refract (alt, press, temp) |
| Compute the atmospheric refraction for a given true altitude. You should add the result to the uncorrected altitude in order to obtain the observed altitude. Return 0 if alt + refract < -0.3°. | |
| real function | refract_sp (alt, press, temp) |
| Compute the atmospheric refraction for a given true altitude, using single-precision values. This is a wrapper for refract(). | |
| real(double) function | atmospheric_refraction (alt0, h0, lat0, t0, p0, rh, lam, dtdh, eps) |
| Compute the atmospheric refraction of light for a given true altitude. Return 0 for alt<-0.9°. This is a wrapper for aref(), which does the opposite (compute refraction for an apparent zenith angle). This is an expensive way to go about(!) | |
| real(double) function | atmospheric_refraction_apparent (alt0, h0, ph, t0, p0, rh, lam, dtdh, eps) |
| Compute the atmospheric refraction of light for a given apparent (observed) altitude of a celestial object and a given observer. Note that you will usually want to use the true altitude as input instead. The method is based on N.A.O Technical Notes 59 and 63 and a paper by Standish and Auer 'Astronomical Refraction: Computational Method for all Zenith Angles'. Return 0 if alt<-1.102°. | |
| real(double) function | aref (z0, h0, ph, t0, p0, rh, lam, dtdh, eps) |
| Compute the atmospheric refraction of light for a given apparent (observed) zenith angle. The method is based on N.A.O Technical Notes 59 and 63 and a paper by Standish and Auer 'Astronomical Refraction: Computational Method for all Zenith Angles'. Return 0 if z0>91.102°. | |
| real(double) function | refi (r, n, dndr) |
| The refraction integrand for atmospheric_refraction_apparent() | |
| subroutine | troposphere_model (r0, t0, a, r, t, n, dndr) |
| Troposphere model for atmospheric_refraction_apparent() | |
| subroutine | stratosphere_model (rt, tt, nt, a, r, n, dndr) |
| Stratosphere model for atmospheric_refraction_apparent() | |
Procedures for coordinates.
| subroutine thesky_coordinates::aberration_ecl | ( | real(double), intent(in) | t, |
| real(double), intent(in) | l0, | ||
| real(double), intent(inout) | l, | ||
| real(double), intent(inout) | b ) |
Correct ecliptic longitude and latitiude for annual aberration.
| t | Dynamical time in Julian Millennia since 2000.0 |
| l0 | Earth longitude (rad) |
| l | Longitude of the object (rad, I/O) (output) |
| b | Latitude of the object (rad, I/O) (output) |
Definition at line 426 of file coordinates.f90.
Referenced by thesky_planets::planet_position().
| subroutine thesky_coordinates::aberration_eq | ( | real(double), intent(in) | jd, |
| real(double), intent(in) | ra, | ||
| real(double), intent(in) | dec, | ||
| real(double), intent(out) | dra, | ||
| real(double), intent(out) | ddec, | ||
| real(double), intent(in), optional | eps0 ) |
Correct equatorial coordinates for annual aberration - moderate accuracy, use for stars.
| jd | Julian day of epoch |
| ra | Right ascension of the object (rad) |
| dec | Declination of the object (rad) |
| dra | Correction in right ascension due to aberration (rad) (output) |
| ddec | Correction in declination due to aberration(rad) (output) |
| eps0 | The mean obliquity of the ecliptic |
Definition at line 470 of file coordinates.f90.
References thesky_nutation::nutation().
Referenced by thesky_stars::calcstars().

| real(double) function thesky_coordinates::aref | ( | real(double), intent(in) | z0, |
| real(double), intent(in) | h0, | ||
| real(double), intent(in) | ph, | ||
| real(double), intent(in) | t0, | ||
| real(double), intent(in) | p0, | ||
| real(double), intent(in) | rh, | ||
| real(double), intent(in) | lam, | ||
| real(double), intent(in) | dtdh, | ||
| real(double), intent(in) | eps ) |
Compute the atmospheric refraction of light for a given apparent (observed) zenith angle. The method is based on N.A.O Technical Notes 59 and 63 and a paper by Standish and Auer 'Astronomical Refraction: Computational Method for all Zenith Angles'. Return 0 if z0>91.102°.
| z0 | The observed zenith distance of the object in degrees(!) |
| h0 | The height of the observer above sea level in metres |
| ph | The latitude of the observer in degrees(!) |
| t0 | The temperature at the observer in Kelvin |
| p0 | The pressure at the observer in millibars |
| rh | The relative humidity at the observer as a fraction (0-1) |
| lam | The wavelength of the light at the observer in micrometres |
| dTdh | The temperature lapse rate dT/dh in Kelvin/metre in the troposphere; the absolute value is used |
| eps | The desired precision in arcseconds(!) |
| aref | The refraction at the observer in degrees(!) |
Definition at line 1277 of file coordinates.f90.
References aref(), and atmospheric_refraction_apparent().
Referenced by aref(), and atmospheric_refraction().

| real(double) function thesky_coordinates::atmospheric_refraction | ( | real(double), intent(in) | alt0, |
| real(double), intent(in) | h0, | ||
| real(double), intent(in) | lat0, | ||
| real(double), intent(in) | t0, | ||
| real(double), intent(in) | p0, | ||
| real(double), intent(in) | rh, | ||
| real(double), intent(in) | lam, | ||
| real(double), intent(in) | dtdh, | ||
| real(double), intent(in) | eps ) |
Compute the atmospheric refraction of light for a given true altitude. Return 0 for alt<-0.9°. This is a wrapper for aref(), which does the opposite (compute refraction for an apparent zenith angle). This is an expensive way to go about(!)
| alt0 | The true (theoretical, computed) altitude of the object in radians |
| h0 | The height of the observer above sea level in metres |
| lat0 | The latitude of the observer in radians |
| t0 | The temperature at the observer in degrees Celsius (e.g. 10) |
| p0 | The pressure at the observer in millibars (e.g. 1010) |
| rh | The relative humidity at the observer in percent (e.g. 50) |
| lam | The wavelength of the light at the observer in nanometres (e.g. 550) |
| dTdh | The temperature lapse rate dT/dh in Kelvin/metre in the troposphere (only the absolute value is used; e.g. 0.0065) |
| eps | The desired precision in arcseconds (e.g. 1.d-3) |
| atmospheric_refraction | The refraction at the observer in radians |
Definition at line 1003 of file coordinates.f90.
References aref(), and atmospheric_refraction().
Referenced by atmospheric_refraction().

| real(double) function thesky_coordinates::atmospheric_refraction_apparent | ( | real(double), intent(in) | alt0, |
| real(double), intent(in) | h0, | ||
| real(double), intent(in) | ph, | ||
| real(double), intent(in), optional | t0, | ||
| real(double), intent(in), optional | p0, | ||
| real(double), intent(in), optional | rh, | ||
| real(double), intent(in), optional | lam, | ||
| real(double), intent(in), optional | dtdh, | ||
| real(double), intent(in), optional | eps ) |
Compute the atmospheric refraction of light for a given apparent (observed) altitude of a celestial object and a given observer. Note that you will usually want to use the true altitude as input instead. The method is based on N.A.O Technical Notes 59 and 63 and a paper by Standish and Auer 'Astronomical Refraction: Computational Method for all Zenith Angles'. Return 0 if alt<-1.102°.
| alt0 | The observed (apparent) altitude of the object (rad). |
| h0 | The height of the observer above sea level (metres). |
| ph | The latitude of the observer (rad). |
| t0 | The temperature at the observer's site; optional, default 10 (°C). |
| p0 | The air pressure at the observer's site; optional, default: 1010 (mbar). |
| rh | The relative humidity at the observer's site; optional, default: 0.5 (fraction: 0-1). |
| lam | The wavelength of the light; optional, default: 550 (nm). |
| dTdh | The temperature gradient dT/dh in the troposphere; the absolute value is used; optional, default: 6.5e-3 (Kelvin/metre). |
| eps | The desired precision; optional, default: 1e-4; don't make this smaller than ~1e-8 (rad). |
| atmospheric_refraction_apparent | The refraction at the observer (rad). |
Definition at line 1064 of file coordinates.f90.
References atmospheric_refraction_apparent(), refi(), stratosphere_model(), and troposphere_model().
Referenced by aref(), and atmospheric_refraction_apparent().

| subroutine thesky_coordinates::calcsunxyz | ( | real(double), intent(in) | t1, |
| real(double), intent(in) | l0, | ||
| real(double), intent(in) | b0, | ||
| real(double), intent(in) | r0, | ||
| real(double), intent(out) | x, | ||
| real(double), intent(out) | y, | ||
| real(double), intent(out) | z ) |
Compute the geocentric equatorial rectangular coordinates of the Sun, from Earth's heliocentric, spherical position.
| t1 | Dynamical time in Julian Millennia after 2000.0 |
| l0 | Heliocentric longitude of Earth |
| b0 | Heliocentric latitude of Earth |
| r0 | Heliocentric distance of Earth |
| x | Geocentric rectangular X of planet (output) |
| y | Geocentric rectangular Y of planet (output) |
| z | Geocentric rectangular Z of planet (output) |
Definition at line 103 of file coordinates.f90.
References fk5(), and thesky_nutation::nutation().
Referenced by thesky_asteroids::asteroid_eq().

| subroutine thesky_coordinates::ecl_2_eq | ( | real(double), intent(in) | l, |
| real(double), intent(in) | b, | ||
| real(double), intent(in) | eps, | ||
| real(double), intent(out) | ra, | ||
| real(double), intent(out) | dec ) |
Convert (geocentric) spherical ecliptical coordinates l,b (and eps) to spherical equatorial coordinates RA, Dec.
| l | Longitude (rad) |
| b | Latitude (rad) |
| eps | Obliquity of the ecliptic |
| ra | Right ascension (rad) (output) |
| dec | Declination (rad) (output) |
Definition at line 571 of file coordinates.f90.
Referenced by thesky_visibility::comet_invisible(), thesky_planets::jupiterphys(), thesky_moon::moonpos_la(), thesky_planets::planet_position(), and thesky_planets::saturnphys().
| subroutine thesky_coordinates::ecl_spher_2_eq_rect | ( | real(double), intent(in) | l, |
| real(double), intent(in) | b, | ||
| real(double), intent(in) | r, | ||
| real(double), intent(in) | eps, | ||
| real(double), intent(out) | x, | ||
| real(double), intent(out) | y, | ||
| real(double), intent(out) | z ) |
Convert spherical, ecliptical coordinates to rectangular, equatorial coordinates of an object - both geocentric.
| l | Heliocentric longitude of planet |
| b | Heliocentric latitude of planet |
| r | Heliocentric distance of planet |
| eps | Obliquity of the ecliptic |
| x | Geocentric rectangular X of planet (output) |
| y | Geocentric rectangular Y of planet (output) |
| z | Geocentric rectangular Z of planet (output) |
Definition at line 73 of file coordinates.f90.
Referenced by thesky_comets::cometgc().
| subroutine thesky_coordinates::eq2gal | ( | real(double), intent(in) | ra, |
| real(double), intent(in) | dec, | ||
| real(double), intent(out) | l, | ||
| real(double), intent(out) | b ) |
Convert spherical equatorial coordinates (RA, dec) to spherical galactic coordinates (l,b), for J2000.0!!!
| ra | Right ascension |
| dec | Declination |
| l | Longitude (output) |
| b | Latitude (output) |
Definition at line 724 of file coordinates.f90.
| subroutine thesky_coordinates::eq2horiz | ( | real(double), intent(in) | ra, |
| real(double), intent(in) | dec, | ||
| real(double), intent(in) | agst, | ||
| real(double), intent(out) | hh, | ||
| real(double), intent(out) | az, | ||
| real(double), intent(out) | alt, | ||
| real(double), intent(in), optional | lat, | ||
| real(double), intent(in), optional | lon ) |
Convert spherical equatorial coordinates (RA, dec, agst) to spherical horizontal coordinates (hh, az, alt)
| ra | Right ascension |
| dec | Declination |
| agst | Greenwich sidereal time |
| hh | Local hour angle (output) |
| az | Azimuth (output) |
| alt | Altitude (output) |
| lat | Geographical latitude (rad), optional |
| lon | Geographical longitude (rad), optional |
Definition at line 629 of file coordinates.f90.
References thesky_local::lat0, and thesky_local::lon0.
Referenced by thesky_moon::moonpos_la(), thesky_planets::planet_position(), thesky_planets::planet_position_la(), and thesky_sun::sunpos_la().
| subroutine thesky_coordinates::eq_2_ecl | ( | real(double), intent(in) | ra, |
| real(double), intent(in) | dec, | ||
| real(double), intent(in) | eps, | ||
| real(double), intent(out) | l, | ||
| real(double), intent(out) | b ) |
Convert (geocentric) spherical equatorial coordinates RA, Dec (and eps) to spherical ecliptical coordinates l,b.
| ra | Right ascension (rad) |
| dec | Declination (rad) |
| eps | Obliquity of the ecliptic |
| l | Longitude (rad) (output) |
| b | Latitude (rad) (output) |
Definition at line 598 of file coordinates.f90.
Referenced by thesky_stars::calcstars(), thesky_comets::cometgc(), and thesky_planets::jupiterphys().
| subroutine thesky_coordinates::fk5 | ( | real(double), intent(in) | t, |
| real(double), intent(inout) | l, | ||
| real(double), intent(inout) | b ) |
Convert coordinates to the FK5 system.
| t | Dynamical time in Julian Millennia since 2000.0 |
| l | Longitude (rad, I/O) (output) |
| b | Latitude (rad, I/O) (output) |
Definition at line 538 of file coordinates.f90.
Referenced by calcsunxyz(), thesky_comets::cometgc(), and thesky_planets::planet_position().
| subroutine thesky_coordinates::gal2eq | ( | real(double), intent(in) | l, |
| real(double), intent(in) | b, | ||
| real(double), intent(out) | ra, | ||
| real(double), intent(out) | dec ) |
Convert spherical galactic coordinates (l,b) to spherical equatorial coordinates (RA, dec), for J2000.0!!!
| l | Longitude |
| b | Latitude |
| ra | Right ascension (output) |
| dec | Declination (output) |
Definition at line 753 of file coordinates.f90.
| subroutine thesky_coordinates::geoc2topoc_ecl | ( | real(double), intent(in) | gcl, |
| real(double), intent(in) | gcb, | ||
| real(double), intent(in) | gcr, | ||
| real(double), intent(in) | gcs, | ||
| real(double), intent(in) | eps, | ||
| real(double), intent(in) | lst, | ||
| real(double), intent(out) | tcl, | ||
| real(double), intent(out) | tcb, | ||
| real(double), intent(out) | tcs, | ||
| real(double), intent(in), optional | lat, | ||
| real(double), intent(in), optional | hgt ) |
Convert spherical ecliptical coordinates from the geocentric to the topocentric system.
| gcl | Geocentric ecliptic longitude of the object (rad) |
| gcb | Geocentric ecliptic latitude of the object (rad) |
| gcr | Geocentric distance of the object |
| gcs | Geocentric semi-diameter of the object (rad) |
| eps | Obliquity of the ecliptic (rad) |
| lst | Local sidereal time (rad) |
| tcl | Topocentric ecliptic longitude of the object (rad) (output) |
| tcb | Topocentric ecliptic latitude of the object (rad) (output) |
| tcs | Topocentric semi-diameter of the object (rad) (output) |
| lat | Latitude of the observer (rad, optional) |
| hgt | Altitude/elevation of the observer above sea level (metres, optional) |
Definition at line 797 of file coordinates.f90.
References thesky_local::height, and thesky_local::lat0.
Referenced by thesky_planets::planet_position(), and thesky_planets::planet_position_la().
| subroutine thesky_coordinates::geoc2topoc_eq | ( | real(double), intent(in) | gcra, |
| real(double), intent(in) | gcd, | ||
| real(double), intent(in) | gcr, | ||
| real(double), intent(in) | gch, | ||
| real(double), intent(out) | tcra, | ||
| real(double), intent(out) | tcd, | ||
| real(double), intent(in), optional | lat, | ||
| real(double), intent(in), optional | hgt ) |
Convert geocentric equatorial coordinates to topocentric.
| gcra | Geocentric right ascension |
| gcd | Geocentric declination |
| gcr | Geocentric distance |
| gch | Geocentric hour angle |
| tcra | Topocentric right ascension (output) |
| tcd | Topocentric declination (output) |
| lat | Latitude of the observer (rad, optional) |
| hgt | Altitude/elevation of the observer above sea level (metres, optional) |
Definition at line 858 of file coordinates.f90.
References thesky_local::height, and thesky_local::lat0.
Referenced by thesky_planets::planet_position_la().
| subroutine thesky_coordinates::hc_spher_2_gc_rect | ( | real(double), intent(in) | l, |
| real(double), intent(in) | b, | ||
| real(double), intent(in) | r, | ||
| real(double), intent(in) | l0, | ||
| real(double), intent(in) | b0, | ||
| real(double), intent(in) | r0, | ||
| real(double), intent(out) | x, | ||
| real(double), intent(out) | y, | ||
| real(double), intent(out) | z ) |
Compute the geocentric rectangular coordinates of a planet, from its and the Earth's heliocentric spherical position.
| l | Heliocentric longitude of planet |
| b | Heliocentric latitude of planet |
| r | Heliocentric distance of planet |
| l0 | Heliocentric longitude of Earth |
| b0 | Heliocentric latitude of Earth |
| r0 | Heliocentric distance of Earth |
| x | Geocentric rectangular X of planet (output) |
| y | Geocentric rectangular Y of planet (output) |
| z | Geocentric rectangular Z of planet (output) |
Definition at line 46 of file coordinates.f90.
Referenced by thesky_planets::planet_position(), and thesky_planets::saturnphys().
| subroutine thesky_coordinates::horiz2eq | ( | real(double), intent(in) | az, |
| real(double), intent(in) | alt, | ||
| real(double), intent(in) | agst, | ||
| real(double), intent(out) | hh, | ||
| real(double), intent(out) | ra, | ||
| real(double), intent(out) | dec, | ||
| real(double), intent(in), optional | lat, | ||
| real(double), intent(in), optional | lon ) |
Convert spherical horizontal coordinates (az, alt, agst) to spherical equatorial coordinates (hh, RA, dec)
| az | Azimuth |
| alt | Altitude |
| agst | Greenwich sidereal time |
| hh | Local hour angle (output) |
| ra | Right ascension (output) |
| dec | Declination (output) |
| lat | Geographical latitude (rad), optional |
| lon | Geographical longitude (rad), optional |
Definition at line 680 of file coordinates.f90.
References thesky_local::lat0, and thesky_local::lon0.
Referenced by thesky_visibility::limmag_zenith_jd().
| subroutine thesky_coordinates::precess_ecl | ( | real(double), intent(in) | jd1, |
| real(double), intent(in) | jd2, | ||
| real(double), intent(inout) | l, | ||
| real(double), intent(inout) | b ) |
Compute the precession of the equinoxes in geocentric ecliptical coordinates.
| jd1 | Original Julian day |
| jd2 | Target Julian day |
| l | Ecliptic longitude (I/O, rad) (output) |
| b | Ecliptic latitude (I/O, rad) (output) |
Definition at line 295 of file coordinates.f90.
Referenced by thesky_moon::elp_mpp02_lbr(), thesky_moonroutines::moonphys(), and thesky_planets::planet_position().
| subroutine thesky_coordinates::precess_eq | ( | real(double), intent(in) | jd1, |
| real(double), intent(in) | jd2, | ||
| real(double), intent(inout) | a1, | ||
| real(double), intent(inout) | d1 ) |
Compute the precession of the equinoxes in equatorial coordinates, from jd1 to jd2.
| jd1 | Original Julian day |
| jd2 | Target Julian day |
| a1 | Right ascension (IO, rad) (output) |
| d1 | Declination (IO, rad) (output) |
Definition at line 210 of file coordinates.f90.
Referenced by thesky_stars::calcstars(), thesky_functions::const_id(), and thesky_moonroutines::moonphys().
| subroutine thesky_coordinates::precess_eq_yr | ( | real(double), intent(in) | yr1, |
| real(double), intent(in) | yr2, | ||
| real(double), intent(inout) | a1, | ||
| real(double), intent(inout) | d1 ) |
Compute the precession of the equinoxes in equatorial coordinates, from yr1 to yr2.
| yr1 | Original year |
| yr2 | Target year |
| a1 | Right ascension (IO, rad) (output) |
| d1 | Declination (IO, rad) (output) |
Definition at line 253 of file coordinates.f90.
| subroutine thesky_coordinates::precess_orb | ( | real(double), intent(in) | jd1, |
| real(double), intent(in) | jd2, | ||
| real(double), intent(inout) | i, | ||
| real(double), intent(inout) | o1, | ||
| real(double), intent(inout) | o2 ) |
Compute the precession of the equinoxes in orbital elements.
| jd1 | Original Julian day |
| jd2 | Target Julian day |
| i | Inclination (output) |
| o1 | Argument of perihelion (output) |
| o2 | Longitude of ascending node (output) |
Definition at line 341 of file coordinates.f90.
Referenced by thesky_asteroids::asteroid_elements().
| subroutine thesky_coordinates::precess_xyz | ( | real(double), intent(in) | jd1, |
| real(double), intent(in) | jd2, | ||
| real(double), intent(inout) | x, | ||
| real(double), intent(inout) | y, | ||
| real(double), intent(inout) | z ) |
Compute the precession of the equinoxes in rectangular coordinates, from jd1 to jd2.
| jd1 | Original Julian day |
| jd2 | Target Julian day |
| x | Geocentric rectangular X (output) |
| y | Geocentric rectangular Y (output) |
| z | Geocentric rectangular Z (output) |
Definition at line 148 of file coordinates.f90.
Referenced by thesky_comets::cometgc().
| subroutine thesky_coordinates::rect_2_spher | ( | real(double), intent(in) | x, |
| real(double), intent(in) | y, | ||
| real(double), intent(in) | z, | ||
| real(double), intent(out) | l, | ||
| real(double), intent(out) | b, | ||
| real(double), intent(out) | r ) |
Convert rectangular coordinates x,y,z to spherical coordinates l,b,r.
| x | Rectangular x coordinate (same unit as r) |
| y | Rectangular y coordinate (same unit as r) |
| z | Rectangular z coordinate (same unit as r) |
| l | Longitude (rad) (output) |
| b | Latitude (rad) (output) |
| r | Distance (same unit as x,y,z) (output) |
Definition at line 388 of file coordinates.f90.
Referenced by thesky_planets::planet_position(), and thesky_planets::saturnphys().
| real(double) function thesky_coordinates::refi | ( | real(double), intent(in) | r, |
| real(double), intent(in) | n, | ||
| real(double), intent(in) | dndr ) |
The refraction integrand for atmospheric_refraction_apparent()
| r | The current distance from the centre of the Earth in metres |
| n | The refractive index at R |
| dndr | The rate the refractive index is changing at R |
| refi | The integrand of the refraction function |
Definition at line 1302 of file coordinates.f90.
References refi().
Referenced by atmospheric_refraction_apparent(), and refi().

| real(double) function thesky_coordinates::refract | ( | real(double), intent(in) | alt, |
| real(double), intent(in), optional | press, | ||
| real(double), intent(in), optional | temp ) |
Compute the atmospheric refraction for a given true altitude. You should add the result to the uncorrected altitude in order to obtain the observed altitude. Return 0 if alt + refract < -0.3°.
| alt | True (computed) altitude (rad) |
| press | Air pressure (hPa; optional) |
| temp | Air temperature (degrees Celsius; optional) |
| refract | Refraction in altitude (rad). You should add the result to the uncorrected altitude. |
Definition at line 910 of file coordinates.f90.
References refract().
Referenced by thesky_planets::planet_position(), thesky_planets::planet_position_la(), refract(), refract_sp(), thesky_riset::riset(), thesky_riset::riset_ipol(), and thesky_sun::sunpos_la().

| real function thesky_coordinates::refract_sp | ( | real, intent(in) | alt, |
| real, intent(in), optional | press, | ||
| real, intent(in), optional | temp ) |
Compute the atmospheric refraction for a given true altitude, using single-precision values. This is a wrapper for refract().
| alt | True (computed) altitude (rad) |
| press | Air pressure (hPa; optional) |
| temp | Air temperature (degrees Celsius; optional) |
| refract | Refraction in altitude (rad). You should add the result to the uncorrected altitude. |
Definition at line 951 of file coordinates.f90.
References refract(), and refract_sp().
Referenced by refract_sp().

| subroutine thesky_coordinates::stratosphere_model | ( | real(double), intent(in) | rt, |
| real(double), intent(in) | tt, | ||
| real(double), intent(in) | nt, | ||
| real(double), intent(in) | a, | ||
| real(double), intent(in) | r, | ||
| real(double), intent(out) | n, | ||
| real(double), intent(out) | dndr ) |
Stratosphere model for atmospheric_refraction_apparent()
| rt | The height of the tropopause from the centre of the Earth in metres |
| tt | The temperature at the tropopause in Kelvin |
| nt | The refractive index at the tropopause |
| a | Constant of the atmospheric model = G*MD/R |
| r | The current distance from the centre of the Earth in metres |
| n | The refractive index at R (output) |
| dndr | The rate the refractive index is changing at R (output) |
Definition at line 1356 of file coordinates.f90.
Referenced by atmospheric_refraction_apparent().
| subroutine thesky_coordinates::troposphere_model | ( | real(double), intent(in) | r0, |
| real(double), intent(in) | t0, | ||
| real(double), dimension(10), intent(in) | a, | ||
| real(double), intent(in) | r, | ||
| real(double), intent(out) | t, | ||
| real(double), intent(out) | n, | ||
| real(double), intent(out) | dndr ) |
Troposphere model for atmospheric_refraction_apparent()
| r0 | The height of the observer from the centre of the Earth |
| t0 | The temperature at the observer in Kelvin |
| a | Constants defined at the observer |
| r | The current distance from the centre of the Earth in metres |
| t | The temperature at R in Kelvin (output) |
| n | The refractive index at R (output) |
| dndr | The rate the refractive index is changing at R (output) |
Definition at line 1325 of file coordinates.f90.
Referenced by atmospheric_refraction_apparent().