From d54fe7c1f704a63824c5bfa0ece65245572e9b27 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Wed, 4 Mar 2015 21:21:30 -0500 Subject: Initial commit --- src/slalib/Makefile.am | 187 + src/slalib/Makefile.in | 830 ++ src/slalib/addet.f | 67 + src/slalib/afin.f | 102 + src/slalib/airmas.f | 58 + src/slalib/altaz.f | 145 + src/slalib/amp.f | 68 + src/slalib/ampqk.f | 127 + src/slalib/aop.f | 174 + src/slalib/aoppa.f | 176 + src/slalib/aoppat.f | 45 + src/slalib/aopqk.f | 242 + src/slalib/atmdsp.f | 121 + src/slalib/atms.f | 40 + src/slalib/atmt.f | 54 + src/slalib/av2m.f | 68 + src/slalib/bear.f | 42 + src/slalib/caf2r.f | 57 + src/slalib/caldj.f | 57 + src/slalib/calyd.f | 65 + src/slalib/cc2s.f | 53 + src/slalib/cc62s.f | 82 + src/slalib/cd2tf.f | 55 + src/slalib/cldj.f | 78 + src/slalib/clyd.f | 101 + src/slalib/combn.f | 142 + src/slalib/cr2af.f | 58 + src/slalib/cr2tf.f | 58 + src/slalib/create.com | 140 + src/slalib/cs2c.f | 41 + src/slalib/cs2c6.f | 56 + src/slalib/ctf2d.f | 56 + src/slalib/ctf2r.f | 54 + src/slalib/daf2r.f | 55 + src/slalib/dafin.f | 163 + src/slalib/dat.f | 219 + src/slalib/dav2m.f | 67 + src/slalib/dbear.f | 42 + src/slalib/dbjin.f | 113 + src/slalib/dc62s.f | 82 + src/slalib/dcc2s.f | 53 + src/slalib/dcmpf.f | 140 + src/slalib/dcs2c.f | 41 + src/slalib/dd2tf.f | 89 + src/slalib/de2h.f | 89 + src/slalib/deuler.f | 163 + src/slalib/dfltin.f | 280 + src/slalib/dh2e.f | 83 + src/slalib/dimxv.f | 51 + src/slalib/djcal.f | 77 + src/slalib/djcl.f | 68 + src/slalib/dm2av.f | 59 + src/slalib/dmat.f | 140 + src/slalib/dmoon.f | 641 ++ src/slalib/dmxm.f | 56 + src/slalib/dmxv.f | 47 + src/slalib/dpav.f | 72 + src/slalib/dr2af.f | 58 + src/slalib/dr2tf.f | 58 + src/slalib/drange.f | 32 + src/slalib/dranrm.f | 31 + src/slalib/ds2c6.f | 57 + src/slalib/ds2tp.f | 67 + src/slalib/dsep.f | 48 + src/slalib/dt.f | 79 + src/slalib/dtf2d.f | 55 + src/slalib/dtf2r.f | 53 + src/slalib/dtp2s.f | 42 + src/slalib/dtp2v.f | 56 + src/slalib/dtps2c.f | 91 + src/slalib/dtpv2c.f | 83 + src/slalib/dtt.f | 46 + src/slalib/dv2tp.f | 78 + src/slalib/dvdv.f | 27 + src/slalib/dvn.f | 46 + src/slalib/dvxv.f | 39 + src/slalib/e2h.f | 89 + src/slalib/earth.f | 111 + src/slalib/ecleq.f | 55 + src/slalib/ecmat.f | 52 + src/slalib/ecor.f | 78 + src/slalib/eg50.f | 90 + src/slalib/el2ue.f | 301 + src/slalib/epb.f | 30 + src/slalib/epb2d.f | 30 + src/slalib/epco.f | 51 + src/slalib/epj.f | 29 + src/slalib/epj2d.f | 29 + src/slalib/eqecl.f | 55 + src/slalib/eqeqx.f | 57 + src/slalib/eqgal.f | 79 + src/slalib/etrms.f | 62 + src/slalib/euler.f | 68 + src/slalib/evp.f | 441 + src/slalib/fitxy.f | 300 + src/slalib/fk425.f | 249 + src/slalib/fk45z.f | 165 + src/slalib/fk524.f | 257 + src/slalib/fk52h.f | 105 + src/slalib/fk54z.f | 69 + src/slalib/fk5hz.f | 107 + src/slalib/flotin.f | 128 + src/slalib/galeq.f | 79 + src/slalib/galsup.f | 79 + src/slalib/ge50.f | 90 + src/slalib/geoc.f | 57 + src/slalib/gmst.f | 60 + src/slalib/gmsta.f | 80 + src/slalib/gresid.f_alpha_OSF1 | 76 + src/slalib/gresid.f_convex | 80 + src/slalib/gresid.f_ix86_Linux | 74 + src/slalib/gresid.f_mips | 74 + src/slalib/gresid.f_pcm | 73 + src/slalib/gresid.f_sun4 | 80 + src/slalib/gresid.f_sun4_Solaris | 80 + src/slalib/gresid.f_vax | 72 + src/slalib/gresid.f_x86_64 | 74 + src/slalib/h2e.f | 83 + src/slalib/h2fk5.f | 109 + src/slalib/hfk5z.f | 122 + src/slalib/idchf.f | 94 + src/slalib/idchi.f | 91 + src/slalib/imxv.f | 51 + src/slalib/intin.f | 176 + src/slalib/invf.f | 90 + src/slalib/kbj.f | 56 + src/slalib/m2av.f | 59 + src/slalib/makefile.orig | 1426 +++ src/slalib/map.f | 75 + src/slalib/mappa.f | 107 + src/slalib/mapqk.f | 143 + src/slalib/mapqkz.f | 113 + src/slalib/mk | 437 + src/slalib/mk.sv | 437 + src/slalib/moon.f | 362 + src/slalib/mxm.f | 55 + src/slalib/mxv.f | 47 + src/slalib/nut.f | 44 + src/slalib/nutc.f | 442 + src/slalib/oap.f | 172 + src/slalib/oapqk.f | 233 + src/slalib/obs.f | 844 ++ src/slalib/pa.f | 46 + src/slalib/pav.f | 53 + src/slalib/pc.bat | 75 + src/slalib/pcd.f | 59 + src/slalib/pda2h.f | 100 + src/slalib/pdq2h.f | 98 + src/slalib/permut.f | 141 + src/slalib/pertel.f | 159 + src/slalib/pertue.f | 535 + src/slalib/planel.f | 117 + src/slalib/planet.f | 707 ++ src/slalib/plante.f | 157 + src/slalib/pm.f | 74 + src/slalib/polmo.f | 133 + src/slalib/prebn.f | 62 + src/slalib/prec.f | 79 + src/slalib/preces.f | 84 + src/slalib/precl.f | 125 + src/slalib/prenut.f | 48 + src/slalib/put.com | 38 + src/slalib/pv2el.f | 351 + src/slalib/pv2ue.f | 150 + src/slalib/pvobs.f | 59 + src/slalib/pxy.f | 92 + src/slalib/random.f_alpha_OSF1 | 56 + src/slalib/random.f_convex | 56 + src/slalib/random.f_ix86_Linux | 54 + src/slalib/random.f_mips | 54 + src/slalib/random.f_pcm | 42 + src/slalib/random.f_sun4 | 56 + src/slalib/random.f_sun4_Solaris | 56 + src/slalib/random.f_vax | 52 + src/slalib/random.f_x86_64 | 54 + src/slalib/range.f | 33 + src/slalib/ranorm.f | 31 + src/slalib/rcc.f | 1063 ++ src/slalib/rdplan.f | 183 + src/slalib/read.me | 441 + src/slalib/refco.f | 70 + src/slalib/refcoq.f | 208 + src/slalib/refro.f | 374 + src/slalib/refv.f | 106 + src/slalib/refz.f | 139 + src/slalib/rep.bat | 21 + src/slalib/rtl_random.c | 33 + src/slalib/rverot.f | 48 + src/slalib/rvgalc.f | 69 + src/slalib/rvlg.f | 64 + src/slalib/rvlsrd.f | 78 + src/slalib/rvlsrk.f | 77 + src/slalib/s2tp.f | 67 + src/slalib/sep.f | 48 + src/slalib/sla.news | 40 + src/slalib/sla_link | 1 + src/slalib/sla_link_adam | 1 + src/slalib/sla_test.f | 28 + src/slalib/smat.f | 141 + src/slalib/subet.f | 66 + src/slalib/sun67.htx/blueball.gif | Bin 0 -> 398 bytes src/slalib/sun67.htx/change_begin.gif | Bin 0 -> 133 bytes src/slalib/sun67.htx/change_begin_right.gif | Bin 0 -> 128 bytes src/slalib/sun67.htx/change_delete.gif | Bin 0 -> 257 bytes src/slalib/sun67.htx/change_delete_right.gif | Bin 0 -> 257 bytes src/slalib/sun67.htx/change_end.gif | Bin 0 -> 135 bytes src/slalib/sun67.htx/change_end_right.gif | Bin 0 -> 127 bytes src/slalib/sun67.htx/contents.xbm | 12 + src/slalib/sun67.htx/contents_motif.gif | Bin 0 -> 225 bytes src/slalib/sun67.htx/cross_ref_motif.gif | Bin 0 -> 78 bytes src/slalib/sun67.htx/foot_motif.gif | Bin 0 -> 87 bytes src/slalib/sun67.htx/footnode.html | 224 + src/slalib/sun67.htx/greenball.gif | Bin 0 -> 398 bytes src/slalib/sun67.htx/icons.html | 42 + src/slalib/sun67.htx/image.gif | Bin 0 -> 195 bytes src/slalib/sun67.htx/images.aux | 1 + src/slalib/sun67.htx/images.log | 1727 +++ src/slalib/sun67.htx/images.pl | 1686 +++ src/slalib/sun67.htx/images.tex | 2852 +++++ src/slalib/sun67.htx/img1.gif | Bin 0 -> 164 bytes src/slalib/sun67.htx/img10.gif | Bin 0 -> 129 bytes src/slalib/sun67.htx/img100.gif | Bin 0 -> 144 bytes src/slalib/sun67.htx/img101.gif | Bin 0 -> 137 bytes src/slalib/sun67.htx/img102.gif | Bin 0 -> 168 bytes src/slalib/sun67.htx/img103.gif | Bin 0 -> 173 bytes src/slalib/sun67.htx/img104.gif | Bin 0 -> 255 bytes src/slalib/sun67.htx/img105.gif | Bin 0 -> 160 bytes src/slalib/sun67.htx/img106.gif | Bin 0 -> 416 bytes src/slalib/sun67.htx/img107.gif | Bin 0 -> 454 bytes src/slalib/sun67.htx/img108.gif | Bin 0 -> 367 bytes src/slalib/sun67.htx/img109.gif | Bin 0 -> 507 bytes src/slalib/sun67.htx/img11.gif | Bin 0 -> 939 bytes src/slalib/sun67.htx/img110.gif | Bin 0 -> 470 bytes src/slalib/sun67.htx/img111.gif | Bin 0 -> 370 bytes src/slalib/sun67.htx/img112.gif | Bin 0 -> 260 bytes src/slalib/sun67.htx/img113.gif | Bin 0 -> 362 bytes src/slalib/sun67.htx/img114.gif | Bin 0 -> 327 bytes src/slalib/sun67.htx/img115.gif | Bin 0 -> 144 bytes src/slalib/sun67.htx/img116.gif | Bin 0 -> 291 bytes src/slalib/sun67.htx/img117.gif | Bin 0 -> 186 bytes src/slalib/sun67.htx/img118.gif | Bin 0 -> 190 bytes src/slalib/sun67.htx/img119.gif | Bin 0 -> 406 bytes src/slalib/sun67.htx/img12.gif | Bin 0 -> 980 bytes src/slalib/sun67.htx/img120.gif | Bin 0 -> 415 bytes src/slalib/sun67.htx/img121.gif | Bin 0 -> 260 bytes src/slalib/sun67.htx/img122.gif | Bin 0 -> 177 bytes src/slalib/sun67.htx/img123.gif | Bin 0 -> 185 bytes src/slalib/sun67.htx/img124.gif | Bin 0 -> 252 bytes src/slalib/sun67.htx/img125.gif | Bin 0 -> 239 bytes src/slalib/sun67.htx/img126.gif | Bin 0 -> 229 bytes src/slalib/sun67.htx/img127.gif | Bin 0 -> 164 bytes src/slalib/sun67.htx/img128.gif | Bin 0 -> 467 bytes src/slalib/sun67.htx/img129.gif | Bin 0 -> 142 bytes src/slalib/sun67.htx/img13.gif | Bin 0 -> 319 bytes src/slalib/sun67.htx/img130.gif | Bin 0 -> 147 bytes src/slalib/sun67.htx/img131.gif | Bin 0 -> 155 bytes src/slalib/sun67.htx/img132.gif | Bin 0 -> 163 bytes src/slalib/sun67.htx/img133.gif | Bin 0 -> 226 bytes src/slalib/sun67.htx/img134.gif | Bin 0 -> 231 bytes src/slalib/sun67.htx/img135.gif | Bin 0 -> 242 bytes src/slalib/sun67.htx/img136.gif | Bin 0 -> 271 bytes src/slalib/sun67.htx/img137.gif | Bin 0 -> 210 bytes src/slalib/sun67.htx/img138.gif | Bin 0 -> 771 bytes src/slalib/sun67.htx/img139.gif | Bin 0 -> 242 bytes src/slalib/sun67.htx/img14.gif | Bin 0 -> 272 bytes src/slalib/sun67.htx/img140.gif | Bin 0 -> 133 bytes src/slalib/sun67.htx/img141.gif | Bin 0 -> 222 bytes src/slalib/sun67.htx/img142.gif | Bin 0 -> 251 bytes src/slalib/sun67.htx/img143.gif | Bin 0 -> 251 bytes src/slalib/sun67.htx/img144.gif | Bin 0 -> 349 bytes src/slalib/sun67.htx/img145.gif | Bin 0 -> 331 bytes src/slalib/sun67.htx/img146.gif | Bin 0 -> 146 bytes src/slalib/sun67.htx/img147.gif | Bin 0 -> 192 bytes src/slalib/sun67.htx/img148.gif | Bin 0 -> 688 bytes src/slalib/sun67.htx/img149.gif | Bin 0 -> 143 bytes src/slalib/sun67.htx/img15.gif | Bin 0 -> 277 bytes src/slalib/sun67.htx/img150.gif | Bin 0 -> 201 bytes src/slalib/sun67.htx/img151.gif | Bin 0 -> 252 bytes src/slalib/sun67.htx/img152.gif | Bin 0 -> 290 bytes src/slalib/sun67.htx/img153.gif | Bin 0 -> 246 bytes src/slalib/sun67.htx/img154.gif | Bin 0 -> 198 bytes src/slalib/sun67.htx/img155.gif | Bin 0 -> 261 bytes src/slalib/sun67.htx/img156.gif | Bin 0 -> 243 bytes src/slalib/sun67.htx/img157.gif | Bin 0 -> 334 bytes src/slalib/sun67.htx/img158.gif | Bin 0 -> 227 bytes src/slalib/sun67.htx/img159.gif | Bin 0 -> 326 bytes src/slalib/sun67.htx/img16.gif | Bin 0 -> 233 bytes src/slalib/sun67.htx/img160.gif | Bin 0 -> 312 bytes src/slalib/sun67.htx/img161.gif | Bin 0 -> 247 bytes src/slalib/sun67.htx/img162.gif | Bin 0 -> 203 bytes src/slalib/sun67.htx/img163.gif | Bin 0 -> 206 bytes src/slalib/sun67.htx/img164.gif | Bin 0 -> 198 bytes src/slalib/sun67.htx/img165.gif | Bin 0 -> 221 bytes src/slalib/sun67.htx/img166.gif | Bin 0 -> 263 bytes src/slalib/sun67.htx/img167.gif | Bin 0 -> 252 bytes src/slalib/sun67.htx/img168.gif | Bin 0 -> 256 bytes src/slalib/sun67.htx/img169.gif | Bin 0 -> 455 bytes src/slalib/sun67.htx/img17.gif | Bin 0 -> 409 bytes src/slalib/sun67.htx/img170.gif | Bin 0 -> 153 bytes src/slalib/sun67.htx/img171.gif | Bin 0 -> 217 bytes src/slalib/sun67.htx/img172.gif | Bin 0 -> 505 bytes src/slalib/sun67.htx/img173.gif | Bin 0 -> 160 bytes src/slalib/sun67.htx/img174.gif | Bin 0 -> 199 bytes src/slalib/sun67.htx/img175.gif | Bin 0 -> 243 bytes src/slalib/sun67.htx/img176.gif | Bin 0 -> 215 bytes src/slalib/sun67.htx/img177.gif | Bin 0 -> 247 bytes src/slalib/sun67.htx/img178.gif | Bin 0 -> 190 bytes src/slalib/sun67.htx/img179.gif | Bin 0 -> 215 bytes src/slalib/sun67.htx/img18.gif | Bin 0 -> 243 bytes src/slalib/sun67.htx/img180.gif | Bin 0 -> 385 bytes src/slalib/sun67.htx/img181.gif | Bin 0 -> 371 bytes src/slalib/sun67.htx/img182.gif | Bin 0 -> 205 bytes src/slalib/sun67.htx/img183.gif | Bin 0 -> 299 bytes src/slalib/sun67.htx/img184.gif | Bin 0 -> 219 bytes src/slalib/sun67.htx/img185.gif | Bin 0 -> 205 bytes src/slalib/sun67.htx/img186.gif | Bin 0 -> 191 bytes src/slalib/sun67.htx/img187.gif | Bin 0 -> 218 bytes src/slalib/sun67.htx/img188.gif | Bin 0 -> 209 bytes src/slalib/sun67.htx/img189.gif | Bin 0 -> 193 bytes src/slalib/sun67.htx/img19.gif | Bin 0 -> 140 bytes src/slalib/sun67.htx/img190.gif | Bin 0 -> 214 bytes src/slalib/sun67.htx/img191.gif | Bin 0 -> 206 bytes src/slalib/sun67.htx/img192.gif | Bin 0 -> 149 bytes src/slalib/sun67.htx/img193.gif | Bin 0 -> 209 bytes src/slalib/sun67.htx/img194.gif | Bin 0 -> 216 bytes src/slalib/sun67.htx/img195.gif | Bin 0 -> 249 bytes src/slalib/sun67.htx/img196.gif | Bin 0 -> 204 bytes src/slalib/sun67.htx/img197.gif | Bin 0 -> 229 bytes src/slalib/sun67.htx/img198.gif | Bin 0 -> 206 bytes src/slalib/sun67.htx/img199.gif | Bin 0 -> 248 bytes src/slalib/sun67.htx/img2.gif | Bin 0 -> 165 bytes src/slalib/sun67.htx/img20.gif | Bin 0 -> 288 bytes src/slalib/sun67.htx/img200.gif | Bin 0 -> 217 bytes src/slalib/sun67.htx/img201.gif | Bin 0 -> 254 bytes src/slalib/sun67.htx/img202.gif | Bin 0 -> 248 bytes src/slalib/sun67.htx/img203.gif | Bin 0 -> 191 bytes src/slalib/sun67.htx/img204.gif | Bin 0 -> 267 bytes src/slalib/sun67.htx/img205.gif | Bin 0 -> 209 bytes src/slalib/sun67.htx/img206.gif | Bin 0 -> 281 bytes src/slalib/sun67.htx/img207.gif | Bin 0 -> 304 bytes src/slalib/sun67.htx/img208.gif | Bin 0 -> 318 bytes src/slalib/sun67.htx/img209.gif | Bin 0 -> 315 bytes src/slalib/sun67.htx/img21.gif | Bin 0 -> 211 bytes src/slalib/sun67.htx/img210.gif | Bin 0 -> 2211 bytes src/slalib/sun67.htx/img211.gif | Bin 0 -> 493 bytes src/slalib/sun67.htx/img212.gif | Bin 0 -> 189 bytes src/slalib/sun67.htx/img213.gif | Bin 0 -> 207 bytes src/slalib/sun67.htx/img214.gif | Bin 0 -> 212 bytes src/slalib/sun67.htx/img215.gif | Bin 0 -> 215 bytes src/slalib/sun67.htx/img216.gif | Bin 0 -> 193 bytes src/slalib/sun67.htx/img217.gif | Bin 0 -> 233 bytes src/slalib/sun67.htx/img218.gif | Bin 0 -> 234 bytes src/slalib/sun67.htx/img219.gif | Bin 0 -> 257 bytes src/slalib/sun67.htx/img22.gif | Bin 0 -> 206 bytes src/slalib/sun67.htx/img220.gif | Bin 0 -> 262 bytes src/slalib/sun67.htx/img221.gif | Bin 0 -> 238 bytes src/slalib/sun67.htx/img222.gif | Bin 0 -> 327 bytes src/slalib/sun67.htx/img223.gif | Bin 0 -> 325 bytes src/slalib/sun67.htx/img224.gif | Bin 0 -> 704 bytes src/slalib/sun67.htx/img225.gif | Bin 0 -> 572 bytes src/slalib/sun67.htx/img226.gif | Bin 0 -> 192 bytes src/slalib/sun67.htx/img227.gif | Bin 0 -> 278 bytes src/slalib/sun67.htx/img228.gif | Bin 0 -> 258 bytes src/slalib/sun67.htx/img229.gif | Bin 0 -> 307 bytes src/slalib/sun67.htx/img23.gif | Bin 0 -> 138 bytes src/slalib/sun67.htx/img230.gif | Bin 0 -> 443 bytes src/slalib/sun67.htx/img231.gif | Bin 0 -> 248 bytes src/slalib/sun67.htx/img232.gif | Bin 0 -> 206 bytes src/slalib/sun67.htx/img233.gif | Bin 0 -> 197 bytes src/slalib/sun67.htx/img234.gif | Bin 0 -> 204 bytes src/slalib/sun67.htx/img235.gif | Bin 0 -> 193 bytes src/slalib/sun67.htx/img236.gif | Bin 0 -> 189 bytes src/slalib/sun67.htx/img237.gif | Bin 0 -> 563 bytes src/slalib/sun67.htx/img238.gif | Bin 0 -> 314 bytes src/slalib/sun67.htx/img239.gif | Bin 0 -> 507 bytes src/slalib/sun67.htx/img24.gif | Bin 0 -> 138 bytes src/slalib/sun67.htx/img240.gif | Bin 0 -> 143 bytes src/slalib/sun67.htx/img241.gif | Bin 0 -> 183 bytes src/slalib/sun67.htx/img242.gif | Bin 0 -> 212 bytes src/slalib/sun67.htx/img243.gif | Bin 0 -> 412 bytes src/slalib/sun67.htx/img244.gif | Bin 0 -> 414 bytes src/slalib/sun67.htx/img245.gif | Bin 0 -> 202 bytes src/slalib/sun67.htx/img246.gif | Bin 0 -> 461 bytes src/slalib/sun67.htx/img247.gif | Bin 0 -> 360 bytes src/slalib/sun67.htx/img248.gif | Bin 0 -> 353 bytes src/slalib/sun67.htx/img249.gif | Bin 0 -> 303 bytes src/slalib/sun67.htx/img25.gif | Bin 0 -> 187 bytes src/slalib/sun67.htx/img250.gif | Bin 0 -> 487 bytes src/slalib/sun67.htx/img251.gif | Bin 0 -> 91 bytes src/slalib/sun67.htx/img252.gif | Bin 0 -> 473 bytes src/slalib/sun67.htx/img253.gif | Bin 0 -> 233 bytes src/slalib/sun67.htx/img254.gif | Bin 0 -> 352 bytes src/slalib/sun67.htx/img255.gif | Bin 0 -> 9320 bytes src/slalib/sun67.htx/img256.gif | Bin 0 -> 253 bytes src/slalib/sun67.htx/img257.gif | Bin 0 -> 115 bytes src/slalib/sun67.htx/img258.gif | Bin 0 -> 286 bytes src/slalib/sun67.htx/img259.gif | Bin 0 -> 335 bytes src/slalib/sun67.htx/img26.gif | Bin 0 -> 312 bytes src/slalib/sun67.htx/img260.gif | Bin 0 -> 209 bytes src/slalib/sun67.htx/img261.gif | Bin 0 -> 255 bytes src/slalib/sun67.htx/img262.gif | Bin 0 -> 530 bytes src/slalib/sun67.htx/img263.gif | Bin 0 -> 489 bytes src/slalib/sun67.htx/img264.gif | Bin 0 -> 398 bytes src/slalib/sun67.htx/img265.gif | Bin 0 -> 306 bytes src/slalib/sun67.htx/img266.gif | Bin 0 -> 232 bytes src/slalib/sun67.htx/img267.gif | Bin 0 -> 404 bytes src/slalib/sun67.htx/img268.gif | Bin 0 -> 396 bytes src/slalib/sun67.htx/img269.gif | Bin 0 -> 286 bytes src/slalib/sun67.htx/img27.gif | Bin 0 -> 165 bytes src/slalib/sun67.htx/img270.gif | Bin 0 -> 376 bytes src/slalib/sun67.htx/img271.gif | Bin 0 -> 468 bytes src/slalib/sun67.htx/img272.gif | Bin 0 -> 352 bytes src/slalib/sun67.htx/img273.gif | Bin 0 -> 272 bytes src/slalib/sun67.htx/img274.gif | Bin 0 -> 378 bytes src/slalib/sun67.htx/img275.gif | Bin 0 -> 452 bytes src/slalib/sun67.htx/img276.gif | Bin 0 -> 263 bytes src/slalib/sun67.htx/img277.gif | Bin 0 -> 379 bytes src/slalib/sun67.htx/img278.gif | Bin 0 -> 342 bytes src/slalib/sun67.htx/img279.gif | Bin 0 -> 343 bytes src/slalib/sun67.htx/img28.gif | Bin 0 -> 383 bytes src/slalib/sun67.htx/img280.gif | Bin 0 -> 354 bytes src/slalib/sun67.htx/img281.gif | Bin 0 -> 267 bytes src/slalib/sun67.htx/img282.gif | Bin 0 -> 349 bytes src/slalib/sun67.htx/img283.gif | Bin 0 -> 337 bytes src/slalib/sun67.htx/img284.gif | Bin 0 -> 242 bytes src/slalib/sun67.htx/img285.gif | Bin 0 -> 165 bytes src/slalib/sun67.htx/img286.gif | Bin 0 -> 525 bytes src/slalib/sun67.htx/img287.gif | Bin 0 -> 168 bytes src/slalib/sun67.htx/img288.gif | Bin 0 -> 522 bytes src/slalib/sun67.htx/img289.gif | Bin 0 -> 215 bytes src/slalib/sun67.htx/img29.gif | Bin 0 -> 279 bytes src/slalib/sun67.htx/img290.gif | Bin 0 -> 354 bytes src/slalib/sun67.htx/img291.gif | Bin 0 -> 220 bytes src/slalib/sun67.htx/img292.gif | Bin 0 -> 342 bytes src/slalib/sun67.htx/img293.gif | Bin 0 -> 288 bytes src/slalib/sun67.htx/img294.gif | Bin 0 -> 224 bytes src/slalib/sun67.htx/img295.gif | Bin 0 -> 241 bytes src/slalib/sun67.htx/img296.gif | Bin 0 -> 203 bytes src/slalib/sun67.htx/img297.gif | Bin 0 -> 292 bytes src/slalib/sun67.htx/img298.gif | Bin 0 -> 143 bytes src/slalib/sun67.htx/img299.gif | Bin 0 -> 308 bytes src/slalib/sun67.htx/img3.gif | Bin 0 -> 281 bytes src/slalib/sun67.htx/img30.gif | Bin 0 -> 135 bytes src/slalib/sun67.htx/img300.gif | Bin 0 -> 400 bytes src/slalib/sun67.htx/img301.gif | Bin 0 -> 209 bytes src/slalib/sun67.htx/img302.gif | Bin 0 -> 1014 bytes src/slalib/sun67.htx/img303.gif | Bin 0 -> 210 bytes src/slalib/sun67.htx/img304.gif | Bin 0 -> 264 bytes src/slalib/sun67.htx/img305.gif | Bin 0 -> 285 bytes src/slalib/sun67.htx/img306.gif | Bin 0 -> 1785 bytes src/slalib/sun67.htx/img307.gif | Bin 0 -> 324 bytes src/slalib/sun67.htx/img308.gif | Bin 0 -> 516 bytes src/slalib/sun67.htx/img309.gif | Bin 0 -> 431 bytes src/slalib/sun67.htx/img31.gif | Bin 0 -> 208 bytes src/slalib/sun67.htx/img310.gif | Bin 0 -> 371 bytes src/slalib/sun67.htx/img311.gif | Bin 0 -> 316 bytes src/slalib/sun67.htx/img312.gif | Bin 0 -> 304 bytes src/slalib/sun67.htx/img313.gif | Bin 0 -> 301 bytes src/slalib/sun67.htx/img314.gif | Bin 0 -> 446 bytes src/slalib/sun67.htx/img315.gif | Bin 0 -> 184 bytes src/slalib/sun67.htx/img316.gif | Bin 0 -> 154 bytes src/slalib/sun67.htx/img317.gif | Bin 0 -> 253 bytes src/slalib/sun67.htx/img318.gif | Bin 0 -> 139 bytes src/slalib/sun67.htx/img319.gif | Bin 0 -> 162 bytes src/slalib/sun67.htx/img32.gif | Bin 0 -> 212 bytes src/slalib/sun67.htx/img320.gif | Bin 0 -> 287 bytes src/slalib/sun67.htx/img321.gif | Bin 0 -> 364 bytes src/slalib/sun67.htx/img322.gif | Bin 0 -> 372 bytes src/slalib/sun67.htx/img323.gif | Bin 0 -> 306 bytes src/slalib/sun67.htx/img324.gif | Bin 0 -> 214 bytes src/slalib/sun67.htx/img325.gif | Bin 0 -> 399 bytes src/slalib/sun67.htx/img326.gif | Bin 0 -> 349 bytes src/slalib/sun67.htx/img327.gif | Bin 0 -> 379 bytes src/slalib/sun67.htx/img328.gif | Bin 0 -> 413 bytes src/slalib/sun67.htx/img329.gif | Bin 0 -> 255 bytes src/slalib/sun67.htx/img33.gif | Bin 0 -> 201 bytes src/slalib/sun67.htx/img330.gif | Bin 0 -> 376 bytes src/slalib/sun67.htx/img34.gif | Bin 0 -> 309 bytes src/slalib/sun67.htx/img35.gif | Bin 0 -> 314 bytes src/slalib/sun67.htx/img36.gif | Bin 0 -> 211 bytes src/slalib/sun67.htx/img37.gif | Bin 0 -> 247 bytes src/slalib/sun67.htx/img38.gif | Bin 0 -> 436 bytes src/slalib/sun67.htx/img39.gif | Bin 0 -> 179 bytes src/slalib/sun67.htx/img4.gif | Bin 0 -> 468 bytes src/slalib/sun67.htx/img40.gif | Bin 0 -> 297 bytes src/slalib/sun67.htx/img41.gif | Bin 0 -> 316 bytes src/slalib/sun67.htx/img42.gif | Bin 0 -> 305 bytes src/slalib/sun67.htx/img43.gif | Bin 0 -> 152 bytes src/slalib/sun67.htx/img44.gif | Bin 0 -> 316 bytes src/slalib/sun67.htx/img45.gif | Bin 0 -> 286 bytes src/slalib/sun67.htx/img46.gif | Bin 0 -> 290 bytes src/slalib/sun67.htx/img47.gif | Bin 0 -> 178 bytes src/slalib/sun67.htx/img48.gif | Bin 0 -> 87 bytes src/slalib/sun67.htx/img49.gif | Bin 0 -> 169 bytes src/slalib/sun67.htx/img5.gif | Bin 0 -> 122 bytes src/slalib/sun67.htx/img50.gif | Bin 0 -> 352 bytes src/slalib/sun67.htx/img51.gif | Bin 0 -> 541 bytes src/slalib/sun67.htx/img52.gif | Bin 0 -> 171 bytes src/slalib/sun67.htx/img53.gif | Bin 0 -> 250 bytes src/slalib/sun67.htx/img54.gif | Bin 0 -> 446 bytes src/slalib/sun67.htx/img55.gif | Bin 0 -> 325 bytes src/slalib/sun67.htx/img56.gif | Bin 0 -> 350 bytes src/slalib/sun67.htx/img57.gif | Bin 0 -> 434 bytes src/slalib/sun67.htx/img58.gif | Bin 0 -> 448 bytes src/slalib/sun67.htx/img59.gif | Bin 0 -> 382 bytes src/slalib/sun67.htx/img6.gif | Bin 0 -> 1072 bytes src/slalib/sun67.htx/img60.gif | Bin 0 -> 410 bytes src/slalib/sun67.htx/img61.gif | Bin 0 -> 1250 bytes src/slalib/sun67.htx/img62.gif | Bin 0 -> 1276 bytes src/slalib/sun67.htx/img63.gif | Bin 0 -> 1246 bytes src/slalib/sun67.htx/img64.gif | Bin 0 -> 1302 bytes src/slalib/sun67.htx/img65.gif | Bin 0 -> 219 bytes src/slalib/sun67.htx/img66.gif | Bin 0 -> 248 bytes src/slalib/sun67.htx/img67.gif | Bin 0 -> 241 bytes src/slalib/sun67.htx/img68.gif | Bin 0 -> 356 bytes src/slalib/sun67.htx/img69.gif | Bin 0 -> 233 bytes src/slalib/sun67.htx/img7.gif | Bin 0 -> 1121 bytes src/slalib/sun67.htx/img70.gif | Bin 0 -> 143 bytes src/slalib/sun67.htx/img71.gif | Bin 0 -> 170 bytes src/slalib/sun67.htx/img72.gif | Bin 0 -> 73 bytes src/slalib/sun67.htx/img73.gif | Bin 0 -> 237 bytes src/slalib/sun67.htx/img74.gif | Bin 0 -> 236 bytes src/slalib/sun67.htx/img75.gif | Bin 0 -> 160 bytes src/slalib/sun67.htx/img76.gif | Bin 0 -> 207 bytes src/slalib/sun67.htx/img77.gif | Bin 0 -> 206 bytes src/slalib/sun67.htx/img78.gif | Bin 0 -> 211 bytes src/slalib/sun67.htx/img79.gif | Bin 0 -> 241 bytes src/slalib/sun67.htx/img8.gif | Bin 0 -> 305 bytes src/slalib/sun67.htx/img80.gif | Bin 0 -> 243 bytes src/slalib/sun67.htx/img81.gif | Bin 0 -> 246 bytes src/slalib/sun67.htx/img82.gif | Bin 0 -> 261 bytes src/slalib/sun67.htx/img83.gif | Bin 0 -> 208 bytes src/slalib/sun67.htx/img84.gif | Bin 0 -> 139 bytes src/slalib/sun67.htx/img85.gif | Bin 0 -> 290 bytes src/slalib/sun67.htx/img86.gif | Bin 0 -> 201 bytes src/slalib/sun67.htx/img87.gif | Bin 0 -> 219 bytes src/slalib/sun67.htx/img88.gif | Bin 0 -> 334 bytes src/slalib/sun67.htx/img89.gif | Bin 0 -> 217 bytes src/slalib/sun67.htx/img9.gif | Bin 0 -> 428 bytes src/slalib/sun67.htx/img90.gif | Bin 0 -> 226 bytes src/slalib/sun67.htx/img91.gif | Bin 0 -> 218 bytes src/slalib/sun67.htx/img92.gif | Bin 0 -> 151 bytes src/slalib/sun67.htx/img93.gif | Bin 0 -> 278 bytes src/slalib/sun67.htx/img94.gif | Bin 0 -> 294 bytes src/slalib/sun67.htx/img95.gif | Bin 0 -> 403 bytes src/slalib/sun67.htx/img96.gif | Bin 0 -> 246 bytes src/slalib/sun67.htx/img97.gif | Bin 0 -> 224 bytes src/slalib/sun67.htx/img98.gif | Bin 0 -> 425 bytes src/slalib/sun67.htx/img99.gif | Bin 0 -> 157 bytes src/slalib/sun67.htx/index_motif.gif | Bin 0 -> 180 bytes src/slalib/sun67.htx/internals.pl | 1482 +++ src/slalib/sun67.htx/invis_anchor.xbm | 4 + src/slalib/sun67.htx/labels.pl | 1482 +++ src/slalib/sun67.htx/next_group_motif.gif | Bin 0 -> 259 bytes src/slalib/sun67.htx/next_group_motif_gr.gif | Bin 0 -> 259 bytes src/slalib/sun67.htx/next_motif.gif | Bin 0 -> 172 bytes src/slalib/sun67.htx/next_motif_gr.gif | Bin 0 -> 172 bytes src/slalib/sun67.htx/node1.html | 65 + src/slalib/sun67.htx/node10.html | 75 + src/slalib/sun67.htx/node100.html | 110 + src/slalib/sun67.htx/node101.html | 132 + src/slalib/sun67.htx/node102.html | 149 + src/slalib/sun67.htx/node103.html | 170 + src/slalib/sun67.htx/node104.html | 208 + src/slalib/sun67.htx/node105.html | 166 + src/slalib/sun67.htx/node106.html | 207 + src/slalib/sun67.htx/node107.html | 188 + src/slalib/sun67.htx/node108.html | 156 + src/slalib/sun67.htx/node109.html | 168 + src/slalib/sun67.htx/node11.html | 102 + src/slalib/sun67.htx/node110.html | 200 + src/slalib/sun67.htx/node111.html | 104 + src/slalib/sun67.htx/node112.html | 107 + src/slalib/sun67.htx/node113.html | 109 + src/slalib/sun67.htx/node114.html | 107 + src/slalib/sun67.htx/node115.html | 115 + src/slalib/sun67.htx/node116.html | 116 + src/slalib/sun67.htx/node117.html | 92 + src/slalib/sun67.htx/node118.html | 146 + src/slalib/sun67.htx/node119.html | 188 + src/slalib/sun67.htx/node12.html | 75 + src/slalib/sun67.htx/node120.html | 190 + src/slalib/sun67.htx/node121.html | 118 + src/slalib/sun67.htx/node122.html | 170 + src/slalib/sun67.htx/node123.html | 122 + src/slalib/sun67.htx/node124.html | 104 + src/slalib/sun67.htx/node125.html | 107 + src/slalib/sun67.htx/node126.html | 157 + src/slalib/sun67.htx/node127.html | 159 + src/slalib/sun67.htx/node128.html | 187 + src/slalib/sun67.htx/node129.html | 175 + src/slalib/sun67.htx/node13.html | 489 + src/slalib/sun67.htx/node130.html | 140 + src/slalib/sun67.htx/node131.html | 106 + src/slalib/sun67.htx/node132.html | 117 + src/slalib/sun67.htx/node133.html | 111 + src/slalib/sun67.htx/node134.html | 102 + src/slalib/sun67.htx/node135.html | 319 + src/slalib/sun67.htx/node136.html | 258 + src/slalib/sun67.htx/node137.html | 247 + src/slalib/sun67.htx/node138.html | 116 + src/slalib/sun67.htx/node139.html | 117 + src/slalib/sun67.htx/node14.html | 112 + src/slalib/sun67.htx/node140.html | 148 + src/slalib/sun67.htx/node141.html | 107 + src/slalib/sun67.htx/node142.html | 108 + src/slalib/sun67.htx/node143.html | 133 + src/slalib/sun67.htx/node144.html | 310 + src/slalib/sun67.htx/node145.html | 279 + src/slalib/sun67.htx/node146.html | 255 + src/slalib/sun67.htx/node147.html | 278 + src/slalib/sun67.htx/node148.html | 256 + src/slalib/sun67.htx/node149.html | 135 + src/slalib/sun67.htx/node15.html | 230 + src/slalib/sun67.htx/node150.html | 202 + src/slalib/sun67.htx/node151.html | 111 + src/slalib/sun67.htx/node152.html | 145 + src/slalib/sun67.htx/node153.html | 120 + src/slalib/sun67.htx/node154.html | 131 + src/slalib/sun67.htx/node155.html | 110 + src/slalib/sun67.htx/node156.html | 323 + src/slalib/sun67.htx/node157.html | 203 + src/slalib/sun67.htx/node158.html | 102 + src/slalib/sun67.htx/node159.html | 145 + src/slalib/sun67.htx/node16.html | 121 + src/slalib/sun67.htx/node160.html | 98 + src/slalib/sun67.htx/node161.html | 93 + src/slalib/sun67.htx/node162.html | 93 + src/slalib/sun67.htx/node163.html | 166 + src/slalib/sun67.htx/node164.html | 184 + src/slalib/sun67.htx/node165.html | 176 + src/slalib/sun67.htx/node166.html | 428 + src/slalib/sun67.htx/node167.html | 232 + src/slalib/sun67.htx/node168.html | 276 + src/slalib/sun67.htx/node169.html | 275 + src/slalib/sun67.htx/node17.html | 205 + src/slalib/sun67.htx/node170.html | 111 + src/slalib/sun67.htx/node171.html | 115 + src/slalib/sun67.htx/node172.html | 101 + src/slalib/sun67.htx/node173.html | 121 + src/slalib/sun67.htx/node174.html | 126 + src/slalib/sun67.htx/node175.html | 129 + src/slalib/sun67.htx/node176.html | 100 + src/slalib/sun67.htx/node177.html | 152 + src/slalib/sun67.htx/node178.html | 111 + src/slalib/sun67.htx/node179.html | 107 + src/slalib/sun67.htx/node18.html | 135 + src/slalib/sun67.htx/node180.html | 184 + src/slalib/sun67.htx/node181.html | 122 + src/slalib/sun67.htx/node182.html | 201 + src/slalib/sun67.htx/node183.html | 109 + src/slalib/sun67.htx/node184.html | 117 + src/slalib/sun67.htx/node185.html | 168 + src/slalib/sun67.htx/node186.html | 144 + src/slalib/sun67.htx/node187.html | 378 + src/slalib/sun67.htx/node188.html | 220 + src/slalib/sun67.htx/node189.html | 160 + src/slalib/sun67.htx/node19.html | 160 + src/slalib/sun67.htx/node190.html | 137 + src/slalib/sun67.htx/node191.html | 91 + src/slalib/sun67.htx/node192.html | 95 + src/slalib/sun67.htx/node193.html | 93 + src/slalib/sun67.htx/node194.html | 91 + src/slalib/sun67.htx/node195.html | 114 + src/slalib/sun67.htx/node196.html | 137 + src/slalib/sun67.htx/node197.html | 171 + src/slalib/sun67.htx/node198.html | 167 + src/slalib/sun67.htx/node199.html | 174 + src/slalib/sun67.htx/node2.html | 85 + src/slalib/sun67.htx/node20.html | 320 + src/slalib/sun67.htx/node200.html | 168 + src/slalib/sun67.htx/node201.html | 215 + src/slalib/sun67.htx/node202.html | 254 + src/slalib/sun67.htx/node203.html | 187 + src/slalib/sun67.htx/node204.html | 127 + src/slalib/sun67.htx/node205.html | 92 + src/slalib/sun67.htx/node206.html | 125 + src/slalib/sun67.htx/node207.html | 119 + src/slalib/sun67.htx/node208.html | 92 + src/slalib/sun67.htx/node209.html | 147 + src/slalib/sun67.htx/node21.html | 264 + src/slalib/sun67.htx/node210.html | 177 + src/slalib/sun67.htx/node211.html | 232 + src/slalib/sun67.htx/node212.html | 171 + src/slalib/sun67.htx/node213.html | 181 + src/slalib/sun67.htx/node214.html | 189 + src/slalib/sun67.htx/node215.html | 87 + src/slalib/sun67.htx/node216.html | 110 + src/slalib/sun67.htx/node217.html | 92 + src/slalib/sun67.htx/node218.html | 91 + src/slalib/sun67.htx/node219.html | 184 + src/slalib/sun67.htx/node22.html | 119 + src/slalib/sun67.htx/node220.html | 96 + src/slalib/sun67.htx/node221.html | 158 + src/slalib/sun67.htx/node222.html | 113 + src/slalib/sun67.htx/node223.html | 139 + src/slalib/sun67.htx/node224.html | 617 + src/slalib/sun67.htx/node225.html | 143 + src/slalib/sun67.htx/node226.html | 212 + src/slalib/sun67.htx/node227.html | 230 + src/slalib/sun67.htx/node228.html | 696 ++ src/slalib/sun67.htx/node229.html | 65 + src/slalib/sun67.htx/node23.html | 278 + src/slalib/sun67.htx/node24.html | 213 + src/slalib/sun67.htx/node25.html | 103 + src/slalib/sun67.htx/node26.html | 123 + src/slalib/sun67.htx/node27.html | 122 + src/slalib/sun67.htx/node28.html | 128 + src/slalib/sun67.htx/node29.html | 140 + src/slalib/sun67.htx/node3.html | 76 + src/slalib/sun67.htx/node30.html | 103 + src/slalib/sun67.htx/node31.html | 114 + src/slalib/sun67.htx/node32.html | 115 + src/slalib/sun67.htx/node33.html | 128 + src/slalib/sun67.htx/node34.html | 129 + src/slalib/sun67.htx/node35.html | 142 + src/slalib/sun67.htx/node36.html | 122 + src/slalib/sun67.htx/node37.html | 121 + src/slalib/sun67.htx/node38.html | 99 + src/slalib/sun67.htx/node39.html | 114 + src/slalib/sun67.htx/node4.html | 131 + src/slalib/sun67.htx/node40.html | 125 + src/slalib/sun67.htx/node41.html | 125 + src/slalib/sun67.htx/node42.html | 122 + src/slalib/sun67.htx/node43.html | 229 + src/slalib/sun67.htx/node44.html | 109 + src/slalib/sun67.htx/node45.html | 103 + src/slalib/sun67.htx/node46.html | 123 + src/slalib/sun67.htx/node47.html | 157 + src/slalib/sun67.htx/node48.html | 110 + src/slalib/sun67.htx/node49.html | 103 + src/slalib/sun67.htx/node5.html | 83 + src/slalib/sun67.htx/node50.html | 166 + src/slalib/sun67.htx/node51.html | 99 + src/slalib/sun67.htx/node52.html | 115 + src/slalib/sun67.htx/node53.html | 145 + src/slalib/sun67.htx/node54.html | 127 + src/slalib/sun67.htx/node55.html | 200 + src/slalib/sun67.htx/node56.html | 146 + src/slalib/sun67.htx/node57.html | 118 + src/slalib/sun67.htx/node58.html | 112 + src/slalib/sun67.htx/node59.html | 117 + src/slalib/sun67.htx/node6.html | 116 + src/slalib/sun67.htx/node60.html | 107 + src/slalib/sun67.htx/node61.html | 152 + src/slalib/sun67.htx/node62.html | 154 + src/slalib/sun67.htx/node63.html | 106 + src/slalib/sun67.htx/node64.html | 115 + src/slalib/sun67.htx/node65.html | 117 + src/slalib/sun67.htx/node66.html | 122 + src/slalib/sun67.htx/node67.html | 121 + src/slalib/sun67.htx/node68.html | 93 + src/slalib/sun67.htx/node69.html | 93 + src/slalib/sun67.htx/node7.html | 76 + src/slalib/sun67.htx/node70.html | 114 + src/slalib/sun67.htx/node71.html | 129 + src/slalib/sun67.htx/node72.html | 100 + src/slalib/sun67.htx/node73.html | 131 + src/slalib/sun67.htx/node74.html | 125 + src/slalib/sun67.htx/node75.html | 125 + src/slalib/sun67.htx/node76.html | 109 + src/slalib/sun67.htx/node77.html | 117 + src/slalib/sun67.htx/node78.html | 168 + src/slalib/sun67.htx/node79.html | 144 + src/slalib/sun67.htx/node8.html | 85 + src/slalib/sun67.htx/node80.html | 111 + src/slalib/sun67.htx/node81.html | 137 + src/slalib/sun67.htx/node82.html | 91 + src/slalib/sun67.htx/node83.html | 95 + src/slalib/sun67.htx/node84.html | 93 + src/slalib/sun67.htx/node85.html | 145 + src/slalib/sun67.htx/node86.html | 124 + src/slalib/sun67.htx/node87.html | 97 + src/slalib/sun67.htx/node88.html | 106 + src/slalib/sun67.htx/node89.html | 140 + src/slalib/sun67.htx/node9.html | 75 + src/slalib/sun67.htx/node90.html | 106 + src/slalib/sun67.htx/node91.html | 330 + src/slalib/sun67.htx/node92.html | 91 + src/slalib/sun67.htx/node93.html | 91 + src/slalib/sun67.htx/node94.html | 110 + src/slalib/sun67.htx/node95.html | 91 + src/slalib/sun67.htx/node96.html | 91 + src/slalib/sun67.htx/node97.html | 98 + src/slalib/sun67.htx/node98.html | 111 + src/slalib/sun67.htx/node99.html | 105 + src/slalib/sun67.htx/orangeball.gif | Bin 0 -> 398 bytes src/slalib/sun67.htx/pinkball.gif | Bin 0 -> 398 bytes src/slalib/sun67.htx/previous_group_motif.gif | Bin 0 -> 303 bytes src/slalib/sun67.htx/previous_group_motif_gr.gif | Bin 0 -> 303 bytes src/slalib/sun67.htx/previous_motif.gif | Bin 0 -> 220 bytes src/slalib/sun67.htx/previous_motif_gr.gif | Bin 0 -> 220 bytes src/slalib/sun67.htx/purpleball.gif | Bin 0 -> 398 bytes src/slalib/sun67.htx/redball.gif | Bin 0 -> 398 bytes src/slalib/sun67.htx/source.gif | Bin 0 -> 979 bytes src/slalib/sun67.htx/sun67.css | 10 + src/slalib/sun67.htx/sun67.html | 610 + src/slalib/sun67.htx/up_motif.gif | Bin 0 -> 145 bytes src/slalib/sun67.htx/up_motif_gr.gif | Bin 0 -> 145 bytes src/slalib/sun67.htx/whiteball.gif | Bin 0 -> 275 bytes src/slalib/sun67.htx/yellowball.gif | Bin 0 -> 398 bytes src/slalib/sun67.htx_tar | Bin 0 -> 2293760 bytes src/slalib/sun67.tex | 12430 +++++++++++++++++++++ src/slalib/supgal.f | 79 + src/slalib/svd.f | 379 + src/slalib/svdcov.f | 60 + src/slalib/svdsol.f | 109 + src/slalib/tp2s.f | 42 + src/slalib/tp2v.f | 56 + src/slalib/tps2c.f | 91 + src/slalib/tpv2c.f | 83 + src/slalib/ue2el.f | 194 + src/slalib/ue2pv.f | 215 + src/slalib/unpcd.f | 68 + src/slalib/v2tp.f | 78 + src/slalib/vdv.f | 27 + src/slalib/vn.f | 46 + src/slalib/vxv.f | 39 + src/slalib/wait.f_alpha_OSF1 | 32 + src/slalib/wait.f_convex | 32 + src/slalib/wait.f_ix86_Linux | 32 + src/slalib/wait.f_mips | 32 + src/slalib/wait.f_pcm | 66 + src/slalib/wait.f_sun4 | 32 + src/slalib/wait.f_sun4_Solaris | 32 + src/slalib/wait.f_vax | 43 + src/slalib/wait.f_x86_64 | 32 + src/slalib/xy2xy.f | 49 + src/slalib/zd.f | 62 + 829 files changed, 84128 insertions(+) create mode 100644 src/slalib/Makefile.am create mode 100644 src/slalib/Makefile.in create mode 100644 src/slalib/addet.f create mode 100644 src/slalib/afin.f create mode 100644 src/slalib/airmas.f create mode 100644 src/slalib/altaz.f create mode 100644 src/slalib/amp.f create mode 100644 src/slalib/ampqk.f create mode 100644 src/slalib/aop.f create mode 100644 src/slalib/aoppa.f create mode 100644 src/slalib/aoppat.f create mode 100644 src/slalib/aopqk.f create mode 100644 src/slalib/atmdsp.f create mode 100644 src/slalib/atms.f create mode 100644 src/slalib/atmt.f create mode 100644 src/slalib/av2m.f create mode 100644 src/slalib/bear.f create mode 100644 src/slalib/caf2r.f create mode 100644 src/slalib/caldj.f create mode 100644 src/slalib/calyd.f create mode 100644 src/slalib/cc2s.f create mode 100644 src/slalib/cc62s.f create mode 100644 src/slalib/cd2tf.f create mode 100644 src/slalib/cldj.f create mode 100644 src/slalib/clyd.f create mode 100644 src/slalib/combn.f create mode 100644 src/slalib/cr2af.f create mode 100644 src/slalib/cr2tf.f create mode 100755 src/slalib/create.com create mode 100644 src/slalib/cs2c.f create mode 100644 src/slalib/cs2c6.f create mode 100644 src/slalib/ctf2d.f create mode 100644 src/slalib/ctf2r.f create mode 100644 src/slalib/daf2r.f create mode 100644 src/slalib/dafin.f create mode 100644 src/slalib/dat.f create mode 100644 src/slalib/dav2m.f create mode 100644 src/slalib/dbear.f create mode 100644 src/slalib/dbjin.f create mode 100644 src/slalib/dc62s.f create mode 100644 src/slalib/dcc2s.f create mode 100644 src/slalib/dcmpf.f create mode 100644 src/slalib/dcs2c.f create mode 100644 src/slalib/dd2tf.f create mode 100644 src/slalib/de2h.f create mode 100644 src/slalib/deuler.f create mode 100644 src/slalib/dfltin.f create mode 100644 src/slalib/dh2e.f create mode 100644 src/slalib/dimxv.f create mode 100644 src/slalib/djcal.f create mode 100644 src/slalib/djcl.f create mode 100644 src/slalib/dm2av.f create mode 100644 src/slalib/dmat.f create mode 100644 src/slalib/dmoon.f create mode 100644 src/slalib/dmxm.f create mode 100644 src/slalib/dmxv.f create mode 100644 src/slalib/dpav.f create mode 100644 src/slalib/dr2af.f create mode 100644 src/slalib/dr2tf.f create mode 100644 src/slalib/drange.f create mode 100644 src/slalib/dranrm.f create mode 100644 src/slalib/ds2c6.f create mode 100644 src/slalib/ds2tp.f create mode 100644 src/slalib/dsep.f create mode 100644 src/slalib/dt.f create mode 100644 src/slalib/dtf2d.f create mode 100644 src/slalib/dtf2r.f create mode 100644 src/slalib/dtp2s.f create mode 100644 src/slalib/dtp2v.f create mode 100644 src/slalib/dtps2c.f create mode 100644 src/slalib/dtpv2c.f create mode 100644 src/slalib/dtt.f create mode 100644 src/slalib/dv2tp.f create mode 100644 src/slalib/dvdv.f create mode 100644 src/slalib/dvn.f create mode 100644 src/slalib/dvxv.f create mode 100644 src/slalib/e2h.f create mode 100644 src/slalib/earth.f create mode 100644 src/slalib/ecleq.f create mode 100644 src/slalib/ecmat.f create mode 100644 src/slalib/ecor.f create mode 100644 src/slalib/eg50.f create mode 100644 src/slalib/el2ue.f create mode 100644 src/slalib/epb.f create mode 100644 src/slalib/epb2d.f create mode 100644 src/slalib/epco.f create mode 100644 src/slalib/epj.f create mode 100644 src/slalib/epj2d.f create mode 100644 src/slalib/eqecl.f create mode 100644 src/slalib/eqeqx.f create mode 100644 src/slalib/eqgal.f create mode 100644 src/slalib/etrms.f create mode 100644 src/slalib/euler.f create mode 100644 src/slalib/evp.f create mode 100644 src/slalib/fitxy.f create mode 100644 src/slalib/fk425.f create mode 100644 src/slalib/fk45z.f create mode 100644 src/slalib/fk524.f create mode 100644 src/slalib/fk52h.f create mode 100644 src/slalib/fk54z.f create mode 100644 src/slalib/fk5hz.f create mode 100644 src/slalib/flotin.f create mode 100644 src/slalib/galeq.f create mode 100644 src/slalib/galsup.f create mode 100644 src/slalib/ge50.f create mode 100644 src/slalib/geoc.f create mode 100644 src/slalib/gmst.f create mode 100644 src/slalib/gmsta.f create mode 100644 src/slalib/gresid.f_alpha_OSF1 create mode 100644 src/slalib/gresid.f_convex create mode 100644 src/slalib/gresid.f_ix86_Linux create mode 100644 src/slalib/gresid.f_mips create mode 100644 src/slalib/gresid.f_pcm create mode 100644 src/slalib/gresid.f_sun4 create mode 100644 src/slalib/gresid.f_sun4_Solaris create mode 100644 src/slalib/gresid.f_vax create mode 100644 src/slalib/gresid.f_x86_64 create mode 100644 src/slalib/h2e.f create mode 100644 src/slalib/h2fk5.f create mode 100644 src/slalib/hfk5z.f create mode 100644 src/slalib/idchf.f create mode 100644 src/slalib/idchi.f create mode 100644 src/slalib/imxv.f create mode 100644 src/slalib/intin.f create mode 100644 src/slalib/invf.f create mode 100644 src/slalib/kbj.f create mode 100644 src/slalib/m2av.f create mode 100644 src/slalib/makefile.orig create mode 100644 src/slalib/map.f create mode 100644 src/slalib/mappa.f create mode 100644 src/slalib/mapqk.f create mode 100644 src/slalib/mapqkz.f create mode 100755 src/slalib/mk create mode 100755 src/slalib/mk.sv create mode 100644 src/slalib/moon.f create mode 100644 src/slalib/mxm.f create mode 100644 src/slalib/mxv.f create mode 100644 src/slalib/nut.f create mode 100644 src/slalib/nutc.f create mode 100644 src/slalib/oap.f create mode 100644 src/slalib/oapqk.f create mode 100644 src/slalib/obs.f create mode 100644 src/slalib/pa.f create mode 100644 src/slalib/pav.f create mode 100755 src/slalib/pc.bat create mode 100644 src/slalib/pcd.f create mode 100644 src/slalib/pda2h.f create mode 100644 src/slalib/pdq2h.f create mode 100644 src/slalib/permut.f create mode 100644 src/slalib/pertel.f create mode 100644 src/slalib/pertue.f create mode 100644 src/slalib/planel.f create mode 100644 src/slalib/planet.f create mode 100644 src/slalib/plante.f create mode 100644 src/slalib/pm.f create mode 100644 src/slalib/polmo.f create mode 100644 src/slalib/prebn.f create mode 100644 src/slalib/prec.f create mode 100644 src/slalib/preces.f create mode 100644 src/slalib/precl.f create mode 100644 src/slalib/prenut.f create mode 100755 src/slalib/put.com create mode 100644 src/slalib/pv2el.f create mode 100644 src/slalib/pv2ue.f create mode 100644 src/slalib/pvobs.f create mode 100644 src/slalib/pxy.f create mode 100644 src/slalib/random.f_alpha_OSF1 create mode 100644 src/slalib/random.f_convex create mode 100644 src/slalib/random.f_ix86_Linux create mode 100644 src/slalib/random.f_mips create mode 100644 src/slalib/random.f_pcm create mode 100644 src/slalib/random.f_sun4 create mode 100644 src/slalib/random.f_sun4_Solaris create mode 100644 src/slalib/random.f_vax create mode 100644 src/slalib/random.f_x86_64 create mode 100644 src/slalib/range.f create mode 100644 src/slalib/ranorm.f create mode 100644 src/slalib/rcc.f create mode 100644 src/slalib/rdplan.f create mode 100644 src/slalib/read.me create mode 100644 src/slalib/refco.f create mode 100644 src/slalib/refcoq.f create mode 100644 src/slalib/refro.f create mode 100644 src/slalib/refv.f create mode 100644 src/slalib/refz.f create mode 100755 src/slalib/rep.bat create mode 100644 src/slalib/rtl_random.c create mode 100644 src/slalib/rverot.f create mode 100644 src/slalib/rvgalc.f create mode 100644 src/slalib/rvlg.f create mode 100644 src/slalib/rvlsrd.f create mode 100644 src/slalib/rvlsrk.f create mode 100644 src/slalib/s2tp.f create mode 100644 src/slalib/sep.f create mode 100644 src/slalib/sla.news create mode 100755 src/slalib/sla_link create mode 100755 src/slalib/sla_link_adam create mode 100644 src/slalib/sla_test.f create mode 100644 src/slalib/smat.f create mode 100644 src/slalib/subet.f create mode 100644 src/slalib/sun67.htx/blueball.gif create mode 100644 src/slalib/sun67.htx/change_begin.gif create mode 100644 src/slalib/sun67.htx/change_begin_right.gif create mode 100644 src/slalib/sun67.htx/change_delete.gif create mode 100644 src/slalib/sun67.htx/change_delete_right.gif create mode 100644 src/slalib/sun67.htx/change_end.gif create mode 100644 src/slalib/sun67.htx/change_end_right.gif create mode 100644 src/slalib/sun67.htx/contents.xbm create mode 100644 src/slalib/sun67.htx/contents_motif.gif create mode 100644 src/slalib/sun67.htx/cross_ref_motif.gif create mode 100644 src/slalib/sun67.htx/foot_motif.gif create mode 100644 src/slalib/sun67.htx/footnode.html create mode 100644 src/slalib/sun67.htx/greenball.gif create mode 100644 src/slalib/sun67.htx/icons.html create mode 100644 src/slalib/sun67.htx/image.gif create mode 100644 src/slalib/sun67.htx/images.aux create mode 100644 src/slalib/sun67.htx/images.log create mode 100644 src/slalib/sun67.htx/images.pl create mode 100644 src/slalib/sun67.htx/images.tex create mode 100644 src/slalib/sun67.htx/img1.gif create mode 100644 src/slalib/sun67.htx/img10.gif create mode 100644 src/slalib/sun67.htx/img100.gif create mode 100644 src/slalib/sun67.htx/img101.gif create mode 100644 src/slalib/sun67.htx/img102.gif create mode 100644 src/slalib/sun67.htx/img103.gif create mode 100644 src/slalib/sun67.htx/img104.gif create mode 100644 src/slalib/sun67.htx/img105.gif create mode 100644 src/slalib/sun67.htx/img106.gif create mode 100644 src/slalib/sun67.htx/img107.gif create mode 100644 src/slalib/sun67.htx/img108.gif create mode 100644 src/slalib/sun67.htx/img109.gif create mode 100644 src/slalib/sun67.htx/img11.gif create mode 100644 src/slalib/sun67.htx/img110.gif create mode 100644 src/slalib/sun67.htx/img111.gif create mode 100644 src/slalib/sun67.htx/img112.gif create mode 100644 src/slalib/sun67.htx/img113.gif create mode 100644 src/slalib/sun67.htx/img114.gif create mode 100644 src/slalib/sun67.htx/img115.gif create mode 100644 src/slalib/sun67.htx/img116.gif create mode 100644 src/slalib/sun67.htx/img117.gif create mode 100644 src/slalib/sun67.htx/img118.gif create mode 100644 src/slalib/sun67.htx/img119.gif create mode 100644 src/slalib/sun67.htx/img12.gif create mode 100644 src/slalib/sun67.htx/img120.gif create mode 100644 src/slalib/sun67.htx/img121.gif create mode 100644 src/slalib/sun67.htx/img122.gif create mode 100644 src/slalib/sun67.htx/img123.gif create mode 100644 src/slalib/sun67.htx/img124.gif create mode 100644 src/slalib/sun67.htx/img125.gif create mode 100644 src/slalib/sun67.htx/img126.gif create mode 100644 src/slalib/sun67.htx/img127.gif create mode 100644 src/slalib/sun67.htx/img128.gif create mode 100644 src/slalib/sun67.htx/img129.gif create mode 100644 src/slalib/sun67.htx/img13.gif create mode 100644 src/slalib/sun67.htx/img130.gif create mode 100644 src/slalib/sun67.htx/img131.gif create mode 100644 src/slalib/sun67.htx/img132.gif create mode 100644 src/slalib/sun67.htx/img133.gif create mode 100644 src/slalib/sun67.htx/img134.gif create mode 100644 src/slalib/sun67.htx/img135.gif create mode 100644 src/slalib/sun67.htx/img136.gif create mode 100644 src/slalib/sun67.htx/img137.gif create mode 100644 src/slalib/sun67.htx/img138.gif create mode 100644 src/slalib/sun67.htx/img139.gif create mode 100644 src/slalib/sun67.htx/img14.gif create mode 100644 src/slalib/sun67.htx/img140.gif create mode 100644 src/slalib/sun67.htx/img141.gif create mode 100644 src/slalib/sun67.htx/img142.gif create mode 100644 src/slalib/sun67.htx/img143.gif create mode 100644 src/slalib/sun67.htx/img144.gif create mode 100644 src/slalib/sun67.htx/img145.gif create mode 100644 src/slalib/sun67.htx/img146.gif create mode 100644 src/slalib/sun67.htx/img147.gif create mode 100644 src/slalib/sun67.htx/img148.gif create mode 100644 src/slalib/sun67.htx/img149.gif create mode 100644 src/slalib/sun67.htx/img15.gif create mode 100644 src/slalib/sun67.htx/img150.gif create mode 100644 src/slalib/sun67.htx/img151.gif create mode 100644 src/slalib/sun67.htx/img152.gif create mode 100644 src/slalib/sun67.htx/img153.gif create mode 100644 src/slalib/sun67.htx/img154.gif create mode 100644 src/slalib/sun67.htx/img155.gif create mode 100644 src/slalib/sun67.htx/img156.gif create mode 100644 src/slalib/sun67.htx/img157.gif create mode 100644 src/slalib/sun67.htx/img158.gif create mode 100644 src/slalib/sun67.htx/img159.gif create mode 100644 src/slalib/sun67.htx/img16.gif create mode 100644 src/slalib/sun67.htx/img160.gif create mode 100644 src/slalib/sun67.htx/img161.gif create mode 100644 src/slalib/sun67.htx/img162.gif create mode 100644 src/slalib/sun67.htx/img163.gif create mode 100644 src/slalib/sun67.htx/img164.gif create mode 100644 src/slalib/sun67.htx/img165.gif create mode 100644 src/slalib/sun67.htx/img166.gif create mode 100644 src/slalib/sun67.htx/img167.gif create mode 100644 src/slalib/sun67.htx/img168.gif create mode 100644 src/slalib/sun67.htx/img169.gif create mode 100644 src/slalib/sun67.htx/img17.gif create mode 100644 src/slalib/sun67.htx/img170.gif create mode 100644 src/slalib/sun67.htx/img171.gif create mode 100644 src/slalib/sun67.htx/img172.gif create mode 100644 src/slalib/sun67.htx/img173.gif create mode 100644 src/slalib/sun67.htx/img174.gif create mode 100644 src/slalib/sun67.htx/img175.gif create mode 100644 src/slalib/sun67.htx/img176.gif create mode 100644 src/slalib/sun67.htx/img177.gif create mode 100644 src/slalib/sun67.htx/img178.gif create mode 100644 src/slalib/sun67.htx/img179.gif create mode 100644 src/slalib/sun67.htx/img18.gif create mode 100644 src/slalib/sun67.htx/img180.gif create mode 100644 src/slalib/sun67.htx/img181.gif create mode 100644 src/slalib/sun67.htx/img182.gif create mode 100644 src/slalib/sun67.htx/img183.gif create mode 100644 src/slalib/sun67.htx/img184.gif create mode 100644 src/slalib/sun67.htx/img185.gif create mode 100644 src/slalib/sun67.htx/img186.gif create mode 100644 src/slalib/sun67.htx/img187.gif create mode 100644 src/slalib/sun67.htx/img188.gif create mode 100644 src/slalib/sun67.htx/img189.gif create mode 100644 src/slalib/sun67.htx/img19.gif create mode 100644 src/slalib/sun67.htx/img190.gif create mode 100644 src/slalib/sun67.htx/img191.gif create mode 100644 src/slalib/sun67.htx/img192.gif create mode 100644 src/slalib/sun67.htx/img193.gif create mode 100644 src/slalib/sun67.htx/img194.gif create mode 100644 src/slalib/sun67.htx/img195.gif create mode 100644 src/slalib/sun67.htx/img196.gif create mode 100644 src/slalib/sun67.htx/img197.gif create mode 100644 src/slalib/sun67.htx/img198.gif create mode 100644 src/slalib/sun67.htx/img199.gif create mode 100644 src/slalib/sun67.htx/img2.gif create mode 100644 src/slalib/sun67.htx/img20.gif create mode 100644 src/slalib/sun67.htx/img200.gif create mode 100644 src/slalib/sun67.htx/img201.gif create mode 100644 src/slalib/sun67.htx/img202.gif create mode 100644 src/slalib/sun67.htx/img203.gif create mode 100644 src/slalib/sun67.htx/img204.gif create mode 100644 src/slalib/sun67.htx/img205.gif create mode 100644 src/slalib/sun67.htx/img206.gif create mode 100644 src/slalib/sun67.htx/img207.gif create mode 100644 src/slalib/sun67.htx/img208.gif create mode 100644 src/slalib/sun67.htx/img209.gif create mode 100644 src/slalib/sun67.htx/img21.gif create mode 100644 src/slalib/sun67.htx/img210.gif create mode 100644 src/slalib/sun67.htx/img211.gif create mode 100644 src/slalib/sun67.htx/img212.gif create mode 100644 src/slalib/sun67.htx/img213.gif create mode 100644 src/slalib/sun67.htx/img214.gif create mode 100644 src/slalib/sun67.htx/img215.gif create mode 100644 src/slalib/sun67.htx/img216.gif create mode 100644 src/slalib/sun67.htx/img217.gif create mode 100644 src/slalib/sun67.htx/img218.gif create mode 100644 src/slalib/sun67.htx/img219.gif create mode 100644 src/slalib/sun67.htx/img22.gif create mode 100644 src/slalib/sun67.htx/img220.gif create mode 100644 src/slalib/sun67.htx/img221.gif create mode 100644 src/slalib/sun67.htx/img222.gif create mode 100644 src/slalib/sun67.htx/img223.gif create mode 100644 src/slalib/sun67.htx/img224.gif create mode 100644 src/slalib/sun67.htx/img225.gif create mode 100644 src/slalib/sun67.htx/img226.gif create mode 100644 src/slalib/sun67.htx/img227.gif create mode 100644 src/slalib/sun67.htx/img228.gif create mode 100644 src/slalib/sun67.htx/img229.gif create mode 100644 src/slalib/sun67.htx/img23.gif create mode 100644 src/slalib/sun67.htx/img230.gif create mode 100644 src/slalib/sun67.htx/img231.gif create mode 100644 src/slalib/sun67.htx/img232.gif create mode 100644 src/slalib/sun67.htx/img233.gif create mode 100644 src/slalib/sun67.htx/img234.gif create mode 100644 src/slalib/sun67.htx/img235.gif create mode 100644 src/slalib/sun67.htx/img236.gif create mode 100644 src/slalib/sun67.htx/img237.gif create mode 100644 src/slalib/sun67.htx/img238.gif create mode 100644 src/slalib/sun67.htx/img239.gif create mode 100644 src/slalib/sun67.htx/img24.gif create mode 100644 src/slalib/sun67.htx/img240.gif create mode 100644 src/slalib/sun67.htx/img241.gif create mode 100644 src/slalib/sun67.htx/img242.gif create mode 100644 src/slalib/sun67.htx/img243.gif create mode 100644 src/slalib/sun67.htx/img244.gif create mode 100644 src/slalib/sun67.htx/img245.gif create mode 100644 src/slalib/sun67.htx/img246.gif create mode 100644 src/slalib/sun67.htx/img247.gif create mode 100644 src/slalib/sun67.htx/img248.gif create mode 100644 src/slalib/sun67.htx/img249.gif create mode 100644 src/slalib/sun67.htx/img25.gif create mode 100644 src/slalib/sun67.htx/img250.gif create mode 100644 src/slalib/sun67.htx/img251.gif create mode 100644 src/slalib/sun67.htx/img252.gif create mode 100644 src/slalib/sun67.htx/img253.gif create mode 100644 src/slalib/sun67.htx/img254.gif create mode 100644 src/slalib/sun67.htx/img255.gif create mode 100644 src/slalib/sun67.htx/img256.gif create mode 100644 src/slalib/sun67.htx/img257.gif create mode 100644 src/slalib/sun67.htx/img258.gif create mode 100644 src/slalib/sun67.htx/img259.gif create mode 100644 src/slalib/sun67.htx/img26.gif create mode 100644 src/slalib/sun67.htx/img260.gif create mode 100644 src/slalib/sun67.htx/img261.gif create mode 100644 src/slalib/sun67.htx/img262.gif create mode 100644 src/slalib/sun67.htx/img263.gif create mode 100644 src/slalib/sun67.htx/img264.gif create mode 100644 src/slalib/sun67.htx/img265.gif create mode 100644 src/slalib/sun67.htx/img266.gif create mode 100644 src/slalib/sun67.htx/img267.gif create mode 100644 src/slalib/sun67.htx/img268.gif create mode 100644 src/slalib/sun67.htx/img269.gif create mode 100644 src/slalib/sun67.htx/img27.gif create mode 100644 src/slalib/sun67.htx/img270.gif create mode 100644 src/slalib/sun67.htx/img271.gif create mode 100644 src/slalib/sun67.htx/img272.gif create mode 100644 src/slalib/sun67.htx/img273.gif create mode 100644 src/slalib/sun67.htx/img274.gif create mode 100644 src/slalib/sun67.htx/img275.gif create mode 100644 src/slalib/sun67.htx/img276.gif create mode 100644 src/slalib/sun67.htx/img277.gif create mode 100644 src/slalib/sun67.htx/img278.gif create mode 100644 src/slalib/sun67.htx/img279.gif create mode 100644 src/slalib/sun67.htx/img28.gif create mode 100644 src/slalib/sun67.htx/img280.gif create mode 100644 src/slalib/sun67.htx/img281.gif create mode 100644 src/slalib/sun67.htx/img282.gif create mode 100644 src/slalib/sun67.htx/img283.gif create mode 100644 src/slalib/sun67.htx/img284.gif create mode 100644 src/slalib/sun67.htx/img285.gif create mode 100644 src/slalib/sun67.htx/img286.gif create mode 100644 src/slalib/sun67.htx/img287.gif create mode 100644 src/slalib/sun67.htx/img288.gif create mode 100644 src/slalib/sun67.htx/img289.gif create mode 100644 src/slalib/sun67.htx/img29.gif create mode 100644 src/slalib/sun67.htx/img290.gif create mode 100644 src/slalib/sun67.htx/img291.gif create mode 100644 src/slalib/sun67.htx/img292.gif create mode 100644 src/slalib/sun67.htx/img293.gif create mode 100644 src/slalib/sun67.htx/img294.gif create mode 100644 src/slalib/sun67.htx/img295.gif create mode 100644 src/slalib/sun67.htx/img296.gif create mode 100644 src/slalib/sun67.htx/img297.gif create mode 100644 src/slalib/sun67.htx/img298.gif create mode 100644 src/slalib/sun67.htx/img299.gif create mode 100644 src/slalib/sun67.htx/img3.gif create mode 100644 src/slalib/sun67.htx/img30.gif create mode 100644 src/slalib/sun67.htx/img300.gif create mode 100644 src/slalib/sun67.htx/img301.gif create mode 100644 src/slalib/sun67.htx/img302.gif create mode 100644 src/slalib/sun67.htx/img303.gif create mode 100644 src/slalib/sun67.htx/img304.gif create mode 100644 src/slalib/sun67.htx/img305.gif create mode 100644 src/slalib/sun67.htx/img306.gif create mode 100644 src/slalib/sun67.htx/img307.gif create mode 100644 src/slalib/sun67.htx/img308.gif create mode 100644 src/slalib/sun67.htx/img309.gif create mode 100644 src/slalib/sun67.htx/img31.gif create mode 100644 src/slalib/sun67.htx/img310.gif create mode 100644 src/slalib/sun67.htx/img311.gif create mode 100644 src/slalib/sun67.htx/img312.gif create mode 100644 src/slalib/sun67.htx/img313.gif create mode 100644 src/slalib/sun67.htx/img314.gif create mode 100644 src/slalib/sun67.htx/img315.gif create mode 100644 src/slalib/sun67.htx/img316.gif create mode 100644 src/slalib/sun67.htx/img317.gif create mode 100644 src/slalib/sun67.htx/img318.gif create mode 100644 src/slalib/sun67.htx/img319.gif create mode 100644 src/slalib/sun67.htx/img32.gif create mode 100644 src/slalib/sun67.htx/img320.gif create mode 100644 src/slalib/sun67.htx/img321.gif create mode 100644 src/slalib/sun67.htx/img322.gif create mode 100644 src/slalib/sun67.htx/img323.gif create mode 100644 src/slalib/sun67.htx/img324.gif create mode 100644 src/slalib/sun67.htx/img325.gif create mode 100644 src/slalib/sun67.htx/img326.gif create mode 100644 src/slalib/sun67.htx/img327.gif create mode 100644 src/slalib/sun67.htx/img328.gif create mode 100644 src/slalib/sun67.htx/img329.gif create mode 100644 src/slalib/sun67.htx/img33.gif create mode 100644 src/slalib/sun67.htx/img330.gif create mode 100644 src/slalib/sun67.htx/img34.gif create mode 100644 src/slalib/sun67.htx/img35.gif create mode 100644 src/slalib/sun67.htx/img36.gif create mode 100644 src/slalib/sun67.htx/img37.gif create mode 100644 src/slalib/sun67.htx/img38.gif create mode 100644 src/slalib/sun67.htx/img39.gif create mode 100644 src/slalib/sun67.htx/img4.gif create mode 100644 src/slalib/sun67.htx/img40.gif create mode 100644 src/slalib/sun67.htx/img41.gif create mode 100644 src/slalib/sun67.htx/img42.gif create mode 100644 src/slalib/sun67.htx/img43.gif create mode 100644 src/slalib/sun67.htx/img44.gif create mode 100644 src/slalib/sun67.htx/img45.gif create mode 100644 src/slalib/sun67.htx/img46.gif create mode 100644 src/slalib/sun67.htx/img47.gif create mode 100644 src/slalib/sun67.htx/img48.gif create mode 100644 src/slalib/sun67.htx/img49.gif create mode 100644 src/slalib/sun67.htx/img5.gif create mode 100644 src/slalib/sun67.htx/img50.gif create mode 100644 src/slalib/sun67.htx/img51.gif create mode 100644 src/slalib/sun67.htx/img52.gif create mode 100644 src/slalib/sun67.htx/img53.gif create mode 100644 src/slalib/sun67.htx/img54.gif create mode 100644 src/slalib/sun67.htx/img55.gif create mode 100644 src/slalib/sun67.htx/img56.gif create mode 100644 src/slalib/sun67.htx/img57.gif create mode 100644 src/slalib/sun67.htx/img58.gif create mode 100644 src/slalib/sun67.htx/img59.gif create mode 100644 src/slalib/sun67.htx/img6.gif create mode 100644 src/slalib/sun67.htx/img60.gif create mode 100644 src/slalib/sun67.htx/img61.gif create mode 100644 src/slalib/sun67.htx/img62.gif create mode 100644 src/slalib/sun67.htx/img63.gif create mode 100644 src/slalib/sun67.htx/img64.gif create mode 100644 src/slalib/sun67.htx/img65.gif create mode 100644 src/slalib/sun67.htx/img66.gif create mode 100644 src/slalib/sun67.htx/img67.gif create mode 100644 src/slalib/sun67.htx/img68.gif create mode 100644 src/slalib/sun67.htx/img69.gif create mode 100644 src/slalib/sun67.htx/img7.gif create mode 100644 src/slalib/sun67.htx/img70.gif create mode 100644 src/slalib/sun67.htx/img71.gif create mode 100644 src/slalib/sun67.htx/img72.gif create mode 100644 src/slalib/sun67.htx/img73.gif create mode 100644 src/slalib/sun67.htx/img74.gif create mode 100644 src/slalib/sun67.htx/img75.gif create mode 100644 src/slalib/sun67.htx/img76.gif create mode 100644 src/slalib/sun67.htx/img77.gif create mode 100644 src/slalib/sun67.htx/img78.gif create mode 100644 src/slalib/sun67.htx/img79.gif create mode 100644 src/slalib/sun67.htx/img8.gif create mode 100644 src/slalib/sun67.htx/img80.gif create mode 100644 src/slalib/sun67.htx/img81.gif create mode 100644 src/slalib/sun67.htx/img82.gif create mode 100644 src/slalib/sun67.htx/img83.gif create mode 100644 src/slalib/sun67.htx/img84.gif create mode 100644 src/slalib/sun67.htx/img85.gif create mode 100644 src/slalib/sun67.htx/img86.gif create mode 100644 src/slalib/sun67.htx/img87.gif create mode 100644 src/slalib/sun67.htx/img88.gif create mode 100644 src/slalib/sun67.htx/img89.gif create mode 100644 src/slalib/sun67.htx/img9.gif create mode 100644 src/slalib/sun67.htx/img90.gif create mode 100644 src/slalib/sun67.htx/img91.gif create mode 100644 src/slalib/sun67.htx/img92.gif create mode 100644 src/slalib/sun67.htx/img93.gif create mode 100644 src/slalib/sun67.htx/img94.gif create mode 100644 src/slalib/sun67.htx/img95.gif create mode 100644 src/slalib/sun67.htx/img96.gif create mode 100644 src/slalib/sun67.htx/img97.gif create mode 100644 src/slalib/sun67.htx/img98.gif create mode 100644 src/slalib/sun67.htx/img99.gif create mode 100644 src/slalib/sun67.htx/index_motif.gif create mode 100644 src/slalib/sun67.htx/internals.pl create mode 100644 src/slalib/sun67.htx/invis_anchor.xbm create mode 100644 src/slalib/sun67.htx/labels.pl create mode 100644 src/slalib/sun67.htx/next_group_motif.gif create mode 100644 src/slalib/sun67.htx/next_group_motif_gr.gif create mode 100644 src/slalib/sun67.htx/next_motif.gif create mode 100644 src/slalib/sun67.htx/next_motif_gr.gif create mode 100644 src/slalib/sun67.htx/node1.html create mode 100644 src/slalib/sun67.htx/node10.html create mode 100644 src/slalib/sun67.htx/node100.html create mode 100644 src/slalib/sun67.htx/node101.html create mode 100644 src/slalib/sun67.htx/node102.html create mode 100644 src/slalib/sun67.htx/node103.html create mode 100644 src/slalib/sun67.htx/node104.html create mode 100644 src/slalib/sun67.htx/node105.html create mode 100644 src/slalib/sun67.htx/node106.html create mode 100644 src/slalib/sun67.htx/node107.html create mode 100644 src/slalib/sun67.htx/node108.html create mode 100644 src/slalib/sun67.htx/node109.html create mode 100644 src/slalib/sun67.htx/node11.html create mode 100644 src/slalib/sun67.htx/node110.html create mode 100644 src/slalib/sun67.htx/node111.html create mode 100644 src/slalib/sun67.htx/node112.html create mode 100644 src/slalib/sun67.htx/node113.html create mode 100644 src/slalib/sun67.htx/node114.html create mode 100644 src/slalib/sun67.htx/node115.html create mode 100644 src/slalib/sun67.htx/node116.html create mode 100644 src/slalib/sun67.htx/node117.html create mode 100644 src/slalib/sun67.htx/node118.html create mode 100644 src/slalib/sun67.htx/node119.html create mode 100644 src/slalib/sun67.htx/node12.html create mode 100644 src/slalib/sun67.htx/node120.html create mode 100644 src/slalib/sun67.htx/node121.html create mode 100644 src/slalib/sun67.htx/node122.html create mode 100644 src/slalib/sun67.htx/node123.html create mode 100644 src/slalib/sun67.htx/node124.html create mode 100644 src/slalib/sun67.htx/node125.html create mode 100644 src/slalib/sun67.htx/node126.html create mode 100644 src/slalib/sun67.htx/node127.html create mode 100644 src/slalib/sun67.htx/node128.html create mode 100644 src/slalib/sun67.htx/node129.html create mode 100644 src/slalib/sun67.htx/node13.html create mode 100644 src/slalib/sun67.htx/node130.html create mode 100644 src/slalib/sun67.htx/node131.html create mode 100644 src/slalib/sun67.htx/node132.html create mode 100644 src/slalib/sun67.htx/node133.html create mode 100644 src/slalib/sun67.htx/node134.html create mode 100644 src/slalib/sun67.htx/node135.html create mode 100644 src/slalib/sun67.htx/node136.html create mode 100644 src/slalib/sun67.htx/node137.html create mode 100644 src/slalib/sun67.htx/node138.html create mode 100644 src/slalib/sun67.htx/node139.html create mode 100644 src/slalib/sun67.htx/node14.html create mode 100644 src/slalib/sun67.htx/node140.html create mode 100644 src/slalib/sun67.htx/node141.html create mode 100644 src/slalib/sun67.htx/node142.html create mode 100644 src/slalib/sun67.htx/node143.html create mode 100644 src/slalib/sun67.htx/node144.html create mode 100644 src/slalib/sun67.htx/node145.html create mode 100644 src/slalib/sun67.htx/node146.html create mode 100644 src/slalib/sun67.htx/node147.html create mode 100644 src/slalib/sun67.htx/node148.html create mode 100644 src/slalib/sun67.htx/node149.html create mode 100644 src/slalib/sun67.htx/node15.html create mode 100644 src/slalib/sun67.htx/node150.html create mode 100644 src/slalib/sun67.htx/node151.html create mode 100644 src/slalib/sun67.htx/node152.html create mode 100644 src/slalib/sun67.htx/node153.html create mode 100644 src/slalib/sun67.htx/node154.html create mode 100644 src/slalib/sun67.htx/node155.html create mode 100644 src/slalib/sun67.htx/node156.html create mode 100644 src/slalib/sun67.htx/node157.html create mode 100644 src/slalib/sun67.htx/node158.html create mode 100644 src/slalib/sun67.htx/node159.html create mode 100644 src/slalib/sun67.htx/node16.html create mode 100644 src/slalib/sun67.htx/node160.html create mode 100644 src/slalib/sun67.htx/node161.html create mode 100644 src/slalib/sun67.htx/node162.html create mode 100644 src/slalib/sun67.htx/node163.html create mode 100644 src/slalib/sun67.htx/node164.html create mode 100644 src/slalib/sun67.htx/node165.html create mode 100644 src/slalib/sun67.htx/node166.html create mode 100644 src/slalib/sun67.htx/node167.html create mode 100644 src/slalib/sun67.htx/node168.html create mode 100644 src/slalib/sun67.htx/node169.html create mode 100644 src/slalib/sun67.htx/node17.html create mode 100644 src/slalib/sun67.htx/node170.html create mode 100644 src/slalib/sun67.htx/node171.html create mode 100644 src/slalib/sun67.htx/node172.html create mode 100644 src/slalib/sun67.htx/node173.html create mode 100644 src/slalib/sun67.htx/node174.html create mode 100644 src/slalib/sun67.htx/node175.html create mode 100644 src/slalib/sun67.htx/node176.html create mode 100644 src/slalib/sun67.htx/node177.html create mode 100644 src/slalib/sun67.htx/node178.html create mode 100644 src/slalib/sun67.htx/node179.html create mode 100644 src/slalib/sun67.htx/node18.html create mode 100644 src/slalib/sun67.htx/node180.html create mode 100644 src/slalib/sun67.htx/node181.html create mode 100644 src/slalib/sun67.htx/node182.html create mode 100644 src/slalib/sun67.htx/node183.html create mode 100644 src/slalib/sun67.htx/node184.html create mode 100644 src/slalib/sun67.htx/node185.html create mode 100644 src/slalib/sun67.htx/node186.html create mode 100644 src/slalib/sun67.htx/node187.html create mode 100644 src/slalib/sun67.htx/node188.html create mode 100644 src/slalib/sun67.htx/node189.html create mode 100644 src/slalib/sun67.htx/node19.html create mode 100644 src/slalib/sun67.htx/node190.html create mode 100644 src/slalib/sun67.htx/node191.html create mode 100644 src/slalib/sun67.htx/node192.html create mode 100644 src/slalib/sun67.htx/node193.html create mode 100644 src/slalib/sun67.htx/node194.html create mode 100644 src/slalib/sun67.htx/node195.html create mode 100644 src/slalib/sun67.htx/node196.html create mode 100644 src/slalib/sun67.htx/node197.html create mode 100644 src/slalib/sun67.htx/node198.html create mode 100644 src/slalib/sun67.htx/node199.html create mode 100644 src/slalib/sun67.htx/node2.html create mode 100644 src/slalib/sun67.htx/node20.html create mode 100644 src/slalib/sun67.htx/node200.html create mode 100644 src/slalib/sun67.htx/node201.html create mode 100644 src/slalib/sun67.htx/node202.html create mode 100644 src/slalib/sun67.htx/node203.html create mode 100644 src/slalib/sun67.htx/node204.html create mode 100644 src/slalib/sun67.htx/node205.html create mode 100644 src/slalib/sun67.htx/node206.html create mode 100644 src/slalib/sun67.htx/node207.html create mode 100644 src/slalib/sun67.htx/node208.html create mode 100644 src/slalib/sun67.htx/node209.html create mode 100644 src/slalib/sun67.htx/node21.html create mode 100644 src/slalib/sun67.htx/node210.html create mode 100644 src/slalib/sun67.htx/node211.html create mode 100644 src/slalib/sun67.htx/node212.html create mode 100644 src/slalib/sun67.htx/node213.html create mode 100644 src/slalib/sun67.htx/node214.html create mode 100644 src/slalib/sun67.htx/node215.html create mode 100644 src/slalib/sun67.htx/node216.html create mode 100644 src/slalib/sun67.htx/node217.html create mode 100644 src/slalib/sun67.htx/node218.html create mode 100644 src/slalib/sun67.htx/node219.html create mode 100644 src/slalib/sun67.htx/node22.html create mode 100644 src/slalib/sun67.htx/node220.html create mode 100644 src/slalib/sun67.htx/node221.html create mode 100644 src/slalib/sun67.htx/node222.html create mode 100644 src/slalib/sun67.htx/node223.html create mode 100644 src/slalib/sun67.htx/node224.html create mode 100644 src/slalib/sun67.htx/node225.html create mode 100644 src/slalib/sun67.htx/node226.html create mode 100644 src/slalib/sun67.htx/node227.html create mode 100644 src/slalib/sun67.htx/node228.html create mode 100644 src/slalib/sun67.htx/node229.html create mode 100644 src/slalib/sun67.htx/node23.html create mode 100644 src/slalib/sun67.htx/node24.html create mode 100644 src/slalib/sun67.htx/node25.html create mode 100644 src/slalib/sun67.htx/node26.html create mode 100644 src/slalib/sun67.htx/node27.html create mode 100644 src/slalib/sun67.htx/node28.html create mode 100644 src/slalib/sun67.htx/node29.html create mode 100644 src/slalib/sun67.htx/node3.html create mode 100644 src/slalib/sun67.htx/node30.html create mode 100644 src/slalib/sun67.htx/node31.html create mode 100644 src/slalib/sun67.htx/node32.html create mode 100644 src/slalib/sun67.htx/node33.html create mode 100644 src/slalib/sun67.htx/node34.html create mode 100644 src/slalib/sun67.htx/node35.html create mode 100644 src/slalib/sun67.htx/node36.html create mode 100644 src/slalib/sun67.htx/node37.html create mode 100644 src/slalib/sun67.htx/node38.html create mode 100644 src/slalib/sun67.htx/node39.html create mode 100644 src/slalib/sun67.htx/node4.html create mode 100644 src/slalib/sun67.htx/node40.html create mode 100644 src/slalib/sun67.htx/node41.html create mode 100644 src/slalib/sun67.htx/node42.html create mode 100644 src/slalib/sun67.htx/node43.html create mode 100644 src/slalib/sun67.htx/node44.html create mode 100644 src/slalib/sun67.htx/node45.html create mode 100644 src/slalib/sun67.htx/node46.html create mode 100644 src/slalib/sun67.htx/node47.html create mode 100644 src/slalib/sun67.htx/node48.html create mode 100644 src/slalib/sun67.htx/node49.html create mode 100644 src/slalib/sun67.htx/node5.html create mode 100644 src/slalib/sun67.htx/node50.html create mode 100644 src/slalib/sun67.htx/node51.html create mode 100644 src/slalib/sun67.htx/node52.html create mode 100644 src/slalib/sun67.htx/node53.html create mode 100644 src/slalib/sun67.htx/node54.html create mode 100644 src/slalib/sun67.htx/node55.html create mode 100644 src/slalib/sun67.htx/node56.html create mode 100644 src/slalib/sun67.htx/node57.html create mode 100644 src/slalib/sun67.htx/node58.html create mode 100644 src/slalib/sun67.htx/node59.html create mode 100644 src/slalib/sun67.htx/node6.html create mode 100644 src/slalib/sun67.htx/node60.html create mode 100644 src/slalib/sun67.htx/node61.html create mode 100644 src/slalib/sun67.htx/node62.html create mode 100644 src/slalib/sun67.htx/node63.html create mode 100644 src/slalib/sun67.htx/node64.html create mode 100644 src/slalib/sun67.htx/node65.html create mode 100644 src/slalib/sun67.htx/node66.html create mode 100644 src/slalib/sun67.htx/node67.html create mode 100644 src/slalib/sun67.htx/node68.html create mode 100644 src/slalib/sun67.htx/node69.html create mode 100644 src/slalib/sun67.htx/node7.html create mode 100644 src/slalib/sun67.htx/node70.html create mode 100644 src/slalib/sun67.htx/node71.html create mode 100644 src/slalib/sun67.htx/node72.html create mode 100644 src/slalib/sun67.htx/node73.html create mode 100644 src/slalib/sun67.htx/node74.html create mode 100644 src/slalib/sun67.htx/node75.html create mode 100644 src/slalib/sun67.htx/node76.html create mode 100644 src/slalib/sun67.htx/node77.html create mode 100644 src/slalib/sun67.htx/node78.html create mode 100644 src/slalib/sun67.htx/node79.html create mode 100644 src/slalib/sun67.htx/node8.html create mode 100644 src/slalib/sun67.htx/node80.html create mode 100644 src/slalib/sun67.htx/node81.html create mode 100644 src/slalib/sun67.htx/node82.html create mode 100644 src/slalib/sun67.htx/node83.html create mode 100644 src/slalib/sun67.htx/node84.html create mode 100644 src/slalib/sun67.htx/node85.html create mode 100644 src/slalib/sun67.htx/node86.html create mode 100644 src/slalib/sun67.htx/node87.html create mode 100644 src/slalib/sun67.htx/node88.html create mode 100644 src/slalib/sun67.htx/node89.html create mode 100644 src/slalib/sun67.htx/node9.html create mode 100644 src/slalib/sun67.htx/node90.html create mode 100644 src/slalib/sun67.htx/node91.html create mode 100644 src/slalib/sun67.htx/node92.html create mode 100644 src/slalib/sun67.htx/node93.html create mode 100644 src/slalib/sun67.htx/node94.html create mode 100644 src/slalib/sun67.htx/node95.html create mode 100644 src/slalib/sun67.htx/node96.html create mode 100644 src/slalib/sun67.htx/node97.html create mode 100644 src/slalib/sun67.htx/node98.html create mode 100644 src/slalib/sun67.htx/node99.html create mode 100644 src/slalib/sun67.htx/orangeball.gif create mode 100644 src/slalib/sun67.htx/pinkball.gif create mode 100644 src/slalib/sun67.htx/previous_group_motif.gif create mode 100644 src/slalib/sun67.htx/previous_group_motif_gr.gif create mode 100644 src/slalib/sun67.htx/previous_motif.gif create mode 100644 src/slalib/sun67.htx/previous_motif_gr.gif create mode 100644 src/slalib/sun67.htx/purpleball.gif create mode 100644 src/slalib/sun67.htx/redball.gif create mode 100755 src/slalib/sun67.htx/source.gif create mode 100644 src/slalib/sun67.htx/sun67.css create mode 100644 src/slalib/sun67.htx/sun67.html create mode 100644 src/slalib/sun67.htx/up_motif.gif create mode 100644 src/slalib/sun67.htx/up_motif_gr.gif create mode 100644 src/slalib/sun67.htx/whiteball.gif create mode 100644 src/slalib/sun67.htx/yellowball.gif create mode 100644 src/slalib/sun67.htx_tar create mode 100644 src/slalib/sun67.tex create mode 100644 src/slalib/supgal.f create mode 100644 src/slalib/svd.f create mode 100644 src/slalib/svdcov.f create mode 100644 src/slalib/svdsol.f create mode 100644 src/slalib/tp2s.f create mode 100644 src/slalib/tp2v.f create mode 100644 src/slalib/tps2c.f create mode 100644 src/slalib/tpv2c.f create mode 100644 src/slalib/ue2el.f create mode 100644 src/slalib/ue2pv.f create mode 100644 src/slalib/unpcd.f create mode 100644 src/slalib/v2tp.f create mode 100644 src/slalib/vdv.f create mode 100644 src/slalib/vn.f create mode 100644 src/slalib/vxv.f create mode 100644 src/slalib/wait.f_alpha_OSF1 create mode 100644 src/slalib/wait.f_convex create mode 100644 src/slalib/wait.f_ix86_Linux create mode 100644 src/slalib/wait.f_mips create mode 100644 src/slalib/wait.f_pcm create mode 100644 src/slalib/wait.f_sun4 create mode 100644 src/slalib/wait.f_sun4_Solaris create mode 100644 src/slalib/wait.f_vax create mode 100644 src/slalib/wait.f_x86_64 create mode 100644 src/slalib/xy2xy.f create mode 100644 src/slalib/zd.f (limited to 'src/slalib') diff --git a/src/slalib/Makefile.am b/src/slalib/Makefile.am new file mode 100644 index 0000000..895eea9 --- /dev/null +++ b/src/slalib/Makefile.am @@ -0,0 +1,187 @@ +lib_LTLIBRARIES = libsla.la +libsla_la_SOURCES = \ + addet.f \ + afin.f \ + airmas.f \ + altaz.f \ + amp.f \ + ampqk.f \ + aop.f \ + aoppa.f \ + aoppat.f \ + aopqk.f \ + atmdsp.f \ + atms.f \ + atmt.f \ + av2m.f \ + bear.f \ + caf2r.f \ + caldj.f \ + calyd.f \ + cc2s.f \ + cc62s.f \ + cd2tf.f \ + cldj.f \ + clyd.f \ + combn.f \ + cr2af.f \ + cr2tf.f \ + cs2c.f \ + cs2c6.f \ + ctf2d.f \ + ctf2r.f \ + daf2r.f \ + dafin.f \ + dat.f \ + dav2m.f \ + dbear.f \ + dbjin.f \ + dc62s.f \ + dcc2s.f \ + dcmpf.f \ + dcs2c.f \ + dd2tf.f \ + de2h.f \ + deuler.f \ + dfltin.f \ + dh2e.f \ + dimxv.f \ + djcal.f \ + djcl.f \ + dm2av.f \ + dmat.f \ + dmoon.f \ + dmxm.f \ + dmxv.f \ + dpav.f \ + dr2af.f \ + dr2tf.f \ + drange.f \ + dranrm.f \ + ds2c6.f \ + ds2tp.f \ + dsep.f \ + dt.f \ + dtf2d.f \ + dtf2r.f \ + dtp2s.f \ + dtp2v.f \ + dtps2c.f \ + dtpv2c.f \ + dtt.f \ + dv2tp.f \ + dvdv.f \ + dvn.f \ + dvxv.f \ + e2h.f \ + earth.f \ + ecleq.f \ + ecmat.f \ + ecor.f \ + eg50.f \ + el2ue.f \ + epb.f \ + epb2d.f \ + epco.f \ + epj.f \ + epj2d.f \ + eqecl.f \ + eqeqx.f \ + eqgal.f \ + etrms.f \ + euler.f \ + evp.f \ + fitxy.f \ + fk425.f \ + fk45z.f \ + fk524.f \ + fk52h.f \ + fk54z.f \ + fk5hz.f \ + flotin.f \ + galeq.f \ + galsup.f \ + ge50.f \ + geoc.f \ + gmst.f \ + gmsta.f \ + h2e.f \ + h2fk5.f \ + hfk5z.f \ + idchf.f \ + idchi.f \ + imxv.f \ + intin.f \ + invf.f \ + kbj.f \ + m2av.f \ + map.f \ + mappa.f \ + mapqk.f \ + mapqkz.f \ + moon.f \ + mxm.f \ + mxv.f \ + nut.f \ + nutc.f \ + oap.f \ + oapqk.f \ + obs.f \ + pa.f \ + pav.f \ + pcd.f \ + pda2h.f \ + pdq2h.f \ + permut.f \ + pertel.f \ + pertue.f \ + planel.f \ + planet.f \ + plante.f \ + pm.f \ + polmo.f \ + prebn.f \ + prec.f \ + precl.f \ + preces.f \ + prenut.f \ + pv2el.f \ + pv2ue.f \ + pvobs.f \ + pxy.f \ + range.f \ + ranorm.f \ + rcc.f \ + rdplan.f \ + refco.f \ + refro.f \ + refv.f \ + refz.f \ + rverot.f \ + rvgalc.f \ + rvlg.f \ + rvlsrd.f \ + rvlsrk.f \ + s2tp.f \ + sep.f \ + smat.f \ + subet.f \ + supgal.f \ + svd.f \ + svdcov.f \ + svdsol.f \ + tp2s.f \ + tp2v.f \ + tps2c.f \ + tpv2c.f \ + ue2el.f \ + ue2pv.f \ + unpcd.f \ + v2tp.f \ + vdv.f \ + vn.f \ + vxv.f \ + xy2xy.f \ + zd.f + +AM_CFLAGS = -I../include -I./ diff --git a/src/slalib/Makefile.in b/src/slalib/Makefile.in new file mode 100644 index 0000000..718fd59 --- /dev/null +++ b/src/slalib/Makefile.in @@ -0,0 +1,830 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = src/slalib +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(libdir)" +LTLIBRARIES = $(lib_LTLIBRARIES) +libsla_la_LIBADD = +am_libsla_la_OBJECTS = addet.lo afin.lo airmas.lo altaz.lo amp.lo \ + ampqk.lo aop.lo aoppa.lo aoppat.lo aopqk.lo atmdsp.lo atms.lo \ + atmt.lo av2m.lo bear.lo caf2r.lo caldj.lo calyd.lo cc2s.lo \ + cc62s.lo cd2tf.lo cldj.lo clyd.lo combn.lo cr2af.lo cr2tf.lo \ + cs2c.lo cs2c6.lo ctf2d.lo ctf2r.lo daf2r.lo dafin.lo dat.lo \ + dav2m.lo dbear.lo dbjin.lo dc62s.lo dcc2s.lo dcmpf.lo dcs2c.lo \ + dd2tf.lo de2h.lo deuler.lo dfltin.lo dh2e.lo dimxv.lo djcal.lo \ + djcl.lo dm2av.lo dmat.lo dmoon.lo dmxm.lo dmxv.lo dpav.lo \ + dr2af.lo dr2tf.lo drange.lo dranrm.lo ds2c6.lo ds2tp.lo \ + dsep.lo dt.lo dtf2d.lo dtf2r.lo dtp2s.lo dtp2v.lo dtps2c.lo \ + dtpv2c.lo dtt.lo dv2tp.lo dvdv.lo dvn.lo dvxv.lo e2h.lo \ + earth.lo ecleq.lo ecmat.lo ecor.lo eg50.lo el2ue.lo epb.lo \ + epb2d.lo epco.lo epj.lo epj2d.lo eqecl.lo eqeqx.lo eqgal.lo \ + etrms.lo euler.lo evp.lo fitxy.lo fk425.lo fk45z.lo fk524.lo \ + fk52h.lo fk54z.lo fk5hz.lo flotin.lo galeq.lo galsup.lo \ + ge50.lo geoc.lo gmst.lo gmsta.lo h2e.lo h2fk5.lo hfk5z.lo \ + idchf.lo idchi.lo imxv.lo intin.lo invf.lo kbj.lo m2av.lo \ + map.lo mappa.lo mapqk.lo mapqkz.lo moon.lo mxm.lo mxv.lo \ + nut.lo nutc.lo oap.lo oapqk.lo obs.lo pa.lo pav.lo pcd.lo \ + pda2h.lo pdq2h.lo permut.lo pertel.lo pertue.lo planel.lo \ + planet.lo plante.lo pm.lo polmo.lo prebn.lo prec.lo precl.lo \ + preces.lo prenut.lo pv2el.lo pv2ue.lo pvobs.lo pxy.lo range.lo \ + ranorm.lo rcc.lo rdplan.lo refco.lo refro.lo refv.lo refz.lo \ + rverot.lo rvgalc.lo rvlg.lo rvlsrd.lo rvlsrk.lo s2tp.lo sep.lo \ + smat.lo subet.lo supgal.lo svd.lo svdcov.lo svdsol.lo tp2s.lo \ + tp2v.lo tps2c.lo tpv2c.lo ue2el.lo ue2pv.lo unpcd.lo v2tp.lo \ + vdv.lo vn.lo vxv.lo xy2xy.lo zd.lo +libsla_la_OBJECTS = $(am_libsla_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) +F77COMPILE = $(F77) $(AM_FFLAGS) $(FFLAGS) +LTF77COMPILE = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS) +AM_V_F77 = $(am__v_F77_@AM_V@) +am__v_F77_ = $(am__v_F77_@AM_DEFAULT_V@) +am__v_F77_0 = @echo " F77 " $@; +am__v_F77_1 = +F77LD = $(F77) +F77LINK = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(F77LD) $(AM_FFLAGS) $(FFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_F77LD = $(am__v_F77LD_@AM_V@) +am__v_F77LD_ = $(am__v_F77LD_@AM_DEFAULT_V@) +am__v_F77LD_0 = @echo " F77LD " $@; +am__v_F77LD_1 = +SOURCES = $(libsla_la_SOURCES) +DIST_SOURCES = $(libsla_la_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +F77 = @F77@ +FFLAGS = @FFLAGS@ +FGREP = @FGREP@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_F77 = @ac_ct_F77@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +lib_LTLIBRARIES = libsla.la +libsla_la_SOURCES = \ + addet.f \ + afin.f \ + airmas.f \ + altaz.f \ + amp.f \ + ampqk.f \ + aop.f \ + aoppa.f \ + aoppat.f \ + aopqk.f \ + atmdsp.f \ + atms.f \ + atmt.f \ + av2m.f \ + bear.f \ + caf2r.f \ + caldj.f \ + calyd.f \ + cc2s.f \ + cc62s.f \ + cd2tf.f \ + cldj.f \ + clyd.f \ + combn.f \ + cr2af.f \ + cr2tf.f \ + cs2c.f \ + cs2c6.f \ + ctf2d.f \ + ctf2r.f \ + daf2r.f \ + dafin.f \ + dat.f \ + dav2m.f \ + dbear.f \ + dbjin.f \ + dc62s.f \ + dcc2s.f \ + dcmpf.f \ + dcs2c.f \ + dd2tf.f \ + de2h.f \ + deuler.f \ + dfltin.f \ + dh2e.f \ + dimxv.f \ + djcal.f \ + djcl.f \ + dm2av.f \ + dmat.f \ + dmoon.f \ + dmxm.f \ + dmxv.f \ + dpav.f \ + dr2af.f \ + dr2tf.f \ + drange.f \ + dranrm.f \ + ds2c6.f \ + ds2tp.f \ + dsep.f \ + dt.f \ + dtf2d.f \ + dtf2r.f \ + dtp2s.f \ + dtp2v.f \ + dtps2c.f \ + dtpv2c.f \ + dtt.f \ + dv2tp.f \ + dvdv.f \ + dvn.f \ + dvxv.f \ + e2h.f \ + earth.f \ + ecleq.f \ + ecmat.f \ + ecor.f \ + eg50.f \ + el2ue.f \ + epb.f \ + epb2d.f \ + epco.f \ + epj.f \ + epj2d.f \ + eqecl.f \ + eqeqx.f \ + eqgal.f \ + etrms.f \ + euler.f \ + evp.f \ + fitxy.f \ + fk425.f \ + fk45z.f \ + fk524.f \ + fk52h.f \ + fk54z.f \ + fk5hz.f \ + flotin.f \ + galeq.f \ + galsup.f \ + ge50.f \ + geoc.f \ + gmst.f \ + gmsta.f \ + h2e.f \ + h2fk5.f \ + hfk5z.f \ + idchf.f \ + idchi.f \ + imxv.f \ + intin.f \ + invf.f \ + kbj.f \ + m2av.f \ + map.f \ + mappa.f \ + mapqk.f \ + mapqkz.f \ + moon.f \ + mxm.f \ + mxv.f \ + nut.f \ + nutc.f \ + oap.f \ + oapqk.f \ + obs.f \ + pa.f \ + pav.f \ + pcd.f \ + pda2h.f \ + pdq2h.f \ + permut.f \ + pertel.f \ + pertue.f \ + planel.f \ + planet.f \ + plante.f \ + pm.f \ + polmo.f \ + prebn.f \ + prec.f \ + precl.f \ + preces.f \ + prenut.f \ + pv2el.f \ + pv2ue.f \ + pvobs.f \ + pxy.f \ + range.f \ + ranorm.f \ + rcc.f \ + rdplan.f \ + refco.f \ + refro.f \ + refv.f \ + refz.f \ + rverot.f \ + rvgalc.f \ + rvlg.f \ + rvlsrd.f \ + rvlsrk.f \ + s2tp.f \ + sep.f \ + smat.f \ + subet.f \ + supgal.f \ + svd.f \ + svdcov.f \ + svdsol.f \ + tp2s.f \ + tp2v.f \ + tps2c.f \ + tpv2c.f \ + ue2el.f \ + ue2pv.f \ + unpcd.f \ + v2tp.f \ + vdv.f \ + vn.f \ + vxv.f \ + xy2xy.f \ + zd.f + +AM_CFLAGS = -I../include -I./ +all: all-am + +.SUFFIXES: +.SUFFIXES: .f .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/slalib/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign src/slalib/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +install-libLTLIBRARIES: $(lib_LTLIBRARIES) + @$(NORMAL_INSTALL) + @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ + list2=; for p in $$list; do \ + if test -f $$p; then \ + list2="$$list2 $$p"; \ + else :; fi; \ + done; \ + test -z "$$list2" || { \ + echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ + } + +uninstall-libLTLIBRARIES: + @$(NORMAL_UNINSTALL) + @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ + for p in $$list; do \ + $(am__strip_dir) \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ + done + +clean-libLTLIBRARIES: + -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) + @list='$(lib_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +libsla.la: $(libsla_la_OBJECTS) $(libsla_la_DEPENDENCIES) $(EXTRA_libsla_la_DEPENDENCIES) + $(AM_V_F77LD)$(F77LINK) -rpath $(libdir) $(libsla_la_OBJECTS) $(libsla_la_LIBADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +.f.o: + $(AM_V_F77)$(F77COMPILE) -c -o $@ $< + +.f.obj: + $(AM_V_F77)$(F77COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.f.lo: + $(AM_V_F77)$(LTF77COMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(LTLIBRARIES) +installdirs: + for dir in "$(DESTDIR)$(libdir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ + mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-libLTLIBRARIES + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-libLTLIBRARIES + +.MAKE: install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libLTLIBRARIES clean-libtool cscopelist-am ctags \ + ctags-am distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-libLTLIBRARIES install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-libLTLIBRARIES + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/src/slalib/addet.f b/src/slalib/addet.f new file mode 100644 index 0000000..c039aff --- /dev/null +++ b/src/slalib/addet.f @@ -0,0 +1,67 @@ + SUBROUTINE sla_ADDET (RM, DM, EQ, RC, DC) +*+ +* - - - - - - +* A D D E T +* - - - - - - +* +* Add the E-terms (elliptic component of annual aberration) +* to a pre IAU 1976 mean place to conform to the old +* catalogue convention (double precision) +* +* Given: +* RM,DM dp RA,Dec (radians) without E-terms +* EQ dp Besselian epoch of mean equator and equinox +* +* Returned: +* RC,DC dp RA,Dec (radians) with E-terms included +* +* Note: +* +* Most star positions from pre-1984 optical catalogues (or +* derived from astrometry using such stars) embody the +* E-terms. If it is necessary to convert a formal mean +* place (for example a pulsar timing position) to one +* consistent with such a star catalogue, then the RA,Dec +* should be adjusted using this routine. +* +* Reference: +* Explanatory Supplement to the Astronomical Ephemeris, +* section 2D, page 48. +* +* Called: sla_ETRMS, sla_DCS2C, sla_DCC2S, sla_DRANRM, sla_DRANGE +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RM,DM,EQ,RC,DC + + DOUBLE PRECISION sla_DRANRM + + DOUBLE PRECISION A(3),V(3) + + INTEGER I + + + +* E-terms vector + CALL sla_ETRMS(EQ,A) + +* Spherical to Cartesian + CALL sla_DCS2C(RM,DM,V) + +* Include the E-terms + DO I=1,3 + V(I)=V(I)+A(I) + END DO + +* Cartesian to spherical + CALL sla_DCC2S(V,RC,DC) + +* Bring RA into conventional range + RC=sla_DRANRM(RC) + + END diff --git a/src/slalib/afin.f b/src/slalib/afin.f new file mode 100644 index 0000000..2308c74 --- /dev/null +++ b/src/slalib/afin.f @@ -0,0 +1,102 @@ + SUBROUTINE sla_AFIN (STRING, IPTR, A, J) +*+ +* - - - - - +* A F I N +* - - - - - +* +* Sexagesimal character string to angle (single precision) +* +* Given: +* STRING c*(*) string containing deg, arcmin, arcsec fields +* IPTR i pointer to start of decode (1st = 1) +* +* Returned: +* IPTR i advanced past the decoded angle +* A r angle in radians +* J i status: 0 = OK +* +1 = default, A unchanged +* -1 = bad degrees ) +* -2 = bad arcminutes ) (note 3) +* -3 = bad arcseconds ) +* +* Example: +* +* argument before after +* +* STRING '-57 17 44.806 12 34 56.7' unchanged +* IPTR 1 16 (points to 12...) +* A ? -1.00000 +* J ? 0 +* +* A further call to sla_AFIN, without adjustment of IPTR, will +* decode the second angle, 12deg 34min 56.7sec. +* +* Notes: +* +* 1) The first three "fields" in STRING are degrees, arcminutes, +* arcseconds, separated by spaces or commas. The degrees field +* may be signed, but not the others. The decoding is carried +* out by the DFLTIN routine and is free-format. +* +* 2) Successive fields may be absent, defaulting to zero. For +* zero status, the only combinations allowed are degrees alone, +* degrees and arcminutes, and all three fields present. If all +* three fields are omitted, a status of +1 is returned and A is +* unchanged. In all other cases A is changed. +* +* 3) Range checking: +* +* The degrees field is not range checked. However, it is +* expected to be integral unless the other two fields are +* absent. +* +* The arcminutes field is expected to be 0-59, and integral if +* the arcseconds field is present. If the arcseconds field +* is absent, the arcminutes is expected to be 0-59.9999... +* +* The arcseconds field is expected to be 0-59.9999... +* +* 4) Decoding continues even when a check has failed. Under these +* circumstances the field takes the supplied value, defaulting +* to zero, and the result A is computed and returned. +* +* 5) Further fields after the three expected ones are not treated +* as an error. The pointer IPTR is left in the correct state +* for further decoding with the present routine or with DFLTIN +* etc. See the example, above. +* +* 6) If STRING contains hours, minutes, seconds instead of degrees +* etc, or if the required units are turns (or days) instead of +* radians, the result A should be multiplied as follows: +* +* for to obtain multiply +* STRING A in A by +* +* d ' " radians 1 = 1.0 +* d ' " turns 1/2pi = 0.1591549430918953358 +* h m s radians 15 = 15.0 +* h m s days 15/2pi = 2.3873241463784300365 +* +* Called: sla_DAFIN +* +* P.T.Wallace Starlink 13 September 1990 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) STRING + INTEGER IPTR + REAL A + INTEGER J + + DOUBLE PRECISION AD + + + +* Call the double precision version + CALL sla_DAFIN(STRING,IPTR,AD,J) + IF (J.LE.0) A=REAL(AD) + + END diff --git a/src/slalib/airmas.f b/src/slalib/airmas.f new file mode 100644 index 0000000..12431c8 --- /dev/null +++ b/src/slalib/airmas.f @@ -0,0 +1,58 @@ + DOUBLE PRECISION FUNCTION sla_AIRMAS (ZD) +*+ +* - - - - - - - +* A I R M A S +* - - - - - - - +* +* Air mass at given zenith distance (double precision) +* +* Given: +* ZD d Observed zenith distance (radians) +* +* The result is an estimate of the air mass, in units of that +* at the zenith. +* +* Notes: +* +* 1) The "observed" zenith distance referred to above means "as +* affected by refraction". +* +* 2) Uses Hardie's (1962) polynomial fit to Bemporad's data for +* the relative air mass, X, in units of thickness at the zenith +* as tabulated by Schoenberg (1929). This is adequate for all +* normal needs as it is accurate to better than 0.1% up to X = +* 6.8 and better than 1% up to X = 10. Bemporad's tabulated +* values are unlikely to be trustworthy to such accuracy +* because of variations in density, pressure and other +* conditions in the atmosphere from those assumed in his work. +* +* 3) The sign of the ZD is ignored. +* +* 4) At zenith distances greater than about ZD = 87 degrees the +* air mass is held constant to avoid arithmetic overflows. +* +* References: +* Hardie, R.H., 1962, in "Astronomical Techniques" +* ed. W.A. Hiltner, University of Chicago Press, p180. +* Schoenberg, E., 1929, Hdb. d. Ap., +* Berlin, Julius Springer, 2, 268. +* +* Original code by P.W.Hill, St Andrews +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION ZD + + DOUBLE PRECISION SECZM1 + + + SECZM1 = 1D0/(COS(MIN(1.52D0,ABS(ZD))))-1D0 + sla_AIRMAS = 1D0 + SECZM1*(0.9981833D0 + : - SECZM1*(0.002875D0 + 0.0008083D0*SECZM1)) + + END diff --git a/src/slalib/altaz.f b/src/slalib/altaz.f new file mode 100644 index 0000000..3a7124b --- /dev/null +++ b/src/slalib/altaz.f @@ -0,0 +1,145 @@ + SUBROUTINE sla_ALTAZ (HA, DEC, PHI, + : AZ, AZD, AZDD, EL, ELD, ELDD, PA, PAD, PADD) +*+ +* - - - - - - +* A L T A Z +* - - - - - - +* +* Positions, velocities and accelerations for an altazimuth +* telescope mount. +* +* (double precision) +* +* Given: +* HA d hour angle +* DEC d declination +* PHI d observatory latitude +* +* Returned: +* AZ d azimuth +* AZD d " velocity +* AZDD d " acceleration +* EL d elevation +* ELD d " velocity +* ELDD d " acceleration +* PA d parallactic angle +* PAD d " " velocity +* PADD d " " acceleration +* +* Notes: +* +* 1) Natural units are used throughout. HA, DEC, PHI, AZ, EL +* and ZD are in radians. The velocities and accelerations +* assume constant declination and constant rate of change of +* hour angle (as for tracking a star); the units of AZD, ELD +* and PAD are radians per radian of HA, while the units of AZDD, +* ELDD and PADD are radians per radian of HA squared. To +* convert into practical degree- and second-based units: +* +* angles * 360/2pi -> degrees +* velocities * (2pi/86400)*(360/2pi) -> degree/sec +* accelerations * ((2pi/86400)**2)*(360/2pi) -> degree/sec/sec +* +* Note that the seconds here are sidereal rather than SI. One +* sidereal second is about 0.99727 SI seconds. +* +* The velocity and acceleration factors assume the sidereal +* tracking case. Their respective numerical values are (exactly) +* 1/240 and (approximately) 1/3300236.9. +* +* 2) Azimuth is returned in the range 0-2pi; north is zero, +* and east is +pi/2. Elevation and parallactic angle are +* returned in the range +/-pi/2. Position angle is +ve +* for a star west of the meridian and is the angle NP-star-zenith. +* +* 3) The latitude is geodetic as opposed to geocentric. The +* hour angle and declination are topocentric. Refraction and +* deficiencies in the telescope mounting are ignored. The +* purpose of the routine is to give the general form of the +* quantities. The details of a real telescope could profoundly +* change the results, especially close to the zenith. +* +* 4) No range checking of arguments is carried out. +* +* 5) In applications which involve many such calculations, rather +* than calling the present routine it will be more efficient to +* use inline code, having previously computed fixed terms such +* as sine and cosine of latitude, and (for tracking a star) +* sine and cosine of declination. +* +* P.T.Wallace Starlink 14 March 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION HA,DEC,PHI,AZ,AZD,AZDD,EL,ELD,ELDD,PA,PAD,PADD + + DOUBLE PRECISION DPI,D2PI,TINY + PARAMETER (DPI=3.1415926535897932384626433832795D0, + : D2PI=6.283185307179586476925286766559D0, + : TINY=1D-30) + + DOUBLE PRECISION SH,CH,SD,CD,SP,CP,CHCD,SDCP,X,Y,Z,RSQ,R,A,E,C,S, + : Q,QD,AD,ED,EDR,ADD,EDD,QDD + + +* Useful functions + SH=SIN(HA) + CH=COS(HA) + SD=SIN(DEC) + CD=COS(DEC) + SP=SIN(PHI) + CP=COS(PHI) + CHCD=CH*CD + SDCP=SD*CP + X=-CHCD*SP+SDCP + Y=-SH*CD + Z=CHCD*CP+SD*SP + RSQ=X*X+Y*Y + R=SQRT(RSQ) + +* Azimuth and elevation + IF (RSQ.EQ.0D0) THEN + A=0D0 + ELSE + A=ATAN2(Y,X) + END IF + IF (A.LT.0D0) A=A+D2PI + E=ATAN2(Z,R) + +* Parallactic angle + C=CD*SP-CH*SDCP + S=SH*CP + IF (C*C+S*S.GT.0) THEN + Q=ATAN2(S,C) + ELSE + Q=DPI-HA + END IF + +* Velocities and accelerations (clamped at zenith/nadir) + IF (RSQ.LT.TINY) THEN + RSQ=TINY + R=SQRT(RSQ) + END IF + QD=-X*CP/RSQ + AD=SP+Z*QD + ED=CP*Y/R + EDR=ED/R + ADD=EDR*(Z*SP+(2D0-RSQ)*QD) + EDD=-R*QD*AD + QDD=EDR*(SP+2D0*Z*QD) + +* Results + AZ=A + AZD=AD + AZDD=ADD + EL=E + ELD=ED + ELDD=EDD + PA=Q + PAD=QD + PADD=QDD + + END diff --git a/src/slalib/amp.f b/src/slalib/amp.f new file mode 100644 index 0000000..6feb570 --- /dev/null +++ b/src/slalib/amp.f @@ -0,0 +1,68 @@ + SUBROUTINE sla_AMP (RA, DA, DATE, EQ, RM, DM) +*+ +* - - - - +* A M P +* - - - - +* +* Convert star RA,Dec from geocentric apparent to mean place +* +* The mean coordinate system is the post IAU 1976 system, +* loosely called FK5. +* +* Given: +* RA d apparent RA (radians) +* DA d apparent Dec (radians) +* DATE d TDB for apparent place (JD-2400000.5) +* EQ d equinox: Julian epoch of mean place +* +* Returned: +* RM d mean RA (radians) +* DM d mean Dec (radians) +* +* References: +* 1984 Astronomical Almanac, pp B39-B41. +* (also Lederle & Schwan, Astron. Astrophys. 134, +* 1-6, 1984) +* +* Notes: +* +* 1) The distinction between the required TDB and TT is +* always negligible. Moreover, for all but the most +* critical applications UTC is adequate. +* +* 2) The accuracy is limited by the routine sla_EVP, called +* by sla_MAPPA, which computes the Earth position and +* velocity using the methods of Stumpff. The maximum +* error is about 0.3 milliarcsecond. +* +* 3) Iterative techniques are used for the aberration and +* light deflection corrections so that the routines +* sla_AMP (or sla_AMPQK) and sla_MAP (or sla_MAPQK) are +* accurate inverses; even at the edge of the Sun's disc +* the discrepancy is only about 1 nanoarcsecond. +* +* 4) Where multiple apparent places are to be converted to +* mean places, for a fixed date and equinox, it is more +* efficient to use the sla_MAPPA routine to compute the +* required parameters once, followed by one call to +* sla_AMPQK per star. +* +* Called: sla_MAPPA, sla_AMPQK +* +* P.T.Wallace Starlink 19 January 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RA,DA,DATE,EQ,RM,DM + + DOUBLE PRECISION AMPRMS(21) + + + + CALL sla_MAPPA(EQ,DATE,AMPRMS) + CALL sla_AMPQK(RA,DA,AMPRMS,RM,DM) + + END diff --git a/src/slalib/ampqk.f b/src/slalib/ampqk.f new file mode 100644 index 0000000..6b94db1 --- /dev/null +++ b/src/slalib/ampqk.f @@ -0,0 +1,127 @@ + SUBROUTINE sla_AMPQK (RA, DA, AMPRMS, RM, DM) +*+ +* - - - - - - +* A M P Q K +* - - - - - - +* +* Convert star RA,Dec from geocentric apparent to mean place +* +* The mean coordinate system is the post IAU 1976 system, +* loosely called FK5. +* +* Use of this routine is appropriate when efficiency is important +* and where many star positions are all to be transformed for +* one epoch and equinox. The star-independent parameters can be +* obtained by calling the sla_MAPPA routine. +* +* Given: +* RA d apparent RA (radians) +* DA d apparent Dec (radians) +* +* AMPRMS d(21) star-independent mean-to-apparent parameters: +* +* (1) time interval for proper motion (Julian years) +* (2-4) barycentric position of the Earth (AU) +* (5-7) heliocentric direction of the Earth (unit vector) +* (8) (grav rad Sun)*2/(Sun-Earth distance) +* (9-11) ABV: barycentric Earth velocity in units of c +* (12) sqrt(1-v**2) where v=modulus(ABV) +* (13-21) precession/nutation (3,3) matrix +* +* Returned: +* RM d mean RA (radians) +* DM d mean Dec (radians) +* +* References: +* 1984 Astronomical Almanac, pp B39-B41. +* (also Lederle & Schwan, Astron. Astrophys. 134, +* 1-6, 1984) +* +* Notes: +* +* 1) The accuracy is limited by the routine sla_EVP, called +* by sla_MAPPA, which computes the Earth position and +* velocity using the methods of Stumpff. The maximum +* error is about 0.3 milliarcsecond. +* +* 2) Iterative techniques are used for the aberration and +* light deflection corrections so that the routines +* sla_AMP (or sla_AMPQK) and sla_MAP (or sla_MAPQK) are +* accurate inverses; even at the edge of the Sun's disc +* the discrepancy is only about 1 nanoarcsecond. +* +* Called: sla_DCS2C, sla_DIMXV, sla_DVDV, sla_DVN, sla_DCC2S, +* sla_DRANRM +* +* P.T.Wallace Starlink 21 June 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RA,DA,AMPRMS(21),RM,DM + + INTEGER I,J + + DOUBLE PRECISION GR2E,AB1,EHN(3),ABV(3),P3(3),P2(3), + : AB1P1,P1DV,P1DVP1,P1(3),W,PDE,PDEP1,P(3) + + DOUBLE PRECISION sla_DVDV,sla_DRANRM + + + +* Unpack scalar and vector parameters + GR2E = AMPRMS(8) + AB1 = AMPRMS(12) + DO I=1,3 + EHN(I) = AMPRMS(I+4) + ABV(I) = AMPRMS(I+8) + END DO + +* Apparent RA,Dec to Cartesian + CALL sla_DCS2C(RA,DA,P3) + +* Precession and nutation + CALL sla_DIMXV(AMPRMS(13),P3,P2) + +* Aberration + AB1P1 = AB1+1D0 + DO I=1,3 + P1(I) = P2(I) + END DO + DO J=1,2 + P1DV = sla_DVDV(P1,ABV) + P1DVP1 = 1D0+P1DV + W = 1D0+P1DV/AB1P1 + DO I=1,3 + P1(I) = (P1DVP1*P2(I)-W*ABV(I))/AB1 + END DO + CALL sla_DVN(P1,P3,W) + DO I=1,3 + P1(I) = P3(I) + END DO + END DO + +* Light deflection + DO I=1,3 + P(I) = P1(I) + END DO + DO J=1,5 + PDE = sla_DVDV(P,EHN) + PDEP1 = 1D0+PDE + W = PDEP1-GR2E*PDE + DO I=1,3 + P(I) = (PDEP1*P1(I)-GR2E*EHN(I))/W + END DO + CALL sla_DVN(P,P2,W) + DO I=1,3 + P(I) = P2(I) + END DO + END DO + +* Mean RA,Dec + CALL sla_DCC2S(P,RM,DM) + RM = sla_DRANRM(RM) + + END diff --git a/src/slalib/aop.f b/src/slalib/aop.f new file mode 100644 index 0000000..66ef9c4 --- /dev/null +++ b/src/slalib/aop.f @@ -0,0 +1,174 @@ + SUBROUTINE sla_AOP (RAP, DAP, DATE, DUT, ELONGM, PHIM, HM, + : XP, YP, TDK, PMB, RH, WL, TLR, + : AOB, ZOB, HOB, DOB, ROB) +*+ +* - - - - +* A O P +* - - - - +* +* Apparent to observed place, for optical sources distant from +* the solar system. +* +* Given: +* RAP d geocentric apparent right ascension +* DAP d geocentric apparent declination +* DATE d UTC date/time (Modified Julian Date, JD-2400000.5) +* DUT d delta UT: UT1-UTC (UTC seconds) +* ELONGM d mean longitude of the observer (radians, east +ve) +* PHIM d mean geodetic latitude of the observer (radians) +* HM d observer's height above sea level (metres) +* XP d polar motion x-coordinate (radians) +* YP d polar motion y-coordinate (radians) +* TDK d local ambient temperature (DegK; std=273.155D0) +* PMB d local atmospheric pressure (mB; std=1013.25D0) +* RH d local relative humidity (in the range 0D0-1D0) +* WL d effective wavelength (micron, e.g. 0.55D0) +* TLR d tropospheric lapse rate (DegK/metre, e.g. 0.0065D0) +* +* Returned: +* AOB d observed azimuth (radians: N=0,E=90) +* ZOB d observed zenith distance (radians) +* HOB d observed Hour Angle (radians) +* DOB d observed Declination (radians) +* ROB d observed Right Ascension (radians) +* +* Notes: +* +* 1) This routine returns zenith distance rather than elevation +* in order to reflect the fact that no allowance is made for +* depression of the horizon. +* +* 2) The accuracy of the result is limited by the corrections for +* refraction. Providing the meteorological parameters are +* known accurately and there are no gross local effects, the +* predicted apparent RA,Dec should be within about 0.1 arcsec +* for a zenith distance of less than 70 degrees. Even at a +* topocentric zenith distance of 90 degrees, the accuracy in +* elevation should be better than 1 arcmin; useful results +* are available for a further 3 degrees, beyond which the +* sla_REFRO routine returns a fixed value of the refraction. +* The complementary routines sla_AOP (or sla_AOPQK) and sla_OAP +* (or sla_OAPQK) are self-consistent to better than 1 micro- +* arcsecond all over the celestial sphere. +* +* 3) It is advisable to take great care with units, as even +* unlikely values of the input parameters are accepted and +* processed in accordance with the models used. +* +* 4) "Apparent" place means the geocentric apparent right ascension +* and declination, which is obtained from a catalogue mean place +* by allowing for space motion, parallax, precession, nutation, +* annual aberration, and the Sun's gravitational lens effect. For +* star positions in the FK5 system (i.e. J2000), these effects can +* be applied by means of the sla_MAP etc routines. Starting from +* other mean place systems, additional transformations will be +* needed; for example, FK4 (i.e. B1950) mean places would first +* have to be converted to FK5, which can be done with the +* sla_FK425 etc routines. +* +* 5) "Observed" Az,El means the position that would be seen by a +* perfect theodolite located at the observer. This is obtained +* from the geocentric apparent RA,Dec by allowing for Earth +* orientation and diurnal aberration, rotating from equator +* to horizon coordinates, and then adjusting for refraction. +* The HA,Dec is obtained by rotating back into equatorial +* coordinates, using the geodetic latitude corrected for polar +* motion, and is the position that would be seen by a perfect +* equatorial located at the observer and with its polar axis +* aligned to the Earth's axis of rotation (n.b. not to the +* refracted pole). Finally, the RA is obtained by subtracting +* the HA from the local apparent ST. +* +* 6) To predict the required setting of a real telescope, the +* observed place produced by this routine would have to be +* adjusted for the tilt of the azimuth or polar axis of the +* mounting (with appropriate corrections for mount flexures), +* for non-perpendicularity between the mounting axes, for the +* position of the rotator axis and the pointing axis relative +* to it, for tube flexure, for gear and encoder errors, and +* finally for encoder zero points. Some telescopes would, of +* course, exhibit other properties which would need to be +* accounted for at the appropriate point in the sequence. +* +* 7) This routine takes time to execute, due mainly to the +* rigorous integration used to evaluate the refraction. +* For processing multiple stars for one location and time, +* call sla_AOPPA once followed by one call per star to sla_AOPQK. +* Where a range of times within a limited period of a few hours +* is involved, and the highest precision is not required, call +* sla_AOPPA once, followed by a call to sla_AOPPAT each time the +* time changes, followed by one call per star to sla_AOPQK. +* +* 8) The DATE argument is UTC expressed as an MJD. This is, +* strictly speaking, wrong, because of leap seconds. However, +* as long as the delta UT and the UTC are consistent there +* are no difficulties, except during a leap second. In this +* case, the start of the 61st second of the final minute should +* begin a new MJD day and the old pre-leap delta UT should +* continue to be used. As the 61st second completes, the MJD +* should revert to the start of the day as, simultaneously, +* the delta UTC changes by one second to its post-leap new value. +* +* 9) The delta UT (UT1-UTC) is tabulated in IERS circulars and +* elsewhere. It increases by exactly one second at the end of +* each UTC leap second, introduced in order to keep delta UT +* within +/- 0.9 seconds. +* +* 10) IMPORTANT -- TAKE CARE WITH THE LONGITUDE SIGN CONVENTION. +* The longitude required by the present routine is east-positive, +* in accordance with geographical convention (and right-handed). +* In particular, note that the longitudes returned by the +* sla_OBS routine are west-positive, following astronomical +* usage, and must be reversed in sign before use in the present +* routine. +* +* 11) The polar coordinates XP,YP can be obtained from IERS +* circulars and equivalent publications. The maximum amplitude +* is about 0.3 arcseconds. If XP,YP values are unavailable, +* use XP=YP=0D0. See page B60 of the 1988 Astronomical Almanac +* for a definition of the two angles. +* +* 12) The height above sea level of the observing station, HM, +* can be obtained from the Astronomical Almanac (Section J +* in the 1988 edition), or via the routine sla_OBS. If P, +* the pressure in millibars, is available, an adequate +* estimate of HM can be obtained from the expression +* +* HM ~ -29.3D0*TSL*LOG(P/1013.25D0). +* +* where TSL is the approximate sea-level air temperature in +* deg K (see Astrophysical Quantities, C.W.Allen, 3rd edition, +* section 52). Similarly, if the pressure P is not known, +* it can be estimated from the height of the observing +* station, HM as follows: +* +* P ~ 1013.25D0*EXP(-HM/(29.3D0*TSL)). +* +* Note, however, that the refraction is proportional to the +* pressure and that an accurate P value is important for +* precise work. +* +* 13) The azimuths etc produced by the present routine are with +* respect to the celestial pole. Corrections to the terrestrial +* pole can be computed using sla_POLMO. +* +* Called: sla_AOPPA, sla_AOPQK +* +* P.T.Wallace Starlink 6 September 1999 +* +* Copyright (C) 1999 P.T.Wallace and CCLRC +*- + + IMPLICIT NONE + + DOUBLE PRECISION RAP,DAP,DATE,DUT,ELONGM,PHIM,HM, + : XP,YP,TDK,PMB,RH,WL,TLR,AOB,ZOB,HOB,DOB,ROB + + DOUBLE PRECISION AOPRMS(14) + + + CALL sla_AOPPA(DATE,DUT,ELONGM,PHIM,HM,XP,YP,TDK,PMB,RH,WL,TLR, + : AOPRMS) + CALL sla_AOPQK(RAP,DAP,AOPRMS,AOB,ZOB,HOB,DOB,ROB) + + END diff --git a/src/slalib/aoppa.f b/src/slalib/aoppa.f new file mode 100644 index 0000000..b497fdb --- /dev/null +++ b/src/slalib/aoppa.f @@ -0,0 +1,176 @@ + SUBROUTINE sla_AOPPA (DATE, DUT, ELONGM, PHIM, HM, + : XP, YP, TDK, PMB, RH, WL, TLR, AOPRMS) +*+ +* - - - - - - +* A O P P A +* - - - - - - +* +* Precompute apparent to observed place parameters required by +* sla_AOPQK and sla_OAPQK. +* +* Given: +* DATE d UTC date/time (modified Julian Date, JD-2400000.5) +* DUT d delta UT: UT1-UTC (UTC seconds) +* ELONGM d mean longitude of the observer (radians, east +ve) +* PHIM d mean geodetic latitude of the observer (radians) +* HM d observer's height above sea level (metres) +* XP d polar motion x-coordinate (radians) +* YP d polar motion y-coordinate (radians) +* TDK d local ambient temperature (DegK; std=273.155D0) +* PMB d local atmospheric pressure (mB; std=1013.25D0) +* RH d local relative humidity (in the range 0D0-1D0) +* WL d effective wavelength (micron, e.g. 0.55D0) +* TLR d tropospheric lapse rate (DegK/metre, e.g. 0.0065D0) +* +* Returned: +* AOPRMS d(14) star-independent apparent-to-observed parameters: +* +* (1) geodetic latitude (radians) +* (2,3) sine and cosine of geodetic latitude +* (4) magnitude of diurnal aberration vector +* (5) height (HM) +* (6) ambient temperature (TDK) +* (7) pressure (PMB) +* (8) relative humidity (RH) +* (9) wavelength (WL) +* (10) lapse rate (TLR) +* (11,12) refraction constants A and B (radians) +* (13) longitude + eqn of equinoxes + sidereal DUT (radians) +* (14) local apparent sidereal time (radians) +* +* Notes: +* +* 1) It is advisable to take great care with units, as even +* unlikely values of the input parameters are accepted and +* processed in accordance with the models used. +* +* 2) The DATE argument is UTC expressed as an MJD. This is, +* strictly speaking, improper, because of leap seconds. However, +* as long as the delta UT and the UTC are consistent there +* are no difficulties, except during a leap second. In this +* case, the start of the 61st second of the final minute should +* begin a new MJD day and the old pre-leap delta UT should +* continue to be used. As the 61st second completes, the MJD +* should revert to the start of the day as, simultaneously, +* the delta UTC changes by one second to its post-leap new value. +* +* 3) The delta UT (UT1-UTC) is tabulated in IERS circulars and +* elsewhere. It increases by exactly one second at the end of +* each UTC leap second, introduced in order to keep delta UT +* within +/- 0.9 seconds. +* +* 4) IMPORTANT -- TAKE CARE WITH THE LONGITUDE SIGN CONVENTION. +* The longitude required by the present routine is east-positive, +* in accordance with geographical convention (and right-handed). +* In particular, note that the longitudes returned by the +* sla_OBS routine are west-positive, following astronomical +* usage, and must be reversed in sign before use in the present +* routine. +* +* 5) The polar coordinates XP,YP can be obtained from IERS +* circulars and equivalent publications. The maximum amplitude +* is about 0.3 arcseconds. If XP,YP values are unavailable, +* use XP=YP=0D0. See page B60 of the 1988 Astronomical Almanac +* for a definition of the two angles. +* +* 6) The height above sea level of the observing station, HM, +* can be obtained from the Astronomical Almanac (Section J +* in the 1988 edition), or via the routine sla_OBS. If P, +* the pressure in millibars, is available, an adequate +* estimate of HM can be obtained from the expression +* +* HM ~ -29.3D0*TSL*LOG(P/1013.25D0). +* +* where TSL is the approximate sea-level air temperature in +* deg K (see Astrophysical Quantities, C.W.Allen, 3rd edition, +* section 52). Similarly, if the pressure P is not known, +* it can be estimated from the height of the observing +* station, HM as follows: +* +* P ~ 1013.25D0*EXP(-HM/(29.3D0*TSL)). +* +* Note, however, that the refraction is proportional to the +* pressure and that an accurate P value is important for +* precise work. +* +* 7) Repeated, computationally-expensive, calls to sla_AOPPA for +* times that are very close together can be avoided by calling +* sla_AOPPA just once and then using sla_AOPPAT for the subsequent +* times. Fresh calls to sla_AOPPA will be needed only when changes +* in the precession have grown to unacceptable levels or when +* anything affecting the refraction has changed. +* +* Called: sla_GEOC, sla_REFCO, sla_EQEQX, sla_AOPPAT +* +* P.T.Wallace Starlink 6 September 1999 +* +* Copyright (C) 1999 P.T.Wallace and CCLRC +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,DUT,ELONGM,PHIM,HM,XP,YP,TDK,PMB, + : RH,WL,TLR,AOPRMS(14) + + DOUBLE PRECISION sla_EQEQX + +* 2Pi + DOUBLE PRECISION D2PI + PARAMETER (D2PI=6.283185307179586476925287D0) + +* Seconds of time to radians + DOUBLE PRECISION S2R + PARAMETER (S2R=7.272205216643039903848712D-5) + +* Speed of light (AU per day) + DOUBLE PRECISION C + PARAMETER (C=173.14463331D0) + +* Ratio between solar and sidereal time + DOUBLE PRECISION SOLSID + PARAMETER (SOLSID=1.00273790935D0) + + DOUBLE PRECISION CPHIM,XT,YT,ZT,XC,YC,ZC,ELONG,PHI,UAU,VAU + + + +* Observer's location corrected for polar motion + CPHIM = COS(PHIM) + XT = COS(ELONGM)*CPHIM + YT = SIN(ELONGM)*CPHIM + ZT = SIN(PHIM) + XC = XT-XP*ZT + YC = YT+YP*ZT + ZC = XP*XT-YP*YT+ZT + IF (XC.EQ.0D0.AND.YC.EQ.0D0) THEN + ELONG = 0D0 + ELSE + ELONG = ATAN2(YC,XC) + END IF + PHI = ATAN2(ZC,SQRT(XC*XC+YC*YC)) + AOPRMS(1) = PHI + AOPRMS(2) = SIN(PHI) + AOPRMS(3) = COS(PHI) + +* Magnitude of the diurnal aberration vector + CALL sla_GEOC(PHI,HM,UAU,VAU) + AOPRMS(4) = D2PI*UAU*SOLSID/C + +* Copy the refraction parameters and compute the A & B constants + AOPRMS(5) = HM + AOPRMS(6) = TDK + AOPRMS(7) = PMB + AOPRMS(8) = RH + AOPRMS(9) = WL + AOPRMS(10) = TLR + CALL sla_REFCO(HM,TDK,PMB,RH,WL,PHI,TLR,1D-10, + : AOPRMS(11),AOPRMS(12)) + +* Longitude + equation of the equinoxes + sidereal equivalent of DUT +* (ignoring change in equation of the equinoxes between UTC and TDB) + AOPRMS(13) = ELONG+sla_EQEQX(DATE)+DUT*SOLSID*S2R + +* Sidereal time + CALL sla_AOPPAT(DATE,AOPRMS) + + END diff --git a/src/slalib/aoppat.f b/src/slalib/aoppat.f new file mode 100644 index 0000000..1342024 --- /dev/null +++ b/src/slalib/aoppat.f @@ -0,0 +1,45 @@ + SUBROUTINE sla_AOPPAT (DATE, AOPRMS) +*+ +* - - - - - - - +* A O P P A T +* - - - - - - - +* +* Recompute the sidereal time in the apparent to observed place +* star-independent parameter block. +* +* Given: +* DATE d UTC date/time (modified Julian Date, JD-2400000.5) +* (see AOPPA source for comments on leap seconds) +* +* AOPRMS d(14) star-independent apparent-to-observed parameters +* +* (1-12) not required +* (13) longitude + eqn of equinoxes + sidereal DUT +* (14) not required +* +* Returned: +* AOPRMS d(14) star-independent apparent-to-observed parameters: +* +* (1-13) not changed +* (14) local apparent sidereal time (radians) +* +* For more information, see sla_AOPPA. +* +* Called: sla_GMST +* +* P.T.Wallace Starlink 1 July 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,AOPRMS(14) + + DOUBLE PRECISION sla_GMST + + + + AOPRMS(14) = sla_GMST(DATE)+AOPRMS(13) + + END diff --git a/src/slalib/aopqk.f b/src/slalib/aopqk.f new file mode 100644 index 0000000..9f8a45c --- /dev/null +++ b/src/slalib/aopqk.f @@ -0,0 +1,242 @@ + SUBROUTINE sla_AOPQK (RAP, DAP, AOPRMS, AOB, ZOB, HOB, DOB, ROB) +*+ +* - - - - - - +* A O P Q K +* - - - - - - +* +* Quick apparent to observed place (but see note 8, below, for +* remarks about speed). +* +* Given: +* RAP d geocentric apparent right ascension +* DAP d geocentric apparent declination +* AOPRMS d(14) star-independent apparent-to-observed parameters: +* +* (1) geodetic latitude (radians) +* (2,3) sine and cosine of geodetic latitude +* (4) magnitude of diurnal aberration vector +* (5) height (HM) +* (6) ambient temperature (T) +* (7) pressure (P) +* (8) relative humidity (RH) +* (9) wavelength (WL) +* (10) lapse rate (TLR) +* (11,12) refraction constants A and B (radians) +* (13) longitude + eqn of equinoxes + sidereal DUT (radians) +* (14) local apparent sidereal time (radians) +* +* Returned: +* AOB d observed azimuth (radians: N=0,E=90) +* ZOB d observed zenith distance (radians) +* HOB d observed Hour Angle (radians) +* DOB d observed Declination (radians) +* ROB d observed Right Ascension (radians) +* +* Notes: +* +* 1) This routine returns zenith distance rather than elevation +* in order to reflect the fact that no allowance is made for +* depression of the horizon. +* +* 2) The accuracy of the result is limited by the corrections for +* refraction. Providing the meteorological parameters are +* known accurately and there are no gross local effects, the +* observed RA,Dec predicted by this routine should be within +* about 0.1 arcsec for a zenith distance of less than 70 degrees. +* Even at a topocentric zenith distance of 90 degrees, the +* accuracy in elevation should be better than 1 arcmin; useful +* results are available for a further 3 degrees, beyond which +* the slaRefro routine returns a fixed value of the refraction. +* The complementary routines slaAop (or slaAopqk) and slaOap +* (or slaOapqk) are self-consistent to better than 1 micro- +* arcsecond all over the celestial sphere. +* +* 3) It is advisable to take great care with units, as even +* unlikely values of the input parameters are accepted and +* processed in accordance with the models used. +* +* 4) "Apparent" place means the geocentric apparent right ascension +* and declination, which is obtained from a catalogue mean place +* by allowing for space motion, parallax, precession, nutation, +* annual aberration, and the Sun's gravitational lens effect. For +* star positions in the FK5 system (i.e. J2000), these effects can +* be applied by means of the sla_MAP etc routines. Starting from +* other mean place systems, additional transformations will be +* needed; for example, FK4 (i.e. B1950) mean places would first +* have to be converted to FK5, which can be done with the +* sla_FK425 etc routines. +* +* 5) "Observed" Az,El means the position that would be seen by a +* perfect theodolite located at the observer. This is obtained +* from the geocentric apparent RA,Dec by allowing for Earth +* orientation and diurnal aberration, rotating from equator +* to horizon coordinates, and then adjusting for refraction. +* The HA,Dec is obtained by rotating back into equatorial +* coordinates, using the geodetic latitude corrected for polar +* motion, and is the position that would be seen by a perfect +* equatorial located at the observer and with its polar axis +* aligned to the Earth's axis of rotation (n.b. not to the +* refracted pole). Finally, the RA is obtained by subtracting +* the HA from the local apparent ST. +* +* 6) To predict the required setting of a real telescope, the +* observed place produced by this routine would have to be +* adjusted for the tilt of the azimuth or polar axis of the +* mounting (with appropriate corrections for mount flexures), +* for non-perpendicularity between the mounting axes, for the +* position of the rotator axis and the pointing axis relative +* to it, for tube flexure, for gear and encoder errors, and +* finally for encoder zero points. Some telescopes would, of +* course, exhibit other properties which would need to be +* accounted for at the appropriate point in the sequence. +* +* 7) The star-independent apparent-to-observed-place parameters +* in AOPRMS may be computed by means of the sla_AOPPA routine. +* If nothing has changed significantly except the time, the +* sla_AOPPAT routine may be used to perform the requisite +* partial recomputation of AOPRMS. +* +* 8) At zenith distances beyond about 76 degrees, the need for +* special care with the corrections for refraction causes a +* marked increase in execution time. Moreover, the effect +* gets worse with increasing zenith distance. Adroit +* programming in the calling application may allow the +* problem to be reduced. Prepare an alternative AOPRMS array, +* computed for zero air-pressure; this will disable the +* refraction corrections and cause rapid execution. Using +* this AOPRMS array, a preliminary call to the present routine +* will, depending on the application, produce a rough position +* which may be enough to establish whether the full, slow +* calculation (using the real AOPRMS array) is worthwhile. +* For example, there would be no need for the full calculation +* if the preliminary call had already established that the +* source was well below the elevation limits for a particular +* telescope. +* +* 9) The azimuths etc produced by the present routine are with +* respect to the celestial pole. Corrections to the terrestrial +* pole can be computed using sla_POLMO. +* +* Called: sla_DCS2C, sla_REFZ, sla_REFRO, sla_DCC2S, sla_DRANRM +* +* P.T.Wallace Starlink 22 February 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RAP,DAP,AOPRMS(14),AOB,ZOB,HOB,DOB,ROB + +* Breakpoint for fast/slow refraction algorithm: +* ZD greater than arctan(4), (see sla_REFCO routine) +* or vector Z less than cosine(arctan(Z)) = 1/sqrt(17) + DOUBLE PRECISION ZBREAK + PARAMETER (ZBREAK=0.242535625D0) + + INTEGER I + + DOUBLE PRECISION SPHI,CPHI,ST,V(3),XHD,YHD,ZHD,DIURAB,F, + : XHDT,YHDT,ZHDT,XAET,YAET,ZAET,AZOBS, + : ZDT,REFA,REFB,ZDOBS,DZD,DREF,CE, + : XAEO,YAEO,ZAEO,HMOBS,DCOBS,RAOBS + + DOUBLE PRECISION sla_DRANRM + + + +* Sin, cos of latitude + SPHI = AOPRMS(2) + CPHI = AOPRMS(3) + +* Local apparent sidereal time + ST = AOPRMS(14) + +* Apparent RA,Dec to Cartesian -HA,Dec + CALL sla_DCS2C(RAP-ST,DAP,V) + XHD = V(1) + YHD = V(2) + ZHD = V(3) + +* Diurnal aberration + DIURAB = AOPRMS(4) + F = (1D0-DIURAB*YHD) + XHDT = F*XHD + YHDT = F*(YHD+DIURAB) + ZHDT = F*ZHD + +* Cartesian -HA,Dec to Cartesian Az,El (S=0,E=90) + XAET = SPHI*XHDT-CPHI*ZHDT + YAET = YHDT + ZAET = CPHI*XHDT+SPHI*ZHDT + +* Azimuth (N=0,E=90) + IF (XAET.EQ.0D0.AND.YAET.EQ.0D0) THEN + AZOBS = 0D0 + ELSE + AZOBS = ATAN2(YAET,-XAET) + END IF + +* Topocentric zenith distance + ZDT = ATAN2(SQRT(XAET*XAET+YAET*YAET),ZAET) + +* +* Refraction +* ---------- + +* Fast algorithm using two constant model + REFA = AOPRMS(11) + REFB = AOPRMS(12) + CALL sla_REFZ(ZDT,REFA,REFB,ZDOBS) + +* Large zenith distance? + IF (COS(ZDOBS).LT.ZBREAK) THEN + +* Yes: use rigorous algorithm + +* Initialize loop (maximum of 10 iterations) + I = 1 + DZD = 1D1 + DO WHILE (ABS(DZD).GT.1D-10.AND.I.LE.10) + +* Compute refraction using current estimate of observed ZD + CALL sla_REFRO(ZDOBS,AOPRMS(5),AOPRMS(6),AOPRMS(7), + : AOPRMS(8),AOPRMS(9),AOPRMS(1), + : AOPRMS(10),1D-8,DREF) + +* Remaining discrepancy + DZD = ZDOBS+DREF-ZDT + +* Update the estimate + ZDOBS = ZDOBS-DZD + +* Increment the iteration counter + I = I+1 + END DO + END IF + +* To Cartesian Az/ZD + CE = SIN(ZDOBS) + XAEO = -COS(AZOBS)*CE + YAEO = SIN(AZOBS)*CE + ZAEO = COS(ZDOBS) + +* Cartesian Az/ZD to Cartesian -HA,Dec + V(1) = SPHI*XAEO+CPHI*ZAEO + V(2) = YAEO + V(3) = -CPHI*XAEO+SPHI*ZAEO + +* To spherical -HA,Dec + CALL sla_DCC2S(V,HMOBS,DCOBS) + +* Right Ascension + RAOBS = sla_DRANRM(ST+HMOBS) + +* Return the results + AOB = AZOBS + ZOB = ZDOBS + HOB = -HMOBS + DOB = DCOBS + ROB = RAOBS + + END diff --git a/src/slalib/atmdsp.f b/src/slalib/atmdsp.f new file mode 100644 index 0000000..62869aa --- /dev/null +++ b/src/slalib/atmdsp.f @@ -0,0 +1,121 @@ + SUBROUTINE sla_ATMDSP (TDK, PMB, RH, WL1, A1, B1, WL2, A2, B2) +*+ +* - - - - - - - +* A T M D S P +* - - - - - - - +* +* Apply atmospheric-dispersion adjustments to refraction coefficients. +* +* Given: +* TDK d ambient temperature, degrees K +* PMB d ambient pressure, millibars +* RH d ambient relative humidity, 0-1 +* WL1 d reference wavelength, micrometre (0.4D0 recommended) +* A1 d refraction coefficient A for wavelength WL1 (radians) +* B1 d refraction coefficient B for wavelength WL1 (radians) +* WL2 d wavelength for which adjusted A,B required +* +* Returned: +* A2 d refraction coefficient A for wavelength WL2 (radians) +* B2 d refraction coefficient B for wavelength WL2 (radians) +* +* Notes: +* +* 1 To use this routine, first call sla_REFCO specifying WL1 as the +* wavelength. This yields refraction coefficients A1,B1, correct +* for that wavelength. Subsequently, calls to sla_ATMDSP specifying +* different wavelengths will produce new, slightly adjusted +* refraction coefficients which apply to the specified wavelength. +* +* 2 Most of the atmospheric dispersion happens between 0.7 micrometre +* and the UV atmospheric cutoff, and the effect increases strongly +* towards the UV end. For this reason a blue reference wavelength +* is recommended, for example 0.4 micrometres. +* +* 3 The accuracy, for this set of conditions: +* +* height above sea level 2000 m +* latitude 29 deg +* pressure 793 mB +* temperature 17 degC +* humidity 50% +* lapse rate 0.0065 degC/m +* reference wavelength 0.4 micrometre +* star elevation 15 deg +* +* is about 2.5 mas RMS between 0.3 and 1.0 micrometres, and stays +* within 4 mas for the whole range longward of 0.3 micrometres +* (compared with a total dispersion from 0.3 to 20.0 micrometres +* of about 11 arcsec). These errors are typical for ordinary +* conditions and the given elevation; in extreme conditions values +* a few times this size may occur, while at higher elevations the +* errors become much smaller. +* +* 4 If either wavelength exceeds 100 micrometres, the radio case +* is assumed and the returned refraction coefficients are the +* same as the given ones. +* +* 5 The algorithm consists of calculation of the refractivity of the +* air at the observer for the two wavelengths, using the methods +* of the sla_REFRO routine, and then scaling of the two refraction +* coefficients according to classical refraction theory. This +* amounts to scaling the A coefficient in proportion to (n-1) and +* the B coefficient almost in the same ratio (see R.M.Green, +* "Spherical Astronomy", Cambridge University Press, 1985). +* +* P.T.Wallace Starlink 6 October 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION TDK,PMB,RH,WL1,A1,B1,WL2,A2,B2 + + DOUBLE PRECISION F,TDKOK,PMBOK,RHOK, + : PSAT,PWO,W1,WLOK,WLSQ,W2,DN1,DN2 + + +* Check for radio wavelengths + IF (WL1.GT.100D0.OR.WL2.GT.100D0) THEN + +* Radio: no dispersion + A2 = A1 + B2 = B1 + ELSE + +* Optical: keep arguments within safe bounds + TDKOK = MIN(MAX(TDK,100D0),500D0) + PMBOK = MIN(MAX(PMB,0D0),10000D0) + RHOK = MIN(MAX(RH,0D0),1D0) + +* Atmosphere parameters at the observer + PSAT = 10D0**(-8.7115D0+0.03477D0*TDKOK) + PWO = RHOK*PSAT + W1 = 11.2684D-6*PWO + +* Refractivity at the observer for first wavelength + WLOK = MAX(WL1,0.1D0) + WLSQ = WLOK*WLOK + W2 = 77.5317D-6+(0.43909D-6+0.00367D-6/WLSQ)/WLSQ + DN1 = (W2*PMBOK-W1)/TDKOK + +* Refractivity at the observer for second wavelength + WLOK = MAX(WL2,0.1D0) + WLSQ = WLOK*WLOK + W2 = 77.5317D-6+(0.43909D-6+0.00367D-6/WLSQ)/WLSQ + DN2 = (W2*PMBOK-W1)/TDKOK + +* Scale the refraction coefficients (see Green 4.31, p93) + IF (DN1.NE.0D0) THEN + F = DN2/DN1 + A2 = A1*F + B2 = B1*F + IF (DN1.NE.A1) B2=B2*(1D0+DN1*(DN1-DN2)/(2D0*(DN1-A1))) + ELSE + A2 = A1 + B2 = B1 + END IF + END IF + + END diff --git a/src/slalib/atms.f b/src/slalib/atms.f new file mode 100644 index 0000000..3b991f4 --- /dev/null +++ b/src/slalib/atms.f @@ -0,0 +1,40 @@ + SUBROUTINE sla__ATMS (RT, TT, DNT, GAMAL, R, DN, RDNDR) +*+ +* - - - - - +* A T M S +* - - - - - +* +* Internal routine used by REFRO +* +* Refractive index and derivative with respect to height for the +* stratosphere. +* +* Given: +* RT d height of tropopause from centre of the Earth (metre) +* TT d temperature at the tropopause (deg K) +* DNT d refractive index at the tropopause +* GAMAL d constant of the atmospheric model = G*MD/R +* R d current distance from the centre of the Earth (metre) +* +* Returned: +* DN d refractive index at R +* RDNDR d R * rate the refractive index is changing at R +* +* P.T.Wallace Starlink 14 July 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RT,TT,DNT,GAMAL,R,DN,RDNDR + + DOUBLE PRECISION B,W + + + B = GAMAL/TT + W = (DNT-1D0)*EXP(-B*(R-RT)) + DN = 1D0+W + RDNDR = -R*B*W + + END diff --git a/src/slalib/atmt.f b/src/slalib/atmt.f new file mode 100644 index 0000000..82d0ecd --- /dev/null +++ b/src/slalib/atmt.f @@ -0,0 +1,54 @@ + SUBROUTINE sla__ATMT (R0, T0, ALPHA, GAMM2, DELM2, + : C1, C2, C3, C4, C5, C6, R, T, DN, RDNDR) +*+ +* - - - - - +* A T M T +* - - - - - +* +* Internal routine used by REFRO +* +* Refractive index and derivative with respect to height for the +* troposphere. +* +* Given: +* R0 d height of observer from centre of the Earth (metre) +* T0 d temperature at the observer (deg K) +* ALPHA d alpha ) +* GAMM2 d gamma minus 2 ) see HMNAO paper +* DELM2 d delta minus 2 ) +* C1 d useful term ) +* C2 d useful term ) +* C3 d useful term ) see source +* C4 d useful term ) of sla_REFRO +* C5 d useful term ) +* C6 d useful term ) +* R d current distance from the centre of the Earth (metre) +* +* Returned: +* T d temperature at R (deg K) +* DN d refractive index at R +* RDNDR d R * rate the refractive index is changing at R +* +* Note that in the optical case C5 and C6 are zero. +* +* P.T.Wallace Starlink 30 May 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION R0,T0,ALPHA,GAMM2,DELM2,C1,C2,C3,C4,C5,C6, + : R,T,DN,RDNDR + + DOUBLE PRECISION TT0,TT0GM2,TT0DM2 + + + T = MAX(MIN(T0-ALPHA*(R-R0),320D0),100D0) + TT0 = T/T0 + TT0GM2 = TT0**GAMM2 + TT0DM2 = TT0**DELM2 + DN = 1D0+(C1*TT0GM2-(C2-C5/T)*TT0DM2)*TT0 + RDNDR = R*(-C3*TT0GM2+(C4-C6/TT0)*TT0DM2) + + END diff --git a/src/slalib/av2m.f b/src/slalib/av2m.f new file mode 100644 index 0000000..ec1967c --- /dev/null +++ b/src/slalib/av2m.f @@ -0,0 +1,68 @@ + SUBROUTINE sla_AV2M (AXVEC, RMAT) +*+ +* - - - - - +* A V 2 M +* - - - - - +* +* Form the rotation matrix corresponding to a given axial vector. +* +* (single precision) +* +* A rotation matrix describes a rotation about some arbitrary axis. +* The axis is called the Euler axis, and the angle through which the +* reference frame rotates is called the Euler angle. The axial +* vector supplied to this routine has the same direction as the +* Euler axis, and its magnitude is the Euler angle in radians. +* +* Given: +* AXVEC r(3) axial vector (radians) +* +* Returned: +* RMAT r(3,3) rotation matrix +* +* If AXVEC is null, the unit matrix is returned. +* +* The reference frame rotates clockwise as seen looking along +* the axial vector from the origin. +* +* P.T.Wallace Starlink June 1989 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL AXVEC(3),RMAT(3,3) + + REAL X,Y,Z,PHI,S,C,W + + + +* Euler angle - magnitude of axial vector - and functions + X = AXVEC(1) + Y = AXVEC(2) + Z = AXVEC(3) + PHI = SQRT(X*X+Y*Y+Z*Z) + S = SIN(PHI) + C = COS(PHI) + W = 1.0-C + +* Euler axis - direction of axial vector (perhaps null) + IF (PHI.NE.0.0) THEN + X = X/PHI + Y = Y/PHI + Z = Z/PHI + END IF + +* Compute the rotation matrix + RMAT(1,1) = X*X*W+C + RMAT(1,2) = X*Y*W+Z*S + RMAT(1,3) = X*Z*W-Y*S + RMAT(2,1) = X*Y*W-Z*S + RMAT(2,2) = Y*Y*W+C + RMAT(2,3) = Y*Z*W+X*S + RMAT(3,1) = X*Z*W+Y*S + RMAT(3,2) = Y*Z*W-X*S + RMAT(3,3) = Z*Z*W+C + + END diff --git a/src/slalib/bear.f b/src/slalib/bear.f new file mode 100644 index 0000000..11238ff --- /dev/null +++ b/src/slalib/bear.f @@ -0,0 +1,42 @@ + REAL FUNCTION sla_BEAR (A1, B1, A2, B2) +*+ +* - - - - - +* B E A R +* - - - - - +* +* Bearing (position angle) of one point on a sphere relative to another +* (single precision) +* +* Given: +* A1,B1 r spherical coordinates of one point +* A2,B2 r spherical coordinates of the other point +* +* (The spherical coordinates are RA,Dec, Long,Lat etc, in radians.) +* +* The result is the bearing (position angle), in radians, of point +* A2,B2 as seen from point A1,B1. It is in the range +/- pi. If +* A2,B2 is due east of A1,B1 the bearing is +pi/2. Zero is returned +* if the two points are coincident. +* +* P.T.Wallace Starlink 23 March 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL A1,B1,A2,B2 + + REAL DA,X,Y + + + DA=A2-A1 + Y=SIN(DA)*COS(B2) + X=SIN(B2)*COS(B1)-COS(B2)*SIN(B1)*COS(DA) + IF (X.NE.0.0.OR.Y.NE.0.0) THEN + sla_BEAR=ATAN2(Y,X) + ELSE + sla_BEAR=0.0 + END IF + + END diff --git a/src/slalib/caf2r.f b/src/slalib/caf2r.f new file mode 100644 index 0000000..5e5b616 --- /dev/null +++ b/src/slalib/caf2r.f @@ -0,0 +1,57 @@ + SUBROUTINE sla_CAF2R (IDEG, IAMIN, ASEC, RAD, J) +*+ +* - - - - - - +* C A F 2 R +* - - - - - - +* +* Convert degrees, arcminutes, arcseconds to radians +* (single precision) +* +* Given: +* IDEG int degrees +* IAMIN int arcminutes +* ASEC real arcseconds +* +* Returned: +* RAD real angle in radians +* J int status: 0 = OK +* 1 = IDEG outside range 0-359 +* 2 = IAMIN outside range 0-59 +* 3 = ASEC outside range 0-59.999... +* +* Notes: +* +* 1) The result is computed even if any of the range checks +* fail. +* +* 2) The sign must be dealt with outside this routine. +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IDEG,IAMIN + REAL ASEC,RAD + INTEGER J + +* Arc seconds to radians + REAL AS2R + PARAMETER (AS2R=0.484813681109535994E-5) + + + +* Preset status + J=0 + +* Validate arcsec, arcmin, deg + IF (ASEC.LT.0.0.OR.ASEC.GE.60.0) J=3 + IF (IAMIN.LT.0.OR.IAMIN.GT.59) J=2 + IF (IDEG.LT.0.OR.IDEG.GT.359) J=1 + +* Compute angle + RAD=AS2R*(60.0*(60.0*REAL(IDEG)+REAL(IAMIN))+ASEC) + + END diff --git a/src/slalib/caldj.f b/src/slalib/caldj.f new file mode 100644 index 0000000..c2d9a6d --- /dev/null +++ b/src/slalib/caldj.f @@ -0,0 +1,57 @@ + SUBROUTINE sla_CALDJ (IY, IM, ID, DJM, J) +*+ +* - - - - - - +* C A L D J +* - - - - - - +* +* Gregorian Calendar to Modified Julian Date +* +* (Includes century default feature: use sla_CLDJ for years +* before 100AD.) +* +* Given: +* IY,IM,ID int year, month, day in Gregorian calendar +* +* Returned: +* DJM dp modified Julian Date (JD-2400000.5) for 0 hrs +* J int status: +* 0 = OK +* 1 = bad year (MJD not computed) +* 2 = bad month (MJD not computed) +* 3 = bad day (MJD computed) +* +* Acceptable years are 00-49, interpreted as 2000-2049, +* 50-99, " " 1950-1999, +* 100 upwards, interpreted literally. +* +* Called: sla_CLDJ +* +* P.T.Wallace Starlink November 1985 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IY,IM,ID + DOUBLE PRECISION DJM + INTEGER J + + INTEGER NY + + + + +* Default century if appropriate + IF (IY.GE.0.AND.IY.LE.49) THEN + NY=IY+2000 + ELSE IF (IY.GE.50.AND.IY.LE.99) THEN + NY=IY+1900 + ELSE + NY=IY + END IF + +* Modified Julian Date + CALL sla_CLDJ(NY,IM,ID,DJM,J) + + END diff --git a/src/slalib/calyd.f b/src/slalib/calyd.f new file mode 100644 index 0000000..240a887 --- /dev/null +++ b/src/slalib/calyd.f @@ -0,0 +1,65 @@ + SUBROUTINE sla_CALYD (IY, IM, ID, NY, ND, J) +*+ +* - - - - - - +* C A L Y D +* - - - - - - +* +* Gregorian calendar date to year and day in year (in a Julian +* calendar aligned to the 20th/21st century Gregorian calendar). +* +* (Includes century default feature: use sla_CLYD for years +* before 100AD.) +* +* Given: +* IY,IM,ID int year, month, day in Gregorian calendar +* (year may optionally omit the century) +* Returned: +* NY int year (re-aligned Julian calendar) +* ND int day in year (1 = January 1st) +* J int status: +* 0 = OK +* 1 = bad year (before -4711) +* 2 = bad month +* 3 = bad day (but conversion performed) +* +* Notes: +* +* 1 This routine exists to support the low-precision routines +* sla_EARTH, sla_MOON and sla_ECOR. +* +* 2 Between 1900 March 1 and 2100 February 28 it returns answers +* which are consistent with the ordinary Gregorian calendar. +* Outside this range there will be a discrepancy which increases +* by one day for every non-leap century year. +* +* 3 Years in the range 50-99 are interpreted as 1950-1999, and +* years in the range 00-49 are interpreted as 2000-2049. +* +* Called: sla_CLYD +* +* P.T.Wallace Starlink 23 November 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IY,IM,ID,NY,ND,J + + INTEGER I + + + +* Default century if appropriate + IF (IY.GE.0.AND.IY.LE.49) THEN + I=IY+2000 + ELSE IF (IY.GE.50.AND.IY.LE.99) THEN + I=IY+1900 + ELSE + I=IY + END IF + +* Perform the conversion + CALL sla_CLYD(I,IM,ID,NY,ND,J) + + END diff --git a/src/slalib/cc2s.f b/src/slalib/cc2s.f new file mode 100644 index 0000000..2e24b9d --- /dev/null +++ b/src/slalib/cc2s.f @@ -0,0 +1,53 @@ + SUBROUTINE sla_CC2S (V, A, B) +*+ +* - - - - - +* C C 2 S +* - - - - - +* +* Direction cosines to spherical coordinates (single precision) +* +* Given: +* V r(3) x,y,z vector +* +* Returned: +* A,B r spherical coordinates in radians +* +* The spherical coordinates are longitude (+ve anticlockwise +* looking from the +ve latitude pole) and latitude. The +* Cartesian coordinates are right handed, with the x axis +* at zero longitude and latitude, and the z axis at the +* +ve latitude pole. +* +* If V is null, zero A and B are returned. +* At either pole, zero A is returned. +* +* P.T.Wallace Starlink July 1989 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL V(3),A,B + + REAL X,Y,Z,R + + + X = V(1) + Y = V(2) + Z = V(3) + R = SQRT(X*X+Y*Y) + + IF (R.EQ.0.0) THEN + A = 0.0 + ELSE + A = ATAN2(Y,X) + END IF + + IF (Z.EQ.0.0) THEN + B = 0.0 + ELSE + B = ATAN2(Z,R) + END IF + + END diff --git a/src/slalib/cc62s.f b/src/slalib/cc62s.f new file mode 100644 index 0000000..c2ccd8d --- /dev/null +++ b/src/slalib/cc62s.f @@ -0,0 +1,82 @@ + SUBROUTINE sla_CC62S (V, A, B, R, AD, BD, RD) +*+ +* - - - - - - +* C C 6 2 S +* - - - - - - +* +* Conversion of position & velocity in Cartesian coordinates +* to spherical coordinates (single precision) +* +* Given: +* V r(6) Cartesian position & velocity vector +* +* Returned: +* A r longitude (radians) +* B r latitude (radians) +* R r radial coordinate +* AD r longitude derivative (radians per unit time) +* BD r latitude derivative (radians per unit time) +* RD r radial derivative +* +* P.T.Wallace Starlink 28 April 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL V(6),A,B,R,AD,BD,RD + + REAL X,Y,Z,XD,YD,ZD,RXY2,RXY,R2,XYP + + + +* Components of position/velocity vector + X=V(1) + Y=V(2) + Z=V(3) + XD=V(4) + YD=V(5) + ZD=V(6) + +* Component of R in XY plane squared + RXY2=X*X+Y*Y + +* Modulus squared + R2=RXY2+Z*Z + +* Protection against null vector + IF (R2.EQ.0.0) THEN + X=XD + Y=YD + Z=ZD + RXY2=X*X+Y*Y + R2=RXY2+Z*Z + END IF + +* Position and velocity in spherical coordinates + RXY=SQRT(RXY2) + XYP=X*XD+Y*YD + IF (RXY2.NE.0.0) THEN + A=ATAN2(Y,X) + B=ATAN2(Z,RXY) + AD=(X*YD-Y*XD)/RXY2 + BD=(ZD*RXY2-Z*XYP)/(R2*RXY) + ELSE + A=0.0 + IF (Z.NE.0.0) THEN + B=ATAN2(Z,RXY) + ELSE + B=0.0 + END IF + AD=0.0 + BD=0.0 + END IF + R=SQRT(R2) + IF (R.NE.0.0) THEN + RD=(XYP+Z*ZD)/R + ELSE + RD=0.0 + END IF + + END diff --git a/src/slalib/cd2tf.f b/src/slalib/cd2tf.f new file mode 100644 index 0000000..abd26ef --- /dev/null +++ b/src/slalib/cd2tf.f @@ -0,0 +1,55 @@ + SUBROUTINE sla_CD2TF (NDP, DAYS, SIGN, IHMSF) +*+ +* - - - - - - +* C D 2 T F +* - - - - - - +* +* Convert an interval in days into hours, minutes, seconds +* +* (single precision) +* +* Given: +* NDP int number of decimal places of seconds +* DAYS real interval in days +* +* Returned: +* SIGN char '+' or '-' +* IHMSF int(4) hours, minutes, seconds, fraction +* +* Notes: +* +* 1) NDP less than zero is interpreted as zero. +* +* 2) The largest useful value for NDP is determined by the size of +* DAYS, the format of REAL floating-point numbers on the target +* machine, and the risk of overflowing IHMSF(4). For example, +* on the VAX, for DAYS up to 1.0, the available floating-point +* precision corresponds roughly to NDP=3. This is well below +* the ultimate limit of NDP=9 set by the capacity of the 32-bit +* integer IHMSF(4). +* +* 3) The absolute value of DAYS may exceed 1.0. In cases where it +* does not, it is up to the caller to test for and handle the +* case where DAYS is very nearly 1.0 and rounds up to 24 hours, +* by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +* +* Called: sla_DD2TF +* +* P.T.Wallace Starlink 12 December 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER NDP + REAL DAYS + CHARACTER SIGN*(*) + INTEGER IHMSF(4) + + + +* Call double precision version + CALL sla_DD2TF(NDP,DBLE(DAYS),SIGN,IHMSF) + + END diff --git a/src/slalib/cldj.f b/src/slalib/cldj.f new file mode 100644 index 0000000..0536259 --- /dev/null +++ b/src/slalib/cldj.f @@ -0,0 +1,78 @@ + SUBROUTINE sla_CLDJ (IY, IM, ID, DJM, J) +*+ +* - - - - - +* C L D J +* - - - - - +* +* Gregorian Calendar to Modified Julian Date +* +* Given: +* IY,IM,ID int year, month, day in Gregorian calendar +* +* Returned: +* DJM dp modified Julian Date (JD-2400000.5) for 0 hrs +* J int status: +* 0 = OK +* 1 = bad year (MJD not computed) +* 2 = bad month (MJD not computed) +* 3 = bad day (MJD computed) +* +* The year must be -4699 (i.e. 4700BC) or later. +* +* The algorithm is derived from that of Hatcher 1984 +* (QJRAS 25, 53-55). +* +* P.T.Wallace Starlink 11 March 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IY,IM,ID + DOUBLE PRECISION DJM + INTEGER J + +* Month lengths in days + INTEGER MTAB(12) + DATA MTAB / 31,28,31,30,31,30,31,31,30,31,30,31 / + + + +* Preset status + J=0 + +* Validate year + IF (IY.LT.-4699) THEN + J=1 + ELSE + +* Validate month + IF (IM.GE.1.AND.IM.LE.12) THEN + +* Allow for leap year + IF (MOD(IY,4).EQ.0) THEN + MTAB(2)=29 + ELSE + MTAB(2)=28 + END IF + IF (MOD(IY,100).EQ.0.AND.MOD(IY,400).NE.0) + : MTAB(2)=28 + +* Validate day + IF (ID.LT.1.OR.ID.GT.MTAB(IM)) J=3 + +* Modified Julian Date + DJM=DBLE((1461*(IY-(12-IM)/10+4712))/4 + : +(306*MOD(IM+9,12)+5)/10 + : -(3*((IY-(12-IM)/10+4900)/100))/4 + : +ID-2399904) + +* Bad month + ELSE + J=2 + END IF + + END IF + + END diff --git a/src/slalib/clyd.f b/src/slalib/clyd.f new file mode 100644 index 0000000..ee4fb92 --- /dev/null +++ b/src/slalib/clyd.f @@ -0,0 +1,101 @@ + SUBROUTINE sla_CLYD (IY, IM, ID, NY, ND, JSTAT) +*+ +* - - - - - +* C L Y D +* - - - - - +* +* Gregorian calendar to year and day in year (in a Julian calendar +* aligned to the 20th/21st century Gregorian calendar). +* +* Given: +* IY,IM,ID i year, month, day in Gregorian calendar +* +* Returned: +* NY i year (re-aligned Julian calendar) +* ND i day in year (1 = January 1st) +* JSTAT i status: +* 0 = OK +* 1 = bad year (before -4711) +* 2 = bad month +* 3 = bad day (but conversion performed) +* +* Notes: +* +* 1 This routine exists to support the low-precision routines +* sla_EARTH, sla_MOON and sla_ECOR. +* +* 2 Between 1900 March 1 and 2100 February 28 it returns answers +* which are consistent with the ordinary Gregorian calendar. +* Outside this range there will be a discrepancy which increases +* by one day for every non-leap century year. +* +* 3 The essence of the algorithm is first to express the Gregorian +* date as a Julian Day Number and then to convert this back to +* a Julian calendar date, with day-in-year instead of month and +* day. See 12.92-1 and 12.95-1 in the reference. +* +* Reference: Explanatory Supplement to the Astronomical Almanac, +* ed P.K.Seidelmann, University Science Books (1992), +* p604-606. +* +* P.T.Wallace Starlink 26 November 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IY,IM,ID,NY,ND,JSTAT + + INTEGER I,J,K,L,N + +* Month lengths in days + INTEGER MTAB(12) + DATA MTAB/31,28,31,30,31,30,31,31,30,31,30,31/ + + + +* Preset status + JSTAT=0 + +* Validate year + IF (IY.GE.-4711) THEN + +* Validate month + IF (IM.GE.1.AND.IM.LE.12) THEN + +* Allow for (Gregorian) leap year + IF (MOD(IY,4).EQ.0.AND. + : (MOD(IY,100).NE.0.OR.MOD(IY,400).EQ.0)) THEN + MTAB(2)=29 + ELSE + MTAB(2)=28 + END IF + +* Validate day + IF (ID.LT.1.OR.ID.GT.MTAB(IM)) JSTAT=3 + +* Perform the conversion + I=(14-IM)/12 + K=IY-I + J=(1461*(K+4800))/4+(367*(IM-2+12*I))/12 + : -(3*((K+4900)/100))/4+ID-30660 + K=(J-1)/1461 + L=J-1461*K + N=(L-1)/365-L/1461 + J=((80*(L-365*N+30))/2447)/11 + I=N+J + ND=59+L-365*I+((4-N)/4)*(1-J) + NY=4*K+I-4716 + +* Bad month + ELSE + JSTAT=2 + END IF + ELSE + +* Bad year + JSTAT=1 + END IF + + END diff --git a/src/slalib/combn.f b/src/slalib/combn.f new file mode 100644 index 0000000..9e2354d --- /dev/null +++ b/src/slalib/combn.f @@ -0,0 +1,142 @@ + SUBROUTINE sla_COMBN ( NSEL, NCAND, LIST, J ) +*+ +* - - - - - - +* C O M B N +* - - - - - - +* +* Generate the next combination, a subset of a specified size chosen +* from a specified number of items. +* +* Given: +* NSEL i number of items (subset size) +* NCAND i number of candidates (set size) +* +* Given and returned: +* LIST i(NSEL) latest combination, LIST(1)=0 to initialize +* +* Returned: +* J i status: -1 = illegal NSEL or NCAND +* 0 = OK +* +1 = no more combinations available +* +* Notes: +* +* 1) NSEL and NCAND must both be at least 1, and NSEL must be less +* than or equal to NCAND. +* +* 2) This routine returns, in the LIST array, a subset of NSEL integers +* chosen from the range 1 to NCAND inclusive, in ascending order. +* Before calling the routine for the first time, the caller must set +* the first element of the LIST array to zero (any value less than 1 +* will do) to cause initialization. +* +* 2) The first combination to be generated is: +* +* LIST(1)=1, LIST(2)=2, ..., LIST(NSEL)=NSEL +* +* This is also the combination returned for the "finished" (J=1) +* case. +* +* The final permutation to be generated is: +* +* LIST(1)=NCAND, LIST(2)=NCAND-1, ..., LIST(NSEL)=NCAND-NSEL+1 +* +* 3) If the "finished" (J=1) status is ignored, the routine +* continues to deliver combinations, the pattern repeating +* every NCAND!/(NSEL!*(NCAND-NSEL)!) calls. +* +* 4) The algorithm is by R.F.Warren-Smith (private communication). +* +* P.T.Wallace Starlink 25 August 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER NSEL,NCAND,LIST(NSEL),J + + INTEGER I,LISTI,NMAX,M + LOGICAL MORE + + +* Validate, and set status. + IF (NSEL.LT.1.OR.NCAND.LT.1.OR.NSEL.GT.NCAND) THEN + J = -1 + GO TO 9999 + ELSE + J = 0 + END IF + +* Just starting? + IF (LIST(1).LT.1) THEN + +* Yes: return 1,2,3... + DO I=1,NSEL + LIST(I) = I + END DO + + ELSE + +* No: find the first selection that we can increment. + +* Start with the first list item. + I = 1 + +* Loop. + MORE = .TRUE. + DO WHILE (MORE) + +* Current list item. + LISTI = LIST(I) + +* Is this the final list item? + IF (I.GE.NSEL) THEN + +* Yes: comparison value is number of candidates plus one. + NMAX = NCAND+1 + ELSE + +* No: comparison value is next list item. + NMAX = LIST(I+1) + END IF + +* Can the current item be incremented? + IF (NMAX-LISTI.GT.1) THEN + +* Yes: increment it. + LIST(I) = LISTI+1 + +* Reinitialize the preceding items. + DO M=1,I-1 + LIST(M) = M + END DO + +* Break. + MORE = .FALSE. + ELSE + +* Can't increment the current item: is it the final one? + IF (I.GE.NSEL) THEN + +* Yes: set the status. + J = 1 + +* Restart the sequence. + DO I=1,NSEL + LIST(I) = I + END DO + +* Break. + MORE = .FALSE. + ELSE + +* No: next list item. + I = I+1 + END IF + END IF + END DO + END IF + 9999 CONTINUE + + END diff --git a/src/slalib/cr2af.f b/src/slalib/cr2af.f new file mode 100644 index 0000000..74afa0f --- /dev/null +++ b/src/slalib/cr2af.f @@ -0,0 +1,58 @@ + SUBROUTINE sla_CR2AF (NDP, ANGLE, SIGN, IDMSF) +*+ +* - - - - - - +* C R 2 A F +* - - - - - - +* +* Convert an angle in radians into degrees, arcminutes, arcseconds +* (single precision) +* +* Given: +* NDP int number of decimal places of arcseconds +* ANGLE real angle in radians +* +* Returned: +* SIGN char '+' or '-' +* IDMSF int(4) degrees, arcminutes, arcseconds, fraction +* +* Notes: +* +* 1) NDP less than zero is interpreted as zero. +* +* 2) The largest useful value for NDP is determined by the size of +* ANGLE, the format of REAL floating-point numbers on the target +* machine, and the risk of overflowing IDMSF(4). For example, +* on the VAX, for ANGLE up to 2pi, the available floating-point +* precision corresponds roughly to NDP=3. This is well below +* the ultimate limit of NDP=9 set by the capacity of the 32-bit +* integer IHMSF(4). +* +* 3) The absolute value of ANGLE may exceed 2pi. In cases where it +* does not, it is up to the caller to test for and handle the +* case where ANGLE is very nearly 2pi and rounds up to 360 deg, +* by testing for IDMSF(1)=360 and setting IDMSF(1-4) to zero. +* +* Called: sla_CD2TF +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER NDP + REAL ANGLE + CHARACTER SIGN*(*) + INTEGER IDMSF(4) + +* Hours to degrees * radians to turns + REAL F + PARAMETER (F=15.0/6.283185307179586476925287) + + + +* Scale then use days to h,m,s routine + CALL sla_CD2TF(NDP,ANGLE*F,SIGN,IDMSF) + + END diff --git a/src/slalib/cr2tf.f b/src/slalib/cr2tf.f new file mode 100644 index 0000000..3e9214b --- /dev/null +++ b/src/slalib/cr2tf.f @@ -0,0 +1,58 @@ + SUBROUTINE sla_CR2TF (NDP, ANGLE, SIGN, IHMSF) +*+ +* - - - - - - +* C R 2 T F +* - - - - - - +* +* Convert an angle in radians into hours, minutes, seconds +* (single precision) +* +* Given: +* NDP int number of decimal places of seconds +* ANGLE real angle in radians +* +* Returned: +* SIGN char '+' or '-' +* IHMSF int(4) hours, minutes, seconds, fraction +* +* Notes: +* +* 1) NDP less than zero is interpreted as zero. +* +* 2) The largest useful value for NDP is determined by the size of +* ANGLE, the format of REAL floating-point numbers on the target +* machine, and the risk of overflowing IHMSF(4). For example, +* on the VAX, for ANGLE up to 2pi, the available floating-point +* precision corresponds roughly to NDP=3. This is well below +* the ultimate limit of NDP=9 set by the capacity of the 32-bit +* integer IHMSF(4). +* +* 3) The absolute value of ANGLE may exceed 2pi. In cases where it +* does not, it is up to the caller to test for and handle the +* case where ANGLE is very nearly 2pi and rounds up to 24 hours, +* by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +* +* Called: sla_CD2TF +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER NDP + REAL ANGLE + CHARACTER SIGN*(*) + INTEGER IHMSF(4) + +* Turns to radians + REAL T2R + PARAMETER (T2R=6.283185307179586476925287) + + + +* Scale then use days to h,m,s routine + CALL sla_CD2TF(NDP,ANGLE/T2R,SIGN,IHMSF) + + END diff --git a/src/slalib/create.com b/src/slalib/create.com new file mode 100755 index 0000000..161584c --- /dev/null +++ b/src/slalib/create.com @@ -0,0 +1,140 @@ +$! +$! - - - - - - - +$! C R E A T E +$! - - - - - - - +$! +$! Create SLALIB releases from source - VAX and Unix +$! +$! The command is @CREATE +$! +$! The default directory must be the one containing the source +$! modules. The VAX release will be inserted into [.RELEASE] +$! and the Unix release into [.UNIX]. Prior contents of any +$! pre-existing [.RELEASE] and [.UNIX] directories will be lost. +$! +$! P.T.Wallace Starlink 22 January 1998 +$! +$!---------------------------------------------------------------------- +$! +$! VMS +$! +$! Create an empty [.RELEASE] directory +$ IF F$SEARCH("RELEASE.DIR").EQS."" THEN $CREATE/DIR [.RELEASE] +$ IF F$SEARCH("[.RELEASE]*.*").NES."" THEN $DELETE [.RELEASE]*.*;* +$! +$! Copy the document and news item +$ COPY SUN67.TEX [.RELEASE]*.* +$ COPY SLA.NEWS [.RELEASE]*.* +$! +$! Initialise the text and object libraries +$ LIBR/CREATE/TEXT [.RELEASE]SLALIB.TLB +$ PURGE [.RELEASE]SLALIB.TLB +$ LIBR/CREATE [.RELEASE]SLALIB.OLB +$ PURGE [.RELEASE]SLALIB.OLB +$! +$! Update the libraries +$UPOBJ: +$ FILE = F$SEARCH("*.FOR") +$ IF FILE .EQS. "" THEN GOTO UPOBJX +$ NAME = F$PARSE(FILE,,,"NAME") +$ @PUT 'NAME' +$ GOTO UPOBJ +$UPOBJX: +$ @PUT GRESID.VAX +$ @PUT RANDOM.VAX +$ @PUT WAIT.VAX +$! +$! Compress +$ LIBR/COMP/DATA=REDUCE/TEXT/OUTPUT=[.RELEASE]SLALIB.TLB - + [.RELEASE]SLALIB.TLB +$ PURGE [.RELEASE]SLALIB.TLB +$ LIBR/COMP/OUTPUT=[.RELEASE]SLALIB.OLB [.RELEASE]SLALIB.OLB +$ PURGE [.RELEASE]SLALIB.OLB +$! +$!---------------------------------------------------------------------- +$! +$! UNIX +$! +$! Create an empty [.UNIX] directory +$ IF F$SEARCH("UNIX.DIR").EQS."" THEN $CREATE/DIR [.UNIX] +$ IF F$SEARCH("[.UNIX]*.*").NES."" THEN $DELETE [.UNIX]*.*;* +$! +$! Copy the platform-independent Fortran source +$FLOOP: +$ FILE = F$SEARCH("*.FOR") +$ IF FILE.EQS."" THEN $GOTO FLOOPX +$ FILE=F$EXTRACT(0,F$LOCATE(";",FILE),FILE) +$ NAME = F$PARSE(FILE,,,"NAME") +$ IF NAME .EQS. "GRESID" THEN $GOTO FLOOP +$ IF NAME .EQS. "RANDOM" THEN $GOTO FLOOP +$ IF NAME .EQS. "WAIT" THEN $GOTO FLOOP +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT 'FILE' [.UNIX]'NAME'.F +$ GOTO FLOOP +$FLOOPX: +$! +$! Copy the platform specific source code +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT GRESID.VAX [.UNIX]GRESID.VAX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT GRESID.PCM [.UNIX]GRESID.PCM +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT GRESID.CNVX [.UNIX]GRESID.CNVX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT GRESID.MIPS [.UNIX]GRESID.MIPS +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT GRESID.SUN4 [.UNIX]GRESID.SUN4 +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT GRESID.LNX [.UNIX]GRESID.LNX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT GRESID.DEC [.UNIX]GRESID.DEC +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT RANDOM.VAX [.UNIX]RANDOM.VAX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT RANDOM.PCM [.UNIX]RANDOM.PCM +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT RANDOM.CNVX [.UNIX]RANDOM.CNVX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT RANDOM.MIPS [.UNIX]RANDOM.MIPS +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT RANDOM.SUN4 [.UNIX]RANDOM.SUN4 +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT RANDOM.LNX [.UNIX]RANDOM.LNX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT RANDOM.DEC [.UNIX]RANDOM.DEC +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT RTL_RANDOM.C [.UNIX]RTL_RANDOM.C +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT WAIT.VAX [.UNIX]WAIT.VAX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT WAIT.PCM [.UNIX]WAIT.PCM +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT WAIT.CNVX [.UNIX]WAIT.CNVX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT WAIT.MIPS [.UNIX]WAIT.MIPS +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT WAIT.SUN4 [.UNIX]WAIT.SUN4 +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT WAIT.LNX [.UNIX]WAIT.LNX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT WAIT.DEC [.UNIX]WAIT.DEC +$! +$! Copy the miscellaneous files +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT MK [.UNIX]MK +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT MAKEFILE [.UNIX]MAKEFILE +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT SLA_LINK [.UNIX]SLA_LINK +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT SLA_LINK_ADAM [.UNIX]SLA_LINK_ADAM +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT SUN67.TEX [.UNIX]SUN67.TEX +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT READ.ME [.UNIX]READ.ME +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT SLA.NEWS [.UNIX]SLA.NEWS +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT PC.BAT [.UNIX]PC.BAT +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT REP.BAT [.UNIX]REP.BAT +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT CREATE.COM [.UNIX]CREATE.COM +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT PUT.COM [.UNIX]PUT.COM +$ CONVERT/FDL=SYS$SYSTEM:UCX$CONVERT VAX_TO_UNIX.USH [.UNIX]VAX_TO_UNIX. +$! ^^^ +$! The USH suffix prevents accidental +$! execution of the script when the +$! working directory is .RELEASE instead +$! of .UNIX +$! +$! Explain what to do next +$ COPY SYS$INPUT SYS$OUTPUT + + To complete building the Unix release, please do the following: + + 1) Login to the Unix machine. + + 2) Locate the NFS-served directory corresponding to subdirectory + [.UNIX] of the current default directory. + + 3) For efficiency, and to avoid possible problems involving case + sensitivity in filenames, copy all the files in that directory + to a scratch directory on the Unix machine. + + 4) Type "vax_to_unix" to archive all the source files. + +$! +$!---------------------------------------------------------------------- +$! +$! Wrap up +$ PURGE [...] +$ SET FILE/TRUNCATE [...]*.*/EXCLUDE=CREATE.COM +$ EXIT diff --git a/src/slalib/cs2c.f b/src/slalib/cs2c.f new file mode 100644 index 0000000..7d516c8 --- /dev/null +++ b/src/slalib/cs2c.f @@ -0,0 +1,41 @@ + SUBROUTINE sla_CS2C (A, B, V) +*+ +* - - - - - +* C S 2 C +* - - - - - +* +* Spherical coordinates to direction cosines (single precision) +* +* Given: +* A,B real spherical coordinates in radians +* (RA,Dec), (Long,Lat) etc +* +* Returned: +* V real(3) x,y,z unit vector +* +* The spherical coordinates are longitude (+ve anticlockwise +* looking from the +ve latitude pole) and latitude. The +* Cartesian coordinates are right handed, with the x axis +* at zero longitude and latitude, and the z axis at the +* +ve latitude pole. +* +* P.T.Wallace Starlink October 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL A,B,V(3) + + REAL COSB + + + + COSB=COS(B) + + V(1)=COS(A)*COSB + V(2)=SIN(A)*COSB + V(3)=SIN(B) + + END diff --git a/src/slalib/cs2c6.f b/src/slalib/cs2c6.f new file mode 100644 index 0000000..e0b9e06 --- /dev/null +++ b/src/slalib/cs2c6.f @@ -0,0 +1,56 @@ + SUBROUTINE sla_CS2C6 (A, B, R, AD, BD, RD, V) +*+ +* - - - - - - +* C S 2 C 6 +* - - - - - - +* +* Conversion of position & velocity in spherical coordinates +* to Cartesian coordinates (single precision) +* +* Given: +* A r longitude (radians) +* B r latitude (radians) +* R r radial coordinate +* AD r longitude derivative (radians per unit time) +* BD r latitude derivative (radians per unit time) +* RD r radial derivative +* +* Returned: +* V r(6) Cartesian position & velocity vector +* +* P.T.Wallace Starlink November 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL A,B,R,AD,BD,RD,V(6) + + REAL SA,CA,SB,CB,RCB,X,Y,RBD,CBRD,W + + + +* Useful functions + SA=SIN(A) + CA=COS(A) + SB=SIN(B) + CB=COS(B) + RCB=R*CB + X=RCB*CA + Y=RCB*SA + RBD=R*BD + CBRD=CB*RD + W=RBD*SB-CB*RD + +* Position + V(1)=X + V(2)=Y + V(3)=R*SB + +* Velocity + V(4)=-Y*AD-W*CA + V(5)=X*AD-W*SA + V(6)=RBD*CB+SB*RD + + END diff --git a/src/slalib/ctf2d.f b/src/slalib/ctf2d.f new file mode 100644 index 0000000..9280616 --- /dev/null +++ b/src/slalib/ctf2d.f @@ -0,0 +1,56 @@ + SUBROUTINE sla_CTF2D (IHOUR, IMIN, SEC, DAYS, J) +*+ +* - - - - - - +* C T F 2 D +* - - - - - - +* +* Convert hours, minutes, seconds to days (single precision) +* +* Given: +* IHOUR int hours +* IMIN int minutes +* SEC real seconds +* +* Returned: +* DAYS real interval in days +* J int status: 0 = OK +* 1 = IHOUR outside range 0-23 +* 2 = IMIN outside range 0-59 +* 3 = SEC outside range 0-59.999... +* +* Notes: +* +* 1) The result is computed even if any of the range checks +* fail. +* +* 2) The sign must be dealt with outside this routine. +* +* P.T.Wallace Starlink November 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IHOUR,IMIN + REAL SEC,DAYS + INTEGER J + +* Seconds per day + REAL D2S + PARAMETER (D2S=86400.0) + + + +* Preset status + J=0 + +* Validate sec, min, hour + IF (SEC.LT.0.0.OR.SEC.GE.60.0) J=3 + IF (IMIN.LT.0.OR.IMIN.GT.59) J=2 + IF (IHOUR.LT.0.OR.IHOUR.GT.23) J=1 + +* Compute interval + DAYS=(60.0*(60.0*REAL(IHOUR)+REAL(IMIN))+SEC)/D2S + + END diff --git a/src/slalib/ctf2r.f b/src/slalib/ctf2r.f new file mode 100644 index 0000000..585d587 --- /dev/null +++ b/src/slalib/ctf2r.f @@ -0,0 +1,54 @@ + SUBROUTINE sla_CTF2R (IHOUR, IMIN, SEC, RAD, J) +*+ +* - - - - - - +* C T F 2 R +* - - - - - - +* +* Convert hours, minutes, seconds to radians (single precision) +* +* Given: +* IHOUR int hours +* IMIN int minutes +* SEC real seconds +* +* Returned: +* RAD real angle in radians +* J int status: 0 = OK +* 1 = IHOUR outside range 0-23 +* 2 = IMIN outside range 0-59 +* 3 = SEC outside range 0-59.999... +* +* Called: +* sla_CTF2D +* +* Notes: +* +* 1) The result is computed even if any of the range checks +* fail. +* +* 2) The sign must be dealt with outside this routine. +* +* P.T.Wallace Starlink November 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IHOUR,IMIN + REAL SEC,RAD + INTEGER J + + REAL TURNS + +* Turns to radians + REAL T2R + PARAMETER (T2R=6.283185307179586476925287) + + + +* Convert to turns then radians + CALL sla_CTF2D(IHOUR,IMIN,SEC,TURNS,J) + RAD=T2R*TURNS + + END diff --git a/src/slalib/daf2r.f b/src/slalib/daf2r.f new file mode 100644 index 0000000..3f89864 --- /dev/null +++ b/src/slalib/daf2r.f @@ -0,0 +1,55 @@ + SUBROUTINE sla_DAF2R (IDEG, IAMIN, ASEC, RAD, J) +*+ +* - - - - - - +* D A F 2 R +* - - - - - - +* +* Convert degrees, arcminutes, arcseconds to radians +* (double precision) +* +* Given: +* IDEG int degrees +* IAMIN int arcminutes +* ASEC dp arcseconds +* +* Returned: +* RAD dp angle in radians +* J int status: 0 = OK +* 1 = IDEG outside range 0-359 +* 2 = IAMIN outside range 0-59 +* 3 = ASEC outside range 0-59.999... +* +* Notes: +* 1) The result is computed even if any of the range checks +* fail. +* 2) The sign must be dealt with outside this routine. +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IDEG,IAMIN + DOUBLE PRECISION ASEC,RAD + INTEGER J + +* Arc seconds to radians + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + + + +* Preset status + J=0 + +* Validate arcsec, arcmin, deg + IF (ASEC.LT.0D0.OR.ASEC.GE.60D0) J=3 + IF (IAMIN.LT.0.OR.IAMIN.GT.59) J=2 + IF (IDEG.LT.0.OR.IDEG.GT.359) J=1 + +* Compute angle + RAD=AS2R*(60D0*(60D0*DBLE(IDEG)+DBLE(IAMIN))+ASEC) + + END diff --git a/src/slalib/dafin.f b/src/slalib/dafin.f new file mode 100644 index 0000000..e8dc456 --- /dev/null +++ b/src/slalib/dafin.f @@ -0,0 +1,163 @@ + SUBROUTINE sla_DAFIN (STRING, IPTR, A, J) +*+ +* - - - - - - +* D A F I N +* - - - - - - +* +* Sexagesimal character string to angle (double precision) +* +* Given: +* STRING c*(*) string containing deg, arcmin, arcsec fields +* IPTR i pointer to start of decode (1st = 1) +* +* Returned: +* IPTR i advanced past the decoded angle +* A d angle in radians +* J i status: 0 = OK +* +1 = default, A unchanged +* -1 = bad degrees ) +* -2 = bad arcminutes ) (note 3) +* -3 = bad arcseconds ) +* +* Example: +* +* argument before after +* +* STRING '-57 17 44.806 12 34 56.7' unchanged +* IPTR 1 16 (points to 12...) +* A ? -1.00000D0 +* J ? 0 +* +* A further call to sla_DAFIN, without adjustment of IPTR, will +* decode the second angle, 12deg 34min 56.7sec. +* +* Notes: +* +* 1) The first three "fields" in STRING are degrees, arcminutes, +* arcseconds, separated by spaces or commas. The degrees field +* may be signed, but not the others. The decoding is carried +* out by the DFLTIN routine and is free-format. +* +* 2) Successive fields may be absent, defaulting to zero. For +* zero status, the only combinations allowed are degrees alone, +* degrees and arcminutes, and all three fields present. If all +* three fields are omitted, a status of +1 is returned and A is +* unchanged. In all other cases A is changed. +* +* 3) Range checking: +* +* The degrees field is not range checked. However, it is +* expected to be integral unless the other two fields are absent. +* +* The arcminutes field is expected to be 0-59, and integral if +* the arcseconds field is present. If the arcseconds field +* is absent, the arcminutes is expected to be 0-59.9999... +* +* The arcseconds field is expected to be 0-59.9999... +* +* 4) Decoding continues even when a check has failed. Under these +* circumstances the field takes the supplied value, defaulting +* to zero, and the result A is computed and returned. +* +* 5) Further fields after the three expected ones are not treated +* as an error. The pointer IPTR is left in the correct state +* for further decoding with the present routine or with DFLTIN +* etc. See the example, above. +* +* 6) If STRING contains hours, minutes, seconds instead of degrees +* etc, or if the required units are turns (or days) instead of +* radians, the result A should be multiplied as follows: +* +* for to obtain multiply +* STRING A in A by +* +* d ' " radians 1 = 1D0 +* d ' " turns 1/2pi = 0.1591549430918953358D0 +* h m s radians 15 = 15D0 +* h m s days 15/2pi = 2.3873241463784300365D0 +* +* Called: sla_DFLTIN +* +* P.T.Wallace Starlink 1 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) STRING + INTEGER IPTR + DOUBLE PRECISION A + INTEGER J + + DOUBLE PRECISION AS2R + PARAMETER (AS2R=4.84813681109535993589914102358D-6) + INTEGER JF,JD,JM,JS + DOUBLE PRECISION DEG,ARCMIN,ARCSEC + + + +* Preset the status to OK + JF=0 + +* Defaults + DEG=0D0 + ARCMIN=0D0 + ARCSEC=0D0 + +* Decode degrees, arcminutes, arcseconds + CALL sla_DFLTIN(STRING,IPTR,DEG,JD) + IF (JD.GT.1) THEN + JF=-1 + ELSE + CALL sla_DFLTIN(STRING,IPTR,ARCMIN,JM) + IF (JM.LT.0.OR.JM.GT.1) THEN + JF=-2 + ELSE + CALL sla_DFLTIN(STRING,IPTR,ARCSEC,JS) + IF (JS.LT.0.OR.JS.GT.1) THEN + JF=-3 + +* See if the combination of fields is credible + ELSE IF (JD.GT.0) THEN +* No degrees: arcmin, arcsec ought also to be absent + IF (JM.EQ.0) THEN +* Suspect arcmin + JF=-2 + ELSE IF (JS.EQ.0) THEN +* Suspect arcsec + JF=-3 + ELSE +* All three fields absent + JF=1 + END IF +* Degrees present: if arcsec present so ought arcmin to be + ELSE IF (JM.NE.0.AND.JS.EQ.0) THEN + JF=-3 + +* Tests for range and integrality + +* Degrees + ELSE IF (JM.EQ.0.AND.DINT(DEG).NE.DEG) THEN + JF=-1 +* Arcminutes + ELSE IF ((JS.EQ.0.AND.DINT(ARCMIN).NE.ARCMIN).OR. + : ARCMIN.GE.60D0) THEN + JF=-2 +* Arcseconds + ELSE IF (ARCSEC.GE.60D0) THEN + JF=-3 + END IF + END IF + END IF + +* Unless all three fields absent, compute angle value + IF (JF.LE.0) THEN + A=AS2R*(60D0*(60D0*ABS(DEG)+ARCMIN)+ARCSEC) + IF (JD.LT.0) A=-A + END IF + +* Return the status + J=JF + + END diff --git a/src/slalib/dat.f b/src/slalib/dat.f new file mode 100644 index 0000000..423e59b --- /dev/null +++ b/src/slalib/dat.f @@ -0,0 +1,219 @@ + DOUBLE PRECISION FUNCTION sla_DAT (UTC) +*+ +* - - - - +* D A T +* - - - - +* +* Increment to be applied to Coordinated Universal Time UTC to give +* International Atomic Time TAI (double precision) +* +* Given: +* UTC d UTC date as a modified JD (JD-2400000.5) +* +* Result: TAI-UTC in seconds +* +* Notes: +* +* 1 The UTC is specified to be a date rather than a time to indicate +* that care needs to be taken not to specify an instant which lies +* within a leap second. Though in most cases UTC can include the +* fractional part, correct behaviour on the day of a leap second +* can only be guaranteed up to the end of the second 23:59:59. +* +* 2 For epochs from 1961 January 1 onwards, the expressions from the +* file ftp://maia.usno.navy.mil/ser7/tai-utc.dat are used. +* +* 3 The 5ms timestep at 1961 January 1 is taken from 2.58.1 (p87) of +* the 1992 Explanatory Supplement. +* +* 4 UTC began at 1960 January 1.0 (JD 2436934.5) and it is improper +* to call the routine with an earlier epoch. However, if this +* is attempted, the TAI-UTC expression for the year 1960 is used. +* +* +* :-----------------------------------------: +* : : +* : IMPORTANT : +* : : +* : This routine must be updated on each : +* : occasion that a leap second is : +* : announced : +* : : +* : Latest leap second: 1999 January 1 : +* : : +* :-----------------------------------------: +* +* P.T.Wallace Starlink 31 May 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION UTC + + DOUBLE PRECISION DT + + + + IF (.FALSE.) THEN + +* - - - - - - - - - - - - - - - - - - - - - - * +* Add new code here on each occasion that a * +* leap second is announced, and update the * +* preamble comments appropriately. * +* - - - - - - - - - - - - - - - - - - - - - - * + +* 1999 January 1 + ELSE IF (UTC.GE.51179D0) THEN + DT=32D0 + +* 1997 July 1 + ELSE IF (UTC.GE.50630D0) THEN + DT=31D0 + +* 1996 January 1 + ELSE IF (UTC.GE.50083D0) THEN + DT=30D0 + +* 1994 July 1 + ELSE IF (UTC.GE.49534D0) THEN + DT=29D0 + +* 1993 July 1 + ELSE IF (UTC.GE.49169D0) THEN + DT=28D0 + +* 1992 July 1 + ELSE IF (UTC.GE.48804D0) THEN + DT=27D0 + +* 1991 January 1 + ELSE IF (UTC.GE.48257D0) THEN + DT=26D0 + +* 1990 January 1 + ELSE IF (UTC.GE.47892D0) THEN + DT=25D0 + +* 1988 January 1 + ELSE IF (UTC.GE.47161D0) THEN + DT=24D0 + +* 1985 July 1 + ELSE IF (UTC.GE.46247D0) THEN + DT=23D0 + +* 1983 July 1 + ELSE IF (UTC.GE.45516D0) THEN + DT=22D0 + +* 1982 July 1 + ELSE IF (UTC.GE.45151D0) THEN + DT=21D0 + +* 1981 July 1 + ELSE IF (UTC.GE.44786D0) THEN + DT=20D0 + +* 1980 January 1 + ELSE IF (UTC.GE.44239D0) THEN + DT=19D0 + +* 1979 January 1 + ELSE IF (UTC.GE.43874D0) THEN + DT=18D0 + +* 1978 January 1 + ELSE IF (UTC.GE.43509D0) THEN + DT=17D0 + +* 1977 January 1 + ELSE IF (UTC.GE.43144D0) THEN + DT=16D0 + +* 1976 January 1 + ELSE IF (UTC.GE.42778D0) THEN + DT=15D0 + +* 1975 January 1 + ELSE IF (UTC.GE.42413D0) THEN + DT=14D0 + +* 1974 January 1 + ELSE IF (UTC.GE.42048D0) THEN + DT=13D0 + +* 1973 January 1 + ELSE IF (UTC.GE.41683D0) THEN + DT=12D0 + +* 1972 July 1 + ELSE IF (UTC.GE.41499D0) THEN + DT=11D0 + +* 1972 January 1 + ELSE IF (UTC.GE.41317D0) THEN + DT=10D0 + +* 1968 February 1 + ELSE IF (UTC.GE.39887D0) THEN + DT=4.2131700D0+(UTC-39126D0)*0.002592D0 + +* 1966 January 1 + ELSE IF (UTC.GE.39126D0) THEN + DT=4.3131700D0+(UTC-39126D0)*0.002592D0 + +* 1965 September 1 + ELSE IF (UTC.GE.39004D0) THEN + DT=3.8401300D0+(UTC-38761D0)*0.001296D0 + +* 1965 July 1 + ELSE IF (UTC.GE.38942D0) THEN + DT=3.7401300D0+(UTC-38761D0)*0.001296D0 + +* 1965 March 1 + ELSE IF (UTC.GE.38820D0) THEN + DT=3.6401300D0+(UTC-38761D0)*0.001296D0 + +* 1965 January 1 + ELSE IF (UTC.GE.38761D0) THEN + DT=3.5401300D0+(UTC-38761D0)*0.001296D0 + +* 1964 September 1 + ELSE IF (UTC.GE.38639D0) THEN + DT=3.4401300D0+(UTC-38761D0)*0.001296D0 + +* 1964 April 1 + ELSE IF (UTC.GE.38486D0) THEN + DT=3.3401300D0+(UTC-38761D0)*0.001296D0 + +* 1964 January 1 + ELSE IF (UTC.GE.38395D0) THEN + DT=3.2401300D0+(UTC-38761D0)*0.001296D0 + +* 1963 November 1 + ELSE IF (UTC.GE.38334D0) THEN + DT=1.9458580D0+(UTC-37665D0)*0.0011232D0 + +* 1962 January 1 + ELSE IF (UTC.GE.37665D0) THEN + DT=1.8458580D0+(UTC-37665D0)*0.0011232D0 + +* 1961 August 1 + ELSE IF (UTC.GE.37512D0) THEN + DT=1.3728180D0+(UTC-37300D0)*0.001296D0 + +* 1961 January 1 + ELSE IF (UTC.GE.37300D0) THEN + DT=1.4228180D0+(UTC-37300D0)*0.001296D0 + +* Before that + ELSE + DT=1.4178180D0+(UTC-37300D0)*0.001296D0 + + END IF + + sla_DAT=DT + + END diff --git a/src/slalib/dav2m.f b/src/slalib/dav2m.f new file mode 100644 index 0000000..dc3f46c --- /dev/null +++ b/src/slalib/dav2m.f @@ -0,0 +1,67 @@ + SUBROUTINE sla_DAV2M (AXVEC, RMAT) +*+ +* - - - - - - +* D A V 2 M +* - - - - - - +* +* Form the rotation matrix corresponding to a given axial vector. +* (double precision) +* +* A rotation matrix describes a rotation about some arbitrary axis. +* The axis is called the Euler axis, and the angle through which the +* reference frame rotates is called the Euler angle. The axial +* vector supplied to this routine has the same direction as the +* Euler axis, and its magnitude is the Euler angle in radians. +* +* Given: +* AXVEC d(3) axial vector (radians) +* +* Returned: +* RMAT d(3,3) rotation matrix +* +* If AXVEC is null, the unit matrix is returned. +* +* The reference frame rotates clockwise as seen looking along +* the axial vector from the origin. +* +* P.T.Wallace Starlink June 1989 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION AXVEC(3),RMAT(3,3) + + DOUBLE PRECISION X,Y,Z,PHI,S,C,W + + + +* Euler angle - magnitude of axial vector - and functions + X = AXVEC(1) + Y = AXVEC(2) + Z = AXVEC(3) + PHI = SQRT(X*X+Y*Y+Z*Z) + S = SIN(PHI) + C = COS(PHI) + W = 1D0-C + +* Euler axis - direction of axial vector (perhaps null) + IF (PHI.NE.0D0) THEN + X = X/PHI + Y = Y/PHI + Z = Z/PHI + END IF + +* Compute the rotation matrix + RMAT(1,1) = X*X*W+C + RMAT(1,2) = X*Y*W+Z*S + RMAT(1,3) = X*Z*W-Y*S + RMAT(2,1) = X*Y*W-Z*S + RMAT(2,2) = Y*Y*W+C + RMAT(2,3) = Y*Z*W+X*S + RMAT(3,1) = X*Z*W+Y*S + RMAT(3,2) = Y*Z*W-X*S + RMAT(3,3) = Z*Z*W+C + + END diff --git a/src/slalib/dbear.f b/src/slalib/dbear.f new file mode 100644 index 0000000..7cd5818 --- /dev/null +++ b/src/slalib/dbear.f @@ -0,0 +1,42 @@ + DOUBLE PRECISION FUNCTION sla_DBEAR (A1, B1, A2, B2) +*+ +* - - - - - - +* D B E A R +* - - - - - - +* +* Bearing (position angle) of one point on a sphere relative to another +* (double precision) +* +* Given: +* A1,B1 d spherical coordinates of one point +* A2,B2 d spherical coordinates of the other point +* +* (The spherical coordinates are RA,Dec, Long,Lat etc, in radians.) +* +* The result is the bearing (position angle), in radians, of point +* A2,B2 as seen from point A1,B1. It is in the range +/- pi. If +* A2,B2 is due east of A1,B1 the bearing is +pi/2. Zero is returned +* if the two points are coincident. +* +* P.T.Wallace Starlink 23 March 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION A1,B1,A2,B2 + + DOUBLE PRECISION DA,X,Y + + + DA=A2-A1 + Y=SIN(DA)*COS(B2) + X=SIN(B2)*COS(B1)-COS(B2)*SIN(B1)*COS(DA) + IF (X.NE.0D0.OR.Y.NE.0D0) THEN + sla_DBEAR=ATAN2(Y,X) + ELSE + sla_DBEAR=0D0 + END IF + + END diff --git a/src/slalib/dbjin.f b/src/slalib/dbjin.f new file mode 100644 index 0000000..60563e4 --- /dev/null +++ b/src/slalib/dbjin.f @@ -0,0 +1,113 @@ + SUBROUTINE sla_DBJIN (STRING, NSTRT, DRESLT, J1, J2) +*+ +* - - - - - - +* D B J I N +* - - - - - - +* +* Convert free-format input into double precision floating point, +* using DFLTIN but with special syntax extensions. +* +* The purpose of the syntax extensions is to help cope with mixed +* FK4 and FK5 data. In addition to the syntax accepted by DFLTIN, +* the following two extensions are recognized by DBJIN: +* +* 1) A valid non-null field preceded by the character 'B' +* (or 'b') is accepted. +* +* 2) A valid non-null field preceded by the character 'J' +* (or 'j') is accepted. +* +* The calling program is notified of the incidence of either of these +* extensions through an supplementary status argument. The rest of +* the arguments are as for DFLTIN. +* +* Given: +* STRING char string containing field to be decoded +* NSTRT int pointer to 1st character of field in string +* +* Returned: +* NSTRT int incremented +* DRESLT double result +* J1 int DFLTIN status: -1 = -OK +* 0 = +OK +* +1 = null field +* +2 = error +* J2 int syntax flag: 0 = normal DFLTIN syntax +* +1 = 'B' or 'b' +* +2 = 'J' or 'j' +* +* Called: sla_DFLTIN +* +* For details of the basic syntax, see sla_DFLTIN. +* +* P.T.Wallace Starlink 23 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) STRING + INTEGER NSTRT + DOUBLE PRECISION DRESLT + INTEGER J1,J2 + + INTEGER J2A,LENSTR,NA,J1A,NB,J1B + CHARACTER C + + + +* Preset syntax flag + J2A=0 + +* Length of string + LENSTR=LEN(STRING) + +* Pointer to current character + NA=NSTRT + +* Attempt normal decode + CALL sla_DFLTIN(STRING,NA,DRESLT,J1A) + +* Proceed only if pointer still within string + IF (NA.GE.1.AND.NA.LE.LENSTR) THEN + +* See if DFLTIN reported a null field + IF (J1A.EQ.1) THEN + +* It did: examine character it stuck on + C=STRING(NA:NA) + IF (C.EQ.'B'.OR.C.EQ.'b') THEN +* 'B' - provisionally note + J2A=1 + ELSE IF (C.EQ.'J'.OR.C.EQ.'j') THEN +* 'J' - provisionally note + J2A=2 + END IF + +* Following B or J, attempt to decode a number + IF (J2A.EQ.1.OR.J2A.EQ.2) THEN + NB=NA+1 + CALL sla_DFLTIN(STRING,NB,DRESLT,J1B) + +* If successful, copy pointer and status + IF (J1B.LE.0) THEN + NA=NB + J1A=J1B +* If not, forget about the B or J + ELSE + J2A=0 + END IF + + END IF + + END IF + + END IF + +* Return argument values and exit + NSTRT=NA + J1=J1A + J2=J2A + + END diff --git a/src/slalib/dc62s.f b/src/slalib/dc62s.f new file mode 100644 index 0000000..2dd63ba --- /dev/null +++ b/src/slalib/dc62s.f @@ -0,0 +1,82 @@ + SUBROUTINE sla_DC62S (V, A, B, R, AD, BD, RD) +*+ +* - - - - - - +* D C 6 2 S +* - - - - - - +* +* Conversion of position & velocity in Cartesian coordinates +* to spherical coordinates (double precision) +* +* Given: +* V d(6) Cartesian position & velocity vector +* +* Returned: +* A d longitude (radians) +* B d latitude (radians) +* R d radial coordinate +* AD d longitude derivative (radians per unit time) +* BD d latitude derivative (radians per unit time) +* RD d radial derivative +* +* P.T.Wallace Starlink 28 April 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION V(6),A,B,R,AD,BD,RD + + DOUBLE PRECISION X,Y,Z,XD,YD,ZD,RXY2,RXY,R2,XYP + + + +* Components of position/velocity vector + X=V(1) + Y=V(2) + Z=V(3) + XD=V(4) + YD=V(5) + ZD=V(6) + +* Component of R in XY plane squared + RXY2=X*X+Y*Y + +* Modulus squared + R2=RXY2+Z*Z + +* Protection against null vector + IF (R2.EQ.0D0) THEN + X=XD + Y=YD + Z=ZD + RXY2=X*X+Y*Y + R2=RXY2+Z*Z + END IF + +* Position and velocity in spherical coordinates + RXY=SQRT(RXY2) + XYP=X*XD+Y*YD + IF (RXY2.NE.0D0) THEN + A=ATAN2(Y,X) + B=ATAN2(Z,RXY) + AD=(X*YD-Y*XD)/RXY2 + BD=(ZD*RXY2-Z*XYP)/(R2*RXY) + ELSE + A=0D0 + IF (Z.NE.0D0) THEN + B=ATAN2(Z,RXY) + ELSE + B=0D0 + END IF + AD=0D0 + BD=0D0 + END IF + R=SQRT(R2) + IF (R.NE.0D0) THEN + RD=(XYP+Z*ZD)/R + ELSE + RD=0D0 + END IF + + END diff --git a/src/slalib/dcc2s.f b/src/slalib/dcc2s.f new file mode 100644 index 0000000..9f5d0fe --- /dev/null +++ b/src/slalib/dcc2s.f @@ -0,0 +1,53 @@ + SUBROUTINE sla_DCC2S (V, A, B) +*+ +* - - - - - - +* D C C 2 S +* - - - - - - +* +* Direction cosines to spherical coordinates (double precision) +* +* Given: +* V d(3) x,y,z vector +* +* Returned: +* A,B d spherical coordinates in radians +* +* The spherical coordinates are longitude (+ve anticlockwise +* looking from the +ve latitude pole) and latitude. The +* Cartesian coordinates are right handed, with the x axis +* at zero longitude and latitude, and the z axis at the +* +ve latitude pole. +* +* If V is null, zero A and B are returned. +* At either pole, zero A is returned. +* +* P.T.Wallace Starlink July 1989 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION V(3),A,B + + DOUBLE PRECISION X,Y,Z,R + + + X = V(1) + Y = V(2) + Z = V(3) + R = SQRT(X*X+Y*Y) + + IF (R.EQ.0D0) THEN + A = 0D0 + ELSE + A = ATAN2(Y,X) + END IF + + IF (Z.EQ.0D0) THEN + B = 0D0 + ELSE + B = ATAN2(Z,R) + END IF + + END diff --git a/src/slalib/dcmpf.f b/src/slalib/dcmpf.f new file mode 100644 index 0000000..3689e25 --- /dev/null +++ b/src/slalib/dcmpf.f @@ -0,0 +1,140 @@ + SUBROUTINE sla_DCMPF (COEFFS,XZ,YZ,XS,YS,PERP,ORIENT) +*+ +* - - - - - - +* D C M P F +* - - - - - - +* +* Decompose an [X,Y] linear fit into its constituent parameters: +* zero points, scales, nonperpendicularity and orientation. +* +* Given: +* COEFFS d(6) transformation coefficients (see note) +* +* Returned: +* XZ d x zero point +* YZ d y zero point +* XS d x scale +* YS d y scale +* PERP d nonperpendicularity (radians) +* ORIENT d orientation (radians) +* +* The model relates two sets of [X,Y] coordinates as follows. +* Naming the elements of COEFFS: +* +* COEFFS(1) = A +* COEFFS(2) = B +* COEFFS(3) = C +* COEFFS(4) = D +* COEFFS(5) = E +* COEFFS(6) = F +* +* the model transforms coordinates [X1,Y1] into coordinates +* [X2,Y2] as follows: +* +* X2 = A + B*X1 + C*Y1 +* Y2 = D + E*X1 + F*Y1 +* +* The transformation can be decomposed into four steps: +* +* 1) Zero points: +* +* x' = XZ + X1 +* y' = YZ + Y1 +* +* 2) Scales: +* +* x'' = XS*x' +* y'' = YS*y' +* +* 3) Nonperpendicularity: +* +* x''' = cos(PERP/2)*x'' + sin(PERP/2)*y'' +* y''' = sin(PERP/2)*x'' + cos(PERP/2)*y'' +* +* 4) Orientation: +* +* X2 = cos(ORIENT)*x''' + sin(ORIENT)*y''' +* Y2 =-sin(ORIENT)*y''' + cos(ORIENT)*y''' +* +* See also sla_FITXY, sla_PXY, sla_INVF, sla_XY2XY +* +* P.T.Wallace Starlink 14 August 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION COEFFS(6),XZ,YZ,XS,YS,PERP,ORIENT + + DOUBLE PRECISION A,B,C,D,E,F,RB2E2,RC2F2,XSC,YSC,P1,P2,P,WS,WC, + : OR,HP,SHP,CHP,SOR,COR,DET,X0,Y0 + + + +* Copy the six coefficients + A=COEFFS(1) + B=COEFFS(2) + C=COEFFS(3) + D=COEFFS(4) + E=COEFFS(5) + F=COEFFS(6) + +* Scales + RB2E2=SQRT(B*B+E*E) + RC2F2=SQRT(C*C+F*F) + IF (B*F-C*E.GE.0D0) THEN + XSC=RB2E2 + ELSE + B=-B + C=-C + XSC=-RB2E2 + END IF + YSC=RC2F2 + +* Non-perpendicularity + IF (C.NE.0D0.OR.F.NE.0D0) THEN + P1=ATAN2(C,F) + ELSE + P1=0D0 + END IF + IF (E.NE.0D0.OR.B.NE.0D0) THEN + P2=ATAN2(E,B) + ELSE + P2=0D0 + END IF + P=P1+P2 + +* Orientation + WS=C*RB2E2-E*RC2F2 + WC=B*RC2F2+F*RB2E2 + IF (WS.NE.0D0.OR.WC.NE.0D0) THEN + OR=ATAN2(WS,WC) + ELSE + OR=0D0 + END IF + +* Zero corrections + HP=P/2D0 + SHP=SIN(HP) + CHP=COS(HP) + SOR=SIN(OR) + COR=COS(OR) + DET=XSC*YSC*(CHP+SHP)*(CHP-SHP) + IF (ABS(DET).GT.0D0) THEN + X0=YSC*(A*(CHP*COR-SHP*SOR)-D*(CHP*SOR+SHP*COR))/DET + Y0=XSC*(A*(CHP*SOR-SHP*COR)+D*(CHP*COR+SHP*SOR))/DET + ELSE + X0=0D0 + Y0=0D0 + END IF + +* Results + XZ=X0 + YZ=Y0 + XS=XSC + YS=YSC + PERP=P + ORIENT=OR + + END diff --git a/src/slalib/dcs2c.f b/src/slalib/dcs2c.f new file mode 100644 index 0000000..5c20009 --- /dev/null +++ b/src/slalib/dcs2c.f @@ -0,0 +1,41 @@ + SUBROUTINE sla_DCS2C (A, B, V) +*+ +* - - - - - - +* D C S 2 C +* - - - - - - +* +* Spherical coordinates to direction cosines (double precision) +* +* Given: +* A,B dp spherical coordinates in radians +* (RA,Dec), (Long,Lat) etc +* +* Returned: +* V dp(3) x,y,z unit vector +* +* The spherical coordinates are longitude (+ve anticlockwise +* looking from the +ve latitude pole) and latitude. The +* Cartesian coordinates are right handed, with the x axis +* at zero longitude and latitude, and the z axis at the +* +ve latitude pole. +* +* P.T.Wallace Starlink October 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION A,B,V(3) + + DOUBLE PRECISION COSB + + + + COSB=COS(B) + + V(1)=COS(A)*COSB + V(2)=SIN(A)*COSB + V(3)=SIN(B) + + END diff --git a/src/slalib/dd2tf.f b/src/slalib/dd2tf.f new file mode 100644 index 0000000..2fc0db6 --- /dev/null +++ b/src/slalib/dd2tf.f @@ -0,0 +1,89 @@ + SUBROUTINE sla_DD2TF (NDP, DAYS, SIGN, IHMSF) +*+ +* - - - - - - +* D D 2 T F +* - - - - - - +* +* Convert an interval in days into hours, minutes, seconds +* (double precision) +* +* Given: +* NDP i number of decimal places of seconds +* DAYS d interval in days +* +* Returned: +* SIGN c '+' or '-' +* IHMSF i(4) hours, minutes, seconds, fraction +* +* Notes: +* +* 1) NDP less than zero is interpreted as zero. +* +* 2) The largest useful value for NDP is determined by the size +* of DAYS, the format of DOUBLE PRECISION floating-point numbers +* on the target machine, and the risk of overflowing IHMSF(4). +* For example, on the VAX, for DAYS up to 1D0, the available +* floating-point precision corresponds roughly to NDP=12. +* However, the practical limit is NDP=9, set by the capacity of +* the 32-bit integer IHMSF(4). +* +* 3) The absolute value of DAYS may exceed 1D0. In cases where it +* does not, it is up to the caller to test for and handle the +* case where DAYS is very nearly 1D0 and rounds up to 24 hours, +* by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +* +* P.T.Wallace Starlink 19 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER NDP + DOUBLE PRECISION DAYS + CHARACTER SIGN*(*) + INTEGER IHMSF(4) + +* Days to seconds + DOUBLE PRECISION D2S + PARAMETER (D2S=86400D0) + + INTEGER NRS,N + DOUBLE PRECISION RS,RM,RH,A,AH,AM,AS,AF + + + +* Handle sign + IF (DAYS.GE.0D0) THEN + SIGN='+' + ELSE + SIGN='-' + END IF + +* Field units in terms of least significant figure + NRS=1 + DO N=1,NDP + NRS=NRS*10 + END DO + RS=DBLE(NRS) + RM=RS*60D0 + RH=RM*60D0 + +* Round interval and express in smallest units required + A=ANINT(RS*D2S*ABS(DAYS)) + +* Separate into fields + AH=AINT(A/RH) + A=A-AH*RH + AM=AINT(A/RM) + A=A-AM*RM + AS=AINT(A/RS) + AF=A-AS*RS + +* Return results + IHMSF(1)=MAX(NINT(AH),0) + IHMSF(2)=MAX(MIN(NINT(AM),59),0) + IHMSF(3)=MAX(MIN(NINT(AS),59),0) + IHMSF(4)=MAX(NINT(MIN(AF,RS-1D0)),0) + + END diff --git a/src/slalib/de2h.f b/src/slalib/de2h.f new file mode 100644 index 0000000..138a3f7 --- /dev/null +++ b/src/slalib/de2h.f @@ -0,0 +1,89 @@ + SUBROUTINE sla_DE2H (HA, DEC, PHI, AZ, EL) +*+ +* - - - - - +* D E 2 H +* - - - - - +* +* Equatorial to horizon coordinates: HA,Dec to Az,El +* +* (double precision) +* +* Given: +* HA d hour angle +* DEC d declination +* PHI d observatory latitude +* +* Returned: +* AZ d azimuth +* EL d elevation +* +* Notes: +* +* 1) All the arguments are angles in radians. +* +* 2) Azimuth is returned in the range 0-2pi; north is zero, +* and east is +pi/2. Elevation is returned in the range +* +/-pi/2. +* +* 3) The latitude must be geodetic. In critical applications, +* corrections for polar motion should be applied. +* +* 4) In some applications it will be important to specify the +* correct type of hour angle and declination in order to +* produce the required type of azimuth and elevation. In +* particular, it may be important to distinguish between +* elevation as affected by refraction, which would +* require the "observed" HA,Dec, and the elevation +* in vacuo, which would require the "topocentric" HA,Dec. +* If the effects of diurnal aberration can be neglected, the +* "apparent" HA,Dec may be used instead of the topocentric +* HA,Dec. +* +* 5) No range checking of arguments is carried out. +* +* 6) In applications which involve many such calculations, rather +* than calling the present routine it will be more efficient to +* use inline code, having previously computed fixed terms such +* as sine and cosine of latitude, and (for tracking a star) +* sine and cosine of declination. +* +* P.T.Wallace Starlink 9 July 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION HA,DEC,PHI,AZ,EL + + DOUBLE PRECISION D2PI + PARAMETER (D2PI=6.283185307179586476925286766559D0) + + DOUBLE PRECISION SH,CH,SD,CD,SP,CP,X,Y,Z,R,A + + +* Useful trig functions + SH=SIN(HA) + CH=COS(HA) + SD=SIN(DEC) + CD=COS(DEC) + SP=SIN(PHI) + CP=COS(PHI) + +* Az,El as x,y,z + X=-CH*CD*SP+SD*CP + Y=-SH*CD + Z=CH*CD*CP+SD*SP + +* To spherical + R=SQRT(X*X+Y*Y) + IF (R.EQ.0D0) THEN + A=0D0 + ELSE + A=ATAN2(Y,X) + END IF + IF (A.LT.0D0) A=A+D2PI + AZ=A + EL=ATAN2(Z,R) + + END diff --git a/src/slalib/deuler.f b/src/slalib/deuler.f new file mode 100644 index 0000000..6ce1479 --- /dev/null +++ b/src/slalib/deuler.f @@ -0,0 +1,163 @@ + SUBROUTINE sla_DEULER (ORDER, PHI, THETA, PSI, RMAT) +*+ +* - - - - - - - +* D E U L E R +* - - - - - - - +* +* Form a rotation matrix from the Euler angles - three successive +* rotations about specified Cartesian axes (double precision) +* +* Given: +* ORDER c*(*) specifies about which axes the rotations occur +* PHI d 1st rotation (radians) +* THETA d 2nd rotation ( " ) +* PSI d 3rd rotation ( " ) +* +* Returned: +* RMAT d(3,3) rotation matrix +* +* A rotation is positive when the reference frame rotates +* anticlockwise as seen looking towards the origin from the +* positive region of the specified axis. +* +* The characters of ORDER define which axes the three successive +* rotations are about. A typical value is 'ZXZ', indicating that +* RMAT is to become the direction cosine matrix corresponding to +* rotations of the reference frame through PHI radians about the +* old Z-axis, followed by THETA radians about the resulting X-axis, +* then PSI radians about the resulting Z-axis. +* +* The axis names can be any of the following, in any order or +* combination: X, Y, Z, uppercase or lowercase, 1, 2, 3. Normal +* axis labelling/numbering conventions apply; the xyz (=123) +* triad is right-handed. Thus, the 'ZXZ' example given above +* could be written 'zxz' or '313' (or even 'ZxZ' or '3xZ'). ORDER +* is terminated by length or by the first unrecognized character. +* +* Fewer than three rotations are acceptable, in which case the later +* angle arguments are ignored. If all rotations are zero, the +* identity matrix is produced. +* +* P.T.Wallace Starlink 23 May 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) ORDER + DOUBLE PRECISION PHI,THETA,PSI,RMAT(3,3) + + INTEGER J,I,L,N,K + DOUBLE PRECISION RESULT(3,3),ROTN(3,3),ANGLE,S,C,W,WM(3,3) + CHARACTER AXIS + + + +* Initialize result matrix + DO J=1,3 + DO I=1,3 + IF (I.NE.J) THEN + RESULT(I,J) = 0D0 + ELSE + RESULT(I,J) = 1D0 + END IF + END DO + END DO + +* Establish length of axis string + L = LEN(ORDER) + +* Look at each character of axis string until finished + DO N=1,3 + IF (N.LE.L) THEN + +* Initialize rotation matrix for the current rotation + DO J=1,3 + DO I=1,3 + IF (I.NE.J) THEN + ROTN(I,J) = 0D0 + ELSE + ROTN(I,J) = 1D0 + END IF + END DO + END DO + +* Pick up the appropriate Euler angle and take sine & cosine + IF (N.EQ.1) THEN + ANGLE = PHI + ELSE IF (N.EQ.2) THEN + ANGLE = THETA + ELSE + ANGLE = PSI + END IF + S = SIN(ANGLE) + C = COS(ANGLE) + +* Identify the axis + AXIS = ORDER(N:N) + IF (AXIS.EQ.'X'.OR. + : AXIS.EQ.'x'.OR. + : AXIS.EQ.'1') THEN + +* Matrix for x-rotation + ROTN(2,2) = C + ROTN(2,3) = S + ROTN(3,2) = -S + ROTN(3,3) = C + + ELSE IF (AXIS.EQ.'Y'.OR. + : AXIS.EQ.'y'.OR. + : AXIS.EQ.'2') THEN + +* Matrix for y-rotation + ROTN(1,1) = C + ROTN(1,3) = -S + ROTN(3,1) = S + ROTN(3,3) = C + + ELSE IF (AXIS.EQ.'Z'.OR. + : AXIS.EQ.'z'.OR. + : AXIS.EQ.'3') THEN + +* Matrix for z-rotation + ROTN(1,1) = C + ROTN(1,2) = S + ROTN(2,1) = -S + ROTN(2,2) = C + + ELSE + +* Unrecognized character - fake end of string + L = 0 + + END IF + +* Apply the current rotation (matrix ROTN x matrix RESULT) + DO I=1,3 + DO J=1,3 + W = 0D0 + DO K=1,3 + W = W+ROTN(I,K)*RESULT(K,J) + END DO + WM(I,J) = W + END DO + END DO + DO J=1,3 + DO I=1,3 + RESULT(I,J) = WM(I,J) + END DO + END DO + + END IF + + END DO + +* Copy the result + DO J=1,3 + DO I=1,3 + RMAT(I,J) = RESULT(I,J) + END DO + END DO + + END diff --git a/src/slalib/dfltin.f b/src/slalib/dfltin.f new file mode 100644 index 0000000..1fbdb94 --- /dev/null +++ b/src/slalib/dfltin.f @@ -0,0 +1,280 @@ + SUBROUTINE sla_DFLTIN (STRING, NSTRT, DRESLT, JFLAG) +*+ +* - - - - - - - +* D F L T I N +* - - - - - - - +* +* Convert free-format input into double precision floating point +* +* Given: +* STRING c string containing number to be decoded +* NSTRT i pointer to where decoding is to start +* DRESLT d current value of result +* +* Returned: +* NSTRT i advanced to next number +* DRESLT d result +* JFLAG i status: -1 = -OK, 0 = +OK, 1 = null, 2 = error +* +* Notes: +* +* 1 The reason DFLTIN has separate OK status values for + +* and - is to enable minus zero to be detected. This is +* of crucial importance when decoding mixed-radix numbers. +* For example, an angle expressed as deg, arcmin, arcsec +* may have a leading minus sign but a zero degrees field. +* +* 2 A TAB is interpreted as a space, and lowercase characters +* are interpreted as uppercase. +* +* 3 The basic format is the sequence of fields #^.^@#^, where +* # is a sign character + or -, ^ means a string of decimal +* digits, and @, which indicates an exponent, means D or E. +* Various combinations of these fields can be omitted, and +* embedded blanks are permissible in certain places. +* +* 4 Spaces: +* +* . Leading spaces are ignored. +* +* . Embedded spaces are allowed only after +, -, D or E, +* and after the decomal point if the first sequence of +* digits is absent. +* +* . Trailing spaces are ignored; the first signifies +* end of decoding and subsequent ones are skipped. +* +* 5 Delimiters: +* +* . Any character other than +,-,0-9,.,D,E or space may be +* used to signal the end of the number and terminate +* decoding. +* +* . Comma is recognized by DFLTIN as a special case; it +* is skipped, leaving the pointer on the next character. +* See 13, below. +* +* 6 Both signs are optional. The default is +. +* +* 7 The mantissa ^.^ defaults to 1. +* +* 8 The exponent @#^ defaults to D0. +* +* 9 The strings of decimal digits may be of any length. +* +* 10 The decimal point is optional for whole numbers. +* +* 11 A "null result" occurs when the string of characters being +* decoded does not begin with +,-,0-9,.,D or E, or consists +* entirely of spaces. When this condition is detected, JFLAG +* is set to 1 and DRESLT is left untouched. +* +* 12 NSTRT = 1 for the first character in the string. +* +* 13 On return from DFLTIN, NSTRT is set ready for the next +* decode - following trailing blanks and any comma. If a +* delimiter other than comma is being used, NSTRT must be +* incremented before the next call to DFLTIN, otherwise +* all subsequent calls will return a null result. +* +* 14 Errors (JFLAG=2) occur when: +* +* . a +, -, D or E is left unsatisfied; or +* +* . the decimal point is present without at least +* one decimal digit before or after it; or +* +* . an exponent more than 100 has been presented. +* +* 15 When an error has been detected, NSTRT is left +* pointing to the character following the last +* one used before the error came to light. This +* may be after the point at which a more sophisticated +* program could have detected the error. For example, +* DFLTIN does not detect that '1D999' is unacceptable +* (on a computer where this is so) until the entire number +* has been decoded. +* +* 16 Certain highly unlikely combinations of mantissa & +* exponent can cause arithmetic faults during the +* decode, in some cases despite the fact that they +* together could be construed as a valid number. +* +* 17 Decoding is left to right, one pass. +* +* 18 See also FLOTIN and INTIN +* +* Called: sla__IDCHF +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) STRING + INTEGER NSTRT + DOUBLE PRECISION DRESLT + INTEGER JFLAG + + INTEGER NPTR,MSIGN,NEXP,NDP,NVEC,NDIGIT,ISIGNX,J + DOUBLE PRECISION DMANT,DIGIT + + + +* Current character + NPTR=NSTRT + +* Set defaults: mantissa & sign, exponent & sign, decimal place count + DMANT=0D0 + MSIGN=1 + NEXP=0 + ISIGNX=1 + NDP=0 + +* Look for sign + 100 CONTINUE + CALL sla__IDCHF(STRING,NPTR,NVEC,NDIGIT,DIGIT) + GO TO ( 400, 100, 800, 500, 300, 200, 9110, 9100, 9110),NVEC +* 0-9 SP D/E . + - , ELSE END + +* Negative + 200 CONTINUE + MSIGN=-1 + +* Look for first leading decimal + 300 CONTINUE + CALL sla__IDCHF(STRING,NPTR,NVEC,NDIGIT,DIGIT) + GO TO ( 400, 300, 800, 500, 9200, 9200, 9200, 9200, 9210),NVEC +* 0-9 SP D/E . + - , ELSE END + +* Accept leading decimals + 400 CONTINUE + DMANT=DMANT*1D1+DIGIT + CALL sla__IDCHF(STRING,NPTR,NVEC,NDIGIT,DIGIT) + GO TO ( 400, 1310, 900, 600, 1300, 1300, 1300, 1300, 1310),NVEC +* 0-9 SP D/E . + - , ELSE END + +* Look for decimal when none preceded the point + 500 CONTINUE + CALL sla__IDCHF(STRING,NPTR,NVEC,NDIGIT,DIGIT) + GO TO ( 700, 500, 9200, 9200, 9200, 9200, 9200, 9200, 9210),NVEC +* 0-9 SP D/E . + - , ELSE END + +* Look for trailing decimals + 600 CONTINUE + CALL sla__IDCHF(STRING,NPTR,NVEC,NDIGIT,DIGIT) + GO TO ( 700, 1310, 900, 1300, 1300, 1300, 1300, 1300, 1310),NVEC +* 0-9 SP D/E . + - , ELSE END + +* Accept trailing decimals + 700 CONTINUE + NDP=NDP+1 + DMANT=DMANT*1D1+DIGIT + GO TO 600 + +* Exponent symbol first in field: default mantissa to 1 + 800 CONTINUE + DMANT=1D0 + +* Look for sign of exponent + 900 CONTINUE + CALL sla__IDCHF(STRING,NPTR,NVEC,NDIGIT,DIGIT) + GO TO (1200, 900, 9200, 9200, 1100, 1000, 9200, 9200, 9210),NVEC +* 0-9 SP D/E . + - , ELSE END + +* Exponent negative + 1000 CONTINUE + ISIGNX=-1 + +* Look for first digit of exponent + 1100 CONTINUE + CALL sla__IDCHF(STRING,NPTR,NVEC,NDIGIT,DIGIT) + GO TO (1200, 1100, 9200, 9200, 9200, 9200, 9200, 9200, 9210),NVEC +* 0-9 SP D/E . + - , ELSE END + +* Use exponent digit + 1200 CONTINUE + NEXP=NEXP*10+NDIGIT + IF (NEXP.GT.100) GO TO 9200 + +* Look for subsequent digits of exponent + CALL sla__IDCHF(STRING,NPTR,NVEC,NDIGIT,DIGIT) + GO TO (1200, 1310, 1300, 1300, 1300, 1300, 1300, 1300, 1310),NVEC +* 0-9 SP D/E . + - , ELSE END + +* Combine exponent and decimal place count + 1300 CONTINUE + NPTR=NPTR-1 + 1310 CONTINUE + NEXP=NEXP*ISIGNX-NDP + +* Skip if net exponent negative + IF (NEXP.LT.0) GO TO 1500 + +* Positive exponent: scale up + 1400 CONTINUE + IF (NEXP.LT.10) GO TO 1410 + DMANT=DMANT*1D10 + NEXP=NEXP-10 + GO TO 1400 + 1410 CONTINUE + IF (NEXP.LT.1) GO TO 1600 + DMANT=DMANT*1D1 + NEXP=NEXP-1 + GO TO 1410 + +* Negative exponent: scale down + 1500 CONTINUE + IF (NEXP.GT.-10) GO TO 1510 + DMANT=DMANT/1D10 + NEXP=NEXP+10 + GO TO 1500 + 1510 CONTINUE + IF (NEXP.GT.-1) GO TO 1600 + DMANT=DMANT/1D1 + NEXP=NEXP+1 + GO TO 1510 + +* Get result & status + 1600 CONTINUE + J=0 + IF (MSIGN.EQ.1) GO TO 1610 + J=-1 + DMANT=-DMANT + 1610 CONTINUE + DRESLT=DMANT + +* Skip to end of field + 1620 CONTINUE + CALL sla__IDCHF(STRING,NPTR,NVEC,NDIGIT,DIGIT) + GO TO (1720, 1620, 1720, 1720, 1720, 1720, 9900, 1720, 9900),NVEC +* 0-9 SP D/E . + - , ELSE END + + 1720 CONTINUE + NPTR=NPTR-1 + GO TO 9900 + + +* Exits + +* Null field + 9100 CONTINUE + NPTR=NPTR-1 + 9110 CONTINUE + J=1 + GO TO 9900 + +* Errors + 9200 CONTINUE + NPTR=NPTR-1 + 9210 CONTINUE + J=2 + +* Return + 9900 CONTINUE + NSTRT=NPTR + JFLAG=J + + END diff --git a/src/slalib/dh2e.f b/src/slalib/dh2e.f new file mode 100644 index 0000000..688a087 --- /dev/null +++ b/src/slalib/dh2e.f @@ -0,0 +1,83 @@ + SUBROUTINE sla_DH2E (AZ, EL, PHI, HA, DEC) +*+ +* - - - - - +* D E 2 H +* - - - - - +* +* Horizon to equatorial coordinates: Az,El to HA,Dec +* +* (double precision) +* +* Given: +* AZ d azimuth +* EL d elevation +* PHI d observatory latitude +* +* Returned: +* HA d hour angle +* DEC d declination +* +* Notes: +* +* 1) All the arguments are angles in radians. +* +* 2) The sign convention for azimuth is north zero, east +pi/2. +* +* 3) HA is returned in the range +/-pi. Declination is returned +* in the range +/-pi/2. +* +* 4) The latitude is (in principle) geodetic. In critical +* applications, corrections for polar motion should be applied. +* +* 5) In some applications it will be important to specify the +* correct type of elevation in order to produce the required +* type of HA,Dec. In particular, it may be important to +* distinguish between the elevation as affected by refraction, +* which will yield the "observed" HA,Dec, and the elevation +* in vacuo, which will yield the "topocentric" HA,Dec. If the +* effects of diurnal aberration can be neglected, the +* topocentric HA,Dec may be used as an approximation to the +* "apparent" HA,Dec. +* +* 6) No range checking of arguments is done. +* +* 7) In applications which involve many such calculations, rather +* than calling the present routine it will be more efficient to +* use inline code, having previously computed fixed terms such +* as sine and cosine of latitude. +* +* P.T.Wallace Starlink 21 February 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION AZ,EL,PHI,HA,DEC + + DOUBLE PRECISION SA,CA,SE,CE,SP,CP,X,Y,Z,R + + +* Useful trig functions + SA=SIN(AZ) + CA=COS(AZ) + SE=SIN(EL) + CE=COS(EL) + SP=SIN(PHI) + CP=COS(PHI) + +* HA,Dec as x,y,z + X=-CA*CE*SP+SE*CP + Y=-SA*CE + Z=CA*CE*CP+SE*SP + +* To HA,Dec + R=SQRT(X*X+Y*Y) + IF (R.EQ.0D0) THEN + HA=0D0 + ELSE + HA=ATAN2(Y,X) + END IF + DEC=ATAN2(Z,R) + + END diff --git a/src/slalib/dimxv.f b/src/slalib/dimxv.f new file mode 100644 index 0000000..3da8fad --- /dev/null +++ b/src/slalib/dimxv.f @@ -0,0 +1,51 @@ + SUBROUTINE sla_DIMXV (DM, VA, VB) +*+ +* - - - - - - +* D I M X V +* - - - - - - +* +* Performs the 3-D backward unitary transformation: +* +* vector VB = (inverse of matrix DM) * vector VA +* +* (double precision) +* +* (n.b. the matrix must be unitary, as this routine assumes that +* the inverse and transpose are identical) +* +* Given: +* DM dp(3,3) matrix +* VA dp(3) vector +* +* Returned: +* VB dp(3) result vector +* +* P.T.Wallace Starlink March 1986 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DM(3,3),VA(3),VB(3) + + INTEGER I,J + DOUBLE PRECISION W,VW(3) + + + +* Inverse of matrix DM * vector VA -> vector VW + DO J=1,3 + W=0D0 + DO I=1,3 + W=W+DM(I,J)*VA(I) + END DO + VW(J)=W + END DO + +* Vector VW -> vector VB + DO J=1,3 + VB(J)=VW(J) + END DO + + END diff --git a/src/slalib/djcal.f b/src/slalib/djcal.f new file mode 100644 index 0000000..7da1a07 --- /dev/null +++ b/src/slalib/djcal.f @@ -0,0 +1,77 @@ + SUBROUTINE sla_DJCAL (NDP, DJM, IYMDF, J) +*+ +* - - - - - - +* D J C A L +* - - - - - - +* +* Modified Julian Date to Gregorian Calendar, expressed +* in a form convenient for formatting messages (namely +* rounded to a specified precision, and with the fields +* stored in a single array) +* +* Given: +* NDP i number of decimal places of days in fraction +* DJM d modified Julian Date (JD-2400000.5) +* +* Returned: +* IYMDF i(4) year, month, day, fraction in Gregorian +* calendar +* J i status: nonzero = out of range +* +* Any date after 4701BC March 1 is accepted. +* +* NDP should be 4 or less if internal overflows are to be avoided +* on machines which use 32-bit integers. +* +* The algorithm is derived from that of Hatcher 1984 +* (QJRAS 25, 53-55). +* +* P.T.Wallace Starlink 27 April 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER NDP + DOUBLE PRECISION DJM + INTEGER IYMDF(4),J + + INTEGER NFD + DOUBLE PRECISION FD,DF,F,D + INTEGER JD,N4,ND10 + + + +* Validate + IF (DJM.LE.-2395520D0.OR.DJM.GE.1D9) THEN + J=-1 + ELSE + J=0 + +* Denominator of fraction + NFD=10**MAX(NDP,0) + FD=DBLE(NFD) + +* Round date and express in units of fraction + DF=ANINT(DJM*FD) + +* Separate day and fraction + F=MOD(DF,FD) + IF (F.LT.0D0) F=F+FD + D=(DF-F)/FD + +* Express day in Gregorian calendar + JD=NINT(D)+2400001 + + N4=4*(JD+((2*((4*JD-17918)/146097)*3)/4+1)/2-37) + ND10=10*(MOD(N4-237,1461)/4)+5 + + IYMDF(1)=N4/1461-4712 + IYMDF(2)=MOD(ND10/306+2,12)+1 + IYMDF(3)=MOD(ND10,306)/10+1 + IYMDF(4)=NINT(F) + + END IF + + END diff --git a/src/slalib/djcl.f b/src/slalib/djcl.f new file mode 100644 index 0000000..add7a48 --- /dev/null +++ b/src/slalib/djcl.f @@ -0,0 +1,68 @@ + SUBROUTINE sla_DJCL (DJM, IY, IM, ID, FD, J) +*+ +* - - - - - +* D J C L +* - - - - - +* +* Modified Julian Date to Gregorian year, month, day, +* and fraction of a day. +* +* Given: +* DJM dp modified Julian Date (JD-2400000.5) +* +* Returned: +* IY int year +* IM int month +* ID int day +* FD dp fraction of day +* J int status: +* 0 = OK +* -1 = unacceptable date (before 4701BC March 1) +* +* The algorithm is derived from that of Hatcher 1984 +* (QJRAS 25, 53-55). +* +* P.T.Wallace Starlink 27 April 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DJM + INTEGER IY,IM,ID + DOUBLE PRECISION FD + INTEGER J + + DOUBLE PRECISION F,D + INTEGER JD,N4,ND10 + + + +* Check if date is acceptable + IF (DJM.LE.-2395520D0.OR.DJM.GE.1D9) THEN + J=-1 + ELSE + J=0 + +* Separate day and fraction + F=MOD(DJM,1D0) + IF (F.LT.0D0) F=F+1D0 + D=ANINT(DJM-F) + +* Express day in Gregorian calendar + JD=NINT(D)+2400001 + + N4=4*(JD+((6*((4*JD-17918)/146097))/4+1)/2-37) + ND10=10*(MOD(N4-237,1461)/4)+5 + + IY=N4/1461-4712 + IM=MOD(ND10/306+2,12)+1 + ID=MOD(ND10,306)/10+1 + FD=F + + J=0 + + END IF + + END diff --git a/src/slalib/dm2av.f b/src/slalib/dm2av.f new file mode 100644 index 0000000..3f684fb --- /dev/null +++ b/src/slalib/dm2av.f @@ -0,0 +1,59 @@ + SUBROUTINE sla_DM2AV (RMAT, AXVEC) +*+ +* - - - - - - +* D M 2 A V +* - - - - - - +* +* From a rotation matrix, determine the corresponding axial vector. +* (double precision) +* +* A rotation matrix describes a rotation about some arbitrary axis. +* The axis is called the Euler axis, and the angle through which the +* reference frame rotates is called the Euler angle. The axial +* vector returned by this routine has the same direction as the +* Euler axis, and its magnitude is the Euler angle in radians. (The +* magnitude and direction can be separated by means of the routine +* sla_DVN.) +* +* Given: +* RMAT d(3,3) rotation matrix +* +* Returned: +* AXVEC d(3) axial vector (radians) +* +* The reference frame rotates clockwise as seen looking along +* the axial vector from the origin. +* +* If RMAT is null, so is the result. +* +* P.T.Wallace Starlink 24 December 1992 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RMAT(3,3),AXVEC(3) + + DOUBLE PRECISION X,Y,Z,S2,C2,PHI,F + + + + X = RMAT(2,3)-RMAT(3,2) + Y = RMAT(3,1)-RMAT(1,3) + Z = RMAT(1,2)-RMAT(2,1) + S2 = SQRT(X*X+Y*Y+Z*Z) + IF (S2.NE.0D0) THEN + C2 = (RMAT(1,1)+RMAT(2,2)+RMAT(3,3)-1D0) + PHI = ATAN2(S2/2D0,C2/2D0) + F = PHI/S2 + AXVEC(1) = X*F + AXVEC(2) = Y*F + AXVEC(3) = Z*F + ELSE + AXVEC(1) = 0D0 + AXVEC(2) = 0D0 + AXVEC(3) = 0D0 + END IF + + END diff --git a/src/slalib/dmat.f b/src/slalib/dmat.f new file mode 100644 index 0000000..2480b82 --- /dev/null +++ b/src/slalib/dmat.f @@ -0,0 +1,140 @@ + SUBROUTINE sla_DMAT (N, A, Y, D, JF, IW) +*+ +* - - - - - +* D M A T +* - - - - - +* +* Matrix inversion & solution of simultaneous equations +* (double precision) +* +* For the set of n simultaneous equations in n unknowns: +* A.Y = X +* +* where: +* A is a non-singular N x N matrix +* Y is the vector of N unknowns +* X is the known vector +* +* DMATRX computes: +* the inverse of matrix A +* the determinant of matrix A +* the vector of N unknowns +* +* Arguments: +* +* symbol type dimension before after +* +* N i no. of unknowns unchanged +* A d (N,N) matrix inverse +* Y d (N) vector solution +* D d - determinant +* * JF i - singularity flag +* IW i (N) - workspace +* +* * JF is the singularity flag. If the matrix is non-singular, +* JF=0 is returned. If the matrix is singular, JF=-1 & D=0D0 are +* returned. In the latter case, the contents of array A on return +* are undefined. +* +* Algorithm: +* Gaussian elimination with partial pivoting. +* +* Speed: +* Very fast. +* +* Accuracy: +* Fairly accurate - errors 1 to 4 times those of routines optimized +* for accuracy. +* +* P.T.Wallace Starlink 7 February 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER N + DOUBLE PRECISION A(N,N),Y(N),D + INTEGER JF + INTEGER IW(N) + + DOUBLE PRECISION SFA + PARAMETER (SFA=1D-20) + + INTEGER K,IMX,I,J,NP1MK,KI + DOUBLE PRECISION AMX,T,AKK,YK,AIK + + + JF=0 + D=1D0 + DO K=1,N + AMX=DABS(A(K,K)) + IMX=K + IF (K.NE.N) THEN + DO I=K+1,N + T=DABS(A(I,K)) + IF (T.GT.AMX) THEN + AMX=T + IMX=I + END IF + END DO + END IF + IF (AMX.LT.SFA) THEN + JF=-1 + ELSE + IF (IMX.NE.K) THEN + DO J=1,N + T=A(K,J) + A(K,J)=A(IMX,J) + A(IMX,J)=T + END DO + T=Y(K) + Y(K)=Y(IMX) + Y(IMX)=T + D=-D + END IF + IW(K)=IMX + AKK=A(K,K) + D=D*AKK + IF (DABS(D).LT.SFA) THEN + JF=-1 + ELSE + AKK=1D0/AKK + A(K,K)=AKK + DO J=1,N + IF (J.NE.K) A(K,J)=A(K,J)*AKK + END DO + YK=Y(K)*AKK + Y(K)=YK + DO I=1,N + AIK=A(I,K) + IF (I.NE.K) THEN + DO J=1,N + IF (J.NE.K) A(I,J)=A(I,J)-AIK*A(K,J) + END DO + Y(I)=Y(I)-AIK*YK + END IF + END DO + DO I=1,N + IF (I.NE.K) A(I,K)=-A(I,K)*AKK + END DO + END IF + END IF + END DO + IF (JF.NE.0) THEN + D=0D0 + ELSE + DO K=1,N + NP1MK=N+1-K + KI=IW(NP1MK) + IF (NP1MK.NE.KI) THEN + DO I=1,N + T=A(I,NP1MK) + A(I,NP1MK)=A(I,KI) + A(I,KI)=T + END DO + END IF + END DO + END IF + + END diff --git a/src/slalib/dmoon.f b/src/slalib/dmoon.f new file mode 100644 index 0000000..7794255 --- /dev/null +++ b/src/slalib/dmoon.f @@ -0,0 +1,641 @@ + SUBROUTINE sla_DMOON (DATE, PV) +*+ +* - - - - - - +* D M O O N +* - - - - - - +* +* Approximate geocentric position and velocity of the Moon +* (double precision) +* +* Given: +* DATE D TDB (loosely ET) as a Modified Julian Date +* (JD-2400000.5) +* +* Returned: +* PV D(6) Moon x,y,z,xdot,ydot,zdot, mean equator and +* equinox of date (AU, AU/s) +* +* Notes: +* +* 1 This routine is a full implementation of the algorithm +* published by Meeus (see reference). +* +* 2 Meeus quotes accuracies of 10 arcsec in longitude, 3 arcsec in +* latitude and 0.2 arcsec in HP (equivalent to about 20 km in +* distance). Comparison with JPL DE200 over the interval +* 1960-2025 gives RMS errors of 3.7 arcsec and 83 mas/hour in +* longitude, 2.3 arcsec and 48 mas/hour in latitude, 11 km +* and 81 mm/s in distance. The maximum errors over the same +* interval are 18 arcsec and 0.50 arcsec/hour in longitude, +* 11 arcsec and 0.24 arcsec/hour in latitude, 40 km and 0.29 m/s +* in distance. +* +* 3 The original algorithm is expressed in terms of the obsolete +* timescale Ephemeris Time. Either TDB or TT can be used, but +* not UT without incurring significant errors (30 arcsec at +* the present time) due to the Moon's 0.5 arcsec/sec movement. +* +* 4 The algorithm is based on pre IAU 1976 standards. However, +* the result has been moved onto the new (FK5) equinox, an +* adjustment which is in any case much smaller than the +* intrinsic accuracy of the procedure. +* +* 5 Velocity is obtained by a complete analytical differentiation +* of the Meeus model. +* +* Reference: +* Meeus, l'Astronomie, June 1984, p348. +* +* P.T.Wallace Starlink 22 January 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,PV(6) + +* Degrees, arcseconds and seconds of time to radians + DOUBLE PRECISION D2R,DAS2R,DS2R + PARAMETER (D2R=0.0174532925199432957692369D0, + : DAS2R=4.848136811095359935899141D-6, + : DS2R=7.272205216643039903848712D-5) + +* Seconds per Julian century (86400*36525) + DOUBLE PRECISION CJ + PARAMETER (CJ=3155760000D0) + +* Julian epoch of B1950 + DOUBLE PRECISION B1950 + PARAMETER (B1950=1949.9997904423D0) + +* Earth equatorial radius in AU ( = 6378.137 / 149597870 ) + DOUBLE PRECISION ERADAU + PARAMETER (ERADAU=4.2635212653763D-5) + + DOUBLE PRECISION T,THETA,SINOM,COSOM,DOMCOM,WA,DWA,WB,DWB,WOM, + : DWOM,SINWOM,COSWOM,V,DV,COEFF,EMN,EMPN,DN,FN,EN, + : DEN,DTHETA,FTHETA,EL,DEL,B,DB,BF,DBF,P,DP,SP,R, + : DR,X,Y,Z,XD,YD,ZD,SEL,CEL,SB,CB,RCB,RBD,W,EPJ, + : EQCOR,EPS,SINEPS,COSEPS,ES,EC + INTEGER N,I + +* +* Coefficients for fundamental arguments +* +* at J1900: T**0, T**1, T**2, T**3 +* at epoch: T**0, T**1 +* +* Units are degrees for position and Julian centuries for time +* + +* Moon's mean longitude + DOUBLE PRECISION ELP0,ELP1,ELP2,ELP3,ELP,DELP + PARAMETER (ELP0=270.434164D0, + : ELP1=481267.8831D0, + : ELP2=-0.001133D0, + : ELP3=0.0000019D0) + +* Sun's mean anomaly + DOUBLE PRECISION EM0,EM1,EM2,EM3,EM,DEM + PARAMETER (EM0=358.475833D0, + : EM1=35999.0498D0, + : EM2=-0.000150D0, + : EM3=-0.0000033D0) + +* Moon's mean anomaly + DOUBLE PRECISION EMP0,EMP1,EMP2,EMP3,EMP,DEMP + PARAMETER (EMP0=296.104608D0, + : EMP1=477198.8491D0, + : EMP2=0.009192D0, + : EMP3=0.0000144D0) + +* Moon's mean elongation + DOUBLE PRECISION D0,D1,D2,D3,D,DD + PARAMETER (D0=350.737486D0, + : D1=445267.1142D0, + : D2=-0.001436D0, + : D3=0.0000019D0) + +* Mean distance of the Moon from its ascending node + DOUBLE PRECISION F0,F1,F2,F3,F,DF + PARAMETER (F0=11.250889D0, + : F1=483202.0251D0, + : F2=-0.003211D0, + : F3=-0.0000003D0) + +* Longitude of the Moon's ascending node + DOUBLE PRECISION OM0,OM1,OM2,OM3,OM,DOM + PARAMETER (OM0=259.183275D0, + : OM1=-1934.1420D0, + : OM2=0.002078D0, + : OM3=0.0000022D0) + +* Coefficients for (dimensionless) E factor + DOUBLE PRECISION E1,E2,E,DE,ESQ,DESQ + PARAMETER (E1=-0.002495D0,E2=-0.00000752D0) + +* Coefficients for periodic variations etc + DOUBLE PRECISION PAC,PA0,PA1 + PARAMETER (PAC=0.000233D0,PA0=51.2D0,PA1=20.2D0) + DOUBLE PRECISION PBC + PARAMETER (PBC=-0.001778D0) + DOUBLE PRECISION PCC + PARAMETER (PCC=0.000817D0) + DOUBLE PRECISION PDC + PARAMETER (PDC=0.002011D0) + DOUBLE PRECISION PEC,PE0,PE1,PE2 + PARAMETER (PEC=0.003964D0, + : PE0=346.560D0,PE1=132.870D0,PE2=-0.0091731D0) + DOUBLE PRECISION PFC + PARAMETER (PFC=0.001964D0) + DOUBLE PRECISION PGC + PARAMETER (PGC=0.002541D0) + DOUBLE PRECISION PHC + PARAMETER (PHC=0.001964D0) + DOUBLE PRECISION PIC + PARAMETER (PIC=-0.024691D0) + DOUBLE PRECISION PJC,PJ0,PJ1 + PARAMETER (PJC=-0.004328D0,PJ0=275.05D0,PJ1=-2.30D0) + DOUBLE PRECISION CW1 + PARAMETER (CW1=0.0004664D0) + DOUBLE PRECISION CW2 + PARAMETER (CW2=0.0000754D0) + +* +* Coefficients for Moon position +* +* Tx(N) = coefficient of L, B or P term (deg) +* ITx(N,1-5) = coefficients of M, M', D, F, E**n in argument +* + INTEGER NL,NB,NP + PARAMETER (NL=50,NB=45,NP=31) + DOUBLE PRECISION TL(NL),TB(NB),TP(NP) + INTEGER ITL(5,NL),ITB(5,NB),ITP(5,NP) +* +* Longitude +* M M' D F n + DATA TL( 1)/ +6.288750D0 /, + : (ITL(I, 1),I=1,5)/ +0, +1, +0, +0, 0 / + DATA TL( 2)/ +1.274018D0 /, + : (ITL(I, 2),I=1,5)/ +0, -1, +2, +0, 0 / + DATA TL( 3)/ +0.658309D0 /, + : (ITL(I, 3),I=1,5)/ +0, +0, +2, +0, 0 / + DATA TL( 4)/ +0.213616D0 /, + : (ITL(I, 4),I=1,5)/ +0, +2, +0, +0, 0 / + DATA TL( 5)/ -0.185596D0 /, + : (ITL(I, 5),I=1,5)/ +1, +0, +0, +0, 1 / + DATA TL( 6)/ -0.114336D0 /, + : (ITL(I, 6),I=1,5)/ +0, +0, +0, +2, 0 / + DATA TL( 7)/ +0.058793D0 /, + : (ITL(I, 7),I=1,5)/ +0, -2, +2, +0, 0 / + DATA TL( 8)/ +0.057212D0 /, + : (ITL(I, 8),I=1,5)/ -1, -1, +2, +0, 1 / + DATA TL( 9)/ +0.053320D0 /, + : (ITL(I, 9),I=1,5)/ +0, +1, +2, +0, 0 / + DATA TL(10)/ +0.045874D0 /, + : (ITL(I,10),I=1,5)/ -1, +0, +2, +0, 1 / + DATA TL(11)/ +0.041024D0 /, + : (ITL(I,11),I=1,5)/ -1, +1, +0, +0, 1 / + DATA TL(12)/ -0.034718D0 /, + : (ITL(I,12),I=1,5)/ +0, +0, +1, +0, 0 / + DATA TL(13)/ -0.030465D0 /, + : (ITL(I,13),I=1,5)/ +1, +1, +0, +0, 1 / + DATA TL(14)/ +0.015326D0 /, + : (ITL(I,14),I=1,5)/ +0, +0, +2, -2, 0 / + DATA TL(15)/ -0.012528D0 /, + : (ITL(I,15),I=1,5)/ +0, +1, +0, +2, 0 / + DATA TL(16)/ -0.010980D0 /, + : (ITL(I,16),I=1,5)/ +0, -1, +0, +2, 0 / + DATA TL(17)/ +0.010674D0 /, + : (ITL(I,17),I=1,5)/ +0, -1, +4, +0, 0 / + DATA TL(18)/ +0.010034D0 /, + : (ITL(I,18),I=1,5)/ +0, +3, +0, +0, 0 / + DATA TL(19)/ +0.008548D0 /, + : (ITL(I,19),I=1,5)/ +0, -2, +4, +0, 0 / + DATA TL(20)/ -0.007910D0 /, + : (ITL(I,20),I=1,5)/ +1, -1, +2, +0, 1 / + DATA TL(21)/ -0.006783D0 /, + : (ITL(I,21),I=1,5)/ +1, +0, +2, +0, 1 / + DATA TL(22)/ +0.005162D0 /, + : (ITL(I,22),I=1,5)/ +0, +1, -1, +0, 0 / + DATA TL(23)/ +0.005000D0 /, + : (ITL(I,23),I=1,5)/ +1, +0, +1, +0, 1 / + DATA TL(24)/ +0.004049D0 /, + : (ITL(I,24),I=1,5)/ -1, +1, +2, +0, 1 / + DATA TL(25)/ +0.003996D0 /, + : (ITL(I,25),I=1,5)/ +0, +2, +2, +0, 0 / + DATA TL(26)/ +0.003862D0 /, + : (ITL(I,26),I=1,5)/ +0, +0, +4, +0, 0 / + DATA TL(27)/ +0.003665D0 /, + : (ITL(I,27),I=1,5)/ +0, -3, +2, +0, 0 / + DATA TL(28)/ +0.002695D0 /, + : (ITL(I,28),I=1,5)/ -1, +2, +0, +0, 1 / + DATA TL(29)/ +0.002602D0 /, + : (ITL(I,29),I=1,5)/ +0, +1, -2, -2, 0 / + DATA TL(30)/ +0.002396D0 /, + : (ITL(I,30),I=1,5)/ -1, -2, +2, +0, 1 / + DATA TL(31)/ -0.002349D0 /, + : (ITL(I,31),I=1,5)/ +0, +1, +1, +0, 0 / + DATA TL(32)/ +0.002249D0 /, + : (ITL(I,32),I=1,5)/ -2, +0, +2, +0, 2 / + DATA TL(33)/ -0.002125D0 /, + : (ITL(I,33),I=1,5)/ +1, +2, +0, +0, 1 / + DATA TL(34)/ -0.002079D0 /, + : (ITL(I,34),I=1,5)/ +2, +0, +0, +0, 2 / + DATA TL(35)/ +0.002059D0 /, + : (ITL(I,35),I=1,5)/ -2, -1, +2, +0, 2 / + DATA TL(36)/ -0.001773D0 /, + : (ITL(I,36),I=1,5)/ +0, +1, +2, -2, 0 / + DATA TL(37)/ -0.001595D0 /, + : (ITL(I,37),I=1,5)/ +0, +0, +2, +2, 0 / + DATA TL(38)/ +0.001220D0 /, + : (ITL(I,38),I=1,5)/ -1, -1, +4, +0, 1 / + DATA TL(39)/ -0.001110D0 /, + : (ITL(I,39),I=1,5)/ +0, +2, +0, +2, 0 / + DATA TL(40)/ +0.000892D0 /, + : (ITL(I,40),I=1,5)/ +0, +1, -3, +0, 0 / + DATA TL(41)/ -0.000811D0 /, + : (ITL(I,41),I=1,5)/ +1, +1, +2, +0, 1 / + DATA TL(42)/ +0.000761D0 /, + : (ITL(I,42),I=1,5)/ -1, -2, +4, +0, 1 / + DATA TL(43)/ +0.000717D0 /, + : (ITL(I,43),I=1,5)/ -2, +1, +0, +0, 2 / + DATA TL(44)/ +0.000704D0 /, + : (ITL(I,44),I=1,5)/ -2, +1, -2, +0, 2 / + DATA TL(45)/ +0.000693D0 /, + : (ITL(I,45),I=1,5)/ +1, -2, +2, +0, 1 / + DATA TL(46)/ +0.000598D0 /, + : (ITL(I,46),I=1,5)/ -1, +0, +2, -2, 1 / + DATA TL(47)/ +0.000550D0 /, + : (ITL(I,47),I=1,5)/ +0, +1, +4, +0, 0 / + DATA TL(48)/ +0.000538D0 /, + : (ITL(I,48),I=1,5)/ +0, +4, +0, +0, 0 / + DATA TL(49)/ +0.000521D0 /, + : (ITL(I,49),I=1,5)/ -1, +0, +4, +0, 1 / + DATA TL(50)/ +0.000486D0 /, + : (ITL(I,50),I=1,5)/ +0, +2, -1, +0, 0 / +* +* Latitude +* M M' D F n + DATA TB( 1)/ +5.128189D0 /, + : (ITB(I, 1),I=1,5)/ +0, +0, +0, +1, 0 / + DATA TB( 2)/ +0.280606D0 /, + : (ITB(I, 2),I=1,5)/ +0, +1, +0, +1, 0 / + DATA TB( 3)/ +0.277693D0 /, + : (ITB(I, 3),I=1,5)/ +0, +1, +0, -1, 0 / + DATA TB( 4)/ +0.173238D0 /, + : (ITB(I, 4),I=1,5)/ +0, +0, +2, -1, 0 / + DATA TB( 5)/ +0.055413D0 /, + : (ITB(I, 5),I=1,5)/ +0, -1, +2, +1, 0 / + DATA TB( 6)/ +0.046272D0 /, + : (ITB(I, 6),I=1,5)/ +0, -1, +2, -1, 0 / + DATA TB( 7)/ +0.032573D0 /, + : (ITB(I, 7),I=1,5)/ +0, +0, +2, +1, 0 / + DATA TB( 8)/ +0.017198D0 /, + : (ITB(I, 8),I=1,5)/ +0, +2, +0, +1, 0 / + DATA TB( 9)/ +0.009267D0 /, + : (ITB(I, 9),I=1,5)/ +0, +1, +2, -1, 0 / + DATA TB(10)/ +0.008823D0 /, + : (ITB(I,10),I=1,5)/ +0, +2, +0, -1, 0 / + DATA TB(11)/ +0.008247D0 /, + : (ITB(I,11),I=1,5)/ -1, +0, +2, -1, 1 / + DATA TB(12)/ +0.004323D0 /, + : (ITB(I,12),I=1,5)/ +0, -2, +2, -1, 0 / + DATA TB(13)/ +0.004200D0 /, + : (ITB(I,13),I=1,5)/ +0, +1, +2, +1, 0 / + DATA TB(14)/ +0.003372D0 /, + : (ITB(I,14),I=1,5)/ -1, +0, -2, +1, 1 / + DATA TB(15)/ +0.002472D0 /, + : (ITB(I,15),I=1,5)/ -1, -1, +2, +1, 1 / + DATA TB(16)/ +0.002222D0 /, + : (ITB(I,16),I=1,5)/ -1, +0, +2, +1, 1 / + DATA TB(17)/ +0.002072D0 /, + : (ITB(I,17),I=1,5)/ -1, -1, +2, -1, 1 / + DATA TB(18)/ +0.001877D0 /, + : (ITB(I,18),I=1,5)/ -1, +1, +0, +1, 1 / + DATA TB(19)/ +0.001828D0 /, + : (ITB(I,19),I=1,5)/ +0, -1, +4, -1, 0 / + DATA TB(20)/ -0.001803D0 /, + : (ITB(I,20),I=1,5)/ +1, +0, +0, +1, 1 / + DATA TB(21)/ -0.001750D0 /, + : (ITB(I,21),I=1,5)/ +0, +0, +0, +3, 0 / + DATA TB(22)/ +0.001570D0 /, + : (ITB(I,22),I=1,5)/ -1, +1, +0, -1, 1 / + DATA TB(23)/ -0.001487D0 /, + : (ITB(I,23),I=1,5)/ +0, +0, +1, +1, 0 / + DATA TB(24)/ -0.001481D0 /, + : (ITB(I,24),I=1,5)/ +1, +1, +0, +1, 1 / + DATA TB(25)/ +0.001417D0 /, + : (ITB(I,25),I=1,5)/ -1, -1, +0, +1, 1 / + DATA TB(26)/ +0.001350D0 /, + : (ITB(I,26),I=1,5)/ -1, +0, +0, +1, 1 / + DATA TB(27)/ +0.001330D0 /, + : (ITB(I,27),I=1,5)/ +0, +0, -1, +1, 0 / + DATA TB(28)/ +0.001106D0 /, + : (ITB(I,28),I=1,5)/ +0, +3, +0, +1, 0 / + DATA TB(29)/ +0.001020D0 /, + : (ITB(I,29),I=1,5)/ +0, +0, +4, -1, 0 / + DATA TB(30)/ +0.000833D0 /, + : (ITB(I,30),I=1,5)/ +0, -1, +4, +1, 0 / + DATA TB(31)/ +0.000781D0 /, + : (ITB(I,31),I=1,5)/ +0, +1, +0, -3, 0 / + DATA TB(32)/ +0.000670D0 /, + : (ITB(I,32),I=1,5)/ +0, -2, +4, +1, 0 / + DATA TB(33)/ +0.000606D0 /, + : (ITB(I,33),I=1,5)/ +0, +0, +2, -3, 0 / + DATA TB(34)/ +0.000597D0 /, + : (ITB(I,34),I=1,5)/ +0, +2, +2, -1, 0 / + DATA TB(35)/ +0.000492D0 /, + : (ITB(I,35),I=1,5)/ -1, +1, +2, -1, 1 / + DATA TB(36)/ +0.000450D0 /, + : (ITB(I,36),I=1,5)/ +0, +2, -2, -1, 0 / + DATA TB(37)/ +0.000439D0 /, + : (ITB(I,37),I=1,5)/ +0, +3, +0, -1, 0 / + DATA TB(38)/ +0.000423D0 /, + : (ITB(I,38),I=1,5)/ +0, +2, +2, +1, 0 / + DATA TB(39)/ +0.000422D0 /, + : (ITB(I,39),I=1,5)/ +0, -3, +2, -1, 0 / + DATA TB(40)/ -0.000367D0 /, + : (ITB(I,40),I=1,5)/ +1, -1, +2, +1, 1 / + DATA TB(41)/ -0.000353D0 /, + : (ITB(I,41),I=1,5)/ +1, +0, +2, +1, 1 / + DATA TB(42)/ +0.000331D0 /, + : (ITB(I,42),I=1,5)/ +0, +0, +4, +1, 0 / + DATA TB(43)/ +0.000317D0 /, + : (ITB(I,43),I=1,5)/ -1, +1, +2, +1, 1 / + DATA TB(44)/ +0.000306D0 /, + : (ITB(I,44),I=1,5)/ -2, +0, +2, -1, 2 / + DATA TB(45)/ -0.000283D0 /, + : (ITB(I,45),I=1,5)/ +0, +1, +0, +3, 0 / +* +* Parallax +* M M' D F n + DATA TP( 1)/ +0.950724D0 /, + : (ITP(I, 1),I=1,5)/ +0, +0, +0, +0, 0 / + DATA TP( 2)/ +0.051818D0 /, + : (ITP(I, 2),I=1,5)/ +0, +1, +0, +0, 0 / + DATA TP( 3)/ +0.009531D0 /, + : (ITP(I, 3),I=1,5)/ +0, -1, +2, +0, 0 / + DATA TP( 4)/ +0.007843D0 /, + : (ITP(I, 4),I=1,5)/ +0, +0, +2, +0, 0 / + DATA TP( 5)/ +0.002824D0 /, + : (ITP(I, 5),I=1,5)/ +0, +2, +0, +0, 0 / + DATA TP( 6)/ +0.000857D0 /, + : (ITP(I, 6),I=1,5)/ +0, +1, +2, +0, 0 / + DATA TP( 7)/ +0.000533D0 /, + : (ITP(I, 7),I=1,5)/ -1, +0, +2, +0, 1 / + DATA TP( 8)/ +0.000401D0 /, + : (ITP(I, 8),I=1,5)/ -1, -1, +2, +0, 1 / + DATA TP( 9)/ +0.000320D0 /, + : (ITP(I, 9),I=1,5)/ -1, +1, +0, +0, 1 / + DATA TP(10)/ -0.000271D0 /, + : (ITP(I,10),I=1,5)/ +0, +0, +1, +0, 0 / + DATA TP(11)/ -0.000264D0 /, + : (ITP(I,11),I=1,5)/ +1, +1, +0, +0, 1 / + DATA TP(12)/ -0.000198D0 /, + : (ITP(I,12),I=1,5)/ +0, -1, +0, +2, 0 / + DATA TP(13)/ +0.000173D0 /, + : (ITP(I,13),I=1,5)/ +0, +3, +0, +0, 0 / + DATA TP(14)/ +0.000167D0 /, + : (ITP(I,14),I=1,5)/ +0, -1, +4, +0, 0 / + DATA TP(15)/ -0.000111D0 /, + : (ITP(I,15),I=1,5)/ +1, +0, +0, +0, 1 / + DATA TP(16)/ +0.000103D0 /, + : (ITP(I,16),I=1,5)/ +0, -2, +4, +0, 0 / + DATA TP(17)/ -0.000084D0 /, + : (ITP(I,17),I=1,5)/ +0, +2, -2, +0, 0 / + DATA TP(18)/ -0.000083D0 /, + : (ITP(I,18),I=1,5)/ +1, +0, +2, +0, 1 / + DATA TP(19)/ +0.000079D0 /, + : (ITP(I,19),I=1,5)/ +0, +2, +2, +0, 0 / + DATA TP(20)/ +0.000072D0 /, + : (ITP(I,20),I=1,5)/ +0, +0, +4, +0, 0 / + DATA TP(21)/ +0.000064D0 /, + : (ITP(I,21),I=1,5)/ -1, +1, +2, +0, 1 / + DATA TP(22)/ -0.000063D0 /, + : (ITP(I,22),I=1,5)/ +1, -1, +2, +0, 1 / + DATA TP(23)/ +0.000041D0 /, + : (ITP(I,23),I=1,5)/ +1, +0, +1, +0, 1 / + DATA TP(24)/ +0.000035D0 /, + : (ITP(I,24),I=1,5)/ -1, +2, +0, +0, 1 / + DATA TP(25)/ -0.000033D0 /, + : (ITP(I,25),I=1,5)/ +0, +3, -2, +0, 0 / + DATA TP(26)/ -0.000030D0 /, + : (ITP(I,26),I=1,5)/ +0, +1, +1, +0, 0 / + DATA TP(27)/ -0.000029D0 /, + : (ITP(I,27),I=1,5)/ +0, +0, -2, +2, 0 / + DATA TP(28)/ -0.000029D0 /, + : (ITP(I,28),I=1,5)/ +1, +2, +0, +0, 1 / + DATA TP(29)/ +0.000026D0 /, + : (ITP(I,29),I=1,5)/ -2, +0, +2, +0, 2 / + DATA TP(30)/ -0.000023D0 /, + : (ITP(I,30),I=1,5)/ +0, +1, -2, +2, 0 / + DATA TP(31)/ +0.000019D0 /, + : (ITP(I,31),I=1,5)/ -1, -1, +4, +0, 1 / + + + +* Centuries since J1900 + T=(DATE-15019.5D0)/36525D0 + +* +* Fundamental arguments (radians) and derivatives (radians per +* Julian century) for the current epoch +* + +* Moon's mean longitude + ELP=D2R*MOD(ELP0+(ELP1+(ELP2+ELP3*T)*T)*T,360D0) + DELP=D2R*(ELP1+(2D0*ELP2+3D0*ELP3*T)*T) + +* Sun's mean anomaly + EM=D2R*MOD(EM0+(EM1+(EM2+EM3*T)*T)*T,360D0) + DEM=D2R*(EM1+(2D0*EM2+3D0*EM3*T)*T) + +* Moon's mean anomaly + EMP=D2R*MOD(EMP0+(EMP1+(EMP2+EMP3*T)*T)*T,360D0) + DEMP=D2R*(EMP1+(2D0*EMP2+3D0*EMP3*T)*T) + +* Moon's mean elongation + D=D2R*MOD(D0+(D1+(D2+D3*T)*T)*T,360D0) + DD=D2R*(D1+(2D0*D2+3D0*D3*T)*T) + +* Mean distance of the Moon from its ascending node + F=D2R*MOD(F0+(F1+(F2+F3*T)*T)*T,360D0) + DF=D2R*(F1+(2D0*F2+3D0*F3*T)*T) + +* Longitude of the Moon's ascending node + OM=D2R*MOD(OM0+(OM1+(OM2+OM3*T)*T)*T,360D0) + DOM=D2R*(OM1+(2D0*OM2+3D0*OM3*T)*T) + SINOM=SIN(OM) + COSOM=COS(OM) + DOMCOM=DOM*COSOM + +* Add the periodic variations + THETA=D2R*(PA0+PA1*T) + WA=SIN(THETA) + DWA=D2R*PA1*COS(THETA) + THETA=D2R*(PE0+(PE1+PE2*T)*T) + WB=PEC*SIN(THETA) + DWB=D2R*PEC*(PE1+2D0*PE2*T)*COS(THETA) + ELP=ELP+D2R*(PAC*WA+WB+PFC*SINOM) + DELP=DELP+D2R*(PAC*DWA+DWB+PFC*DOMCOM) + EM=EM+D2R*PBC*WA + DEM=DEM+D2R*PBC*DWA + EMP=EMP+D2R*(PCC*WA+WB+PGC*SINOM) + DEMP=DEMP+D2R*(PCC*DWA+DWB+PGC*DOMCOM) + D=D+D2R*(PDC*WA+WB+PHC*SINOM) + DD=DD+D2R*(PDC*DWA+DWB+PHC*DOMCOM) + WOM=OM+D2R*(PJ0+PJ1*T) + DWOM=DOM+D2R*PJ1 + SINWOM=SIN(WOM) + COSWOM=COS(WOM) + F=F+D2R*(WB+PIC*SINOM+PJC*SINWOM) + DF=DF+D2R*(DWB+PIC*DOMCOM+PJC*DWOM*COSWOM) + +* E-factor, and square + E=1D0+(E1+E2*T)*T + DE=E1+2D0*E2*T + ESQ=E*E + DESQ=2D0*E*DE + +* +* Series expansions +* + +* Longitude + V=0D0 + DV=0D0 + DO N=NL,1,-1 + COEFF=TL(N) + EMN=DBLE(ITL(1,N)) + EMPN=DBLE(ITL(2,N)) + DN=DBLE(ITL(3,N)) + FN=DBLE(ITL(4,N)) + I=ITL(5,N) + IF (I.EQ.0) THEN + EN=1D0 + DEN=0D0 + ELSE IF (I.EQ.1) THEN + EN=E + DEN=DE + ELSE + EN=ESQ + DEN=DESQ + END IF + THETA=EMN*EM+EMPN*EMP+DN*D+FN*F + DTHETA=EMN*DEM+EMPN*DEMP+DN*DD+FN*DF + FTHETA=SIN(THETA) + V=V+COEFF*FTHETA*EN + DV=DV+COEFF*(COS(THETA)*DTHETA*EN+FTHETA*DEN) + END DO + EL=ELP+D2R*V + DEL=(DELP+D2R*DV)/CJ + +* Latitude + V=0D0 + DV=0D0 + DO N=NB,1,-1 + COEFF=TB(N) + EMN=DBLE(ITB(1,N)) + EMPN=DBLE(ITB(2,N)) + DN=DBLE(ITB(3,N)) + FN=DBLE(ITB(4,N)) + I=ITB(5,N) + IF (I.EQ.0) THEN + EN=1D0 + DEN=0D0 + ELSE IF (I.EQ.1) THEN + EN=E + DEN=DE + ELSE + EN=ESQ + DEN=DESQ + END IF + THETA=EMN*EM+EMPN*EMP+DN*D+FN*F + DTHETA=EMN*DEM+EMPN*DEMP+DN*DD+FN*DF + FTHETA=SIN(THETA) + V=V+COEFF*FTHETA*EN + DV=DV+COEFF*(COS(THETA)*DTHETA*EN+FTHETA*DEN) + END DO + BF=1D0-CW1*COSOM-CW2*COSWOM + DBF=CW1*DOM*SINOM+CW2*DWOM*SINWOM + B=D2R*V*BF + DB=D2R*(DV*BF+V*DBF)/CJ + +* Parallax + V=0D0 + DV=0D0 + DO N=NP,1,-1 + COEFF=TP(N) + EMN=DBLE(ITP(1,N)) + EMPN=DBLE(ITP(2,N)) + DN=DBLE(ITP(3,N)) + FN=DBLE(ITP(4,N)) + I=ITP(5,N) + IF (I.EQ.0) THEN + EN=1D0 + DEN=0D0 + ELSE IF (I.EQ.1) THEN + EN=E + DEN=DE + ELSE + EN=ESQ + DEN=DESQ + END IF + THETA=EMN*EM+EMPN*EMP+DN*D+FN*F + DTHETA=EMN*DEM+EMPN*DEMP+DN*DD+FN*DF + FTHETA=COS(THETA) + V=V+COEFF*FTHETA*EN + DV=DV+COEFF*(-SIN(THETA)*DTHETA*EN+FTHETA*DEN) + END DO + P=D2R*V + DP=D2R*DV/CJ + +* +* Transformation into final form +* + +* Parallax to distance (AU, AU/sec) + SP=SIN(P) + R=ERADAU/SP + DR=-R*DP*COS(P)/SP + +* Longitude, latitude to x,y,z (AU) + SEL=SIN(EL) + CEL=COS(EL) + SB=SIN(B) + CB=COS(B) + RCB=R*CB + RBD=R*DB + W=RBD*SB-CB*DR + X=RCB*CEL + Y=RCB*SEL + Z=R*SB + XD=-Y*DEL-W*CEL + YD=X*DEL-W*SEL + ZD=RBD*CB+SB*DR + +* Julian centuries since J2000 + T=(DATE-51544.5D0)/36525D0 + +* Fricke equinox correction + EPJ=2000D0+T*100D0 + EQCOR=DS2R*(0.035D0+0.00085D0*(EPJ-B1950)) + +* Mean obliquity (IAU 1976) + EPS=DAS2R*(84381.448D0+(-46.8150D0+(-0.00059D0+0.001813D0*T)*T)*T) + +* To the equatorial system, mean of date, FK5 system + SINEPS=SIN(EPS) + COSEPS=COS(EPS) + ES=EQCOR*SINEPS + EC=EQCOR*COSEPS + PV(1)=X-EC*Y+ES*Z + PV(2)=EQCOR*X+Y*COSEPS-Z*SINEPS + PV(3)=Y*SINEPS+Z*COSEPS + PV(4)=XD-EC*YD+ES*ZD + PV(5)=EQCOR*XD+YD*COSEPS-ZD*SINEPS + PV(6)=YD*SINEPS+ZD*COSEPS + + END diff --git a/src/slalib/dmxm.f b/src/slalib/dmxm.f new file mode 100644 index 0000000..41f3d99 --- /dev/null +++ b/src/slalib/dmxm.f @@ -0,0 +1,56 @@ + SUBROUTINE sla_DMXM (A, B, C) +*+ +* - - - - - +* D M X M +* - - - - - +* +* Product of two 3x3 matrices: +* +* matrix C = matrix A x matrix B +* +* (double precision) +* +* Given: +* A dp(3,3) matrix +* B dp(3,3) matrix +* +* Returned: +* C dp(3,3) matrix result +* +* To comply with the ANSI Fortran 77 standard, A, B and C must +* be different arrays. However, the routine is coded so as to +* work properly on the VAX and many other systems even if this +* rule is violated. +* +* P.T.Wallace Starlink 5 April 1990 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION A(3,3),B(3,3),C(3,3) + + INTEGER I,J,K + DOUBLE PRECISION W,WM(3,3) + + +* Multiply into scratch matrix + DO I=1,3 + DO J=1,3 + W=0D0 + DO K=1,3 + W=W+A(I,K)*B(K,J) + END DO + WM(I,J)=W + END DO + END DO + +* Return the result + DO J=1,3 + DO I=1,3 + C(I,J)=WM(I,J) + END DO + END DO + + END diff --git a/src/slalib/dmxv.f b/src/slalib/dmxv.f new file mode 100644 index 0000000..e70a28e --- /dev/null +++ b/src/slalib/dmxv.f @@ -0,0 +1,47 @@ + SUBROUTINE sla_DMXV (DM, VA, VB) +*+ +* - - - - - +* D M X V +* - - - - - +* +* Performs the 3-D forward unitary transformation: +* +* vector VB = matrix DM * vector VA +* +* (double precision) +* +* Given: +* DM dp(3,3) matrix +* VA dp(3) vector +* +* Returned: +* VB dp(3) result vector +* +* P.T.Wallace Starlink March 1986 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DM(3,3),VA(3),VB(3) + + INTEGER I,J + DOUBLE PRECISION W,VW(3) + + +* Matrix DM * vector VA -> vector VW + DO J=1,3 + W=0D0 + DO I=1,3 + W=W+DM(J,I)*VA(I) + END DO + VW(J)=W + END DO + +* Vector VW -> vector VB + DO J=1,3 + VB(J)=VW(J) + END DO + + END diff --git a/src/slalib/dpav.f b/src/slalib/dpav.f new file mode 100644 index 0000000..63ad759 --- /dev/null +++ b/src/slalib/dpav.f @@ -0,0 +1,72 @@ + DOUBLE PRECISION FUNCTION sla_DPAV ( V1, V2 ) +*+ +* - - - - - +* D P A V +* - - - - - +* +* Position angle of one celestial direction with respect to another. +* +* (double precision) +* +* Given: +* V1 d(3) direction cosines of one point +* V2 d(3) direction cosines of the other point +* +* (The coordinate frames correspond to RA,Dec, Long,Lat etc.) +* +* The result is the bearing (position angle), in radians, of point +* V2 with respect to point V1. It is in the range +/- pi. The +* sense is such that if V2 is a small distance east of V1, the +* bearing is about +pi/2. Zero is returned if the two points +* are coincident. +* +* V1 and V2 need not be unit vectors. +* +* The routine sla_DBEAR performs an equivalent function except +* that the points are specified in the form of spherical +* coordinates. +* +* Patrick Wallace Starlink 13 July 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION V1(3),V2(3) + + DOUBLE PRECISION X1,Y1,Z1,W,R,XU1,YU1,ZU1,DX,DY,DZ,SQ,CQ + + + +* Unit vector to point 1 + X1=V1(1) + Y1=V1(2) + Z1=V1(3) + W=SQRT(X1*X1+Y1*Y1+Z1*Z1) + IF (W.NE.0D0) THEN + X1=X1/W + Y1=Y1/W + Z1=Z1/W + END IF + +* Unit vector "north" from point 1 + R=SQRT(X1*X1+Y1*Y1) + IF (R.EQ.0.0) R=1D-5 + W=Z1/R + XU1=-X1*W + YU1=-Y1*W + ZU1=R + +* Vector from point 1 to point 2 + DX=V2(1)-X1 + DY=V2(2)-Y1 + DZ=V2(3)-Z1 + +* Position angle + SQ=DX*YU1*Z1+DY*ZU1*X1+DZ*XU1*Y1-DZ*YU1*X1-DY*XU1*Z1-DX*ZU1*Y1 + CQ=DX*XU1+DY*YU1+DZ*ZU1 + IF (SQ.EQ.0D0.AND.CQ.EQ.0D0) CQ=1D0 + sla_DPAV=ATAN2(SQ,CQ) + + END diff --git a/src/slalib/dr2af.f b/src/slalib/dr2af.f new file mode 100644 index 0000000..3f9dbf3 --- /dev/null +++ b/src/slalib/dr2af.f @@ -0,0 +1,58 @@ + SUBROUTINE sla_DR2AF (NDP, ANGLE, SIGN, IDMSF) +*+ +* - - - - - - +* D R 2 A F +* - - - - - - +* +* Convert an angle in radians to degrees, arcminutes, arcseconds +* (double precision) +* +* Given: +* NDP i number of decimal places of arcseconds +* ANGLE d angle in radians +* +* Returned: +* SIGN c '+' or '-' +* IDMSF i(4) degrees, arcminutes, arcseconds, fraction +* +* Notes: +* +* 1) NDP less than zero is interpreted as zero. +* +* 2) The largest useful value for NDP is determined by the size +* of ANGLE, the format of DOUBLE PRECISION floating-point +* numbers on the target machine, and the risk of overflowing +* IDMSF(4). For example, on the VAX, for ANGLE up to 2pi, the +* available floating-point precision corresponds roughly to +* NDP=12. However, the practical limit is NDP=9, set by the +* capacity of the 32-bit integer IDMSF(4). +* +* 3) The absolute value of ANGLE may exceed 2pi. In cases where it +* does not, it is up to the caller to test for and handle the +* case where ANGLE is very nearly 2pi and rounds up to 360 deg, +* by testing for IDMSF(1)=360 and setting IDMSF(1-4) to zero. +* +* Called: sla_DD2TF +* +* P.T.Wallace Starlink 19 March 1999 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER NDP + DOUBLE PRECISION ANGLE + CHARACTER SIGN*(*) + INTEGER IDMSF(4) + +* Hours to degrees * radians to turns + DOUBLE PRECISION F + PARAMETER (F=15D0/6.283185307179586476925287D0) + + + +* Scale then use days to h,m,s routine + CALL sla_DD2TF(NDP,ANGLE*F,SIGN,IDMSF) + + END diff --git a/src/slalib/dr2tf.f b/src/slalib/dr2tf.f new file mode 100644 index 0000000..f8f2a71 --- /dev/null +++ b/src/slalib/dr2tf.f @@ -0,0 +1,58 @@ + SUBROUTINE sla_DR2TF (NDP, ANGLE, SIGN, IHMSF) +*+ +* - - - - - - +* D R 2 T F +* - - - - - - +* +* Convert an angle in radians to hours, minutes, seconds +* (double precision) +* +* Given: +* NDP i number of decimal places of seconds +* ANGLE d angle in radians +* +* Returned: +* SIGN c '+' or '-' +* IHMSF i(4) hours, minutes, seconds, fraction +* +* Notes: +* +* 1) NDP less than zero is interpreted as zero. +* +* 2) The largest useful value for NDP is determined by the size +* of ANGLE, the format of DOUBLE PRECISION floating-point +* numbers on the target machine, and the risk of overflowing +* IHMSF(4). For example, on the VAX, for ANGLE up to 2pi, the +* available floating-point precision corresponds roughly to +* NDP=12. However, the practical limit is NDP=9, set by the +* capacity of the 32-bit integer IHMSF(4). +* +* 3) The absolute value of ANGLE may exceed 2pi. In cases where it +* does not, it is up to the caller to test for and handle the +* case where ANGLE is very nearly 2pi and rounds up to 24 hours, +* by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +* +* Called: sla_DD2TF +* +* P.T.Wallace Starlink 19 March 1999 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER NDP + DOUBLE PRECISION ANGLE + CHARACTER SIGN*(*) + INTEGER IHMSF(4) + +* Turns to radians + DOUBLE PRECISION T2R + PARAMETER (T2R=6.283185307179586476925287D0) + + + +* Scale then use days to h,m,s routine + CALL sla_DD2TF(NDP,ANGLE/T2R,SIGN,IHMSF) + + END diff --git a/src/slalib/drange.f b/src/slalib/drange.f new file mode 100644 index 0000000..9e678af --- /dev/null +++ b/src/slalib/drange.f @@ -0,0 +1,32 @@ + DOUBLE PRECISION FUNCTION sla_DRANGE (ANGLE) +*+ +* - - - - - - - +* D R A N G E +* - - - - - - - +* +* Normalize angle into range +/- pi (double precision) +* +* Given: +* ANGLE dp the angle in radians +* +* The result (double precision) is ANGLE expressed in the range +/- pi. +* +* P.T.Wallace Starlink 23 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION ANGLE + + DOUBLE PRECISION DPI,D2PI + PARAMETER (DPI=3.141592653589793238462643D0) + PARAMETER (D2PI=6.283185307179586476925287D0) + + + sla_DRANGE=MOD(ANGLE,D2PI) + IF (ABS(sla_DRANGE).GE.DPI) + : sla_DRANGE=sla_DRANGE-SIGN(D2PI,ANGLE) + + END diff --git a/src/slalib/dranrm.f b/src/slalib/dranrm.f new file mode 100644 index 0000000..ee9af25 --- /dev/null +++ b/src/slalib/dranrm.f @@ -0,0 +1,31 @@ + DOUBLE PRECISION FUNCTION sla_DRANRM (ANGLE) +*+ +* - - - - - - - +* D R A N R M +* - - - - - - - +* +* Normalize angle into range 0-2 pi (double precision) +* +* Given: +* ANGLE dp the angle in radians +* +* The result is ANGLE expressed in the range 0-2 pi (double +* precision). +* +* P.T.Wallace Starlink 23 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION ANGLE + + DOUBLE PRECISION D2PI + PARAMETER (D2PI=6.283185307179586476925286766559D0) + + + sla_DRANRM=MOD(ANGLE,D2PI) + IF (sla_DRANRM.LT.0D0) sla_DRANRM=sla_DRANRM+D2PI + + END diff --git a/src/slalib/ds2c6.f b/src/slalib/ds2c6.f new file mode 100644 index 0000000..56298f3 --- /dev/null +++ b/src/slalib/ds2c6.f @@ -0,0 +1,57 @@ + SUBROUTINE sla_DS2C6 (A, B, R, AD, BD, RD, V) +*+ +* - - - - - - +* D S 2 C 6 +* - - - - - - +* +* Conversion of position & velocity in spherical coordinates +* to Cartesian coordinates +* +* (double precision) +* +* Given: +* A dp longitude (radians) +* B dp latitude (radians) +* R dp radial coordinate +* AD dp longitude derivative (radians per unit time) +* BD dp latitude derivative (radians per unit time) +* RD dp radial derivative +* +* Returned: +* V dp(6) Cartesian position & velocity vector +* +* P.T.Wallace Starlink 10 July 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION A,B,R,AD,BD,RD,V(6) + + DOUBLE PRECISION SA,CA,SB,CB,RCB,X,Y,RBD,W + + + +* Useful functions + SA=SIN(A) + CA=COS(A) + SB=SIN(B) + CB=COS(B) + RCB=R*CB + X=RCB*CA + Y=RCB*SA + RBD=R*BD + W=RBD*SB-CB*RD + +* Position + V(1)=X + V(2)=Y + V(3)=R*SB + +* Velocity + V(4)=-Y*AD-W*CA + V(5)=X*AD-W*SA + V(6)=RBD*CB+SB*RD + + END diff --git a/src/slalib/ds2tp.f b/src/slalib/ds2tp.f new file mode 100644 index 0000000..ab1ccf9 --- /dev/null +++ b/src/slalib/ds2tp.f @@ -0,0 +1,67 @@ + SUBROUTINE sla_DS2TP (RA, DEC, RAZ, DECZ, XI, ETA, J) +*+ +* - - - - - - +* D S 2 T P +* - - - - - - +* +* Projection of spherical coordinates onto tangent plane: +* "gnomonic" projection - "standard coordinates" (double precision) +* +* Given: +* RA,DEC dp spherical coordinates of point to be projected +* RAZ,DECZ dp spherical coordinates of tangent point +* +* Returned: +* XI,ETA dp rectangular coordinates on tangent plane +* J int status: 0 = OK, star on tangent plane +* 1 = error, star too far from axis +* 2 = error, antistar on tangent plane +* 3 = error, antistar too far from axis +* +* P.T.Wallace Starlink 18 July 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RA,DEC,RAZ,DECZ,XI,ETA + INTEGER J + + DOUBLE PRECISION SDECZ,SDEC,CDECZ,CDEC, + : RADIF,SRADIF,CRADIF,DENOM + + DOUBLE PRECISION TINY + PARAMETER (TINY=1D-6) + + +* Trig functions + SDECZ=SIN(DECZ) + SDEC=SIN(DEC) + CDECZ=COS(DECZ) + CDEC=COS(DEC) + RADIF=RA-RAZ + SRADIF=SIN(RADIF) + CRADIF=COS(RADIF) + +* Reciprocal of star vector length to tangent plane + DENOM=SDEC*SDECZ+CDEC*CDECZ*CRADIF + +* Handle vectors too far from axis + IF (DENOM.GT.TINY) THEN + J=0 + ELSE IF (DENOM.GE.0D0) THEN + J=1 + DENOM=TINY + ELSE IF (DENOM.GT.-TINY) THEN + J=2 + DENOM=-TINY + ELSE + J=3 + END IF + +* Compute tangent plane coordinates (even in dubious cases) + XI=CDEC*SRADIF/DENOM + ETA=(SDEC*CDECZ-CDEC*SDECZ*CRADIF)/DENOM + + END diff --git a/src/slalib/dsep.f b/src/slalib/dsep.f new file mode 100644 index 0000000..b1bd4be --- /dev/null +++ b/src/slalib/dsep.f @@ -0,0 +1,48 @@ + DOUBLE PRECISION FUNCTION sla_DSEP (A1, B1, A2, B2) +*+ +* - - - - - +* D S E P +* - - - - - +* +* Angle between two points on a sphere (double precision) +* +* Given: +* A1,B1 dp spherical coordinates of one point +* A2,B2 dp spherical coordinates of the other point +* +* (The spherical coordinates are RA,Dec, Long,Lat etc, in radians.) +* +* The result is the angle, in radians, between the two points. It +* is always positive. +* +* Called: sla_DCS2C +* +* P.T.Wallace Starlink April 1985 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION A1,B1,A2,B2 + + INTEGER I + DOUBLE PRECISION V1(3),V2(3),W + + + +* Convert coordinates from spherical to Cartesian + CALL sla_DCS2C(A1,B1,V1) + CALL sla_DCS2C(A2,B2,V2) + +* Modulus squared of half the difference vector + W=0D0 + DO I=1,3 + W=W+(V1(I)-V2(I))**2 + END DO + W=W/4D0 + +* Angle between the vectors + sla_DSEP=2D0*ATAN2(SQRT(W),SQRT(MAX(0D0,1D0-W))) + + END diff --git a/src/slalib/dt.f b/src/slalib/dt.f new file mode 100644 index 0000000..d46c7be --- /dev/null +++ b/src/slalib/dt.f @@ -0,0 +1,79 @@ + DOUBLE PRECISION FUNCTION sla_DT (EPOCH) +*+ +* - - - +* D T +* - - - +* +* Estimate the offset between dynamical time and Universal Time +* for a given historical epoch. +* +* Given: +* EPOCH d (Julian) epoch (e.g. 1850D0) +* +* The result is a rough estimate of ET-UT (after 1984, TT-UT) at +* the given epoch, in seconds. +* +* Notes: +* +* 1 Depending on the epoch, one of three parabolic approximations +* is used: +* +* before 979 Stephenson & Morrison's 390 BC to AD 948 model +* 979 to 1708 Stephenson & Morrison's 948 to 1600 model +* after 1708 McCarthy & Babcock's post-1650 model +* +* The breakpoints are chosen to ensure continuity: they occur +* at places where the adjacent models give the same answer as +* each other. +* +* 2 The accuracy is modest, with errors of up to 20 sec during +* the interval since 1650, rising to perhaps 30 min by 1000 BC. +* Comparatively accurate values from AD 1600 are tabulated in +* the Astronomical Almanac (see section K8 of the 1995 AA). +* +* 3 The use of double-precision for both argument and result is +* purely for compatibility with other SLALIB time routines. +* +* 4 The models used are based on a lunar tidal acceleration value +* of -26.00 arcsec per century. +* +* Reference: Explanatory Supplement to the Astronomical Almanac, +* ed P.K.Seidelmann, University Science Books (1992), +* section 2.553, p83. This contains references to +* the Stephenson & Morrison and McCarthy & Babcock +* papers. +* +* P.T.Wallace Starlink 1 March 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION EPOCH + DOUBLE PRECISION T,W,S + + +* Centuries since 1800 + T=(EPOCH-1800D0)/100D0 + +* Select model + IF (EPOCH.GE.1708.185161980887D0) THEN + +* Post-1708: use McCarthy & Babcock + W=T-0.19D0 + S=5.156D0+13.3066D0*W*W + ELSE IF (EPOCH.GE.979.0258204760233D0) THEN + +* 979-1708: use Stephenson & Morrison's 948-1600 model + S=25.5D0*T*T + ELSE + +* Pre-979: use Stephenson & Morrison's 390 BC to AD 948 model + S=1360.0D0+(320D0+44.3D0*T)*T + END IF + +* Result + sla_DT=S + + END diff --git a/src/slalib/dtf2d.f b/src/slalib/dtf2d.f new file mode 100644 index 0000000..4a25ac6 --- /dev/null +++ b/src/slalib/dtf2d.f @@ -0,0 +1,55 @@ + SUBROUTINE sla_DTF2D (IHOUR, IMIN, SEC, DAYS, J) +*+ +* - - - - - - +* D T F 2 D +* - - - - - - +* +* Convert hours, minutes, seconds to days (double precision) +* +* Given: +* IHOUR int hours +* IMIN int minutes +* SEC dp seconds +* +* Returned: +* DAYS dp interval in days +* J int status: 0 = OK +* 1 = IHOUR outside range 0-23 +* 2 = IMIN outside range 0-59 +* 3 = SEC outside range 0-59.999... +* +* Notes: +* +* 1) The result is computed even if any of the range checks fail. +* +* 2) The sign must be dealt with outside this routine. +* +* P.T.Wallace Starlink July 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IHOUR,IMIN + DOUBLE PRECISION SEC,DAYS + INTEGER J + +* Seconds per day + DOUBLE PRECISION D2S + PARAMETER (D2S=86400D0) + + + +* Preset status + J=0 + +* Validate sec, min, hour + IF (SEC.LT.0D0.OR.SEC.GE.60D0) J=3 + IF (IMIN.LT.0.OR.IMIN.GT.59) J=2 + IF (IHOUR.LT.0.OR.IHOUR.GT.23) J=1 + +* Compute interval + DAYS=(60D0*(60D0*DBLE(IHOUR)+DBLE(IMIN))+SEC)/D2S + + END diff --git a/src/slalib/dtf2r.f b/src/slalib/dtf2r.f new file mode 100644 index 0000000..b100889 --- /dev/null +++ b/src/slalib/dtf2r.f @@ -0,0 +1,53 @@ + SUBROUTINE sla_DTF2R (IHOUR, IMIN, SEC, RAD, J) +*+ +* - - - - - - +* D T F 2 R +* - - - - - - +* +* Convert hours, minutes, seconds to radians (double precision) +* +* Given: +* IHOUR int hours +* IMIN int minutes +* SEC dp seconds +* +* Returned: +* RAD dp angle in radians +* J int status: 0 = OK +* 1 = IHOUR outside range 0-23 +* 2 = IMIN outside range 0-59 +* 3 = SEC outside range 0-59.999... +* +* Called: +* sla_DTF2D +* +* Notes: +* +* 1) The result is computed even if any of the range checks fail. +* +* 2) The sign must be dealt with outside this routine. +* +* P.T.Wallace Starlink July 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IHOUR,IMIN + DOUBLE PRECISION SEC,RAD + INTEGER J + + DOUBLE PRECISION TURNS + +* Turns to radians + DOUBLE PRECISION T2R + PARAMETER (T2R=6.283185307179586476925287D0) + + + +* Convert to turns then radians + CALL sla_DTF2D(IHOUR,IMIN,SEC,TURNS,J) + RAD=T2R*TURNS + + END diff --git a/src/slalib/dtp2s.f b/src/slalib/dtp2s.f new file mode 100644 index 0000000..0a67a11 --- /dev/null +++ b/src/slalib/dtp2s.f @@ -0,0 +1,42 @@ + SUBROUTINE sla_DTP2S (XI, ETA, RAZ, DECZ, RA, DEC) +*+ +* - - - - - - +* D T P 2 S +* - - - - - - +* +* Transform tangent plane coordinates into spherical +* (double precision) +* +* Given: +* XI,ETA dp tangent plane rectangular coordinates +* RAZ,DECZ dp spherical coordinates of tangent point +* +* Returned: +* RA,DEC dp spherical coordinates (0-2pi,+/-pi/2) +* +* Called: sla_DRANRM +* +* P.T.Wallace Starlink 24 July 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION XI,ETA,RAZ,DECZ,RA,DEC + + DOUBLE PRECISION sla_DRANRM + + DOUBLE PRECISION SDECZ,CDECZ,DENOM + + + + SDECZ=SIN(DECZ) + CDECZ=COS(DECZ) + + DENOM=CDECZ-ETA*SDECZ + + RA=sla_DRANRM(ATAN2(XI,DENOM)+RAZ) + DEC=ATAN2(SDECZ+ETA*CDECZ,SQRT(XI*XI+DENOM*DENOM)) + + END diff --git a/src/slalib/dtp2v.f b/src/slalib/dtp2v.f new file mode 100644 index 0000000..e1795b9 --- /dev/null +++ b/src/slalib/dtp2v.f @@ -0,0 +1,56 @@ + SUBROUTINE sla_DTP2V (XI, ETA, V0, V) +*+ +* - - - - - - +* D T P 2 V +* - - - - - - +* +* Given the tangent-plane coordinates of a star and the direction +* cosines of the tangent point, determine the direction cosines +* of the star. +* +* (double precision) +* +* Given: +* XI,ETA d tangent plane coordinates of star +* V0 d(3) direction cosines of tangent point +* +* Returned: +* V d(3) direction cosines of star +* +* Notes: +* +* 1 If vector V0 is not of unit length, the returned vector V will +* be wrong. +* +* 2 If vector V0 points at a pole, the returned vector V will be +* based on the arbitrary assumption that the RA of the tangent +* point is zero. +* +* 3 This routine is the Cartesian equivalent of the routine sla_DTP2S. +* +* P.T.Wallace Starlink 11 February 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION XI,ETA,V0(3),V(3) + + DOUBLE PRECISION X,Y,Z,F,R + + + X=V0(1) + Y=V0(2) + Z=V0(3) + F=SQRT(1D0+XI*XI+ETA*ETA) + R=SQRT(X*X+Y*Y) + IF (R.EQ.0D0) THEN + R=1D-20 + X=R + END IF + V(1)=(X-(XI*Y+ETA*X*Z)/R)/F + V(2)=(Y+(XI*X-ETA*Y*Z)/R)/F + V(3)=(Z+ETA*R)/F + + END diff --git a/src/slalib/dtps2c.f b/src/slalib/dtps2c.f new file mode 100644 index 0000000..43e3bad --- /dev/null +++ b/src/slalib/dtps2c.f @@ -0,0 +1,91 @@ + SUBROUTINE sla_DTPS2C (XI, ETA, RA, DEC, RAZ1, DECZ1, + : RAZ2, DECZ2, N) +*+ +* - - - - - - - +* D T P S 2 C +* - - - - - - - +* +* From the tangent plane coordinates of a star of known RA,Dec, +* determine the RA,Dec of the tangent point. +* +* (double precision) +* +* Given: +* XI,ETA d tangent plane rectangular coordinates +* RA,DEC d spherical coordinates +* +* Returned: +* RAZ1,DECZ1 d spherical coordinates of tangent point, solution 1 +* RAZ2,DECZ2 d spherical coordinates of tangent point, solution 2 +* N i number of solutions: +* 0 = no solutions returned (note 2) +* 1 = only the first solution is useful (note 3) +* 2 = both solutions are useful (note 3) +* +* Notes: +* +* 1 The RAZ1 and RAZ2 values are returned in the range 0-2pi. +* +* 2 Cases where there is no solution can only arise near the poles. +* For example, it is clearly impossible for a star at the pole +* itself to have a non-zero XI value, and hence it is +* meaningless to ask where the tangent point would have to be +* to bring about this combination of XI and DEC. +* +* 3 Also near the poles, cases can arise where there are two useful +* solutions. The argument N indicates whether the second of the +* two solutions returned is useful. N=1 indicates only one useful +* solution, the usual case; under these circumstances, the second +* solution corresponds to the "over-the-pole" case, and this is +* reflected in the values of RAZ2 and DECZ2 which are returned. +* +* 4 The DECZ1 and DECZ2 values are returned in the range +/-pi, but +* in the usual, non-pole-crossing, case, the range is +/-pi/2. +* +* 5 This routine is the spherical equivalent of the routine sla_DTPV2C. +* +* Called: sla_DRANRM +* +* P.T.Wallace Starlink 5 June 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION XI,ETA,RA,DEC,RAZ1,DECZ1,RAZ2,DECZ2 + INTEGER N + + DOUBLE PRECISION X2,Y2,SD,CD,SDF,R2,R,S,C + + DOUBLE PRECISION sla_DRANRM + + + X2=XI*XI + Y2=ETA*ETA + SD=SIN(DEC) + CD=COS(DEC) + SDF=SD*SQRT(1D0+X2+Y2) + R2=CD*CD*(1D0+Y2)-SD*SD*X2 + IF (R2.GE.0D0) THEN + R=SQRT(R2) + S=SDF-ETA*R + C=SDF*ETA+R + IF (XI.EQ.0D0.AND.R.EQ.0D0) R=1D0 + RAZ1=sla_DRANRM(RA-ATAN2(XI,R)) + DECZ1=ATAN2(S,C) + R=-R + S=SDF-ETA*R + C=SDF*ETA+R + RAZ2=sla_DRANRM(RA-ATAN2(XI,R)) + DECZ2=ATAN2(S,C) + IF (ABS(SDF).LT.1D0) THEN + N=1 + ELSE + N=2 + END IF + ELSE + N=0 + END IF + + END diff --git a/src/slalib/dtpv2c.f b/src/slalib/dtpv2c.f new file mode 100644 index 0000000..6ea2c29 --- /dev/null +++ b/src/slalib/dtpv2c.f @@ -0,0 +1,83 @@ + SUBROUTINE sla_DTPV2C (XI, ETA, V, V01, V02, N) +*+ +* - - - - - - - +* D T P V 2 C +* - - - - - - - +* +* Given the tangent-plane coordinates of a star and its direction +* cosines, determine the direction cosines of the tangent-point. +* +* (double precision) +* +* Given: +* XI,ETA d tangent plane coordinates of star +* V d(3) direction cosines of star +* +* Returned: +* V01 d(3) direction cosines of tangent point, solution 1 +* V02 d(3) direction cosines of tangent point, solution 2 +* N i number of solutions: +* 0 = no solutions returned (note 2) +* 1 = only the first solution is useful (note 3) +* 2 = both solutions are useful (note 3) +* +* Notes: +* +* 1 The vector V must be of unit length or the result will be wrong. +* +* 2 Cases where there is no solution can only arise near the poles. +* For example, it is clearly impossible for a star at the pole +* itself to have a non-zero XI value, and hence it is meaningless +* to ask where the tangent point would have to be. +* +* 3 Also near the poles, cases can arise where there are two useful +* solutions. The argument N indicates whether the second of the +* two solutions returned is useful. N=1 indicates only one useful +* solution, the usual case; under these circumstances, the second +* solution can be regarded as valid if the vector V02 is interpreted +* as the "over-the-pole" case. +* +* 4 This routine is the Cartesian equivalent of the routine sla_DTPS2C. +* +* P.T.Wallace Starlink 5 June 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION XI,ETA,V(3),V01(3),V02(3) + INTEGER N + + DOUBLE PRECISION X,Y,Z,RXY2,XI2,ETA2P1,SDF,R2,R,C + + + X=V(1) + Y=V(2) + Z=V(3) + RXY2=X*X+Y*Y + XI2=XI*XI + ETA2P1=ETA*ETA+1D0 + SDF=Z*SQRT(XI2+ETA2P1) + R2=RXY2*ETA2P1-Z*Z*XI2 + IF (R2.GT.0D0) THEN + R=SQRT(R2) + C=(SDF*ETA+R)/(ETA2P1*SQRT(RXY2*(R2+XI2))) + V01(1)=C*(X*R+Y*XI) + V01(2)=C*(Y*R-X*XI) + V01(3)=(SDF-ETA*R)/ETA2P1 + R=-R + C=(SDF*ETA+R)/(ETA2P1*SQRT(RXY2*(R2+XI2))) + V02(1)=C*(X*R+Y*XI) + V02(2)=C*(Y*R-X*XI) + V02(3)=(SDF-ETA*R)/ETA2P1 + IF (ABS(SDF).LT.1D0) THEN + N=1 + ELSE + N=2 + END IF + ELSE + N=0 + END IF + + END diff --git a/src/slalib/dtt.f b/src/slalib/dtt.f new file mode 100644 index 0000000..9d456ef --- /dev/null +++ b/src/slalib/dtt.f @@ -0,0 +1,46 @@ + DOUBLE PRECISION FUNCTION sla_DTT (UTC) +*+ +* - - - - +* D T T +* - - - - +* +* Increment to be applied to Coordinated Universal Time UTC to give +* Terrestrial Time TT (formerly Ephemeris Time ET) +* +* (double precision) +* +* Given: +* UTC d UTC date as a modified JD (JD-2400000.5) +* +* Result: TT-UTC in seconds +* +* Notes: +* +* 1 The UTC is specified to be a date rather than a time to indicate +* that care needs to be taken not to specify an instant which lies +* within a leap second. Though in most cases UTC can include the +* fractional part, correct behaviour on the day of a leap second +* can only be guaranteed up to the end of the second 23:59:59. +* +* 2 Pre 1972 January 1 a fixed value of 10 + ET-TAI is returned. +* +* 3 See also the routine sla_DT, which roughly estimates ET-UT for +* historical epochs. +* +* Called: sla_DAT +* +* P.T.Wallace Starlink 6 December 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION UTC + + DOUBLE PRECISION sla_DAT + + + sla_DTT=32.184D0+sla_DAT(UTC) + + END diff --git a/src/slalib/dv2tp.f b/src/slalib/dv2tp.f new file mode 100644 index 0000000..9bf2c33 --- /dev/null +++ b/src/slalib/dv2tp.f @@ -0,0 +1,78 @@ + SUBROUTINE sla_DV2TP (V, V0, XI, ETA, J) +*+ +* - - - - - - +* D V 2 T P +* - - - - - - +* +* Given the direction cosines of a star and of the tangent point, +* determine the star's tangent-plane coordinates. +* +* (double precision) +* +* Given: +* V d(3) direction cosines of star +* V0 d(3) direction cosines of tangent point +* +* Returned: +* XI,ETA d tangent plane coordinates of star +* J i status: 0 = OK +* 1 = error, star too far from axis +* 2 = error, antistar on tangent plane +* 3 = error, antistar too far from axis +* +* Notes: +* +* 1 If vector V0 is not of unit length, or if vector V is of zero +* length, the results will be wrong. +* +* 2 If V0 points at a pole, the returned XI,ETA will be based on the +* arbitrary assumption that the RA of the tangent point is zero. +* +* 3 This routine is the Cartesian equivalent of the routine sla_DS2TP. +* +* P.T.Wallace Starlink 27 November 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION V(3),V0(3),XI,ETA + INTEGER J + + DOUBLE PRECISION X,Y,Z,X0,Y0,Z0,R2,R,W,D + + DOUBLE PRECISION TINY + PARAMETER (TINY=1D-6) + + + X=V(1) + Y=V(2) + Z=V(3) + X0=V0(1) + Y0=V0(2) + Z0=V0(3) + R2=X0*X0+Y0*Y0 + R=SQRT(R2) + IF (R.EQ.0D0) THEN + R=1D-20 + X0=R + END IF + W=X*X0+Y*Y0 + D=W+Z*Z0 + IF (D.GT.TINY) THEN + J=0 + ELSE IF (D.GE.0D0) THEN + J=1 + D=TINY + ELSE IF (D.GT.-TINY) THEN + J=2 + D=-TINY + ELSE + J=3 + END IF + D=D*R + XI=(Y*X0-X*Y0)/D + ETA=(Z*R2-Z0*W)/D + + END diff --git a/src/slalib/dvdv.f b/src/slalib/dvdv.f new file mode 100644 index 0000000..ab3e411 --- /dev/null +++ b/src/slalib/dvdv.f @@ -0,0 +1,27 @@ + DOUBLE PRECISION FUNCTION sla_DVDV (VA, VB) +*+ +* - - - - - +* D V D V +* - - - - - +* +* Scalar product of two 3-vectors (double precision) +* +* Given: +* VA dp(3) first vector +* VB dp(3) second vector +* +* The result is the scalar product VA.VB (double precision) +* +* P.T.Wallace Starlink November 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION VA(3),VB(3) + + + sla_DVDV=VA(1)*VB(1)+VA(2)*VB(2)+VA(3)*VB(3) + + END diff --git a/src/slalib/dvn.f b/src/slalib/dvn.f new file mode 100644 index 0000000..37a4a6d --- /dev/null +++ b/src/slalib/dvn.f @@ -0,0 +1,46 @@ + SUBROUTINE sla_DVN (V, UV, VM) +*+ +* - - - - +* D V N +* - - - - +* +* Normalizes a 3-vector also giving the modulus (double precision) +* +* Given: +* V dp(3) vector +* +* Returned: +* UV dp(3) unit vector in direction of V +* VM dp modulus of V +* +* If the modulus of V is zero, UV is set to zero as well +* +* P.T.Wallace Starlink 23 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION V(3),UV(3),VM + + INTEGER I + DOUBLE PRECISION W1,W2 + + +* Modulus + W1=0D0 + DO I=1,3 + W2=V(I) + W1=W1+W2*W2 + END DO + W1=SQRT(W1) + VM=W1 + +* Normalize the vector + IF (W1.LE.0D0) W1=1D0 + DO I=1,3 + UV(I)=V(I)/W1 + END DO + + END diff --git a/src/slalib/dvxv.f b/src/slalib/dvxv.f new file mode 100644 index 0000000..389deb4 --- /dev/null +++ b/src/slalib/dvxv.f @@ -0,0 +1,39 @@ + SUBROUTINE sla_DVXV (VA, VB, VC) +*+ +* - - - - - +* D V X V +* - - - - - +* +* Vector product of two 3-vectors (double precision) +* +* Given: +* VA dp(3) first vector +* VB dp(3) second vector +* +* Returned: +* VC dp(3) vector result +* +* P.T.Wallace Starlink March 1986 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION VA(3),VB(3),VC(3) + + DOUBLE PRECISION VW(3) + INTEGER I + + +* Form the vector product VA cross VB + VW(1)=VA(2)*VB(3)-VA(3)*VB(2) + VW(2)=VA(3)*VB(1)-VA(1)*VB(3) + VW(3)=VA(1)*VB(2)-VA(2)*VB(1) + +* Return the result + DO I=1,3 + VC(I)=VW(I) + END DO + + END diff --git a/src/slalib/e2h.f b/src/slalib/e2h.f new file mode 100644 index 0000000..03e36d3 --- /dev/null +++ b/src/slalib/e2h.f @@ -0,0 +1,89 @@ + SUBROUTINE sla_E2H (HA, DEC, PHI, AZ, EL) +*+ +* - - - - +* E 2 H +* - - - - +* +* Equatorial to horizon coordinates: HA,Dec to Az,El +* +* (single precision) +* +* Given: +* HA r hour angle +* DEC r declination +* PHI r observatory latitude +* +* Returned: +* AZ r azimuth +* EL r elevation +* +* Notes: +* +* 1) All the arguments are angles in radians. +* +* 2) Azimuth is returned in the range 0-2pi; north is zero, +* and east is +pi/2. Elevation is returned in the range +* +/-pi/2. +* +* 3) The latitude must be geodetic. In critical applications, +* corrections for polar motion should be applied. +* +* 4) In some applications it will be important to specify the +* correct type of hour angle and declination in order to +* produce the required type of azimuth and elevation. In +* particular, it may be important to distinguish between +* elevation as affected by refraction, which would +* require the "observed" HA,Dec, and the elevation +* in vacuo, which would require the "topocentric" HA,Dec. +* If the effects of diurnal aberration can be neglected, the +* "apparent" HA,Dec may be used instead of the topocentric +* HA,Dec. +* +* 5) No range checking of arguments is carried out. +* +* 6) In applications which involve many such calculations, rather +* than calling the present routine it will be more efficient to +* use inline code, having previously computed fixed terms such +* as sine and cosine of latitude, and (for tracking a star) +* sine and cosine of declination. +* +* P.T.Wallace Starlink 9 July 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL HA,DEC,PHI,AZ,EL + + REAL R2PI + PARAMETER (R2PI=6.283185307179586476925286766559) + + REAL SH,CH,SD,CD,SP,CP,X,Y,Z,R,A + + +* Useful trig functions + SH=SIN(HA) + CH=COS(HA) + SD=SIN(DEC) + CD=COS(DEC) + SP=SIN(PHI) + CP=COS(PHI) + +* Az,El as x,y,z + X=-CH*CD*SP+SD*CP + Y=-SH*CD + Z=CH*CD*CP+SD*SP + +* To spherical + R=SQRT(X*X+Y*Y) + IF (R.EQ.0.0) THEN + A=0.0 + ELSE + A=ATAN2(Y,X) + END IF + IF (A.LT.0.0) A=A+R2PI + AZ=A + EL=ATAN2(Z,R) + + END diff --git a/src/slalib/earth.f b/src/slalib/earth.f new file mode 100644 index 0000000..f37ba2e --- /dev/null +++ b/src/slalib/earth.f @@ -0,0 +1,111 @@ + SUBROUTINE sla_EARTH (IY, ID, FD, PV) +*+ +* - - - - - - +* E A R T H +* - - - - - - +* +* Approximate heliocentric position and velocity of the Earth +* +* Given: +* IY I year +* ID I day in year (1 = Jan 1st) +* FD R fraction of day +* +* Returned: +* PV R(6) Earth position & velocity vector +* +* Notes: +* +* 1 The date and time is TDB (loosely ET) in a Julian calendar +* which has been aligned to the ordinary Gregorian +* calendar for the interval 1900 March 1 to 2100 February 28. +* The year and day can be obtained by calling sla_CALYD or +* sla_CLYD. +* +* 2 The Earth heliocentric 6-vector is mean equator and equinox +* of date. Position part, PV(1-3), is in AU; velocity part, +* PV(4-6), is in AU/sec. +* +* 3 Max/RMS errors 1950-2050: +* 13/5 E-5 AU = 19200/7600 km in position +* 47/26 E-10 AU/s = 0.0070/0.0039 km/s in speed +* +* 4 More precise results are obtainable with the routine sla_EVP. +* +* P.T.Wallace Starlink 23 November 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IY,ID + REAL FD,PV(6) + + INTEGER IY4 + REAL TWOPI,SPEED,REMB,SEMB,YI,YF,T,ELM,GAMMA,EM,ELT,EPS0, + : E,ESQ,V,R,ELMM,COSELT,SINEPS,COSEPS,W1,W2,SELMM,CELMM + + PARAMETER (TWOPI=6.28318530718) + +* Mean orbital speed of Earth, AU/s + PARAMETER (SPEED=1.9913E-7) + +* Mean Earth:EMB distance and speed, AU and AU/s + PARAMETER (REMB=3.12E-5,SEMB=8.31E-11) + + + +* Whole years & fraction of year, and years since J1900.0 + YI=FLOAT(IY-1900) + IY4=MOD(MOD(IY,4)+4,4) + YF=(FLOAT(4*(ID-1/(IY4+1))-IY4-2)+4.0*FD)/1461.0 + T=YI+YF + +* Geometric mean longitude of Sun +* (cf 4.881627938+6.283319509911*T MOD 2PI) + ELM=MOD(4.881628+TWOPI*YF+0.00013420*T,TWOPI) + +* Mean longitude of perihelion + GAMMA=4.908230+3.0005E-4*T + +* Mean anomaly + EM=ELM-GAMMA + +* Mean obliquity + EPS0=0.40931975-2.27E-6*T + +* Eccentricity + E=0.016751-4.2E-7*T + ESQ=E*E + +* True anomaly + V=EM+2.0*E*SIN(EM)+1.25*ESQ*SIN(2.0*EM) + +* True ecliptic longitude + ELT=V+GAMMA + +* True distance + R=(1.0-ESQ)/(1.0+E*COS(V)) + +* Moon's mean longitude + ELMM=MOD(4.72+83.9971*T,TWOPI) + +* Useful functions + COSELT=COS(ELT) + SINEPS=SIN(EPS0) + COSEPS=COS(EPS0) + W1=-R*SIN(ELT) + W2=-SPEED*(COSELT+E*COS(GAMMA)) + SELMM=SIN(ELMM) + CELMM=COS(ELMM) + +* Earth position and velocity + PV(1)=-R*COSELT-REMB*CELMM + PV(2)=(W1-REMB*SELMM)*COSEPS + PV(3)=W1*SINEPS + PV(4)=SPEED*(SIN(ELT)+E*SIN(GAMMA))+SEMB*SELMM + PV(5)=(W2-SEMB*CELMM)*COSEPS + PV(6)=W2*SINEPS + + END diff --git a/src/slalib/ecleq.f b/src/slalib/ecleq.f new file mode 100644 index 0000000..5aa93c9 --- /dev/null +++ b/src/slalib/ecleq.f @@ -0,0 +1,55 @@ + SUBROUTINE sla_ECLEQ (DL, DB, DATE, DR, DD) +*+ +* - - - - - - +* E C L E Q +* - - - - - - +* +* Transformation from ecliptic coordinates to +* J2000.0 equatorial coordinates (double precision) +* +* Given: +* DL,DB dp ecliptic longitude and latitude +* (mean of date, IAU 1980 theory, radians) +* DATE dp TDB (loosely ET) as Modified Julian Date +* (JD-2400000.5) +* Returned: +* DR,DD dp J2000.0 mean RA,Dec (radians) +* +* Called: +* sla_DCS2C, sla_ECMAT, sla_DIMXV, sla_PREC, sla_EPJ, sla_DCC2S, +* sla_DRANRM, sla_DRANGE +* +* P.T.Wallace Starlink March 1986 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DL,DB,DATE,DR,DD + + DOUBLE PRECISION sla_EPJ,sla_DRANRM,sla_DRANGE + + DOUBLE PRECISION RMAT(3,3),V1(3),V2(3) + + + +* Spherical to Cartesian + CALL sla_DCS2C(DL,DB,V1) + +* Ecliptic to equatorial + CALL sla_ECMAT(DATE,RMAT) + CALL sla_DIMXV(RMAT,V1,V2) + +* Mean of date to J2000 + CALL sla_PREC(2000D0,sla_EPJ(DATE),RMAT) + CALL sla_DIMXV(RMAT,V2,V1) + +* Cartesian to spherical + CALL sla_DCC2S(V1,DR,DD) + +* Express in conventional ranges + DR=sla_DRANRM(DR) + DD=sla_DRANGE(DD) + + END diff --git a/src/slalib/ecmat.f b/src/slalib/ecmat.f new file mode 100644 index 0000000..3a1f8d4 --- /dev/null +++ b/src/slalib/ecmat.f @@ -0,0 +1,52 @@ + SUBROUTINE sla_ECMAT (DATE, RMAT) +*+ +* - - - - - - +* E C M A T +* - - - - - - +* +* Form the equatorial to ecliptic rotation matrix - IAU 1980 theory +* (double precision) +* +* Given: +* DATE dp TDB (loosely ET) as Modified Julian Date +* (JD-2400000.5) +* Returned: +* RMAT dp(3,3) matrix +* +* Reference: +* Murray,C.A., Vectorial Astrometry, section 4.3. +* +* Note: +* The matrix is in the sense V(ecl) = RMAT * V(equ); the +* equator, equinox and ecliptic are mean of date. +* +* Called: sla_DEULER +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,RMAT(3,3) + +* Arc seconds to radians + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + + DOUBLE PRECISION T,EPS0 + + + +* Interval between basic epoch J2000.0 and current epoch (JC) + T = (DATE-51544.5D0)/36525D0 + +* Mean obliquity + EPS0 = AS2R* + : (84381.448D0+(-46.8150D0+(-0.00059D0+0.001813D0*T)*T)*T) + +* Matrix + CALL sla_DEULER('X',EPS0,0D0,0D0,RMAT) + + END diff --git a/src/slalib/ecor.f b/src/slalib/ecor.f new file mode 100644 index 0000000..b936909 --- /dev/null +++ b/src/slalib/ecor.f @@ -0,0 +1,78 @@ + SUBROUTINE sla_ECOR (RM, DM, IY, ID, FD, RV, TL) +*+ +* - - - - - +* E C O R +* - - - - - +* +* Component of Earth orbit velocity and heliocentric +* light time in a given direction (single precision) +* +* Given: +* RM,DM real mean RA, Dec of date (radians) +* IY int year +* ID int day in year (1 = Jan 1st) +* FD real fraction of day +* +* Returned: +* RV real component of Earth orbital velocity (km/sec) +* TL real component of heliocentric light time (sec) +* +* Notes: +* +* 1 The date and time is TDB (loosely ET) in a Julian calendar +* which has been aligned to the ordinary Gregorian +* calendar for the interval 1900 March 1 to 2100 February 28. +* The year and day can be obtained by calling sla_CALYD or +* sla_CLYD. +* +* 2 Sign convention: +* +* The velocity component is +ve when the Earth is receding from +* the given point on the sky. The light time component is +ve +* when the Earth lies between the Sun and the given point on +* the sky. +* +* 3 Accuracy: +* +* The velocity component is usually within 0.004 km/s of the +* correct value and is never in error by more than 0.007 km/s. +* The error in light time correction is about 0.03s at worst, +* but is usually better than 0.01s. For applications requiring +* higher accuracy, see the sla_EVP routine. +* +* Called: sla_EARTH, sla_CS2C, sla_VDV +* +* P.T.Wallace Starlink 24 November 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL RM,DM + INTEGER IY,ID + REAL FD,RV,TL + + REAL sla_VDV + + REAL PV(6),V(3),AUKM,AUSEC + +* AU to km and light sec (1985 Almanac) + PARAMETER (AUKM=1.4959787066E8, + : AUSEC=499.0047837) + + + +* Sun:Earth position & velocity vector + CALL sla_EARTH(IY,ID,FD,PV) + +* Star position vector + CALL sla_CS2C(RM,DM,V) + +* Velocity component + RV=-AUKM*sla_VDV(PV(4),V) + +* Light time component + TL=AUSEC*sla_VDV(PV(1),V) + + END diff --git a/src/slalib/eg50.f b/src/slalib/eg50.f new file mode 100644 index 0000000..343fc11 --- /dev/null +++ b/src/slalib/eg50.f @@ -0,0 +1,90 @@ + SUBROUTINE sla_EG50 (DR, DD, DL, DB) +*+ +* - - - - - +* E G 5 0 +* - - - - - +* +* Transformation from B1950.0 'FK4' equatorial coordinates to +* IAU 1958 galactic coordinates (double precision) +* +* Given: +* DR,DD dp B1950.0 'FK4' RA,Dec +* +* Returned: +* DL,DB dp galactic longitude and latitude L2,B2 +* +* (all arguments are radians) +* +* Called: +* sla_DCS2C, sla_DMXV, sla_DCC2S, sla_SUBET, sla_DRANRM, sla_DRANGE +* +* Note: +* The equatorial coordinates are B1950.0 'FK4'. Use the +* routine sla_EQGAL if conversion from J2000.0 coordinates +* is required. +* +* Reference: +* Blaauw et al, Mon.Not.R.Astron.Soc.,121,123 (1960) +* +* P.T.Wallace Starlink 5 September 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DR,DD,DL,DB + + DOUBLE PRECISION sla_DRANRM,sla_DRANGE + + DOUBLE PRECISION V1(3),V2(3),R,D + +* +* L2,B2 system of galactic coordinates +* +* P = 192.25 RA of galactic north pole (mean B1950.0) +* Q = 62.6 inclination of galactic to mean B1950.0 equator +* R = 33 longitude of ascending node +* +* P,Q,R are degrees +* +* +* Equatorial to galactic rotation matrix +* +* The Euler angles are P, Q, 90-R, about the z then y then +* z axes. +* +* +CP.CQ.SR-SP.CR +SP.CQ.SR+CP.CR -SQ.SR +* +* -CP.CQ.CR-SP.SR -SP.CQ.CR+CP.SR +SQ.CR +* +* +CP.SQ +SP.SQ +CQ +* + + DOUBLE PRECISION RMAT(3,3) + DATA RMAT(1,1),RMAT(1,2),RMAT(1,3), + : RMAT(2,1),RMAT(2,2),RMAT(2,3), + : RMAT(3,1),RMAT(3,2),RMAT(3,3) / + : -0.066988739415D0,-0.872755765852D0,-0.483538914632D0, + : +0.492728466075D0,-0.450346958020D0,+0.744584633283D0, + : -0.867600811151D0,-0.188374601723D0,+0.460199784784D0 / + + + +* Remove E-terms + CALL sla_SUBET(DR,DD,1950D0,R,D) + +* Spherical to Cartesian + CALL sla_DCS2C(R,D,V1) + +* Rotate to galactic + CALL sla_DMXV(RMAT,V1,V2) + +* Cartesian to spherical + CALL sla_DCC2S(V2,DL,DB) + +* Express angles in conventional ranges + DL=sla_DRANRM(DL) + DB=sla_DRANGE(DB) + + END diff --git a/src/slalib/el2ue.f b/src/slalib/el2ue.f new file mode 100644 index 0000000..49f8ed6 --- /dev/null +++ b/src/slalib/el2ue.f @@ -0,0 +1,301 @@ + SUBROUTINE sla_EL2UE (DATE, JFORM, EPOCH, ORBINC, ANODE, + : PERIH, AORQ, E, AORL, DM, + : U, JSTAT) +*+ +* - - - - - - +* E L 2 U E +* - - - - - - +* +* Transform conventional osculating orbital elements into "universal" form. +* +* Given: +* DATE d epoch (TT MJD) of osculation (Note 3) +* JFORM i choice of element set (1-3, Note 6) +* EPOCH d epoch (TT MJD) of the elements +* ORBINC d inclination (radians) +* ANODE d longitude of the ascending node (radians) +* PERIH d longitude or argument of perihelion (radians) +* AORQ d mean distance or perihelion distance (AU) +* E d eccentricity +* AORL d mean anomaly or longitude (radians, JFORM=1,2 only) +* DM d daily motion (radians, JFORM=1 only) +* +* Returned: +* U d(13) universal orbital elements (Note 1) +* +* (1) combined mass (M+m) +* (2) total energy of the orbit (alpha) +* (3) reference (osculating) epoch (t0) +* (4-6) position at reference epoch (r0) +* (7-9) velocity at reference epoch (v0) +* (10) heliocentric distance at reference epoch +* (11) r0.v0 +* (12) date (t) +* (13) universal eccentric anomaly (psi) of date, approx +* +* JSTAT i status: 0 = OK +* -1 = illegal JFORM +* -2 = illegal E +* -3 = illegal AORQ +* -4 = illegal DM +* -5 = numerical error +* +* Called: sla_UE2PV, sla_PV2UE +* +* Notes +* +* 1 The "universal" elements are those which define the orbit for the +* purposes of the method of universal variables (see reference). +* They consist of the combined mass of the two bodies, an epoch, +* and the position and velocity vectors (arbitrary reference frame) +* at that epoch. The parameter set used here includes also various +* quantities that can, in fact, be derived from the other +* information. This approach is taken to avoiding unnecessary +* computation and loss of accuracy. The supplementary quantities +* are (i) alpha, which is proportional to the total energy of the +* orbit, (ii) the heliocentric distance at epoch, (iii) the +* outwards component of the velocity at the given epoch, (iv) an +* estimate of psi, the "universal eccentric anomaly" at a given +* date and (v) that date. +* +* 2 The companion routine is sla_UE2PV. This takes the set of numbers +* that the present routine outputs and uses them to derive the +* object's position and velocity. A single prediction requires one +* call to the present routine followed by one call to sla_UE2PV; +* for convenience, the two calls are packaged as the routine +* sla_PLANEL. Multiple predictions may be made by again calling the +* present routine once, but then calling sla_UE2PV multiple times, +* which is faster than multiple calls to sla_PLANEL. +* +* 3 DATE is the epoch of osculation. It is in the TT timescale +* (formerly Ephemeris Time, ET) and is a Modified Julian Date +* (JD-2400000.5). +* +* 4 The supplied orbital elements are with respect to the J2000 +* ecliptic and equinox. The position and velocity parameters +* returned in the array U are with respect to the mean equator and +* equinox of epoch J2000, and are for the perihelion prior to the +* specified epoch. +* +* 5 The universal elements returned in the array U are in canonical +* units (solar masses, AU and canonical days). +* +* 6 Three different element-format options are available: +* +* Option JFORM=1, suitable for the major planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = longitude of perihelion, curly pi (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e (range 0 to <1) +* AORL = mean longitude L (radians) +* DM = daily motion (radians) +* +* Option JFORM=2, suitable for minor planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e (range 0 to <1) +* AORL = mean anomaly M (radians) +* +* Option JFORM=3, suitable for comets: +* +* EPOCH = epoch of perihelion (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = perihelion distance, q (AU) +* E = eccentricity, e (range 0 to 10) +* +* 7 Unused elements (DM for JFORM=2, AORL and DM for JFORM=3) are +* not accessed. +* +* 8 The algorithm was originally adapted from the EPHSLA program of +* D.H.P.Jones (private communication, 1996). The method is based +* on Stumpff's Universal Variables. +* +* Reference: Everhart & Pitkin, Am.J.Phys. 51, 712 (1983). +* +* P.T.Wallace Starlink 18 February 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE + INTEGER JFORM + DOUBLE PRECISION EPOCH,ORBINC,ANODE,PERIH,AORQ,E,AORL,DM,U(13) + INTEGER JSTAT + +* Gaussian gravitational constant (exact) + DOUBLE PRECISION GCON + PARAMETER (GCON=0.01720209895D0) + +* Sin and cos of J2000 mean obliquity (IAU 1976) + DOUBLE PRECISION SE,CE + PARAMETER (SE=0.3977771559319137D0, + : CE=0.9174820620691818D0) + + INTEGER J + + DOUBLE PRECISION PHT,ARGPH,Q,W,CM,ALPHA,PHS,SW,CW,SI,CI,SO,CO, + : X,Y,Z,PX,PY,PZ,VX,VY,VZ,DT,FC,FP,PSI, + : UL(13),PV(6) + + + +* Validate arguments. + IF (JFORM.LT.1.OR.JFORM.GT.3) THEN + JSTAT = -1 + GO TO 9999 + END IF + IF (E.LT.0D0.OR.E.GT.10D0.OR.(E.GE.1D0.AND.JFORM.NE.3)) THEN + JSTAT = -2 + GO TO 9999 + END IF + IF (AORQ.LE.0D0) THEN + JSTAT = -3 + GO TO 9999 + END IF + IF (JFORM.EQ.1.AND.DM.LE.0D0) THEN + JSTAT = -4 + GO TO 9999 + END IF + +* +* Transform elements into standard form: +* +* PHT = epoch of perihelion passage +* ARGPH = argument of perihelion (little omega) +* Q = perihelion distance (q) +* CM = combined mass, M+m (mu) + + IF (JFORM.EQ.1) THEN + PHT = EPOCH-(AORL-PERIH)/DM + ARGPH = PERIH-ANODE + Q = AORQ*(1D0-E) + W = DM/GCON + CM = W*W*AORQ*AORQ*AORQ + ELSE IF (JFORM.EQ.2) THEN + PHT = EPOCH-AORL*SQRT(AORQ*AORQ*AORQ)/GCON + ARGPH = PERIH + Q = AORQ*(1D0-E) + CM = 1D0 + ELSE IF (JFORM.EQ.3) THEN + PHT = EPOCH + ARGPH = PERIH + Q = AORQ + CM = 1D0 + END IF + +* The universal variable alpha. This is proportional to the total +* energy of the orbit: -ve for an ellipse, zero for a parabola, +* +ve for a hyperbola. + + ALPHA = CM*(E-1D0)/Q + +* Speed at perihelion. + + PHS = SQRT(ALPHA+2D0*CM/Q) + +* In a Cartesian coordinate system which has the x-axis pointing +* to perihelion and the z-axis normal to the orbit (such that the +* object orbits counter-clockwise as seen from +ve z), the +* perihelion position and velocity vectors are: +* +* position [Q,0,0] +* velocity [0,PHS,0] +* +* To express the results in J2000 equatorial coordinates we make a +* series of four rotations of the Cartesian axes: +* +* axis Euler angle +* +* 1 z argument of perihelion (little omega) +* 2 x inclination (i) +* 3 z longitude of the ascending node (big omega) +* 4 x J2000 obliquity (epsilon) +* +* In each case the rotation is clockwise as seen from the +ve end of +* the axis concerned. + +* Functions of the Euler angles. + SW = SIN(ARGPH) + CW = COS(ARGPH) + SI = SIN(ORBINC) + CI = COS(ORBINC) + SO = SIN(ANODE) + CO = COS(ANODE) + +* Position at perihelion (AU). + X = Q*CW + Y = Q*SW + Z = Y*SI + Y = Y*CI + PX = X*CO-Y*SO + Y = X*SO+Y*CO + PY = Y*CE-Z*SE + PZ = Y*SE+Z*CE + +* Velocity at perihelion (AU per canonical day). + X = -PHS*SW + Y = PHS*CW + Z = Y*SI + Y = Y*CI + VX = X*CO-Y*SO + Y = X*SO+Y*CO + VY = Y*CE-Z*SE + VZ = Y*SE+Z*CE + +* Time from perihelion to date (in Canonical Days: a canonical day +* is 58.1324409... days, defined as 1/GCON). + + DT = (DATE-PHT)*GCON + +* First Approximation to the Universal Eccentric Anomaly, PSI, +* based on the circle (FC) and parabola (FP) values. + + FC = DT/Q + W = (3D0*DT+SQRT(9D0*DT*DT+8D0*Q*Q*Q))**(1D0/3D0) + FP = W-2D0*Q/W + PSI = (1D0-E)*FC+E*FP + +* Assemble local copy of element set. + UL(1) = CM + UL(2) = ALPHA + UL(3) = PHT + UL(4) = PX + UL(5) = PY + UL(6) = PZ + UL(7) = VX + UL(8) = VY + UL(9) = VZ + UL(10) = Q + UL(11) = 0D0 + UL(12) = DATE + UL(13) = PSI + +* Predict position+velocity at epoch of osculation. + CALL sla_UE2PV(DATE,UL,PV,J) + IF (J.NE.0) GO TO 9010 + +* Convert back to universal elements. + CALL sla_PV2UE(PV,DATE,CM-1D0,U,J) + IF (J.NE.0) GO TO 9010 + +* OK exit. + JSTAT = 0 + GO TO 9999 + +* Quasi-impossible numerical errors. + 9010 CONTINUE + JSTAT = -5 + + 9999 CONTINUE + END diff --git a/src/slalib/epb.f b/src/slalib/epb.f new file mode 100644 index 0000000..4cc4d49 --- /dev/null +++ b/src/slalib/epb.f @@ -0,0 +1,30 @@ + DOUBLE PRECISION FUNCTION sla_EPB (DATE) +*+ +* - - - - +* E P B +* - - - - +* +* Conversion of Modified Julian Date to Besselian Epoch +* (double precision) +* +* Given: +* DATE dp Modified Julian Date (JD - 2400000.5) +* +* The result is the Besselian Epoch. +* +* Reference: +* Lieske,J.H., 1979. Astron.Astrophys.,73,282. +* +* P.T.Wallace Starlink February 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE + + + sla_EPB = 1900D0 + (DATE-15019.81352D0)/365.242198781D0 + + END diff --git a/src/slalib/epb2d.f b/src/slalib/epb2d.f new file mode 100644 index 0000000..cb1be4f --- /dev/null +++ b/src/slalib/epb2d.f @@ -0,0 +1,30 @@ + DOUBLE PRECISION FUNCTION sla_EPB2D (EPB) +*+ +* - - - - - - +* E P B 2 D +* - - - - - - +* +* Conversion of Besselian Epoch to Modified Julian Date +* (double precision) +* +* Given: +* EPB dp Besselian Epoch +* +* The result is the Modified Julian Date (JD - 2400000.5). +* +* Reference: +* Lieske,J.H., 1979. Astron.Astrophys.,73,282. +* +* P.T.Wallace Starlink February 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION EPB + + + sla_EPB2D = 15019.81352D0 + (EPB-1900D0)*365.242198781D0 + + END diff --git a/src/slalib/epco.f b/src/slalib/epco.f new file mode 100644 index 0000000..ef642ca --- /dev/null +++ b/src/slalib/epco.f @@ -0,0 +1,51 @@ + DOUBLE PRECISION FUNCTION sla_EPCO (K0, K, E) +*+ +* - - - - - +* E P C O +* - - - - - +* +* Convert an epoch into the appropriate form - 'B' or 'J' +* +* Given: +* K0 char form of result: 'B'=Besselian, 'J'=Julian +* K char form of given epoch: 'B' or 'J' +* E dp epoch +* +* Called: sla_EPB, sla_EPJ2D, sla_EPJ, sla_EPB2D +* +* Notes: +* +* 1) The result is always either equal to or very close to +* the given epoch E. The routine is required only in +* applications where punctilious treatment of heterogeneous +* mixtures of star positions is necessary. +* +* 2) K0 and K are not validated. They are interpreted as follows: +* +* o If K0 and K are the same the result is E. +* o If K0 is 'B' or 'b' and K isn't, the conversion is J to B. +* o In all other cases, the conversion is B to J. +* +* Note that K0 and K won't match if their cases differ. +* +* P.T.Wallace Starlink 5 September 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) K0,K + DOUBLE PRECISION E + DOUBLE PRECISION sla_EPB,sla_EPJ2D,sla_EPJ,sla_EPB2D + + + IF (K.EQ.K0) THEN + sla_EPCO=E + ELSE IF (K0.EQ.'B'.OR.K0.EQ.'b') THEN + sla_EPCO=sla_EPB(sla_EPJ2D(E)) + ELSE + sla_EPCO=sla_EPJ(sla_EPB2D(E)) + END IF + + END diff --git a/src/slalib/epj.f b/src/slalib/epj.f new file mode 100644 index 0000000..66d5eb9 --- /dev/null +++ b/src/slalib/epj.f @@ -0,0 +1,29 @@ + DOUBLE PRECISION FUNCTION sla_EPJ (DATE) +*+ +* - - - - +* E P J +* - - - - +* +* Conversion of Modified Julian Date to Julian Epoch (double precision) +* +* Given: +* DATE dp Modified Julian Date (JD - 2400000.5) +* +* The result is the Julian Epoch. +* +* Reference: +* Lieske,J.H., 1979. Astron.Astrophys.,73,282. +* +* P.T.Wallace Starlink February 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE + + + sla_EPJ = 2000D0 + (DATE-51544.5D0)/365.25D0 + + END diff --git a/src/slalib/epj2d.f b/src/slalib/epj2d.f new file mode 100644 index 0000000..c6a5c5f --- /dev/null +++ b/src/slalib/epj2d.f @@ -0,0 +1,29 @@ + DOUBLE PRECISION FUNCTION sla_EPJ2D (EPJ) +*+ +* - - - - - - +* E P J 2 D +* - - - - - - +* +* Conversion of Julian Epoch to Modified Julian Date (double precision) +* +* Given: +* EPJ dp Julian Epoch +* +* The result is the Modified Julian Date (JD - 2400000.5). +* +* Reference: +* Lieske,J.H., 1979. Astron.Astrophys.,73,282. +* +* P.T.Wallace Starlink February 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION EPJ + + + sla_EPJ2D = 51544.5D0 + (EPJ-2000D0)*365.25D0 + + END diff --git a/src/slalib/eqecl.f b/src/slalib/eqecl.f new file mode 100644 index 0000000..a3a73f6 --- /dev/null +++ b/src/slalib/eqecl.f @@ -0,0 +1,55 @@ + SUBROUTINE sla_EQECL (DR, DD, DATE, DL, DB) +*+ +* - - - - - - +* E Q E C L +* - - - - - - +* +* Transformation from J2000.0 equatorial coordinates to +* ecliptic coordinates (double precision) +* +* Given: +* DR,DD dp J2000.0 mean RA,Dec (radians) +* DATE dp TDB (loosely ET) as Modified Julian Date +* (JD-2400000.5) +* Returned: +* DL,DB dp ecliptic longitude and latitude +* (mean of date, IAU 1980 theory, radians) +* +* Called: +* sla_DCS2C, sla_PREC, sla_EPJ, sla_DMXV, sla_ECMAT, sla_DCC2S, +* sla_DRANRM, sla_DRANGE +* +* P.T.Wallace Starlink March 1986 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DR,DD,DATE,DL,DB + + DOUBLE PRECISION sla_EPJ,sla_DRANRM,sla_DRANGE + + DOUBLE PRECISION RMAT(3,3),V1(3),V2(3) + + + +* Spherical to Cartesian + CALL sla_DCS2C(DR,DD,V1) + +* Mean J2000 to mean of date + CALL sla_PREC(2000D0,sla_EPJ(DATE),RMAT) + CALL sla_DMXV(RMAT,V1,V2) + +* Equatorial to ecliptic + CALL sla_ECMAT(DATE,RMAT) + CALL sla_DMXV(RMAT,V2,V1) + +* Cartesian to spherical + CALL sla_DCC2S(V1,DL,DB) + +* Express in conventional ranges + DL=sla_DRANRM(DL) + DB=sla_DRANGE(DB) + + END diff --git a/src/slalib/eqeqx.f b/src/slalib/eqeqx.f new file mode 100644 index 0000000..f811039 --- /dev/null +++ b/src/slalib/eqeqx.f @@ -0,0 +1,57 @@ + DOUBLE PRECISION FUNCTION sla_EQEQX (DATE) +*+ +* - - - - - - +* E Q E Q X +* - - - - - - +* +* Equation of the equinoxes (IAU 1994, double precision) +* +* Given: +* DATE dp TDB (loosely ET) as Modified Julian Date +* (JD-2400000.5) +* +* The result is the equation of the equinoxes (double precision) +* in radians: +* +* Greenwich apparent ST = GMST + sla_EQEQX +* +* References: IAU Resolution C7, Recommendation 3 (1994) +* Capitaine, N. & Gontier, A.-M., Astron. Astrophys., +* 275, 645-650 (1993) +* +* Called: sla_NUTC +* +* Patrick Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE + +* Turns to arc seconds and arc seconds to radians + DOUBLE PRECISION T2AS,AS2R + PARAMETER (T2AS=1296000D0, + : AS2R=0.484813681109535994D-5) + + DOUBLE PRECISION T,OM,DPSI,DEPS,EPS0 + + + +* Interval between basic epoch J2000.0 and current epoch (JC) + T=(DATE-51544.5D0)/36525D0 + +* Longitude of the mean ascending node of the lunar orbit on the +* ecliptic, measured from the mean equinox of date + OM=AS2R*(450160.280D0+(-5D0*T2AS-482890.539D0 + : +(7.455D0+0.008D0*T)*T)*T) + +* Nutation + CALL sla_NUTC(DATE,DPSI,DEPS,EPS0) + +* Equation of the equinoxes + sla_EQEQX=DPSI*COS(EPS0)+AS2R*(0.00264D0*SIN(OM)+ + : 0.000063D0*SIN(OM+OM)) + + END diff --git a/src/slalib/eqgal.f b/src/slalib/eqgal.f new file mode 100644 index 0000000..bb59cc6 --- /dev/null +++ b/src/slalib/eqgal.f @@ -0,0 +1,79 @@ + SUBROUTINE sla_EQGAL (DR, DD, DL, DB) +*+ +* - - - - - - +* E Q G A L +* - - - - - - +* +* Transformation from J2000.0 equatorial coordinates to +* IAU 1958 galactic coordinates (double precision) +* +* Given: +* DR,DD dp J2000.0 RA,Dec +* +* Returned: +* DL,DB dp galactic longitude and latitude L2,B2 +* +* (all arguments are radians) +* +* Called: +* sla_DCS2C, sla_DMXV, sla_DCC2S, sla_DRANRM, sla_DRANGE +* +* Note: +* The equatorial coordinates are J2000.0. Use the routine +* sla_EG50 if conversion from B1950.0 'FK4' coordinates is +* required. +* +* Reference: +* Blaauw et al, Mon.Not.R.Astron.Soc.,121,123 (1960) +* +* P.T.Wallace Starlink 21 September 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DR,DD,DL,DB + + DOUBLE PRECISION sla_DRANRM,sla_DRANGE + + DOUBLE PRECISION V1(3),V2(3) + +* +* L2,B2 system of galactic coordinates +* +* P = 192.25 RA of galactic north pole (mean B1950.0) +* Q = 62.6 inclination of galactic to mean B1950.0 equator +* R = 33 longitude of ascending node +* +* P,Q,R are degrees +* +* Equatorial to galactic rotation matrix (J2000.0), obtained by +* applying the standard FK4 to FK5 transformation, for zero proper +* motion in FK5, to the columns of the B1950 equatorial to +* galactic rotation matrix: +* + DOUBLE PRECISION RMAT(3,3) + DATA RMAT(1,1),RMAT(1,2),RMAT(1,3), + : RMAT(2,1),RMAT(2,2),RMAT(2,3), + : RMAT(3,1),RMAT(3,2),RMAT(3,3)/ + : -0.054875539726D0,-0.873437108010D0,-0.483834985808D0, + : +0.494109453312D0,-0.444829589425D0,+0.746982251810D0, + : -0.867666135858D0,-0.198076386122D0,+0.455983795705D0/ + + + +* Spherical to Cartesian + CALL sla_DCS2C(DR,DD,V1) + +* Equatorial to galactic + CALL sla_DMXV(RMAT,V1,V2) + +* Cartesian to spherical + CALL sla_DCC2S(V2,DL,DB) + +* Express in conventional ranges + DL=sla_DRANRM(DL) + DB=sla_DRANGE(DB) + + END diff --git a/src/slalib/etrms.f b/src/slalib/etrms.f new file mode 100644 index 0000000..efac204 --- /dev/null +++ b/src/slalib/etrms.f @@ -0,0 +1,62 @@ + SUBROUTINE sla_ETRMS (EP, EV) +*+ +* - - - - - - +* E T R M S +* - - - - - - +* +* Compute the E-terms (elliptic component of annual aberration) +* vector (double precision) +* +* Given: +* EP dp Besselian epoch +* +* Returned: +* EV dp(3) E-terms as (dx,dy,dz) +* +* Note the use of the J2000 aberration constant (20.49552 arcsec). +* This is a reflection of the fact that the E-terms embodied in +* existing star catalogues were computed from a variety of +* aberration constants. Rather than adopting one of the old +* constants the latest value is used here. +* +* References: +* 1 Smith, C.A. et al., 1989. Astr.J. 97, 265. +* 2 Yallop, B.D. et al., 1989. Astr.J. 97, 274. +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION EP,EV(3) + +* Arcseconds to radians + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + + DOUBLE PRECISION T,E,E0,P,EK,CP + + + +* Julian centuries since B1950 + T=(EP-1950D0)*1.00002135903D-2 + +* Eccentricity + E=0.01673011D0-(0.00004193D0+0.000000126D0*T)*T + +* Mean obliquity + E0=(84404.836D0-(46.8495D0+(0.00319D0+0.00181D0*T)*T)*T)*AS2R + +* Mean longitude of perihelion + P=(1015489.951D0+(6190.67D0+(1.65D0+0.012D0*T)*T)*T)*AS2R + +* E-terms + EK=E*20.49552D0*AS2R + CP=COS(P) + EV(1)= EK*SIN(P) + EV(2)=-EK*CP*COS(E0) + EV(3)=-EK*CP*SIN(E0) + + END diff --git a/src/slalib/euler.f b/src/slalib/euler.f new file mode 100644 index 0000000..278da31 --- /dev/null +++ b/src/slalib/euler.f @@ -0,0 +1,68 @@ + SUBROUTINE sla_EULER (ORDER, PHI, THETA, PSI, RMAT) +*+ +* - - - - - - +* E U L E R +* - - - - - - +* +* Form a rotation matrix from the Euler angles - three successive +* rotations about specified Cartesian axes (single precision) +* +* Given: +* ORDER c*(*) specifies about which axes the rotations occur +* PHI r 1st rotation (radians) +* THETA r 2nd rotation ( " ) +* PSI r 3rd rotation ( " ) +* +* Returned: +* RMAT r(3,3) rotation matrix +* +* A rotation is positive when the reference frame rotates +* anticlockwise as seen looking towards the origin from the +* positive region of the specified axis. +* +* The characters of ORDER define which axes the three successive +* rotations are about. A typical value is 'ZXZ', indicating that +* RMAT is to become the direction cosine matrix corresponding to +* rotations of the reference frame through PHI radians about the +* old Z-axis, followed by THETA radians about the resulting X-axis, +* then PSI radians about the resulting Z-axis. +* +* The axis names can be any of the following, in any order or +* combination: X, Y, Z, uppercase or lowercase, 1, 2, 3. Normal +* axis labelling/numbering conventions apply; the xyz (=123) +* triad is right-handed. Thus, the 'ZXZ' example given above +* could be written 'zxz' or '313' (or even 'ZxZ' or '3xZ'). ORDER +* is terminated by length or by the first unrecognized character. +* +* Fewer than three rotations are acceptable, in which case the later +* angle arguments are ignored. If all rotations are zero, the +* identity matrix is produced. +* +* Called: sla_DEULER +* +* P.T.Wallace Starlink 23 May 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) ORDER + REAL PHI,THETA,PSI,RMAT(3,3) + + INTEGER J,I + DOUBLE PRECISION W(3,3) + + + +* Compute matrix in double precision + CALL sla_DEULER(ORDER,DBLE(PHI),DBLE(THETA),DBLE(PSI),W) + +* Copy the result + DO J=1,3 + DO I=1,3 + RMAT(I,J) = REAL(W(I,J)) + END DO + END DO + + END diff --git a/src/slalib/evp.f b/src/slalib/evp.f new file mode 100644 index 0000000..b295a12 --- /dev/null +++ b/src/slalib/evp.f @@ -0,0 +1,441 @@ + SUBROUTINE sla_EVP (DATE, DEQX, DVB, DPB, DVH, DPH) +*+ +* - - - - +* E V P +* - - - - +* +* Barycentric and heliocentric velocity and position of the Earth +* +* All arguments are double precision +* +* Given: +* +* DATE TDB (loosely ET) as a Modified Julian Date +* (JD-2400000.5) +* +* DEQX Julian Epoch (e.g. 2000.0D0) of mean equator and +* equinox of the vectors returned. If DEQX .LE. 0D0, +* all vectors are referred to the mean equator and +* equinox (FK5) of epoch DATE. +* +* Returned (all 3D Cartesian vectors): +* +* DVB,DPB barycentric velocity, position +* +* DVH,DPH heliocentric velocity, position +* +* (Units are AU/s for velocity and AU for position) +* +* Called: sla_EPJ, sla_PREC +* +* Accuracy: +* +* The maximum deviations from the JPL DE96 ephemeris are as +* follows: +* +* barycentric velocity 0.42 m/s +* barycentric position 6900 km +* +* heliocentric velocity 0.42 m/s +* heliocentric position 1600 km +* +* This routine is adapted from the BARVEL and BARCOR +* subroutines of P.Stumpff, which are described in +* Astron. Astrophys. Suppl. Ser. 41, 1-8 (1980). Most of the +* changes are merely cosmetic and do not affect the results at +* all. However, some adjustments have been made so as to give +* results that refer to the new (IAU 1976 'FK5') equinox +* and precession, although the differences these changes make +* relative to the results from Stumpff's original 'FK4' version +* are smaller than the inherent accuracy of the algorithm. One +* minor shortcoming in the original routines that has NOT been +* corrected is that better numerical accuracy could be achieved +* if the various polynomial evaluations were nested. Note also +* that one of Stumpff's precession constants differs by 0.001 arcsec +* from the value given in the Explanatory Supplement to the A.E. +* +* P.T.Wallace Starlink 21 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,DEQX,DVB(3),DPB(3),DVH(3),DPH(3) + + INTEGER IDEQ,I,J,K + + REAL CC2PI,CCSEC3,CCSGD,CCKM,CCMLD,CCFDI,CCIM,T,TSQ,A,PERTL, + : PERTLD,PERTR,PERTRD,COSA,SINA,ESQ,E,PARAM,TWOE,TWOG,G, + : PHI,F,SINF,COSF,PHID,PSID,PERTP,PERTPD,TL,SINLM,COSLM, + : SIGMA,B,PLON,POMG,PECC,FLATM,FLAT + + DOUBLE PRECISION DC2PI,DS2R,DCSLD,DC1MME,DT,DTSQ,DLOCAL,DML, + : DEPS,DPARAM,DPSI,D1PDRO,DRD,DRLD,DTL,DSINLS, + : DCOSLS,DXHD,DYHD,DZHD,DXBD,DYBD,DZBD,DCOSEP, + : DSINEP,DYAHD,DZAHD,DYABD,DZABD,DR, + : DXH,DYH,DZH,DXB,DYB,DZB,DYAH,DZAH,DYAB, + : DZAB,DEPJ,DEQCOR,B1950 + + REAL SN(4),CCSEL(3,17),CCAMPS(5,15),CCSEC(3,4),CCAMPM(4,3), + : CCPAMV(4),CCPAM(4),FORBEL(7),SORBEL(17),SINLP(4),COSLP(4) + EQUIVALENCE (SORBEL(1),E),(FORBEL(1),G) + + DOUBLE PRECISION DCFEL(3,8),DCEPS(3),DCARGS(2,15),DCARGM(2,3), + : DPREMA(3,3),W,VW(3) + + DOUBLE PRECISION sla_EPJ + + PARAMETER (DC2PI=6.2831853071796D0,CC2PI=6.283185) + PARAMETER (DS2R=0.7272205216643D-4) + PARAMETER (B1950=1949.9997904423D0) + +* +* Constants DCFEL(I,K) of fast changing elements +* I=1 I=2 I=3 + DATA DCFEL/ 1.7400353D+00, 6.2833195099091D+02, 5.2796D-06, + : 6.2565836D+00, 6.2830194572674D+02,-2.6180D-06, + : 4.7199666D+00, 8.3997091449254D+03,-1.9780D-05, + : 1.9636505D-01, 8.4334662911720D+03,-5.6044D-05, + : 4.1547339D+00, 5.2993466764997D+01, 5.8845D-06, + : 4.6524223D+00, 2.1354275911213D+01, 5.6797D-06, + : 4.2620486D+00, 7.5025342197656D+00, 5.5317D-06, + : 1.4740694D+00, 3.8377331909193D+00, 5.6093D-06/ + +* +* Constants DCEPS and CCSEL(I,K) of slowly changing elements +* I=1 I=2 I=3 + DATA DCEPS/ 4.093198D-01,-2.271110D-04,-2.860401D-08 / + DATA CCSEL/ 1.675104E-02,-4.179579E-05,-1.260516E-07, + : 2.220221E-01, 2.809917E-02, 1.852532E-05, + : 1.589963E+00, 3.418075E-02, 1.430200E-05, + : 2.994089E+00, 2.590824E-02, 4.155840E-06, + : 8.155457E-01, 2.486352E-02, 6.836840E-06, + : 1.735614E+00, 1.763719E-02, 6.370440E-06, + : 1.968564E+00, 1.524020E-02,-2.517152E-06, + : 1.282417E+00, 8.703393E-03, 2.289292E-05, + : 2.280820E+00, 1.918010E-02, 4.484520E-06, + : 4.833473E-02, 1.641773E-04,-4.654200E-07, + : 5.589232E-02,-3.455092E-04,-7.388560E-07, + : 4.634443E-02,-2.658234E-05, 7.757000E-08, + : 8.997041E-03, 6.329728E-06,-1.939256E-09, + : 2.284178E-02,-9.941590E-05, 6.787400E-08, + : 4.350267E-02,-6.839749E-05,-2.714956E-07, + : 1.348204E-02, 1.091504E-05, 6.903760E-07, + : 3.106570E-02,-1.665665E-04,-1.590188E-07/ + +* +* Constants of the arguments of the short-period perturbations +* by the planets: DCARGS(I,K) +* I=1 I=2 + DATA DCARGS/ 5.0974222D+00,-7.8604195454652D+02, + : 3.9584962D+00,-5.7533848094674D+02, + : 1.6338070D+00,-1.1506769618935D+03, + : 2.5487111D+00,-3.9302097727326D+02, + : 4.9255514D+00,-5.8849265665348D+02, + : 1.3363463D+00,-5.5076098609303D+02, + : 1.6072053D+00,-5.2237501616674D+02, + : 1.3629480D+00,-1.1790629318198D+03, + : 5.5657014D+00,-1.0977134971135D+03, + : 5.0708205D+00,-1.5774000881978D+02, + : 3.9318944D+00, 5.2963464780000D+01, + : 4.8989497D+00, 3.9809289073258D+01, + : 1.3097446D+00, 7.7540959633708D+01, + : 3.5147141D+00, 7.9618578146517D+01, + : 3.5413158D+00,-5.4868336758022D+02/ + +* +* Amplitudes CCAMPS(N,K) of the short-period perturbations +* N=1 N=2 N=3 N=4 N=5 + DATA CCAMPS/ + : -2.279594E-5, 1.407414E-5, 8.273188E-6, 1.340565E-5,-2.490817E-7, + : -3.494537E-5, 2.860401E-7, 1.289448E-7, 1.627237E-5,-1.823138E-7, + : 6.593466E-7, 1.322572E-5, 9.258695E-6,-4.674248E-7,-3.646275E-7, + : 1.140767E-5,-2.049792E-5,-4.747930E-6,-2.638763E-6,-1.245408E-7, + : 9.516893E-6,-2.748894E-6,-1.319381E-6,-4.549908E-6,-1.864821E-7, + : 7.310990E-6,-1.924710E-6,-8.772849E-7,-3.334143E-6,-1.745256E-7, + : -2.603449E-6, 7.359472E-6, 3.168357E-6, 1.119056E-6,-1.655307E-7, + : -3.228859E-6, 1.308997E-7, 1.013137E-7, 2.403899E-6,-3.736225E-7, + : 3.442177E-7, 2.671323E-6, 1.832858E-6,-2.394688E-7,-3.478444E-7, + : 8.702406E-6,-8.421214E-6,-1.372341E-6,-1.455234E-6,-4.998479E-8, + : -1.488378E-6,-1.251789E-5, 5.226868E-7,-2.049301E-7, 0.0E0, + : -8.043059E-6,-2.991300E-6, 1.473654E-7,-3.154542E-7, 0.0E0, + : 3.699128E-6,-3.316126E-6, 2.901257E-7, 3.407826E-7, 0.0E0, + : 2.550120E-6,-1.241123E-6, 9.901116E-8, 2.210482E-7, 0.0E0, + : -6.351059E-7, 2.341650E-6, 1.061492E-6, 2.878231E-7, 0.0E0/ + +* +* Constants of the secular perturbations in longitude +* CCSEC3 and CCSEC(N,K) +* N=1 N=2 N=3 + DATA CCSEC3/-7.757020E-08/, + : CCSEC/ 1.289600E-06, 5.550147E-01, 2.076942E+00, + : 3.102810E-05, 4.035027E+00, 3.525565E-01, + : 9.124190E-06, 9.990265E-01, 2.622706E+00, + : 9.793240E-07, 5.508259E+00, 1.559103E+01/ + +* Sidereal rate DCSLD in longitude, rate CCSGD in mean anomaly + DATA DCSLD/1.990987D-07/, + : CCSGD/1.990969E-07/ + +* Some constants used in the calculation of the lunar contribution + DATA CCKM/3.122140E-05/, + : CCMLD/2.661699E-06/, + : CCFDI/2.399485E-07/ + +* +* Constants DCARGM(I,K) of the arguments of the perturbations +* of the motion of the Moon +* I=1 I=2 + DATA DCARGM/ 5.1679830D+00, 8.3286911095275D+03, + : 5.4913150D+00,-7.2140632838100D+03, + : 5.9598530D+00, 1.5542754389685D+04/ + +* +* Amplitudes CCAMPM(N,K) of the perturbations of the Moon +* N=1 N=2 N=3 N=4 + DATA CCAMPM/ + : 1.097594E-01, 2.896773E-07, 5.450474E-02, 1.438491E-07, + : -2.223581E-02, 5.083103E-08, 1.002548E-02,-2.291823E-08, + : 1.148966E-02, 5.658888E-08, 8.249439E-03, 4.063015E-08/ + +* +* CCPAMV(K)=A*M*DL/DT (planets), DC1MME=1-MASS(Earth+Moon) + DATA CCPAMV/8.326827E-11,1.843484E-11,1.988712E-12,1.881276E-12/ + DATA DC1MME/0.99999696D0/ + +* CCPAM(K)=A*M(planets), CCIM=INCLINATION(Moon) + DATA CCPAM/4.960906E-3,2.727436E-3,8.392311E-4,1.556861E-3/ + DATA CCIM/8.978749E-2/ + + + + +* +* EXECUTION +* --------- + +* Control parameter IDEQ, and time arguments + IDEQ = 0 + IF (DEQX.GT.0D0) IDEQ=1 + DT = (DATE-15019.5D0)/36525D0 + T = REAL(DT) + DTSQ = DT*DT + TSQ = REAL(DTSQ) + +* Values of all elements for the instant DATE + DO K=1,8 + DLOCAL = MOD(DCFEL(1,K)+DT*DCFEL(2,K)+DTSQ*DCFEL(3,K), DC2PI) + IF (K.EQ.1) THEN + DML = DLOCAL + ELSE + FORBEL(K-1) = REAL(DLOCAL) + END IF + END DO + DEPS = MOD(DCEPS(1)+DT*DCEPS(2)+DTSQ*DCEPS(3), DC2PI) + DO K=1,17 + SORBEL(K) = MOD(CCSEL(1,K)+T*CCSEL(2,K)+TSQ*CCSEL(3,K), + : CC2PI) + END DO + +* Secular perturbations in longitude + DO K=1,4 + A = MOD(CCSEC(2,K)+T*CCSEC(3,K), CC2PI) + SN(K) = SIN(A) + END DO + +* Periodic perturbations of the EMB (Earth-Moon barycentre) + PERTL = CCSEC(1,1) *SN(1) +CCSEC(1,2)*SN(2)+ + : (CCSEC(1,3)+T*CCSEC3)*SN(3) +CCSEC(1,4)*SN(4) + PERTLD = 0.0 + PERTR = 0.0 + PERTRD = 0.0 + DO K=1,15 + A = SNGL(MOD(DCARGS(1,K)+DT*DCARGS(2,K), DC2PI)) + COSA = COS(A) + SINA = SIN(A) + PERTL = PERTL + CCAMPS(1,K)*COSA+CCAMPS(2,K)*SINA + PERTR = PERTR + CCAMPS(3,K)*COSA+CCAMPS(4,K)*SINA + IF (K.LT.11) THEN + PERTLD = PERTLD+ + : (CCAMPS(2,K)*COSA-CCAMPS(1,K)*SINA)*CCAMPS(5,K) + PERTRD = PERTRD+ + : (CCAMPS(4,K)*COSA-CCAMPS(3,K)*SINA)*CCAMPS(5,K) + END IF + END DO + +* Elliptic part of the motion of the EMB + ESQ = E*E + DPARAM = 1D0-DBLE(ESQ) + PARAM = REAL(DPARAM) + TWOE = E+E + TWOG = G+G + PHI = TWOE*((1.0-ESQ*0.125)*SIN(G)+E*0.625*SIN(TWOG) + : +ESQ*0.54166667*SIN(G+TWOG) ) + F = G+PHI + SINF = SIN(F) + COSF = COS(F) + DPSI = DPARAM/(1D0+DBLE(E*COSF)) + PHID = TWOE*CCSGD*((1.0+ESQ*1.5)*COSF+E*(1.25-SINF*SINF*0.5)) + PSID = CCSGD*E*SINF/SQRT(PARAM) + +* Perturbed heliocentric motion of the EMB + D1PDRO = 1D0+DBLE(PERTR) + DRD = D1PDRO*(DBLE(PSID)+DPSI*DBLE(PERTRD)) + DRLD = D1PDRO*DPSI*(DCSLD+DBLE(PHID)+DBLE(PERTLD)) + DTL = MOD(DML+DBLE(PHI)+DBLE(PERTL), DC2PI) + DSINLS = SIN(DTL) + DCOSLS = COS(DTL) + DXHD = DRD*DCOSLS-DRLD*DSINLS + DYHD = DRD*DSINLS+DRLD*DCOSLS + +* Influence of eccentricity, evection and variation on the +* geocentric motion of the Moon + PERTL = 0.0 + PERTLD = 0.0 + PERTP = 0.0 + PERTPD = 0.0 + DO K=1,3 + A = SNGL(MOD(DCARGM(1,K)+DT*DCARGM(2,K), DC2PI)) + SINA = SIN(A) + COSA = COS(A) + PERTL = PERTL +CCAMPM(1,K)*SINA + PERTLD = PERTLD+CCAMPM(2,K)*COSA + PERTP = PERTP +CCAMPM(3,K)*COSA + PERTPD = PERTPD-CCAMPM(4,K)*SINA + END DO + +* Heliocentric motion of the Earth + TL = FORBEL(2)+PERTL + SINLM = SIN(TL) + COSLM = COS(TL) + SIGMA = CCKM/(1.0+PERTP) + A = SIGMA*(CCMLD+PERTLD) + B = SIGMA*PERTPD + DXHD = DXHD+DBLE(A*SINLM)+DBLE(B*COSLM) + DYHD = DYHD-DBLE(A*COSLM)+DBLE(B*SINLM) + DZHD = -DBLE(SIGMA*CCFDI*COS(FORBEL(3))) + +* Barycentric motion of the Earth + DXBD = DXHD*DC1MME + DYBD = DYHD*DC1MME + DZBD = DZHD*DC1MME + DO K=1,4 + PLON = FORBEL(K+3) + POMG = SORBEL(K+1) + PECC = SORBEL(K+9) + TL = MOD(PLON+2.0*PECC*SIN(PLON-POMG), CC2PI) + SINLP(K) = SIN(TL) + COSLP(K) = COS(TL) + DXBD = DXBD+DBLE(CCPAMV(K)*(SINLP(K)+PECC*SIN(POMG))) + DYBD = DYBD-DBLE(CCPAMV(K)*(COSLP(K)+PECC*COS(POMG))) + DZBD = DZBD-DBLE(CCPAMV(K)*SORBEL(K+13)*COS(PLON-SORBEL(K+5))) + END DO + +* Transition to mean equator of date + DCOSEP = COS(DEPS) + DSINEP = SIN(DEPS) + DYAHD = DCOSEP*DYHD-DSINEP*DZHD + DZAHD = DSINEP*DYHD+DCOSEP*DZHD + DYABD = DCOSEP*DYBD-DSINEP*DZBD + DZABD = DSINEP*DYBD+DCOSEP*DZBD + +* Heliocentric coordinates of the Earth + DR = DPSI*D1PDRO + FLATM = CCIM*SIN(FORBEL(3)) + A = SIGMA*COS(FLATM) + DXH = DR*DCOSLS-DBLE(A*COSLM) + DYH = DR*DSINLS-DBLE(A*SINLM) + DZH = -DBLE(SIGMA*SIN(FLATM)) + +* Barycentric coordinates of the Earth + DXB = DXH*DC1MME + DYB = DYH*DC1MME + DZB = DZH*DC1MME + DO K=1,4 + FLAT = SORBEL(K+13)*SIN(FORBEL(K+3)-SORBEL(K+5)) + A = CCPAM(K)*(1.0-SORBEL(K+9)*COS(FORBEL(K+3)-SORBEL(K+1))) + B = A*COS(FLAT) + DXB = DXB-DBLE(B*COSLP(K)) + DYB = DYB-DBLE(B*SINLP(K)) + DZB = DZB-DBLE(A*SIN(FLAT)) + END DO + +* Transition to mean equator of date + DYAH = DCOSEP*DYH-DSINEP*DZH + DZAH = DSINEP*DYH+DCOSEP*DZH + DYAB = DCOSEP*DYB-DSINEP*DZB + DZAB = DSINEP*DYB+DCOSEP*DZB + +* Copy result components into vectors, correcting for FK4 equinox + DEPJ=sla_EPJ(DATE) + DEQCOR = DS2R*(0.035D0+0.00085D0*(DEPJ-B1950)) + DVH(1) = DXHD-DEQCOR*DYAHD + DVH(2) = DYAHD+DEQCOR*DXHD + DVH(3) = DZAHD + DVB(1) = DXBD-DEQCOR*DYABD + DVB(2) = DYABD+DEQCOR*DXBD + DVB(3) = DZABD + DPH(1) = DXH-DEQCOR*DYAH + DPH(2) = DYAH+DEQCOR*DXH + DPH(3) = DZAH + DPB(1) = DXB-DEQCOR*DYAB + DPB(2) = DYAB+DEQCOR*DXB + DPB(3) = DZAB + +* Was precession to another equinox requested? + IF (IDEQ.NE.0) THEN + +* Yes: compute precession matrix from MJD DATE to Julian epoch DEQX + CALL sla_PREC(DEPJ,DEQX,DPREMA) + +* Rotate DVH + DO J=1,3 + W=0D0 + DO I=1,3 + W=W+DPREMA(J,I)*DVH(I) + END DO + VW(J)=W + END DO + DO J=1,3 + DVH(J)=VW(J) + END DO + +* Rotate DVB + DO J=1,3 + W=0D0 + DO I=1,3 + W=W+DPREMA(J,I)*DVB(I) + END DO + VW(J)=W + END DO + DO J=1,3 + DVB(J)=VW(J) + END DO + +* Rotate DPH + DO J=1,3 + W=0D0 + DO I=1,3 + W=W+DPREMA(J,I)*DPH(I) + END DO + VW(J)=W + END DO + DO J=1,3 + DPH(J)=VW(J) + END DO + +* Rotate DPB + DO J=1,3 + W=0D0 + DO I=1,3 + W=W+DPREMA(J,I)*DPB(I) + END DO + VW(J)=W + END DO + DO J=1,3 + DPB(J)=VW(J) + END DO + END IF + + END diff --git a/src/slalib/fitxy.f b/src/slalib/fitxy.f new file mode 100644 index 0000000..97f1e00 --- /dev/null +++ b/src/slalib/fitxy.f @@ -0,0 +1,300 @@ + SUBROUTINE sla_FITXY (ITYPE,NP,XYE,XYM,COEFFS,J) +*+ +* - - - - - - +* F I T X Y +* - - - - - - +* +* Fit a linear model to relate two sets of [X,Y] coordinates. +* +* Given: +* ITYPE i type of model: 4 or 6 (note 1) +* NP i number of samples (note 2) +* XYE d(2,np) expected [X,Y] for each sample +* XYM d(2,np) measured [X,Y] for each sample +* +* Returned: +* COEFFS d(6) coefficients of model (note 3) +* J i status: 0 = OK +* -1 = illegal ITYPE +* -2 = insufficient data +* -3 = singular solution +* +* Notes: +* +* 1) ITYPE, which must be either 4 or 6, selects the type of model +* fitted. Both allowed ITYPE values produce a model COEFFS which +* consists of six coefficients, namely the zero points and, for +* each of XE and YE, the coefficient of XM and YM. For ITYPE=6, +* all six coefficients are independent, modelling squash and shear +* as well as origin, scale, and orientation. However, ITYPE=4 +* selects the "solid body rotation" option; the model COEFFS +* still consists of the same six coefficients, but now two of +* them are used twice (appropriately signed). Origin, scale +* and orientation are still modelled, but not squash or shear - +* the units of X and Y have to be the same. +* +* 2) For NC=4, NP must be at least 2. For NC=6, NP must be at +* least 3. +* +* 3) The model is returned in the array COEFFS. Naming the +* elements of COEFFS as follows: +* +* COEFFS(1) = A +* COEFFS(2) = B +* COEFFS(3) = C +* COEFFS(4) = D +* COEFFS(5) = E +* COEFFS(6) = F +* +* the model is: +* +* XE = A + B*XM + C*YM +* YE = D + E*XM + F*YM +* +* For the "solid body rotation" option (ITYPE=4), the +* magnitudes of B and F, and of C and E, are equal. The +* signs of these coefficients depend on whether there is a +* sign reversal between XE,YE and XM,YM; fits are performed +* with and without a sign reversal and the best one chosen. +* +* 4) Error status values J=-1 and -2 leave COEFFS unchanged; +* if J=-3 COEFFS may have been changed. +* +* See also sla_PXY, sla_INVF, sla_XY2XY, sla_DCMPF +* +* Called: sla_DMAT, sla_DMXV +* +* P.T.Wallace Starlink 11 February 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER ITYPE,NP + DOUBLE PRECISION XYE(2,NP),XYM(2,NP),COEFFS(6) + INTEGER J + + INTEGER I,JSTAT,IW(4),NSOL + DOUBLE PRECISION P,SXE,SXEXM,SXEYM,SYE,SYEYM,SYEXM,SXM, + : SYM,SXMXM,SXMYM,SYMYM,XE,YE, + : XM,YM,V(4),DM3(3,3),DM4(4,4),DET, + : SGN,SXXYY,SXYYX,SX2Y2,A,B,C,D, + : SDR2,XR,YR,AOLD,BOLD,COLD,DOLD,SOLD + + + +* Preset the status + J=0 + +* Float the number of samples + P=DBLE(NP) + +* Check ITYPE + IF (ITYPE.EQ.6) THEN + +* +* Six-coefficient linear model +* ---------------------------- + +* Check enough samples + IF (NP.GE.3) THEN + +* Form summations + SXE=0D0 + SXEXM=0D0 + SXEYM=0D0 + SYE=0D0 + SYEYM=0D0 + SYEXM=0D0 + SXM=0D0 + SYM=0D0 + SXMXM=0D0 + SXMYM=0D0 + SYMYM=0D0 + DO I=1,NP + XE=XYE(1,I) + YE=XYE(2,I) + XM=XYM(1,I) + YM=XYM(2,I) + SXE=SXE+XE + SXEXM=SXEXM+XE*XM + SXEYM=SXEYM+XE*YM + SYE=SYE+YE + SYEYM=SYEYM+YE*YM + SYEXM=SYEXM+YE*XM + SXM=SXM+XM + SYM=SYM+YM + SXMXM=SXMXM+XM*XM + SXMYM=SXMYM+XM*YM + SYMYM=SYMYM+YM*YM + END DO + +* Solve for A,B,C in XE = A + B*XM + C*YM + V(1)=SXE + V(2)=SXEXM + V(3)=SXEYM + DM3(1,1)=P + DM3(1,2)=SXM + DM3(1,3)=SYM + DM3(2,1)=SXM + DM3(2,2)=SXMXM + DM3(2,3)=SXMYM + DM3(3,1)=SYM + DM3(3,2)=SXMYM + DM3(3,3)=SYMYM + CALL sla_DMAT(3,DM3,V,DET,JSTAT,IW) + IF (JSTAT.EQ.0) THEN + DO I=1,3 + COEFFS(I)=V(I) + END DO + +* Solve for D,E,F in YE = D + E*XM + F*YM + V(1)=SYE + V(2)=SYEXM + V(3)=SYEYM + CALL sla_DMXV(DM3,V,COEFFS(4)) + + ELSE + +* No 6-coefficient solution possible + J=-3 + + END IF + + ELSE + +* Insufficient data for 6-coefficient fit + J=-2 + + END IF + + ELSE IF (ITYPE.EQ.4) THEN + +* +* Four-coefficient solid body rotation model +* ------------------------------------------ + +* Check enough samples + IF (NP.GE.2) THEN + +* Try two solutions, first without then with flip in X + DO NSOL=1,2 + IF (NSOL.EQ.1) THEN + SGN=1D0 + ELSE + SGN=-1D0 + END IF + +* Form summations + SXE=0D0 + SXXYY=0D0 + SXYYX=0D0 + SYE=0D0 + SXM=0D0 + SYM=0D0 + SX2Y2=0D0 + DO I=1,NP + XE=XYE(1,I)*SGN + YE=XYE(2,I) + XM=XYM(1,I) + YM=XYM(2,I) + SXE=SXE+XE + SXXYY=SXXYY+XE*XM+YE*YM + SXYYX=SXYYX+XE*YM-YE*XM + SYE=SYE+YE + SXM=SXM+XM + SYM=SYM+YM + SX2Y2=SX2Y2+XM*XM+YM*YM + END DO + +* +* Solve for A,B,C,D in: +/- XE = A + B*XM - C*YM +* + YE = D + C*XM + B*YM + V(1)=SXE + V(2)=SXXYY + V(3)=SXYYX + V(4)=SYE + DM4(1,1)=P + DM4(1,2)=SXM + DM4(1,3)=-SYM + DM4(1,4)=0D0 + DM4(2,1)=SXM + DM4(2,2)=SX2Y2 + DM4(2,3)=0D0 + DM4(2,4)=SYM + DM4(3,1)=SYM + DM4(3,2)=0D0 + DM4(3,3)=-SX2Y2 + DM4(3,4)=-SXM + DM4(4,1)=0D0 + DM4(4,2)=SYM + DM4(4,3)=SXM + DM4(4,4)=P + CALL sla_DMAT(4,DM4,V,DET,JSTAT,IW) + IF (JSTAT.EQ.0) THEN + A=V(1) + B=V(2) + C=V(3) + D=V(4) + +* Determine sum of radial errors squared + SDR2=0D0 + DO I=1,NP + XM=XYM(1,I) + YM=XYM(2,I) + XR=A+B*XM-C*YM-XYE(1,I)*SGN + YR=D+C*XM+B*YM-XYE(2,I) + SDR2=SDR2+XR*XR+YR*YR + END DO + + ELSE + +* Singular: set flag + SDR2=-1D0 + + END IF + +* If first pass and non-singular, save variables + IF (NSOL.EQ.1.AND.JSTAT.EQ.0) THEN + AOLD=A + BOLD=B + COLD=C + DOLD=D + SOLD=SDR2 + END IF + + END DO + +* Pick the best of the two solutions + IF (SOLD.GE.0D0.AND.(SOLD.LE.SDR2.OR.NP.EQ.2)) THEN + COEFFS(1)=AOLD + COEFFS(2)=BOLD + COEFFS(3)=-COLD + COEFFS(4)=DOLD + COEFFS(5)=COLD + COEFFS(6)=BOLD + ELSE IF (JSTAT.EQ.0) THEN + COEFFS(1)=-A + COEFFS(2)=-B + COEFFS(3)=C + COEFFS(4)=D + COEFFS(5)=C + COEFFS(6)=B + ELSE + +* No 4-coefficient fit possible + J=-3 + END IF + ELSE + +* Insufficient data for 4-coefficient fit + J=-2 + END IF + ELSE + +* Illegal ITYPE - not 4 or 6 + J=-1 + END IF + + END diff --git a/src/slalib/fk425.f b/src/slalib/fk425.f new file mode 100644 index 0000000..9b8465f --- /dev/null +++ b/src/slalib/fk425.f @@ -0,0 +1,249 @@ + SUBROUTINE sla_FK425 (R1950,D1950,DR1950,DD1950,P1950,V1950, + : R2000,D2000,DR2000,DD2000,P2000,V2000) +*+ +* - - - - - - +* F K 4 2 5 +* - - - - - - +* +* Convert B1950.0 FK4 star data to J2000.0 FK5 (double precision) +* +* This routine converts stars from the old, Bessel-Newcomb, FK4 +* system to the new, IAU 1976, FK5, Fricke system. The precepts +* of Smith et al (Ref 1) are followed, using the implementation +* by Yallop et al (Ref 2) of a matrix method due to Standish. +* Kinoshita's development of Andoyer's post-Newcomb precession is +* used. The numerical constants from Seidelmann et al (Ref 3) are +* used canonically. +* +* Given: (all B1950.0,FK4) +* R1950,D1950 dp B1950.0 RA,Dec (rad) +* DR1950,DD1950 dp B1950.0 proper motions (rad/trop.yr) +* P1950 dp parallax (arcsec) +* V1950 dp radial velocity (km/s, +ve = moving away) +* +* Returned: (all J2000.0,FK5) +* R2000,D2000 dp J2000.0 RA,Dec (rad) +* DR2000,DD2000 dp J2000.0 proper motions (rad/Jul.yr) +* P2000 dp parallax (arcsec) +* V2000 dp radial velocity (km/s, +ve = moving away) +* +* Notes: +* +* 1) The proper motions in RA are dRA/dt rather than +* cos(Dec)*dRA/dt, and are per year rather than per century. +* +* 2) Conversion from Besselian epoch 1950.0 to Julian epoch +* 2000.0 only is provided for. Conversions involving other +* epochs will require use of the appropriate precession, +* proper motion, and E-terms routines before and/or +* after FK425 is called. +* +* 3) In the FK4 catalogue the proper motions of stars within +* 10 degrees of the poles do not embody the differential +* E-term effect and should, strictly speaking, be handled +* in a different manner from stars outside these regions. +* However, given the general lack of homogeneity of the star +* data available for routine astrometry, the difficulties of +* handling positions that may have been determined from +* astrometric fields spanning the polar and non-polar regions, +* the likelihood that the differential E-terms effect was not +* taken into account when allowing for proper motion in past +* astrometry, and the undesirability of a discontinuity in +* the algorithm, the decision has been made in this routine to +* include the effect of differential E-terms on the proper +* motions for all stars, whether polar or not. At epoch 2000, +* and measuring on the sky rather than in terms of dRA, the +* errors resulting from this simplification are less than +* 1 milliarcsecond in position and 1 milliarcsecond per +* century in proper motion. +* +* References: +* +* 1 Smith, C.A. et al, 1989. "The transformation of astrometric +* catalog systems to the equinox J2000.0". Astron.J. 97, 265. +* +* 2 Yallop, B.D. et al, 1989. "Transformation of mean star places +* from FK4 B1950.0 to FK5 J2000.0 using matrices in 6-space". +* Astron.J. 97, 274. +* +* 3 Seidelmann, P.K. (ed), 1992. "Explanatory Supplement to +* the Astronomical Almanac", ISBN 0-935702-68-7. +* +* P.T.Wallace Starlink 19 December 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION R1950,D1950,DR1950,DD1950,P1950,V1950, + : R2000,D2000,DR2000,DD2000,P2000,V2000 + + +* Miscellaneous + DOUBLE PRECISION R,D,UR,UD,PX,RV,SR,CR,SD,CD,W,WD + DOUBLE PRECISION X,Y,Z,XD,YD,ZD + DOUBLE PRECISION RXYSQ,RXYZSQ,RXY,RXYZ,SPXY,SPXYZ + INTEGER I,J + +* Star position and velocity vectors + DOUBLE PRECISION R0(3),RD0(3) + +* Combined position and velocity vectors + DOUBLE PRECISION V1(6),V2(6) + +* 2Pi + DOUBLE PRECISION D2PI + PARAMETER (D2PI=6.283185307179586476925287D0) + +* Radians per year to arcsec per century + DOUBLE PRECISION PMF + PARAMETER (PMF=100D0*60D0*60D0*360D0/D2PI) + +* Small number to avoid arithmetic problems + DOUBLE PRECISION TINY + PARAMETER (TINY=1D-30) + + +* +* CANONICAL CONSTANTS (see references) +* + +* Km per sec to AU per tropical century +* = 86400 * 36524.2198782 / 149597870 + DOUBLE PRECISION VF + PARAMETER (VF=21.095D0) + +* Constant vector and matrix (by columns) + DOUBLE PRECISION A(3),AD(3),EM(6,6) + DATA A,AD/ -1.62557D-6, -0.31919D-6, -0.13843D-6, + : +1.245D-3, -1.580D-3, -0.659D-3/ + + DATA (EM(I,1),I=1,6) / +0.9999256782D0, + : +0.0111820610D0, + : +0.0048579479D0, + : -0.000551D0, + : +0.238514D0, + : -0.435623D0 / + + DATA (EM(I,2),I=1,6) / -0.0111820611D0, + : +0.9999374784D0, + : -0.0000271474D0, + : -0.238565D0, + : -0.002667D0, + : +0.012254D0 / + + DATA (EM(I,3),I=1,6) / -0.0048579477D0, + : -0.0000271765D0, + : +0.9999881997D0, + : +0.435739D0, + : -0.008541D0, + : +0.002117D0 / + + DATA (EM(I,4),I=1,6) / +0.00000242395018D0, + : +0.00000002710663D0, + : +0.00000001177656D0, + : +0.99994704D0, + : +0.01118251D0, + : +0.00485767D0 / + + DATA (EM(I,5),I=1,6) / -0.00000002710663D0, + : +0.00000242397878D0, + : -0.00000000006582D0, + : -0.01118251D0, + : +0.99995883D0, + : -0.00002714D0 / + + DATA (EM(I,6),I=1,6) / -0.00000001177656D0, + : -0.00000000006587D0, + : +0.00000242410173D0, + : -0.00485767D0, + : -0.00002718D0, + : +1.00000956D0 / + + + +* Pick up B1950 data (units radians and arcsec/TC) + R=R1950 + D=D1950 + UR=DR1950*PMF + UD=DD1950*PMF + PX=P1950 + RV=V1950 + +* Spherical to Cartesian + SR=SIN(R) + CR=COS(R) + SD=SIN(D) + CD=COS(D) + + R0(1)=CR*CD + R0(2)=SR*CD + R0(3)= SD + + W=VF*RV*PX + + RD0(1)=-SR*CD*UR-CR*SD*UD+W*R0(1) + RD0(2)= CR*CD*UR-SR*SD*UD+W*R0(2) + RD0(3)= CD*UD+W*R0(3) + +* Allow for e-terms and express as position+velocity 6-vector + W=R0(1)*A(1)+R0(2)*A(2)+R0(3)*A(3) + WD=R0(1)*AD(1)+R0(2)*AD(2)+R0(3)*AD(3) + DO I=1,3 + V1(I)=R0(I)-A(I)+W*R0(I) + V1(I+3)=RD0(I)-AD(I)+WD*R0(I) + END DO + +* Convert position+velocity vector to Fricke system + DO I=1,6 + W=0D0 + DO J=1,6 + W=W+EM(I,J)*V1(J) + END DO + V2(I)=W + END DO + +* Revert to spherical coordinates + X=V2(1) + Y=V2(2) + Z=V2(3) + XD=V2(4) + YD=V2(5) + ZD=V2(6) + + RXYSQ=X*X+Y*Y + RXYZSQ=RXYSQ+Z*Z + RXY=SQRT(RXYSQ) + RXYZ=SQRT(RXYZSQ) + + SPXY=X*XD+Y*YD + SPXYZ=SPXY+Z*ZD + + IF (X.EQ.0D0.AND.Y.EQ.0D0) THEN + R=0D0 + ELSE + R=ATAN2(Y,X) + IF (R.LT.0.0D0) R=R+D2PI + END IF + D=ATAN2(Z,RXY) + + IF (RXY.GT.TINY) THEN + UR=(X*YD-Y*XD)/RXYSQ + UD=(ZD*RXYSQ-Z*SPXY)/(RXYZSQ*RXY) + END IF + + IF (PX.GT.TINY) THEN + RV=SPXYZ/(PX*RXYZ*VF) + PX=PX/RXYZ + END IF + +* Return results + R2000=R + D2000=D + DR2000=UR/PMF + DD2000=UD/PMF + V2000=RV + P2000=PX + + END diff --git a/src/slalib/fk45z.f b/src/slalib/fk45z.f new file mode 100644 index 0000000..350251d --- /dev/null +++ b/src/slalib/fk45z.f @@ -0,0 +1,165 @@ + SUBROUTINE sla_FK45Z (R1950,D1950,BEPOCH,R2000,D2000) +*+ +* - - - - - - +* F K 4 5 Z +* - - - - - - +* +* Convert B1950.0 FK4 star data to J2000.0 FK5 assuming zero +* proper motion in the FK5 frame (double precision) +* +* This routine converts stars from the old, Bessel-Newcomb, FK4 +* system to the new, IAU 1976, FK5, Fricke system, in such a +* way that the FK5 proper motion is zero. Because such a star +* has, in general, a non-zero proper motion in the FK4 system, +* the routine requires the epoch at which the position in the +* FK4 system was determined. +* +* The method is from Appendix 2 of Ref 1, but using the constants +* of Ref 4. +* +* Given: +* R1950,D1950 dp B1950.0 FK4 RA,Dec at epoch (rad) +* BEPOCH dp Besselian epoch (e.g. 1979.3D0) +* +* Returned: +* R2000,D2000 dp J2000.0 FK5 RA,Dec (rad) +* +* Notes: +* +* 1) The epoch BEPOCH is strictly speaking Besselian, but +* if a Julian epoch is supplied the result will be +* affected only to a negligible extent. +* +* 2) Conversion from Besselian epoch 1950.0 to Julian epoch +* 2000.0 only is provided for. Conversions involving other +* epochs will require use of the appropriate precession, +* proper motion, and E-terms routines before and/or +* after FK45Z is called. +* +* 3) In the FK4 catalogue the proper motions of stars within +* 10 degrees of the poles do not embody the differential +* E-term effect and should, strictly speaking, be handled +* in a different manner from stars outside these regions. +* However, given the general lack of homogeneity of the star +* data available for routine astrometry, the difficulties of +* handling positions that may have been determined from +* astrometric fields spanning the polar and non-polar regions, +* the likelihood that the differential E-terms effect was not +* taken into account when allowing for proper motion in past +* astrometry, and the undesirability of a discontinuity in +* the algorithm, the decision has been made in this routine to +* include the effect of differential E-terms on the proper +* motions for all stars, whether polar or not. At epoch 2000, +* and measuring on the sky rather than in terms of dRA, the +* errors resulting from this simplification are less than +* 1 milliarcsecond in position and 1 milliarcsecond per +* century in proper motion. +* +* References: +* +* 1 Aoki,S., et al, 1983. Astron.Astrophys., 128, 263. +* +* 2 Smith, C.A. et al, 1989. "The transformation of astrometric +* catalog systems to the equinox J2000.0". Astron.J. 97, 265. +* +* 3 Yallop, B.D. et al, 1989. "Transformation of mean star places +* from FK4 B1950.0 to FK5 J2000.0 using matrices in 6-space". +* Astron.J. 97, 274. +* +* 4 Seidelmann, P.K. (ed), 1992. "Explanatory Supplement to +* the Astronomical Almanac", ISBN 0-935702-68-7. +* +* Called: sla_DCS2C, sla_EPJ, sla_EPB2D, sla_DCC2S, sla_DRANRM +* +* P.T.Wallace Starlink 21 September 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION R1950,D1950,BEPOCH,R2000,D2000 + + DOUBLE PRECISION D2PI + PARAMETER (D2PI=6.283185307179586476925287D0) + + DOUBLE PRECISION W + INTEGER I,J + +* Position and position+velocity vectors + DOUBLE PRECISION R0(3),A1(3),V1(3),V2(6) + +* Radians per year to arcsec per century + DOUBLE PRECISION PMF + PARAMETER (PMF=100D0*60D0*60D0*360D0/D2PI) + +* Functions + DOUBLE PRECISION sla_EPJ,sla_EPB2D,sla_DRANRM + +* +* CANONICAL CONSTANTS (see references) +* + +* Vectors A and Adot, and matrix M (only half of which is needed here) + DOUBLE PRECISION A(3),AD(3),EM(6,3) + DATA A,AD/ -1.62557D-6, -0.31919D-6, -0.13843D-6, + : +1.245D-3, -1.580D-3, -0.659D-3/ + + DATA (EM(I,1),I=1,6) / +0.9999256782D0, + : +0.0111820610D0, + : +0.0048579479D0, + : -0.000551D0, + : +0.238514D0, + : -0.435623D0 / + + DATA (EM(I,2),I=1,6) / -0.0111820611D0, + : +0.9999374784D0, + : -0.0000271474D0, + : -0.238565D0, + : -0.002667D0, + : +0.012254D0 / + + DATA (EM(I,3),I=1,6) / -0.0048579477D0, + : -0.0000271765D0, + : +0.9999881997D0, + : +0.435739D0, + : -0.008541D0, + : +0.002117D0 / + + + +* Spherical to Cartesian + CALL sla_DCS2C(R1950,D1950,R0) + +* Adjust vector A to give zero proper motion in FK5 + W=(BEPOCH-1950D0)/PMF + DO I=1,3 + A1(I)=A(I)+W*AD(I) + END DO + +* Remove e-terms + W=R0(1)*A1(1)+R0(2)*A1(2)+R0(3)*A1(3) + DO I=1,3 + V1(I)=R0(I)-A1(I)+W*R0(I) + END DO + +* Convert position vector to Fricke system + DO I=1,6 + W=0D0 + DO J=1,3 + W=W+EM(I,J)*V1(J) + END DO + V2(I)=W + END DO + +* Allow for fictitious proper motion in FK4 + W=(sla_EPJ(sla_EPB2D(BEPOCH))-2000D0)/PMF + DO I=1,3 + V2(I)=V2(I)+W*V2(I+3) + END DO + +* Revert to spherical coordinates + CALL sla_DCC2S(V2,W,D2000) + R2000=sla_DRANRM(W) + + END diff --git a/src/slalib/fk524.f b/src/slalib/fk524.f new file mode 100644 index 0000000..1b990dc --- /dev/null +++ b/src/slalib/fk524.f @@ -0,0 +1,257 @@ + SUBROUTINE sla_FK524 (R2000,D2000,DR2000,DD2000,P2000,V2000, + : R1950,D1950,DR1950,DD1950,P1950,V1950) +*+ +* - - - - - - +* F K 5 2 4 +* - - - - - - +* +* Convert J2000.0 FK5 star data to B1950.0 FK4 (double precision) +* +* This routine converts stars from the new, IAU 1976, FK5, Fricke +* system, to the old, Bessel-Newcomb, FK4 system. The precepts +* of Smith et al (Ref 1) are followed, using the implementation +* by Yallop et al (Ref 2) of a matrix method due to Standish. +* Kinoshita's development of Andoyer's post-Newcomb precession is +* used. The numerical constants from Seidelmann et al (Ref 3) are +* used canonically. +* +* Given: (all J2000.0,FK5) +* R2000,D2000 dp J2000.0 RA,Dec (rad) +* DR2000,DD2000 dp J2000.0 proper motions (rad/Jul.yr) +* P2000 dp parallax (arcsec) +* V2000 dp radial velocity (km/s, +ve = moving away) +* +* Returned: (all B1950.0,FK4) +* R1950,D1950 dp B1950.0 RA,Dec (rad) +* DR1950,DD1950 dp B1950.0 proper motions (rad/trop.yr) +* P1950 dp parallax (arcsec) +* V1950 dp radial velocity (km/s, +ve = moving away) +* +* Notes: +* +* 1) The proper motions in RA are dRA/dt rather than +* cos(Dec)*dRA/dt, and are per year rather than per century. +* +* 2) Note that conversion from Julian epoch 2000.0 to Besselian +* epoch 1950.0 only is provided for. Conversions involving +* other epochs will require use of the appropriate precession, +* proper motion, and E-terms routines before and/or after +* FK524 is called. +* +* 3) In the FK4 catalogue the proper motions of stars within +* 10 degrees of the poles do not embody the differential +* E-term effect and should, strictly speaking, be handled +* in a different manner from stars outside these regions. +* However, given the general lack of homogeneity of the star +* data available for routine astrometry, the difficulties of +* handling positions that may have been determined from +* astrometric fields spanning the polar and non-polar regions, +* the likelihood that the differential E-terms effect was not +* taken into account when allowing for proper motion in past +* astrometry, and the undesirability of a discontinuity in +* the algorithm, the decision has been made in this routine to +* include the effect of differential E-terms on the proper +* motions for all stars, whether polar or not. At epoch 2000, +* and measuring on the sky rather than in terms of dRA, the +* errors resulting from this simplification are less than +* 1 milliarcsecond in position and 1 milliarcsecond per +* century in proper motion. +* +* References: +* +* 1 Smith, C.A. et al, 1989. "The transformation of astrometric +* catalog systems to the equinox J2000.0". Astron.J. 97, 265. +* +* 2 Yallop, B.D. et al, 1989. "Transformation of mean star places +* from FK4 B1950.0 to FK5 J2000.0 using matrices in 6-space". +* Astron.J. 97, 274. +* +* 3 Seidelmann, P.K. (ed), 1992. "Explanatory Supplement to +* the Astronomical Almanac", ISBN 0-935702-68-7. +* +* P.T.Wallace Starlink 19 December 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION R2000,D2000,DR2000,DD2000,P2000,V2000, + : R1950,D1950,DR1950,DD1950,P1950,V1950 + + +* Miscellaneous + DOUBLE PRECISION R,D,UR,UD,PX,RV + DOUBLE PRECISION SR,CR,SD,CD,X,Y,Z,W + DOUBLE PRECISION V1(6),V2(6) + DOUBLE PRECISION XD,YD,ZD + DOUBLE PRECISION RXYZ,WD,RXYSQ,RXY + INTEGER I,J + +* 2Pi + DOUBLE PRECISION D2PI + PARAMETER (D2PI=6.283185307179586476925287D0) + +* Radians per year to arcsec per century + DOUBLE PRECISION PMF + PARAMETER (PMF=100D0*60D0*60D0*360D0/D2PI) + +* Small number to avoid arithmetic problems + DOUBLE PRECISION TINY + PARAMETER (TINY=1D-30) + +* +* CANONICAL CONSTANTS (see references) +* + +* Km per sec to AU per tropical century +* = 86400 * 36524.2198782 / 149597870 + DOUBLE PRECISION VF + PARAMETER (VF=21.095D0) + +* Constant vector and matrix (by columns) + DOUBLE PRECISION A(6),EMI(6,6) + DATA A/ -1.62557D-6, -0.31919D-6, -0.13843D-6, + : +1.245D-3, -1.580D-3, -0.659D-3/ + + DATA (EMI(I,1),I=1,6) / +0.9999256795D0, + : -0.0111814828D0, + : -0.0048590040D0, + : -0.000551D0, + : -0.238560D0, + : +0.435730D0 / + + DATA (EMI(I,2),I=1,6) / +0.0111814828D0, + : +0.9999374849D0, + : -0.0000271557D0, + : +0.238509D0, + : -0.002667D0, + : -0.008541D0 / + + DATA (EMI(I,3),I=1,6) / +0.0048590039D0, + : -0.0000271771D0, + : +0.9999881946D0, + : -0.435614D0, + : +0.012254D0, + : +0.002117D0 / + + DATA (EMI(I,4),I=1,6) / -0.00000242389840D0, + : +0.00000002710544D0, + : +0.00000001177742D0, + : +0.99990432D0, + : -0.01118145D0, + : -0.00485852D0 / + + DATA (EMI(I,5),I=1,6) / -0.00000002710544D0, + : -0.00000242392702D0, + : +0.00000000006585D0, + : +0.01118145D0, + : +0.99991613D0, + : -0.00002716D0 / + + DATA (EMI(I,6),I=1,6) / -0.00000001177742D0, + : +0.00000000006585D0, + : -0.00000242404995D0, + : +0.00485852D0, + : -0.00002717D0, + : +0.99996684D0 / + + + +* Pick up J2000 data (units radians and arcsec/JC) + R=R2000 + D=D2000 + UR=DR2000*PMF + UD=DD2000*PMF + PX=P2000 + RV=V2000 + +* Spherical to Cartesian + SR=SIN(R) + CR=COS(R) + SD=SIN(D) + CD=COS(D) + + X=CR*CD + Y=SR*CD + Z= SD + + W=VF*RV*PX + + V1(1)=X + V1(2)=Y + V1(3)=Z + + V1(4)=-UR*Y-CR*SD*UD+W*X + V1(5)= UR*X-SR*SD*UD+W*Y + V1(6)= CD*UD+W*Z + +* Convert position+velocity vector to BN system + DO I=1,6 + W=0D0 + DO J=1,6 + W=W+EMI(I,J)*V1(J) + END DO + V2(I)=W + END DO + +* Position vector components and magnitude + X=V2(1) + Y=V2(2) + Z=V2(3) + RXYZ=SQRT(X*X+Y*Y+Z*Z) + +* Apply E-terms to position + W=X*A(1)+Y*A(2)+Z*A(3) + X=X+A(1)*RXYZ-W*X + Y=Y+A(2)*RXYZ-W*Y + Z=Z+A(3)*RXYZ-W*Z + +* Recompute magnitude + RXYZ=SQRT(X*X+Y*Y+Z*Z) + +* Apply E-terms to both position and velocity + X=V2(1) + Y=V2(2) + Z=V2(3) + W=X*A(1)+Y*A(2)+Z*A(3) + WD=X*A(4)+Y*A(5)+Z*A(6) + X=X+A(1)*RXYZ-W*X + Y=Y+A(2)*RXYZ-W*Y + Z=Z+A(3)*RXYZ-W*Z + XD=V2(4)+A(4)*RXYZ-WD*X + YD=V2(5)+A(5)*RXYZ-WD*Y + ZD=V2(6)+A(6)*RXYZ-WD*Z + +* Convert to spherical + RXYSQ=X*X+Y*Y + RXY=SQRT(RXYSQ) + + IF (X.EQ.0D0.AND.Y.EQ.0D0) THEN + R=0D0 + ELSE + R=ATAN2(Y,X) + IF (R.LT.0.0D0) R=R+D2PI + END IF + D=ATAN2(Z,RXY) + + IF (RXY.GT.TINY) THEN + UR=(X*YD-Y*XD)/RXYSQ + UD=(ZD*RXYSQ-Z*(X*XD+Y*YD))/((RXYSQ+Z*Z)*RXY) + END IF + +* Radial velocity and parallax + IF (PX.GT.TINY) THEN + RV=(X*XD+Y*YD+Z*ZD)/(PX*VF*RXYZ) + PX=PX/RXYZ + END IF + +* Return results + R1950=R + D1950=D + DR1950=UR/PMF + DD1950=UD/PMF + P1950=PX + V1950=RV + + END diff --git a/src/slalib/fk52h.f b/src/slalib/fk52h.f new file mode 100644 index 0000000..c31a8fe --- /dev/null +++ b/src/slalib/fk52h.f @@ -0,0 +1,105 @@ + SUBROUTINE sla_FK52H (R5,D5,DR5,DD5,RH,DH,DRH,DDH) +*+ +* - - - - - - +* F K 5 2 H +* - - - - - - +* +* Transform FK5 (J2000) star data into the Hipparcos frame. +* +* (double precision) +* +* This routine transforms FK5 star positions and proper motions +* into the frame of the Hipparcos catalogue. +* +* Given (all FK5, equinox J2000, epoch J2000): +* R5 d RA (radians) +* D5 d Dec (radians) +* DR5 d proper motion in RA (dRA/dt, rad/Jyear) +* DD5 d proper motion in Dec (dDec/dt, rad/Jyear) +* +* Returned (all Hipparcos, epoch J2000): +* RH d RA (radians) +* DH d Dec (radians) +* DRH d proper motion in RA (dRA/dt, rad/Jyear) +* DDH d proper motion in Dec (dDec/dt, rad/Jyear) +* +* Called: sla_DS2C6, sla_DAV2M, sla_DMXV, sla_DVXV, sla_DC62S, +* sla_DRANRM +* +* Notes: +* +* 1) The proper motions in RA are dRA/dt rather than +* cos(Dec)*dRA/dt, and are per year rather than per century. +* +* 2) The FK5 to Hipparcos transformation consists of a pure +* rotation and spin; zonal errors in the FK5 catalogue are +* not taken into account. +* +* 3) The published orientation and spin components are interpreted +* as "axial vectors". An axial vector points at the pole of the +* rotation and its length is the amount of rotation in radians. +* +* 4) See also sla_H2FK5, sla_FK5HZ, sla_HFK5Z. +* +* Reference: +* +* M.Feissel & F.Mignard, Astron. Astrophys. 331, L33-L36 (1998). +* +* P.T.Wallace Starlink 22 June 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION R5,D5,DR5,DD5,RH,DH,DRH,DDH + + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + +* FK5 to Hipparcos orientation and spin (radians, radians/year) + DOUBLE PRECISION EPX,EPY,EPZ + DOUBLE PRECISION OMX,OMY,OMZ + + PARAMETER ( EPX = -19.9D-3 * AS2R, + : EPY = -9.1D-3 * AS2R, + : EPZ = +22.9D-3 * AS2R ) + + PARAMETER ( OMX = -0.30D-3 * AS2R, + : OMY = +0.60D-3 * AS2R, + : OMZ = +0.70D-3 * AS2R ) + + DOUBLE PRECISION PV5(6),ORTN(3),R5H(3,3),S5(3),VV(3),PVH(6),W,R,V + INTEGER I + + DOUBLE PRECISION sla_DRANRM + + + +* FK5 barycentric position/velocity 6-vector (normalized). + CALL sla_DS2C6(R5,D5,1D0,DR5,DD5,0D0,PV5) + +* FK5 to Hipparcos orientation matrix. + ORTN(1) = EPX + ORTN(2) = EPY + ORTN(3) = EPZ + CALL sla_DAV2M(ORTN,R5H) + +* Hipparcos wrt FK5 spin vector. + S5(1) = OMX + S5(2) = OMY + S5(3) = OMZ + +* Orient & spin the 6-vector into the Hipparcos frame. + CALL sla_DMXV(R5H,PV5,PVH) + CALL sla_DVXV(PV5,S5,VV) + DO I=1,3 + VV(I) = PV5(I+3)+VV(I) + END DO + CALL sla_DMXV(R5H,VV,PVH(4)) + +* Hipparcos 6-vector to spherical. + CALL sla_DC62S(PVH,W,DH,R,DRH,DDH,V) + RH = sla_DRANRM(W) + + END diff --git a/src/slalib/fk54z.f b/src/slalib/fk54z.f new file mode 100644 index 0000000..4ab564f --- /dev/null +++ b/src/slalib/fk54z.f @@ -0,0 +1,69 @@ + SUBROUTINE sla_FK54Z (R2000,D2000,BEPOCH, + : R1950,D1950,DR1950,DD1950) +*+ +* - - - - - - +* F K 5 4 Z +* - - - - - - +* +* Convert a J2000.0 FK5 star position to B1950.0 FK4 assuming +* zero proper motion and parallax (double precision) +* +* This routine converts star positions from the new, IAU 1976, +* FK5, Fricke system to the old, Bessel-Newcomb, FK4 system. +* +* Given: +* R2000,D2000 dp J2000.0 FK5 RA,Dec (rad) +* BEPOCH dp Besselian epoch (e.g. 1950D0) +* +* Returned: +* R1950,D1950 dp B1950.0 FK4 RA,Dec (rad) at epoch BEPOCH +* DR1950,DD1950 dp B1950.0 FK4 proper motions (rad/trop.yr) +* +* Notes: +* +* 1) The proper motion in RA is dRA/dt rather than cos(Dec)*dRA/dt. +* +* 2) Conversion from Julian epoch 2000.0 to Besselian epoch 1950.0 +* only is provided for. Conversions involving other epochs will +* require use of the appropriate precession routines before and +* after this routine is called. +* +* 3) Unlike in the sla_FK524 routine, the FK5 proper motions, the +* parallax and the radial velocity are presumed zero. +* +* 4) It is the intention that FK5 should be a close approximation +* to an inertial frame, so that distant objects have zero proper +* motion; such objects have (in general) non-zero proper motion +* in FK4, and this routine returns those fictitious proper +* motions. +* +* 5) The position returned by this routine is in the B1950 +* reference frame but at Besselian epoch BEPOCH. For +* comparison with catalogues the BEPOCH argument will +* frequently be 1950D0. +* +* Called: sla_FK524, sla_PM +* +* P.T.Wallace Starlink 10 April 1990 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION R2000,D2000,BEPOCH, + : R1950,D1950,DR1950,DD1950 + + DOUBLE PRECISION R,D,PX,RV + + + +* FK5 equinox J2000 (any epoch) to FK4 equinox B1950 epoch B1950 + CALL sla_FK524(R2000,D2000,0D0,0D0,0D0,0D0, + : R,D,DR1950,DD1950,PX,RV) + +* Fictitious proper motion to epoch BEPOCH + CALL sla_PM(R,D,DR1950,DD1950,0D0,0D0,1950D0,BEPOCH, + : R1950,D1950) + + END diff --git a/src/slalib/fk5hz.f b/src/slalib/fk5hz.f new file mode 100644 index 0000000..7aa209d --- /dev/null +++ b/src/slalib/fk5hz.f @@ -0,0 +1,107 @@ + SUBROUTINE sla_FK5HZ (R5,D5,EPOCH,RH,DH) +*+ +* - - - - - - +* F K 5 H Z +* - - - - - - +* +* Transform an FK5 (J2000) star position into the frame of the +* Hipparcos catalogue, assuming zero Hipparcos proper motion. +* +* (double precision) +* +* This routine converts a star position from the FK5 system to +* the Hipparcos system, in such a way that the Hipparcos proper +* motion is zero. Because such a star has, in general, a non-zero +* proper motion in the FK5 system, the routine requires the epoch +* at which the position in the FK5 system was determined. +* +* Given: +* R5 d FK5 RA (radians), equinox J2000, epoch EPOCH +* D5 d FK5 Dec (radians), equinox J2000, epoch EPOCH +* EPOCH d Julian epoch (TDB) +* +* Returned (all Hipparcos): +* RH d RA (radians) +* DH d Dec (radians) +* +* Called: sla_DCS2C, sla_DAV2M, sla_DIMXV, sla_DMXV, sla_DCC2S, +* sla_DRANRM +* +* Notes: +* +* 1) The FK5 to Hipparcos transformation consists of a pure +* rotation and spin; zonal errors in the FK5 catalogue are +* not taken into account. +* +* 2) The published orientation and spin components are interpreted +* as "axial vectors". An axial vector points at the pole of the +* rotation and its length is the amount of rotation in radians. +* +* 3) See also sla_FK52H, sla_H2FK5, sla_HFK5Z. +* +* Reference: +* +* M.Feissel & F.Mignard, Astron. Astrophys. 331, L33-L36 (1998). +* +* P.T.Wallace Starlink 22 June 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION R5,D5,EPOCH,RH,DH + + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + +* FK5 to Hipparcos orientation and spin (radians, radians/year) + DOUBLE PRECISION EPX,EPY,EPZ + DOUBLE PRECISION OMX,OMY,OMZ + + PARAMETER ( EPX = -19.9D-3 * AS2R, + : EPY = -9.1D-3 * AS2R, + : EPZ = +22.9D-3 * AS2R ) + + PARAMETER ( OMX = -0.30D-3 * AS2R, + : OMY = +0.60D-3 * AS2R, + : OMZ = +0.70D-3 * AS2R ) + + DOUBLE PRECISION P5E(3),ORTN(3),R5H(3,3),T,VST(3),RST(3,3), + : P5(3),PH(3),W + + DOUBLE PRECISION sla_DRANRM + + + +* FK5 barycentric position vector. + CALL sla_DCS2C(R5,D5,P5E) + +* FK5 to Hipparcos orientation matrix. + ORTN(1) = EPX + ORTN(2) = EPY + ORTN(3) = EPZ + CALL sla_DAV2M(ORTN,R5H) + +* Time interval from epoch to J2000. + T = 2000D0-EPOCH + +* Axial vector: accumulated Hipparcos wrt FK5 spin over that interval. + VST(1) = OMX*T + VST(2) = OMY*T + VST(3) = OMZ*T + +* Express the accumulated spin as a rotation matrix. + CALL sla_DAV2M(VST,RST) + +* Derotate the vector's FK5 axes back to epoch. + CALL sla_DIMXV(RST,P5E,P5) + +* Rotate the vector into the Hipparcos frame. + CALL sla_DMXV(R5H,P5,PH) + +* Hipparcos vector to spherical. + CALL sla_DCC2S(PH,W,DH) + RH = sla_DRANRM(W) + + END diff --git a/src/slalib/flotin.f b/src/slalib/flotin.f new file mode 100644 index 0000000..ce90726 --- /dev/null +++ b/src/slalib/flotin.f @@ -0,0 +1,128 @@ + SUBROUTINE sla_FLOTIN (STRING, NSTRT, RESLT, JFLAG) +*+ +* - - - - - - - +* F L O T I N +* - - - - - - - +* +* Convert free-format input into single precision floating point +* +* Given: +* STRING c string containing number to be decoded +* NSTRT i pointer to where decoding is to start +* RESLT r current value of result +* +* Returned: +* NSTRT i advanced to next number +* RESLT r result +* JFLAG i status: -1 = -OK, 0 = +OK, 1 = null, 2 = error +* +* Called: sla_DFLTIN +* +* Notes: +* +* 1 The reason FLOTIN has separate OK status values for + +* and - is to enable minus zero to be detected. This is +* of crucial importance when decoding mixed-radix numbers. +* For example, an angle expressed as deg, arcmin, arcsec +* may have a leading minus sign but a zero degrees field. +* +* 2 A TAB is interpreted as a space, and lowercase characters +* are interpreted as uppercase. +* +* 3 The basic format is the sequence of fields #^.^@#^, where +* # is a sign character + or -, ^ means a string of decimal +* digits, and @, which indicates an exponent, means D or E. +* Various combinations of these fields can be omitted, and +* embedded blanks are permissible in certain places. +* +* 4 Spaces: +* +* . Leading spaces are ignored. +* +* . Embedded spaces are allowed only after +, -, D or E, +* and after the decomal point if the first sequence of +* digits is absent. +* +* . Trailing spaces are ignored; the first signifies +* end of decoding and subsequent ones are skipped. +* +* 5 Delimiters: +* +* . Any character other than +,-,0-9,.,D,E or space may be +* used to signal the end of the number and terminate +* decoding. +* +* . Comma is recognized by FLOTIN as a special case; it +* is skipped, leaving the pointer on the next character. +* See 13, below. +* +* 6 Both signs are optional. The default is +. +* +* 7 The mantissa ^.^ defaults to 1. +* +* 8 The exponent @#^ defaults to E0. +* +* 9 The strings of decimal digits may be of any length. +* +* 10 The decimal point is optional for whole numbers. +* +* 11 A "null result" occurs when the string of characters being +* decoded does not begin with +,-,0-9,.,D or E, or consists +* entirely of spaces. When this condition is detected, JFLAG +* is set to 1 and RESLT is left untouched. +* +* 12 NSTRT = 1 for the first character in the string. +* +* 13 On return from FLOTIN, NSTRT is set ready for the next +* decode - following trailing blanks and any comma. If a +* delimiter other than comma is being used, NSTRT must be +* incremented before the next call to FLOTIN, otherwise +* all subsequent calls will return a null result. +* +* 14 Errors (JFLAG=2) occur when: +* +* . a +, -, D or E is left unsatisfied; or +* +* . the decimal point is present without at least +* one decimal digit before or after it; or +* +* . an exponent more than 100 has been presented. +* +* 15 When an error has been detected, NSTRT is left +* pointing to the character following the last +* one used before the error came to light. This +* may be after the point at which a more sophisticated +* program could have detected the error. For example, +* FLOTIN does not detect that '1E999' is unacceptable +* (on a computer where this is so) until the entire number +* has been decoded. +* +* 16 Certain highly unlikely combinations of mantissa & +* exponent can cause arithmetic faults during the +* decode, in some cases despite the fact that they +* together could be construed as a valid number. +* +* 17 Decoding is left to right, one pass. +* +* 18 See also DFLTIN and INTIN +* +* P.T.Wallace Starlink 23 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) STRING + INTEGER NSTRT + REAL RESLT + INTEGER JFLAG + + DOUBLE PRECISION DRESLT + + +* Call the double precision version + CALL sla_DFLTIN(STRING,NSTRT,DRESLT,JFLAG) + IF (JFLAG.LE.0) RESLT=REAL(DRESLT) + + END diff --git a/src/slalib/galeq.f b/src/slalib/galeq.f new file mode 100644 index 0000000..c2c3718 --- /dev/null +++ b/src/slalib/galeq.f @@ -0,0 +1,79 @@ + SUBROUTINE sla_GALEQ (DL, DB, DR, DD) +*+ +* - - - - - - +* G A L E Q +* - - - - - - +* +* Transformation from IAU 1958 galactic coordinates to +* J2000.0 equatorial coordinates (double precision) +* +* Given: +* DL,DB dp galactic longitude and latitude L2,B2 +* +* Returned: +* DR,DD dp J2000.0 RA,Dec +* +* (all arguments are radians) +* +* Called: +* sla_DCS2C, sla_DIMXV, sla_DCC2S, sla_DRANRM, sla_DRANGE +* +* Note: +* The equatorial coordinates are J2000.0. Use the routine +* sla_GE50 if conversion to B1950.0 'FK4' coordinates is +* required. +* +* Reference: +* Blaauw et al, Mon.Not.R.Astron.Soc.,121,123 (1960) +* +* P.T.Wallace Starlink 21 September 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DL,DB,DR,DD + + DOUBLE PRECISION sla_DRANRM,sla_DRANGE + + DOUBLE PRECISION V1(3),V2(3) + +* +* L2,B2 system of galactic coordinates +* +* P = 192.25 RA of galactic north pole (mean B1950.0) +* Q = 62.6 inclination of galactic to mean B1950.0 equator +* R = 33 longitude of ascending node +* +* P,Q,R are degrees +* +* Equatorial to galactic rotation matrix (J2000.0), obtained by +* applying the standard FK4 to FK5 transformation, for zero proper +* motion in FK5, to the columns of the B1950 equatorial to +* galactic rotation matrix: +* + DOUBLE PRECISION RMAT(3,3) + DATA RMAT(1,1),RMAT(1,2),RMAT(1,3), + : RMAT(2,1),RMAT(2,2),RMAT(2,3), + : RMAT(3,1),RMAT(3,2),RMAT(3,3)/ + : -0.054875539726D0,-0.873437108010D0,-0.483834985808D0, + : +0.494109453312D0,-0.444829589425D0,+0.746982251810D0, + : -0.867666135858D0,-0.198076386122D0,+0.455983795705D0/ + + + +* Spherical to Cartesian + CALL sla_DCS2C(DL,DB,V1) + +* Galactic to equatorial + CALL sla_DIMXV(RMAT,V1,V2) + +* Cartesian to spherical + CALL sla_DCC2S(V2,DR,DD) + +* Express in conventional ranges + DR=sla_DRANRM(DR) + DD=sla_DRANGE(DD) + + END diff --git a/src/slalib/galsup.f b/src/slalib/galsup.f new file mode 100644 index 0000000..b2520b9 --- /dev/null +++ b/src/slalib/galsup.f @@ -0,0 +1,79 @@ + SUBROUTINE sla_GALSUP (DL, DB, DSL, DSB) +*+ +* - - - - - - - +* G A L S U P +* - - - - - - - +* +* Transformation from IAU 1958 galactic coordinates to +* de Vaucouleurs supergalactic coordinates (double precision) +* +* Given: +* DL,DB dp galactic longitude and latitude L2,B2 +* +* Returned: +* DSL,DSB dp supergalactic longitude and latitude +* +* (all arguments are radians) +* +* Called: +* sla_DCS2C, sla_DMXV, sla_DCC2S, sla_DRANRM, sla_DRANGE +* +* References: +* +* de Vaucouleurs, de Vaucouleurs, & Corwin, Second Reference +* Catalogue of Bright Galaxies, U. Texas, page 8. +* +* Systems & Applied Sciences Corp., Documentation for the +* machine-readable version of the above catalogue, +* Contract NAS 5-26490. +* +* (These two references give different values for the galactic +* longitude of the supergalactic origin. Both are wrong; the +* correct value is L2=137.37.) +* +* P.T.Wallace Starlink 25 January 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DL,DB,DSL,DSB + + DOUBLE PRECISION sla_DRANRM,sla_DRANGE + + DOUBLE PRECISION V1(3),V2(3) + +* +* System of supergalactic coordinates: +* +* SGL SGB L2 B2 (deg) +* - +90 47.37 +6.32 +* 0 0 - 0 +* +* Galactic to supergalactic rotation matrix: +* + DOUBLE PRECISION RMAT(3,3) + DATA RMAT(1,1),RMAT(1,2),RMAT(1,3), + : RMAT(2,1),RMAT(2,2),RMAT(2,3), + : RMAT(3,1),RMAT(3,2),RMAT(3,3)/ + : -0.735742574804D0,+0.677261296414D0,+0.000000000000D0, + : -0.074553778365D0,-0.080991471307D0,+0.993922590400D0, + : +0.673145302109D0,+0.731271165817D0,+0.110081262225D0/ + + + +* Spherical to Cartesian + CALL sla_DCS2C(DL,DB,V1) + +* Galactic to supergalactic + CALL sla_DMXV(RMAT,V1,V2) + +* Cartesian to spherical + CALL sla_DCC2S(V2,DSL,DSB) + +* Express in conventional ranges + DSL=sla_DRANRM(DSL) + DSB=sla_DRANGE(DSB) + + END diff --git a/src/slalib/ge50.f b/src/slalib/ge50.f new file mode 100644 index 0000000..fed5728 --- /dev/null +++ b/src/slalib/ge50.f @@ -0,0 +1,90 @@ + SUBROUTINE sla_GE50 (DL, DB, DR, DD) +*+ +* - - - - - +* G E 5 0 +* - - - - - +* +* Transformation from IAU 1958 galactic coordinates to +* B1950.0 'FK4' equatorial coordinates (double precision) +* +* Given: +* DL,DB dp galactic longitude and latitude L2,B2 +* +* Returned: +* DR,DD dp B1950.0 'FK4' RA,Dec +* +* (all arguments are radians) +* +* Called: +* sla_DCS2C, sla_DIMXV, sla_DCC2S, sla_ADDET, sla_DRANRM, sla_DRANGE +* +* Note: +* The equatorial coordinates are B1950.0 'FK4'. Use the +* routine sla_GALEQ if conversion to J2000.0 coordinates +* is required. +* +* Reference: +* Blaauw et al, Mon.Not.R.Astron.Soc.,121,123 (1960) +* +* P.T.Wallace Starlink 5 September 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DL,DB,DR,DD + + DOUBLE PRECISION sla_DRANRM,sla_DRANGE + + DOUBLE PRECISION V1(3),V2(3),R,D,RE,DE + +* +* L2,B2 system of galactic coordinates +* +* P = 192.25 RA of galactic north pole (mean B1950.0) +* Q = 62.6 inclination of galactic to mean B1950.0 equator +* R = 33 longitude of ascending node +* +* P,Q,R are degrees +* +* +* Equatorial to galactic rotation matrix +* +* The Euler angles are P, Q, 90-R, about the z then y then +* z axes. +* +* +CP.CQ.SR-SP.CR +SP.CQ.SR+CP.CR -SQ.SR +* +* -CP.CQ.CR-SP.SR -SP.CQ.CR+CP.SR +SQ.CR +* +* +CP.SQ +SP.SQ +CQ +* + + DOUBLE PRECISION RMAT(3,3) + DATA RMAT(1,1),RMAT(1,2),RMAT(1,3), + : RMAT(2,1),RMAT(2,2),RMAT(2,3), + : RMAT(3,1),RMAT(3,2),RMAT(3,3) / + : -0.066988739415D0,-0.872755765852D0,-0.483538914632D0, + : +0.492728466075D0,-0.450346958020D0,+0.744584633283D0, + : -0.867600811151D0,-0.188374601723D0,+0.460199784784D0 / + + + +* Spherical to Cartesian + CALL sla_DCS2C(DL,DB,V1) + +* Rotate to mean B1950.0 + CALL sla_DIMXV(RMAT,V1,V2) + +* Cartesian to spherical + CALL sla_DCC2S(V2,R,D) + +* Introduce E-terms + CALL sla_ADDET(R,D,1950D0,RE,DE) + +* Express in conventional ranges + DR=sla_DRANRM(RE) + DD=sla_DRANGE(DE) + + END diff --git a/src/slalib/geoc.f b/src/slalib/geoc.f new file mode 100644 index 0000000..89f51b7 --- /dev/null +++ b/src/slalib/geoc.f @@ -0,0 +1,57 @@ + SUBROUTINE sla_GEOC (P, H, R, Z) +*+ +* - - - - - +* G E O C +* - - - - - +* +* Convert geodetic position to geocentric (double precision) +* +* Given: +* P dp latitude (geodetic, radians) +* H dp height above reference spheroid (geodetic, metres) +* +* Returned: +* R dp distance from Earth axis (AU) +* Z dp distance from plane of Earth equator (AU) +* +* Notes: +* 1) Geocentric latitude can be obtained by evaluating ATAN2(Z,R). +* 2) IAU 1976 constants are used. +* +* Reference: +* Green,R.M., Spherical Astronomy, CUP 1985, p98. +* +* P.T.Wallace Starlink 4th October 1989 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION P,H,R,Z + +* Earth equatorial radius (metres) + DOUBLE PRECISION A0 + PARAMETER (A0=6378140D0) + +* Reference spheroid flattening factor and useful function + DOUBLE PRECISION F,B + PARAMETER (F=1D0/298.257D0,B=(1D0-F)**2) + +* Astronomical unit in metres + DOUBLE PRECISION AU + PARAMETER (AU=1.49597870D11) + + DOUBLE PRECISION SP,CP,C,S + + + +* Geodetic to geocentric conversion + SP=SIN(P) + CP=COS(P) + C=1D0/SQRT(CP*CP+B*SP*SP) + S=B*C + R=(A0*C+H)*CP/AU + Z=(A0*S+H)*SP/AU + + END diff --git a/src/slalib/gmst.f b/src/slalib/gmst.f new file mode 100644 index 0000000..b115311 --- /dev/null +++ b/src/slalib/gmst.f @@ -0,0 +1,60 @@ + DOUBLE PRECISION FUNCTION sla_GMST (UT1) +*+ +* - - - - - +* G M S T +* - - - - - +* +* Conversion from universal time to sidereal time (double precision) +* +* Given: +* UT1 dp universal time (strictly UT1) expressed as +* modified Julian Date (JD-2400000.5) +* +* The result is the Greenwich mean sidereal time (double +* precision, radians). +* +* The IAU 1982 expression (see page S15 of 1984 Astronomical +* Almanac) is used, but rearranged to reduce rounding errors. +* This expression is always described as giving the GMST at +* 0 hours UT. In fact, it gives the difference between the +* GMST and the UT, which happens to equal the GMST (modulo +* 24 hours) at 0 hours UT each day. In this routine, the +* entire UT is used directly as the argument for the +* standard formula, and the fractional part of the UT is +* added separately; note that the factor 1.0027379... does +* not appear. +* +* See also the routine sla_GMSTA, which delivers better numerical +* precision by accepting the UT date and time as separate arguments. +* +* Called: sla_DRANRM +* +* P.T.Wallace Starlink 14 September 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION UT1 + + DOUBLE PRECISION sla_DRANRM + + DOUBLE PRECISION D2PI,S2R + PARAMETER (D2PI=6.283185307179586476925286766559D0, + : S2R=7.272205216643039903848711535369D-5) + + DOUBLE PRECISION TU + + + +* Julian centuries from fundamental epoch J2000 to this UT + TU=(UT1-51544.5D0)/36525D0 + +* GMST at this UT + sla_GMST=sla_DRANRM(MOD(UT1,1D0)*D2PI+ + : (24110.54841D0+ + : (8640184.812866D0+ + : (0.093104D0-6.2D-6*TU)*TU)*TU)*S2R) + + END diff --git a/src/slalib/gmsta.f b/src/slalib/gmsta.f new file mode 100644 index 0000000..5259f6f --- /dev/null +++ b/src/slalib/gmsta.f @@ -0,0 +1,80 @@ + DOUBLE PRECISION FUNCTION sla_GMSTA (DATE, UT) +*+ +* - - - - - - +* G M S T A +* - - - - - - +* +* Conversion from Universal Time to Greenwich mean sidereal time, +* with rounding errors minimized. +* +* double precision +* +* Given: +* DATE d UT1 date (MJD: integer part of JD-2400000.5)) +* UT d UT1 time (fraction of a day) +* +* The result is the Greenwich mean sidereal time (double precision, +* radians, in the range 0 to 2pi). +* +* There is no restriction on how the UT is apportioned between the +* DATE and UT arguments. Either of the two arguments could, for +* example, be zero and the entire date+time supplied in the other. +* However, the routine is designed to deliver maximum accuracy when +* the DATE argument is a whole number and the UT lies in the range +* 0 to 1 (or vice versa). +* +* The algorithm is based on the IAU 1982 expression (see page S15 of +* the 1984 Astronomical Almanac). This is always described as giving +* the GMST at 0 hours UT1. In fact, it gives the difference between +* the GMST and the UT, the steady 4-minutes-per-day drawing-ahead of +* ST with respect to UT. When whole days are ignored, the expression +* happens to equal the GMST at 0 hours UT1 each day. +* +* In this routine, the entire UT1 (the sum of the two arguments DATE +* and UT) is used directly as the argument for the standard formula. +* The UT1 is then added, but omitting whole days to conserve accuracy. +* +* See also the routine sla_GMST, which accepts the UT as a single +* argument. Compared with sla_GMST, the extra numerical precision +* delivered by the present routine is unlikely to be important in +* an absolute sense, but may be useful when critically comparing +* algorithms and in applications where two sidereal times close +* together are differenced. +* +* Called: sla_DRANRM +* +* P.T.Wallace Starlink 13 April 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,UT + +* Seconds of time to radians + DOUBLE PRECISION S2R + PARAMETER (S2R=7.272205216643039903848712D-5) + + DOUBLE PRECISION D1,D2,T + DOUBLE PRECISION sla_DRANRM + + +* Julian centuries since J2000. + IF (DATE.LT.UT) THEN + D1=DATE + D2=UT + ELSE + D1=UT + D2=DATE + END IF + T=(D1+(D2-51544.5D0))/36525D0 + +* GMST at this UT1. + sla_GMSTA=sla_DRANRM(S2R*(24110.54841D0+ + : (8640184.812866D0+ + : (0.093104D0 + : -6.2D-6*T)*T)*T + : +86400D0*(MOD(D1,1D0)+MOD(D2,1D0)))) + + END diff --git a/src/slalib/gresid.f_alpha_OSF1 b/src/slalib/gresid.f_alpha_OSF1 new file mode 100644 index 0000000..9cc021b --- /dev/null +++ b/src/slalib/gresid.f_alpha_OSF1 @@ -0,0 +1,76 @@ + REAL FUNCTION sla_GRESID (S) +*+ +* - - - - - - - +* G R E S I D +* - - - - - - - +* +* Generate pseudo-random normal deviate ( = 'Gaussian residual') +* (single precision) +* +* !!! Version for DEC Alpha/OSF1 !!! +* +* Given: +* S real standard deviation +* +* The results of many calls to this routine will be +* normally distributed with mean zero and standard deviation S. +* +* The Box-Muller algorithm is used. This is described in +* Numerical Recipes, section 7.2. +* +* P.T.Wallace Starlink 14 October 1991 +* Revised for new recommended RTL RANDOM(3f) function. +* B.K.McIlwrath Starlink 12 January 1996 +*- + + IMPLICIT NONE + + REAL S + + REAL X,Y,R,W,GNEXT,G + LOGICAL FTF,FIRST + + REAL RANDOM + + SAVE GNEXT,FTF,FIRST + DATA FTF,FIRST / .TRUE.,.TRUE. / + +* First time through, initialise the random-number generator + IF (FTF) THEN + X = RANDOM(12345678) + FTF = .FALSE. + END IF + +* Second normal deviate of the pair available? + IF (FIRST) THEN + +* No - generate two random numbers inside unit circle + R = 2.0 + DO WHILE (R.GE.1.0) + +* Generate two random numbers in range +/- 1 + X = 2.0*RANDOM(0)-1.0 + Y = 2.0*RANDOM(0)-1.0 + +* Try again if not in unit circle + R = X*X+Y*Y + END DO + +* Box-Muller transformation, generating two deviates + W = SQRT(-2.0*LOG(R)/MAX(R,1E-20)) + GNEXT = X*W + G = Y*W + +* Set flag to indicate availability of next deviate + FIRST = .FALSE. + ELSE + +* Return second deviate of the pair & reset flag + G = GNEXT + FIRST = .TRUE. + END IF + +* Scale the deviate by the required standard deviation + sla_GRESID = G*S + + END diff --git a/src/slalib/gresid.f_convex b/src/slalib/gresid.f_convex new file mode 100644 index 0000000..278a79e --- /dev/null +++ b/src/slalib/gresid.f_convex @@ -0,0 +1,80 @@ + REAL FUNCTION sla_GRESID (S) +*+ +* - - - - - - - +* G R E S I D +* - - - - - - - +* +* Generate pseudo-random normal deviate ( = 'Gaussian residual') +* (single precision) +* +* !!! Convex specific !!! +* +* Given: +* S real standard deviation +* +* The results of many calls to this routine will be +* normally distributed with mean zero and standard deviation S. +* +* The Box-Muller algorithm is used. This is described in +* Numerical Recipes, section 7.2. +* +* Called: RAND (a REAL function from the Convex Fortran Library) +* +* P.T.Wallace Starlink 28 June 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL S + + REAL X,Y,R,W,GNEXT,G + LOGICAL FTF,FIRST + + REAL RAND + + SAVE GNEXT,FIRST + DATA FTF,FIRST / .TRUE.,.TRUE. / + + + +* First time through, initialise the random-number generator + IF (FTF) THEN + X = RAND(123456789) + FTF = .FALSE. + END IF + +* Second normal deviate of the pair available? + IF (FIRST) THEN + +* No - generate two random numbers inside unit circle + R = 2.0 + DO WHILE (R.GE.1.0) + +* Generate two random numbers in range +/- 1 + X = 2.0*RAND(0)-1.0 + Y = 2.0*RAND(0)-1.0 + +* Try again if not in unit circle + R = X*X+Y*Y + END DO + +* Box-Muller transformation, generating two deviates + W = SQRT(-2.0*LOG(R)/MAX(R,1E-20)) + GNEXT = X*W + G = Y*W + +* Set flag to indicate availability of next deviate + FIRST = .FALSE. + ELSE + +* Return second deviate of the pair & reset flag + G = GNEXT + FIRST = .TRUE. + END IF + +* Scale the deviate by the required standard deviation + sla_GRESID = G*S + + END diff --git a/src/slalib/gresid.f_ix86_Linux b/src/slalib/gresid.f_ix86_Linux new file mode 100644 index 0000000..ec93bdd --- /dev/null +++ b/src/slalib/gresid.f_ix86_Linux @@ -0,0 +1,74 @@ + REAL FUNCTION sla_GRESID (S) +*+ +* - - - - - - - +* G R E S I D +* - - - - - - - +* +* Generate pseudo-random normal deviate ( = 'Gaussian residual') +* (single precision) +* +* !!! Version for Linux !!! +* +* Given: +* S real standard deviation +* +* The results of many calls to this routine will be +* normally distributed with mean zero and standard deviation S. +* +* The Box-Muller algorithm is used. This is described in +* Numerical Recipes, section 7.2. +* +* B.K.McIlwrath Starlink 12 January 1996 +*- + + IMPLICIT NONE + + REAL S + + REAL X,Y,R,W,GNEXT,G + LOGICAL FTF,FIRST + + REAL RANDOM + + SAVE GNEXT,FTF,FIRST + DATA FTF,FIRST / .TRUE.,.TRUE. / + +* First time through, initialise the random-number generator + IF (FTF) THEN + X = RANDOM(12345678) + FTF = .FALSE. + END IF + +* Second normal deviate of the pair available? + IF (FIRST) THEN + +* No - generate two random numbers inside unit circle + R = 2.0 + DO WHILE (R.GE.1.0) + +* Generate two random numbers in range +/- 1 + X = 2.0*RANDOM(0)-1.0 + Y = 2.0*RANDOM(0)-1.0 + +* Try again if not in unit circle + R = X*X+Y*Y + END DO + +* Box-Muller transformation, generating two deviates + W = SQRT(-2.0*LOG(R)/MAX(R,1E-20)) + GNEXT = X*W + G = Y*W + +* Set flag to indicate availability of next deviate + FIRST = .FALSE. + ELSE + +* Return second deviate of the pair & reset flag + G = GNEXT + FIRST = .TRUE. + END IF + +* Scale the deviate by the required standard deviation + sla_GRESID = G*S + + END diff --git a/src/slalib/gresid.f_mips b/src/slalib/gresid.f_mips new file mode 100644 index 0000000..7f353f9 --- /dev/null +++ b/src/slalib/gresid.f_mips @@ -0,0 +1,74 @@ + REAL FUNCTION sla_GRESID (S) +*+ +* - - - - - - - +* G R E S I D +* - - - - - - - +* +* Generate pseudo-random normal deviate ( = 'Gaussian residual') +* (single precision) +* +* !!! Version for VAX/VMS and DECstation !!! +* +* Given: +* S real standard deviation +* +* The results of many calls to this routine will be +* normally distributed with mean zero and standard deviation S. +* +* The Box-Muller algorithm is used. This is described in +* Numerical Recipes, section 7.2. +* +* P.T.Wallace Starlink 14 October 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL S + + REAL X,Y,R,W,GNEXT,G + INTEGER ISEED + LOGICAL FIRST + + REAL RAN + + SAVE GNEXT,ISEED,FIRST + DATA ISEED / 123456789 / + DATA FIRST / .TRUE. / + + + +* Second normal deviate of the pair available? + IF (FIRST) THEN + +* No - generate two random numbers inside unit circle + R = 2.0 + DO WHILE (R.GE.1.0) + +* Generate two random numbers in range +/- 1 + X = 2.0*RAN(ISEED)-1.0 + Y = 2.0*RAN(ISEED)-1.0 + +* Try again if not in unit circle + R = X*X+Y*Y + END DO + +* Box-Muller transformation, generating two deviates + W = SQRT(-2.0*LOG(R)/MAX(R,1E-20)) + GNEXT = X*W + G = Y*W + +* Set flag to indicate availability of next deviate + FIRST = .FALSE. + ELSE + +* Return second deviate of the pair & reset flag + G = GNEXT + FIRST = .TRUE. + END IF + +* Scale the deviate by the required standard deviation + sla_GRESID = G*S + + END diff --git a/src/slalib/gresid.f_pcm b/src/slalib/gresid.f_pcm new file mode 100644 index 0000000..b2c6f76 --- /dev/null +++ b/src/slalib/gresid.f_pcm @@ -0,0 +1,73 @@ + REAL FUNCTION sla_GRESID (S) +*+ +* - - - - - - - +* G R E S I D +* - - - - - - - +* +* Generate pseudo-random normal deviate ( = 'Gaussian residual') +* (single precision) +* +* Given: +* S real standard deviation +* +* The results of many calls to this routine will be +* normally distributed with mean zero and standard deviation S. +* +* The Box-Muller algorithm is used. This is described in +* Numerical Recipes, section 7.2. +* +* !!! Microsoft Fortran dependent - calls the RAN routine !!! +* !!! To seed the random-number generator, either call the !!! +* !!! Microsoft SEED routine specifying some INTEGER*2 !!! +* !!! seed or call the function sla_RANDOM specifying some !!! +* !!! REAL seed. !!! +* +* P.T.Wallace Starlink 1 April 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL S + + REAL X,Y,RV,R,W,GNEXT,G + LOGICAL FIRST + + SAVE GNEXT,RV,FIRST + DATA FIRST / .TRUE. / + + + +* Second normal deviate of the pair available? + IF (FIRST) THEN + +* No - generate two random numbers in range +/- 1 + 1 CONTINUE + CALL RANDOM(RV) !!! PC + X = 2.0*RV-1.0 + CALL RANDOM(RV) !!! PC + Y = 2.0*RV-1.0 + +* Try again if not in unit circle + R = X*X+Y*Y + IF (R.GE.1.0) GO TO 1 + +* Box-Muller transformation, generating two deviates + W = SQRT(-2.0*LOG(R)/MAX(R,1E-20)) + GNEXT = X*W + G = Y*W + +* Set flag to indicate availability of next deviate + FIRST = .FALSE. + ELSE + +* Return second deviate of the pair & reset flag + G = GNEXT + FIRST = .TRUE. + END IF + +* Scale the deviate by the required standard deviation + sla_GRESID = G*S + + END diff --git a/src/slalib/gresid.f_sun4 b/src/slalib/gresid.f_sun4 new file mode 100644 index 0000000..3205062 --- /dev/null +++ b/src/slalib/gresid.f_sun4 @@ -0,0 +1,80 @@ + REAL FUNCTION sla_GRESID (S) +*+ +* - - - - - - - +* G R E S I D +* - - - - - - - +* +* Generate pseudo-random normal deviate ( = 'Gaussian residual') +* (single precision) +* +* !!! Sun 4 specific !!! +* +* Given: +* S real standard deviation +* +* The results of many calls to this routine will be +* normally distributed with mean zero and standard deviation S. +* +* The Box-Muller algorithm is used. This is described in +* Numerical Recipes, section 7.2. +* +* Called: RAND (a REAL function from the Sun Fortran Library) +* +* P.T.Wallace Starlink 14 October 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL S + + REAL X,Y,R,W,GNEXT,G + LOGICAL FTF,FIRST + + REAL RAND + + SAVE GNEXT,FIRST + DATA FTF,FIRST / .TRUE.,.TRUE. / + + + +* First time through, initialise the random-number generator + IF (FTF) THEN + X = RAND(123456789) + FTF = .FALSE. + END IF + +* Second normal deviate of the pair available? + IF (FIRST) THEN + +* No - generate two random numbers inside unit circle + R = 2.0 + DO WHILE (R.GE.1.0) + +* Generate two random numbers in range +/- 1 + X = 2.0*RAND(0)-1.0 + Y = 2.0*RAND(0)-1.0 + +* Try again if not in unit circle + R = X*X+Y*Y + END DO + +* Box-Muller transformation, generating two deviates + W = SQRT(-2.0*LOG(R)/MAX(R,1E-20)) + GNEXT = X*W + G = Y*W + +* Set flag to indicate availability of next deviate + FIRST = .FALSE. + ELSE + +* Return second deviate of the pair & reset flag + G = GNEXT + FIRST = .TRUE. + END IF + +* Scale the deviate by the required standard deviation + sla_GRESID = G*S + + END diff --git a/src/slalib/gresid.f_sun4_Solaris b/src/slalib/gresid.f_sun4_Solaris new file mode 100644 index 0000000..3205062 --- /dev/null +++ b/src/slalib/gresid.f_sun4_Solaris @@ -0,0 +1,80 @@ + REAL FUNCTION sla_GRESID (S) +*+ +* - - - - - - - +* G R E S I D +* - - - - - - - +* +* Generate pseudo-random normal deviate ( = 'Gaussian residual') +* (single precision) +* +* !!! Sun 4 specific !!! +* +* Given: +* S real standard deviation +* +* The results of many calls to this routine will be +* normally distributed with mean zero and standard deviation S. +* +* The Box-Muller algorithm is used. This is described in +* Numerical Recipes, section 7.2. +* +* Called: RAND (a REAL function from the Sun Fortran Library) +* +* P.T.Wallace Starlink 14 October 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL S + + REAL X,Y,R,W,GNEXT,G + LOGICAL FTF,FIRST + + REAL RAND + + SAVE GNEXT,FIRST + DATA FTF,FIRST / .TRUE.,.TRUE. / + + + +* First time through, initialise the random-number generator + IF (FTF) THEN + X = RAND(123456789) + FTF = .FALSE. + END IF + +* Second normal deviate of the pair available? + IF (FIRST) THEN + +* No - generate two random numbers inside unit circle + R = 2.0 + DO WHILE (R.GE.1.0) + +* Generate two random numbers in range +/- 1 + X = 2.0*RAND(0)-1.0 + Y = 2.0*RAND(0)-1.0 + +* Try again if not in unit circle + R = X*X+Y*Y + END DO + +* Box-Muller transformation, generating two deviates + W = SQRT(-2.0*LOG(R)/MAX(R,1E-20)) + GNEXT = X*W + G = Y*W + +* Set flag to indicate availability of next deviate + FIRST = .FALSE. + ELSE + +* Return second deviate of the pair & reset flag + G = GNEXT + FIRST = .TRUE. + END IF + +* Scale the deviate by the required standard deviation + sla_GRESID = G*S + + END diff --git a/src/slalib/gresid.f_vax b/src/slalib/gresid.f_vax new file mode 100644 index 0000000..90dab0a --- /dev/null +++ b/src/slalib/gresid.f_vax @@ -0,0 +1,72 @@ + REAL FUNCTION sla_GRESID (S) +*+ +* - - - - - - - +* G R E S I D +* - - - - - - - +* +* Generate pseudo-random normal deviate ( = 'Gaussian residual') +* (single precision) +* +* !!! Version for VAX/VMS and DECstation !!! +* +* Given: +* S real standard deviation +* +* The results of many calls to this routine will be +* normally distributed with mean zero and standard deviation S. +* +* The Box-Muller algorithm is used. This is described in +* Numerical Recipes, section 7.2. +* +* P.T.Wallace Starlink 14 October 1991 +*- + + IMPLICIT NONE + + REAL S + + REAL X,Y,R,W,GNEXT,G + INTEGER ISEED + LOGICAL FIRST + + REAL RAN + + SAVE GNEXT,ISEED,FIRST + DATA ISEED / 123456789 / + DATA FIRST / .TRUE. / + + + +* Second normal deviate of the pair available? + IF (FIRST) THEN + +* No - generate two random numbers inside unit circle + R = 2.0 + DO WHILE (R.GE.1.0) + +* Generate two random numbers in range +/- 1 + X = 2.0*RAN(ISEED)-1.0 + Y = 2.0*RAN(ISEED)-1.0 + +* Try again if not in unit circle + R = X*X+Y*Y + END DO + +* Box-Muller transformation, generating two deviates + W = SQRT(-2.0*LOG(R)/MAX(R,1E-20)) + GNEXT = X*W + G = Y*W + +* Set flag to indicate availability of next deviate + FIRST = .FALSE. + ELSE + +* Return second deviate of the pair & reset flag + G = GNEXT + FIRST = .TRUE. + END IF + +* Scale the deviate by the required standard deviation + sla_GRESID = G*S + + END diff --git a/src/slalib/gresid.f_x86_64 b/src/slalib/gresid.f_x86_64 new file mode 100644 index 0000000..ec93bdd --- /dev/null +++ b/src/slalib/gresid.f_x86_64 @@ -0,0 +1,74 @@ + REAL FUNCTION sla_GRESID (S) +*+ +* - - - - - - - +* G R E S I D +* - - - - - - - +* +* Generate pseudo-random normal deviate ( = 'Gaussian residual') +* (single precision) +* +* !!! Version for Linux !!! +* +* Given: +* S real standard deviation +* +* The results of many calls to this routine will be +* normally distributed with mean zero and standard deviation S. +* +* The Box-Muller algorithm is used. This is described in +* Numerical Recipes, section 7.2. +* +* B.K.McIlwrath Starlink 12 January 1996 +*- + + IMPLICIT NONE + + REAL S + + REAL X,Y,R,W,GNEXT,G + LOGICAL FTF,FIRST + + REAL RANDOM + + SAVE GNEXT,FTF,FIRST + DATA FTF,FIRST / .TRUE.,.TRUE. / + +* First time through, initialise the random-number generator + IF (FTF) THEN + X = RANDOM(12345678) + FTF = .FALSE. + END IF + +* Second normal deviate of the pair available? + IF (FIRST) THEN + +* No - generate two random numbers inside unit circle + R = 2.0 + DO WHILE (R.GE.1.0) + +* Generate two random numbers in range +/- 1 + X = 2.0*RANDOM(0)-1.0 + Y = 2.0*RANDOM(0)-1.0 + +* Try again if not in unit circle + R = X*X+Y*Y + END DO + +* Box-Muller transformation, generating two deviates + W = SQRT(-2.0*LOG(R)/MAX(R,1E-20)) + GNEXT = X*W + G = Y*W + +* Set flag to indicate availability of next deviate + FIRST = .FALSE. + ELSE + +* Return second deviate of the pair & reset flag + G = GNEXT + FIRST = .TRUE. + END IF + +* Scale the deviate by the required standard deviation + sla_GRESID = G*S + + END diff --git a/src/slalib/h2e.f b/src/slalib/h2e.f new file mode 100644 index 0000000..e850493 --- /dev/null +++ b/src/slalib/h2e.f @@ -0,0 +1,83 @@ + SUBROUTINE sla_H2E (AZ, EL, PHI, HA, DEC) +*+ +* - - - - - +* D E 2 H +* - - - - - +* +* Horizon to equatorial coordinates: Az,El to HA,Dec +* +* (single precision) +* +* Given: +* AZ r azimuth +* EL r elevation +* PHI r observatory latitude +* +* Returned: +* HA r hour angle +* DEC r declination +* +* Notes: +* +* 1) All the arguments are angles in radians. +* +* 2) The sign convention for azimuth is north zero, east +pi/2. +* +* 3) HA is returned in the range +/-pi. Declination is returned +* in the range +/-pi/2. +* +* 4) The latitude is (in principle) geodetic. In critical +* applications, corrections for polar motion should be applied. +* +* 5) In some applications it will be important to specify the +* correct type of elevation in order to produce the required +* type of HA,Dec. In particular, it may be important to +* distinguish between the elevation as affected by refraction, +* which will yield the "observed" HA,Dec, and the elevation +* in vacuo, which will yield the "topocentric" HA,Dec. If the +* effects of diurnal aberration can be neglected, the +* topocentric HA,Dec may be used as an approximation to the +* "apparent" HA,Dec. +* +* 6) No range checking of arguments is done. +* +* 7) In applications which involve many such calculations, rather +* than calling the present routine it will be more efficient to +* use inline code, having previously computed fixed terms such +* as sine and cosine of latitude. +* +* P.T.Wallace Starlink 21 February 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL AZ,EL,PHI,HA,DEC + + DOUBLE PRECISION SA,CA,SE,CE,SP,CP,X,Y,Z,R + + +* Useful trig functions + SA=SIN(AZ) + CA=COS(AZ) + SE=SIN(EL) + CE=COS(EL) + SP=SIN(PHI) + CP=COS(PHI) + +* HA,Dec as x,y,z + X=-CA*CE*SP+SE*CP + Y=-SA*CE + Z=CA*CE*CP+SE*SP + +* To HA,Dec + R=SQRT(X*X+Y*Y) + IF (R.EQ.0.0) THEN + HA=0.0 + ELSE + HA=ATAN2(Y,X) + END IF + DEC=ATAN2(Z,R) + + END diff --git a/src/slalib/h2fk5.f b/src/slalib/h2fk5.f new file mode 100644 index 0000000..d3a0116 --- /dev/null +++ b/src/slalib/h2fk5.f @@ -0,0 +1,109 @@ + SUBROUTINE sla_H2FK5 (RH,DH,DRH,DDH,R5,D5,DR5,DD5) +*+ +* - - - - - - +* H 2 F K 5 +* - - - - - - +* +* Transform Hipparcos star data into the FK5 (J2000) system. +* +* (double precision) +* +* This routine transforms Hipparcos star positions and proper +* motions into FK5 J2000. +* +* Given (all Hipparcos, epoch J2000): +* RH d RA (radians) +* DH d Dec (radians) +* DRH d proper motion in RA (dRA/dt, rad/Jyear) +* DDH d proper motion in Dec (dDec/dt, rad/Jyear) +* +* Returned (all FK5, equinox J2000, epoch J2000): +* R5 d RA (radians) +* D5 d Dec (radians) +* DR5 d proper motion in RA (dRA/dt, rad/Jyear) +* DD5 d proper motion in Dec (dDec/dt, rad/Jyear) +* +* Called: sla_DS2C6, sla_DAV2M, sla_DMXV, sla_DIMXV, sla_DVXV, +* sla_DC62S, sla_DRANRM +* +* Notes: +* +* 1) The proper motions in RA are dRA/dt rather than +* cos(Dec)*dRA/dt, and are per year rather than per century. +* +* 2) The FK5 to Hipparcos transformation consists of a pure +* rotation and spin; zonal errors in the FK5 catalogue are +* not taken into account. +* +* 3) The published orientation and spin components are interpreted +* as "axial vectors". An axial vector points at the pole of the +* rotation and its length is the amount of rotation in radians. +* +* 4) See also sla_FK52H, sla_FK5HZ, sla_HFK5Z. +* +* Reference: +* +* M.Feissel & F.Mignard, Astron. Astrophys. 331, L33-L36 (1998). +* +* P.T.Wallace Starlink 22 June 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RH,DH,DRH,DDH,R5,D5,DR5,DD5 + + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + +* FK5 to Hipparcos orientation and spin (radians, radians/year) + DOUBLE PRECISION EPX,EPY,EPZ + DOUBLE PRECISION OMX,OMY,OMZ + + PARAMETER ( EPX = -19.9D-3 * AS2R, + : EPY = -9.1D-3 * AS2R, + : EPZ = +22.9D-3 * AS2R ) + + PARAMETER ( OMX = -0.30D-3 * AS2R, + : OMY = +0.60D-3 * AS2R, + : OMZ = +0.70D-3 * AS2R ) + + DOUBLE PRECISION PVH(6),ORTN(3),R5H(3,3),S5(3),SH(3),VV(3), + : PV5(6),W,R,V + INTEGER I + + DOUBLE PRECISION sla_DRANRM + + + +* Hipparcos barycentric position/velocity 6-vector (normalized). + CALL sla_DS2C6(RH,DH,1D0,DRH,DDH,0D0,PVH) + +* FK5 to Hipparcos orientation matrix. + ORTN(1) = EPX + ORTN(2) = EPY + ORTN(3) = EPZ + CALL sla_DAV2M(ORTN,R5H) + +* Hipparcos wrt FK5 spin vector. + S5(1) = OMX + S5(2) = OMY + S5(3) = OMZ + +* Rotate the spin vector into the Hipparcos frame. + CALL sla_DMXV(R5H,S5,SH) + +* De-orient & de-spin the 6-vector into FK5 J2000. + CALL sla_DIMXV(R5H,PVH,PV5) + CALL sla_DVXV(PVH,SH,VV) + DO I=1,3 + VV(I) = PVH(I+3)-VV(I) + END DO + CALL sla_DIMXV(R5H,VV,PV5(4)) + +* FK5 6-vector to spherical. + CALL sla_DC62S(PV5,W,D5,R,DR5,DD5,V) + R5 = sla_DRANRM(W) + + END diff --git a/src/slalib/hfk5z.f b/src/slalib/hfk5z.f new file mode 100644 index 0000000..b50d38a --- /dev/null +++ b/src/slalib/hfk5z.f @@ -0,0 +1,122 @@ + SUBROUTINE sla_HFK5Z (RH,DH,EPOCH,R5,D5,DR5,DD5) +*+ +* - - - - - - +* H F K 5 Z +* - - - - - - +* +* Transform a Hipparcos star position into FK5 J2000, assuming +* zero Hipparcos proper motion. +* +* (double precision) +* +* Given: +* RH d Hipparcos RA (radians) +* DH d Hipparcos Dec (radians) +* EPOCH d Julian epoch (TDB) +* +* Returned (all FK5, equinox J2000, epoch EPOCH): +* R5 d RA (radians) +* D5 d Dec (radians) +* +* Called: sla_DCS2C, sla_DAV2M, sla_DMXV, sla_DAV2M, sla_DMXM, +* sla_DIMXV, sla_DVXV, sla_DC62S, sla_DRANRM +* +* Notes: +* +* 1) The proper motion in RA is dRA/dt rather than cos(Dec)*dRA/dt. +* +* 2) The FK5 to Hipparcos transformation consists of a pure +* rotation and spin; zonal errors in the FK5 catalogue are +* not taken into account. +* +* 3) The published orientation and spin components are interpreted +* as "axial vectors". An axial vector points at the pole of the +* rotation and its length is the amount of rotation in radians. +* +* 4) It was the intention that Hipparcos should be a close +* approximation to an inertial frame, so that distant objects +* have zero proper motion; such objects have (in general) +* non-zero proper motion in FK5, and this routine returns those +* fictitious proper motions. +* +* 5) The position returned by this routine is in the FK5 J2000 +* reference frame but at Julian epoch EPOCH. +* +* 6) See also sla_FK52H, sla_H2FK5, sla_FK5ZHZ. +* +* Reference: +* +* M.Feissel & F.Mignard, Astron. Astrophys. 331, L33-L36 (1998). +* +* P.T.Wallace Starlink 22 June 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RH,DH,EPOCH,R5,D5,DR5,DD5 + + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + +* FK5 to Hipparcos orientation and spin (radians, radians/year) + DOUBLE PRECISION EPX,EPY,EPZ + DOUBLE PRECISION OMX,OMY,OMZ + + PARAMETER ( EPX = -19.9D-3 * AS2R, + : EPY = -9.1D-3 * AS2R, + : EPZ = +22.9D-3 * AS2R ) + + PARAMETER ( OMX = -0.30D-3 * AS2R, + : OMY = +0.60D-3 * AS2R, + : OMZ = +0.70D-3 * AS2R ) + + DOUBLE PRECISION PH(6),ORTN(3),R5H(3,3),S5(3),SH(3),T,VST(3), + : RST(3,3),R5HT(3,3),PV5E(6),VV(3),W,R,V + + DOUBLE PRECISION sla_DRANRM + + + +* Hipparcos barycentric position vector (normalized). + CALL sla_DCS2C(RH,DH,PH) + +* FK5 to Hipparcos orientation matrix. + ORTN(1) = EPX + ORTN(2) = EPY + ORTN(3) = EPZ + CALL sla_DAV2M(ORTN,R5H) + +* Hipparcos wrt FK5 spin vector. + S5(1) = OMX + S5(2) = OMY + S5(3) = OMZ + +* Rotate the spin vector into the Hipparcos frame. + CALL sla_DMXV(R5H,S5,SH) + +* Time interval from J2000 to epoch. + T = EPOCH-2000D0 + +* Axial vector: accumulated Hipparcos wrt FK5 spin over that interval. + VST(1) = OMX*T + VST(2) = OMY*T + VST(3) = OMZ*T + +* Express the accumulated spin as a rotation matrix. + CALL sla_DAV2M(VST,RST) + +* Rotation matrix: accumulated spin, then FK5 to Hipparcos. + CALL sla_DMXM(R5H,RST,R5HT) + +* De-orient & de-spin the vector into FK5 J2000 at epoch. + CALL sla_DIMXV(R5HT,PH,PV5E) + CALL sla_DVXV(SH,PH,VV) + CALL sla_DIMXV(R5HT,VV,PV5E(4)) + +* FK5 position/velocity 6-vector to spherical. + CALL sla_DC62S(PV5E,W,D5,R,DR5,DD5,V) + R5 = sla_DRANRM(W) + + END diff --git a/src/slalib/idchf.f b/src/slalib/idchf.f new file mode 100644 index 0000000..2f758bf --- /dev/null +++ b/src/slalib/idchf.f @@ -0,0 +1,94 @@ + SUBROUTINE sla__IDCHF (STRING, NPTR, NVEC, NDIGIT, DIGIT) +*+ +* - - - - - - +* I D C H F +* - - - - - - +* +* Internal routine used by DFLTIN +* +* Identify next character in string +* +* Given: +* STRING char string +* NPTR int pointer to character to be identified +* +* Returned: +* NPTR int incremented unless end of field +* NVEC int vector for identified character +* NDIGIT int 0-9 if character was a numeral +* DIGIT double equivalent of NDIGIT +* +* NVEC takes the following values: +* +* 1 0-9 +* 2 space or TAB !!! n.b. ASCII TAB assumed !!! +* 3 D,d,E or e +* 4 . +* 5 + +* 6 - +* 7 , +* 8 else +* 9 outside field +* +* If the character is not 0-9, NDIGIT and DIGIT are either not +* altered or are set to arbitrary values. +* +* P.T.Wallace Starlink 22 December 1992 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) STRING + INTEGER NPTR,NVEC,NDIGIT + DOUBLE PRECISION DIGIT + + CHARACTER K + INTEGER NCHAR + +* Character/vector tables + INTEGER NCREC + PARAMETER (NCREC=19) + CHARACTER KCTAB(NCREC) + INTEGER KVTAB(NCREC) + DATA KCTAB/'0','1','2','3','4','5','6','7','8','9', + : ' ','D','d','E','e','.','+','-',','/ + DATA KVTAB/10*1,2,4*3,4,5,6,7/ + + +* Handle pointer outside field + IF (NPTR.LT.1.OR.NPTR.GT.LEN(STRING)) THEN + NVEC=9 + ELSE + +* Not end of field: identify the character + K=STRING(NPTR:NPTR) + DO NCHAR=1,NCREC + IF (K.EQ.KCTAB(NCHAR)) THEN + +* Recognized + NVEC=KVTAB(NCHAR) + NDIGIT=NCHAR-1 + DIGIT=DBLE(NDIGIT) + GO TO 2300 + END IF + END DO + +* Not recognized: check for TAB !!! n.b. ASCII assumed !!! + IF (K.EQ.CHAR(9)) THEN + +* TAB: treat as space + NVEC=2 + ELSE + +* Unrecognized + NVEC=8 + END IF + +* Increment pointer + 2300 CONTINUE + NPTR=NPTR+1 + END IF + + END diff --git a/src/slalib/idchi.f b/src/slalib/idchi.f new file mode 100644 index 0000000..56f596f --- /dev/null +++ b/src/slalib/idchi.f @@ -0,0 +1,91 @@ + SUBROUTINE sla__IDCHI (STRING, NPTR, NVEC, DIGIT) +*+ +* - - - - - - +* I D C H I +* - - - - - - +* +* Internal routine used by INTIN +* +* Identify next character in string +* +* Given: +* STRING char string +* NPTR int pointer to character to be identified +* +* Returned: +* NPTR int incremented unless end of field +* NVEC int vector for identified character +* DIGIT double double precision digit if 0-9 +* +* NVEC takes the following values: +* +* 1 0-9 +* 2 space or TAB !!! n.b. ASCII TAB assumed !!! +* 3 + +* 4 - +* 5 , +* 6 else +* 7 outside string +* +* If the character is not 0-9, DIGIT is either unaltered or +* is set to an arbitrary value. +* +* P.T.Wallace Starlink 22 December 1992 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) STRING + INTEGER NPTR,NVEC + DOUBLE PRECISION DIGIT + + CHARACTER K + INTEGER NCHAR + +* Character/vector tables + INTEGER NCREC + PARAMETER (NCREC=14) + CHARACTER KCTAB(NCREC) + INTEGER KVTAB(NCREC) + DATA KCTAB/'0','1','2','3','4','5','6','7','8','9', + : ' ', '+','-',','/ + DATA KVTAB/10*1,2,3,4,5/ + + + +* Handle pointer outside field + IF (NPTR.LT.1.OR.NPTR.GT.LEN(STRING)) THEN + NVEC=7 + ELSE + +* Not end of field: identify character + K=STRING(NPTR:NPTR) + DO NCHAR=1,NCREC + IF (K.EQ.KCTAB(NCHAR)) THEN + +* Recognized + NVEC=KVTAB(NCHAR) + DIGIT=DBLE(NCHAR-1) + GO TO 2300 + END IF + END DO + +* Not recognized: check for TAB !!! n.b. ASCII assumed !!! + IF (K.EQ.CHAR(9)) THEN + +* TAB: treat as space + NVEC=2 + ELSE + +* Unrecognized + NVEC=6 + END IF + +* Increment pointer + 2300 CONTINUE + NPTR=NPTR+1 + END IF + + END diff --git a/src/slalib/imxv.f b/src/slalib/imxv.f new file mode 100644 index 0000000..2aef263 --- /dev/null +++ b/src/slalib/imxv.f @@ -0,0 +1,51 @@ + SUBROUTINE sla_IMXV (RM, VA, VB) +*+ +* - - - - - +* I M X V +* - - - - - +* +* Performs the 3-D backward unitary transformation: +* +* vector VB = (inverse of matrix RM) * vector VA +* +* (single precision) +* +* (n.b. the matrix must be unitary, as this routine assumes that +* the inverse and transpose are identical) +* +* Given: +* RM real(3,3) matrix +* VA real(3) vector +* +* Returned: +* VB real(3) result vector +* +* P.T.Wallace Starlink November 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL RM(3,3),VA(3),VB(3) + + INTEGER I,J + REAL W,VW(3) + + + +* Inverse of matrix RM * vector VA -> vector VW + DO J=1,3 + W=0.0 + DO I=1,3 + W=W+RM(I,J)*VA(I) + END DO + VW(J)=W + END DO + +* Vector VW -> vector VB + DO J=1,3 + VB(J)=VW(J) + END DO + + END diff --git a/src/slalib/intin.f b/src/slalib/intin.f new file mode 100644 index 0000000..a4cee15 --- /dev/null +++ b/src/slalib/intin.f @@ -0,0 +1,176 @@ + SUBROUTINE sla_INTIN (STRING, NSTRT, IRESLT, JFLAG) +*+ +* - - - - - - +* I N T I N +* - - - - - - +* +* Convert free-format input into an integer +* +* Given: +* STRING c string containing number to be decoded +* NSTRT i pointer to where decoding is to start +* IRESLT i current value of result +* +* Returned: +* NSTRT i advanced to next number +* IRESLT i result +* JFLAG i status: -1 = -OK, 0 = +OK, 1 = null, 2 = error +* +* Called: sla__IDCHI +* +* Notes: +* +* 1 The reason INTIN has separate OK status values for + +* and - is to enable minus zero to be detected. This is +* of crucial importance when decoding mixed-radix numbers. +* For example, an angle expressed as deg, arcmin, arcsec +* may have a leading minus sign but a zero degrees field. +* +* 2 A TAB is interpreted as a space. +* +* 3 The basic format is the sequence of fields #^, where +* # is a sign character + or -, and ^ means a string of +* decimal digits. +* +* 4 Spaces: +* +* . Leading spaces are ignored. +* +* . Spaces between the sign and the number are allowed. +* +* . Trailing spaces are ignored; the first signifies +* end of decoding and subsequent ones are skipped. +* +* 5 Delimiters: +* +* . Any character other than +,-,0-9 or space may be +* used to signal the end of the number and terminate +* decoding. +* +* . Comma is recognized by INTIN as a special case; it +* is skipped, leaving the pointer on the next character. +* See 9, below. +* +* 6 The sign is optional. The default is +. +* +* 7 A "null result" occurs when the string of characters being +* decoded does not begin with +,- or 0-9, or consists +* entirely of spaces. When this condition is detected, JFLAG +* is set to 1 and IRESLT is left untouched. +* +* 8 NSTRT = 1 for the first character in the string. +* +* 9 On return from INTIN, NSTRT is set ready for the next +* decode - following trailing blanks and any comma. If a +* delimiter other than comma is being used, NSTRT must be +* incremented before the next call to INTIN, otherwise +* all subsequent calls will return a null result. +* +* 10 Errors (JFLAG=2) occur when: +* +* . there is a + or - but no number; or +* +* . the number is greater than BIG (defined below). +* +* 11 When an error has been detected, NSTRT is left +* pointing to the character following the last +* one used before the error came to light. +* +* 12 See also FLOTIN and DFLTIN. +* +* P.T.Wallace Starlink 27 April 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) STRING + INTEGER NSTRT,IRESLT,JFLAG + +* Maximum allowed value + DOUBLE PRECISION BIG + PARAMETER (BIG=2147483647D0) + + INTEGER JPTR,MSIGN,NVEC,J + DOUBLE PRECISION DRES,DIGIT + + + +* Current character + JPTR=NSTRT + +* Set defaults + DRES=0D0 + MSIGN=1 + +* Look for sign + 100 CONTINUE + CALL sla__IDCHI(STRING,JPTR,NVEC,DIGIT) + GO TO ( 400, 100, 300, 200, 9110, 9100, 9110),NVEC +* 0-9 SP + - , ELSE END + +* Negative + 200 CONTINUE + MSIGN=-1 + +* Look for first decimal + 300 CONTINUE + CALL sla__IDCHI(STRING,JPTR,NVEC,DIGIT) + GO TO ( 400, 300, 9200, 9200, 9200, 9200, 9210),NVEC +* 0-9 SP + - , ELSE END + +* Accept decimals + 400 CONTINUE + DRES=DRES*1D1+DIGIT + +* Test for overflow + IF (DRES.GT.BIG) GO TO 9200 + +* Look for subsequent decimals + CALL sla__IDCHI(STRING,JPTR,NVEC,DIGIT) + GO TO ( 400, 1610, 1600, 1600, 1600, 1600, 1610),NVEC +* 0-9 SP + - , ELSE END + +* Get result & status + 1600 CONTINUE + JPTR=JPTR-1 + 1610 CONTINUE + J=0 + IF (MSIGN.EQ.1) GO TO 1620 + J=-1 + DRES=-DRES + 1620 CONTINUE + IRESLT=NINT(DRES) + +* Skip to end of field + 1630 CONTINUE + CALL sla__IDCHI(STRING,JPTR,NVEC,DIGIT) + GO TO (1720, 1630, 1720, 1720, 9900, 1720, 9900),NVEC +* 0-9 SP + - , ELSE END + + 1720 CONTINUE + JPTR=JPTR-1 + GO TO 9900 + +* Exits + +* Null field + 9100 CONTINUE + JPTR=JPTR-1 + 9110 CONTINUE + J=1 + GO TO 9900 + +* Errors + 9200 CONTINUE + JPTR=JPTR-1 + 9210 CONTINUE + J=2 + +* Return + 9900 CONTINUE + NSTRT=JPTR + JFLAG=J + + END diff --git a/src/slalib/invf.f b/src/slalib/invf.f new file mode 100644 index 0000000..f323228 --- /dev/null +++ b/src/slalib/invf.f @@ -0,0 +1,90 @@ + SUBROUTINE sla_INVF (FWDS,BKWDS,J) +*+ +* - - - - - +* I N V F +* - - - - - +* +* Invert a linear model of the type produced by the +* sla_FITXY routine. +* +* Given: +* FWDS d(6) model coefficients +* +* Returned: +* BKWDS d(6) inverse model +* J i status: 0 = OK, -1 = no inverse +* +* The models relate two sets of [X,Y] coordinates as follows. +* Naming the elements of FWDS: +* +* FWDS(1) = A +* FWDS(2) = B +* FWDS(3) = C +* FWDS(4) = D +* FWDS(5) = E +* FWDS(6) = F +* +* where two sets of coordinates [X1,Y1] and [X2,Y1] are related +* thus: +* +* X2 = A + B*X1 + C*Y1 +* Y2 = D + E*X1 + F*Y1 +* +* the present routine generates a new set of coefficients: +* +* BKWDS(1) = P +* BKWDS(2) = Q +* BKWDS(3) = R +* BKWDS(4) = S +* BKWDS(5) = T +* BKWDS(6) = U +* +* such that: +* +* X1 = P + Q*X2 + R*Y2 +* Y1 = S + T*X2 + U*Y2 +* +* Two successive calls to sla_INVF will thus deliver a set +* of coefficients equal to the starting values. +* +* To comply with the ANSI Fortran standard, FWDS and BKWDS must +* not be the same array, even though the routine is coded to +* work on the VAX and most other computers even if this rule +* is violated. +* +* See also sla_FITXY, sla_PXY, sla_XY2XY, sla_DCMPF +* +* P.T.Wallace Starlink 11 April 1990 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION FWDS(6),BKWDS(6) + INTEGER J + + DOUBLE PRECISION A,B,C,D,E,F,DET + + + + A=FWDS(1) + B=FWDS(2) + C=FWDS(3) + D=FWDS(4) + E=FWDS(5) + F=FWDS(6) + DET=B*F-C*E + IF (DET.NE.0D0) THEN + BKWDS(1)=(C*D-A*F)/DET + BKWDS(2)=F/DET + BKWDS(3)=-C/DET + BKWDS(4)=(A*E-B*D)/DET + BKWDS(5)=-E/DET + BKWDS(6)=B/DET + J=0 + ELSE + J=-1 + END IF + + END diff --git a/src/slalib/kbj.f b/src/slalib/kbj.f new file mode 100644 index 0000000..6a3ddb4 --- /dev/null +++ b/src/slalib/kbj.f @@ -0,0 +1,56 @@ + SUBROUTINE sla_KBJ (JB, E, K, J) +*+ +* - - - - +* K B J +* - - - - +* +* Select epoch prefix 'B' or 'J' +* +* Given: +* JB int sla_DBJIN prefix status: 0=none, 1='B', 2='J' +* E dp epoch - Besselian or Julian +* +* Returned: +* K char 'B' or 'J' +* J int status: 0=OK +* +* If JB=0, B is assumed for E < 1984D0, otherwise J. +* +* P.T.Wallace Starlink 31 July 1989 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER JB + DOUBLE PRECISION E + CHARACTER K*(*) + INTEGER J + +* Preset status + J=0 + +* If prefix given expressly, use it + IF (JB.EQ.1) THEN + K='B' + ELSE IF (JB.EQ.2) THEN + K='J' + +* If no prefix, examine the epoch + ELSE IF (JB.EQ.0) THEN + +* If epoch is pre-1984.0, assume Besselian; otherwise Julian + IF (E.LT.1984D0) THEN + K='B' + ELSE + K='J' + END IF + +* If illegal prefix, return error status + ELSE + K=' ' + J=1 + END IF + + END diff --git a/src/slalib/m2av.f b/src/slalib/m2av.f new file mode 100644 index 0000000..1299ed9 --- /dev/null +++ b/src/slalib/m2av.f @@ -0,0 +1,59 @@ + SUBROUTINE sla_M2AV (RMAT, AXVEC) +*+ +* - - - - - +* M 2 A V +* - - - - - +* +* From a rotation matrix, determine the corresponding axial vector +* (single precision) +* +* A rotation matrix describes a rotation about some arbitrary axis. +* The axis is called the Euler axis, and the angle through which the +* reference frame rotates is called the Euler angle. The axial +* vector returned by this routine has the same direction as the +* Euler axis, and its magnitude is the Euler angle in radians. (The +* magnitude and direction can be separated by means of the routine +* sla_VN.) +* +* Given: +* RMAT r(3,3) rotation matrix +* +* Returned: +* AXVEC r(3) axial vector (radians) +* +* The reference frame rotates clockwise as seen looking along +* the axial vector from the origin. +* +* If RMAT is null, so is the result. +* +* P.T.Wallace Starlink 11 April 1990 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL RMAT(3,3),AXVEC(3) + + REAL X,Y,Z,S2,C2,PHI,F + + + + X = RMAT(2,3)-RMAT(3,2) + Y = RMAT(3,1)-RMAT(1,3) + Z = RMAT(1,2)-RMAT(2,1) + S2 = SQRT(X*X+Y*Y+Z*Z) + IF (S2.NE.0.0) THEN + C2 = (RMAT(1,1)+RMAT(2,2)+RMAT(3,3)-1.0) + PHI = ATAN2(S2/2.0,C2/2.0) + F = PHI/S2 + AXVEC(1) = X*F + AXVEC(2) = Y*F + AXVEC(3) = Z*F + ELSE + AXVEC(1) = 0.0 + AXVEC(2) = 0.0 + AXVEC(3) = 0.0 + END IF + + END diff --git a/src/slalib/makefile.orig b/src/slalib/makefile.orig new file mode 100644 index 0000000..ff61e16 --- /dev/null +++ b/src/slalib/makefile.orig @@ -0,0 +1,1426 @@ +#+ +# Name: +# makefile +# +# Version: +# Library makefile Mk V +# +# Purpose: +# Build and install the SLALIB package. +# +# Type of Module: +# Description file for the make utility. +# +# Description: +# This description file is used by the make utility to build the +# SLALIB package from the distributed source files, to install +# the resulting system for use, and to perform other housekeeping +# tasks. +# +# Invocation: +# This makefile is not intended to be used by make when invoked +# directly (although this is possible), but instead to be used via +# the accompanying mk script. This script sets up a number of +# environment variables which are used as macros within the +# makefile and which accommodate differences between machines and +# operating systems (it invokes make with the -e option). Please +# consult the mk script prologue for full details. +# +# Targets: +# The following make targets are defined in this script for +# external use: +# +# [help] +# This is the default target. It outputs a message describing +# the mk script and lists the targets provided. +# +# check +# Performs a simple check that all necessary source files are +# present, and displays the version number and current state +# of the package (built/installed/tested, etc.). +# +# build +# Compiles the source files and creates all files needed +# prior to installing the package for use. +# +# install +# Installs the package for use by putting the necessary files +# into sub-directories of the $INSTALL directory (the $HOME +# directory is used if the environment variable INSTALL is +# not defined). Links to the installed files are left in the +# source directory. +# +# deinstall +# Reverses the action of the install target, removing files +# from sub-directories of the $INSTALL directory and +# restoring them to the source directory (the $HOME directory +# is used by default if the environment variable INSTALL is +# not defined). +# +# test +# Builds and runs a simple test program to check for correct +# installation of the package. +# +# export +# Produces an export copy of the built package suitable for +# passing to another user. A compressed tar file is created +# in the $EXPORT directory containing copies of the source +# files and built files for the package (the current +# directory is used by default if the environment variable +# EXPORT is not defined). The package should normally be +# built, installed and tested (see above) before using this +# target. After unpacking the exported file on a similar +# machine, the recipient may simply install it for use. +# +# export_run +# Produces an export copy of the built package suitable for +# passing to another user. A compressed tar file is created +# in the $EXPORT directory containing copies of the built +# files for the package (the current directory is used by +# default if the environment variable EXPORT is not defined). +# The package should normally be built, installed and tested +# (see above) before using this target. After unpacking the +# exported file on a similar machine, the recipient may simply +# install it for use. +# +# export_source +# Produces an export copy of the source for the package +# suitable for passing to another user to build (possibly on +# a different type of machine). A compressed tar file is +# created in the $EXPORT directory containing copies of just +# the source files for the package (the current directory is +# used by default if the environment variable EXPORT is not +# defined). After unpacking the exported file, the recipient +# must build the package before installing it for use. +# +# clean +# Cleans up after building the package, removing all +# intermediate files created during the building process, but +# leaving the built files themselves. +# +# unbuild +# Reverses the building process, removing all intermediate +# files along with all the built files. +# +# External Dependencies: +# The SLALIB package depends on the following other Starlink +# packages which must previously have been installed into the +# appropriate sub-directories of the $STARLINK directory (/star is +# used if the environment variable STARLINK is not defined). +# +# None. +# +# Notes: +# This makefile uses the presence/absence of the hidden files +# .BUILT, .INSTALLED_$(SYSTEM) and .TESTED_$(SYSTEM) to record the +# current state of the system during housekeeping operations. +# +# Implementation Deficiencies: +# The method of generating the list of external libraries passed to +# the $(BLD_SHR) command is still preliminary. +# +# Copyright: +# Copyright (C) 1995 Rutherford Appleton Laboratory +# +# Authors: +# RFWS: R.F.Warren-Smith (Starlink, RAL) +# PMA: P.M.Allan (Starlink, RAL) +# PTW: P.T.Wallace (Starlink, RAL) +# AJC: A.J.Chipperfield (Starlink, RAL) +# BLY: M.J.Bly (Starlink, RAL) +# {enter_new_authors_here} +# +# History: +# 1-DEC-1993 (RFWS/PMA): +# Starlink template. +# 1-DEC-1993 (PTW): +# SLALIB version. +# 18-JAN-1994 (PTW): +# Corrections to if statements. +# 10-MAR-1994 (PTW): +# sla_RVLSR replaced by sla_RVLSRD and sla_RVLSRK +# 8-AUG-1994 (PTW): +# New routines added: sla_DE2H, sla_DH2E, sla_DTPRD, sla_E2H, +# sla_H2E, sla_PRECL, sla_TPRD. Version number changed to 1.3-4. +# Missing dependencies on source archive added. +# 19-OCT-1994 (PTW): +# New routines added: sla_ALTAZ, sla_PDA2H, sla_PDQ2H. Package +# version number changed to 1.4-1. Library version number +# changed to 1.4. +# 26-OCT-1994 (PTW): +# Package version number changed to 1.4-2. +# 15-DEC-1994 (PTW): +# New routines added: sla_PLANET, sla_RDPLAN, sla_DMOON, sla_DT, +# sla_CLYD. Package version number changed to 1.4-4. +# 3-JAN-1995 (PTW): +# Package version number changed to 1.4-5. +# 13-FEB-1995 (PTW): +# New routines added: sla_DTP2V, sla_DTPXYZ, sla_DV2TP, sla_TP2V, +# sla_TPXYZ, sla_V2TP. Package version number changed to 1.4-6. +# 20-FEB-1995 (PTW): +# Package version number changed to 1.4-7 (sla_OBS enhanced). +# 23-MAR-1995 (PTW): +# Unnecessary creation of INSTALL_INC removed. +# 05-JUN-1995 (PTW): +# Four routines replaced: sla_DTPRD, sla_DTPXYZ, sla_TPRD and +# sla_TPXYZ become sla_DTPS2C, sla_DTPXYZ, sla_TPS2C and sla_TPV2C. +# Package version number changed to 1.5-1. Library version +# number changed to 1.5. +# 06-JUN-1995 (BLY/AJC): +# Updated to match Mk IVa makefile standard. +# 02-JUL-1995 (PTW): +# Package version number changed to 1.5-2. +# 21-JUL-1995 (PTW): +# Package version number changed to 1.5-3. +# 14-SEP-1995 (PTW): +# New routine added: sla_GMSTA. +# Package version number changed to 1.6-1. +# 04-OCT-1995 (PTW): +# New routine added: sla_ATMDSP. +# Package version number changed to 1.6-2. +# 14-NOV-1995 (PTW): +# Bug fix: sla_DAT. +# Package version number changed to 1.6-3. +# 21-FEB-1996 (PTW): +# New routine: sla_POLMO. +# Bug fix: sla_DC62S, sla_CC62S. +# Comment corrections: sla_DH2E, sla_H2E. +# New, html-compatible, document: SUN/67.34. +# Package version number changed to 1.6-4. +# 04-MAR-1996 (BLY): +# Update makefile to Mk V specification. +# Add special HLINK macro definitions. +# No change to version number. +# 24-APR-1996 (BLY): +# Integrate ix86_Linux version. +# Update version to v1.7-0. +# 10-MAY-1996 (BLY): +# Update version to v1.7-1. No changes to Fortran version. +# 18-JUL-1996 (PTW): +# Comment corrections: sla_DS2TP, sla_DV2TP, sla_S2TP, sla_V2TP +# New, html-compatible, document: SUN/67.34. +# Package version number changed to 1.7-2. +# 26-NOV-1996 (PTW): +# Minor corrections to sla_DV2TP and sla_V2TP. In sla_OBS, +# revision of Parkes position and addition of ATNF Mopra. +# Package version number changed to 1.7-3. +# 28-MAY-1997 (PTW): +# New routines: sla_PLANEL, sla_PLANTE. +# Functionally enhanced: sla_PLANET, sla_RDPLAN. +# Minor code improvements: several. +# Comment corrections: numerous. +# Revised document: SUN/67.36. +# Package version number changed to 2.0-1. +# 6-JAN-1998 (PTW): +# Functionally enhanced: sla_DAT. +# Revised document: SUN/67.38. +# Package version number changed to 2.0-3. +# 15-APR-1998 (PTW): +# Code improvements: sla_GMSTA. +# Revised document: SUN/67.40. +# Package version number changed to 2.0-4. +# 28-MAY-1998 (PTW): +# Code improvements: sla_PLANEL. +# New routine: sla_PV2EL +# Revised document: SUN/67.41. +# Package version number changed to 2.1-0. +# 14-JUL-1998 (PTW): +# Makefile updated - sla_PAV had been omitted. +# 18-JUL-1998 (PTW): +# 1999 January 1 leap second added to sla_DAT. +# Package version number changed to 2.1-1. +# 11-AUG-1998 (PTW): +# Makefile updated - sla_DPAV had been omitted (!). +# 30-SEP-1998 (PTW): +# New routines: sla_FK52H, sla_H2FK5, sla_FK5HZ and sla_HFK5Z. +# Revised document: SUN/67.43. +# Package version number changed to 2.2-0. +# 19-MAR-1999 (PTW): +# New routines: sla_EL2UE, sla_PERTEL, sla_PERTUE, +# sla_PV2UE, sla_UE2EL and sla_UE2PV +# Revised document: SUN/67.44. +# Package version number changed to 2.3-0. +# 2-AUG-1999 (PTW): +# New routines: sla_COMBN and sla_PERMUT +# Revised document: SUN/67.45. +# Package version number changed to 2.4-0. +# 29-OCT-1999 (PTW): +# The F_ROUTINES definition lacked entries for sla_EL2UE, +# sla_PERTEL, sla_PERTUE, sla_PV2UE, sla_UE2EL, sla_UE2PV, +# sla_COMBN and sla_PERMUT. +# {enter_further_changes_here} +# +# Bugs: +# {note_any_bugs_here} +# +#------------------------------------------------------------------------------- + +# Help target. +# =========== +# +# This is the default target, so it appears first. + +# Display information about the mk script and the make targets. + +help: + @ echo \ + ' The makefile provided is intended to be used by the make utility when';\ + echo \ + ' invoked via the associated mk script. This script defines environment';\ + echo \ + ' variables which are used by make to accommodate differing machine and';\ + echo \ + ' operating system characteristics. Please see the mk script prologue';\ + echo \ + ' for full details.';\ + echo;\ + echo \ + ' The following targets are provided:';\ + echo;\ + echo \ + ' help - Display this message';\ + echo \ + ' check - Check source file presence and show current state';\ + echo \ + ' build - Build the package from source';\ + echo \ + ' install - Install the built package for use';\ + echo \ + ' deinstall - Deinstall the package';\ + echo \ + ' test - Perform a quick test of the installation';\ + echo \ + ' export - Make a compressed tar file for exporting the'\ + 'built package';\ + echo \ + ' complete with source and documentation';\ + echo \ + ' export_run - Make a compressed tar file for exporting the'\ + 'built package';\ + echo \ + ' with documentation but no source';\ + echo \ + ' export_source - Make a compressed tar file for exporting the'\ + 'source files';\ + echo \ + ' clean - Tidy up after building the package';\ + echo \ + ' unbuild - Remove all the built files';\ + echo;\ + echo \ + ' To build and install the $(PACK_NAME) package on a supported system:';\ + echo;\ + echo \ + ' mk build; mk install; mk test; mk clean';\ + echo + +#------------------------------------------------------------------------------- + +# Defaults. +# ======== +# +# This section defines default macros and should rarely need changing. +# The values given here should be overridden externally to adapt to +# the local system setup (either use the mk script or use environment +# variables and invoke "make" with the "-e" option). + +# Name of computer hardware/OS combination. + +SYSTEM = unknown + +# Name used to distinguish platform-specific source files. + +SOURCE_VARIANT = $(SYSTEM) + +# Pathname of the root directory beneath which other Starlink software +# is currently installed. + +STARLINK = /star + +# Pathnames of Starlink sub-directories that may be referenced when +# building this package. + +STAR_BIN = $(STARLINK)/bin +STAR_DATES = $(STARLINK)/dates +STAR_DOCS = $(STARLINK)/docs +STAR_ETC = $(STARLINK)/etc +STAR_HELP = $(STARLINK)/help +STAR_INC = $(STARLINK)/include +STAR_LIB = $(STARLINK)/lib + +# Pathname of the root directory beneath which the built files for +# this package should be installed for use. This defaults to the +# user's home directory. + +INSTALL = $(HOME) + +# Pathname of the directory into which exported tar files will be +# placed. This defaults to the current working directory. + +EXPORT = . + +# Default macros for compiling C and Fortran source code. + +CC = c89 +CFLAGS = -O +FC = fort77 +FFLAGS = -O + +# Command for forming a link to a file. + +LINK = ln + +# Command for "randomizing" an object library. The default acts as a +# null command. + +RANLIB = : + +# Commands for adding to and extracting from an archive file (.tar). + +TAR_IN = pax -w -v -x ustar -f +TAR_OUT = pax -r -f + +# Command for adding a file to an object archive (.a). + +AR_IN = ar -r + +# Default file type extension for a shareable library and command for +# building a shareable library (the default acts as a null command). + +SHARE = .so +BLD_SHR = : + +# Default command for linking hypertext document to others, including those +# on the RAL document server. + +HLINK = : + +#------------------------------------------------------------------------------- +################################################################################ +# +# Define package source files. +# =========================== +# +# This section defines the set of source files for the package. + +# Name of the package as specified in documentation +# The value is used in messages from make to the user. + +PACK_NAME = SLALIB + +# Prefix for the package in lower-case as used in filenames etc. +PKG_NAME = sla + +# Prefix for the package in upper-case as used in include file links. +PKG_LINK = SLA + +# Version number (as in the documentation - i.e. not the same thing +# as the shared library version number). +# +# The major component of the version number (before the dot) should +# normally only be incremented following major changes to the package. +# The minor version number (after the dot) is the number normally +# incremented following development which introduces new documented +# functionality. Any revision number (appended after a dash) should +# be incremented for other minor changes (bug fixes, etc.) which do +# not merit documentation changes. + +PKG_VERS = 2.4-0 + +# Library version number. +# +# n.b. Care needed - may affect existing applications. +# +# The minor component of this number (following the dot) should be +# incremented whenever a new routine is added to a library or some +# other change is made such that programs built with the latest +# version would fail to run using an earlier version. The major number +# should be incremented if a change is made such that existing +# programs would have to be re-built in order to work with the new +# version. + +LIB_VERS = 1.6 + +# List of files comprising the distributed source-only system. This +# defines the minimum set of files required to rebuild completely the +# package from source (including this makefile, the associated mk +# script and any documentation files). + +SOURCE_FILES = $(PKG_NAME)_source.tar makefile mk $(DOCUMENTATION) + +# List of public script files. These are scripts which form part of +# the package and will be required by users of it. They will be +# installed in the $(INSTALL_BIN) directory with execute permission +# set. + +PUBLIC_SCRIPTS = $(PKG_NAME)_link $(PKG_NAME)_link_adam + +# Startup script. This is the file that must be executed by a +# programmer using this package in order to define links to include +# files. It is listed separately from the public scripts as it is +# edited by the installation procedure. + +STARTUP_SCRIPT = + +# List of public include files. These are include files which form +# part of the package and may be required by users of it. They will be +# installed in the $(INSTALL_INC) directory. + +PUBLIC_INCLUDES = + +# List of private include files. These are additional include files +# which form part of the package and are required in order to build +# it, but which are not required by users of it. + +PRIVATE_INCLUDES = + +# List of external include files. These are files which are required +# in order to build the package but form part of other, externally +# installed packages. This list should contain the names used to +# reference the files within the source code, not the actual names of +# the files. + +EXTERNAL_INCLUDES = + +# List of Fortran routines required for building the package. This is +# just a list of all the Fortran source files (excluding BLOCK DATA +# routines, which are treated separately). + +F_ROUTINES = \ + addet.f \ + afin.f \ + airmas.f \ + altaz.f \ + amp.f \ + ampqk.f \ + aop.f \ + aoppa.f \ + aoppat.f \ + aopqk.f \ + atmdsp.f \ + atms.f \ + atmt.f \ + av2m.f \ + bear.f \ + caf2r.f \ + caldj.f \ + calyd.f \ + cc2s.f \ + cc62s.f \ + cd2tf.f \ + cldj.f \ + clyd.f \ + combn.f \ + cr2af.f \ + cr2tf.f \ + cs2c.f \ + cs2c6.f \ + ctf2d.f \ + ctf2r.f \ + daf2r.f \ + dafin.f \ + dat.f \ + dav2m.f \ + dbear.f \ + dbjin.f \ + dc62s.f \ + dcc2s.f \ + dcmpf.f \ + dcs2c.f \ + dd2tf.f \ + de2h.f \ + deuler.f \ + dfltin.f \ + dh2e.f \ + dimxv.f \ + djcal.f \ + djcl.f \ + dm2av.f \ + dmat.f \ + dmoon.f \ + dmxm.f \ + dmxv.f \ + dpav.f \ + dr2af.f \ + dr2tf.f \ + drange.f \ + dranrm.f \ + ds2c6.f \ + ds2tp.f \ + dsep.f \ + dt.f \ + dtf2d.f \ + dtf2r.f \ + dtp2s.f \ + dtp2v.f \ + dtps2c.f \ + dtpv2c.f \ + dtt.f \ + dv2tp.f \ + dvdv.f \ + dvn.f \ + dvxv.f \ + e2h.f \ + earth.f \ + ecleq.f \ + ecmat.f \ + ecor.f \ + eg50.f \ + el2ue.f \ + epb.f \ + epb2d.f \ + epco.f \ + epj.f \ + epj2d.f \ + eqecl.f \ + eqeqx.f \ + eqgal.f \ + etrms.f \ + euler.f \ + evp.f \ + fitxy.f \ + fk425.f \ + fk45z.f \ + fk524.f \ + fk52h.f \ + fk54z.f \ + fk5hz.f \ + flotin.f \ + galeq.f \ + galsup.f \ + ge50.f \ + geoc.f \ + gmst.f \ + gmsta.f \ + h2e.f \ + h2fk5.f \ + hfk5z.f \ + idchf.f \ + idchi.f \ + imxv.f \ + intin.f \ + invf.f \ + kbj.f \ + m2av.f \ + map.f \ + mappa.f \ + mapqk.f \ + mapqkz.f \ + moon.f \ + mxm.f \ + mxv.f \ + nut.f \ + nutc.f \ + oap.f \ + oapqk.f \ + obs.f \ + pa.f \ + pav.f \ + pcd.f \ + pda2h.f \ + pdq2h.f \ + permut.f \ + pertel.f \ + pertue.f \ + planel.f \ + planet.f \ + plante.f \ + pm.f \ + polmo.f \ + prebn.f \ + prec.f \ + precl.f \ + preces.f \ + prenut.f \ + pv2el.f \ + pv2ue.f \ + pvobs.f \ + pxy.f \ + range.f \ + ranorm.f \ + rcc.f \ + rdplan.f \ + refco.f \ + refro.f \ + refv.f \ + refz.f \ + rverot.f \ + rvgalc.f \ + rvlg.f \ + rvlsrd.f \ + rvlsrk.f \ + s2tp.f \ + sep.f \ + smat.f \ + subet.f \ + supgal.f \ + svd.f \ + svdcov.f \ + svdsol.f \ + tp2s.f \ + tp2v.f \ + tps2c.f \ + tpv2c.f \ + ue2el.f \ + ue2pv.f \ + unpcd.f \ + v2tp.f \ + vdv.f \ + vn.f \ + vxv.f \ + xy2xy.f \ + zd.f + +# List of Fortran BLOCK DATA routines. + +BLOCK_DATA = + +# List of platform specific Fortran routines. The source tar file will +# contain a version of these files for each set of platforms. The names +# given here are the general version of the file, e.g. pkg_open.f. The +# names in the tar file will be pkg_open.f_sun4, pkg_open.f_mips, etc. + +PLATFORM_F = \ + gresid.f \ + random.f \ + wait.f + +# C routines required for building the package. This is just a list of +# all the C source files. + +C_ROUTINES = + +# Lists of Latex and hypertext documents. + +LATEX_DOCS = sun67.tex +HYPERTEXT_DOCS = sun67.htx + +# List of documentation files. + +DOCUMENTATION = $(LATEX_DOCS) $(HYPERTEXT_DOCS:.htx=.htx_tar) \ +$(PKG_NAME).news read.me + +################################################################################ +#------------------------------------------------------------------------------- + +# Define files required for building the package. +# ============================================== +# +# This section defines the set of files produced from the source files +# when the package is built and installed. + +# Use only .o, .c and .f suffix rules. + +.SUFFIXES: +.SUFFIXES: .o .c .f + +# List of files which must be built from the source files before the +# package can be installed for use. This should comprise all the files +# that are required to use the package (but excluding the date stamp +# file). + +BUILT_FILES = $(PUBLIC_SCRIPTS) $(PUBLIC_INCLUDES) $(OBJECT_LIBRARIES) \ +$(SHAREABLE_LIBRARIES) $(STARTUP_SCRIPT) + +# List of links used to access include files during compilation. This +# should comprise all the external include files and any other include +# files whose names do not exactly match the names used in the source +# code. + +INCLUDE_LINKS = $(EXTERNAL_INCLUDES) + +# Rules to set up links to locate each of the above include files. + +# Rules for extracting source files from the source archive. + +$(PUBLIC_SCRIPTS) $(PUBLIC_INCLUDES) $(F_ROUTINES) \ +$(BLOCK_DATA) $(C_ROUTINES) $(STARTUP_SCRIPT): + $(TAR_OUT) $(PKG_NAME)_source.tar $@ + @ if test -f $@; then :;\ + else echo $@ is not in the tar file; exit 1; fi + +# Rules for extracting platform specific source files from the source +# archive. + +# It is quite likely that there are no platform-specific source files +# and that the macro PLATFORM_F is empty. To prevent a syntax error in +# make, a dummy target is present. + +$(PLATFORM_F) dummy_target1: + $(TAR_OUT) $(PKG_NAME)_source.tar $@_$(SOURCE_VARIANT) + @ if test -f $@_$(SOURCE_VARIANT); then :;\ + else echo $@_$(SOURCE_VARIANT) is not in the tar file; exit 1; fi + mv $@_$(SOURCE_VARIANT) $@ + +# List of object files produced by compiling the source code and rules +# for performing the compilations. + +OBJECT_FILES = $(BLOCK_DATA:.f=.o) $(F_ROUTINES:.f=.o) \ + $(PLATFORM_F:.f=.o) $(C_ROUTINES:.c=.o) + +.c.o: + $(CC) $(CFLAGS) -c $< +.f.o: + $(FC) $(FFLAGS) -c $< + +# List of object library files to be built and rules for building +# them. + +OBJECT_LIBRARIES = lib$(PKG_NAME).a + +lib$(PKG_NAME).a: $(OBJECT_FILES) + $(AR_IN) $@ $? + $(RANLIB) $@ + +# List of shareable library files to be built and rules for building +# them. The third argument to $(BLD_SHR) should provide the information +# necessary to link any libraries called by this package. + +SHAREABLE_LIBRARIES = lib$(PKG_NAME)$(SHARE) + +lib$(PKG_NAME)$(SHARE): $(OBJECT_FILES) + touch $@ + $(BLD_SHR) $@ '$(OBJECT_FILES)' + +# Name of the date stamp file. This is used to record the time of the +# most recent build for use in subsequent operations that require it. +# There must be no rule for generating this file; it is updated only +# as a side effect of building the package. + +DATE_STAMP = $(PKG_NAME)_datestamp + +# Pathnames of directories into which files may be placed when the +# package is installed. + +INSTALL_BIN = $(INSTALL)/bin +INSTALL_DATES = $(INSTALL)/dates +INSTALL_DOCS = $(INSTALL)/docs +INSTALL_ETC = $(INSTALL)/etc +INSTALL_HELP = $(INSTALL)/help +INSTALL_INC = $(INSTALL)/include +INSTALL_LIB = $(INSTALL)/lib +INSTALL_SHARE = $(INSTALL)/share + +# List of directories actually used for installation (selected from +# those above) and rules to create them. + +INSTALL_DIRS = $(INSTALL_BIN) $(INSTALL_DATES) $(INSTALL_DOCS) $(INSTALL_LIB) \ +$(INSTALL_SHARE) + +$(INSTALL_DIRS): + mkdir -p $@ + +#------------------------------------------------------------------------------- + +# Primary targets. +# =============== +# +# These are the targets intended for normal external use (apart from +# help, which appears at the start of the file). + +# check: Check source file presence and show current state. +# -------------------------------------------------------- + +check: + @ echo + @ echo \ + '*** This is $(PACK_NAME) version V$(PKG_VERS) on system $(SYSTEM)' + @ echo + @ nosource='';\ + for f in $(SOURCE_FILES); do \ + if test ! -f $$f; then \ + nosource='1';\ + break;\ + else :; fi;\ + done;\ + if test -n "$$nosource"; then \ + echo ' Source files are NOT present';\ + else \ + echo ' All essential source files are present';\ + fi + @ echo +# +# Display the current state. + @ if test -f .BUILT;\ + then echo ' The package is currently: built for system'\ + `cat .BUILT`;\ + else echo ' The package is currently: not built';fi + @ if test -f .INSTALLED_$(SYSTEM);\ + then echo ' installed in'\ + `cat .INSTALLED_$(SYSTEM)`;\ + else echo ' not installed';fi + @ if test -f .TESTED_$(SYSTEM);\ + then echo ' tested';\ + else echo ' not tested';fi + @ echo + @ if test -f .BUILT;\ + then if test "$(SYSTEM)" != "`cat .BUILT`";\ + then echo '*** WARNING ***';\ + echo \ +' The package is built for a system other than the current one';\ + echo ;\ + else :;fi;\ + else :;fi + +# build: Build the system. +# ----------------------- +# +# Compile the source and build the required files in the source +# directory. + +# The build target first checks that the package is not installed. If +# not, it then causes the .BUILT target to be made which ensures that +# the package has been built. + +build: + @ if test -f .INSTALLED_$(SYSTEM); then \ + echo;\ + echo \ + '*** The $(PACK_NAME) package is currently installed -- please use the';\ + echo ' "deinstall" target before re-building it';\ + echo;\ + elif $(MAKE) .BUILT; then \ + echo;\ + echo '*** The $(PACK_NAME) package has been built';\ + echo;\ + else \ + echo;\ + echo '*** "make" failed building the $(PACK_NAME) package';\ + echo;\ + exit 1;\ + fi + +# The .BUILT target records the time of the most recent build which +# modified any of the built files. It depends on all the built files +# being up to date (which causes them to be built). + +.BUILT: $(BUILT_FILES) +# +# Enter information about the current machine and build environment +# into the date stamp file. + @ echo 'Package : $(PACK_NAME)' >$(DATE_STAMP) + @ echo 'Version : V$(PKG_VERS)' >>$(DATE_STAMP) + @ echo 'Library : V$(LIB_VERS)' >>$(DATE_STAMP) + @ echo '' >>$(DATE_STAMP) + @ echo "Built by: $(USER) on node `uname -n`" \ + >>$(DATE_STAMP) + @ echo "On : `date`" >>$(DATE_STAMP) + @ echo '' >>$(DATE_STAMP) + @ echo \ + "Machine : `uname -m` running `uname -s` `uname -v` (release `uname -r`)" \ + >>$(DATE_STAMP) + @ echo '' >>$(DATE_STAMP) + @ echo 'make macros:' >>$(DATE_STAMP) + @ echo '' >>$(DATE_STAMP) + @ echo ' SYSTEM : $(SYSTEM)' >>$(DATE_STAMP) + @ echo '' >>$(DATE_STAMP) + @ echo ' EXPORT : $(EXPORT)' >>$(DATE_STAMP) + @ echo ' INSTALL : $(INSTALL)' >>$(DATE_STAMP) + @ echo ' STARLINK: $(STARLINK)' >>$(DATE_STAMP) + @ echo '' >>$(DATE_STAMP) + @ echo ' AR_IN : $(AR_IN)' >>$(DATE_STAMP) + @ echo ' BLD_SHR : $(BLD_SHR)' >>$(DATE_STAMP) + @ echo ' CC : $(CC)' >>$(DATE_STAMP) + @ echo ' CFLAGS : $(CFLAGS)' >>$(DATE_STAMP) + @ echo ' FC : $(FC)' >>$(DATE_STAMP) + @ echo ' FFLAGS : $(FFLAGS)' >>$(DATE_STAMP) + @ echo ' LINK : $(LINK)' >>$(DATE_STAMP) + @ echo ' RANLIB : $(RANLIB)' >>$(DATE_STAMP) + @ echo ' SHARE : $(SHARE)' >>$(DATE_STAMP) + @ echo ' SOURCE_VARIANT: $(SOURCE_VARIANT)' \ + >>$(DATE_STAMP) + @ echo ' TAR_IN : $(TAR_IN)' >>$(DATE_STAMP) + @ echo ' TAR_OUT : $(TAR_OUT)' >>$(DATE_STAMP) + @ echo '' >>$(DATE_STAMP) +# +# Record completion of the build. + @ echo '$(SYSTEM)' > .BUILT + +# install: Install the package for use. +# ------------------------------------ +# +# Copy the built files to their installation directories, from where +# they may be accessed. + +# The install target first checks if any part of the package is +# already installed. If not, it checks that the system is built for this +# SYSTEM and, if it is, causes the .INSTALLED_$(SYSTEM) target to be made +# which performs the installation. + +install: + @ if test -f .INSTALLED_$(SYSTEM); then \ + echo;\ + echo \ + '*** The $(PACK_NAME) package has already been installed -- please use the';\ + echo \ + ' "deinstall" target first if you wish to reinstall it';\ + echo;\ + elif test -f .BUILT; then \ + if test "`cat .BUILT`" = "$(SYSTEM)"; then \ + if $(MAKE) .INSTALLED_$(SYSTEM); then \ + echo;\ + echo \ + '*** The $(PACK_NAME) package has been installed in directory $(INSTALL)';\ + echo;\ + else \ + echo;\ + echo \ + '*** "make" failed installing the $(PACK_NAME) package in directory $(INSTALL)';\ + echo;\ + exit 1;\ + fi;\ + else \ + echo;\ + echo \ + "*** The $(PACK_NAME) package is built for system `cat .BUILT` -"\ + 'so cannot be installed on system $(SYSTEM)';\ + echo;\ + exit 1;\ + fi;\ + else \ + echo;\ + echo \ + '*** The $(PACK_NAME) package is not built, so cannot be installed';\ + echo;\ + exit 1;\ + fi + +# The .INSTALLED_$(SYSTEM) target copies each file from the source +# directory using "cp -p" to preserve its date, and replaces each +# original file by a link to the installed copy. + +.INSTALLED_$(SYSTEM): $(INSTALL_DIRS) +# +# Create .INSTALLED_$(SYSTEM), containing $INSTALL, to record that the +# package is installed (at least in part). + @ echo $(INSTALL) > .INSTALLED_$(SYSTEM) +# +# Install the public scripts, giving them world execute permission. + for f in $(PUBLIC_SCRIPTS) ""; do \ + if test -n "$$f"; then \ + cp -p $$f $(INSTALL_BIN);\ + chmod 755 $(INSTALL_BIN)/$$f;\ + rm -f $$f;\ + $(LINK) $(INSTALL_BIN)/$$f $$f;\ + else :; fi;\ + done +# +# Install the public include files, giving them world read permission. + for f in $(PUBLIC_INCLUDES) ""; do \ + if test -n "$$f"; then \ + cp -p $$f $(INSTALL_INC);\ + chmod 644 $(INSTALL_INC)/$$f;\ + rm -f $$f;\ + $(LINK) $(INSTALL_INC)/$$f $$f;\ + else :; fi;\ + done +# +# Install the object libraries, giving them world read permission. + for f in $(OBJECT_LIBRARIES) ""; do \ + if test -n "$$f"; then \ + cp -p $$f $(INSTALL_LIB);\ + chmod 644 $(INSTALL_LIB)/$$f;\ + rm -f $$f;\ + $(LINK) $(INSTALL_LIB)/$$f $$f;\ + else :; fi;\ + done +# +# Install shareable libraries, giving them read permission (unless +# they are dummy, zero size, files in which case they are left in +# place). + for f in $(SHAREABLE_LIBRARIES) ""; do \ + if test -n "$$f" -a -s "$$f"; then \ + cp -p $$f $(INSTALL_SHARE);\ + chmod 755 $(INSTALL_SHARE)/$$f;\ + rm -f $$f;\ + $(LINK) $(INSTALL_SHARE)/$$f $$f;\ + else :; fi;\ + done +# +# Install the package startup script. The name of the directory +# containing the installed public include files must be edited into +# this, and execute permission given. Leave the original file in +# place. + if test -n "$(STARTUP_SCRIPT)"; then \ + sed -e 's#LINK#$(LINK)#' -e s#INSTALL_INC#$(INSTALL_INC)# \ + $(STARTUP_SCRIPT) >$(INSTALL_BIN)/$(STARTUP_SCRIPT) ;\ + chmod 755 $(INSTALL_BIN)/$(STARTUP_SCRIPT) ;\ + else :; fi +# +# Install the Latex documentation, giving it world read permission, +# leaving the source copy in place. + for f in $(LATEX_DOCS) ""; do \ + if test -n "$$f"; then \ + cp -p $$f $(INSTALL_DOCS);\ + chmod 644 $(INSTALL_DOCS)/$$f;\ + else :; fi;\ + done +# +# Install any hypertext documents, giving world read access to all the files +# they contain and linking with other documents. + if test -n "$(HYPERTEXT_DOCS)"; then \ + pwd=`pwd`;\ + (cd $(INSTALL_DOCS);\ + for f in $(HYPERTEXT_DOCS) ""; do \ + if test -n "$$f"; then\ + $(TAR_OUT) $$pwd/$${f}_tar;\ + chmod 755 `find $$f -type d -print`;\ + chmod 644 `find $$f ! -type d -print`;\ + touch $$f;\ + else :; fi;\ + done);\ + HTX_PATH='$(STAR_DOCS):$(STAR_HELP)';\ + export HTX_PATH;\ + $(HLINK) $(INSTALL_DOCS) $(INSTALL_HELP);\ + fi; +# +# Install the date stamp file and make it read-only to prevent its +# date being changed. + cp -p $(DATE_STAMP) $(INSTALL_DATES) + chmod 444 $(INSTALL_DATES)/$(DATE_STAMP) + chmod 644 $(DATE_STAMP) + rm $(DATE_STAMP) + $(LINK) $(INSTALL_DATES)/$(DATE_STAMP) $(DATE_STAMP) + +# deinstall: Deinstall the package. +# -------------------------------- +# +# Reverse the action of the install target, removing the installed +# files and returning them to the source directory. + +# The deinstall target checks that the package is installed in the INSTALL +# directory. If so, it causes the do_deinstall target to be made which +# performs the deinstallation. + +deinstall: + @ if test ! -f .INSTALLED_$(SYSTEM); then \ + echo;\ + echo '*** The $(PACK_NAME) package is not currently installed';\ + echo;\ + else \ + if test "`cat .INSTALLED_$(SYSTEM)`" = "$(INSTALL)"; then \ + if $(MAKE) do_deinstall; then \ + echo;\ + echo \ +'*** The $(PACK_NAME) package has been deinstalled from directory $(INSTALL)';\ + echo;\ + else \ + echo;\ + echo \ +'*** "make" failed deinstalling the $(PACK_NAME) package from directory $(INSTALL)';\ + echo;\ + exit 1;\ + fi;\ + else \ + echo;\ + echo \ +"*** The $(PACK_NAME) package is installed in `cat .INSTALLED_$(SYSTEM)`";\ + echo \ +"*** and not in your INSTALL directory ($(INSTALL))";\ + echo '*** Not deinstalled';\ + exit 1;\ + fi;\ + fi + +# The do_deinstall target (which should never exist) checks that an +# installed version of each file exists (in case an install failed +# part of the way through) and returns it to the source directory, +# using "cp -p" to preserve file dates. Links are removed from the +# source directory before copying. + +do_deinstall: +# +# Note the package will need to be tested again. + @- if test -f .TESTED_$(SYSTEM); then rm -f .TESTED_$(SYSTEM); else :; fi +# +# Deinstall the public script files, if installed versions exist. + - for f in $(PUBLIC_SCRIPTS) ""; do \ + if test -n "$$f" -a -f $(INSTALL_BIN)/$$f; then \ + rm -f $$f;\ + cp -p $(INSTALL_BIN)/$$f .;\ + rm -f $(INSTALL_BIN)/$$f;\ + else :; fi;\ + done +# +# Deinstall the public include files, if installed versions exist. + - for f in $(PUBLIC_INCLUDES) ""; do \ + if test -n "$$f" -a -f $(INSTALL_INC)/$$f; then \ + rm -f $$f;\ + cp -p $(INSTALL_INC)/$$f .;\ + rm -f $(INSTALL_INC)/$$f;\ + else :; fi;\ + done +# +# Deinstall the object libraries, if installed versions exist. + - for f in $(OBJECT_LIBRARIES) ""; do \ + if test -n "$$f" -a -f $(INSTALL_LIB)/$$f; then \ + rm -f $$f;\ + cp -p $(INSTALL_LIB)/$$f .;\ + rm -f $(INSTALL_LIB)/$$f;\ + else :; fi;\ + done +# +# Deinstall the shareable libraries, if installed versions exist. + - for f in $(SHAREABLE_LIBRARIES) ""; do \ + if test -n "$$f" -a -f $(INSTALL_SHARE)/$$f; then \ + rm -f $$f;\ + cp -p $(INSTALL_SHARE)/$$f .;\ + rm -f $(INSTALL_SHARE)/$$f;\ + else :; fi;\ + done +# +# Deinstall the package startup file. Since it will have been edited +# during installation, we remove the installed copy, if present, and +# then ensure that the original exists. + - if test -n "$(STARTUP_SCRIPT)"; then \ + if test -f $(INSTALL_BIN)/$(STARTUP_SCRIPT); then\ + rm -f $(INSTALL_BIN)/$(STARTUP_SCRIPT);\ + else :; fi ;\ + $(MAKE) $(STARTUP_SCRIPT);\ + else :; fi +# +# Deinstall the Latex documentation, if installed versions exist. + - for f in $(LATEX_DOCS) ""; do \ + if test -n "$$f" -a -f $(INSTALL_DOCS)/$$f; then \ + rm -f $(INSTALL_DOCS)/$$f;\ + else :; fi;\ + done +# +# Deinstall any hypertext documents, and relink the hypertext if required. + - if test -n "$(HYPERTEXT_DOCS)"; then \ + for f in $(HYPERTEXT_DOCS) ""; do \ + if test -n "$$f" -a -d $(INSTALL_DOCS)/$$f; then \ + rm -f -r $(INSTALL_DOCS)/$$f;\ + else :; fi;\ + done;\ + HTX_PATH='$(STAR_DOCS):$(STAR_HELP)';\ + export HTX_PATH;\ + $(HLINK) $(INSTALL_DOCS) $(INSTALL_HELP);\ + fi +# +# Deinstall the date stamp file after setting its protection so it may +# be removed. + - if test -f $(INSTALL_DATES)/$(DATE_STAMP); then \ + chmod 644 $(DATE_STAMP); rm $(DATE_STAMP);\ + chmod 644 $(INSTALL_DATES)/$(DATE_STAMP);\ + cp -p $(INSTALL_DATES)/$(DATE_STAMP) .;\ + rm $(INSTALL_DATES)/$(DATE_STAMP);\ + else :; fi +# +# Note the system is no longer installed. Re-create .BUILT, since we have +# returned the built files to the source directory but an unbuild may have +# been done. + @- rm -f .INSTALLED_$(SYSTEM) 1>/dev/null 2>/dev/null + @ echo '$(SYSTEM)' > .BUILT + +# test: Perform an installation test. +# ---------------------------------- +# +# Check that installed files are in their correct places and that a +# simple test program will run correctly. + +# The test target checks that the package is currently installed. If +# so, it causes the do_test target to be made, which performs the +# installation test. + +test: + @ if test ! -f .INSTALLED_$(SYSTEM); then \ + echo;\ + echo '*** The $(PACK_NAME) package is not currently installed';\ + echo;\ + elif $(MAKE) do_test; then\ + echo;\ + echo \ + '*** Installation test for the $(PACK_NAME) package has been run';\ + echo;\ + else \ + echo;\ + echo \ + '*** Installation test for the $(PACK_NAME) package failed';\ + echo;\ + exit 1;\ + fi + +# The do_test target performs the installation test. A file named do_test +# should never exist. + +do_test: $(EXTERNAL_INCLUDES) +# +# Note the test has not yet succeeded. + @- if test -f .TESTED_$(SYSTEM); then rm -f .TESTED_$(SYSTEM); else :; fi +# +# Extract the test program from the archive and set up new links for +# the include files which point at the installed versions. Remove any +# pre-existing links first if necessary. + $(TAR_OUT) $(PKG_NAME)_source.tar $(PKG_NAME)_test.f + @ if test -f $(PKG_NAME)_test.f; then :;\ + else echo $(PKG_NAME)_test.f is not in the tar file; exit 1; fi +# +# Build the test program, ensuring that the installed version of the library +# and link files are used. + $(FC) $(FFLAGS) $(PKG_NAME)_test.f -L$(INSTALL_LIB) -L$(STAR_LIB) \ + `$(INSTALL_BIN)/$(PKG_NAME)_link` -o $(PKG_NAME)_test +# +# Remove the test program source and the include file links used to +# build it. + rm -f $(PKG_NAME)_test.f $(EXTERNAL_INCLUDES) +# +# Execute the test program and remove the binary file when done. Note +# that any external mechanism for locating shareable libraries (e.g. a +# search path) must previously have been set up. + ./$(PKG_NAME)_test + rm -f $(PKG_NAME)_test +# +# Note the test has been run. + @ touch .TESTED_$(SYSTEM) + +# export: Export the installed system. +# ----------------------------------- +# +# Export the source plus all the built files to a new user. + +# The export target depends on the resulting compressed tar file being +# up to date. + +export: $(EXPORT)/$(PKG_NAME)_$(SYSTEM).tar.Z + @ echo + @ echo \ +'*** Export copy of the built $(PACK_NAME) package is in the compressed' + @ echo \ +' tar file $(EXPORT)/$(PKG_NAME)_$(SYSTEM).tar.Z' + @ echo + +# The compressed tar file is up to date if it exists and is more +# recent than all the source files and the date stamp file (which +# records the time of the last build which modified any files). + +$(EXPORT)/$(PKG_NAME)_$(SYSTEM).tar.Z: $(SOURCE_FILES) $(DATE_STAMP) +# +# Issue a warning if the package has not been tested. + @ if test ! -f .TESTED_$(SYSTEM); then \ + echo;\ + echo '*** Warning: the $(PACK_NAME) package has not been tested';\ + echo;\ + else :; fi +# +# Remove any pre-existing tar files before creating new ones. + if test -f $(EXPORT)/$(PKG_NAME)_$(SYSTEM).tar.Z; then \ + rm -f $(EXPORT)/$(PKG_NAME)_$(SYSTEM).tar.Z; else :; fi + $(TAR_IN) - $(SOURCE_FILES) $(BUILT_FILES) $(DATE_STAMP) .BUILT \ + | compress -v > $(EXPORT)/$(PKG_NAME)_$(SYSTEM).tar.Z + +# export_run: Export the built system (without source). +# ----------------------------------------------------- +# +# Export all the built files to a new user. + +# The export_run target depends on the resulting compressed tar file being +# up to date. + +export_run: $(EXPORT)/$(PKG_NAME)_$(SYSTEM)_run.tar.Z + @ echo + @ echo \ +'*** Export copy of the "runtime" $(PACK_NAME) package is in the compressed' + @ echo \ +' tar file $(EXPORT)/$(PKG_NAME)_$(SYSTEM)_run.tar.Z' + @ echo + +# The compressed tar file is up to date if it exists and is more +# recent than all the source files and the date stamp file (which +# records the time of the last build which modified any files). + +$(EXPORT)/$(PKG_NAME)_$(SYSTEM)_run.tar.Z: $(SOURCE_FILES) $(DATE_STAMP) +# +# Issue a warning if the package has not been tested. + @ if test ! -f .TESTED_$(SYSTEM); then \ + echo;\ + echo '*** Warning: the $(PACK_NAME) package has not been tested';\ + echo;\ + else :; fi +# +# Remove any pre-existing tar files before creating new ones. + if test -f $(EXPORT)/$(PKG_NAME)_$(SYSTEM)_run.tar.Z; then \ + rm -f $(EXPORT)/$(PKG_NAME)_$(SYSTEM)_run.tar.Z; else :; fi + $(TAR_IN) - mk makefile $(DOCUMENTATION) $(BUILT_FILES) \ + $(DATE_STAMP) .BUILT \ + | compress -v > $(EXPORT)/$(PKG_NAME)_$(SYSTEM)_run.tar.Z + +# export_source: Export the source. +# -------------------------------- +# +# Export the source files only to a new user. + +# This target depends on the resulting compressed tar file being up to +# date. + +export_source: $(EXPORT)/$(PKG_NAME).tar.Z + @ echo + @ echo \ +'*** Export copy of the $(PACK_NAME) package source is in the compressed' + @ echo \ +' tar file $(EXPORT)/$(PKG_NAME).tar.Z' + @ echo + +# The compressed tar file is up to date if it exists and is more +# recent than all the source files. + +$(EXPORT)/$(PKG_NAME).tar.Z: $(SOURCE_FILES) +# +# Remove any pre-existing tar files before creating new ones. + if test -f $(EXPORT)/$(PKG_NAME).tar.Z; then \ + rm -f $(EXPORT)/$(PKG_NAME).tar.Z; else :; fi + $(TAR_IN) - $(SOURCE_FILES) \ + | compress -v > $(EXPORT)/$(PKG_NAME).tar.Z + +# clean: Clean up the source directory. +# ------------------------------------ +# +# Remove all intermediate files. Do not remove built files. + +clean: + @- rm -f $(INCLUDE_LINKS) $(F_ROUTINES) \ + $(PLATFORM_F) $(BLOCK_DATA) 1>/dev/null 2>/dev/null + @- rm -f $(C_ROUTINES) $(OBJECT_FILES) 1>/dev/null 2>/dev/null + @ echo + @ echo '*** Intermediate files removed' + @ echo + +# unbuild: Reverse the build process. +# ---------------------------------- + +# Remove all intermediate files and all built files, and note that the +# package is no longer built or tested. + +unbuild: clean + @- rm -f $(BUILT_FILES) $(DATE_STAMP) .BUILT 1>/dev/null 2>/dev/null + @ echo '*** Built files removed' + @ echo + +#------------------------------------------------------------------------------- + +# Include file dependencies. +# ========================= + +# Object file dependencies on include files (or links to those include +# files). These are normally generated automatically from the source +# files. + +#------------------------------------------------------------------------------- + +# Private targets. + +# Targets for manipulating the hypertext documentation (creating, +# generating tar files etc, cleaning etc). + +hypertext: sun67.tex sun67.aux + star2html -aux -m ptw@star.rl.ac.uk sun67.tex + +hypertext_tar: + $(TAR_IN) sun67.htx_tar sun67.htx/* + +hypertext_clean: + rm -rf sun67.htx +#------------------------------------------------------------------------------- +# +# End of makefile. +#. diff --git a/src/slalib/map.f b/src/slalib/map.f new file mode 100644 index 0000000..6046774 --- /dev/null +++ b/src/slalib/map.f @@ -0,0 +1,75 @@ + SUBROUTINE sla_MAP (RM, DM, PR, PD, PX, RV, EQ, DATE, RA, DA) +*+ +* - - - - +* M A P +* - - - - +* +* Transform star RA,Dec from mean place to geocentric apparent +* +* The reference frames and timescales used are post IAU 1976. +* +* References: +* 1984 Astronomical Almanac, pp B39-B41. +* (also Lederle & Schwan, Astron. Astrophys. 134, +* 1-6, 1984) +* +* Given: +* RM,DM dp mean RA,Dec (rad) +* PR,PD dp proper motions: RA,Dec changes per Julian year +* PX dp parallax (arcsec) +* RV dp radial velocity (km/sec, +ve if receding) +* EQ dp epoch and equinox of star data (Julian) +* DATE dp TDB for apparent place (JD-2400000.5) +* +* Returned: +* RA,DA dp apparent RA,Dec (rad) +* +* Called: +* sla_MAPPA star-independent parameters +* sla_MAPQK quick mean to apparent +* +* Notes: +* +* 1) EQ is the Julian epoch specifying both the reference +* frame and the epoch of the position - usually 2000. +* For positions where the epoch and equinox are +* different, use the routine sla_PM to apply proper +* motion corrections before using this routine. +* +* 2) The distinction between the required TDB and TT is +* always negligible. Moreover, for all but the most +* critical applications UTC is adequate. +* +* 3) The proper motions in RA are dRA/dt rather than +* cos(Dec)*dRA/dt. +* +* 4) This routine may be wasteful for some applications +* because it recomputes the Earth position/velocity and +* the precession/nutation matrix each time, and because +* it allows for parallax and proper motion. Where +* multiple transformations are to be carried out for one +* epoch, a faster method is to call the sla_MAPPA routine +* once and then either the sla_MAPQK routine (which includes +* parallax and proper motion) or sla_MAPQKZ (which assumes +* zero parallax and proper motion). +* +* P.T.Wallace Starlink 19 January 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RM,DM,PR,PD,PX,RV,EQ,DATE,RA,DA + + DOUBLE PRECISION AMPRMS(21) + + + +* Star-independent parameters + CALL sla_MAPPA(EQ,DATE,AMPRMS) + +* Mean to apparent + CALL sla_MAPQK(RM,DM,PR,PD,PX,RV,AMPRMS,RA,DA) + + END diff --git a/src/slalib/mappa.f b/src/slalib/mappa.f new file mode 100644 index 0000000..8dce865 --- /dev/null +++ b/src/slalib/mappa.f @@ -0,0 +1,107 @@ + SUBROUTINE sla_MAPPA (EQ, DATE, AMPRMS) +*+ +* - - - - - - +* M A P P A +* - - - - - - +* +* Compute star-independent parameters in preparation for +* conversions between mean place and geocentric apparent place. +* +* The parameters produced by this routine are required in the +* parallax, light deflection, aberration, and precession/nutation +* parts of the mean/apparent transformations. +* +* The reference frames and timescales used are post IAU 1976. +* +* Given: +* EQ d epoch of mean equinox to be used (Julian) +* DATE d TDB (JD-2400000.5) +* +* Returned: +* AMPRMS d(21) star-independent mean-to-apparent parameters: +* +* (1) time interval for proper motion (Julian years) +* (2-4) barycentric position of the Earth (AU) +* (5-7) heliocentric direction of the Earth (unit vector) +* (8) (grav rad Sun)*2/(Sun-Earth distance) +* (9-11) ABV: barycentric Earth velocity in units of c +* (12) sqrt(1-v**2) where v=modulus(ABV) +* (13-21) precession/nutation (3,3) matrix +* +* References: +* 1984 Astronomical Almanac, pp B39-B41. +* (also Lederle & Schwan, Astron. Astrophys. 134, +* 1-6, 1984) +* +* Notes: +* +* 1) For DATE, the distinction between the required TDB and TT +* is always negligible. Moreover, for all but the most +* critical applications UTC is adequate. +* +* 2) The accuracy of the routines using the parameters AMPRMS is +* limited by the routine sla_EVP, used here to compute the +* Earth position and velocity by the methods of Stumpff. +* The maximum error in the resulting aberration corrections is +* about 0.3 milliarcsecond. +* +* 3) The vectors AMPRMS(2-4) and AMPRMS(5-7) are referred to +* the mean equinox and equator of epoch EQ. +* +* 4) The parameters AMPRMS produced by this routine are used by +* sla_MAPQK and sla_MAPQKZ. +* +* Called: +* sla_EPJ MDJ to Julian epoch +* sla_EVP earth position & velocity +* sla_DVN normalize vector +* sla_PRENUT precession/nutation matrix +* +* P.T.Wallace Starlink 23 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION EQ,DATE,AMPRMS(21) + +* Light time for 1 AU (sec) + DOUBLE PRECISION CR + PARAMETER (CR=499.004782D0) + +* Gravitational radius of the sun x 2 (2*mu/c**2, AU) + DOUBLE PRECISION GR2 + PARAMETER (GR2=2D0*9.87063D-9) + + INTEGER I + + DOUBLE PRECISION EBD(3),EHD(3),EH(3),E,VN(3),VM + + DOUBLE PRECISION sla_EPJ + + + +* Time interval for proper motion correction + AMPRMS(1) = sla_EPJ(DATE)-EQ + +* Get Earth barycentric and heliocentric position and velocity + CALL sla_EVP(DATE,EQ,EBD,AMPRMS(2),EHD,EH) + +* Heliocentric direction of earth (normalized) and modulus + CALL sla_DVN(EH,AMPRMS(5),E) + +* Light deflection parameter + AMPRMS(8) = GR2/E + +* Aberration parameters + DO I=1,3 + AMPRMS(I+8) = EBD(I)*CR + END DO + CALL sla_DVN(AMPRMS(9),VN,VM) + AMPRMS(12) = SQRT(1D0-VM*VM) + +* Precession/nutation matrix + CALL sla_PRENUT(EQ,DATE,AMPRMS(13)) + + END diff --git a/src/slalib/mapqk.f b/src/slalib/mapqk.f new file mode 100644 index 0000000..4cd0f95 --- /dev/null +++ b/src/slalib/mapqk.f @@ -0,0 +1,143 @@ + SUBROUTINE sla_MAPQK (RM, DM, PR, PD, PX, RV, AMPRMS, RA, DA) +*+ +* - - - - - - +* M A P Q K +* - - - - - - +* +* Quick mean to apparent place: transform a star RA,Dec from +* mean place to geocentric apparent place, given the +* star-independent parameters. +* +* Use of this routine is appropriate when efficiency is important +* and where many star positions, all referred to the same equator +* and equinox, are to be transformed for one epoch. The +* star-independent parameters can be obtained by calling the +* sla_MAPPA routine. +* +* If the parallax and proper motions are zero the sla_MAPQKZ +* routine can be used instead. +* +* The reference frames and timescales used are post IAU 1976. +* +* Given: +* RM,DM d mean RA,Dec (rad) +* PR,PD d proper motions: RA,Dec changes per Julian year +* PX d parallax (arcsec) +* RV d radial velocity (km/sec, +ve if receding) +* +* AMPRMS d(21) star-independent mean-to-apparent parameters: +* +* (1) time interval for proper motion (Julian years) +* (2-4) barycentric position of the Earth (AU) +* (5-7) heliocentric direction of the Earth (unit vector) +* (8) (grav rad Sun)*2/(Sun-Earth distance) +* (9-11) barycentric Earth velocity in units of c +* (12) sqrt(1-v**2) where v=modulus(ABV) +* (13-21) precession/nutation (3,3) matrix +* +* Returned: +* RA,DA d apparent RA,Dec (rad) +* +* References: +* 1984 Astronomical Almanac, pp B39-B41. +* (also Lederle & Schwan, Astron. Astrophys. 134, +* 1-6, 1984) +* +* Notes: +* +* 1) The vectors AMPRMS(2-4) and AMPRMS(5-7) are referred to +* the mean equinox and equator of epoch EQ. +* +* 2) Strictly speaking, the routine is not valid for solar-system +* sources, though the error will usually be extremely small. +* However, to prevent gross errors in the case where the +* position of the Sun is specified, the gravitational +* deflection term is restrained within about 920 arcsec of the +* centre of the Sun's disc. The term has a maximum value of +* about 1.85 arcsec at this radius, and decreases to zero as +* the centre of the disc is approached. +* +* Called: +* sla_DCS2C spherical to Cartesian +* sla_DVDV dot product +* sla_DMXV matrix x vector +* sla_DCC2S Cartesian to spherical +* sla_DRANRM normalize angle 0-2Pi +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RM,DM,PR,PD,PX,RV,AMPRMS(21),RA,DA + +* Arc seconds to radians + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + +* Km/s to AU/year + DOUBLE PRECISION VF + PARAMETER (VF=0.21094502D0) + + INTEGER I + + DOUBLE PRECISION PMT,GR2E,AB1,EB(3),EHN(3),ABV(3), + : Q(3),PXR,W,EM(3),P(3),PN(3),PDE,PDEP1, + : P1(3),P1DV,P1DVP1,P2(3),P3(3) + + DOUBLE PRECISION sla_DVDV,sla_DRANRM + + + +* Unpack scalar and vector parameters + PMT = AMPRMS(1) + GR2E = AMPRMS(8) + AB1 = AMPRMS(12) + DO I=1,3 + EB(I) = AMPRMS(I+1) + EHN(I) = AMPRMS(I+4) + ABV(I) = AMPRMS(I+8) + END DO + +* Spherical to x,y,z + CALL sla_DCS2C(RM,DM,Q) + +* Space motion (radians per year) + PXR = PX*AS2R + W = VF*RV*PXR + EM(1) = -PR*Q(2)-PD*COS(RM)*SIN(DM)+W*Q(1) + EM(2) = PR*Q(1)-PD*SIN(RM)*SIN(DM)+W*Q(2) + EM(3) = PD*COS(DM) +W*Q(3) + +* Geocentric direction of star (normalized) + DO I=1,3 + P(I) = Q(I)+PMT*EM(I)-PXR*EB(I) + END DO + CALL sla_DVN(P,PN,W) + +* Light deflection (restrained within the Sun's disc) + PDE = sla_DVDV(PN,EHN) + PDEP1 = PDE+1D0 + W = GR2E/MAX(PDEP1,1D-5) + DO I=1,3 + P1(I) = PN(I)+W*(EHN(I)-PDE*PN(I)) + END DO + +* Aberration + P1DV = sla_DVDV(P1,ABV) + P1DVP1 = P1DV+1D0 + W = 1D0+P1DV/(AB1+1D0) + DO I=1,3 + P2(I) = (AB1*P1(I)+W*ABV(I))/P1DVP1 + END DO + +* Precession and nutation + CALL sla_DMXV(AMPRMS(13),P2,P3) + +* Geocentric apparent RA,Dec + CALL sla_DCC2S(P3,RA,DA) + RA = sla_DRANRM(RA) + + END diff --git a/src/slalib/mapqkz.f b/src/slalib/mapqkz.f new file mode 100644 index 0000000..2922874 --- /dev/null +++ b/src/slalib/mapqkz.f @@ -0,0 +1,113 @@ + SUBROUTINE sla_MAPQKZ (RM, DM, AMPRMS, RA, DA) +*+ +* - - - - - - - +* M A P Q K Z +* - - - - - - - +* +* Quick mean to apparent place: transform a star RA,Dec from +* mean place to geocentric apparent place, given the +* star-independent parameters, and assuming zero parallax +* and proper motion. +* +* Use of this routine is appropriate when efficiency is important +* and where many star positions, all with parallax and proper +* motion either zero or already allowed for, and all referred to +* the same equator and equinox, are to be transformed for one +* epoch. The star-independent parameters can be obtained by +* calling the sla_MAPPA routine. +* +* The corresponding routine for the case of non-zero parallax +* and proper motion is sla_MAPQK. +* +* The reference frames and timescales used are post IAU 1976. +* +* Given: +* RM,DM d mean RA,Dec (rad) +* AMPRMS d(21) star-independent mean-to-apparent parameters: +* +* (1-4) not used +* (5-7) heliocentric direction of the Earth (unit vector) +* (8) (grav rad Sun)*2/(Sun-Earth distance) +* (9-11) ABV: barycentric Earth velocity in units of c +* (12) sqrt(1-v**2) where v=modulus(ABV) +* (13-21) precession/nutation (3,3) matrix +* +* Returned: +* RA,DA d apparent RA,Dec (rad) +* +* References: +* 1984 Astronomical Almanac, pp B39-B41. +* (also Lederle & Schwan, Astron. Astrophys. 134, +* 1-6, 1984) +* +* Notes: +* +* 1) The vectors AMPRMS(2-4) and AMPRMS(5-7) are referred to the +* mean equinox and equator of epoch EQ. +* +* 2) Strictly speaking, the routine is not valid for solar-system +* sources, though the error will usually be extremely small. +* However, to prevent gross errors in the case where the +* position of the Sun is specified, the gravitational +* deflection term is restrained within about 920 arcsec of the +* centre of the Sun's disc. The term has a maximum value of +* about 1.85 arcsec at this radius, and decreases to zero as +* the centre of the disc is approached. +* +* Called: sla_DCS2C, sla_DVDV, sla_DMXV, sla_DCC2S, sla_DRANRM +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RM,DM,AMPRMS(21),RA,DA + + INTEGER I + + DOUBLE PRECISION GR2E,AB1,EHN(3),ABV(3), + : P(3),PDE,PDEP1,W,P1(3),P1DV, + : P1DVP1,P2(3),P3(3) + + DOUBLE PRECISION sla_DVDV,sla_DRANRM + + + + +* Unpack scalar and vector parameters + GR2E = AMPRMS(8) + AB1 = AMPRMS(12) + DO I=1,3 + EHN(I) = AMPRMS(I+4) + ABV(I) = AMPRMS(I+8) + END DO + +* Spherical to x,y,z + CALL sla_DCS2C(RM,DM,P) + +* Light deflection + PDE = sla_DVDV(P,EHN) + PDEP1 = PDE+1D0 + W = GR2E/MAX(PDEP1,1D-5) + DO I=1,3 + P1(I) = P(I)+W*(EHN(I)-PDE*P(I)) + END DO + +* Aberration + P1DV = sla_DVDV(P1,ABV) + P1DVP1 = P1DV+1D0 + W = 1D0+P1DV/(AB1+1D0) + DO I=1,3 + P2(I) = (AB1*P1(I)+W*ABV(I))/P1DVP1 + END DO + +* Precession and nutation + CALL sla_DMXV(AMPRMS(13),P2,P3) + +* Geocentric apparent RA,Dec + CALL sla_DCC2S(P3,RA,DA) + RA = sla_DRANRM(RA) + + END diff --git a/src/slalib/mk b/src/slalib/mk new file mode 100755 index 0000000..5a186c3 --- /dev/null +++ b/src/slalib/mk @@ -0,0 +1,437 @@ + +# This is a Bourne shell script. In order to be POSIX-compliant, the +# first line must be blank. + +#+ +# Name: +# mk +# +# Version: +# Version for Mk V library makefile. +# +# Purpose: +# Invoke make to build and install the SLALIB package. +# +# Type of Module: +# Shell script. +# +# Description: +# This script should normally be used to invoke the make utility +# to build and install the SLALIB package and to perform other +# housekeeping tasks. It invokes the make utility after first +# defining appropriate environment variables and macros for the +# computer system in use. This file also serves to document the +# systems on which SLALIB is implemented. +# +# Invocation: +# The user of this script should normally first define the SYSTEM +# environment variable to identify the host computer system (see +# the "Supported Systems" section). This script should then be used +# in the same way as the make utility would be used. For instance, +# to build, install and test SLALIB, you might use the following +# commands: +# +# ./mk build +# ./mk install +# ./mk test +# ./mk clean +# +# Supported Systems: +# The following systems are currently supported and may be +# identified by defining the SYSTEM environment variable +# appropriately before invoking this script: +# +# alpha_OSF1 +# DEC Alpha machines running OSF1 +# +# ix86_Linux +# Intel PC machines running Linux +# +# sun4_Solaris +# SUN Sparcstations running SunOS 5.x (Solaris) +# +# In addition, the following systems have been supported at some +# time in the past. This script contains the macro definitions +# needed for these systems, but it is not known whether {PACKAGE} +# will still build or run on these systems: +# +# convex +# Convex running ConvexOS +# +# mips +# DECstations running Ultrix +# +# sun4 +# SUN Sparcstations running SunOS 4.x +# +# This script will exit without action if the SYSTEM environment +# variable is not defined. A warning will be issued if it is +# defined but is not set to one of the values above. In this case, +# the only environment variable that will be defined by this script +# is SOURCE_VARIANT, which is set to unknown (any that are +# pre-defined will be passed on to make unaltered). +# +# Targets: +# For details of what targets are provided, see the associated +# makefile. The latter will normally provide a default target +# called "help", which outputs a message describing this script +# and lists the targets provided. +# +# Notes on Porting: +# If your machine or system setup does not appear in this script, +# then it should be possible to build and install SLALIB by +# adding a new case to this script with appropriate definitions +# (probably based on one of the existing implementations). +# +# make Macros: +# The following "global" make macros are used in the associated +# makefile and may be changed by means of appropriate environment +# variable definitions (in each case the default is shown in +# parentheses). Note that these macros are provided to allow +# external control over the directories in which software is +# installed, etc., so they should not normally be re-defined within +# this script. +# +# STARLINK (/star) +# Pathname of the root directory beneath which Starlink +# software is currently installed. This indicates to +# SLALIB where to find other Starlink software (include +# files, libraries, etc.) which it uses. +# +# INSTALL ($HOME) +# Pathname of the root directory beneath which SLALIB will +# be installed for use. Your home directory will be used by +# default. This macro is provided to allow SLALIB to be +# installed locally for personal use (e.g. during development +# or testing). It should be set to the $STARLINK directory if +# you want to add SLALIB into an already installed set of +# Starlink software. You should ensure that the appropriate +# sub-directories appear on any relevant search paths which +# your system uses for locating software (e.g. binaries and +# libraries). +# +# EXPORT (.) +# Pathname of the directory into which compressed tar files +# will be written if the "export" or "export_source" make +# targets are used to produce an exportable copy of SLALIB +# or its source files. The current working directory (i.e. +# the SLALIB source directory) will be used by default. +# +# The following "local" make macros are used in the associated +# makefile and should normally be overridden by environment variable +# definitions within this script. All the local macros that are +# used in building a package should overridden even when the value +# is the same as the default. This documents which macros are used +# and ensures that the package will continue to build correctly even +# if the default values are changed. Macros that are not used on a +# particular machine (e.g. BLD_SHR on DECstations) should not be +# overridden. In each case the default is shown in parentheses. +# +# AR_IN (ar -r) +# The command to use to insert an object (.o) file into an +# archive (.a) library. On some systems the variation 'ar r' +# may be required instead. +# +# BLD_SHR (:) +# Command to build a shareable library when given three +# arguments specifying (1) the name of the library file to be +# built (2) a list of the object files to be used in the +# library and (3) a list of any additional libraries against +# which to link. By default, it is assumed that shareable +# libraries are not available, and the default acts as a null +# command. +# +# CC (c89) +# The C compiler command to use. +# +# CFLAGS (-O) +# The C compiler options to use. +# +# C_ROUTINES () +# Names of the C routines needed to build the library. Some +# systems (ix86_Linux) require extra C routines to provide +# missing system functions. +# +# FC (fort77) +# The Fortran compiler command to use. SLALIB requires a Fortran +# 77 compiler that supports the common "permitted" Starlink +# extensions, as documented in Starlink General Paper SGP/16. +# (These include only the most common extensions, such as +# long names, end of line comments, include files, etc.) +# +# FFLAGS (-O) +# The Fortran compiler options to be used. +# +# HLINK (:) +# The command required to perform the linking of the package +# hypertext documentation into a cohesive whole with the rest +# (if any) Starlink documentation at the installation site, and +# with the Hypertext document server at RAL. This service is not +# available on Sparc SunOS4, Dec MIPS Ultrix or Convex. This +# macro is not a standard Starlink macro. +# +# LINK (ln) +# The command required to establish a link to a file. The +# default assumes POSIX.2 behavior, which only provides a +# "hard" link operating within a single file system. If the +# host operating system allows "symbolic" links, then this +# macro might be re-defined as 'ln -s'. Alternatively, if the +# use of multiple file systems is essential but not supported +# by any form of link, then a copy command could be +# substituted (e.g. 'cp -p'), at some cost in file space. +# +# SOURCE_VARIANT ($SYSTEM) +# The name used to distinguish between platform-specific +# files. Using the default ($SYSTEM) implies that multiple +# copies of the same source may exist under different names. +# For example, the files sub1.f_sun4 and sun1.f_sun4_Solaris +# may contain identical source code. If this is to be +# avoided (to save space), edit this script to set +# SOURCE_VARIANT to a suitable string - for example setting it +# to "sun" would allow one copy of the source called +# sub1.f_sun to be used. To do this, add to each of the +# per-system sections a statement of the form: +# +# SOURCE_VARIANT='string' +# +# RANLIB (:) +# The command required to "randomise" an object library. By +# default, this operation is not performed (the default acts +# as a null command). On systems which require it, this +# should typically be set to 'ranlib'. +# +# SHARE (.so) +# The file type suffix to be applied to produce the name of a +# shareable library file. By default, the ".so" suffix is +# applied without a library version number. For systems which +# support version numbers on shareable libraries, the macro +# LIB_VERS is defined within the associated makefile and may +# be used as part of a definition such as '.so.$(LIB_VERS)'. +# +# TAR_IN (pax -w -v -x ustar -f) +# Command to use to insert a file into a .tar archive file. +# The default uses the POSIX.2 pax command, which is not +# available on traditional UNIX systems. These typically use +# a tar command such as 'tar -cvhf' instead (if symbolic +# links are supported, then an option to follow these must be +# included in this command). +# +# TAR_OUT (pax -r -f) +# Command to use to extract a file from a .tar archive file. +# The default uses the POSIX.2 pax command, which is not +# available on traditional UNIX systems. These typically use +# a tar command such as 'tar -xf' instead. +# +# Implementation Deficiencies: +# - The implementation of shareable libraries on the alpha_OSF1 +# system is still preliminary. +# +# Copyright: +# Copyright (C) 1995 Rutherford Appleton Laboratory +# +# Authors: +# RFWS: R.F.Warren-Smith (Starlink, RAL) +# PMA: P.M.Allan (Starlink, RAL) +# PTW: P.T.Wallace (Starlink, RAL) +# AJC: A.J.Chipperfield (Starlink, RAL) +# BLY: M.J.Bly (Starlink, RAL) +# BKM: B.K.McIlwrath (Starlink, RAL) +# {enter_new_authors_here} +# +# History: +# 26-NOV-1993 (RFWS/PMA): +# Starlink template. +# 26-NOV-1993 (PTW): +# Version for SLALIB. +# 28-JUN-1993 (PTW): +# Convex added. +# 06-JUN-1995 (BLY): +# Updated to Mk IVa standard. +# 04-MAR-1996 (BLY): +# Updated to Mk V specification. +# Added HLINK macro and definitions. +# 24-APR-1996 (BLY): +# Integrated Linux support from BKM version. +# 22-JAN-1998 (BLY): +# Removed rtl_sleep.c from C_ROUTINES for Linux case. +# {enter_further_changes_here} +# +# Bugs: +# {note_any_bugs_here} +# +#- + +# Export "local" definitions to the environment for use by make. + export AR_IN + export BLD_SHR + export CC + export CFLAGS + export C_ROUTINES + export FC + export FFLAGS + export HLINK + export LINK + export SOURCE_VARIANT + export RANLIB + export SHARE + export TAR_IN + export TAR_OUT + +# Check that the SYSTEM environment variable is defined. + if test "$SYSTEM" = ""; then + echo "mk: Please define the environment variable SYSTEM to identify" + echo " your computer system (the prologue in the mk script file" + echo " contains more information if you require it)." + +# If OK, test for each recognised system. + else + case "$SYSTEM" in + +# DEC Alpha: +# ========= +# DEC Alpha machines running OSF1. +# ------------------------------- + alpha_OSF1) + AR_IN='ar -r' +# BLD_SHR=\ +#'f() ld -shared -update_registry $(INSTALL)/share/so_locations -o $$1 $$2 $$3 \ +#-lfor -lFutil -lUfor -lm -lots -lc; f' + CC='cc' + CFLAGS='-I$(STAR_INC) -O -std1' + FC='f77' + FFLAGS='-O' + HLINK='$(STAR_BIN)/hlink' + LINK='ln -s' + RANLIB='ranlib' +# SHARE='.so' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# DECstations: +# =========== +# DECstations running Ultrix. +# -------------------------- + mips) + AR_IN='ar -r' + CC='c89' + CFLAGS='-I$(STAR_INC) -O' + FC='f77' + FFLAGS='-O' + LINK='ln -s' + RANLIB='ranlib' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# SUN4 systems: +# ============ +# SUN Sparcstations running SunOS 4.x. +# ----------------------------------- + sun4) + AR_IN='ar r' + BLD_SHR='f() ld -assert pure-text -o $$1 $$2; f' + CC='gcc' + CFLAGS='-I$(STAR_INC) -O -fPIC' + FC='f77' + FFLAGS='-O -PIC' + LINK='ln -s' + RANLIB='ranlib' + SHARE='.so.$(LIB_VERS)' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# SUN Sparcstations running SunOS 5.x (Solaris). +# --------------------------------------------- + sun4_Solaris) + AR_IN='ar -r' + BLD_SHR='f() ld -G -z text -o $$1 $$2; f' + CC='cc' + CFLAGS='-I$(STAR_INC) -O -K PIC' + FC='f77' + FFLAGS='-O -PIC' + HLINK='$(STAR_BIN)/hlink' + LINK='ln -s' + SHARE='.so' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# PC systems: +# ========== +# Intel PC running Linux. +# ---------------------- + ix86_Linux) + AR_IN='ar r' + CC='gcc' + CFLAGS='-O' + C_ROUTINES='rtl_random.c' + FC='gfortran' + FFLAGS='-fno-second-underscore -O' + HLINK='$(STAR_BIN)/hlink' + LINK='ln -s' + RANLIB='ranlib' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# Intel PC running Linux on 64 architecture. +# ----------------------------------------- + x86_64) + AR_IN='ar r' + CC='gcc' + CFLAGS='-O -fPIC' + C_ROUTINES='rtl_random.c' + FC='gfortran' + FFLAGS='-fno-second-underscore -O -fPIC' + HLINK='$(STAR_BIN)/hlink' + LINK='ln -s' + RANLIB='ranlib' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# Convex running ConvexOS. +# ------------------------ + convex) + AR_IN='ar r' + FC='fc' + FFLAGS='-O3' + CC='gcc' + CFLAGS='-I$(STAR_INC) -O -fPIC' + LINK='ln -s' + RANLIB='ranlib' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# IMPORTANT NOTE - Because Convex make doesn't support the -e +# qualifier (as stipulated by the POSIX standard) it will be +# necessary to use another version of make, for example the +# GNU one. This can be accomplished either by editing this script, +# or by setting up a link. + +# Issue a warning if SYSTEM is not recognised. + *) + SOURCE_VARIANT='unknown' + echo "mk: WARNING: value of SYSTEM = $SYSTEM not recognised..." + echo " ...assuming default system characteristics" + echo ' ...setting SOURCE_VARIANT to "unknown"' + ;; + esac + +# Invoke make with the appropriate environment variables set to override +# default macros defined in the makefile. + echo make -e $* + make -e $* + fi + +# End of script. diff --git a/src/slalib/mk.sv b/src/slalib/mk.sv new file mode 100755 index 0000000..5a186c3 --- /dev/null +++ b/src/slalib/mk.sv @@ -0,0 +1,437 @@ + +# This is a Bourne shell script. In order to be POSIX-compliant, the +# first line must be blank. + +#+ +# Name: +# mk +# +# Version: +# Version for Mk V library makefile. +# +# Purpose: +# Invoke make to build and install the SLALIB package. +# +# Type of Module: +# Shell script. +# +# Description: +# This script should normally be used to invoke the make utility +# to build and install the SLALIB package and to perform other +# housekeeping tasks. It invokes the make utility after first +# defining appropriate environment variables and macros for the +# computer system in use. This file also serves to document the +# systems on which SLALIB is implemented. +# +# Invocation: +# The user of this script should normally first define the SYSTEM +# environment variable to identify the host computer system (see +# the "Supported Systems" section). This script should then be used +# in the same way as the make utility would be used. For instance, +# to build, install and test SLALIB, you might use the following +# commands: +# +# ./mk build +# ./mk install +# ./mk test +# ./mk clean +# +# Supported Systems: +# The following systems are currently supported and may be +# identified by defining the SYSTEM environment variable +# appropriately before invoking this script: +# +# alpha_OSF1 +# DEC Alpha machines running OSF1 +# +# ix86_Linux +# Intel PC machines running Linux +# +# sun4_Solaris +# SUN Sparcstations running SunOS 5.x (Solaris) +# +# In addition, the following systems have been supported at some +# time in the past. This script contains the macro definitions +# needed for these systems, but it is not known whether {PACKAGE} +# will still build or run on these systems: +# +# convex +# Convex running ConvexOS +# +# mips +# DECstations running Ultrix +# +# sun4 +# SUN Sparcstations running SunOS 4.x +# +# This script will exit without action if the SYSTEM environment +# variable is not defined. A warning will be issued if it is +# defined but is not set to one of the values above. In this case, +# the only environment variable that will be defined by this script +# is SOURCE_VARIANT, which is set to unknown (any that are +# pre-defined will be passed on to make unaltered). +# +# Targets: +# For details of what targets are provided, see the associated +# makefile. The latter will normally provide a default target +# called "help", which outputs a message describing this script +# and lists the targets provided. +# +# Notes on Porting: +# If your machine or system setup does not appear in this script, +# then it should be possible to build and install SLALIB by +# adding a new case to this script with appropriate definitions +# (probably based on one of the existing implementations). +# +# make Macros: +# The following "global" make macros are used in the associated +# makefile and may be changed by means of appropriate environment +# variable definitions (in each case the default is shown in +# parentheses). Note that these macros are provided to allow +# external control over the directories in which software is +# installed, etc., so they should not normally be re-defined within +# this script. +# +# STARLINK (/star) +# Pathname of the root directory beneath which Starlink +# software is currently installed. This indicates to +# SLALIB where to find other Starlink software (include +# files, libraries, etc.) which it uses. +# +# INSTALL ($HOME) +# Pathname of the root directory beneath which SLALIB will +# be installed for use. Your home directory will be used by +# default. This macro is provided to allow SLALIB to be +# installed locally for personal use (e.g. during development +# or testing). It should be set to the $STARLINK directory if +# you want to add SLALIB into an already installed set of +# Starlink software. You should ensure that the appropriate +# sub-directories appear on any relevant search paths which +# your system uses for locating software (e.g. binaries and +# libraries). +# +# EXPORT (.) +# Pathname of the directory into which compressed tar files +# will be written if the "export" or "export_source" make +# targets are used to produce an exportable copy of SLALIB +# or its source files. The current working directory (i.e. +# the SLALIB source directory) will be used by default. +# +# The following "local" make macros are used in the associated +# makefile and should normally be overridden by environment variable +# definitions within this script. All the local macros that are +# used in building a package should overridden even when the value +# is the same as the default. This documents which macros are used +# and ensures that the package will continue to build correctly even +# if the default values are changed. Macros that are not used on a +# particular machine (e.g. BLD_SHR on DECstations) should not be +# overridden. In each case the default is shown in parentheses. +# +# AR_IN (ar -r) +# The command to use to insert an object (.o) file into an +# archive (.a) library. On some systems the variation 'ar r' +# may be required instead. +# +# BLD_SHR (:) +# Command to build a shareable library when given three +# arguments specifying (1) the name of the library file to be +# built (2) a list of the object files to be used in the +# library and (3) a list of any additional libraries against +# which to link. By default, it is assumed that shareable +# libraries are not available, and the default acts as a null +# command. +# +# CC (c89) +# The C compiler command to use. +# +# CFLAGS (-O) +# The C compiler options to use. +# +# C_ROUTINES () +# Names of the C routines needed to build the library. Some +# systems (ix86_Linux) require extra C routines to provide +# missing system functions. +# +# FC (fort77) +# The Fortran compiler command to use. SLALIB requires a Fortran +# 77 compiler that supports the common "permitted" Starlink +# extensions, as documented in Starlink General Paper SGP/16. +# (These include only the most common extensions, such as +# long names, end of line comments, include files, etc.) +# +# FFLAGS (-O) +# The Fortran compiler options to be used. +# +# HLINK (:) +# The command required to perform the linking of the package +# hypertext documentation into a cohesive whole with the rest +# (if any) Starlink documentation at the installation site, and +# with the Hypertext document server at RAL. This service is not +# available on Sparc SunOS4, Dec MIPS Ultrix or Convex. This +# macro is not a standard Starlink macro. +# +# LINK (ln) +# The command required to establish a link to a file. The +# default assumes POSIX.2 behavior, which only provides a +# "hard" link operating within a single file system. If the +# host operating system allows "symbolic" links, then this +# macro might be re-defined as 'ln -s'. Alternatively, if the +# use of multiple file systems is essential but not supported +# by any form of link, then a copy command could be +# substituted (e.g. 'cp -p'), at some cost in file space. +# +# SOURCE_VARIANT ($SYSTEM) +# The name used to distinguish between platform-specific +# files. Using the default ($SYSTEM) implies that multiple +# copies of the same source may exist under different names. +# For example, the files sub1.f_sun4 and sun1.f_sun4_Solaris +# may contain identical source code. If this is to be +# avoided (to save space), edit this script to set +# SOURCE_VARIANT to a suitable string - for example setting it +# to "sun" would allow one copy of the source called +# sub1.f_sun to be used. To do this, add to each of the +# per-system sections a statement of the form: +# +# SOURCE_VARIANT='string' +# +# RANLIB (:) +# The command required to "randomise" an object library. By +# default, this operation is not performed (the default acts +# as a null command). On systems which require it, this +# should typically be set to 'ranlib'. +# +# SHARE (.so) +# The file type suffix to be applied to produce the name of a +# shareable library file. By default, the ".so" suffix is +# applied without a library version number. For systems which +# support version numbers on shareable libraries, the macro +# LIB_VERS is defined within the associated makefile and may +# be used as part of a definition such as '.so.$(LIB_VERS)'. +# +# TAR_IN (pax -w -v -x ustar -f) +# Command to use to insert a file into a .tar archive file. +# The default uses the POSIX.2 pax command, which is not +# available on traditional UNIX systems. These typically use +# a tar command such as 'tar -cvhf' instead (if symbolic +# links are supported, then an option to follow these must be +# included in this command). +# +# TAR_OUT (pax -r -f) +# Command to use to extract a file from a .tar archive file. +# The default uses the POSIX.2 pax command, which is not +# available on traditional UNIX systems. These typically use +# a tar command such as 'tar -xf' instead. +# +# Implementation Deficiencies: +# - The implementation of shareable libraries on the alpha_OSF1 +# system is still preliminary. +# +# Copyright: +# Copyright (C) 1995 Rutherford Appleton Laboratory +# +# Authors: +# RFWS: R.F.Warren-Smith (Starlink, RAL) +# PMA: P.M.Allan (Starlink, RAL) +# PTW: P.T.Wallace (Starlink, RAL) +# AJC: A.J.Chipperfield (Starlink, RAL) +# BLY: M.J.Bly (Starlink, RAL) +# BKM: B.K.McIlwrath (Starlink, RAL) +# {enter_new_authors_here} +# +# History: +# 26-NOV-1993 (RFWS/PMA): +# Starlink template. +# 26-NOV-1993 (PTW): +# Version for SLALIB. +# 28-JUN-1993 (PTW): +# Convex added. +# 06-JUN-1995 (BLY): +# Updated to Mk IVa standard. +# 04-MAR-1996 (BLY): +# Updated to Mk V specification. +# Added HLINK macro and definitions. +# 24-APR-1996 (BLY): +# Integrated Linux support from BKM version. +# 22-JAN-1998 (BLY): +# Removed rtl_sleep.c from C_ROUTINES for Linux case. +# {enter_further_changes_here} +# +# Bugs: +# {note_any_bugs_here} +# +#- + +# Export "local" definitions to the environment for use by make. + export AR_IN + export BLD_SHR + export CC + export CFLAGS + export C_ROUTINES + export FC + export FFLAGS + export HLINK + export LINK + export SOURCE_VARIANT + export RANLIB + export SHARE + export TAR_IN + export TAR_OUT + +# Check that the SYSTEM environment variable is defined. + if test "$SYSTEM" = ""; then + echo "mk: Please define the environment variable SYSTEM to identify" + echo " your computer system (the prologue in the mk script file" + echo " contains more information if you require it)." + +# If OK, test for each recognised system. + else + case "$SYSTEM" in + +# DEC Alpha: +# ========= +# DEC Alpha machines running OSF1. +# ------------------------------- + alpha_OSF1) + AR_IN='ar -r' +# BLD_SHR=\ +#'f() ld -shared -update_registry $(INSTALL)/share/so_locations -o $$1 $$2 $$3 \ +#-lfor -lFutil -lUfor -lm -lots -lc; f' + CC='cc' + CFLAGS='-I$(STAR_INC) -O -std1' + FC='f77' + FFLAGS='-O' + HLINK='$(STAR_BIN)/hlink' + LINK='ln -s' + RANLIB='ranlib' +# SHARE='.so' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# DECstations: +# =========== +# DECstations running Ultrix. +# -------------------------- + mips) + AR_IN='ar -r' + CC='c89' + CFLAGS='-I$(STAR_INC) -O' + FC='f77' + FFLAGS='-O' + LINK='ln -s' + RANLIB='ranlib' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# SUN4 systems: +# ============ +# SUN Sparcstations running SunOS 4.x. +# ----------------------------------- + sun4) + AR_IN='ar r' + BLD_SHR='f() ld -assert pure-text -o $$1 $$2; f' + CC='gcc' + CFLAGS='-I$(STAR_INC) -O -fPIC' + FC='f77' + FFLAGS='-O -PIC' + LINK='ln -s' + RANLIB='ranlib' + SHARE='.so.$(LIB_VERS)' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# SUN Sparcstations running SunOS 5.x (Solaris). +# --------------------------------------------- + sun4_Solaris) + AR_IN='ar -r' + BLD_SHR='f() ld -G -z text -o $$1 $$2; f' + CC='cc' + CFLAGS='-I$(STAR_INC) -O -K PIC' + FC='f77' + FFLAGS='-O -PIC' + HLINK='$(STAR_BIN)/hlink' + LINK='ln -s' + SHARE='.so' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# PC systems: +# ========== +# Intel PC running Linux. +# ---------------------- + ix86_Linux) + AR_IN='ar r' + CC='gcc' + CFLAGS='-O' + C_ROUTINES='rtl_random.c' + FC='gfortran' + FFLAGS='-fno-second-underscore -O' + HLINK='$(STAR_BIN)/hlink' + LINK='ln -s' + RANLIB='ranlib' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# Intel PC running Linux on 64 architecture. +# ----------------------------------------- + x86_64) + AR_IN='ar r' + CC='gcc' + CFLAGS='-O -fPIC' + C_ROUTINES='rtl_random.c' + FC='gfortran' + FFLAGS='-fno-second-underscore -O -fPIC' + HLINK='$(STAR_BIN)/hlink' + LINK='ln -s' + RANLIB='ranlib' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# Convex running ConvexOS. +# ------------------------ + convex) + AR_IN='ar r' + FC='fc' + FFLAGS='-O3' + CC='gcc' + CFLAGS='-I$(STAR_INC) -O -fPIC' + LINK='ln -s' + RANLIB='ranlib' + TAR_IN='tar -cvhf' + TAR_OUT='tar -xf' + echo "mk: Environment variables defined for $SYSTEM system" + ;; + +# IMPORTANT NOTE - Because Convex make doesn't support the -e +# qualifier (as stipulated by the POSIX standard) it will be +# necessary to use another version of make, for example the +# GNU one. This can be accomplished either by editing this script, +# or by setting up a link. + +# Issue a warning if SYSTEM is not recognised. + *) + SOURCE_VARIANT='unknown' + echo "mk: WARNING: value of SYSTEM = $SYSTEM not recognised..." + echo " ...assuming default system characteristics" + echo ' ...setting SOURCE_VARIANT to "unknown"' + ;; + esac + +# Invoke make with the appropriate environment variables set to override +# default macros defined in the makefile. + echo make -e $* + make -e $* + fi + +# End of script. diff --git a/src/slalib/moon.f b/src/slalib/moon.f new file mode 100644 index 0000000..eaf1c72 --- /dev/null +++ b/src/slalib/moon.f @@ -0,0 +1,362 @@ + SUBROUTINE sla_MOON (IY, ID, FD, PV) +*+ +* - - - - - +* M O O N +* - - - - - +* +* Approximate geocentric position and velocity of the Moon +* (single precision). +* +* Given: +* IY i year +* ID i day in year (1 = Jan 1st) +* FD r fraction of day +* +* Returned: +* PV r(6) Moon position & velocity vector +* +* Notes: +* +* 1 The date and time is TDB (loosely ET) in a Julian calendar +* which has been aligned to the ordinary Gregorian +* calendar for the interval 1900 March 1 to 2100 February 28. +* The year and day can be obtained by calling sla_CALYD or +* sla_CLYD. +* +* 2 The Moon 6-vector is Moon centre relative to Earth centre, +* mean equator and equinox of date. Position part, PV(1-3), +* is in AU; velocity part, PV(4-6), is in AU/sec. +* +* 3 The position is accurate to better than 0.5 arcminute +* in direction and 1000 km in distance. The velocity +* is accurate to better than 0.5"/hour in direction and +* 4 m/s in distance. (RMS figures with respect to JPL DE200 +* for the interval 1960-2025 are 14 arcsec and 0.2 arcsec/hour in +* longitude, 9 arcsec and 0.2 arcsec/hour in latitude, 350 km and +* 2 m/s in distance.) Note that the distance accuracy is +* comparatively poor because this routine is principally intended +* for computing topocentric direction. +* +* 4 This routine is only a partial implementation of the original +* Meeus algorithm (reference below), which offers 4 times the +* accuracy in direction and 30 times the accuracy in distance +* when fully implemented (as it is in sla_DMOON). +* +* Reference: +* Meeus, l'Astronomie, June 1984, p348. +* +* Called: sla_CS2C6 +* +* P.T.Wallace Starlink 8 December 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER IY,ID + REAL FD,PV(6) + + INTEGER ITP(4,4),ITL(4,39),ITB(4,29),I,IY4,N + REAL D2R,RATCON,ERADAU + REAL ELP0,ELP1,ELP1I,ELP1F + REAL EM0,EM1,EM1F + REAL EMP0,EMP1,EMP1I,EMP1F + REAL D0,D1,D1I,D1F + REAL F0,F1,F1I,F1F + REAL TL(39) + REAL TB(29) + REAL TP(4) + REAL YI,YF,T,ELP,EM,EMP,D,F,EL,ELD,COEFF,CEM,CEMP + REAL CD,CF,THETA,THETAD,B,BD,P,PD,SP,R,RD + REAL V(6),EPS,SINEPS,COSEPS + +* Degrees to radians + PARAMETER (D2R=1.745329252E-2) + +* Rate conversion factor: D2R**2/(86400*365.25) + PARAMETER (RATCON=9.652743551E-12) + +* Earth radius in AU: 6378.137/149597870 + PARAMETER (ERADAU=4.2635212653763E-5) + +* +* Coefficients for fundamental arguments +* +* Fixed term (deg), term in T (deg & whole revs + fraction per year) +* +* Moon's mean longitude + DATA ELP0,ELP1,ELP1I,ELP1F / + : 270.434164, 4812.678831, 4680., 132.678831 / +* +* Sun's mean anomaly + DATA EM0,EM1,EM1F / + : 358.475833, 359.990498, 359.990498 / +* +* Moon's mean anomaly + DATA EMP0,EMP1,EMP1I,EMP1F / + : 296.104608, 4771.988491, 4680., 91.988491 / +* +* Moon's mean elongation + DATA D0,D1,D1I,D1F / + : 350.737486, 4452.671142, 4320., 132.671142 / +* +* Mean distance of the Moon from its ascending node + DATA F0,F1,F1I,F1F / + : 11.250889, 4832.020251, 4680., 152.020251 / + +* +* Coefficients for Moon position +* +* T(N) = coefficient of term (deg) +* IT(N,1-4) = coefficients of M, M', D, F in argument +* +* Longitude +* M M' D F + DATA TL( 1)/ +6.288750 /, + : (ITL(I, 1),I=1,4)/ 0, +1, 0, 0 / + DATA TL( 2)/ +1.274018 /, + : (ITL(I, 2),I=1,4)/ 0, -1, +2, 0 / + DATA TL( 3)/ +0.658309 /, + : (ITL(I, 3),I=1,4)/ 0, 0, +2, 0 / + DATA TL( 4)/ +0.213616 /, + : (ITL(I, 4),I=1,4)/ 0, +2, 0, 0 / + DATA TL( 5)/ -0.185596 /, + : (ITL(I, 5),I=1,4)/ +1, 0, 0, 0 / + DATA TL( 6)/ -0.114336 /, + : (ITL(I, 6),I=1,4)/ 0, 0, 0, +2 / + DATA TL( 7)/ +0.058793 /, + : (ITL(I, 7),I=1,4)/ 0, -2, +2, 0 / + DATA TL( 8)/ +0.057212 /, + : (ITL(I, 8),I=1,4)/ -1, -1, +2, 0 / + DATA TL( 9)/ +0.053320 /, + : (ITL(I, 9),I=1,4)/ 0, +1, +2, 0 / + DATA TL(10)/ +0.045874 /, + : (ITL(I,10),I=1,4)/ -1, 0, +2, 0 / + DATA TL(11)/ +0.041024 /, + : (ITL(I,11),I=1,4)/ -1, +1, 0, 0 / + DATA TL(12)/ -0.034718 /, + : (ITL(I,12),I=1,4)/ 0, 0, +1, 0 / + DATA TL(13)/ -0.030465 /, + : (ITL(I,13),I=1,4)/ +1, +1, 0, 0 / + DATA TL(14)/ +0.015326 /, + : (ITL(I,14),I=1,4)/ 0, 0, +2, -2 / + DATA TL(15)/ -0.012528 /, + : (ITL(I,15),I=1,4)/ 0, +1, 0, +2 / + DATA TL(16)/ -0.010980 /, + : (ITL(I,16),I=1,4)/ 0, -1, 0, +2 / + DATA TL(17)/ +0.010674 /, + : (ITL(I,17),I=1,4)/ 0, -1, +4, 0 / + DATA TL(18)/ +0.010034 /, + : (ITL(I,18),I=1,4)/ 0, +3, 0, 0 / + DATA TL(19)/ +0.008548 /, + : (ITL(I,19),I=1,4)/ 0, -2, +4, 0 / + DATA TL(20)/ -0.007910 /, + : (ITL(I,20),I=1,4)/ +1, -1, +2, 0 / + DATA TL(21)/ -0.006783 /, + : (ITL(I,21),I=1,4)/ +1, 0, +2, 0 / + DATA TL(22)/ +0.005162 /, + : (ITL(I,22),I=1,4)/ 0, +1, -1, 0 / + DATA TL(23)/ +0.005000 /, + : (ITL(I,23),I=1,4)/ +1, 0, +1, 0 / + DATA TL(24)/ +0.004049 /, + : (ITL(I,24),I=1,4)/ -1, +1, +2, 0 / + DATA TL(25)/ +0.003996 /, + : (ITL(I,25),I=1,4)/ 0, +2, +2, 0 / + DATA TL(26)/ +0.003862 /, + : (ITL(I,26),I=1,4)/ 0, 0, +4, 0 / + DATA TL(27)/ +0.003665 /, + : (ITL(I,27),I=1,4)/ 0, -3, +2, 0 / + DATA TL(28)/ +0.002695 /, + : (ITL(I,28),I=1,4)/ -1, +2, 0, 0 / + DATA TL(29)/ +0.002602 /, + : (ITL(I,29),I=1,4)/ 0, +1, -2, -2 / + DATA TL(30)/ +0.002396 /, + : (ITL(I,30),I=1,4)/ -1, -2, +2, 0 / + DATA TL(31)/ -0.002349 /, + : (ITL(I,31),I=1,4)/ 0, +1, +1, 0 / + DATA TL(32)/ +0.002249 /, + : (ITL(I,32),I=1,4)/ -2, 0, +2, 0 / + DATA TL(33)/ -0.002125 /, + : (ITL(I,33),I=1,4)/ +1, +2, 0, 0 / + DATA TL(34)/ -0.002079 /, + : (ITL(I,34),I=1,4)/ +2, 0, 0, 0 / + DATA TL(35)/ +0.002059 /, + : (ITL(I,35),I=1,4)/ -2, -1, +2, 0 / + DATA TL(36)/ -0.001773 /, + : (ITL(I,36),I=1,4)/ 0, +1, +2, -2 / + DATA TL(37)/ -0.001595 /, + : (ITL(I,37),I=1,4)/ 0, 0, +2, +2 / + DATA TL(38)/ +0.001220 /, + : (ITL(I,38),I=1,4)/ -1, -1, +4, 0 / + DATA TL(39)/ -0.001110 /, + : (ITL(I,39),I=1,4)/ 0, +2, 0, +2 / +* +* Latitude +* M M' D F + DATA TB( 1)/ +5.128189 /, + : (ITB(I, 1),I=1,4)/ 0, 0, 0, +1 / + DATA TB( 2)/ +0.280606 /, + : (ITB(I, 2),I=1,4)/ 0, +1, 0, +1 / + DATA TB( 3)/ +0.277693 /, + : (ITB(I, 3),I=1,4)/ 0, +1, 0, -1 / + DATA TB( 4)/ +0.173238 /, + : (ITB(I, 4),I=1,4)/ 0, 0, +2, -1 / + DATA TB( 5)/ +0.055413 /, + : (ITB(I, 5),I=1,4)/ 0, -1, +2, +1 / + DATA TB( 6)/ +0.046272 /, + : (ITB(I, 6),I=1,4)/ 0, -1, +2, -1 / + DATA TB( 7)/ +0.032573 /, + : (ITB(I, 7),I=1,4)/ 0, 0, +2, +1 / + DATA TB( 8)/ +0.017198 /, + : (ITB(I, 8),I=1,4)/ 0, +2, 0, +1 / + DATA TB( 9)/ +0.009267 /, + : (ITB(I, 9),I=1,4)/ 0, +1, +2, -1 / + DATA TB(10)/ +0.008823 /, + : (ITB(I,10),I=1,4)/ 0, +2, 0, -1 / + DATA TB(11)/ +0.008247 /, + : (ITB(I,11),I=1,4)/ -1, 0, +2, -1 / + DATA TB(12)/ +0.004323 /, + : (ITB(I,12),I=1,4)/ 0, -2, +2, -1 / + DATA TB(13)/ +0.004200 /, + : (ITB(I,13),I=1,4)/ 0, +1, +2, +1 / + DATA TB(14)/ +0.003372 /, + : (ITB(I,14),I=1,4)/ -1, 0, -2, +1 / + DATA TB(15)/ +0.002472 /, + : (ITB(I,15),I=1,4)/ -1, -1, +2, +1 / + DATA TB(16)/ +0.002222 /, + : (ITB(I,16),I=1,4)/ -1, 0, +2, +1 / + DATA TB(17)/ +0.002072 /, + : (ITB(I,17),I=1,4)/ -1, -1, +2, -1 / + DATA TB(18)/ +0.001877 /, + : (ITB(I,18),I=1,4)/ -1, +1, 0, +1 / + DATA TB(19)/ +0.001828 /, + : (ITB(I,19),I=1,4)/ 0, -1, +4, -1 / + DATA TB(20)/ -0.001803 /, + : (ITB(I,20),I=1,4)/ +1, 0, 0, +1 / + DATA TB(21)/ -0.001750 /, + : (ITB(I,21),I=1,4)/ 0, 0, 0, +3 / + DATA TB(22)/ +0.001570 /, + : (ITB(I,22),I=1,4)/ -1, +1, 0, -1 / + DATA TB(23)/ -0.001487 /, + : (ITB(I,23),I=1,4)/ 0, 0, +1, +1 / + DATA TB(24)/ -0.001481 /, + : (ITB(I,24),I=1,4)/ +1, +1, 0, +1 / + DATA TB(25)/ +0.001417 /, + : (ITB(I,25),I=1,4)/ -1, -1, 0, +1 / + DATA TB(26)/ +0.001350 /, + : (ITB(I,26),I=1,4)/ -1, 0, 0, +1 / + DATA TB(27)/ +0.001330 /, + : (ITB(I,27),I=1,4)/ 0, 0, -1, +1 / + DATA TB(28)/ +0.001106 /, + : (ITB(I,28),I=1,4)/ 0, +3, 0, +1 / + DATA TB(29)/ +0.001020 /, + : (ITB(I,29),I=1,4)/ 0, 0, +4, -1 / +* +* Parallax +* M M' D F + DATA TP( 1)/ +0.051818 /, + : (ITP(I, 1),I=1,4)/ 0, +1, 0, 0 / + DATA TP( 2)/ +0.009531 /, + : (ITP(I, 2),I=1,4)/ 0, -1, +2, 0 / + DATA TP( 3)/ +0.007843 /, + : (ITP(I, 3),I=1,4)/ 0, 0, +2, 0 / + DATA TP( 4)/ +0.002824 /, + : (ITP(I, 4),I=1,4)/ 0, +2, 0, 0 / + + + +* Whole years & fraction of year, and years since J1900.0 + YI=FLOAT(IY-1900) + IY4=MOD(MOD(IY,4)+4,4) + YF=(FLOAT(4*(ID-1/(IY4+1))-IY4-2)+4.0*FD)/1461.0 + T=YI+YF + +* Moon's mean longitude + ELP=D2R*MOD(ELP0+ELP1I*YF+ELP1F*T,360.0) + +* Sun's mean anomaly + EM=D2R*MOD(EM0+EM1F*T,360.0) + +* Moon's mean anomaly + EMP=D2R*MOD(EMP0+EMP1I*YF+EMP1F*T,360.0) + +* Moon's mean elongation + D=D2R*MOD(D0+D1I*YF+D1F*T,360.0) + +* Mean distance of the moon from its ascending node + F=D2R*MOD(F0+F1I*YF+F1F*T,360.0) + +* Longitude + EL=0.0 + ELD=0.0 + DO N=39,1,-1 + COEFF=TL(N) + CEM=FLOAT(ITL(1,N)) + CEMP=FLOAT(ITL(2,N)) + CD=FLOAT(ITL(3,N)) + CF=FLOAT(ITL(4,N)) + THETA=CEM*EM+CEMP*EMP+CD*D+CF*F + THETAD=CEM*EM1+CEMP*EMP1+CD*D1+CF*F1 + EL=EL+COEFF*SIN(THETA) + ELD=ELD+COEFF*COS(THETA)*THETAD + END DO + EL=EL*D2R+ELP + ELD=RATCON*(ELD+ELP1/D2R) + +* Latitude + B=0.0 + BD=0.0 + DO N=29,1,-1 + COEFF=TB(N) + CEM=FLOAT(ITB(1,N)) + CEMP=FLOAT(ITB(2,N)) + CD=FLOAT(ITB(3,N)) + CF=FLOAT(ITB(4,N)) + THETA=CEM*EM+CEMP*EMP+CD*D+CF*F + THETAD=CEM*EM1+CEMP*EMP1+CD*D1+CF*F1 + B=B+COEFF*SIN(THETA) + BD=BD+COEFF*COS(THETA)*THETAD + END DO + B=B*D2R + BD=RATCON*BD + +* Parallax + P=0.0 + PD=0.0 + DO N=4,1,-1 + COEFF=TP(N) + CEM=FLOAT(ITP(1,N)) + CEMP=FLOAT(ITP(2,N)) + CD=FLOAT(ITP(3,N)) + CF=FLOAT(ITP(4,N)) + THETA=CEM*EM+CEMP*EMP+CD*D+CF*F + THETAD=CEM*EM1+CEMP*EMP1+CD*D1+CF*F1 + P=P+COEFF*COS(THETA) + PD=PD-COEFF*SIN(THETA)*THETAD + END DO + P=(P+0.950724)*D2R + PD=RATCON*PD + +* Transform parallax to distance (AU, AU/sec) + SP=SIN(P) + R=ERADAU/SP + RD=-R*PD/SP + +* Longitude, latitude to x,y,z (AU) + CALL sla_CS2C6(EL,B,R,ELD,BD,RD,V) + +* Mean obliquity + EPS=D2R*(23.45229-0.00013*T) + SINEPS=SIN(EPS) + COSEPS=COS(EPS) + +* Rotate Moon position and velocity into equatorial system + PV(1)=V(1) + PV(2)=V(2)*COSEPS-V(3)*SINEPS + PV(3)=V(2)*SINEPS+V(3)*COSEPS + PV(4)=V(4) + PV(5)=V(5)*COSEPS-V(6)*SINEPS + PV(6)=V(5)*SINEPS+V(6)*COSEPS + + END diff --git a/src/slalib/mxm.f b/src/slalib/mxm.f new file mode 100644 index 0000000..67ce113 --- /dev/null +++ b/src/slalib/mxm.f @@ -0,0 +1,55 @@ + SUBROUTINE sla_MXM (A, B, C) +*+ +* - - - - +* M X M +* - - - - +* +* Product of two 3x3 matrices: +* matrix C = matrix A x matrix B +* +* (single precision) +* +* Given: +* A real(3,3) matrix +* B real(3,3) matrix +* +* Returned: +* C real(3,3) matrix result +* +* To comply with the ANSI Fortran 77 standard, A, B and C must +* be different arrays. However, the routine is coded so as to +* work properly on the VAX and many other systems even if this +* rule is violated. +* +* P.T.Wallace Starlink 5 April 1990 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL A(3,3),B(3,3),C(3,3) + + INTEGER I,J,K + REAL W,WM(3,3) + + +* Multiply into scratch matrix + DO I=1,3 + DO J=1,3 + W=0.0 + DO K=1,3 + W=W+A(I,K)*B(K,J) + END DO + WM(I,J)=W + END DO + END DO + +* Return the result + DO J=1,3 + DO I=1,3 + C(I,J)=WM(I,J) + END DO + END DO + + END diff --git a/src/slalib/mxv.f b/src/slalib/mxv.f new file mode 100644 index 0000000..2935f72 --- /dev/null +++ b/src/slalib/mxv.f @@ -0,0 +1,47 @@ + SUBROUTINE sla_MXV (RM, VA, VB) +*+ +* - - - - +* M X V +* - - - - +* +* Performs the 3-D forward unitary transformation: +* +* vector VB = matrix RM * vector VA +* +* (single precision) +* +* Given: +* RM real(3,3) matrix +* VA real(3) vector +* +* Returned: +* VB real(3) result vector +* +* P.T.Wallace Starlink March 1986 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL RM(3,3),VA(3),VB(3) + + INTEGER I,J + REAL W,VW(3) + + +* Matrix RM * vector VA -> vector VW + DO J=1,3 + W=0.0 + DO I=1,3 + W=W+RM(J,I)*VA(I) + END DO + VW(J)=W + END DO + +* Vector VW -> vector VB + DO J=1,3 + VB(J)=VW(J) + END DO + + END diff --git a/src/slalib/nut.f b/src/slalib/nut.f new file mode 100644 index 0000000..bf2d196 --- /dev/null +++ b/src/slalib/nut.f @@ -0,0 +1,44 @@ + SUBROUTINE sla_NUT (DATE, RMATN) +*+ +* - - - - +* N U T +* - - - - +* +* Form the matrix of nutation for a given date - IAU 1980 theory +* (double precision) +* +* References: +* Final report of the IAU Working Group on Nutation, +* chairman P.K.Seidelmann, 1980. +* Kaplan,G.H., 1981, USNO circular no. 163, pA3-6. +* +* Given: +* DATE dp TDB (loosely ET) as Modified Julian Date +* (=JD-2400000.5) +* Returned: +* RMATN dp(3,3) nutation matrix +* +* The matrix is in the sense V(true) = RMATN * V(mean) +* +* Called: sla_NUTC, sla_DEULER +* +* P.T.Wallace Starlink 1 January 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,RMATN(3,3) + + DOUBLE PRECISION DPSI,DEPS,EPS0 + + + +* Nutation components and mean obliquity + CALL sla_NUTC(DATE,DPSI,DEPS,EPS0) + +* Rotation matrix + CALL sla_DEULER('XZX',EPS0,-DPSI,-(EPS0+DEPS),RMATN) + + END diff --git a/src/slalib/nutc.f b/src/slalib/nutc.f new file mode 100644 index 0000000..1f5890c --- /dev/null +++ b/src/slalib/nutc.f @@ -0,0 +1,442 @@ + SUBROUTINE sla_NUTC (DATE, DPSI, DEPS, EPS0) +*+ +* - - - - - +* N U T C +* - - - - - +* +* Nutation: longitude & obliquity components and mean +* obliquity - IAU 1980 theory (double precision) +* +* Given: +* +* DATE dp TDB (loosely ET) as Modified Julian Date +* (JD-2400000.5) +* Returned: +* +* DPSI,DEPS dp nutation in longitude,obliquity +* EPS0 dp mean obliquity +* +* References: +* Final report of the IAU Working Group on Nutation, +* chairman P.K.Seidelmann, 1980. +* Kaplan,G.H., 1981, USNO circular no. 163, pA3-6. +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,DPSI,DEPS,EPS0 + + DOUBLE PRECISION T2AS,AS2R,U2R + DOUBLE PRECISION T,EL,EL2,EL3 + DOUBLE PRECISION ELP,ELP2 + DOUBLE PRECISION F,F2,F4 + DOUBLE PRECISION D,D2,D4 + DOUBLE PRECISION OM,OM2 + DOUBLE PRECISION DP,DE + DOUBLE PRECISION A + + +* Turns to arc seconds + PARAMETER (T2AS=1296000D0) +* Arc seconds to radians + PARAMETER (AS2R=0.484813681109535994D-5) +* Units of 0.0001 arcsec to radians + PARAMETER (U2R=AS2R/1D4) + + + + +* Interval between basic epoch J2000.0 and current epoch (JC) + T=(DATE-51544.5D0)/36525D0 + +* +* FUNDAMENTAL ARGUMENTS in the FK5 reference system +* + +* Mean longitude of the Moon minus mean longitude of the Moon's perigee + EL=AS2R*(485866.733D0+(1325D0*T2AS+715922.633D0 + : +(31.310D0+0.064D0*T)*T)*T) + +* Mean longitude of the Sun minus mean longitude of the Sun's perigee + ELP=AS2R*(1287099.804D0+(99D0*T2AS+1292581.224D0 + : +(-0.577D0-0.012D0*T)*T)*T) + +* Mean longitude of the Moon minus mean longitude of the Moon's node + F=AS2R*(335778.877D0+(1342D0*T2AS+295263.137D0 + : +(-13.257D0+0.011D0*T)*T)*T) + +* Mean elongation of the Moon from the Sun + D=AS2R*(1072261.307D0+(1236D0*T2AS+1105601.328D0 + : +(-6.891D0+0.019D0*T)*T)*T) + +* Longitude of the mean ascending node of the lunar orbit on the +* ecliptic, measured from the mean equinox of date + OM=AS2R*(450160.280D0+(-5D0*T2AS-482890.539D0 + : +(7.455D0+0.008D0*T)*T)*T) + +* Multiples of arguments + EL2=EL+EL + EL3=EL2+EL + ELP2=ELP+ELP + F2=F+F + F4=F2+F2 + D2=D+D + D4=D2+D2 + OM2=OM+OM + + +* +* SERIES FOR THE NUTATION +* + DP=0D0 + DE=0D0 + +* 106 + DP=DP+SIN(ELP+D) +* 105 + DP=DP-SIN(F2+D4+OM2) +* 104 + DP=DP+SIN(EL2+D2) +* 103 + DP=DP-SIN(EL-F2+D2) +* 102 + DP=DP-SIN(EL+ELP-D2+OM) +* 101 + DP=DP-SIN(-ELP+F2+OM) +* 100 + DP=DP-SIN(EL-F2-D2) +* 99 + DP=DP-SIN(ELP+D2) +* 98 + DP=DP-SIN(F2-D+OM2) +* 97 + DP=DP-SIN(-F2+OM) +* 96 + DP=DP+SIN(-EL-ELP+D2+OM) +* 95 + DP=DP+SIN(ELP+F2+OM) +* 94 + DP=DP-SIN(EL+F2-D2) +* 93 + DP=DP+SIN(EL3+F2-D2+OM2) +* 92 + DP=DP+SIN(F4-D2+OM2) +* 91 + DP=DP-SIN(EL+D2+OM) +* 90 + DP=DP-SIN(EL2+F2+D2+OM2) +* 89 + A=EL2+F2-D2+OM + DP=DP+SIN(A) + DE=DE-COS(A) +* 88 + DP=DP+SIN(EL-ELP-D2) +* 87 + DP=DP+SIN(-EL+F4+OM2) +* 86 + A=-EL2+F2+D4+OM2 + DP=DP-SIN(A) + DE=DE+COS(A) +* 85 + A=EL+F2+D2+OM + DP=DP-SIN(A) + DE=DE+COS(A) +* 84 + A=EL+ELP+F2-D2+OM2 + DP=DP+SIN(A) + DE=DE-COS(A) +* 83 + DP=DP-SIN(EL2-D4) +* 82 + A=-EL+F2+D4+OM2 + DP=DP-2D0*SIN(A) + DE=DE+COS(A) +* 81 + A=-EL2+F2+D2+OM2 + DP=DP+SIN(A) + DE=DE-COS(A) +* 80 + DP=DP-SIN(EL-D4) +* 79 + A=-EL+OM2 + DP=DP+SIN(A) + DE=DE-COS(A) +* 78 + A=F2+D+OM2 + DP=DP+2D0*SIN(A) + DE=DE-COS(A) +* 77 + DP=DP+2D0*SIN(EL3) +* 76 + A=EL+OM2 + DP=DP-2D0*SIN(A) + DE=DE+COS(A) +* 75 + A=EL2+OM + DP=DP+2D0*SIN(A) + DE=DE-COS(A) +* 74 + A=-EL+F2-D2+OM + DP=DP-2D0*SIN(A) + DE=DE+COS(A) +* 73 + A=EL+ELP+F2+OM2 + DP=DP+2D0*SIN(A) + DE=DE-COS(A) +* 72 + A=-ELP+F2+D2+OM2 + DP=DP-3D0*SIN(A) + DE=DE+COS(A) +* 71 + A=EL3+F2+OM2 + DP=DP-3D0*SIN(A) + DE=DE+COS(A) +* 70 + A=-EL2+OM + DP=DP-2D0*SIN(A) + DE=DE+COS(A) +* 69 + A=-EL-ELP+F2+D2+OM2 + DP=DP-3D0*SIN(A) + DE=DE+COS(A) +* 68 + A=EL-ELP+F2+OM2 + DP=DP-3D0*SIN(A) + DE=DE+COS(A) +* 67 + DP=DP+3D0*SIN(EL+F2) +* 66 + DP=DP-3D0*SIN(EL+ELP) +* 65 + DP=DP-4D0*SIN(D) +* 64 + DP=DP+4D0*SIN(EL-F2) +* 63 + DP=DP-4D0*SIN(ELP-D2) +* 62 + A=EL2+F2+OM + DP=DP-5D0*SIN(A) + DE=DE+3D0*COS(A) +* 61 + DP=DP+5D0*SIN(EL-ELP) +* 60 + A=-D2+OM + DP=DP-5D0*SIN(A) + DE=DE+3D0*COS(A) +* 59 + A=EL+F2-D2+OM + DP=DP+6D0*SIN(A) + DE=DE-3D0*COS(A) +* 58 + A=F2+D2+OM + DP=DP-7D0*SIN(A) + DE=DE+3D0*COS(A) +* 57 + A=D2+OM + DP=DP-6D0*SIN(A) + DE=DE+3D0*COS(A) +* 56 + A=EL2+F2-D2+OM2 + DP=DP+6D0*SIN(A) + DE=DE-3D0*COS(A) +* 55 + DP=DP+6D0*SIN(EL+D2) +* 54 + A=EL+F2+D2+OM2 + DP=DP-8D0*SIN(A) + DE=DE+3D0*COS(A) +* 53 + A=-ELP+F2+OM2 + DP=DP-7D0*SIN(A) + DE=DE+3D0*COS(A) +* 52 + A=ELP+F2+OM2 + DP=DP+7D0*SIN(A) + DE=DE-3D0*COS(A) +* 51 + DP=DP-7D0*SIN(EL+ELP-D2) +* 50 + A=-EL+F2+D2+OM + DP=DP-10D0*SIN(A) + DE=DE+5D0*COS(A) +* 49 + A=EL-D2+OM + DP=DP-13D0*SIN(A) + DE=DE+7D0*COS(A) +* 48 + A=-EL+D2+OM + DP=DP+16D0*SIN(A) + DE=DE-8D0*COS(A) +* 47 + A=-EL+F2+OM + DP=DP+21D0*SIN(A) + DE=DE-10D0*COS(A) +* 46 + DP=DP+26D0*SIN(F2) + DE=DE-COS(F2) +* 45 + A=EL2+F2+OM2 + DP=DP-31D0*SIN(A) + DE=DE+13D0*COS(A) +* 44 + A=EL+F2-D2+OM2 + DP=DP+29D0*SIN(A) + DE=DE-12D0*COS(A) +* 43 + DP=DP+29D0*SIN(EL2) + DE=DE-COS(EL2) +* 42 + A=F2+D2+OM2 + DP=DP-38D0*SIN(A) + DE=DE+16D0*COS(A) +* 41 + A=EL+F2+OM + DP=DP-51D0*SIN(A) + DE=DE+27D0*COS(A) +* 40 + A=-EL+F2+D2+OM2 + DP=DP-59D0*SIN(A) + DE=DE+26D0*COS(A) +* 39 + A=-EL+OM + DP=DP+(-58D0-0.1D0*T)*SIN(A) + DE=DE+32D0*COS(A) +* 38 + A=EL+OM + DP=DP+(63D0+0.1D0*T)*SIN(A) + DE=DE-33D0*COS(A) +* 37 + DP=DP+63D0*SIN(D2) + DE=DE-2D0*COS(D2) +* 36 + A=-EL+F2+OM2 + DP=DP+123D0*SIN(A) + DE=DE-53D0*COS(A) +* 35 + A=EL-D2 + DP=DP-158D0*SIN(A) + DE=DE-COS(A) +* 34 + A=EL+F2+OM2 + DP=DP-301D0*SIN(A) + DE=DE+(129D0-0.1D0*T)*COS(A) +* 33 + A=F2+OM + DP=DP+(-386D0-0.4D0*T)*SIN(A) + DE=DE+200D0*COS(A) +* 32 + DP=DP+(712D0+0.1D0*T)*SIN(EL) + DE=DE-7D0*COS(EL) +* 31 + A=F2+OM2 + DP=DP+(-2274D0-0.2D0*T)*SIN(A) + DE=DE+(977D0-0.5D0*T)*COS(A) +* 30 + DP=DP-SIN(ELP+F2-D2) +* 29 + DP=DP+SIN(-EL+D+OM) +* 28 + DP=DP+SIN(ELP+OM2) +* 27 + DP=DP-SIN(ELP-F2+D2) +* 26 + DP=DP+SIN(-F2+D2+OM) +* 25 + DP=DP+SIN(EL2+ELP-D2) +* 24 + DP=DP-4D0*SIN(EL-D) +* 23 + A=ELP+F2-D2+OM + DP=DP+4D0*SIN(A) + DE=DE-2D0*COS(A) +* 22 + A=EL2-D2+OM + DP=DP+4D0*SIN(A) + DE=DE-2D0*COS(A) +* 21 + A=-ELP+F2-D2+OM + DP=DP-5D0*SIN(A) + DE=DE+3D0*COS(A) +* 20 + A=-EL2+D2+OM + DP=DP-6D0*SIN(A) + DE=DE+3D0*COS(A) +* 19 + A=-ELP+OM + DP=DP-12D0*SIN(A) + DE=DE+6D0*COS(A) +* 18 + A=ELP2+F2-D2+OM2 + DP=DP+(-16D0+0.1D0*T)*SIN(A) + DE=DE+7D0*COS(A) +* 17 + A=ELP+OM + DP=DP-15D0*SIN(A) + DE=DE+9D0*COS(A) +* 16 + DP=DP+(17D0-0.1D0*T)*SIN(ELP2) +* 15 + DP=DP-22D0*SIN(F2-D2) +* 14 + A=EL2-D2 + DP=DP+48D0*SIN(A) + DE=DE+COS(A) +* 13 + A=F2-D2+OM + DP=DP+(129D0+0.1D0*T)*SIN(A) + DE=DE-70D0*COS(A) +* 12 + A=-ELP+F2-D2+OM2 + DP=DP+(217D0-0.5D0*T)*SIN(A) + DE=DE+(-95D0+0.3D0*T)*COS(A) +* 11 + A=ELP+F2-D2+OM2 + DP=DP+(-517D0+1.2D0*T)*SIN(A) + DE=DE+(224D0-0.6D0*T)*COS(A) +* 10 + DP=DP+(1426D0-3.4D0*T)*SIN(ELP) + DE=DE+(54D0-0.1D0*T)*COS(ELP) +* 9 + A=F2-D2+OM2 + DP=DP+(-13187D0-1.6D0*T)*SIN(A) + DE=DE+(5736D0-3.1D0*T)*COS(A) +* 8 + DP=DP+SIN(EL2-F2+OM) +* 7 + A=-ELP2+F2-D2+OM + DP=DP-2D0*SIN(A) + DE=DE+1D0*COS(A) +* 6 + DP=DP-3D0*SIN(EL-ELP-D) +* 5 + A=-EL2+F2+OM2 + DP=DP-3D0*SIN(A) + DE=DE+1D0*COS(A) +* 4 + DP=DP+11D0*SIN(EL2-F2) +* 3 + A=-EL2+F2+OM + DP=DP+46D0*SIN(A) + DE=DE-24D0*COS(A) +* 2 + DP=DP+(2062D0+0.2D0*T)*SIN(OM2) + DE=DE+(-895D0+0.5D0*T)*COS(OM2) +* 1 + DP=DP+(-171996D0-174.2D0*T)*SIN(OM) + DE=DE+(92025D0+8.9D0*T)*COS(OM) + +* Convert results to radians + DPSI=DP*U2R + DEPS=DE*U2R + +* Mean obliquity + EPS0=AS2R*(84381.448D0+ + : (-46.8150D0+ + : (-0.00059D0+ + : 0.001813D0*T)*T)*T) + + END diff --git a/src/slalib/oap.f b/src/slalib/oap.f new file mode 100644 index 0000000..6376397 --- /dev/null +++ b/src/slalib/oap.f @@ -0,0 +1,172 @@ + SUBROUTINE sla_OAP (TYPE, OB1, OB2, DATE, DUT, ELONGM, PHIM, + : HM, XP, YP, TDK, PMB, RH, WL, TLR, + : RAP, DAP) +*+ +* - - - - +* O A P +* - - - - +* +* Observed to apparent place +* +* Given: +* TYPE c*(*) type of coordinates - 'R', 'H' or 'A' (see below) +* OB1 d observed Az, HA or RA (radians; Az is N=0,E=90) +* OB2 d observed ZD or Dec (radians) +* DATE d UTC date/time (modified Julian Date, JD-2400000.5) +* DUT d delta UT: UT1-UTC (UTC seconds) +* ELONGM d mean longitude of the observer (radians, east +ve) +* PHIM d mean geodetic latitude of the observer (radians) +* HM d observer's height above sea level (metres) +* XP d polar motion x-coordinate (radians) +* YP d polar motion y-coordinate (radians) +* TDK d local ambient temperature (DegK; std=273.155D0) +* PMB d local atmospheric pressure (mB; std=1013.25D0) +* RH d local relative humidity (in the range 0D0-1D0) +* WL d effective wavelength (micron, e.g. 0.55D0) +* TLR d tropospheric lapse rate (DegK/metre, e.g. 0.0065D0) +* +* Returned: +* RAP d geocentric apparent right ascension +* DAP d geocentric apparent declination +* +* Notes: +* +* 1) Only the first character of the TYPE argument is significant. +* 'R' or 'r' indicates that OBS1 and OBS2 are the observed Right +* Ascension and Declination; 'H' or 'h' indicates that they are +* Hour Angle (West +ve) and Declination; anything else ('A' or +* 'a' is recommended) indicates that OBS1 and OBS2 are Azimuth +* (North zero, East is 90 deg) and zenith distance. (Zenith +* distance is used rather than elevation in order to reflect the +* fact that no allowance is made for depression of the horizon.) +* +* 2) The accuracy of the result is limited by the corrections for +* refraction. Providing the meteorological parameters are +* known accurately and there are no gross local effects, the +* predicted apparent RA,Dec should be within about 0.1 arcsec +* for a zenith distance of less than 70 degrees. Even at a +* topocentric zenith distance of 90 degrees, the accuracy in +* elevation should be better than 1 arcmin; useful results +* are available for a further 3 degrees, beyond which the +* sla_REFRO routine returns a fixed value of the refraction. +* The complementary routines sla_AOP (or sla_AOPQK) and sla_OAP +* (or sla_OAPQK) are self-consistent to better than 1 micro- +* arcsecond all over the celestial sphere. +* +* 3) It is advisable to take great care with units, as even +* unlikely values of the input parameters are accepted and +* processed in accordance with the models used. +* +* 4) "Observed" Az,El means the position that would be seen by a +* perfect theodolite located at the observer. This is +* related to the observed HA,Dec via the standard rotation, using +* the geodetic latitude (corrected for polar motion), while the +* observed HA and RA are related simply through the local +* apparent ST. "Observed" RA,Dec or HA,Dec thus means the +* position that would be seen by a perfect equatorial located +* at the observer and with its polar axis aligned to the +* Earth's axis of rotation (n.b. not to the refracted pole). +* By removing from the observed place the effects of +* atmospheric refraction and diurnal aberration, the +* geocentric apparent RA,Dec is obtained. +* +* 5) Frequently, mean rather than apparent RA,Dec will be required, +* in which case further transformations will be necessary. The +* sla_AMP etc routines will convert the apparent RA,Dec produced +* by the present routine into an "FK5" (J2000) mean place, by +* allowing for the Sun's gravitational lens effect, annual +* aberration, nutation and precession. Should "FK4" (1950) +* coordinates be needed, the routines sla_FK524 etc will also +* need to be applied. +* +* 6) To convert to apparent RA,Dec the coordinates read from a +* real telescope, corrections would have to be applied for +* encoder zero points, gear and encoder errors, tube flexure, +* the position of the rotator axis and the pointing axis +* relative to it, non-perpendicularity between the mounting +* axes, and finally for the tilt of the azimuth or polar axis +* of the mounting (with appropriate corrections for mount +* flexures). Some telescopes would, of course, exhibit other +* properties which would need to be accounted for at the +* appropriate point in the sequence. +* +* 7) The star-independent apparent-to-observed-place parameters +* in AOPRMS may be computed by means of the sla_AOPPA routine. +* If nothing has changed significantly except the time, the +* sla_AOPPAT routine may be used to perform the requisite +* partial recomputation of AOPRMS. +* +* 8) The DATE argument is UTC expressed as an MJD. This is, +* strictly speaking, wrong, because of leap seconds. However, +* as long as the delta UT and the UTC are consistent there +* are no difficulties, except during a leap second. In this +* case, the start of the 61st second of the final minute should +* begin a new MJD day and the old pre-leap delta UT should +* continue to be used. As the 61st second completes, the MJD +* should revert to the start of the day as, simultaneously, +* the delta UTC changes by one second to its post-leap new value. +* +* 9) The delta UT (UT1-UTC) is tabulated in IERS circulars and +* elsewhere. It increases by exactly one second at the end of +* each UTC leap second, introduced in order to keep delta UT +* within +/- 0.9 seconds. +* +* 10) IMPORTANT -- TAKE CARE WITH THE LONGITUDE SIGN CONVENTION. +* The longitude required by the present routine is east-positive, +* in accordance with geographical convention (and right-handed). +* In particular, note that the longitudes returned by the +* sla_OBS routine are west-positive, following astronomical +* usage, and must be reversed in sign before use in the present +* routine. +* +* 11) The polar coordinates XP,YP can be obtained from IERS +* circulars and equivalent publications. The maximum amplitude +* is about 0.3 arcseconds. If XP,YP values are unavailable, +* use XP=YP=0D0. See page B60 of the 1988 Astronomical Almanac +* for a definition of the two angles. +* +* 12) The height above sea level of the observing station, HM, +* can be obtained from the Astronomical Almanac (Section J +* in the 1988 edition), or via the routine sla_OBS. If P, +* the pressure in millibars, is available, an adequate +* estimate of HM can be obtained from the expression +* +* HM ~ -29.3D0*TSL*LOG(P/1013.25D0). +* +* where TSL is the approximate sea-level air temperature in +* deg K (see Astrophysical Quantities, C.W.Allen, 3rd edition, +* section 52). Similarly, if the pressure P is not known, +* it can be estimated from the height of the observing +* station, HM as follows: +* +* P ~ 1013.25D0*EXP(-HM/(29.3D0*TSL)). +* +* Note, however, that the refraction is proportional to the +* pressure and that an accurate P value is important for +* precise work. +* +* 13) The azimuths etc used by the present routine are with respect +* to the celestial pole. Corrections from the terrestrial pole +* can be computed using sla_POLMO. +* +* Called: sla_AOPPA, sla_OAPQK +* +* P.T.Wallace Starlink 6 September 1999 +* +* Copyright (C) 1999 P.T.Wallace and CCLRC +*- + + IMPLICIT NONE + + CHARACTER*(*) TYPE + DOUBLE PRECISION OB1,OB2,DATE,DUT,ELONGM,PHIM,HM, + : XP,YP,TDK,PMB,RH,WL,TLR,RAP,DAP + + DOUBLE PRECISION AOPRMS(14) + + + CALL sla_AOPPA(DATE,DUT,ELONGM,PHIM,HM,XP,YP,TDK,PMB,RH,WL,TLR, + : AOPRMS) + CALL sla_OAPQK(TYPE,OB1,OB2,AOPRMS,RAP,DAP) + + END diff --git a/src/slalib/oapqk.f b/src/slalib/oapqk.f new file mode 100644 index 0000000..c50feb1 --- /dev/null +++ b/src/slalib/oapqk.f @@ -0,0 +1,233 @@ + SUBROUTINE sla_OAPQK (TYPE, OB1, OB2, AOPRMS, RAP, DAP) +*+ +* - - - - - - +* O A P Q K +* - - - - - - +* +* Quick observed to apparent place +* +* Given: +* TYPE c*(*) type of coordinates - 'R', 'H' or 'A' (see below) +* OB1 d observed Az, HA or RA (radians; Az is N=0,E=90) +* OB2 d observed ZD or Dec (radians) +* AOPRMS d(14) star-independent apparent-to-observed parameters: +* +* (1) geodetic latitude (radians) +* (2,3) sine and cosine of geodetic latitude +* (4) magnitude of diurnal aberration vector +* (5) height (HM) +* (6) ambient temperature (T) +* (7) pressure (P) +* (8) relative humidity (RH) +* (9) wavelength (WL) +* (10) lapse rate (TLR) +* (11,12) refraction constants A and B (radians) +* (13) longitude + eqn of equinoxes + sidereal DUT (radians) +* (14) local apparent sidereal time (radians) +* +* Returned: +* RAP d geocentric apparent right ascension +* DAP d geocentric apparent declination +* +* Notes: +* +* 1) Only the first character of the TYPE argument is significant. +* 'R' or 'r' indicates that OBS1 and OBS2 are the observed Right +* Ascension and Declination; 'H' or 'h' indicates that they are +* Hour Angle (West +ve) and Declination; anything else ('A' or +* 'a' is recommended) indicates that OBS1 and OBS2 are Azimuth +* (North zero, East is 90 deg) and zenith distance. (Zenith +* distance is used rather than elevation in order to reflect the +* fact that no allowance is made for depression of the horizon.) +* +* 2) The accuracy of the result is limited by the corrections for +* refraction. Providing the meteorological parameters are +* known accurately and there are no gross local effects, the +* predicted apparent RA,Dec should be within about 0.1 arcsec +* for a zenith distance of less than 70 degrees. Even at a +* topocentric zenith distance of 90 degrees, the accuracy in +* elevation should be better than 1 arcmin; useful results +* are available for a further 3 degrees, beyond which the +* sla_REFRO routine returns a fixed value of the refraction. +* The complementary routines sla_AOP (or sla_AOPQK) and sla_OAP +* (or sla_OAPQK) are self-consistent to better than 1 micro- +* arcsecond all over the celestial sphere. +* +* 3) It is advisable to take great care with units, as even +* unlikely values of the input parameters are accepted and +* processed in accordance with the models used. +* +* 5) "Observed" Az,El means the position that would be seen by a +* perfect theodolite located at the observer. This is +* related to the observed HA,Dec via the standard rotation, using +* the geodetic latitude (corrected for polar motion), while the +* observed HA and RA are related simply through the local +* apparent ST. "Observed" RA,Dec or HA,Dec thus means the +* position that would be seen by a perfect equatorial located +* at the observer and with its polar axis aligned to the +* Earth's axis of rotation (n.b. not to the refracted pole). +* By removing from the observed place the effects of +* atmospheric refraction and diurnal aberration, the +* geocentric apparent RA,Dec is obtained. +* +* 5) Frequently, mean rather than apparent RA,Dec will be required, +* in which case further transformations will be necessary. The +* sla_AMP etc routines will convert the apparent RA,Dec produced +* by the present routine into an "FK5" (J2000) mean place, by +* allowing for the Sun's gravitational lens effect, annual +* aberration, nutation and precession. Should "FK4" (1950) +* coordinates be needed, the routines sla_FK524 etc will also +* need to be applied. +* +* 6) To convert to apparent RA,Dec the coordinates read from a +* real telescope, corrections would have to be applied for +* encoder zero points, gear and encoder errors, tube flexure, +* the position of the rotator axis and the pointing axis +* relative to it, non-perpendicularity between the mounting +* axes, and finally for the tilt of the azimuth or polar axis +* of the mounting (with appropriate corrections for mount +* flexures). Some telescopes would, of course, exhibit other +* properties which would need to be accounted for at the +* appropriate point in the sequence. +* +* 7) The star-independent apparent-to-observed-place parameters +* in AOPRMS may be computed by means of the sla_AOPPA routine. +* If nothing has changed significantly except the time, the +* sla_AOPPAT routine may be used to perform the requisite +* partial recomputation of AOPRMS. +* +* 8) The azimuths etc used by the present routine are with respect +* to the celestial pole. Corrections from the terrestrial pole +* can be computed using sla_POLMO. +* +* Called: sla_DCS2C, sla_DCC2S, sla_REFRO, sla_DRANRM +* +* P.T.Wallace Starlink 23 June 1997 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER*(*) TYPE + DOUBLE PRECISION OB1,OB2,AOPRMS(14),RAP,DAP + +* Breakpoint for fast/slow refraction algorithm: +* ZD greater than arctan(4), (see sla_REFCO routine) +* or vector Z less than cosine(arctan(Z)) = 1/sqrt(17) + DOUBLE PRECISION ZBREAK + PARAMETER (ZBREAK=0.242535625D0) + + CHARACTER C + DOUBLE PRECISION C1,C2,SPHI,CPHI,ST,CE,XAEO,YAEO,ZAEO,V(3), + : XMHDO,YMHDO,ZMHDO,AZ,SZ,ZDO,TZ,DREF,ZDT, + : XAET,YAET,ZAET,XMHDA,YMHDA,ZMHDA,DIURAB,F,HMA + + DOUBLE PRECISION sla_DRANRM + + + +* Coordinate type + C = TYPE(1:1) + +* Coordinates + C1 = OB1 + C2 = OB2 + +* Sin, cos of latitude + SPHI = AOPRMS(2) + CPHI = AOPRMS(3) + +* Local apparent sidereal time + ST = AOPRMS(14) + +* Standardise coordinate type + IF (C.EQ.'R'.OR.C.EQ.'r') THEN + C = 'R' + ELSE IF (C.EQ.'H'.OR.C.EQ.'h') THEN + C = 'H' + ELSE + C = 'A' + END IF + +* If Az,ZD convert to Cartesian (S=0,E=90) + IF (C.EQ.'A') THEN + CE = SIN(C2) + XAEO = -COS(C1)*CE + YAEO = SIN(C1)*CE + ZAEO = COS(C2) + ELSE + +* If RA,Dec convert to HA,Dec + IF (C.EQ.'R') THEN + C1 = ST-C1 + END IF + +* To Cartesian -HA,Dec + CALL sla_DCS2C(-C1,C2,V) + XMHDO = V(1) + YMHDO = V(2) + ZMHDO = V(3) + +* To Cartesian Az,El (S=0,E=90) + XAEO = SPHI*XMHDO-CPHI*ZMHDO + YAEO = YMHDO + ZAEO = CPHI*XMHDO+SPHI*ZMHDO + END IF + +* Azimuth (S=0,E=90) + IF (XAEO.NE.0D0.OR.YAEO.NE.0D0) THEN + AZ = ATAN2(YAEO,XAEO) + ELSE + AZ = 0D0 + END IF + +* Sine of observed ZD, and observed ZD + SZ = SQRT(XAEO*XAEO+YAEO*YAEO) + ZDO = ATAN2(SZ,ZAEO) + +* +* Refraction +* ---------- + +* Large zenith distance? + IF (ZAEO.GE.ZBREAK) THEN + +* Fast algorithm using two constant model + TZ = SZ/ZAEO + DREF = AOPRMS(11)*TZ+AOPRMS(12)*TZ*TZ*TZ + + ELSE + +* Rigorous algorithm for large ZD + CALL sla_REFRO(ZDO,AOPRMS(5),AOPRMS(6),AOPRMS(7),AOPRMS(8), + : AOPRMS(9),AOPRMS(1),AOPRMS(10),1D-8,DREF) + END IF + + ZDT = ZDO+DREF + +* To Cartesian Az,ZD + CE = SIN(ZDT) + XAET = COS(AZ)*CE + YAET = SIN(AZ)*CE + ZAET = COS(ZDT) + +* Cartesian Az,ZD to Cartesian -HA,Dec + XMHDA = SPHI*XAET+CPHI*ZAET + YMHDA = YAET + ZMHDA = -CPHI*XAET+SPHI*ZAET + +* Diurnal aberration + DIURAB = -AOPRMS(4) + F = (1D0-DIURAB*YMHDA) + V(1) = F*XMHDA + V(2) = F*(YMHDA+DIURAB) + V(3) = F*ZMHDA + +* To spherical -HA,Dec + CALL sla_DCC2S(V,HMA,DAP) + +* Right Ascension + RAP = sla_DRANRM(ST+HMA) + + END diff --git a/src/slalib/obs.f b/src/slalib/obs.f new file mode 100644 index 0000000..756678b --- /dev/null +++ b/src/slalib/obs.f @@ -0,0 +1,844 @@ + SUBROUTINE sla_OBS (N, C, NAME, W, P, H) +*+ +* - - - - +* O B S +* - - - - +* +* Parameters of selected groundbased observing stations +* +* Given: +* N int number specifying observing station +* +* Either given or returned +* C c*(*) identifier specifying observing station +* +* Returned: +* NAME c*(*) name of specified observing station +* W dp longitude (radians, West +ve) +* P dp geodetic latitude (radians, North +ve) +* H dp height above sea level (metres) +* +* Notes: +* +* Station identifiers C may be up to 10 characters long, +* and station names NAME may be up to 40 characters long. +* +* C and N are alternative ways of specifying the observing +* station. The C option, which is the most generally useful, +* may be selected by specifying an N value of zero or less. +* If N is 1 or more, the parameters of the Nth station +* in the currently supported list are interrogated, and +* the station identifier C is returned as well as NAME, W, +* P and H. +* +* If the station parameters are not available, either because +* the station identifier C is not recognized, or because an +* N value greater than the number of stations supported is +* given, a name of '?' is returned and C, W, P and H are left +* in their current states. +* +* Programs can obtain a list of all currently supported +* stations by calling the routine repeatedly, with N=1,2,3... +* When NAME='?' is seen, the list of stations has been +* exhausted. +* +* Station numbers, identifiers, names and other details are +* subject to change and should not be hardwired into +* application programs. +* +* All station identifiers C are uppercase only; lowercase +* characters must be converted to uppercase by the calling +* program. The station names returned may contain both upper- +* and lowercase. All characters up to the first space are +* checked; thus an abbreviated ID will return the parameters +* for the first station in the list which matches the +* abbreviation supplied, and no station in the list will ever +* contain embedded spaces. C must not have leading spaces. +* +* IMPORTANT -- BEWARE OF THE LONGITUDE SIGN CONVENTION. The +* longitude returned by sla_OBS is west-positive in accordance +* with astronomical usage. However, this sign convention is +* left-handed and is the opposite of the one used by geographers; +* elsewhere in SLALIB the preferable east-positive convention is +* used. In particular, note that for use in sla_AOP, sla_AOPPA +* and sla_OAP the sign of the longitude must be reversed. +* +* Users are urged to inform the author of any improvements +* they would like to see made. For example: +* +* typographical corrections +* more accurate parameters +* better station identifiers or names +* additional stations +* +* P.T.Wallace Starlink 21 April 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER N + CHARACTER C*(*),NAME*(*) + DOUBLE PRECISION W,P,H + + INTEGER NMAX,M,NS,I + CHARACTER*10 CC + + DOUBLE PRECISION AS2R,WEST,NORTH,EAST,SOUTH + INTEGER ID,IAM + REAL AS + PARAMETER (AS2R=0.484813681109535994D-5) + +* Table of station identifiers + PARAMETER (NMAX=75) + CHARACTER*10 CTAB(NMAX) + DATA CTAB (1) /'AAT '/ + DATA CTAB (2) /'LPO4.2 '/ + DATA CTAB (3) /'LPO2.5 '/ + DATA CTAB (4) /'LPO1 '/ + DATA CTAB (5) /'LICK120 '/ + DATA CTAB (6) /'MMT '/ + DATA CTAB (7) /'DAO72 '/ + DATA CTAB (8) /'DUPONT '/ + DATA CTAB (9) /'MTHOP1.5 '/ + DATA CTAB (10) /'STROMLO74 '/ + DATA CTAB (11) /'ANU2.3 '/ + DATA CTAB (12) /'GBVA140 '/ + DATA CTAB (13) /'TOLOLO4M '/ + DATA CTAB (14) /'TOLOLO1.5M'/ + DATA CTAB (15) /'TIDBINBLA '/ + DATA CTAB (16) /'BLOEMF '/ + DATA CTAB (17) /'BOSQALEGRE'/ + DATA CTAB (18) /'FLAGSTF61 '/ + DATA CTAB (19) /'LOWELL72 '/ + DATA CTAB (20) /'HARVARD '/ + DATA CTAB (21) /'OKAYAMA '/ + DATA CTAB (22) /'KPNO158 '/ + DATA CTAB (23) /'KPNO90 '/ + DATA CTAB (24) /'KPNO84 '/ + DATA CTAB (25) /'KPNO36FT '/ + DATA CTAB (26) /'KOTTAMIA '/ + DATA CTAB (27) /'ESO3.6 '/ + DATA CTAB (28) /'MAUNAK88 '/ + DATA CTAB (29) /'UKIRT '/ + DATA CTAB (30) /'QUEBEC1.6 '/ + DATA CTAB (31) /'MTEKAR '/ + DATA CTAB (32) /'MTLEMMON60'/ + DATA CTAB (33) /'MCDONLD2.7'/ + DATA CTAB (34) /'MCDONLD2.1'/ + DATA CTAB (35) /'PALOMAR200'/ + DATA CTAB (36) /'PALOMAR60 '/ + DATA CTAB (37) /'DUNLAP74 '/ + DATA CTAB (38) /'HPROV1.93 '/ + DATA CTAB (39) /'HPROV1.52 '/ + DATA CTAB (40) /'SANPM83 '/ + DATA CTAB (41) /'SAAO74 '/ + DATA CTAB (42) /'TAUTNBG '/ + DATA CTAB (43) /'CATALINA61'/ + DATA CTAB (44) /'STEWARD90 '/ + DATA CTAB (45) /'USSR6 '/ + DATA CTAB (46) /'ARECIBO '/ + DATA CTAB (47) /'CAMB5KM '/ + DATA CTAB (48) /'CAMB1MILE '/ + DATA CTAB (49) /'EFFELSBERG'/ + DATA CTAB (50) /'GBVA300 '/ + DATA CTAB (51) /'JODRELL1 '/ + DATA CTAB (52) /'PARKES '/ + DATA CTAB (53) /'VLA '/ + DATA CTAB (54) /'SUGARGROVE'/ + DATA CTAB (55) /'USSR600 '/ + DATA CTAB (56) /'NOBEYAMA '/ + DATA CTAB (57) /'JCMT '/ + DATA CTAB (58) /'ESONTT '/ + DATA CTAB (59) /'ST.ANDREWS'/ + DATA CTAB (60) /'APO3.5 '/ + DATA CTAB (61) /'KECK1 '/ + DATA CTAB (62) /'TAUTSCHM '/ + DATA CTAB (63) /'PALOMAR48 '/ + DATA CTAB (64) /'UKST '/ + DATA CTAB (65) /'KISO '/ + DATA CTAB (66) /'ESOSCHM '/ + DATA CTAB (67) /'ATCA '/ + DATA CTAB (68) /'MOPRA '/ + DATA CTAB (69) /'SUBARU '/ + DATA CTAB (70) /'CFHT '/ + DATA CTAB (71) /'KECK2 '/ + DATA CTAB (72) /'GEMININ '/ + DATA CTAB (73) /'FCRAO '/ + DATA CTAB (74) /'IRTF '/ + DATA CTAB (75) /'CSO '/ + +* Degrees, arcminutes, arcseconds to radians + WEST(ID,IAM,AS)=AS2R*(DBLE(60*(60*ID+IAM))+DBLE(AS)) + NORTH(ID,IAM,AS)=WEST(ID,IAM,AS) + EAST(ID,IAM,AS)=-WEST(ID,IAM,AS) + SOUTH(ID,IAM,AS)=-WEST(ID,IAM,AS) + + + + +* Station specified by number or identifier? + IF (N.GT.0) THEN + +* Station specified by number + M=N + IF (M.LE.NMAX) C=CTAB(M) + + ELSE + +* Station specified by identifier: determine corresponding number + CC=C + DO NS=1,NMAX + DO I=1,10 + IF (CC(I:I).EQ.' ') GO TO 5 + IF (CC(I:I).NE.CTAB(NS)(I:I)) GO TO 1 + END DO + GO TO 5 + 1 CONTINUE + END DO + NS=NMAX+1 + 5 CONTINUE + IF (C(1:1).NE.' ') THEN + M=NS + ELSE + M=NMAX+1 + END IF + + END IF + +* +* Return parameters of Mth station +* -------------------------------- + + GO TO (10,20,30,40,50,60,70,80,90,100, + : 110,120,130,140,150,160,170,180,190,200, + : 210,220,230,240,250,260,270,280,290,300, + : 310,320,330,340,350,360,370,380,390,400, + : 410,420,430,440,450,460,470,480,490,500, + : 510,520,530,540,550,560,570,580,590,600, + : 610,620,630,640,650,660,670,680,690,700, + : 710,720,730,740,750) M + GO TO 9000 + +* AAT (Observer's Guide) AAT + 10 CONTINUE + NAME='Anglo-Australian 3.9m Telescope' + W=EAST(149,03,57.91) + P=SOUTH(31,16,37.34) + H=1164D0 + GO TO 9999 + +* WHT (Gemini, April 1987) LPO4.2 + 20 CONTINUE + NAME='William Herschel 4.2m Telescope' + W=WEST(17,52,53.9) + P=NORTH(28,45,38.1) + H=2332D0 + GO TO 9999 + +* INT (Gemini, April 1987) LPO2.5 + 30 CONTINUE + NAME='Isaac Newton 2.5m Telescope' + W=WEST(17,52,39.5) + P=NORTH(28,45,43.2) + H=2336D0 + GO TO 9999 + +* JKT (Gemini, April 1987) LPO1 + 40 CONTINUE + NAME='Jacobus Kapteyn 1m Telescope' + W=WEST(17,52,41.2) + P=NORTH(28,45,39.9) + H=2364D0 + GO TO 9999 + +* Lick 120" (1984 Almanac) LICK120 + 50 CONTINUE + NAME='Lick 120 inch' + W=WEST(121,38,09.9) + P=NORTH(37,20,35.2) + H=1290D0 + GO TO 9999 + +* MMT 6.5m conversion (MMT Observatory website) MMT + 60 CONTINUE + NAME='MMT 6.5m, Mt Hopkins' + W=WEST(110,53,04.4) + P=NORTH(31,41,19.6) + H=2608D0 + GO TO 9999 + +* Victoria B.C. 1.85m (1984 Almanac) DAO72 + 70 CONTINUE + NAME='DAO Victoria BC 1.85 metre' + W=WEST(123,25,01.18) + P=NORTH(48,31,11.9) + H=238D0 + GO TO 9999 + +* Las Campanas (1983 Almanac) DUPONT + 80 CONTINUE + NAME='Du Pont 2.5m Telescope, Las Campanas' + W=WEST(70,42,9.) + P=SOUTH(29,00,11.) + H=2280D0 + GO TO 9999 + +* Mt Hopkins 1.5m (1983 Almanac) MTHOP1.5 + 90 CONTINUE + NAME='Mt Hopkins 1.5 metre' + W=WEST(110,52,39.00) + P=NORTH(31,40,51.4) + H=2344D0 + GO TO 9999 + +* Mt Stromlo 74" (1983 Almanac) STROMLO74 + 100 CONTINUE + NAME='Mount Stromlo 74 inch' + W=EAST(149,00,27.59) + P=SOUTH(35,19,14.3) + H=767D0 + GO TO 9999 + +* ANU 2.3m, SSO (Gary Hovey) ANU2.3 + 110 CONTINUE + NAME='Siding Spring 2.3 metre' + W=EAST(149,03,40.3) + P=SOUTH(31,16,24.1) + H=1149D0 + GO TO 9999 + +* Greenbank 140' (1983 Almanac) GBVA140 + 120 CONTINUE + NAME='Greenbank 140 foot' + W=WEST(79,50,09.61) + P=NORTH(38,26,15.4) + H=881D0 + GO TO 9999 + +* Cerro Tololo 4m (1982 Almanac) TOLOLO4M + 130 CONTINUE + NAME='Cerro Tololo 4 metre' + W=WEST(70,48,53.6) + P=SOUTH(30,09,57.8) + H=2235D0 + GO TO 9999 + +* Cerro Tololo 1.5m (1982 Almanac) TOLOLO1.5M + 140 CONTINUE + NAME='Cerro Tololo 1.5 metre' + W=WEST(70,48,54.5) + P=SOUTH(30,09,56.3) + H=2225D0 + GO TO 9999 + +* Tidbinbilla 64m (1982 Almanac) TIDBINBLA + 150 CONTINUE + NAME='Tidbinbilla 64 metre' + W=EAST(148,58,48.20) + P=SOUTH(35,24,14.3) + H=670D0 + GO TO 9999 + +* Bloemfontein 1.52m (1981 Almanac) BLOEMF + 160 CONTINUE + NAME='Bloemfontein 1.52 metre' + W=EAST(26,24,18.) + P=SOUTH(29,02,18.) + H=1387D0 + GO TO 9999 + +* Bosque Alegre 1.54m (1981 Almanac) BOSQALEGRE + 170 CONTINUE + NAME='Bosque Alegre 1.54 metre' + W=WEST(64,32,48.0) + P=SOUTH(31,35,53.) + H=1250D0 + GO TO 9999 + +* USNO 61" astrographic reflector, Flagstaff (1981 Almanac) FLAGSTF61 + 180 CONTINUE + NAME='USNO 61 inch astrograph, Flagstaff' + W=WEST(111,44,23.6) + P=NORTH(35,11,02.5) + H=2316D0 + GO TO 9999 + +* Lowell 72" (1981 Almanac) LOWELL72 + 190 CONTINUE + NAME='Perkins 72 inch, Lowell' + W=WEST(111,32,09.3) + P=NORTH(35,05,48.6) + H=2198D0 + GO TO 9999 + +* Harvard 1.55m (1981 Almanac) HARVARD + 200 CONTINUE + NAME='Harvard College Observatory 1.55m' + W=WEST(71,33,29.32) + P=NORTH(42,30,19.0) + H=185D0 + GO TO 9999 + +* Okayama 1.88m (1981 Almanac) OKAYAMA + 210 CONTINUE + NAME='Okayama 1.88 metre' + W=EAST(133,35,47.29) + P=NORTH(34,34,26.1) + H=372D0 + GO TO 9999 + +* Kitt Peak Mayall 4m (1981 Almanac) KPNO158 + 220 CONTINUE + NAME='Kitt Peak 158 inch' + W=WEST(111,35,57.61) + P=NORTH(31,57,50.3) + H=2120D0 + GO TO 9999 + +* Kitt Peak 90 inch (1981 Almanac) KPNO90 + 230 CONTINUE + NAME='Kitt Peak 90 inch' + W=WEST(111,35,58.24) + P=NORTH(31,57,46.9) + H=2071D0 + GO TO 9999 + +* Kitt Peak 84 inch (1981 Almanac) KPNO84 + 240 CONTINUE + NAME='Kitt Peak 84 inch' + W=WEST(111,35,51.56) + P=NORTH(31,57,29.2) + H=2096D0 + GO TO 9999 + +* Kitt Peak 36 foot (1981 Almanac) KPNO36FT + 250 CONTINUE + NAME='Kitt Peak 36 foot' + W=WEST(111,36,51.12) + P=NORTH(31,57,12.1) + H=1939D0 + GO TO 9999 + +* Kottamia 74" (1981 Almanac) KOTTAMIA + 260 CONTINUE + NAME='Kottamia 74 inch' + W=EAST(31,49,30.) + P=NORTH(29,55,54.) + H=476D0 + GO TO 9999 + +* La Silla 3.6m (1981 Almanac) ESO3.6 + 270 CONTINUE + NAME='ESO 3.6 metre' + W=WEST(70,43,36.) + P=SOUTH(29,15,36.) + H=2428D0 + GO TO 9999 + +* Mauna Kea 88 inch MAUNAK88 +* (IfA website, Richard Wainscoat) + 280 CONTINUE + NAME='Mauna Kea 88 inch' + W=WEST(155,28,09.96) + P=NORTH(19,49,22.77) + H=4213.6D0 + GO TO 9999 + +* UKIRT (IfA website, Richard Wainscoat) UKIRT + 290 CONTINUE + NAME='UK Infra Red Telescope' + W=WEST(155,28,13.18) + P=NORTH(19,49,20.75) + H=4198.5D0 + GO TO 9999 + +* Quebec 1.6m (1981 Almanac) QUEBEC1.6 + 300 CONTINUE + NAME='Quebec 1.6 metre' + W=WEST(71,09,09.7) + P=NORTH(45,27,20.6) + H=1114D0 + GO TO 9999 + +* Mt Ekar 1.82m (1981 Almanac) MTEKAR + 310 CONTINUE + NAME='Mt Ekar 1.82 metre' + W=EAST(11,34,15.) + P=NORTH(45,50,48.) + H=1365D0 + GO TO 9999 + +* Mt Lemmon 60" (1981 Almanac) MTLEMMON60 + 320 CONTINUE + NAME='Mt Lemmon 60 inch' + W=WEST(110,42,16.9) + P=NORTH(32,26,33.9) + H=2790D0 + GO TO 9999 + +* Mt Locke 2.7m (1981 Almanac) MCDONLD2.7 + 330 CONTINUE + NAME='McDonald 2.7 metre' + W=WEST(104,01,17.60) + P=NORTH(30,40,17.7) + H=2075D0 + GO TO 9999 + +* Mt Locke 2.1m (1981 Almanac) MCDONLD2.1 + 340 CONTINUE + NAME='McDonald 2.1 metre' + W=WEST(104,01,20.10) + P=NORTH(30,40,17.7) + H=2075D0 + GO TO 9999 + +* Palomar 200" (1981 Almanac) PALOMAR200 + 350 CONTINUE + NAME='Palomar 200 inch' + W=WEST(116,51,50.) + P=NORTH(33,21,22.) + H=1706D0 + GO TO 9999 + +* Palomar 60" (1981 Almanac) PALOMAR60 + 360 CONTINUE + NAME='Palomar 60 inch' + W=WEST(116,51,31.) + P=NORTH(33,20,56.) + H=1706D0 + GO TO 9999 + +* David Dunlap 74" (1981 Almanac) DUNLAP74 + 370 CONTINUE + NAME='David Dunlap 74 inch' + W=WEST(79,25,20.) + P=NORTH(43,51,46.) + H=244D0 + GO TO 9999 + +* Haute Provence 1.93m (1981 Almanac) HPROV1.93 + 380 CONTINUE + NAME='Haute Provence 1.93 metre' + W=EAST(5,42,46.75) + P=NORTH(43,55,53.3) + H=665D0 + GO TO 9999 + +* Haute Provence 1.52m (1981 Almanac) HPROV1.52 + 390 CONTINUE + NAME='Haute Provence 1.52 metre' + W=EAST(5,42,43.82) + P=NORTH(43,56,00.2) + H=667D0 + GO TO 9999 + +* San Pedro Martir 83" (1981 Almanac) SANPM83 + 400 CONTINUE + NAME='San Pedro Martir 83 inch' + W=WEST(115,27,47.) + P=NORTH(31,02,38.) + H=2830D0 + GO TO 9999 + +* Sutherland 74" (1981 Almanac) SAAO74 + 410 CONTINUE + NAME='Sutherland 74 inch' + W=EAST(20,48,44.3) + P=SOUTH(32,22,43.4) + H=1771D0 + GO TO 9999 + +* Tautenburg 2m (1981 Almanac) TAUTNBG + 420 CONTINUE + NAME='Tautenburg 2 metre' + W=EAST(11,42,45.) + P=NORTH(50,58,51.) + H=331D0 + GO TO 9999 + +* Catalina 61" (1981 Almanac) CATALINA61 + 430 CONTINUE + NAME='Catalina 61 inch' + W=WEST(110,43,55.1) + P=NORTH(32,25,00.7) + H=2510D0 + GO TO 9999 + +* Steward 90" (1981 Almanac) STEWARD90 + 440 CONTINUE + NAME='Steward 90 inch' + W=WEST(111,35,58.24) + P=NORTH(31,57,46.9) + H=2071D0 + GO TO 9999 + +* Russian 6m (1981 Almanac) USSR6 + 450 CONTINUE + NAME='USSR 6 metre' + W=EAST(41,26,30.0) + P=NORTH(43,39,12.) + H=2100D0 + GO TO 9999 + +* Arecibo 1000' (1981 Almanac) ARECIBO + 460 CONTINUE + NAME='Arecibo 1000 foot' + W=WEST(66,45,11.1) + P=NORTH(18,20,36.6) + H=496D0 + GO TO 9999 + +* Cambridge 5km (1981 Almanac) CAMB5KM + 470 CONTINUE + NAME='Cambridge 5km' + W=EAST(0,02,37.23) + P=NORTH(52,10,12.2) + H=17D0 + GO TO 9999 + +* Cambridge 1 mile (1981 Almanac) CAMB1MILE + 480 CONTINUE + NAME='Cambridge 1 mile' + W=EAST(0,02,21.64) + P=NORTH(52,09,47.3) + H=17D0 + GO TO 9999 + +* Bonn 100m (1981 Almanac) EFFELSBERG + 490 CONTINUE + NAME='Effelsberg 100 metre' + W=EAST(6,53,01.5) + P=NORTH(50,31,28.6) + H=366D0 + GO TO 9999 + +* Greenbank 300' (1981 Almanac) GBVA300 (R.I.P.) + 500 CONTINUE + NAME='Greenbank 300 foot' + W=WEST(79,50,56.36) + P=NORTH(38,25,46.3) + H=894D0 + GO TO 9999 + +* Jodrell Bank Mk 1 (1981 Almanac) JODRELL1 + 510 CONTINUE + NAME='Jodrell Bank 250 foot' + W=WEST(2,18,25.) + P=NORTH(53,14,10.5) + H=78D0 + GO TO 9999 + +* Australia Telescope Parkes Observatory PARKES +* (Peter te Lintel Hekkert, private comm) + 520 CONTINUE + NAME='Parkes 64 metre' + W=EAST(148,15,44.3591) + P=SOUTH(32,59,59.8657) + H=391.79D0 + GO TO 9999 + +* VLA (1981 Almanac) VLA + 530 CONTINUE + NAME='Very Large Array' + W=WEST(107,37,03.82) + P=NORTH(34,04,43.5) + H=2124D0 + GO TO 9999 + +* Sugar Grove 150' (1981 Almanac) SUGARGROVE + 540 CONTINUE + NAME='Sugar Grove 150 foot' + W=WEST(79,16,23.) + P=NORTH(38,31,14.) + H=705D0 + GO TO 9999 + +* Russian 600' (1981 Almanac) USSR600 + 550 CONTINUE + NAME='USSR 600 foot' + W=EAST(41,35,25.5) + P=NORTH(43,49,32.) + H=973D0 + GO TO 9999 + +* Nobeyama 45 metre mm dish (based on 1981 Almanac entry) NOBEYAMA + 560 CONTINUE + NAME='Nobeyama 45 metre' + W=EAST(138,29,12.) + P=NORTH(35,56,19.) + H=1350D0 + GO TO 9999 + +* James Clerk Maxwell 15 metre mm telescope, Mauna Kea JCMT +* (IfA website, Richard Wainscoat, height from I.Coulson) + 570 CONTINUE + NAME='JCMT 15 metre' + W=WEST(155,28,37.20) + P=NORTH(19,49,22.11) + H=4111D0 + GO TO 9999 + +* ESO 3.5 metre NTT, La Silla (K.Wirenstrand) ESONTT + 580 CONTINUE + NAME='ESO 3.5 metre NTT' + W=WEST(70,43,07.) + P=SOUTH(29,15,30.) + H=2377D0 + GO TO 9999 + +* St Andrews University Observatory (1982 Almanac) ST.ANDREWS + 590 CONTINUE + NAME='St Andrews' + W=WEST(2,48,52.5) + P=NORTH(56,20,12.) + H=30D0 + GO TO 9999 + +* Apache Point 3.5 metre (R.Owen) APO3.5 + 600 CONTINUE + NAME='Apache Point 3.5m' + W=WEST(105,49,11.56) + P=NORTH(32,46,48.96) + H=2809D0 + GO TO 9999 + +* W.M.Keck Observatory, Telescope 1 KECK1 +* (William Lupton, private comm) + 610 CONTINUE + NAME='Keck 10m Telescope #1' + W=WEST(155,28,28.99) + P=NORTH(19,49,33.41) + H=4160D0 + GO TO 9999 + +* Tautenberg Schmidt (1983 Almanac) TAUTSCHM + 620 CONTINUE + NAME='Tautenberg 1.34 metre Schmidt' + W=EAST(11,42,45.0) + P=NORTH(50,58,51.0) + H=331D0 + GO TO 9999 + +* Palomar Schmidt (1981 Almanac) PALOMAR48 + 630 CONTINUE + NAME='Palomar 48-inch Schmidt' + W=WEST(116,51,32.0) + P=NORTH(33,21,26.0) + H=1706D0 + GO TO 9999 + +* UK Schmidt, Siding Spring (1983 Almanac) UKST + 640 CONTINUE + NAME='UK 1.2 metre Schmidt, Siding Spring' + W=EAST(149,04,12.8) + P=SOUTH(31,16,27.8) + H=1145D0 + GO TO 9999 + +* Kiso Schmidt, Japan (1981 Almanac) KISO + 650 CONTINUE + NAME='Kiso 1.05 metre Schmidt, Japan' + W=EAST(137,37,42.2) + P=NORTH(35,47,38.7) + H=1130D0 + GO TO 9999 + +* ESO Schmidt, La Silla (1981 Almanac) ESOSCHM + 660 CONTINUE + NAME='ESO 1 metre Schmidt, La Silla' + W=WEST(70,43,46.5) + P=SOUTH(29,15,25.8) + H=2347D0 + GO TO 9999 + +* Australia Telescope Compact Array ATCA +* (WGS84 coordinates of Station 35, Mark Calabretta, private comm) + 670 CONTINUE + NAME='Australia Telescope Compact Array' + W=EAST(149,33,00.500) + P=SOUTH(30,18,46.385) + H=236.9D0 + GO TO 9999 + +* Australia Telescope Mopra Observatory MOPRA +* (Peter te Lintel Hekkert, private comm) + 680 CONTINUE + NAME='ATNF Mopra Observatory' + W=EAST(149,05,58.732) + P=SOUTH(31,16,04.451) + H=850D0 + GO TO 9999 + +* Subaru telescope, Mauna Kea SUBARU +* (IfA website, Richard Wainscoat) + 690 CONTINUE + NAME='Subaru 8m telescope' + W=WEST(155,28,33.67) + P=NORTH(19,49,31.81) + H=4163D0 + GO TO 9999 + +* Canada-France-Hawaii Telescope, Mauna Kea CFHT +* (IfA website, Richard Wainscoat) + 700 CONTINUE + NAME='Canada-France-Hawaii 3.6m Telescope' + W=WEST(155,28,07.95) + P=NORTH(19,49,30.91) + H=4204.1D0 + GO TO 9999 + +* W.M.Keck Observatory, Telescope 2 KECK2 +* (William Lupton, private comm) + 710 CONTINUE + NAME='Keck 10m Telescope #2' + W=WEST(155,28,27.24) + P=NORTH(19,49,35.62) + H=4159.6D0 + GO TO 9999 + +* Gemini North, Mauna Kea GEMININ +* (IfA website, Richard Wainscoat) + 720 CONTINUE + NAME='Gemini North 8-m telescope' + W=WEST(155,28,08.57) + P=NORTH(19,49,25.69) + H=4213.4D0 + GO TO 9999 + +* Five College Radio Astronomy Observatory FCRAO +* (Tim Jenness, private comm) + 730 CONTINUE + NAME='Five College Radio Astronomy Obs' + W=WEST(72,20,42.0) + P=NORTH(42,23,30.0) + H=314D0 + GO TO 9999 + +* NASA Infra Red Telescope Facility IRTF +* (IfA website, Richard Wainscoat) + 740 CONTINUE + NAME='NASA IR Telescope Facility, Mauna Kea' + W=WEST(155,28,19.20) + P=NORTH(19,49,34.39) + H=4168.1D0 + GO TO 9999 + +* Caltech Submillimeter Observatory CSO +* (IfA website, Richard Wainscoat; height estimated) + 750 CONTINUE + NAME='Caltech Sub-mm Observatory, Mauna Kea' + W=WEST(155,28,31.79) + P=NORTH(19,49,20.78) + H=4080D0 + GO TO 9999 + +* Unrecognized station + 9000 CONTINUE + NAME='?' + +* Exit + 9999 CONTINUE + + END diff --git a/src/slalib/pa.f b/src/slalib/pa.f new file mode 100644 index 0000000..8c68296 --- /dev/null +++ b/src/slalib/pa.f @@ -0,0 +1,46 @@ + DOUBLE PRECISION FUNCTION sla_PA (HA, DEC, PHI) +*+ +* - - - +* P A +* - - - +* +* HA, Dec to Parallactic Angle (double precision) +* +* Given: +* HA d hour angle in radians (geocentric apparent) +* DEC d declination in radians (geocentric apparent) +* PHI d observatory latitude in radians (geodetic) +* +* The result is in the range -pi to +pi +* +* Notes: +* +* 1) The parallactic angle at a point in the sky is the position +* angle of the vertical, i.e. the angle between the direction to +* the pole and to the zenith. In precise applications care must +* be taken only to use geocentric apparent HA,Dec and to consider +* separately the effects of atmospheric refraction and telescope +* mount errors. +* +* 2) At the pole a zero result is returned. +* +* P.T.Wallace Starlink 16 August 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION HA,DEC,PHI + + DOUBLE PRECISION CP,SQSZ,CQSZ + + + + CP=COS(PHI) + SQSZ=CP*SIN(HA) + CQSZ=SIN(PHI)*COS(DEC)-CP*SIN(DEC)*COS(HA) + IF (SQSZ.EQ.0D0.AND.CQSZ.EQ.0D0) CQSZ=1D0 + sla_PA=ATAN2(SQSZ,CQSZ) + + END diff --git a/src/slalib/pav.f b/src/slalib/pav.f new file mode 100644 index 0000000..7eb1c12 --- /dev/null +++ b/src/slalib/pav.f @@ -0,0 +1,53 @@ + REAL FUNCTION sla_PAV ( V1, V2 ) +*+ +* - - - - +* P A V +* - - - - +* +* Position angle of one celestial direction with respect to another. +* +* (single precision) +* +* Given: +* V1 r(3) direction cosines of one point +* V2 r(3) direction cosines of the other point +* +* (The coordinate frames correspond to RA,Dec, Long,Lat etc.) +* +* The result is the bearing (position angle), in radians, of point +* V2 with respect to point V1. It is in the range +/- pi. The +* sense is such that if V2 is a small distance east of V1, the +* bearing is about +pi/2. Zero is returned if the two points +* are coincident. +* +* V1 and V2 do not have to be unit vectors. +* +* The routine sla_BEAR performs an equivalent function except +* that the points are specified in the form of spherical +* coordinates. +* +* Called: sla_DPAV +* +* Patrick Wallace Starlink 23 May 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL V1(3),V2(3) + + INTEGER I + DOUBLE PRECISION D1(3),D2(3) + + DOUBLE PRECISION sla_DPAV + + +* Call the double precision version + DO I=1,3 + D1(I)=V1(I) + D2(I)=V2(I) + END DO + sla_PAV=sla_DPAV(D1,D2) + + END diff --git a/src/slalib/pc.bat b/src/slalib/pc.bat new file mode 100755 index 0000000..d0f43b4 --- /dev/null +++ b/src/slalib/pc.bat @@ -0,0 +1,75 @@ +@echo off +rem +rem - - - - - - - +rem P C . B A T +rem - - - - - - - +rem +rem Create the SLALIB library, starting either from the release +rem version copied from the VAX or from the PC version produced +rem by a prior run of the present procedure. +rem +rem Environment variable temp must point to a scratch directory. +rem +rem !!! Non-reversible - it is not possible to recreate !!! +rem !!! the VAX version from the PC version !!! +rem +rem P.T.Wallace Starlink 25 April 1996 +rem +if exist *.pcm copy *.pcm *.for +if exist *.pcm del *.pcm +if exist *.c del *.c +if exist *.obj del *.obj +if exist *.exe del *.exe +if exist *.olb del *.olb +if exist *.vax del *.vax +if exist *.ush del *.ush +if exist *.cnv del *.cnv +if exist *.mip del *.mip +if exist *.sun del *.sun +if exist *.ind del *.ind +if exist *.com del *.com +if exist *.new del *.new +if exist *.obs del *.obs +if exist *.toc del *.toc +if exist *.dir del *.dir +if exist sla_test.for del sla_test.for +if exist makefile del makefile +if exist mk del mk +if exist sla_link del sla_link +if exist a*.for fl/c /FPi a*.for +if exist b*.for fl/c /FPi b*.for +if exist c*.for fl/c /FPi c*.for +if exist d*.for fl/c /FPi d*.for +if exist e*.for fl/c /FPi e*.for +if exist f*.for fl/c /FPi f*.for +if exist g*.for fl/c /FPi g*.for +if exist h*.for fl/c /FPi h*.for +if exist i*.for fl/c /FPi i*.for +if exist j*.for fl/c /FPi j*.for +if exist k*.for fl/c /FPi k*.for +if exist l*.for fl/c /FPi l*.for +if exist m*.for fl/c /FPi m*.for +if exist n*.for fl/c /FPi n*.for +if exist o*.for fl/c /FPi o*.for +if exist p*.for fl/c /FPi p*.for +if exist q*.for fl/c /FPi q*.for +if exist r*.for fl/c /FPi r*.for +if exist s*.for fl/c /FPi s*.for +if exist t*.for fl/c /FPi t*.for +if exist u*.for fl/c /FPi u*.for +if exist v*.for fl/c /FPi v*.for +if exist w*.for fl/c /FPi w*.for +if exist x*.for fl/c /FPi x*.for +if exist y*.for fl/c /FPi y*.for +if exist z*.for fl/c /FPi z*.for +echo Building library SLALIB.LIB ... +@echo slalib > %temp%\slalib.tmp +@echo y >> %temp%\slalib.tmp +for %%f in (*.obj) do echo +%%f& >> %temp%\slalib.tmp +@echo ;. >> %temp%\slalib.tmp +if exist slalib.lib del slalib.lib +lib @%temp%\slalib.tmp +del %temp%\slalib.tmp +del *.obj +echo ... done. +echo: diff --git a/src/slalib/pcd.f b/src/slalib/pcd.f new file mode 100644 index 0000000..71241a7 --- /dev/null +++ b/src/slalib/pcd.f @@ -0,0 +1,59 @@ + SUBROUTINE sla_PCD (DISCO,X,Y) +*+ +* - - - - +* P C D +* - - - - +* +* Apply pincushion/barrel distortion to a tangent-plane [x,y]. +* +* Given: +* DISCO d pincushion/barrel distortion coefficient +* X,Y d tangent-plane coordinates +* +* Returned: +* X,Y d distorted coordinates +* +* Notes: +* +* 1) The distortion is of the form RP = R*(1 + C*R**2), where R is +* the radial distance from the tangent point, C is the DISCO +* argument, and RP is the radial distance in the presence of +* the distortion. +* +* 2) For pincushion distortion, C is +ve; for barrel distortion, +* C is -ve. +* +* 3) For X,Y in units of one projection radius (in the case of +* a photographic plate, the focal length), the following +* DISCO values apply: +* +* Geometry DISCO +* +* astrograph 0.0 +* Schmidt -0.3333 +* AAT PF doublet +147.069 +* AAT PF triplet +178.585 +* AAT f/8 +21.20 +* JKT f/8 +13.32 +* +* 4) There is a companion routine, sla_UNPCD, which performs +* an approximately inverse operation. +* +* P.T.Wallace Starlink 31 December 1992 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DISCO,X,Y + + DOUBLE PRECISION F + + + + F=1D0+DISCO*(X*X+Y*Y) + X=X*F + Y=Y*F + + END diff --git a/src/slalib/pda2h.f b/src/slalib/pda2h.f new file mode 100644 index 0000000..cd31acf --- /dev/null +++ b/src/slalib/pda2h.f @@ -0,0 +1,100 @@ + SUBROUTINE sla_PDA2H (P, D, A, H1, J1, H2, J2) +*+ +* - - - - - - +* P D A 2 H +* - - - - - - +* +* Hour Angle corresponding to a given azimuth +* +* (double precision) +* +* Given: +* P d latitude +* D d declination +* A d azimuth +* +* Returned: +* H1 d hour angle: first solution if any +* J1 i flag: 0 = solution 1 is valid +* H2 d hour angle: second solution if any +* J2 i flag: 0 = solution 2 is valid +* +* Called: sla_DRANGE +* +* P.T.Wallace Starlink 6 October 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION P,D,A,H1 + INTEGER J1 + DOUBLE PRECISION H2 + INTEGER J2 + + DOUBLE PRECISION DPI + PARAMETER (DPI=3.141592653589793238462643D0) + DOUBLE PRECISION D90 + PARAMETER (D90=DPI/2D0) + DOUBLE PRECISION TINY + PARAMETER (TINY=1D-12) + DOUBLE PRECISION PN,AN,DN,SA,CA,SASP,QT,QB,HPT,T + DOUBLE PRECISION sla_DRANGE + + +* Preset status flags to OK + J1=0 + J2=0 + +* Adjust latitude, azimuth, declination to avoid critical values + PN=sla_DRANGE(P) + IF (ABS(ABS(PN)-D90).LT.TINY) THEN + PN=PN-SIGN(TINY,PN) + ELSE IF (ABS(PN).LT.TINY) THEN + PN=TINY + END IF + AN=sla_DRANGE(A) + IF (ABS(ABS(AN)-DPI).LT.TINY) THEN + AN=AN-SIGN(TINY,AN) + ELSE IF (ABS(AN).LT.TINY) THEN + AN=TINY + END IF + DN=sla_DRANGE(D) + IF (ABS(ABS(DN)-ABS(P)).LT.TINY) THEN + DN=DN-SIGN(TINY,DN) + ELSE IF (ABS(ABS(DN)-D90).LT.TINY) THEN + DN=DN-SIGN(TINY,DN) + ELSE IF (ABS(DN).LT.TINY) THEN + DN=TINY + END IF + +* Useful functions + SA=SIN(AN) + CA=COS(AN) + SASP=SA*SIN(PN) + +* Quotient giving sin(h+t) + QT=SIN(DN)*SA*COS(PN) + QB=COS(DN)*SQRT(CA*CA+SASP*SASP) + +* Any solutions? + IF (ABS(QT).LE.QB) THEN + +* Yes: find h+t and t + HPT=ASIN(QT/QB) + T=ATAN2(SASP,-CA) + +* The two solutions + H1=sla_DRANGE(HPT-T) + H2=sla_DRANGE(-HPT-(T+DPI)) + +* Reject unless h and A different signs + IF (H1*AN.GT.0D0) J1=-1 + IF (H2*AN.GT.0D0) J2=-1 + ELSE + J1=-1 + J2=-1 + END IF + + END diff --git a/src/slalib/pdq2h.f b/src/slalib/pdq2h.f new file mode 100644 index 0000000..a12ba72 --- /dev/null +++ b/src/slalib/pdq2h.f @@ -0,0 +1,98 @@ + SUBROUTINE sla_PDQ2H (P, D, Q, H1, J1, H2, J2) +*+ +* - - - - - - +* P D Q 2 H +* - - - - - - +* +* Hour Angle corresponding to a given parallactic angle +* +* (double precision) +* +* Given: +* P d latitude +* D d declination +* Q d parallactic angle +* +* Returned: +* H1 d hour angle: first solution if any +* J1 i flag: 0 = solution 1 is valid +* H2 d hour angle: second solution if any +* J2 i flag: 0 = solution 2 is valid +* +* Called: sla_DRANGE +* +* P.T.Wallace Starlink 6 October 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION P,D,Q,H1 + INTEGER J1 + DOUBLE PRECISION H2 + INTEGER J2 + + DOUBLE PRECISION DPI + PARAMETER (DPI=3.141592653589793238462643D0) + DOUBLE PRECISION D90 + PARAMETER (D90=DPI/2D0) + DOUBLE PRECISION TINY + PARAMETER (TINY=1D-12) + DOUBLE PRECISION PN,QN,DN,SQ,CQ,SQSD,QT,QB,HPT,T + DOUBLE PRECISION sla_DRANGE + + +* Preset status flags to OK + J1=0 + J2=0 + +* Adjust latitude, declination, parallactic angle to avoid critical values + PN=sla_DRANGE(P) + IF (ABS(ABS(PN)-D90).LT.TINY) THEN + PN=PN-SIGN(TINY,PN) + ELSE IF (ABS(PN).LT.TINY) THEN + PN=TINY + END IF + QN=sla_DRANGE(Q) + IF (ABS(ABS(QN)-DPI).LT.TINY) THEN + QN=QN-SIGN(TINY,QN) + ELSE IF (ABS(QN).LT.TINY) THEN + QN=TINY + END IF + DN=sla_DRANGE(D) + IF (ABS(ABS(D)-ABS(P)).LT.TINY) THEN + DN=DN-SIGN(TINY,DN) + ELSE IF (ABS(ABS(D)-D90).LT.TINY) THEN + DN=DN-SIGN(TINY,DN) + END IF + +* Useful functions + SQ=SIN(QN) + CQ=COS(QN) + SQSD=SQ*SIN(DN) + +* Quotient giving sin(h+t) + QT=SIN(PN)*SQ*COS(DN) + QB=COS(PN)*SQRT(CQ*CQ+SQSD*SQSD) + +* Any solutions? + IF (ABS(QT).LE.QB) THEN + +* Yes: find h+t and t + HPT=ASIN(QT/QB) + T=ATAN2(SQSD,CQ) + +* The two solutions + H1=sla_DRANGE(HPT-T) + H2=sla_DRANGE(-HPT-(T+DPI)) + +* Reject if h and Q different signs + IF (H1*QN.LT.0D0) J1=-1 + IF (H2*QN.LT.0D0) J2=-1 + ELSE + J1=-1 + J2=-1 + END IF + + END diff --git a/src/slalib/permut.f b/src/slalib/permut.f new file mode 100644 index 0000000..20b8a27 --- /dev/null +++ b/src/slalib/permut.f @@ -0,0 +1,141 @@ + SUBROUTINE sla_PERMUT ( N, ISTATE, IORDER, J ) +*+ +* - - - - - - - +* P E R M U T +* - - - - - - - +* +* Generate the next permutation of a specified number of items. +* +* Given: +* N i number of items: there will be N! permutations +* ISTATE i(N) state, ISTATE(1)=-1 to initialize +* +* Returned: +* ISTATE i(N) state, updated ready for next time +* IORDER i(N) next permutation of numbers 1,2,...,N +* J i status: -1 = illegal N (zero or less is illegal) +* 0 = OK +* +1 = no more permutations available +* +* Notes: +* +* 1) This routine returns, in the IORDER array, the integers 1 to N +* inclusive, in an order that depends on the current contents of +* the ISTATE array. Before calling the routine for the first +* time, the caller must set the first element of the ISTATE array +* to -1 (any negative number will do) to cause the ISTATE array +* to be fully initialized. +* +* 2) The first permutation to be generated is: +* +* IORDER(1)=N, IORDER(2)=N-1, ..., IORDER(N)=1 +* +* This is also the permutation returned for the "finished" +* (J=1) case. +* +* The final permutation to be generated is: +* +* IORDER(1)=1, IORDER(2)=2, ..., IORDER(N)=N +* +* 3) If the "finished" (J=1) status is ignored, the routine continues +* to deliver permutations, the pattern repeating every N! calls. +* +* P.T.Wallace Starlink 25 August 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER N,IORDER(N),ISTATE(N),J + + INTEGER I,IP1,ISLOT,ISKIP + + +* ------------- +* Preliminaries +* ------------- + +* Validate, and set status. + IF (N.LT.1) THEN + J = -1 + GO TO 9999 + ELSE + J = 0 + END IF + +* If just starting, initialize state array + IF (ISTATE(1).LT.0) THEN + ISTATE(1) = -1 + DO I=2,N + ISTATE(I) = 0 + END DO + END IF + +* -------------------------- +* Increment the state number +* -------------------------- + +* The state number, maintained in the ISTATE array, is a mixed-radix +* number with N! states. The least significant digit, with a radix of +* 1, is in ISTATE(1). The next digit, in ISTATE(2), has a radix of 2, +* and so on. + +* Increment the least-significant digit of the state number. + ISTATE(1) = ISTATE(1)+1 + +* Digit by digit starting with the least significant. + DO I=1,N + +* Carry? + IF (ISTATE(I).GE.I) THEN + +* Yes: reset the current digit. + ISTATE(I) = 0 + +* Overflow? + IF (I.GE.N) THEN + +* Yes: there are no more permutations. + J = 1 + ELSE + +* No: carry. + IP1 = I+1 + ISTATE(IP1) = ISTATE(IP1)+1 + END IF + END IF + END DO + +* ------------------------------------------------------------------- +* Translate the state number into the corresponding permutation order +* ------------------------------------------------------------------- + +* Initialize the order array. All but one element will be overwritten. + DO I=1,N + IORDER(I) = 1 + END DO + +* Look at each state number digit, starting with the most significant. + DO I=N,2,-1 + +* Initialize the position where the new number will go. + ISLOT = 0 + +* The state number digit says which unfilled slot is to be used. + DO ISKIP=0,ISTATE(I) + +* Increment the slot number until an unused slot is found. + ISLOT = ISLOT+1 + DO WHILE (IORDER(ISLOT).GT.1) + ISLOT = ISLOT+1 + END DO + END DO + +* Store the number in the permutation order array. + IORDER(ISLOT) = I + END DO + + 9999 CONTINUE + + END diff --git a/src/slalib/pertel.f b/src/slalib/pertel.f new file mode 100644 index 0000000..45537b4 --- /dev/null +++ b/src/slalib/pertel.f @@ -0,0 +1,159 @@ + SUBROUTINE sla_PERTEL (JFORM, DATE0, DATE1, + : EPOCH0, ORBI0, ANODE0, PERIH0, AORQ0, E0, AM0, + : EPOCH1, ORBI1, ANODE1, PERIH1, AORQ1, E1, AM1, + : JSTAT) +*+ +* - - - - - - - +* P E R T E L +* - - - - - - - +* +* Update the osculating orbital elements of an asteroid or comet by +* applying planetary perturbations. +* +* Given (format and dates): +* JFORM i choice of element set (2 or 3; Note 1) +* DATE0 d date of osculation (TT MJD) for the given elements +* DATE1 d date of osculation (TT MJD) for the updated elements +* +* Given (the unperturbed elements): +* EPOCH0 d epoch (TT MJD) of the given element set (Note 2) +* ORBI0 d inclination (radians) +* ANODE0 d longitude of the ascending node (radians) +* PERIH0 d argument of perihelion (radians) +* AORQ0 d mean distance or perihelion distance (AU) +* E0 d eccentricity +* AM0 d mean anomaly (radians, JFORM=2 only) +* +* Returned (the updated elements): +* EPOCH1 d epoch (TT MJD) of the updated element set (Note 2) +* ORBI1 d inclination (radians) +* ANODE1 d longitude of the ascending node (radians) +* PERIH1 d argument of perihelion (radians) +* AORQ1 d mean distance or perihelion distance (AU) +* E1 d eccentricity +* AM1 d mean anomaly (radians, JFORM=2 only) +* +* Returned (status flag): +* JSTAT i status: +102 = warning, distant epoch +* +101 = warning, large timespan ( > 100 years) +* +1 to +8 = coincident with major planet (Note 6) +* 0 = OK +* -1 = illegal JFORM +* -2 = illegal E0 +* -3 = illegal AORQ0 +* -4 = internal error +* -5 = numerical error +* +* Notes: +* +* 1 Two different element-format options are available: +* +* Option JFORM=2, suitable for minor planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBI = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e +* AM = mean anomaly M (radians) +* +* Option JFORM=3, suitable for comets: +* +* EPOCH = epoch of perihelion (TT MJD) +* ORBI = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = perihelion distance, q (AU) +* E = eccentricity, e +* +* 2 DATE0, DATE1, EPOCH0 and EPOCH1 are all instants of time in +* the TT timescale (formerly Ephemeris Time, ET), expressed +* as Modified Julian Dates (JD-2400000.5). +* +* DATE0 is the instant at which the given (i.e. unperturbed) +* osculating elements are correct. +* +* DATE1 is the specified instant at which the updated osculating +* elements are correct. +* +* EPOCH0 and EPOCH1 will be the same as DATE0 and DATE1 +* (respectively) for the JFORM=2 case, normally used for minor +* planets. For the JFORM=3 case, the two epochs will refer to +* perihelion passage and so will not, in general, be the same as +* DATE0 and/or DATE1 though they may be similar to one another. +* +* 3 The elements are with respect to the J2000 ecliptic and equinox. +* +* 4 Unused elements (AM0 and AM1 for JFORM=3) are not accessed. +* +* 5 See the sla_PERTUE routine for details of the algorithm used. +* +* 6 This routine is not intended to be used for major planets, which +* is why JFORM=1 is not available and why there is no opportunity +* to specify either the longitude of perihelion or the daily +* motion. However, if JFORM=2 elements are somehow obtained for a +* major planet and supplied to the routine, sensible results will, +* in fact, be produced. This happens because the sla_PERTUE routine +* that is called to perform the calculations checks the separation +* between the body and each of the planets and interprets a +* suspiciously small value (0.001 AU) as an attempt to apply it to +* the planet concerned. If this condition is detected, the +* contribution from that planet is ignored, and the status is set to +* the planet number (Mercury=1,...,Neptune=8) as a warning. +* +* Reference: +* +* Sterne, Theodore E., "An Introduction to Celestial Mechanics", +* Interscience Publishers Inc., 1960. Section 6.7, p199. +* +* Called: sla_EL2UE, sla_PERTUE, sla_UE2EL +* +* P.T.Wallace Starlink 14 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + INTEGER JFORM + DOUBLE PRECISION DATE0,DATE1, + : EPOCH0,ORBI0,ANODE0,PERIH0,AORQ0,E0,AM0, + : EPOCH1,ORBI1,ANODE1,PERIH1,AORQ1,E1,AM1 + INTEGER JSTAT + + DOUBLE PRECISION U(13),DM + INTEGER J,JF + + + +* Check that the elements are either minor-planet or comet format. + IF (JFORM.LT.2.OR.JFORM.GT.3) THEN + JSTAT = -1 + GO TO 9999 + END IF + +* Transform the elements from conventional to universal form. + CALL sla_EL2UE(DATE0,JFORM,EPOCH0,ORBI0,ANODE0,PERIH0, + : AORQ0,E0,AM0,0D0,U,J) + IF (J.NE.0) THEN + JSTAT = J + GO TO 9999 + END IF + +* Update the universal elements. + CALL sla_PERTUE(DATE1,U,J) + IF (J.GT.0) THEN + JSTAT = J + ELSE IF (J.LT.0) THEN + JSTAT = -5 + GO TO 9999 + END IF + +* Transform from universal to conventional elements. + CALL sla_UE2EL(U,2, + : JF, EPOCH1, ORBI1, ANODE1, PERIH1, + : AORQ1, E1, AM1, DM, J) + IF (JF.NE.JFORM.OR.J.NE.0) JSTAT=-5 + + 9999 CONTINUE + END diff --git a/src/slalib/pertue.f b/src/slalib/pertue.f new file mode 100644 index 0000000..d6f6f53 --- /dev/null +++ b/src/slalib/pertue.f @@ -0,0 +1,535 @@ + SUBROUTINE sla_PERTUE (DATE, U, JSTAT) +*+ +* - - - - - - - +* P E R T U E +* - - - - - - - +* +* Update the universal elements of an asteroid or comet by applying +* planetary perturbations. +* +* Given: +* DATE d final epoch (TT MJD) for the updated elements +* +* Given and returned: +* U d(13) universal elements (updated in place) +* +* (1) combined mass (M+m) +* (2) total energy of the orbit (alpha) +* (3) reference (osculating) epoch (t0) +* (4-6) position at reference epoch (r0) +* (7-9) velocity at reference epoch (v0) +* (10) heliocentric distance at reference epoch +* (11) r0.v0 +* (12) date (t) +* (13) universal eccentric anomaly (psi) of date, approx +* +* Returned: +* JSTAT i status: +* +102 = warning, distant epoch +* +101 = warning, large timespan ( > 100 years) +* +1 to +8 = coincident with major planet (Note 5) +* 0 = OK +* -1 = numerical error +* +* Called: sla_PLANET, sla_UE2PV, sla_PV2UE +* +* Notes: +* +* 1 The "universal" elements are those which define the orbit for the +* purposes of the method of universal variables (see reference 2). +* They consist of the combined mass of the two bodies, an epoch, +* and the position and velocity vectors (arbitrary reference frame) +* at that epoch. The parameter set used here includes also various +* quantities that can, in fact, be derived from the other +* information. This approach is taken to avoiding unnecessary +* computation and loss of accuracy. The supplementary quantities +* are (i) alpha, which is proportional to the total energy of the +* orbit, (ii) the heliocentric distance at epoch, (iii) the +* outwards component of the velocity at the given epoch, (iv) an +* estimate of psi, the "universal eccentric anomaly" at a given +* date and (v) that date. +* +* 2 The universal elements are with respect to the J2000 equator and +* equinox. +* +* 3 The epochs DATE, U(3) and U(12) are all Modified Julian Dates +* (JD-2400000.5). +* +* 4 The algorithm is a simplified form of Encke's method. It takes as +* a basis the unperturbed motion of the body, and numerically +* integrates the perturbing accelerations from the major planets. +* The expression used is essentially Sterne's 6.7-2 (reference 1). +* Everhart and Pitkin (reference 2) suggest rectifying the orbit at +* each integration step by propagating the new perturbed position +* and velocity as the new universal variables. In the present +* routine the orbit is rectified less frequently than this, in order +* to gain a slight speed advantage. However, the rectification is +* done directly in terms of position and velocity, as suggested by +* Everhart and Pitkin, bypassing the use of conventional orbital +* elements. +* +* The f(q) part of the full Encke method is not used. The purpose +* of this part is to avoid subtracting two nearly equal quantities +* when calculating the "indirect member", which takes account of the +* small change in the Sun's attraction due to the slightly displaced +* position of the perturbed body. A simpler, direct calculation in +* double precision proves to be faster and not significantly less +* accurate. +* +* Apart from employing a variable timestep, and occasionally +* "rectifying the orbit" to keep the indirect member small, the +* integration is done in a fairly straightforward way. The +* acceleration estimated for the middle of the timestep is assumed +* to apply throughout that timestep; it is also used in the +* extrapolation of the perturbations to the middle of the next +* timestep, to predict the new disturbed position. There is no +* iteration within a timestep. +* +* Measures are taken to reach a compromise between execution time +* and accuracy. The starting-point is the goal of achieving +* arcsecond accuracy for ordinary minor planets over a ten-year +* timespan. This goal dictates how large the timesteps can be, +* which in turn dictates how frequently the unperturbed motion has +* to be recalculated from the osculating elements. +* +* Within predetermined limits, the timestep for the numerical +* integration is varied in length in inverse proportion to the +* magnitude of the net acceleration on the body from the major +* planets. +* +* The numerical integration requires estimates of the major-planet +* motions. Approximate positions for the major planets (Pluto +* alone is omitted) are obtained from the routine sla_PLANET. Two +* levels of interpolation are used, to enhance speed without +* significantly degrading accuracy. At a low frequency, the routine +* sla_PLANET is called to generate updated position+velocity "state +* vectors". The only task remaining to be carried out at the full +* frequency (i.e. at each integration step) is to use the state +* vectors to extrapolate the planetary positions. In place of a +* strictly linear extrapolation, some allowance is made for the +* curvature of the orbit by scaling back the radius vector as the +* linear extrapolation goes off at a tangent. +* +* Various other approximations are made. For example, perturbations +* by Pluto and the minor planets are neglected, relativistic effects +* are not taken into account and the Earth-Moon system is treated as +* a single body. +* +* In the interests of simplicity, the background calculations for +* the major planets are carried out en masse. The mean elements and +* state vectors for all the planets are refreshed at the same time, +* without regard for orbit curvature, mass or proximity. +* +* 5 This routine is not intended to be used for major planets. +* However, if major-planet elements are supplied, sensible results +* will, in fact, be produced. This happens because the routine +* checks the separation between the body and each of the planets and +* interprets a suspiciously small value (0.001 AU) as an attempt to +* apply the routine to the planet concerned. If this condition is +* detected, the contribution from that planet is ignored, and the +* status is set to the planet number (Mercury=1,...,Neptune=8) as a +* warning. +* +* References: +* +* 1 Sterne, Theodore E., "An Introduction to Celestial Mechanics", +* Interscience Publishers Inc., 1960. Section 6.7, p199. +* +* 2 Everhart, E. & Pitkin, E.T., Am.J.Phys. 51, 712, 1983. +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + DOUBLE PRECISION DATE,U(13) + INTEGER JSTAT + +* Coefficient relating timestep to perturbing force + DOUBLE PRECISION TSC + PARAMETER (TSC=1D-4) + +* Minimum and maximum timestep (days) + DOUBLE PRECISION TSMIN,TSMAX + PARAMETER (TSMIN=0.01D0,TSMAX=10D0) + +* Age limit for major-planet state vector (days) + DOUBLE PRECISION AGEPMO + PARAMETER (AGEPMO=5D0) + +* Age limit for major-planet mean elements (days) + DOUBLE PRECISION AGEPEL + PARAMETER (AGEPEL=50D0) + +* Margin for error when deciding whether to renew the planetary data + DOUBLE PRECISION TINY + PARAMETER (TINY=1D-6) + +* Age limit for the body's osculating elements (before rectification) + DOUBLE PRECISION AGEBEL + PARAMETER (AGEBEL=100D0) + +* Gaussian gravitational constant (exact) and square + DOUBLE PRECISION GCON,GCON2 + PARAMETER (GCON=0.01720209895D0,GCON2=GCON*GCON) + +* The final epoch + DOUBLE PRECISION TFINAL + +* The body's current universal elements + DOUBLE PRECISION UL(13) + +* Current reference epoch + DOUBLE PRECISION T0 + +* Timespan from latest orbit rectification to final epoch (days) + DOUBLE PRECISION TSPAN + +* Time left to go before integration is complete + DOUBLE PRECISION TLEFT + +* Time direction flag: +1=forwards, -1=backwards + DOUBLE PRECISION FB + +* First-time flag + LOGICAL FIRST + +* +* The current perturbations +* +* Epoch (days relative to current reference epoch) + DOUBLE PRECISION RTN +* Position (AU) + DOUBLE PRECISION PERP(3) +* Velocity (AU/d) + DOUBLE PRECISION PERV(3) +* Acceleration (AU/d/d) + DOUBLE PRECISION PERA(3) +* + +* Length of current timestep (days), and half that + DOUBLE PRECISION TS,HTS + +* Epoch of middle of timestep + DOUBLE PRECISION T + +* Epoch of planetary mean elements + DOUBLE PRECISION TPEL + +* Planet number (1=Mercury, 2=Venus, 3=EMB...8=Neptune) + INTEGER NP + +* Planetary universal orbital elements + DOUBLE PRECISION UP(13,8) + +* Epoch of planetary state vectors + DOUBLE PRECISION TPMO + +* State vectors for the major planets (AU,AU/s) + DOUBLE PRECISION PVIN(6,8) + +* +* Correction terms for extrapolated major planet vectors +* +* Sun-to-planet distances squared multiplied by 3 + DOUBLE PRECISION R2X3(8) +* Sunward acceleration terms, G/2R^3 + DOUBLE PRECISION GC(8) +* Tangential-to-circular correction factor + DOUBLE PRECISION FC +* Radial correction factor due to Sunwards acceleration + DOUBLE PRECISION FG +* + +* The body's unperturbed and perturbed state vectors (AU,AU/s) + DOUBLE PRECISION PV0(6),PV(6) + +* The body's perturbed and unperturbed heliocentric distances (AU) cubed + DOUBLE PRECISION R03,R3 + +* The perturbating accelerations, indirect and direct + DOUBLE PRECISION FI(3),FD(3) + +* Sun-to-planet vector, and distance cubed + DOUBLE PRECISION RHO(3),RHO3 + +* Body-to-planet vector, and distance cubed + DOUBLE PRECISION DELTA(3),DELTA3 + +* Miscellaneous + INTEGER I,J + DOUBLE PRECISION R2,W,DT,DT2,FT + +* Planetary inverse masses, Mercury through Neptune + DOUBLE PRECISION AMAS(8) + DATA AMAS / 6023600D0,408523.5D0,328900.5D0,3098710D0, + : 1047.355D0,3498.5D0,22869D0,19314D0 / + +*---------------------------------------------------------------------* + + +* Preset the status to OK. + JSTAT = 0 + +* Copy the final epoch. + TFINAL = DATE + +* Copy the elements (which will be periodically updated). + DO I=1,13 + UL(I) = U(I) + END DO + +* Initialize the working reference epoch. + T0=UL(3) + +* Total timespan (days) and hence time left. + TSPAN = TFINAL-T0 + TLEFT = TSPAN + +* Warn if excessive. + IF (ABS(TSPAN).GT.36525D0) JSTAT=101 + +* Time direction: +1 for forwards, -1 for backwards. + FB = SIGN(1D0,TSPAN) + +* Initialize relative epoch for start of current timestep. + RTN = 0D0 + +* Reset the perturbations (position, velocity, acceleration). + DO I=1,3 + PERP(I) = 0D0 + PERV(I) = 0D0 + PERA(I) = 0D0 + END DO + +* Set "first iteration" flag. + FIRST = .TRUE. + +* Step through the time left. + DO WHILE (FB*TLEFT.GT.0D0) + +* Magnitude of current acceleration due to planetary attractions. + IF (FIRST) THEN + TS = TSMIN + ELSE + R2 = 0D0 + DO I=1,3 + W = FD(I) + R2 = R2+W*W + END DO + W = SQRT(R2) + +* Use the acceleration to decide how big a timestep can be tolerated. + IF (W.NE.0D0) THEN + TS = MIN(TSMAX,MAX(TSMIN,TSC/W)) + ELSE + TS = TSMAX + END IF + END IF + TS = TS*FB + +* Override if final epoch is imminent. + TLEFT = TSPAN-RTN + IF (ABS(TS).GT.ABS(TLEFT)) TS=TLEFT + +* Epoch of middle of timestep. + HTS = TS/2D0 + T = T0+RTN+HTS + +* Is it time to recompute the major-planet elements? + IF (FIRST.OR.ABS(T-TPEL)-AGEPEL.GE.TINY) THEN + +* Yes: go forward in time by just under the maximum allowed. + TPEL = T+FB*AGEPEL + +* Compute the state vector for the new epoch. + DO NP=1,8 + CALL sla_PLANET(TPEL,NP,PV,J) + +* Warning if remote epoch, abort if error. + IF (J.EQ.1) THEN + JSTAT = 102 + ELSE IF (J.NE.0) THEN + GO TO 9010 + END IF + +* Transform the vector into universal elements. + CALL sla_PV2UE(PV,TPEL,0D0,UP(1,NP),J) + IF (J.NE.0) GO TO 9010 + END DO + END IF + +* Is it time to recompute the major-planet motions? + IF (FIRST.OR.ABS(T-TPMO)-AGEPMO.GE.TINY) THEN + +* Yes: look ahead. + TPMO = T+FB*AGEPMO + +* Compute the motions of each planet (AU,AU/d). + DO NP=1,8 + +* The planet's position and velocity (AU,AU/s). + CALL sla_UE2PV(TPMO,UP(1,NP),PVIN(1,NP),J) + IF (J.NE.0) GO TO 9010 + +* Scale velocity to AU/d. + DO J=4,6 + PVIN(J,NP) = PVIN(J,NP)*86400D0 + END DO + +* Precompute also the extrapolation correction terms. + R2 = 0D0 + DO I=1,3 + W = PVIN(I,NP) + R2 = R2+W*W + END DO + R2X3(NP) = R2*3D0 + GC(NP) = GCON2/(2D0*R2*SQRT(R2)) + END DO + END IF + +* Reset the first-time flag. + FIRST = .FALSE. + +* Unperturbed motion of the body at middle of timestep (AU,AU/s). + CALL sla_UE2PV(T,UL,PV0,J) + IF (J.NE.0) GO TO 9010 + +* Perturbed position of the body (AU) and heliocentric distance cubed. + R2 = 0D0 + DO I=1,3 + W = PV0(I)+PERP(I)+(PERV(I)+PERA(I)*HTS/2D0)*HTS + PV(I) = W + R2 = R2+W*W + END DO + R3 = R2*SQRT(R2) + +* The body's unperturbed heliocentric distance cubed. + R2 = 0D0 + DO I=1,3 + W = PV0(I) + R2 = R2+W*W + END DO + R03 = R2*SQRT(R2) + +* Compute indirect and initialize direct parts of the perturbation. + DO I=1,3 + FI(I) = PV0(I)/R03-PV(I)/R3 + FD(I) = 0D0 + END DO + +* Ready to compute the direct planetary effects. + +* Interval from state-vector epoch to middle of current timestep. + DT = T-TPMO + DT2 = DT*DT + +* Planet by planet. + DO NP=1,8 + +* First compute the extrapolation in longitude (squared). + R2 = 0D0 + DO J=4,6 + W = PVIN(J,NP)*DT + R2 = R2+W*W + END DO + +* Hence the tangential-to-circular correction factor. + FC = 1D0+R2/R2X3(NP) + +* The radial correction factor due to the inwards acceleration. + FG = 1D0-GC(NP)*DT2 + +* Planet's position, and heliocentric distance cubed. + R2 = 0D0 + DO I=1,3 + W = FG*(PVIN(I,NP)+FC*PVIN(I+3,NP)*DT) + RHO(I) = W + R2 = R2+W*W + END DO + RHO3 = R2*SQRT(R2) + +* Body-to-planet vector, light-time, and distance cubed. + R2 = 0D0 + DO I=1,3 + W = RHO(I)-PV(I) + DELTA(I) = W + R2 = R2+W*W + END DO + W = SQRT(R2) + DELTA3 = R2*SQRT(R2) + +* If too close, ignore this planet and set a warning. + IF (R2.LT.1D-6) THEN + JSTAT = NP + ELSE + +* Accumulate "direct" part of perturbation acceleration. + W = AMAS(NP) + DO I=1,3 + FD(I) = FD(I)+(DELTA(I)/DELTA3-RHO(I)/RHO3)/W + END DO + END IF + END DO + +* Update the perturbations to the end of the timestep. + RTN = RTN+TS + DO I=1,3 + W = (FI(I)+FD(I))*GCON2 + FT = W*TS + PERP(I) = PERP(I)+(PERV(I)+FT/2D0)*TS + PERV(I) = PERV(I)+FT + PERA(I) = W + END DO + +* Time still to go. + TLEFT = TSPAN-RTN + +* Is it either time to rectify the orbit or the last time through? + IF (ABS(RTN).GE.AGEBEL.OR.FB*TLEFT.LE.0D0) THEN + +* Yes: update to the end of the current timestep. + T0 = T0+RTN + RTN = 0D0 + +* The body's unperturbed motion (AU,AU/s). + CALL sla_UE2PV(T0,UL,PV0,J) + IF (J.NE.0) GO TO 9010 + +* Add and re-initialize the perturbations. + DO I=1,3 + J = I+3 + PV(I) = PV0(I)+PERP(I) + PV(J) = PV0(J)+PERV(I)/86400D0 + PERP(I) = 0D0 + PERV(I) = 0D0 + PERA(I) = FD(I)*GCON2 + END DO + +* Use the position and velocity to set up new universal elements. + CALL sla_PV2UE(PV,T0,0D0,UL,J) + IF (J.NE.0) GO TO 9010 + +* Adjust the timespan and time left. + TSPAN = TFINAL-T0 + TLEFT = TSPAN + END IF + +* Next timestep. + END DO + +* Return the updated universal-element set. + DO I=1,13 + U(I) = UL(I) + END DO + +* Finished. + GO TO 9999 + +* Miscellaneous numerical error. + 9010 CONTINUE + JSTAT = -1 + + 9999 CONTINUE + END diff --git a/src/slalib/planel.f b/src/slalib/planel.f new file mode 100644 index 0000000..064e51c --- /dev/null +++ b/src/slalib/planel.f @@ -0,0 +1,117 @@ + SUBROUTINE sla_PLANEL (DATE, JFORM, EPOCH, ORBINC, ANODE, PERIH, + : AORQ, E, AORL, DM, PV, JSTAT) +*+ +* - - - - - - - +* P L A N E L +* - - - - - - - +* +* Heliocentric position and velocity of a planet, asteroid or comet, +* starting from orbital elements. +* +* Given: +* DATE d date, Modified Julian Date (JD - 2400000.5) +* JFORM i choice of element set (1-3; Note 3) +* EPOCH d epoch of elements (TT MJD) +* ORBINC d inclination (radians) +* ANODE d longitude of the ascending node (radians) +* PERIH d longitude or argument of perihelion (radians) +* AORQ d mean distance or perihelion distance (AU) +* E d eccentricity +* AORL d mean anomaly or longitude (radians, JFORM=1,2 only) +* DM d daily motion (radians, JFORM=1 only) +* +* Returned: +* PV d(6) heliocentric x,y,z,xdot,ydot,zdot of date, +* J2000 equatorial triad (AU,AU/s) +* JSTAT i status: 0 = OK +* -1 = illegal JFORM +* -2 = illegal E +* -3 = illegal AORQ +* -4 = illegal DM +* -5 = numerical error +* +* Called: sla_EL2UE, sla_UE2PV +* +* Notes +* +* 1 DATE is the instant for which the prediction is required. It is +* in the TT timescale (formerly Ephemeris Time, ET) and is a +* Modified Julian Date (JD-2400000.5). +* +* 2 The elements are with respect to the J2000 ecliptic and equinox. +* +* 3 Three different element-format options are available: +* +* Option JFORM=1, suitable for the major planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = longitude of perihelion, curly pi (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e (range 0 to <1) +* AORL = mean longitude L (radians) +* DM = daily motion (radians) +* +* Option JFORM=2, suitable for minor planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e (range 0 to <1) +* AORL = mean anomaly M (radians) +* +* Option JFORM=3, suitable for comets: +* +* EPOCH = epoch of perihelion (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = perihelion distance, q (AU) +* E = eccentricity, e (range 0 to 10) +* +* 4 Unused elements (DM for JFORM=2, AORL and DM for JFORM=3) are +* not accessed. +* +* 5 The reference frame for the result is with respect to the mean +* equator and equinox of epoch J2000. +* +* 6 The algorithm was originally adapted from the EPHSLA program of +* D.H.P.Jones (private communication, 1996). The method is based +* on Stumpff's Universal Variables. +* +* Reference: Everhart, E. & Pitkin, E.T., Am.J.Phys. 51, 712, 1983. +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE + INTEGER JFORM + DOUBLE PRECISION EPOCH,ORBINC,ANODE,PERIH,AORQ,E,AORL,DM,PV(6) + INTEGER JSTAT + + DOUBLE PRECISION U(13) + INTEGER J + + + +* Validate elements and convert to "universal variables" parameters. + CALL sla_EL2UE(DATE,JFORM, + : EPOCH,ORBINC,ANODE,PERIH,AORQ,E,AORL,DM,U,J) + +* Determine the position and velocity. + IF (J.EQ.0) THEN + CALL sla_UE2PV(DATE,U,PV,J) + IF (J.NE.0) J=-5 + END IF + +* Wrap up. + JSTAT = J + + END diff --git a/src/slalib/planet.f b/src/slalib/planet.f new file mode 100644 index 0000000..095dff7 --- /dev/null +++ b/src/slalib/planet.f @@ -0,0 +1,707 @@ + SUBROUTINE sla_PLANET (DATE, NP, PV, JSTAT) +*+ +* - - - - - - - +* P L A N E T +* - - - - - - - +* +* Approximate heliocentric position and velocity of a specified +* major planet. +* +* Given: +* DATE d Modified Julian Date (JD - 2400000.5) +* NP i planet (1=Mercury, 2=Venus, 3=EMB ... 9=Pluto) +* +* Returned: +* PV d(6) heliocentric x,y,z,xdot,ydot,zdot, J2000 +* equatorial triad (AU,AU/s) +* JSTAT i status: +1 = warning: date out of range +* 0 = OK +* -1 = illegal NP (outside 1-9) +* -2 = solution didn't converge +* +* Called: sla_PLANEL +* +* Notes +* +* 1 The epoch, DATE, is in the TDB timescale and is a Modified +* Julian Date (JD-2400000.5). +* +* 2 The reference frame is equatorial and is with respect to the +* mean equinox and ecliptic of epoch J2000. +* +* 3 If an NP value outside the range 1-9 is supplied, an error +* status (JSTAT = -1) is returned and the PV vector set to zeroes. +* +* 4 The algorithm for obtaining the mean elements of the planets +* from Mercury to Neptune is due to J.L. Simon, P. Bretagnon, +* J. Chapront, M. Chapront-Touze, G. Francou and J. Laskar +* (Bureau des Longitudes, Paris). The (completely different) +* algorithm for calculating the ecliptic coordinates of Pluto +* is by Meeus. +* +* 5 Comparisons of the present routine with the JPL DE200 ephemeris +* give the following RMS errors over the interval 1960-2025: +* +* position (km) speed (metre/sec) +* +* Mercury 334 0.437 +* Venus 1060 0.855 +* EMB 2010 0.815 +* Mars 7690 1.98 +* Jupiter 71700 7.70 +* Saturn 199000 19.4 +* Uranus 564000 16.4 +* Neptune 158000 14.4 +* Pluto 36400 0.137 +* +* From comparisons with DE102, Simon et al quote the following +* longitude accuracies over the interval 1800-2200: +* +* Mercury 4" +* Venus 5" +* EMB 6" +* Mars 17" +* Jupiter 71" +* Saturn 81" +* Uranus 86" +* Neptune 11" +* +* In the case of Pluto, Meeus quotes an accuracy of 0.6 arcsec +* in longitude and 0.2 arcsec in latitude for the period +* 1885-2099. +* +* For all except Pluto, over the period 1000-3000 the accuracy +* is better than 1.5 times that over 1800-2200. Outside the +* period 1000-3000 the accuracy declines. For Pluto the +* accuracy declines rapidly outside the period 1885-2099. +* Outside these ranges (1885-2099 for Pluto, 1000-3000 for +* the rest) a "date out of range" warning status (JSTAT=+1) +* is returned. +* +* 6 The algorithms for (i) Mercury through Neptune and (ii) Pluto +* are completely independent. In the Mercury through Neptune +* case, the present SLALIB implementation differs from the +* original Simon et al Fortran code in the following respects. +* +* * The date is supplied as a Modified Julian Date rather +* than a Julian Date (MJD = JD - 2400000.5). +* +* * The result is returned only in equatorial Cartesian form; +* the ecliptic longitude, latitude and radius vector are not +* returned. +* +* * The velocity is in AU per second, not AU per day. +* +* * Different error/warning status values are used. +* +* * Kepler's equation is not solved inline. +* +* * Polynomials in T are nested to minimize rounding errors. +* +* * Explicit double-precision constants are used to avoid +* mixed-mode expressions. +* +* * There are other, cosmetic, changes to comply with +* Starlink/SLALIB style guidelines. +* +* None of the above changes affects the result significantly. +* +* 7 For NP=3 the result is for the Earth-Moon Barycentre. To +* obtain the heliocentric position and velocity of the Earth, +* either use the SLALIB routine sla_EVP or call sla_DMOON and +* subtract 0.012150581 times the geocentric Moon vector from +* the EMB vector produced by the present routine. (The Moon +* vector should be precessed to J2000 first, but this can +* be omitted for modern epochs without introducing significant +* inaccuracy.) +* +* References: Simon et al., Astron. Astrophys. 282, 663 (1994). +* Meeus, Astronomical Algorithms, Willmann-Bell (1991). +* +* P.T.Wallace Starlink 27 May 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE + INTEGER NP + DOUBLE PRECISION PV(6) + INTEGER JSTAT + +* 2Pi, deg to radians, arcsec to radians + DOUBLE PRECISION D2PI,D2R,AS2R + PARAMETER (D2PI=6.283185307179586476925286766559D0, + : D2R=0.017453292519943295769236907684886D0, + : AS2R=4.848136811095359935899141023579D-6) + +* Gaussian gravitational constant (exact) + DOUBLE PRECISION GCON + PARAMETER (GCON=0.01720209895D0) + +* Seconds per Julian century + DOUBLE PRECISION SPC + PARAMETER (SPC=36525D0*86400D0) + +* Sin and cos of J2000 mean obliquity (IAU 1976) + DOUBLE PRECISION SE,CE + PARAMETER (SE=0.3977771559319137D0, + : CE=0.9174820620691818D0) + + INTEGER I,J,IJSP(3,43) + DOUBLE PRECISION AMAS(8),A(3,8),DLM(3,8),E(3,8), + : PI(3,8),DINC(3,8),OMEGA(3,8), + : DKP(9,8),CA(9,8),SA(9,8), + : DKQ(10,8),CLO(10,8),SLO(10,8), + : T,DA,DE,DPE,DI,DO,DMU,ARGA,ARGL,DM, + : AB(2,3,43),DJ0,DS0,DP0,DL0,DLD0,DB0,DR0, + : DJ,DS,DP,DJD,DSD,DPD,WLBR(3),WLBRD(3), + : WJ,WS,WP,AL,ALD,SAL,CAL, + : AC,BC,DL,DLD,DB,DBD,DR,DRD, + : SL,CL,SB,CB,SLCB,CLCB,X,Y,Z,XD,YD,ZD + +* ----------------------- +* Mercury through Neptune +* ----------------------- + +* Planetary inverse masses + DATA AMAS / 6023600D0,408523.5D0,328900.5D0,3098710D0, + : 1047.355D0,3498.5D0,22869D0,19314D0 / + +* +* Tables giving the mean Keplerian elements, limited to T**2 terms: +* +* A semi-major axis (AU) +* DLM mean longitude (degree and arcsecond) +* E eccentricity +* PI longitude of the perihelion (degree and arcsecond) +* DINC inclination (degree and arcsecond) +* OMEGA longitude of the ascending node (degree and arcsecond) +* + DATA A / + : 0.3870983098D0, 0D0, 0D0, + : 0.7233298200D0, 0D0, 0D0, + : 1.0000010178D0, 0D0, 0D0, + : 1.5236793419D0, 3D-10, 0D0, + : 5.2026032092D0, 19132D-10, -39D-10, + : 9.5549091915D0, -0.0000213896D0, 444D-10, + : 19.2184460618D0, -3716D-10, 979D-10, + : 30.1103868694D0, -16635D-10, 686D-10 / +* + DATA DLM / + : 252.25090552D0, 5381016286.88982D0, -1.92789D0, + : 181.97980085D0, 2106641364.33548D0, 0.59381D0, + : 100.46645683D0, 1295977422.83429D0, -2.04411D0, + : 355.43299958D0, 689050774.93988D0, 0.94264D0, + : 34.35151874D0, 109256603.77991D0, -30.60378D0, + : 50.07744430D0, 43996098.55732D0, 75.61614D0, + : 314.05500511D0, 15424811.93933D0, -1.75083D0, + : 304.34866548D0, 7865503.20744D0, 0.21103D0/ +* + DATA E / + : 0.2056317526D0, 0.0002040653D0, -28349D-10, + : 0.0067719164D0, -0.0004776521D0, 98127D-10, + : 0.0167086342D0, -0.0004203654D0, -0.0000126734D0, + : 0.0934006477D0, 0.0009048438D0, -80641D-10, + : 0.0484979255D0, 0.0016322542D0, -0.0000471366D0, + : 0.0555481426D0, -0.0034664062D0, -0.0000643639D0, + : 0.0463812221D0, -0.0002729293D0, 0.0000078913D0, + : 0.0094557470D0, 0.0000603263D0, 0D0 / +* + DATA PI / + : 77.45611904D0, 5719.11590D0, -4.83016D0, + : 131.56370300D0, 175.48640D0, -498.48184D0, + : 102.93734808D0, 11612.35290D0, 53.27577D0, + : 336.06023395D0, 15980.45908D0, -62.32800D0, + : 14.33120687D0, 7758.75163D0, 259.95938D0, + : 93.05723748D0, 20395.49439D0, 190.25952D0, + : 173.00529106D0, 3215.56238D0, -34.09288D0, + : 48.12027554D0, 1050.71912D0, 27.39717D0 / +* + DATA DINC / + : 7.00498625D0, -214.25629D0, 0.28977D0, + : 3.39466189D0, -30.84437D0, -11.67836D0, + : 0D0, 469.97289D0, -3.35053D0, + : 1.84972648D0, -293.31722D0, -8.11830D0, + : 1.30326698D0, -71.55890D0, 11.95297D0, + : 2.48887878D0, 91.85195D0, -17.66225D0, + : 0.77319689D0, -60.72723D0, 1.25759D0, + : 1.76995259D0, 8.12333D0, 0.08135D0 / +* + DATA OMEGA / + : 48.33089304D0, -4515.21727D0, -31.79892D0, + : 76.67992019D0, -10008.48154D0, -51.32614D0, + : 174.87317577D0, -8679.27034D0, 15.34191D0, + : 49.55809321D0, -10620.90088D0, -230.57416D0, + : 100.46440702D0, 6362.03561D0, 326.52178D0, + : 113.66550252D0, -9240.19942D0, -66.23743D0, + : 74.00595701D0, 2669.15033D0, 145.93964D0, + : 131.78405702D0, -221.94322D0, -0.78728D0 / +* +* Tables for trigonometric terms to be added to the mean elements +* of the semi-major axes. +* + DATA DKP / + : 69613, 75645, 88306, 59899, 15746, 71087, 142173, 3086, 0, + : 21863, 32794, 26934, 10931, 26250, 43725, 53867, 28939, 0, + : 16002, 21863, 32004, 10931, 14529, 16368, 15318, 32794, 0, + : 6345, 7818, 15636, 7077, 8184, 14163, 1107, 4872, 0, + : 1760, 1454, 1167, 880, 287, 2640, 19, 2047, 1454, + : 574, 0, 880, 287, 19, 1760, 1167, 306, 574, + : 204, 0, 177, 1265, 4, 385, 200, 208, 204, + : 0, 102, 106, 4, 98, 1367, 487, 204, 0 / +* + DATA CA / + : 4, -13, 11, -9, -9, -3, -1, 4, 0, + : -156, 59, -42, 6, 19, -20, -10, -12, 0, + : 64, -152, 62, -8, 32, -41, 19, -11, 0, + : 124, 621, -145, 208, 54, -57, 30, 15, 0, + : -23437, -2634, 6601, 6259, -1507, -1821, 2620, -2115,-1489, + : 62911,-119919, 79336, 17814,-24241, 12068, 8306, -4893, 8902, + : 389061,-262125,-44088, 8387,-22976, -2093, -615, -9720, 6633, + :-412235,-157046,-31430, 37817, -9740, -13, -7449, 9644, 0 / +* + DATA SA / + : -29, -1, 9, 6, -6, 5, 4, 0, 0, + : -48, -125, -26, -37, 18, -13, -20, -2, 0, + : -150, -46, 68, 54, 14, 24, -28, 22, 0, + : -621, 532, -694, -20, 192, -94, 71, -73, 0, + : -14614,-19828, -5869, 1881, -4372, -2255, 782, 930, 913, + : 139737, 0, 24667, 51123, -5102, 7429, -4095, -1976,-9566, + : -138081, 0, 37205,-49039,-41901,-33872,-27037,-12474,18797, + : 0, 28492,133236, 69654, 52322,-49577,-26430, -3593, 0 / +* +* Tables giving the trigonometric terms to be added to the mean +* elements of the mean longitudes. +* + DATA DKQ / + : 3086, 15746, 69613, 59899, 75645, 88306, 12661, 2658, 0, 0, + : 21863, 32794, 10931, 73, 4387, 26934, 1473, 2157, 0, 0, + : 10, 16002, 21863, 10931, 1473, 32004, 4387, 73, 0, 0, + : 10, 6345, 7818, 1107, 15636, 7077, 8184, 532, 10, 0, + : 19, 1760, 1454, 287, 1167, 880, 574, 2640, 19,1454, + : 19, 574, 287, 306, 1760, 12, 31, 38, 19, 574, + : 4, 204, 177, 8, 31, 200, 1265, 102, 4, 204, + : 4, 102, 106, 8, 98, 1367, 487, 204, 4, 102 / +* + DATA CLO / + : 21, -95, -157, 41, -5, 42, 23, 30, 0, 0, + : -160, -313, -235, 60, -74, -76, -27, 34, 0, 0, + : -325, -322, -79, 232, -52, 97, 55, -41, 0, 0, + : 2268, -979, 802, 602, -668, -33, 345, 201, -55, 0, + : 7610, -4997,-7689,-5841,-2617, 1115, -748, -607, 6074, 354, + : -18549, 30125,20012, -730, 824, 23, 1289, -352,-14767,-2062, + :-135245,-14594, 4197,-4030,-5630,-2898, 2540, -306, 2939, 1986, + : 89948, 2103, 8963, 2695, 3682, 1648, 866, -154, -1963, -283 / +* + DATA SLO / + : -342, 136, -23, 62, 66, -52, -33, 17, 0, 0, + : 524, -149, -35, 117, 151, 122, -71, -62, 0, 0, + : -105, -137, 258, 35, -116, -88, -112, -80, 0, 0, + : 854, -205, -936, -240, 140, -341, -97, -232, 536, 0, + : -56980, 8016, 1012, 1448,-3024,-3710, 318, 503, 3767, 577, + : 138606,-13478,-4964, 1441,-1319,-1482, 427, 1236, -9167,-1918, + : 71234,-41116, 5334,-4935,-1848, 66, 434,-1748, 3780, -701, + : -47645, 11647, 2166, 3194, 679, 0, -244, -419, -2531, 48 / + +* ----- +* Pluto +* ----- + +* +* Coefficients for fundamental arguments: mean longitudes +* (degrees) and mean rate of change of longitude (degrees per +* Julian century) for Jupiter, Saturn and Pluto +* + DATA DJ0, DJD / 34.35D0, 3034.9057D0 / + DATA DS0, DSD / 50.08D0, 1222.1138D0 / + DATA DP0, DPD / 238.96D0, 144.9600D0 / + +* Coefficients for latitude, longitude, radius vector + DATA DL0,DLD0 / 238.956785D0, 144.96D0 / + DATA DB0 / -3.908202D0 / + DATA DR0 / 40.7247248D0 / + +* +* Coefficients for periodic terms (Meeus's Table 36.A) +* +* The coefficients for term n in the series are: +* +* IJSP(1,n) J +* IJSP(2,n) S +* IJSP(3,n) P +* AB(1,1,n) longitude sine (degrees) +* AB(2,1,n) longitude cosine (degrees) +* AB(1,2,n) latitude sine (degrees) +* AB(2,2,n) latitude cosine (degrees) +* AB(1,3,n) radius vector sine (AU) +* AB(2,3,n) radius vector cosine (AU) +* + DATA (IJSP(I, 1),I=1,3),((AB(J,I, 1),J=1,2),I=1,3) / + : 0, 0, 1, + : -19798886D-6, 19848454D-6, + : -5453098D-6, -14974876D-6, + : 66867334D-7, 68955876D-7 / + DATA (IJSP(I, 2),I=1,3),((AB(J,I, 2),J=1,2),I=1,3) / + : 0, 0, 2, + : 897499D-6, -4955707D-6, + : 3527363D-6, 1672673D-6, + : -11826086D-7, -333765D-7 / + DATA (IJSP(I, 3),I=1,3),((AB(J,I, 3),J=1,2),I=1,3) / + : 0, 0, 3, + : 610820D-6, 1210521D-6, + : -1050939D-6, 327763D-6, + : 1593657D-7, -1439953D-7 / + DATA (IJSP(I, 4),I=1,3),((AB(J,I, 4),J=1,2),I=1,3) / + : 0, 0, 4, + : -341639D-6, -189719D-6, + : 178691D-6, -291925D-6, + : -18948D-7, 482443D-7 / + DATA (IJSP(I, 5),I=1,3),((AB(J,I, 5),J=1,2),I=1,3) / + : 0, 0, 5, + : 129027D-6, -34863D-6, + : 18763D-6, 100448D-6, + : -66634D-7, -85576D-7 / + DATA (IJSP(I, 6),I=1,3),((AB(J,I, 6),J=1,2),I=1,3) / + : 0, 0, 6, + : -38215D-6, 31061D-6, + : -30594D-6, -25838D-6, + : 30841D-7, -5765D-7 / + DATA (IJSP(I, 7),I=1,3),((AB(J,I, 7),J=1,2),I=1,3) / + : 0, 1, -1, + : 20349D-6, -9886D-6, + : 4965D-6, 11263D-6, + : -6140D-7, 22254D-7 / + DATA (IJSP(I, 8),I=1,3),((AB(J,I, 8),J=1,2),I=1,3) / + : 0, 1, 0, + : -4045D-6, -4904D-6, + : 310D-6, -132D-6, + : 4434D-7, 4443D-7 / + DATA (IJSP(I, 9),I=1,3),((AB(J,I, 9),J=1,2),I=1,3) / + : 0, 1, 1, + : -5885D-6, -3238D-6, + : 2036D-6, -947D-6, + : -1518D-7, 641D-7 / + DATA (IJSP(I,10),I=1,3),((AB(J,I,10),J=1,2),I=1,3) / + : 0, 1, 2, + : -3812D-6, 3011D-6, + : -2D-6, -674D-6, + : -5D-7, 792D-7 / + DATA (IJSP(I,11),I=1,3),((AB(J,I,11),J=1,2),I=1,3) / + : 0, 1, 3, + : -601D-6, 3468D-6, + : -329D-6, -563D-6, + : 518D-7, 518D-7 / + DATA (IJSP(I,12),I=1,3),((AB(J,I,12),J=1,2),I=1,3) / + : 0, 2, -2, + : 1237D-6, 463D-6, + : -64D-6, 39D-6, + : -13D-7, -221D-7 / + DATA (IJSP(I,13),I=1,3),((AB(J,I,13),J=1,2),I=1,3) / + : 0, 2, -1, + : 1086D-6, -911D-6, + : -94D-6, 210D-6, + : 837D-7, -494D-7 / + DATA (IJSP(I,14),I=1,3),((AB(J,I,14),J=1,2),I=1,3) / + : 0, 2, 0, + : 595D-6, -1229D-6, + : -8D-6, -160D-6, + : -281D-7, 616D-7 / + DATA (IJSP(I,15),I=1,3),((AB(J,I,15),J=1,2),I=1,3) / + : 1, -1, 0, + : 2484D-6, -485D-6, + : -177D-6, 259D-6, + : 260D-7, -395D-7 / + DATA (IJSP(I,16),I=1,3),((AB(J,I,16),J=1,2),I=1,3) / + : 1, -1, 1, + : 839D-6, -1414D-6, + : 17D-6, 234D-6, + : -191D-7, -396D-7 / + DATA (IJSP(I,17),I=1,3),((AB(J,I,17),J=1,2),I=1,3) / + : 1, 0, -3, + : -964D-6, 1059D-6, + : 582D-6, -285D-6, + : -3218D-7, 370D-7 / + DATA (IJSP(I,18),I=1,3),((AB(J,I,18),J=1,2),I=1,3) / + : 1, 0, -2, + : -2303D-6, -1038D-6, + : -298D-6, 692D-6, + : 8019D-7, -7869D-7 / + DATA (IJSP(I,19),I=1,3),((AB(J,I,19),J=1,2),I=1,3) / + : 1, 0, -1, + : 7049D-6, 747D-6, + : 157D-6, 201D-6, + : 105D-7, 45637D-7 / + DATA (IJSP(I,20),I=1,3),((AB(J,I,20),J=1,2),I=1,3) / + : 1, 0, 0, + : 1179D-6, -358D-6, + : 304D-6, 825D-6, + : 8623D-7, 8444D-7 / + DATA (IJSP(I,21),I=1,3),((AB(J,I,21),J=1,2),I=1,3) / + : 1, 0, 1, + : 393D-6, -63D-6, + : -124D-6, -29D-6, + : -896D-7, -801D-7 / + DATA (IJSP(I,22),I=1,3),((AB(J,I,22),J=1,2),I=1,3) / + : 1, 0, 2, + : 111D-6, -268D-6, + : 15D-6, 8D-6, + : 208D-7, -122D-7 / + DATA (IJSP(I,23),I=1,3),((AB(J,I,23),J=1,2),I=1,3) / + : 1, 0, 3, + : -52D-6, -154D-6, + : 7D-6, 15D-6, + : -133D-7, 65D-7 / + DATA (IJSP(I,24),I=1,3),((AB(J,I,24),J=1,2),I=1,3) / + : 1, 0, 4, + : -78D-6, -30D-6, + : 2D-6, 2D-6, + : -16D-7, 1D-7 / + DATA (IJSP(I,25),I=1,3),((AB(J,I,25),J=1,2),I=1,3) / + : 1, 1, -3, + : -34D-6, -26D-6, + : 4D-6, 2D-6, + : -22D-7, 7D-7 / + DATA (IJSP(I,26),I=1,3),((AB(J,I,26),J=1,2),I=1,3) / + : 1, 1, -2, + : -43D-6, 1D-6, + : 3D-6, 0D-6, + : -8D-7, 16D-7 / + DATA (IJSP(I,27),I=1,3),((AB(J,I,27),J=1,2),I=1,3) / + : 1, 1, -1, + : -15D-6, 21D-6, + : 1D-6, -1D-6, + : 2D-7, 9D-7 / + DATA (IJSP(I,28),I=1,3),((AB(J,I,28),J=1,2),I=1,3) / + : 1, 1, 0, + : -1D-6, 15D-6, + : 0D-6, -2D-6, + : 12D-7, 5D-7 / + DATA (IJSP(I,29),I=1,3),((AB(J,I,29),J=1,2),I=1,3) / + : 1, 1, 1, + : 4D-6, 7D-6, + : 1D-6, 0D-6, + : 1D-7, -3D-7 / + DATA (IJSP(I,30),I=1,3),((AB(J,I,30),J=1,2),I=1,3) / + : 1, 1, 3, + : 1D-6, 5D-6, + : 1D-6, -1D-6, + : 1D-7, 0D-7 / + DATA (IJSP(I,31),I=1,3),((AB(J,I,31),J=1,2),I=1,3) / + : 2, 0, -6, + : 8D-6, 3D-6, + : -2D-6, -3D-6, + : 9D-7, 5D-7 / + DATA (IJSP(I,32),I=1,3),((AB(J,I,32),J=1,2),I=1,3) / + : 2, 0, -5, + : -3D-6, 6D-6, + : 1D-6, 2D-6, + : 2D-7, -1D-7 / + DATA (IJSP(I,33),I=1,3),((AB(J,I,33),J=1,2),I=1,3) / + : 2, 0, -4, + : 6D-6, -13D-6, + : -8D-6, 2D-6, + : 14D-7, 10D-7 / + DATA (IJSP(I,34),I=1,3),((AB(J,I,34),J=1,2),I=1,3) / + : 2, 0, -3, + : 10D-6, 22D-6, + : 10D-6, -7D-6, + : -65D-7, 12D-7 / + DATA (IJSP(I,35),I=1,3),((AB(J,I,35),J=1,2),I=1,3) / + : 2, 0, -2, + : -57D-6, -32D-6, + : 0D-6, 21D-6, + : 126D-7, -233D-7 / + DATA (IJSP(I,36),I=1,3),((AB(J,I,36),J=1,2),I=1,3) / + : 2, 0, -1, + : 157D-6, -46D-6, + : 8D-6, 5D-6, + : 270D-7, 1068D-7 / + DATA (IJSP(I,37),I=1,3),((AB(J,I,37),J=1,2),I=1,3) / + : 2, 0, 0, + : 12D-6, -18D-6, + : 13D-6, 16D-6, + : 254D-7, 155D-7 / + DATA (IJSP(I,38),I=1,3),((AB(J,I,38),J=1,2),I=1,3) / + : 2, 0, 1, + : -4D-6, 8D-6, + : -2D-6, -3D-6, + : -26D-7, -2D-7 / + DATA (IJSP(I,39),I=1,3),((AB(J,I,39),J=1,2),I=1,3) / + : 2, 0, 2, + : -5D-6, 0D-6, + : 0D-6, 0D-6, + : 7D-7, 0D-7 / + DATA (IJSP(I,40),I=1,3),((AB(J,I,40),J=1,2),I=1,3) / + : 2, 0, 3, + : 3D-6, 4D-6, + : 0D-6, 1D-6, + : -11D-7, 4D-7 / + DATA (IJSP(I,41),I=1,3),((AB(J,I,41),J=1,2),I=1,3) / + : 3, 0, -2, + : -1D-6, -1D-6, + : 0D-6, 1D-6, + : 4D-7, -14D-7 / + DATA (IJSP(I,42),I=1,3),((AB(J,I,42),J=1,2),I=1,3) / + : 3, 0, -1, + : 6D-6, -3D-6, + : 0D-6, 0D-6, + : 18D-7, 35D-7 / + DATA (IJSP(I,43),I=1,3),((AB(J,I,43),J=1,2),I=1,3) / + : 3, 0, 0, + : -1D-6, -2D-6, + : 0D-6, 1D-6, + : 13D-7, 3D-7 / + + +* Validate the planet number. + IF (NP.LT.1.OR.NP.GT.9) THEN + JSTAT=-1 + DO I=1,6 + PV(I)=0D0 + END DO + ELSE + +* Separate algorithms for Pluto and the rest. + IF (NP.NE.9) THEN + +* ----------------------- +* Mercury through Neptune +* ----------------------- + +* Time: Julian millennia since J2000. + T=(DATE-51544.5D0)/365250D0 + +* OK status unless remote epoch. + IF (ABS(T).LE.1D0) THEN + JSTAT=0 + ELSE + JSTAT=1 + END IF + +* Compute the mean elements. + DA=A(1,NP)+(A(2,NP)+A(3,NP)*T)*T + DL=(3600D0*DLM(1,NP)+(DLM(2,NP)+DLM(3,NP)*T)*T)*AS2R + DE=E(1,NP)+(E(2,NP)+E(3,NP)*T)*T + DPE=MOD((3600D0*PI(1,NP)+(PI(2,NP)+PI(3,NP)*T)*T)*AS2R,D2PI) + DI=(3600D0*DINC(1,NP)+(DINC(2,NP)+DINC(3,NP)*T)*T)*AS2R + DO=MOD((3600D0*OMEGA(1,NP) + : +(OMEGA(2,NP)+OMEGA(3,NP)*T)*T)*AS2R,D2PI) + +* Apply the trigonometric terms. + DMU=0.35953620D0*T + DO J=1,8 + ARGA=DKP(J,NP)*DMU + ARGL=DKQ(J,NP)*DMU + DA=DA+(CA(J,NP)*COS(ARGA)+SA(J,NP)*SIN(ARGA))*1D-7 + DL=DL+(CLO(J,NP)*COS(ARGL)+SLO(J,NP)*SIN(ARGL))*1D-7 + END DO + ARGA=DKP(9,NP)*DMU + DA=DA+T*(CA(9,NP)*COS(ARGA)+SA(9,NP)*SIN(ARGA))*1D-7 + DO J=9,10 + ARGL=DKQ(J,NP)*DMU + DL=DL+T*(CLO(J,NP)*COS(ARGL)+SLO(J,NP)*SIN(ARGL))*1D-7 + END DO + DL=MOD(DL,D2PI) + +* Daily motion. + DM=GCON*SQRT((1D0+1D0/AMAS(NP))/(DA*DA*DA)) + +* Make the prediction. + CALL sla_PLANEL(DATE,1,DATE,DI,DO,DPE,DA,DE,DL,DM,PV,J) + IF (J.LT.0) JSTAT=-2 + + ELSE + +* ----- +* Pluto +* ----- + +* Time: Julian centuries since J2000. + T=(DATE-51544.5D0)/36525D0 + +* OK status unless remote epoch. + IF (T.GE.-1.15D0.AND.T.LE.1D0) THEN + JSTAT=0 + ELSE + JSTAT=1 + END IF + +* Fundamental arguments (radians). + DJ=(DJ0+DJD*T)*D2R + DS=(DS0+DSD*T)*D2R + DP=(DP0+DPD*T)*D2R + +* Initialize coefficients and derivatives. + DO I=1,3 + WLBR(I)=0D0 + WLBRD(I)=0D0 + END DO + +* Term by term through Meeus Table 36.A. + DO J=1,43 + +* Argument and derivative (radians, radians per century). + WJ=DBLE(IJSP(1,J)) + WS=DBLE(IJSP(2,J)) + WP=DBLE(IJSP(3,J)) + AL=WJ*DJ+WS*DS+WP*DP + ALD=(WJ*DJD+WS*DSD+WP*DPD)*D2R + +* Functions of argument. + SAL=SIN(AL) + CAL=COS(AL) + +* Periodic terms in longitude, latitude, radius vector. + DO I=1,3 + +* A and B coefficients (deg, AU). + AC=AB(1,I,J) + BC=AB(2,I,J) + +* Periodic terms (deg, AU, deg/Jc, AU/Jc). + WLBR(I)=WLBR(I)+AC*SAL+BC*CAL + WLBRD(I)=WLBRD(I)+(AC*CAL-BC*SAL)*ALD + END DO + END DO + +* Heliocentric longitude and derivative (radians, radians/sec). + DL=(DL0+DLD0*T+WLBR(1))*D2R + DLD=(DLD0+WLBRD(1))*D2R/SPC + +* Heliocentric latitude and derivative (radians, radians/sec). + DB=(DB0+WLBR(2))*D2R + DBD=WLBRD(2)*D2R/SPC + +* Heliocentric radius vector and derivative (AU, AU/sec). + DR=DR0+WLBR(3) + DRD=WLBRD(3)/SPC + +* Functions of latitude, longitude, radius vector. + SL=SIN(DL) + CL=COS(DL) + SB=SIN(DB) + CB=COS(DB) + SLCB=SL*CB + CLCB=CL*CB + +* Heliocentric vector and derivative, J2000 ecliptic and equinox. + X=DR*CLCB + Y=DR*SLCB + Z=DR*SB + XD=DRD*CLCB-DR*(CL*SB*DBD+SLCB*DLD) + YD=DRD*SLCB+DR*(-SL*SB*DBD+CLCB*DLD) + ZD=DRD*SB+DR*CB*DBD + +* Transform to J2000 equator and equinox. + PV(1)=X + PV(2)=Y*CE-Z*SE + PV(3)=Y*SE+Z*CE + PV(4)=XD + PV(5)=YD*CE-ZD*SE + PV(6)=YD*SE+ZD*CE + END IF + END IF + + END diff --git a/src/slalib/plante.f b/src/slalib/plante.f new file mode 100644 index 0000000..e8f89d9 --- /dev/null +++ b/src/slalib/plante.f @@ -0,0 +1,157 @@ + SUBROUTINE sla_PLANTE (DATE, ELONG, PHI, JFORM, EPOCH, + : ORBINC, ANODE, PERIH, AORQ, E, + : AORL, DM, RA, DEC, R, JSTAT) +*+ +* - - - - - - - +* P L A N T E +* - - - - - - - +* +* Topocentric apparent RA,Dec of a Solar-System object whose +* heliocentric orbital elements are known. +* +* Given: +* DATE d MJD of observation (JD - 2400000.5) +* ELONG d observer's east longitude (radians) +* PHI d observer's geodetic latitude (radians) +* JFORM i choice of element set (1-3; Note 4) +* EPOCH d epoch of elements (TT MJD) +* ORBINC d inclination (radians) +* ANODE d longitude of the ascending node (radians) +* PERIH d longitude or argument of perihelion (radians) +* AORQ d mean distance or perihelion distance (AU) +* E d eccentricity +* AORL d mean anomaly or longitude (radians, JFORM=1,2 only) +* DM d daily motion (radians, JFORM=1 only ) +* +* Returned: +* RA,DEC d RA, Dec (topocentric apparent, radians) +* R d distance from observer (AU) +* JSTAT i status: 0 = OK +* -1 = illegal JFORM +* -2 = illegal E +* -3 = illegal AORQ +* -4 = illegal DM +* -5 = numerical error +* +* Notes: +* +* 1 DATE is the instant for which the prediction is required. It is +* in the TT timescale (formerly Ephemeris Time, ET) and is a +* Modified Julian Date (JD-2400000.5). +* +* 2 The longitude and latitude allow correction for geocentric +* parallax. This is usually a small effect, but can become +* important for Earth-crossing asteroids. Geocentric positions +* can be generated by appropriate use of routines sla_EVP and +* sla_PLANEL. +* +* 3 The elements are with respect to the J2000 ecliptic and equinox. +* +* 4 Three different element-format options are available: +* +* Option JFORM=1, suitable for the major planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = longitude of perihelion, curly pi (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e +* AORL = mean longitude L (radians) +* DM = daily motion (radians) +* +* Option JFORM=2, suitable for minor planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e +* AORL = mean anomaly M (radians) +* +* Option JFORM=3, suitable for comets: +* +* EPOCH = epoch of perihelion (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = perihelion distance, q (AU) +* E = eccentricity, e +* +* 5 Unused elements (DM for JFORM=2, AORL and DM for JFORM=3) are +* not accessed. +* +* Called: sla_GMST, sla_DT, sla_EPJ, sla_PVOBS, sla_PRENUT, +* sla_PLANEL, sla_DMXV, sla_DCC2S, sla_DRANRM +* +* P.T.Wallace Starlink 17 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,ELONG,PHI + INTEGER JFORM + DOUBLE PRECISION EPOCH,ORBINC,ANODE,PERIH,AORQ,E, + : AORL,DM,RA,DEC,R + INTEGER JSTAT + +* Light time for unit distance (sec) + DOUBLE PRECISION TAU + PARAMETER (TAU=499.004782D0) + + INTEGER I + DOUBLE PRECISION DVB(3),DPB(3),VSG(6),VSP(6),V(6),RMAT(3,3), + : VGP(6),STL,VGO(6),DX,DY,DZ,D,TL + DOUBLE PRECISION sla_GMST,sla_DT,sla_EPJ,sla_DRANRM + + + +* Sun to geocentre (J2000). + CALL sla_EVP(DATE,2000D0,DVB,DPB,VSG(4),VSG) + +* Sun to planet (J2000). + CALL sla_PLANEL(DATE,JFORM,EPOCH,ORBINC,ANODE,PERIH,AORQ, + : E,AORL,DM,VSP,JSTAT) + +* Geocentre to planet (J2000). + DO I=1,6 + V(I)=VSP(I)-VSG(I) + END DO + +* Precession and nutation to date. + CALL sla_PRENUT(2000D0,DATE,RMAT) + CALL sla_DMXV(RMAT,V,VGP) + CALL sla_DMXV(RMAT,V(4),VGP(4)) + +* Geocentre to observer (date). + STL=sla_GMST(DATE-sla_DT(sla_EPJ(DATE))/86400D0)+ELONG + CALL sla_PVOBS(PHI,0D0,STL,VGO) + +* Observer to planet (date). + DO I=1,6 + V(I)=VGP(I)-VGO(I) + END DO + +* Geometric distance (AU). + DX=V(1) + DY=V(2) + DZ=V(3) + D=SQRT(DX*DX+DY*DY+DZ*DZ) + +* Light time (sec). + TL=TAU*D + +* Correct position for planetary aberration + DO I=1,3 + V(I)=V(I)-TL*V(I+3) + END DO + +* To RA,Dec. + CALL sla_DCC2S(V,RA,DEC) + RA=sla_DRANRM(RA) + R=D + + END diff --git a/src/slalib/pm.f b/src/slalib/pm.f new file mode 100644 index 0000000..82a5772 --- /dev/null +++ b/src/slalib/pm.f @@ -0,0 +1,74 @@ + SUBROUTINE sla_PM (R0, D0, PR, PD, PX, RV, EP0, EP1, R1, D1) +*+ +* - - - +* P M +* - - - +* +* Apply corrections for proper motion to a star RA,Dec +* (double precision) +* +* References: +* 1984 Astronomical Almanac, pp B39-B41. +* (also Lederle & Schwan, Astron. Astrophys. 134, +* 1-6, 1984) +* +* Given: +* R0,D0 dp RA,Dec at epoch EP0 (rad) +* PR,PD dp proper motions: RA,Dec changes per year of epoch +* PX dp parallax (arcsec) +* RV dp radial velocity (km/sec, +ve if receding) +* EP0 dp start epoch in years (e.g. Julian epoch) +* EP1 dp end epoch in years (same system as EP0) +* +* Returned: +* R1,D1 dp RA,Dec at epoch EP1 (rad) +* +* Called: +* sla_DCS2C spherical to Cartesian +* sla_DCC2S Cartesian to spherical +* sla_DRANRM normalize angle 0-2Pi +* +* Note: +* The proper motions in RA are dRA/dt rather than +* cos(Dec)*dRA/dt, and are in the same coordinate +* system as R0,D0. +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION R0,D0,PR,PD,PX,RV,EP0,EP1,R1,D1 + +* Km/s to AU/year multiplied by arc seconds to radians + DOUBLE PRECISION VFR + PARAMETER (VFR=0.21094502D0*0.484813681109535994D-5) + + INTEGER I + DOUBLE PRECISION sla_DRANRM + DOUBLE PRECISION W,EM(3),T,P(3) + + + +* Spherical to Cartesian + CALL sla_DCS2C(R0,D0,P) + +* Space motion (radians per year) + W=VFR*RV*PX + EM(1)=-PR*P(2)-PD*COS(R0)*SIN(D0)+W*P(1) + EM(2)= PR*P(1)-PD*SIN(R0)*SIN(D0)+W*P(2) + EM(3)= PD*COS(D0) +W*P(3) + +* Apply the motion + T=EP1-EP0 + DO I=1,3 + P(I)=P(I)+T*EM(I) + END DO + +* Cartesian to spherical + CALL sla_DCC2S(P,R1,D1) + R1=sla_DRANRM(R1) + + END diff --git a/src/slalib/polmo.f b/src/slalib/polmo.f new file mode 100644 index 0000000..4532ca8 --- /dev/null +++ b/src/slalib/polmo.f @@ -0,0 +1,133 @@ + SUBROUTINE sla_POLMO ( ELONGM, PHIM, XP, YP, ELONG, PHI, DAZ ) +*+ +* - - - - - - +* P O L M O +* - - - - - - +* +* Polar motion: correct site longitude and latitude for polar +* motion and calculate azimuth difference between celestial and +* terrestrial poles. +* +* Given: +* ELONGM d mean longitude of the observer (radians, east +ve) +* PHIM d mean geodetic latitude of the observer (radians) +* XP d polar motion x-coordinate (radians) +* YP d polar motion y-coordinate (radians) +* +* Returned: +* ELONG d true longitude of the observer (radians, east +ve) +* PHI d true geodetic latitude of the observer (radians) +* DAZ d azimuth correction (terrestrial-celestial, radians) +* +* Notes: +* +* 1) "Mean" longitude and latitude are the (fixed) values for the +* site's location with respect to the IERS terrestrial reference +* frame; the latitude is geodetic. TAKE CARE WITH THE LONGITUDE +* SIGN CONVENTION. The longitudes used by the present routine +* are east-positive, in accordance with geographical convention +* (and right-handed). In particular, note that the longitudes +* returned by the sla_OBS routine are west-positive, following +* astronomical usage, and must be reversed in sign before use in +* the present routine. +* +* 2) XP and YP are the (changing) coordinates of the Celestial +* Ephemeris Pole with respect to the IERS Reference Pole. +* XP is positive along the meridian at longitude 0 degrees, +* and YP is positive along the meridian at longitude +* 270 degrees (i.e. 90 degrees west). Values for XP,YP can +* be obtained from IERS circulars and equivalent publications; +* the maximum amplitude observed so far is about 0.3 arcseconds. +* +* 3) "True" longitude and latitude are the (moving) values for +* the site's location with respect to the celestial ephemeris +* pole and the meridian which corresponds to the Greenwich +* apparent sidereal time. The true longitude and latitude +* link the terrestrial coordinates with the standard celestial +* models (for precession, nutation, sidereal time etc). +* +* 4) The azimuths produced by sla_AOP and sla_AOPQK are with +* respect to due north as defined by the Celestial Ephemeris +* Pole, and can therefore be called "celestial azimuths". +* However, a telescope fixed to the Earth measures azimuth +* essentially with respect to due north as defined by the +* IERS Reference Pole, and can therefore be called "terrestrial +* azimuth". Uncorrected, this would manifest itself as a +* changing "azimuth zero-point error". The value DAZ is the +* correction to be added to a celestial azimuth to produce +* a terrestrial azimuth. +* +* 5) The present routine is rigorous. For most practical +* purposes, the following simplified formulae provide an +* adequate approximation: +* +* ELONG = ELONGM+XP*COS(ELONGM)-YP*SIN(ELONGM) +* PHI = PHIM+(XP*SIN(ELONGM)+YP*COS(ELONGM))*TAN(PHIM) +* DAZ = -SQRT(XP*XP+YP*YP)*COS(ELONGM-ATAN2(XP,YP))/COS(PHIM) +* +* An alternative formulation for DAZ is: +* +* X = COS(ELONGM)*COS(PHIM) +* Y = SIN(ELONGM)*COS(PHIM) +* DAZ = ATAN2(-X*YP-Y*XP,X*X+Y*Y) +* +* Reference: Seidelmann, P.K. (ed), 1992. "Explanatory Supplement +* to the Astronomical Almanac", ISBN 0-935702-68-7, +* sections 3.27, 4.25, 4.52. +* +* P.T.Wallace Starlink 22 February 1996 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION ELONGM,PHIM,XP,YP,ELONG,PHI,DAZ + + DOUBLE PRECISION SEL,CEL,SPH,CPH,XM,YM,ZM,XNM,YNM,ZNM, + : SXP,CXP,SYP,CYP,ZW,XT,YT,ZT,XNT,YNT + + + +* Site mean longitude and mean geodetic latitude as a Cartesian vector + SEL=SIN(ELONGM) + CEL=COS(ELONGM) + SPH=SIN(PHIM) + CPH=COS(PHIM) + + XM=CEL*CPH + YM=SEL*CPH + ZM=SPH + +* Rotate site vector by polar motion, Y-component then X-component + SXP=SIN(XP) + CXP=COS(XP) + SYP=SIN(YP) + CYP=COS(YP) + + ZW=(-YM*SYP+ZM*CYP) + + XT=XM*CXP-ZW*SXP + YT=YM*CYP+ZM*SYP + ZT=XM*SXP+ZW*CXP + +* Rotate also the geocentric direction of the terrestrial pole (0,0,1) + XNM=-SXP*CYP + YNM=SYP + ZNM=CXP*CYP + + CPH=SQRT(XT*XT+YT*YT) + IF (CPH.EQ.0D0) XT=1D0 + SEL=YT/CPH + CEL=XT/CPH + +* Return true longitude and true geodetic latitude of site + ELONG=ATAN2(YT,XT) + PHI=ATAN2(ZT,CPH) + +* Return current azimuth of terrestrial pole seen from site position + XNT=(XNM*CEL+YNM*SEL)*ZT-ZNM*CPH + YNT=-XNM*SEL+YNM*CEL + DAZ=ATAN2(-YNT,-XNT) + + END diff --git a/src/slalib/prebn.f b/src/slalib/prebn.f new file mode 100644 index 0000000..a99dd51 --- /dev/null +++ b/src/slalib/prebn.f @@ -0,0 +1,62 @@ + SUBROUTINE sla_PREBN (BEP0, BEP1, RMATP) +*+ +* - - - - - - +* P R E B N +* - - - - - - +* +* Generate the matrix of precession between two epochs, +* using the old, pre-IAU1976, Bessel-Newcomb model, using +* Kinoshita's formulation (double precision) +* +* Given: +* BEP0 dp beginning Besselian epoch +* BEP1 dp ending Besselian epoch +* +* Returned: +* RMATP dp(3,3) precession matrix +* +* The matrix is in the sense V(BEP1) = RMATP * V(BEP0) +* +* Reference: +* Kinoshita, H. (1975) 'Formulas for precession', SAO Special +* Report No. 364, Smithsonian Institution Astrophysical +* Observatory, Cambridge, Massachusetts. +* +* Called: sla_DEULER +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION BEP0,BEP1,RMATP(3,3) + +* Arc seconds to radians + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + + DOUBLE PRECISION BIGT,T,TAS2R,W,ZETA,Z,THETA + + + +* Interval between basic epoch B1850.0 and beginning epoch in TC + BIGT = (BEP0-1850D0)/100D0 + +* Interval over which precession required, in tropical centuries + T = (BEP1-BEP0)/100D0 + +* Euler angles + TAS2R = T*AS2R + W = 2303.5548D0+(1.39720D0+0.000059D0*BIGT)*BIGT + + ZETA = (W+(0.30242D0-0.000269D0*BIGT+0.017996D0*T)*T)*TAS2R + Z = (W+(1.09478D0+0.000387D0*BIGT+0.018324D0*T)*T)*TAS2R + THETA = (2005.1125D0+(-0.85294D0-0.000365D0*BIGT)*BIGT+ + : (-0.42647D0-0.000365D0*BIGT-0.041802D0*T)*T)*TAS2R + +* Rotation matrix + CALL sla_DEULER('ZYZ',-ZETA,THETA,-Z,RMATP) + + END diff --git a/src/slalib/prec.f b/src/slalib/prec.f new file mode 100644 index 0000000..65a4bb6 --- /dev/null +++ b/src/slalib/prec.f @@ -0,0 +1,79 @@ + SUBROUTINE sla_PREC (EP0, EP1, RMATP) +*+ +* - - - - - +* P R E C +* - - - - - +* +* Form the matrix of precession between two epochs (IAU 1976, FK5) +* (double precision) +* +* Given: +* EP0 dp beginning epoch +* EP1 dp ending epoch +* +* Returned: +* RMATP dp(3,3) precession matrix +* +* Notes: +* +* 1) The epochs are TDB (loosely ET) Julian epochs. +* +* 2) The matrix is in the sense V(EP1) = RMATP * V(EP0) +* +* 3) Though the matrix method itself is rigorous, the precession +* angles are expressed through canonical polynomials which are +* valid only for a limited time span. There are also known +* errors in the IAU precession rate. The absolute accuracy +* of the present formulation is better than 0.1 arcsec from +* 1960AD to 2040AD, better than 1 arcsec from 1640AD to 2360AD, +* and remains below 3 arcsec for the whole of the period +* 500BC to 3000AD. The errors exceed 10 arcsec outside the +* range 1200BC to 3900AD, exceed 100 arcsec outside 4200BC to +* 5600AD and exceed 1000 arcsec outside 6800BC to 8200AD. +* The SLALIB routine sla_PRECL implements a more elaborate +* model which is suitable for problems spanning several +* thousand years. +* +* References: +* Lieske,J.H., 1979. Astron.Astrophys.,73,282. +* equations (6) & (7), p283. +* Kaplan,G.H., 1981. USNO circular no. 163, pA2. +* +* Called: sla_DEULER +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION EP0,EP1,RMATP(3,3) + +* Arc seconds to radians + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + + DOUBLE PRECISION T0,T,TAS2R,W,ZETA,Z,THETA + + + +* Interval between basic epoch J2000.0 and beginning epoch (JC) + T0 = (EP0-2000D0)/100D0 + +* Interval over which precession required (JC) + T = (EP1-EP0)/100D0 + +* Euler angles + TAS2R = T*AS2R + W = 2306.2181D0+(1.39656D0-0.000139D0*T0)*T0 + + ZETA = (W+((0.30188D0-0.000344D0*T0)+0.017998D0*T)*T)*TAS2R + Z = (W+((1.09468D0+0.000066D0*T0)+0.018203D0*T)*T)*TAS2R + THETA = ((2004.3109D0+(-0.85330D0-0.000217D0*T0)*T0) + : +((-0.42665D0-0.000217D0*T0)-0.041833D0*T)*T)*TAS2R + +* Rotation matrix + CALL sla_DEULER('ZYZ',-ZETA,THETA,-Z,RMATP) + + END diff --git a/src/slalib/preces.f b/src/slalib/preces.f new file mode 100644 index 0000000..09f946e --- /dev/null +++ b/src/slalib/preces.f @@ -0,0 +1,84 @@ + SUBROUTINE sla_PRECES (SYSTEM, EP0, EP1, RA, DC) +*+ +* - - - - - - - +* P R E C E S +* - - - - - - - +* +* Precession - either FK4 (Bessel-Newcomb, pre IAU 1976) or +* FK5 (Fricke, post IAU 1976) as required. +* +* Given: +* SYSTEM char precession to be applied: 'FK4' or 'FK5' +* EP0,EP1 dp starting and ending epoch +* RA,DC dp RA,Dec, mean equator & equinox of epoch EP0 +* +* Returned: +* RA,DC dp RA,Dec, mean equator & equinox of epoch EP1 +* +* Called: sla_DRANRM, sla_PREBN, sla_PREC, sla_DCS2C, +* sla_DMXV, sla_DCC2S +* +* Notes: +* +* 1) Lowercase characters in SYSTEM are acceptable. +* +* 2) The epochs are Besselian if SYSTEM='FK4' and Julian if 'FK5'. +* For example, to precess coordinates in the old system from +* equinox 1900.0 to 1950.0 the call would be: +* CALL sla_PRECES ('FK4', 1900D0, 1950D0, RA, DC) +* +* 3) This routine will NOT correctly convert between the old and +* the new systems - for example conversion from B1950 to J2000. +* For these purposes see sla_FK425, sla_FK524, sla_FK45Z and +* sla_FK54Z. +* +* 4) If an invalid SYSTEM is supplied, values of -99D0,-99D0 will +* be returned for both RA and DC. +* +* P.T.Wallace Starlink 20 April 1990 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + CHARACTER SYSTEM*(*) + DOUBLE PRECISION EP0,EP1,RA,DC + + DOUBLE PRECISION PM(3,3),V1(3),V2(3) + CHARACTER SYSUC*3 + + DOUBLE PRECISION sla_DRANRM + + + + +* Convert to uppercase and validate SYSTEM + SYSUC=SYSTEM + IF (SYSUC(1:1).EQ.'f') SYSUC(1:1)='F' + IF (SYSUC(2:2).EQ.'k') SYSUC(2:2)='K' + IF (SYSUC.NE.'FK4'.AND.SYSUC.NE.'FK5') THEN + RA=-99D0 + DC=-99D0 + ELSE + +* Generate appropriate precession matrix + IF (SYSUC.EQ.'FK4') THEN + CALL sla_PREBN(EP0,EP1,PM) + ELSE + CALL sla_PREC(EP0,EP1,PM) + END IF + +* Convert RA,Dec to x,y,z + CALL sla_DCS2C(RA,DC,V1) + +* Precess + CALL sla_DMXV(PM,V1,V2) + +* Back to RA,Dec + CALL sla_DCC2S(V2,RA,DC) + RA=sla_DRANRM(RA) + + END IF + + END diff --git a/src/slalib/precl.f b/src/slalib/precl.f new file mode 100644 index 0000000..e24b3d3 --- /dev/null +++ b/src/slalib/precl.f @@ -0,0 +1,125 @@ + SUBROUTINE sla_PRECL (EP0, EP1, RMATP) +*+ +* - - - - - - +* P R E C L +* - - - - - - +* +* Form the matrix of precession between two epochs, using the +* model of Simon et al (1994), which is suitable for long +* periods of time. +* +* (double precision) +* +* Given: +* EP0 dp beginning epoch +* EP1 dp ending epoch +* +* Returned: +* RMATP dp(3,3) precession matrix +* +* Notes: +* +* 1) The epochs are TDB Julian epochs. +* +* 2) The matrix is in the sense V(EP1) = RMATP * V(EP0) +* +* 3) The absolute accuracy of the model is limited by the +* uncertainty in the general precession, about 0.3 arcsec per +* 1000 years. The remainder of the formulation provides a +* precision of 1 mas over the interval from 1000AD to 3000AD, +* 0.1 arcsec from 1000BC to 5000AD and 1 arcsec from +* 4000BC to 8000AD. +* +* Reference: +* Simon, J.L. et al., 1994. Astron.Astrophys., 282, 663-683. +* +* Called: sla_DEULER +* +* P.T.Wallace Starlink 23 August 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION EP0,EP1,RMATP(3,3) + +* Arc seconds to radians + DOUBLE PRECISION AS2R + PARAMETER (AS2R=0.484813681109535994D-5) + + DOUBLE PRECISION T0,T,TAS2R,W,ZETA,Z,THETA + + + +* Interval between basic epoch J2000.0 and beginning epoch (1000JY) + T0 = (EP0-2000D0)/1000D0 + +* Interval over which precession required (1000JY) + T = (EP1-EP0)/1000D0 + +* Euler angles + TAS2R = T*AS2R + W = 23060.9097D0+ + : (139.7459D0+ + : (-0.0038D0+ + : (-0.5918D0+ + : (-0.0037D0+ + : 0.0007D0*T0)*T0)*T0)*T0)*T0 + + ZETA = (W+(30.2226D0+ + : (-0.2523D0+ + : (-0.3840D0+ + : (-0.0014D0+ + : 0.0007D0*T0)*T0)*T0)*T0+ + : (18.0183D0+ + : (-0.1326D0+ + : (0.0006D0+ + : 0.0005D0*T0)*T0)*T0+ + : (-0.0583D0+ + : (-0.0001D0+ + : 0.0007D0*T0)*T0+ + : (-0.0285D0+ + : (-0.0002D0)*T)*T)*T)*T)*T)*TAS2R + + Z = (W+(109.5270D0+ + : (0.2446D0+ + : (-1.3913D0+ + : (-0.0134D0+ + : 0.0026D0*T0)*T0)*T0)*T0+ + : (18.2667D0+ + : (-1.1400D0+ + : (-0.0173D0+ + : 0.0044D0*T0)*T0)*T0+ + : (-0.2821D0+ + : (-0.0093D0+ + : 0.0032D0*T0)*T0+ + : (-0.0301D0+ + : 0.0006D0*T0 + : -0.0001D0*T)*T)*T)*T)*T)*TAS2R + + THETA = (20042.0207D0+ + : (-85.3131D0+ + : (-0.2111D0+ + : (0.3642D0+ + : (0.0008D0+ + : (-0.0005D0)*T0)*T0)*T0)*T0)*T0+ + : (-42.6566D0+ + : (-0.2111D0+ + : (0.5463D0+ + : (0.0017D0+ + : (-0.0012D0)*T0)*T0)*T0)*T0+ + : (-41.8238D0+ + : (0.0359D0+ + : (0.0027D0+ + : (-0.0001D0)*T0)*T0)*T0+ + : (-0.0731D0+ + : (0.0019D0+ + : 0.0009D0*T0)*T0+ + : (-0.0127D0+ + : 0.0011D0*T0+0.0004D0*T)*T)*T)*T)*T)*TAS2R + +* Rotation matrix + CALL sla_DEULER('ZYZ',-ZETA,THETA,-Z,RMATP) + + END diff --git a/src/slalib/prenut.f b/src/slalib/prenut.f new file mode 100644 index 0000000..96d6bdc --- /dev/null +++ b/src/slalib/prenut.f @@ -0,0 +1,48 @@ + SUBROUTINE sla_PRENUT (EPOCH, DATE, RMATPN) +*+ +* - - - - - - - +* P R E N U T +* - - - - - - - +* +* Form the matrix of precession and nutation (IAU1976/FK5) +* (double precision) +* +* Given: +* EPOCH dp Julian Epoch for mean coordinates +* DATE dp Modified Julian Date (JD-2400000.5) +* for true coordinates +* +* Returned: +* RMATPN dp(3,3) combined precession/nutation matrix +* +* Called: sla_PREC, sla_EPJ, sla_NUT, sla_DMXM +* +* Notes: +* +* 1) The epoch and date are TDB (loosely ET). +* +* 2) The matrix is in the sense V(true) = RMATPN * V(mean) +* +* P.T.Wallace Starlink April 1987 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION EPOCH,DATE,RMATPN(3,3) + + DOUBLE PRECISION RMATP(3,3),RMATN(3,3),sla_EPJ + + + +* Precession + CALL sla_PREC(EPOCH,sla_EPJ(DATE),RMATP) + +* Nutation + CALL sla_NUT(DATE,RMATN) + +* Combine the matrices: PN = N x P + CALL sla_DMXM(RMATN,RMATP,RMATPN) + + END diff --git a/src/slalib/put.com b/src/slalib/put.com new file mode 100755 index 0000000..fc42fe8 --- /dev/null +++ b/src/slalib/put.com @@ -0,0 +1,38 @@ +$! +$! - - - - +$! P U T +$! - - - - +$! +$! Update one SLALIB routine from Fortran source +$! +$! DCL command is @PUT file +$! +$! The default directory must be the one containing the +$! Fortran source, with the libraries in [.RELEASE]. +$! +$! P T Wallace Starlink 22 January 1993 +$! +$! Save supplied file name and strip recognized extensions +$ FILE=''P1'' +$ P1=P1-".FOR"-".VAX" +$! +$! No action required for TEST program + IF P1.EQS."TEST" THEN $ GOTO DONE +$! +$! If platform-specific module, make .FOR file ... +$ IF F$SEARCH("''P1'.VAX").NES."" THEN $ COPY 'P1'.VAX *.FOR +$! +$! Update the source library +$ LIBR/REPL/TEXT [.RELEASE]SLALIB.TLB 'P1'.FOR +$! +$! Compile, update object library, delete object +$ FORTRAN/NOLIST 'P1'.FOR +$ LIBR/REPL [.RELEASE]SLALIB.OLB 'P1'.OBJ +$ DELETE 'P1'.OBJ;* +$! +$! If module just updated was platform-specific, delete the .FOR version +$ IF F$SEARCH("''P1'.VAX",1).NES."" THEN $ DELETE 'P1'.FOR;* +$! +$! Finished +$DONE: +$ EXIT diff --git a/src/slalib/pv2el.f b/src/slalib/pv2el.f new file mode 100644 index 0000000..e45ad64 --- /dev/null +++ b/src/slalib/pv2el.f @@ -0,0 +1,351 @@ + SUBROUTINE sla_PV2EL (PV, DATE, PMASS, JFORMR, + : JFORM, EPOCH, ORBINC, ANODE, PERIH, + : AORQ, E, AORL, DM, JSTAT) +*+ +* - - - - - - +* P V 2 E L +* - - - - - - +* +* Heliocentric osculating elements obtained from instantaneous position +* and velocity. +* +* Given: +* PV d(6) heliocentric x,y,z,xdot,ydot,zdot of date, +* J2000 equatorial triad (AU,AU/s; Note 1) +* DATE d date (TT Modified Julian Date = JD-2400000.5) +* PMASS d mass of the planet (Sun=1; Note 2) +* JFORMR i requested element set (1-3; Note 3) +* +* Returned: +* JFORM d element set actually returned (1-3; Note 4) +* EPOCH d epoch of elements (TT MJD) +* ORBINC d inclination (radians) +* ANODE d longitude of the ascending node (radians) +* PERIH d longitude or argument of perihelion (radians) +* AORQ d mean distance or perihelion distance (AU) +* E d eccentricity +* AORL d mean anomaly or longitude (radians, JFORM=1,2 only) +* DM d daily motion (radians, JFORM=1 only) +* JSTAT i status: 0 = OK +* -1 = illegal PMASS +* -2 = illegal JFORMR +* -3 = position/velocity out of range +* +* Notes +* +* 1 The PV 6-vector is with respect to the mean equator and equinox of +* epoch J2000. The orbital elements produced are with respect to +* the J2000 ecliptic and mean equinox. +* +* 2 The mass, PMASS, is important only for the larger planets. For +* most purposes (e.g. asteroids) use 0D0. Values less than zero +* are illegal. +* +* 3 Three different element-format options are supported: +* +* Option JFORM=1, suitable for the major planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = longitude of perihelion, curly pi (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e +* AORL = mean longitude L (radians) +* DM = daily motion (radians) +* +* Option JFORM=2, suitable for minor planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e +* AORL = mean anomaly M (radians) +* +* Option JFORM=3, suitable for comets: +* +* EPOCH = epoch of perihelion (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = perihelion distance, q (AU) +* E = eccentricity, e +* +* 4 It may not be possible to generate elements in the form +* requested through JFORMR. The caller is notified of the form +* of elements actually returned by means of the JFORM argument: +* +* JFORMR JFORM meaning +* +* 1 1 OK - elements are in the requested format +* 1 2 never happens +* 1 3 orbit not elliptical +* +* 2 1 never happens +* 2 2 OK - elements are in the requested format +* 2 3 orbit not elliptical +* +* 3 1 never happens +* 3 2 never happens +* 3 3 OK - elements are in the requested format +* +* 5 The arguments returned for each value of JFORM (cf Note 5: JFORM +* may not be the same as JFORMR) are as follows: +* +* JFORM 1 2 3 +* EPOCH t0 t0 T +* ORBINC i i i +* ANODE Omega Omega Omega +* PERIH curly pi omega omega +* AORQ a a q +* E e e e +* AORL L M - +* DM n - - +* +* where: +* +* t0 is the epoch of the elements (MJD, TT) +* T " epoch of perihelion (MJD, TT) +* i " inclination (radians) +* Omega " longitude of the ascending node (radians) +* curly pi " longitude of perihelion (radians) +* omega " argument of perihelion (radians) +* a " mean distance (AU) +* q " perihelion distance (AU) +* e " eccentricity +* L " longitude (radians, 0-2pi) +* M " mean anomaly (radians, 0-2pi) +* n " daily motion (radians) +* - means no value is set +* +* 6 At very small inclinations, the longitude of the ascending node +* ANODE becomes indeterminate and under some circumstances may be +* set arbitrarily to zero. Similarly, if the orbit is close to +* circular, the true anomaly becomes indeterminate and under some +* circumstances may be set arbitrarily to zero. In such cases, +* the other elements are automatically adjusted to compensate, +* and so the elements remain a valid description of the orbit. +* +* Reference: Sterne, Theodore E., "An Introduction to Celestial +* Mechanics", Interscience Publishers, 1960 +* +* Called: sla_DRANRM +* +* P.T.Wallace Starlink 13 February 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION PV(6),DATE,PMASS + INTEGER JFORMR,JFORM + DOUBLE PRECISION EPOCH,ORBINC,ANODE,PERIH,AORQ,E,AORL,DM + INTEGER JSTAT + +* Seconds to days + DOUBLE PRECISION DAY + PARAMETER (DAY=86400D0) + +* Gaussian gravitational constant (exact) + DOUBLE PRECISION GCON + PARAMETER (GCON=0.01720209895D0) + +* Sin and cos of J2000 mean obliquity (IAU 1976) + DOUBLE PRECISION SE,CE + PARAMETER (SE=0.3977771559319137D0, + : CE=0.9174820620691818D0) + +* Minimum allowed distance (AU) and speed (AU/day) + DOUBLE PRECISION RMIN,VMIN + PARAMETER (RMIN=1D-3,VMIN=1D-8) + +* How close to unity the eccentricity has to be to call it a parabola + DOUBLE PRECISION PARAB + PARAMETER (PARAB=1D-8) + + DOUBLE PRECISION X,Y,Z,XD,YD,ZD,R,V2,V,RDV,GMU,HX,HY,HZ, + : HX2PY2,H2,H,OI,BIGOM,AR,ECC,S,C,AT,U,OM, + : GAR3,EM1,EP1,HAT,SHAT,CHAT,AE,AM,DN,PL, + : EL,Q,TP,THAT,THHF,F + + INTEGER JF + + DOUBLE PRECISION sla_DRANRM + + +* Validate arguments PMASS and JFORMR. + IF (PMASS.LT.0D0) THEN + JSTAT = -1 + GO TO 999 + END IF + IF (JFORMR.LT.1.OR.JFORMR.GT.3) THEN + JSTAT = -2 + GO TO 999 + END IF + +* Provisionally assume the elements will be in the chosen form. + JF = JFORMR + +* Rotate the position from equatorial to ecliptic coordinates. + X = PV(1) + Y = PV(2)*CE+PV(3)*SE + Z = -PV(2)*SE+PV(3)*CE + +* Rotate the velocity similarly, scaling to AU/day. + XD = DAY*PV(4) + YD = DAY*(PV(5)*CE+PV(6)*SE) + ZD = DAY*(-PV(5)*SE+PV(6)*CE) + +* Distance and speed. + R = SQRT(X*X+Y*Y+Z*Z) + V2 = XD*XD+YD*YD+ZD*ZD + V = SQRT(V2) + +* Reject unreasonably small values. + IF (R.LT.RMIN.OR.V.LT.VMIN) THEN + JSTAT = -3 + GO TO 999 + END IF + +* R dot V. + RDV = X*XD+Y*YD+Z*ZD + +* Mu. + GMU = (1D0+PMASS)*GCON*GCON + +* Vector angular momentum per unit reduced mass. + HX = Y*ZD-Z*YD + HY = Z*XD-X*ZD + HZ = X*YD-Y*XD + +* Areal constant. + HX2PY2 = HX*HX+HY*HY + H2 = HX2PY2+HZ*HZ + H = SQRT(H2) + +* Inclination. + OI = ATAN2(SQRT(HX2PY2),HZ) + +* Longitude of ascending node. + IF (HX.NE.0D0.OR.HY.NE.0D0) THEN + BIGOM = ATAN2(HX,-HY) + ELSE + BIGOM=0D0 + END IF + +* Reciprocal of mean distance etc. + AR = 2D0/R-V2/GMU + +* Eccentricity. + ECC = SQRT(MAX(1D0-AR*H2/GMU,0D0)) + +* True anomaly. + S = H*RDV + C = H2-R*GMU + IF (S.NE.0D0.AND.C.NE.0D0) THEN + AT = ATAN2(S,C) + ELSE + AT = 0D0 + END IF + +* Argument of the latitude. + S = SIN(BIGOM) + C = COS(BIGOM) + U = ATAN2((-X*S+Y*C)*COS(OI)+Z*SIN(OI),X*C+Y*S) + +* Argument of perihelion. + OM = U-AT + +* Capture near-parabolic cases. + IF (ABS(ECC-1D0).LT.PARAB) ECC=1D0 + +* Comply with JFORMR = 1 or 2 only if orbit is elliptical. + IF (ECC.GE.1D0) JF=3 + +* Functions. + GAR3 = GMU*AR*AR*AR + EM1 = ECC-1D0 + EP1 = ECC+1D0 + HAT = AT/2D0 + SHAT = SIN(HAT) + CHAT = COS(HAT) + +* Ellipse? + IF (ECC.LT.1D0 ) THEN + +* Eccentric anomaly. + AE = 2D0*ATAN2(SQRT(-EM1)*SHAT,SQRT(EP1)*CHAT) + +* Mean anomaly. + AM = AE-ECC*SIN(AE) + +* Daily motion. + DN = SQRT(GAR3) + END IF + +* "Major planet" element set? + IF (JF.EQ.1) THEN + +* Longitude of perihelion. + PL = BIGOM+OM + +* Longitude at epoch. + EL = PL+AM + END IF + +* "Comet" element set? + IF (JF.EQ.3) THEN + +* Perihelion distance. + Q = H2/(GMU*EP1) + +* Ellipse, parabola, hyperbola? + IF (ECC.LT.1D0) THEN + +* Ellipse: epoch of perihelion. + TP = DATE-AM/DN + ELSE + +* Parabola or hyperbola: evaluate tan ( ( true anomaly ) / 2 ) + THAT = SHAT/CHAT + IF (ECC.EQ.1D0) THEN + +* Parabola: epoch of perihelion. + TP = DATE-THAT*(1D0+THAT*THAT/3D0)*H*H2/(2D0*GMU*GMU) + ELSE + +* Hyperbola: epoch of perihelion. + THHF = SQRT(EM1/EP1)*THAT + F = LOG(1D0+THHF)-LOG(1D0-THHF) + TP = DATE-(ECC*SINH(F)-F)/SQRT(-GAR3) + END IF + END IF + END IF + +* Return the appropriate set of elements. + JFORM = JF + ORBINC = OI + ANODE = sla_DRANRM(BIGOM) + E = ECC + IF (JF.EQ.1) THEN + PERIH = sla_DRANRM(PL) + AORL = sla_DRANRM(EL) + DM = DN + ELSE + PERIH = sla_DRANRM(OM) + IF (JF.EQ.2) AORL = sla_DRANRM(AM) + END IF + IF (JF.NE.3) THEN + EPOCH = DATE + AORQ = 1D0/AR + ELSE + EPOCH = TP + AORQ = Q + END IF + JSTAT = 0 + + 999 CONTINUE + END diff --git a/src/slalib/pv2ue.f b/src/slalib/pv2ue.f new file mode 100644 index 0000000..de141e3 --- /dev/null +++ b/src/slalib/pv2ue.f @@ -0,0 +1,150 @@ + SUBROUTINE sla_PV2UE (PV, DATE, PMASS, U, JSTAT) +*+ +* - - - - - - +* P V 2 U E +* - - - - - - +* +* Construct a universal element set based on an instantaneous position +* and velocity. +* +* Given: +* PV d(6) heliocentric x,y,z,xdot,ydot,zdot of date, +* (AU,AU/s; Note 1) +* DATE d date (TT Modified Julian Date = JD-2400000.5) +* PMASS d mass of the planet (Sun=1; Note 2) +* +* Returned: +* U d(13) universal orbital elements (Note 3) +* +* (1) combined mass (M+m) +* (2) total energy of the orbit (alpha) +* (3) reference (osculating) epoch (t0) +* (4-6) position at reference epoch (r0) +* (7-9) velocity at reference epoch (v0) +* (10) heliocentric distance at reference epoch +* (11) r0.v0 +* (12) date (t) +* (13) universal eccentric anomaly (psi) of date, approx +* +* JSTAT i status: 0 = OK +* -1 = illegal PMASS +* -2 = too close to Sun +* -3 = too slow +* +* Notes +* +* 1 The PV 6-vector can be with respect to any chosen inertial frame, +* and the resulting universal-element set will be with respect to +* the same frame. A common choice will be mean equator and ecliptic +* of epoch J2000. +* +* 2 The mass, PMASS, is important only for the larger planets. For +* most purposes (e.g. asteroids) use 0D0. Values less than zero +* are illegal. +* +* 3 The "universal" elements are those which define the orbit for the +* purposes of the method of universal variables (see reference). +* They consist of the combined mass of the two bodies, an epoch, +* and the position and velocity vectors (arbitrary reference frame) +* at that epoch. The parameter set used here includes also various +* quantities that can, in fact, be derived from the other +* information. This approach is taken to avoiding unnecessary +* computation and loss of accuracy. The supplementary quantities +* are (i) alpha, which is proportional to the total energy of the +* orbit, (ii) the heliocentric distance at epoch, (iii) the +* outwards component of the velocity at the given epoch, (iv) an +* estimate of psi, the "universal eccentric anomaly" at a given +* date and (v) that date. +* +* Reference: Everhart, E. & Pitkin, E.T., Am.J.Phys. 51, 712, 1983. +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION PV(6),DATE,PMASS,U(13) + INTEGER JSTAT + +* Gaussian gravitational constant (exact) + DOUBLE PRECISION GCON + PARAMETER (GCON=0.01720209895D0) + +* Canonical days to seconds + DOUBLE PRECISION CD2S + PARAMETER (CD2S=GCON/86400D0) + +* Minimum allowed distance (AU) and speed (AU per canonical day) + DOUBLE PRECISION RMIN,VMIN + PARAMETER (RMIN=1D-3,VMIN=1D-3) + + DOUBLE PRECISION T0,CM,X,Y,Z,XD,YD,ZD,R,V2,V,ALPHA,RDV + + +* Reference epoch. + T0 = DATE + +* Combined mass (mu=M+m). + IF (PMASS.LT.0D0) GO TO 9010 + CM = 1D0+PMASS + +* Unpack the state vector, expressing velocity in AU per canonical day. + X = PV(1) + Y = PV(2) + Z = PV(3) + XD = PV(4)/CD2S + YD = PV(5)/CD2S + ZD = PV(6)/CD2S + +* Heliocentric distance, and speed. + R = SQRT(X*X+Y*Y+Z*Z) + V2 = XD*XD+YD*YD+ZD*ZD + V = SQRT(V2) + +* Reject unreasonably small values. + IF (R.LT.RMIN) GO TO 9020 + IF (V.LT.VMIN) GO TO 9030 + +* Total energy of the orbit. + ALPHA = V2-2D0*CM/R + +* Outward component of velocity. + RDV = X*XD+Y*YD+Z*ZD + +* Construct the universal-element set. + U(1) = CM + U(2) = ALPHA + U(3) = T0 + U(4) = X + U(5) = Y + U(6) = Z + U(7) = XD + U(8) = YD + U(9) = ZD + U(10) = R + U(11) = RDV + U(12) = T0 + U(13) = 0D0 + +* Exit. + JSTAT = 0 + GO TO 9999 + +* Negative PMASS. + 9010 CONTINUE + JSTAT = -1 + GO TO 9999 + +* Too close. + 9020 CONTINUE + JSTAT = -2 + GO TO 9999 + +* Too slow. + 9030 CONTINUE + JSTAT = -3 + + 9999 CONTINUE + END diff --git a/src/slalib/pvobs.f b/src/slalib/pvobs.f new file mode 100644 index 0000000..116bc06 --- /dev/null +++ b/src/slalib/pvobs.f @@ -0,0 +1,59 @@ + SUBROUTINE sla_PVOBS (P, H, STL, PV) +*+ +* - - - - - - +* P V O B S +* - - - - - - +* +* Position and velocity of an observing station (double precision) +* +* Given: +* P dp latitude (geodetic, radians) +* H dp height above reference spheroid (geodetic, metres) +* STL dp local apparent sidereal time (radians) +* +* Returned: +* PV dp(6) position/velocity 6-vector (AU, AU/s, true equator +* and equinox of date) +* +* Called: sla_GEOC +* +* IAU 1976 constants are used. +* +* P.T.Wallace Starlink 14 November 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION P,H,STL,PV(6) + + DOUBLE PRECISION R,Z,S,C,V + +* Mean sidereal rate (at J2000) in radians per (UT1) second + DOUBLE PRECISION SR + PARAMETER (SR=7.292115855306589D-5) + + + +* Geodetic to geocentric conversion + CALL sla_GEOC(P,H,R,Z) + +* Functions of ST + S=SIN(STL) + C=COS(STL) + +* Speed + V=SR*R + +* Position + PV(1)=R*C + PV(2)=R*S + PV(3)=Z + +* Velocity + PV(4)=-V*S + PV(5)=V*C + PV(6)=0D0 + + END diff --git a/src/slalib/pxy.f b/src/slalib/pxy.f new file mode 100644 index 0000000..3dd880f --- /dev/null +++ b/src/slalib/pxy.f @@ -0,0 +1,92 @@ + SUBROUTINE sla_PXY (NP,XYE,XYM,COEFFS,XYP,XRMS,YRMS,RRMS) +*+ +* - - - - +* P X Y +* - - - - +* +* Given arrays of "expected" and "measured" [X,Y] coordinates, and a +* linear model relating them (as produced by sla_FITXY), compute +* the array of "predicted" coordinates and the RMS residuals. +* +* Given: +* NP i number of samples +* XYE d(2,np) expected [X,Y] for each sample +* XYM d(2,np) measured [X,Y] for each sample +* COEFFS d(6) coefficients of model (see below) +* +* Returned: +* XYP d(2,np) predicted [X,Y] for each sample +* XRMS d RMS in X +* YRMS d RMS in Y +* RRMS d total RMS (vector sum of XRMS and YRMS) +* +* The model is supplied in the array COEFFS. Naming the +* elements of COEFF as follows: +* +* COEFFS(1) = A +* COEFFS(2) = B +* COEFFS(3) = C +* COEFFS(4) = D +* COEFFS(5) = E +* COEFFS(6) = F +* +* the model is applied thus: +* +* XP = A + B*XM + C*YM +* YP = D + E*XM + F*YM +* +* The residuals are (XP-XE) and (YP-YE). +* +* If NP is less than or equal to zero, no coordinates are +* transformed, and the RMS residuals are all zero. +* +* See also sla_FITXY, sla_INVF, sla_XY2XY, sla_DCMPF +* +* Called: sla_XY2XY +* +* P.T.Wallace Starlink 22 May 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER NP + DOUBLE PRECISION XYE(2,NP),XYM(2,NP),COEFFS(6), + : XYP(2,NP),XRMS,YRMS,RRMS + + INTEGER I + DOUBLE PRECISION SDX2,SDY2,XP,YP,DX,DY,DX2,DY2,P + + + +* Initialize summations + SDX2=0D0 + SDY2=0D0 + +* Loop by sample + DO I=1,NP + +* Transform "measured" [X,Y] to "predicted" [X,Y] + CALL sla_XY2XY(XYM(1,I),XYM(2,I),COEFFS,XP,YP) + XYP(1,I)=XP + XYP(2,I)=YP + +* Compute residuals in X and Y, and update summations + DX=XYE(1,I)-XP + DY=XYE(2,I)-YP + DX2=DX*DX + DY2=DY*DY + SDX2=SDX2+DX2 + SDY2=SDY2+DY2 + +* Next sample + END DO + +* Compute RMS values + P=MAX(1D0,DBLE(NP)) + XRMS=SQRT(SDX2/P) + YRMS=SQRT(SDY2/P) + RRMS=SQRT(XRMS*XRMS+YRMS*YRMS) + + END diff --git a/src/slalib/random.f_alpha_OSF1 b/src/slalib/random.f_alpha_OSF1 new file mode 100644 index 0000000..54544e3 --- /dev/null +++ b/src/slalib/random.f_alpha_OSF1 @@ -0,0 +1,56 @@ + REAL FUNCTION sla_RANDOM (SEED) +*+ +* - - - - - - - +* R A N D O M +* - - - - - - - +* +* Generate pseudo-random real number in the range 0 <= X < 1. +* (single precision) +* +* !!! Version for Alpha/OSF1 !!! +* +* Given: +* SEED real an arbitrary real number +* +* Notes: +* +* 1) The result is a pseudo-random REAL number in the range +* 0 <= sla_RANDOM < 1. +* +* 2) SEED is used first time through only. +* +* Called: RANDOM (a REAL function from the DEC Fortran Library) +* +* P.T.Wallace Starlink 14 October 1991 +* Revised for new recommended RTL RANDOM(3f) function. +* B.K.McIlwrath Starlink 12 January 1996 +*- + + IMPLICIT NONE + + REAL SEED + + REAL RANDOM + + REAL AS + INTEGER ISEED + LOGICAL FIRST + SAVE FIRST + DATA FIRST /.TRUE./ + + + +* If first time, turn SEED into a large, odd integer + IF (FIRST) THEN + AS=ABS(SEED)+1.0 + ISEED=NINT(AS/10.0**(NINT(ALOG10(AS))-6)) + IF (MOD(ISEED,2).EQ.0) ISEED=ISEED+1 + FIRST=.FALSE. + ELSE + ISEED = 0 + END IF + +* Next pseudo-random number + sla_RANDOM=RANDOM(ISEED) + + END diff --git a/src/slalib/random.f_convex b/src/slalib/random.f_convex new file mode 100644 index 0000000..336983f --- /dev/null +++ b/src/slalib/random.f_convex @@ -0,0 +1,56 @@ + REAL FUNCTION sla_RANDOM (SEED) +*+ +* - - - - - - - +* R A N D O M +* - - - - - - - +* +* Generate pseudo-random real number in the range 0 <= X < 1. +* (single precision) +* +* !!! Convex dependent !!! +* +* Given: +* SEED real an arbitrary real number +* +* Notes: +* +* 1) The result is a pseudo-random REAL number in the range +* 0 <= sla_RANDOM < 1. +* +* 2) SEED is used first time through only. +* +* Called: RAND (a REAL function from the Convex Fortran Library) +* +* P.T.Wallace Starlink 28 June 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL SEED + + REAL RAND + + REAL AS + INTEGER ISEED + LOGICAL FIRST + SAVE FIRST + DATA FIRST /.TRUE./ + + + +* If first time, turn SEED into a large, odd integer, and start the +* generator + IF (FIRST) THEN + AS=ABS(SEED)+1.0 + ISEED=NINT(AS/10.0**(NINT(ALOG10(AS))-6)) + IF (MOD(ISEED,2).EQ.0) ISEED=ISEED+1 + FIRST=.FALSE. + AS=RAND(ISEED) + END IF + +* Next pseudo-random number + sla_RANDOM=RAND(0) + + END diff --git a/src/slalib/random.f_ix86_Linux b/src/slalib/random.f_ix86_Linux new file mode 100644 index 0000000..acd1047 --- /dev/null +++ b/src/slalib/random.f_ix86_Linux @@ -0,0 +1,54 @@ + REAL FUNCTION sla_RANDOM (SEED) +*+ +* - - - - - - - +* R A N D O M +* - - - - - - - +* +* Generate pseudo-random real number in the range 0 <= X < 1. +* (single precision) +* +* !!! Version for Linux !!! +* +* Given: +* SEED real an arbitrary real number +* +* Notes: +* +* 1) The result is a pseudo-random REAL number in the range +* 0 <= sla_RANDOM < 1. +* +* 2) SEED is used first time through only. +* +* Called: RANDOM (a REAL function compiled by the makefile from rtl_random.c) +* +* B.K.McIlwrath Starlink 12 January 1996 +*- + + IMPLICIT NONE + + REAL SEED + + REAL RANDOM + + REAL AS + INTEGER ISEED + LOGICAL FIRST + SAVE FIRST + DATA FIRST /.TRUE./ + + + +* If first time, turn SEED into a large, odd integer + IF (FIRST) THEN + AS=ABS(SEED)+1.0 + ISEED=NINT(AS/10.0**(NINT(ALOG10(AS))-6)) + IF (MOD(ISEED,2).EQ.0) ISEED=ISEED+1 + FIRST=.FALSE. + ELSE + ISEED = 0 + END IF + +* Next pseudo-random number + sla_RANDOM=RANDOM(ISEED) + + END diff --git a/src/slalib/random.f_mips b/src/slalib/random.f_mips new file mode 100644 index 0000000..b82b1bb --- /dev/null +++ b/src/slalib/random.f_mips @@ -0,0 +1,54 @@ + REAL FUNCTION sla_RANDOM (SEED) +*+ +* - - - - - - - +* R A N D O M +* - - - - - - - +* +* Generate pseudo-random real number in the range 0 <= X < 1. +* (single precision) +* +* !!! Version for VAX/VMS and DECstation !!! +* +* Given: +* SEED real an arbitrary real number +* +* Notes: +* +* 1) The result is a pseudo-random REAL number in the range +* 0 <= sla_RANDOM < 1. +* +* 2) SEED is used first time through only. +* +* Called: RAN (a REAL function from the DEC Fortran Library) +* +* P.T.Wallace Starlink 14 October 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL SEED + + REAL RAN + + REAL AS + INTEGER ISEED + LOGICAL FIRST + SAVE FIRST + DATA FIRST /.TRUE./ + + + +* If first time, turn SEED into a large, odd integer + IF (FIRST) THEN + AS=ABS(SEED)+1.0 + ISEED=NINT(AS/10.0**(NINT(ALOG10(AS))-6)) + IF (MOD(ISEED,2).EQ.0) ISEED=ISEED+1 + FIRST=.FALSE. + END IF + +* Next pseudo-random number + sla_RANDOM=RAN(ISEED) + + END diff --git a/src/slalib/random.f_pcm b/src/slalib/random.f_pcm new file mode 100644 index 0000000..4f96ddb --- /dev/null +++ b/src/slalib/random.f_pcm @@ -0,0 +1,42 @@ + REAL FUNCTION sla_RANDOM (XSEED) +*+ +* - - - - - - - +* R A N D O M +* - - - - - - - +* +* Generate pseudo-random real number in the range 0 <= X < 1. +* +* (single precision) +* +* !!! Microsoft Fortran dependent !!! +* +* Given (but used first time only): +* XSEED real an arbitrary real number +* +* The value returned is a pseudo-random number such that +* 0 <= sla_RANDOM < 1. +* +* Called: RANDOM (Microsoft run-time library) +* +* P.T.Wallace Starlink 28 February 1993 +* +*+ + + IMPLICIT NONE + + REAL XSEED + + REAL X + LOGICAL FIRST + SAVE FIRST + DATA FIRST /.TRUE./ + + + IF (FIRST) THEN + CALL SEED(NINT(MOD(XSEED*1.234E7,32E3))) ! Microsoft Fortran + FIRST=.FALSE. + END IF + CALL RANDOM(X) ! Microsoft Fortran + sla_RANDOM=X + + END diff --git a/src/slalib/random.f_sun4 b/src/slalib/random.f_sun4 new file mode 100644 index 0000000..9f49fb6 --- /dev/null +++ b/src/slalib/random.f_sun4 @@ -0,0 +1,56 @@ + REAL FUNCTION sla_RANDOM (SEED) +*+ +* - - - - - - - +* R A N D O M +* - - - - - - - +* +* Generate pseudo-random real number in the range 0 <= X < 1. +* (single precision) +* +* !!! Sun 4 dependent !!! +* +* Given: +* SEED real an arbitrary real number +* +* Notes: +* +* 1) The result is a pseudo-random REAL number in the range +* 0 <= sla_RANDOM < 1. +* +* 2) SEED is used first time through only. +* +* Called: RAND (a REAL function from the Sun Fortran Library) +* +* P.T.Wallace Starlink 14 October 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL SEED + + REAL RAND + + REAL AS + INTEGER ISEED + LOGICAL FIRST + SAVE FIRST + DATA FIRST /.TRUE./ + + + +* If first time, turn SEED into a large, odd integer, and start the +* generator + IF (FIRST) THEN + AS=ABS(SEED)+1.0 + ISEED=NINT(AS/10.0**(NINT(ALOG10(AS))-6)) + IF (MOD(ISEED,2).EQ.0) ISEED=ISEED+1 + FIRST=.FALSE. + AS=RAND(ISEED) + END IF + +* Next pseudo-random number + sla_RANDOM=RAND(0) + + END diff --git a/src/slalib/random.f_sun4_Solaris b/src/slalib/random.f_sun4_Solaris new file mode 100644 index 0000000..9f49fb6 --- /dev/null +++ b/src/slalib/random.f_sun4_Solaris @@ -0,0 +1,56 @@ + REAL FUNCTION sla_RANDOM (SEED) +*+ +* - - - - - - - +* R A N D O M +* - - - - - - - +* +* Generate pseudo-random real number in the range 0 <= X < 1. +* (single precision) +* +* !!! Sun 4 dependent !!! +* +* Given: +* SEED real an arbitrary real number +* +* Notes: +* +* 1) The result is a pseudo-random REAL number in the range +* 0 <= sla_RANDOM < 1. +* +* 2) SEED is used first time through only. +* +* Called: RAND (a REAL function from the Sun Fortran Library) +* +* P.T.Wallace Starlink 14 October 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL SEED + + REAL RAND + + REAL AS + INTEGER ISEED + LOGICAL FIRST + SAVE FIRST + DATA FIRST /.TRUE./ + + + +* If first time, turn SEED into a large, odd integer, and start the +* generator + IF (FIRST) THEN + AS=ABS(SEED)+1.0 + ISEED=NINT(AS/10.0**(NINT(ALOG10(AS))-6)) + IF (MOD(ISEED,2).EQ.0) ISEED=ISEED+1 + FIRST=.FALSE. + AS=RAND(ISEED) + END IF + +* Next pseudo-random number + sla_RANDOM=RAND(0) + + END diff --git a/src/slalib/random.f_vax b/src/slalib/random.f_vax new file mode 100644 index 0000000..bdf9ffe --- /dev/null +++ b/src/slalib/random.f_vax @@ -0,0 +1,52 @@ + REAL FUNCTION sla_RANDOM (SEED) +*+ +* - - - - - - - +* R A N D O M +* - - - - - - - +* +* Generate pseudo-random real number in the range 0 <= X < 1. +* (single precision) +* +* !!! Version for VAX/VMS and DECstation !!! +* +* Given: +* SEED real an arbitrary real number +* +* Notes: +* +* 1) The result is a pseudo-random REAL number in the range +* 0 <= sla_RANDOM < 1. +* +* 2) SEED is used first time through only. +* +* Called: RAN (a REAL function from the DEC Fortran Library) +* +* P.T.Wallace Starlink 14 October 1991 +*- + + IMPLICIT NONE + + REAL SEED + + REAL RAN + + REAL AS + INTEGER ISEED + LOGICAL FIRST + SAVE FIRST + DATA FIRST /.TRUE./ + + + +* If first time, turn SEED into a large, odd integer + IF (FIRST) THEN + AS=ABS(SEED)+1.0 + ISEED=NINT(AS/10.0**(NINT(ALOG10(AS))-6)) + IF (MOD(ISEED,2).EQ.0) ISEED=ISEED+1 + FIRST=.FALSE. + END IF + +* Next pseudo-random number + sla_RANDOM=RAN(ISEED) + + END diff --git a/src/slalib/random.f_x86_64 b/src/slalib/random.f_x86_64 new file mode 100644 index 0000000..acd1047 --- /dev/null +++ b/src/slalib/random.f_x86_64 @@ -0,0 +1,54 @@ + REAL FUNCTION sla_RANDOM (SEED) +*+ +* - - - - - - - +* R A N D O M +* - - - - - - - +* +* Generate pseudo-random real number in the range 0 <= X < 1. +* (single precision) +* +* !!! Version for Linux !!! +* +* Given: +* SEED real an arbitrary real number +* +* Notes: +* +* 1) The result is a pseudo-random REAL number in the range +* 0 <= sla_RANDOM < 1. +* +* 2) SEED is used first time through only. +* +* Called: RANDOM (a REAL function compiled by the makefile from rtl_random.c) +* +* B.K.McIlwrath Starlink 12 January 1996 +*- + + IMPLICIT NONE + + REAL SEED + + REAL RANDOM + + REAL AS + INTEGER ISEED + LOGICAL FIRST + SAVE FIRST + DATA FIRST /.TRUE./ + + + +* If first time, turn SEED into a large, odd integer + IF (FIRST) THEN + AS=ABS(SEED)+1.0 + ISEED=NINT(AS/10.0**(NINT(ALOG10(AS))-6)) + IF (MOD(ISEED,2).EQ.0) ISEED=ISEED+1 + FIRST=.FALSE. + ELSE + ISEED = 0 + END IF + +* Next pseudo-random number + sla_RANDOM=RANDOM(ISEED) + + END diff --git a/src/slalib/range.f b/src/slalib/range.f new file mode 100644 index 0000000..a3684cb --- /dev/null +++ b/src/slalib/range.f @@ -0,0 +1,33 @@ + REAL FUNCTION sla_RANGE (ANGLE) +*+ +* - - - - - - +* R A N G E +* - - - - - - +* +* Normalize angle into range +/- pi (single precision) +* +* Given: +* ANGLE dp the angle in radians +* +* The result is ANGLE expressed in the +/- pi (single +* precision). +* +* P.T.Wallace Starlink 23 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL ANGLE + + REAL API,A2PI + PARAMETER (API=3.141592653589793238462643) + PARAMETER (A2PI=6.283185307179586476925287) + + + sla_RANGE=MOD(ANGLE,A2PI) + IF (ABS(sla_RANGE).GE.API) + : sla_RANGE=sla_RANGE-SIGN(A2PI,ANGLE) + + END diff --git a/src/slalib/ranorm.f b/src/slalib/ranorm.f new file mode 100644 index 0000000..c2e32a5 --- /dev/null +++ b/src/slalib/ranorm.f @@ -0,0 +1,31 @@ + REAL FUNCTION sla_RANORM (ANGLE) +*+ +* - - - - - - - +* R A N O R M +* - - - - - - - +* +* Normalize angle into range 0-2 pi (single precision) +* +* Given: +* ANGLE dp the angle in radians +* +* The result is ANGLE expressed in the range 0-2 pi (single +* precision). +* +* P.T.Wallace Starlink 23 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL ANGLE + + REAL A2PI + PARAMETER (A2PI=6.283185307179586476925287) + + + sla_RANORM=MOD(ANGLE,A2PI) + IF (sla_RANORM.LT.0.0) sla_RANORM=sla_RANORM+A2PI + + END diff --git a/src/slalib/rcc.f b/src/slalib/rcc.f new file mode 100644 index 0000000..74a8874 --- /dev/null +++ b/src/slalib/rcc.f @@ -0,0 +1,1063 @@ + DOUBLE PRECISION FUNCTION sla_RCC (TDB, UT1, WL, U, V) +*+ +* - - - - +* R C C +* - - - - +* +* Relativistic clock correction: the difference between proper time at +* a point on the surface of the Earth and coordinate time in the Solar +* System barycentric space-time frame of reference. +* +* The proper time is Terrestrial Time TT; the coordinate +* time is an implementation of the Barycentric Dynamical Time TDB. +* +* Given: +* TDB dp coordinate time (MJD: JD-2400000.5) +* UT1 dp universal time (fraction of one day) +* WL dp clock longitude (radians west) +* U dp clock distance from Earth spin axis (km) +* V dp clock distance north of Earth equatorial plane (km) +* +* Returned: +* The clock correction, TDB-TT, in seconds. TDB may be considered +* to be the coordinate time in the Solar System barycentre frame of +* reference, and TT is the proper time given by clocks at mean sea +* level on the Earth. +* +* The result has a main (annual) sinusoidal term of amplitude +* approximately 0.00166 seconds, plus planetary terms up to about +* 20 microseconds, and lunar and diurnal terms up to 2 microseconds. +* The variation arises from the transverse Doppler effect and the +* gravitational red-shift as the observer varies in speed and moves +* through different gravitational potentials. +* +* The argument TDB is, strictly, the barycentric coordinate time; +* however, the terrestrial proper time (TT) can in practice be used. +* +* The geocentric model is that of Fairhead & Bretagnon (1990), in its +* full form. It was supplied by Fairhead (private communication) as a +* FORTRAN subroutine. The original Fairhead routine used explicit +* formulae, in such large numbers that problems were experienced with +* certain compilers (Microsoft Fortran on PC aborted with stack +* overflow, Convex compiled successfully but extremely slowly). The +* present implementation is a complete recoding, with the original +* Fairhead coefficients held in a table. To optimise arithmetic +* precision, the terms are accumulated in reverse order, smallest +* first. A number of other coding changes were made, in order to match +* the calling sequence of previous versions of the present routine, and +* to comply with Starlink programming standards. Under VAX/VMS, the +* numerical results compared with those from the Fairhead form are +* essentially unaffected by the changes, the differences being at the +* 10^-20 sec level. +* +* The topocentric part of the model is from Moyer (1981) and +* Murray (1983). +* +* During the interval 1950-2050, the absolute accuracy is better +* than +/- 3 nanoseconds relative to direct numerical integrations +* using the JPL DE200/LE200 solar system ephemeris. +* +* The IAU definition of TDB is that it must differ from TT only by +* periodic terms. Though practical, this is an imprecise definition +* which ignores the existence of very long-period and secular effects +* in the dynamics of the solar system. As a consequence, different +* implementations of TDB will, in general, differ in zero-point and +* will drift linearly relative to one other. +* +* References: +* Bretagnon P, 1982 Astron. Astrophys., 114, 278-288. +* Fairhead L & Bretagnon P, 1990, Astron. Astrophys., 229, 240-247. +* Meeus J, 1984, l'Astronomie, 348-354. +* Moyer T D, 1981, Cel. Mech., 23, 33. +* Murray C A, 1983, Vectorial Astrometry, Adam Hilger. +* +* P.T.Wallace Starlink 10 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION TDB,UT1,WL,U,V + + DOUBLE PRECISION D2PI + PARAMETER (D2PI=6.283185307179586476925287D0) + + DOUBLE PRECISION T,TSOL,RLE,RGE,RTJ,RTS,RDMOON, + : WT,W0,W1,W2,W3,W4,WF,WJ + +* ----------------------------------------------------------------------- +* +* Fairhead and Bretagnon canonical coefficients +* +* 787 sets of three coefficients. +* +* Each set is amplitude (microseconds) +* frequency (radians per Julian millenium since J2000), +* phase (radians). +* +* Sets 1-474 are the T**0 terms, +* " 475-679 " " T**1 " +* " 680-764 " " T**2 " +* " 765-784 " " T**3 " +* " 785-787 " " T**4 " . +* + DOUBLE PRECISION FAIRHD(3,787) + INTEGER I,J + DATA ((FAIRHD(I,J),I=1,3),J= 1, 10) / + : 1656.674564D-6, 6283.075849991D0, 6.240054195D0, + : 22.417471D-6, 5753.384884897D0, 4.296977442D0, + : 13.839792D-6, 12566.151699983D0, 6.196904410D0, + : 4.770086D-6, 529.690965095D0, 0.444401603D0, + : 4.676740D-6, 6069.776754553D0, 4.021195093D0, + : 2.256707D-6, 213.299095438D0, 5.543113262D0, + : 1.694205D-6, -3.523118349D0, 5.025132748D0, + : 1.554905D-6, 77713.771467920D0, 5.198467090D0, + : 1.276839D-6, 7860.419392439D0, 5.988822341D0, + : 1.193379D-6, 5223.693919802D0, 3.649823730D0 / + DATA ((FAIRHD(I,J),I=1,3),J= 11, 20) / + : 1.115322D-6, 3930.209696220D0, 1.422745069D0, + : 0.794185D-6, 11506.769769794D0, 2.322313077D0, + : 0.447061D-6, 26.298319800D0, 3.615796498D0, + : 0.435206D-6, -398.149003408D0, 4.349338347D0, + : 0.600309D-6, 1577.343542448D0, 2.678271909D0, + : 0.496817D-6, 6208.294251424D0, 5.696701824D0, + : 0.486306D-6, 5884.926846583D0, 0.520007179D0, + : 0.432392D-6, 74.781598567D0, 2.435898309D0, + : 0.468597D-6, 6244.942814354D0, 5.866398759D0, + : 0.375510D-6, 5507.553238667D0, 4.103476804D0 / + DATA ((FAIRHD(I,J),I=1,3),J= 21, 30) / + : 0.243085D-6, -775.522611324D0, 3.651837925D0, + : 0.173435D-6, 18849.227549974D0, 6.153743485D0, + : 0.230685D-6, 5856.477659115D0, 4.773852582D0, + : 0.203747D-6, 12036.460734888D0, 4.333987818D0, + : 0.143935D-6, -796.298006816D0, 5.957517795D0, + : 0.159080D-6, 10977.078804699D0, 1.890075226D0, + : 0.119979D-6, 38.133035638D0, 4.551585768D0, + : 0.118971D-6, 5486.777843175D0, 1.914547226D0, + : 0.116120D-6, 1059.381930189D0, 0.873504123D0, + : 0.137927D-6, 11790.629088659D0, 1.135934669D0 / + DATA ((FAIRHD(I,J),I=1,3),J= 31, 40) / + : 0.098358D-6, 2544.314419883D0, 0.092793886D0, + : 0.101868D-6, -5573.142801634D0, 5.984503847D0, + : 0.080164D-6, 206.185548437D0, 2.095377709D0, + : 0.079645D-6, 4694.002954708D0, 2.949233637D0, + : 0.062617D-6, 20.775395492D0, 2.654394814D0, + : 0.075019D-6, 2942.463423292D0, 4.980931759D0, + : 0.064397D-6, 5746.271337896D0, 1.280308748D0, + : 0.063814D-6, 5760.498431898D0, 4.167901731D0, + : 0.048042D-6, 2146.165416475D0, 1.495846011D0, + : 0.048373D-6, 155.420399434D0, 2.251573730D0 / + DATA ((FAIRHD(I,J),I=1,3),J= 41, 50) / + : 0.058844D-6, 426.598190876D0, 4.839650148D0, + : 0.046551D-6, -0.980321068D0, 0.921573539D0, + : 0.054139D-6, 17260.154654690D0, 3.411091093D0, + : 0.042411D-6, 6275.962302991D0, 2.869567043D0, + : 0.040184D-6, -7.113547001D0, 3.565975565D0, + : 0.036564D-6, 5088.628839767D0, 3.324679049D0, + : 0.040759D-6, 12352.852604545D0, 3.981496998D0, + : 0.036507D-6, 801.820931124D0, 6.248866009D0, + : 0.036955D-6, 3154.687084896D0, 5.071801441D0, + : 0.042732D-6, 632.783739313D0, 5.720622217D0 / + DATA ((FAIRHD(I,J),I=1,3),J= 51, 60) / + : 0.042560D-6, 161000.685737473D0, 1.270837679D0, + : 0.040480D-6, 15720.838784878D0, 2.546610123D0, + : 0.028244D-6, -6286.598968340D0, 5.069663519D0, + : 0.033477D-6, 6062.663207553D0, 4.144987272D0, + : 0.034867D-6, 522.577418094D0, 5.210064075D0, + : 0.032438D-6, 6076.890301554D0, 0.749317412D0, + : 0.030215D-6, 7084.896781115D0, 3.389610345D0, + : 0.029247D-6, -71430.695617928D0, 4.183178762D0, + : 0.033529D-6, 9437.762934887D0, 2.404714239D0, + : 0.032423D-6, 8827.390269875D0, 5.541473556D0 / + DATA ((FAIRHD(I,J),I=1,3),J= 61, 70) / + : 0.027567D-6, 6279.552731642D0, 5.040846034D0, + : 0.029862D-6, 12139.553509107D0, 1.770181024D0, + : 0.022509D-6, 10447.387839604D0, 1.460726241D0, + : 0.020937D-6, 8429.241266467D0, 0.652303414D0, + : 0.020322D-6, 419.484643875D0, 3.735430632D0, + : 0.024816D-6, -1194.447010225D0, 1.087136918D0, + : 0.025196D-6, 1748.016413067D0, 2.901883301D0, + : 0.021691D-6, 14143.495242431D0, 5.952658009D0, + : 0.017673D-6, 6812.766815086D0, 3.186129845D0, + : 0.022567D-6, 6133.512652857D0, 3.307984806D0 / + DATA ((FAIRHD(I,J),I=1,3),J= 71, 80) / + : 0.016155D-6, 10213.285546211D0, 1.331103168D0, + : 0.014751D-6, 1349.867409659D0, 4.308933301D0, + : 0.015949D-6, -220.412642439D0, 4.005298270D0, + : 0.015974D-6, -2352.866153772D0, 6.145309371D0, + : 0.014223D-6, 17789.845619785D0, 2.104551349D0, + : 0.017806D-6, 73.297125859D0, 3.475975097D0, + : 0.013671D-6, -536.804512095D0, 5.971672571D0, + : 0.011942D-6, 8031.092263058D0, 2.053414715D0, + : 0.014318D-6, 16730.463689596D0, 3.016058075D0, + : 0.012462D-6, 103.092774219D0, 1.737438797D0 / + DATA ((FAIRHD(I,J),I=1,3),J= 81, 90) / + : 0.010962D-6, 3.590428652D0, 2.196567739D0, + : 0.015078D-6, 19651.048481098D0, 3.969480770D0, + : 0.010396D-6, 951.718406251D0, 5.717799605D0, + : 0.011707D-6, -4705.732307544D0, 2.654125618D0, + : 0.010453D-6, 5863.591206116D0, 1.913704550D0, + : 0.012420D-6, 4690.479836359D0, 4.734090399D0, + : 0.011847D-6, 5643.178563677D0, 5.489005403D0, + : 0.008610D-6, 3340.612426700D0, 3.661698944D0, + : 0.011622D-6, 5120.601145584D0, 4.863931876D0, + : 0.010825D-6, 553.569402842D0, 0.842715011D0 / + DATA ((FAIRHD(I,J),I=1,3),J= 91,100) / + : 0.008666D-6, -135.065080035D0, 3.293406547D0, + : 0.009963D-6, 149.563197135D0, 4.870690598D0, + : 0.009858D-6, 6309.374169791D0, 1.061816410D0, + : 0.007959D-6, 316.391869657D0, 2.465042647D0, + : 0.010099D-6, 283.859318865D0, 1.942176992D0, + : 0.007147D-6, -242.728603974D0, 3.661486981D0, + : 0.007505D-6, 5230.807466803D0, 4.920937029D0, + : 0.008323D-6, 11769.853693166D0, 1.229392026D0, + : 0.007490D-6, -6256.777530192D0, 3.658444681D0, + : 0.009370D-6, 149854.400134205D0, 0.673880395D0 / + DATA ((FAIRHD(I,J),I=1,3),J=101,110) / + : 0.007117D-6, 38.027672636D0, 5.294249518D0, + : 0.007857D-6, 12168.002696575D0, 0.525733528D0, + : 0.007019D-6, 6206.809778716D0, 0.837688810D0, + : 0.006056D-6, 955.599741609D0, 4.194535082D0, + : 0.008107D-6, 13367.972631107D0, 3.793235253D0, + : 0.006731D-6, 5650.292110678D0, 5.639906583D0, + : 0.007332D-6, 36.648562930D0, 0.114858677D0, + : 0.006366D-6, 4164.311989613D0, 2.262081818D0, + : 0.006858D-6, 5216.580372801D0, 0.642063318D0, + : 0.006919D-6, 6681.224853400D0, 6.018501522D0 / + DATA ((FAIRHD(I,J),I=1,3),J=111,120) / + : 0.006826D-6, 7632.943259650D0, 3.458654112D0, + : 0.005308D-6, -1592.596013633D0, 2.500382359D0, + : 0.005096D-6, 11371.704689758D0, 2.547107806D0, + : 0.004841D-6, 5333.900241022D0, 0.437078094D0, + : 0.005582D-6, 5966.683980335D0, 2.246174308D0, + : 0.006304D-6, 11926.254413669D0, 2.512929171D0, + : 0.006603D-6, 23581.258177318D0, 5.393136889D0, + : 0.005123D-6, -1.484472708D0, 2.999641028D0, + : 0.004648D-6, 1589.072895284D0, 1.275847090D0, + : 0.005119D-6, 6438.496249426D0, 1.486539246D0 / + DATA ((FAIRHD(I,J),I=1,3),J=121,130) / + : 0.004521D-6, 4292.330832950D0, 6.140635794D0, + : 0.005680D-6, 23013.539539587D0, 4.557814849D0, + : 0.005488D-6, -3.455808046D0, 0.090675389D0, + : 0.004193D-6, 7234.794256242D0, 4.869091389D0, + : 0.003742D-6, 7238.675591600D0, 4.691976180D0, + : 0.004148D-6, -110.206321219D0, 3.016173439D0, + : 0.004553D-6, 11499.656222793D0, 5.554998314D0, + : 0.004892D-6, 5436.993015240D0, 1.475415597D0, + : 0.004044D-6, 4732.030627343D0, 1.398784824D0, + : 0.004164D-6, 12491.370101415D0, 5.650931916D0 / + DATA ((FAIRHD(I,J),I=1,3),J=131,140) / + : 0.004349D-6, 11513.883316794D0, 2.181745369D0, + : 0.003919D-6, 12528.018664345D0, 5.823319737D0, + : 0.003129D-6, 6836.645252834D0, 0.003844094D0, + : 0.004080D-6, -7058.598461315D0, 3.690360123D0, + : 0.003270D-6, 76.266071276D0, 1.517189902D0, + : 0.002954D-6, 6283.143160294D0, 4.447203799D0, + : 0.002872D-6, 28.449187468D0, 1.158692983D0, + : 0.002881D-6, 735.876513532D0, 0.349250250D0, + : 0.003279D-6, 5849.364112115D0, 4.893384368D0, + : 0.003625D-6, 6209.778724132D0, 1.473760578D0 / + DATA ((FAIRHD(I,J),I=1,3),J=141,150) / + : 0.003074D-6, 949.175608970D0, 5.185878737D0, + : 0.002775D-6, 9917.696874510D0, 1.030026325D0, + : 0.002646D-6, 10973.555686350D0, 3.918259169D0, + : 0.002575D-6, 25132.303399966D0, 6.109659023D0, + : 0.003500D-6, 263.083923373D0, 1.892100742D0, + : 0.002740D-6, 18319.536584880D0, 4.320519510D0, + : 0.002464D-6, 202.253395174D0, 4.698203059D0, + : 0.002409D-6, 2.542797281D0, 5.325009315D0, + : 0.003354D-6, -90955.551694697D0, 1.942656623D0, + : 0.002296D-6, 6496.374945429D0, 5.061810696D0 / + DATA ((FAIRHD(I,J),I=1,3),J=151,160) / + : 0.003002D-6, 6172.869528772D0, 2.797822767D0, + : 0.003202D-6, 27511.467873537D0, 0.531673101D0, + : 0.002954D-6, -6283.008539689D0, 4.533471191D0, + : 0.002353D-6, 639.897286314D0, 3.734548088D0, + : 0.002401D-6, 16200.772724501D0, 2.605547070D0, + : 0.003053D-6, 233141.314403759D0, 3.029030662D0, + : 0.003024D-6, 83286.914269554D0, 2.355556099D0, + : 0.002863D-6, 17298.182327326D0, 5.240963796D0, + : 0.002103D-6, -7079.373856808D0, 5.756641637D0, + : 0.002303D-6, 83996.847317911D0, 2.013686814D0 / + DATA ((FAIRHD(I,J),I=1,3),J=161,170) / + : 0.002303D-6, 18073.704938650D0, 1.089100410D0, + : 0.002381D-6, 63.735898303D0, 0.759188178D0, + : 0.002493D-6, 6386.168624210D0, 0.645026535D0, + : 0.002366D-6, 3.932153263D0, 6.215885448D0, + : 0.002169D-6, 11015.106477335D0, 4.845297676D0, + : 0.002397D-6, 6243.458341645D0, 3.809290043D0, + : 0.002183D-6, 1162.474704408D0, 6.179611691D0, + : 0.002353D-6, 6246.427287062D0, 4.781719760D0, + : 0.002199D-6, -245.831646229D0, 5.956152284D0, + : 0.001729D-6, 3894.181829542D0, 1.264976635D0 / + DATA ((FAIRHD(I,J),I=1,3),J=171,180) / + : 0.001896D-6, -3128.388765096D0, 4.914231596D0, + : 0.002085D-6, 35.164090221D0, 1.405158503D0, + : 0.002024D-6, 14712.317116458D0, 2.752035928D0, + : 0.001737D-6, 6290.189396992D0, 5.280820144D0, + : 0.002229D-6, 491.557929457D0, 1.571007057D0, + : 0.001602D-6, 14314.168113050D0, 4.203664806D0, + : 0.002186D-6, 454.909366527D0, 1.402101526D0, + : 0.001897D-6, 22483.848574493D0, 4.167932508D0, + : 0.001825D-6, -3738.761430108D0, 0.545828785D0, + : 0.001894D-6, 1052.268383188D0, 5.817167450D0 / + DATA ((FAIRHD(I,J),I=1,3),J=181,190) / + : 0.001421D-6, 20.355319399D0, 2.419886601D0, + : 0.001408D-6, 10984.192351700D0, 2.732084787D0, + : 0.001847D-6, 10873.986030480D0, 2.903477885D0, + : 0.001391D-6, -8635.942003763D0, 0.593891500D0, + : 0.001388D-6, -7.046236698D0, 1.166145902D0, + : 0.001810D-6, -88860.057071188D0, 0.487355242D0, + : 0.001288D-6, -1990.745017041D0, 3.913022880D0, + : 0.001297D-6, 23543.230504682D0, 3.063805171D0, + : 0.001335D-6, -266.607041722D0, 3.995764039D0, + : 0.001376D-6, 10969.965257698D0, 5.152914309D0 / + DATA ((FAIRHD(I,J),I=1,3),J=191,200) / + : 0.001745D-6, 244287.600007027D0, 3.626395673D0, + : 0.001649D-6, 31441.677569757D0, 1.952049260D0, + : 0.001416D-6, 9225.539273283D0, 4.996408389D0, + : 0.001238D-6, 4804.209275927D0, 5.503379738D0, + : 0.001472D-6, 4590.910180489D0, 4.164913291D0, + : 0.001169D-6, 6040.347246017D0, 5.841719038D0, + : 0.001039D-6, 5540.085789459D0, 2.769753519D0, + : 0.001004D-6, -170.672870619D0, 0.755008103D0, + : 0.001284D-6, 10575.406682942D0, 5.306538209D0, + : 0.001278D-6, 71.812653151D0, 4.713486491D0 / + DATA ((FAIRHD(I,J),I=1,3),J=201,210) / + : 0.001321D-6, 18209.330263660D0, 2.624866359D0, + : 0.001297D-6, 21228.392023546D0, 0.382603541D0, + : 0.000954D-6, 6282.095528923D0, 0.882213514D0, + : 0.001145D-6, 6058.731054289D0, 1.169483931D0, + : 0.000979D-6, 5547.199336460D0, 5.448375984D0, + : 0.000987D-6, -6262.300454499D0, 2.656486959D0, + : 0.001070D-6, -154717.609887482D0, 1.827624012D0, + : 0.000991D-6, 4701.116501708D0, 4.387001801D0, + : 0.001155D-6, -14.227094002D0, 3.042700750D0, + : 0.001176D-6, 277.034993741D0, 3.335519004D0 / + DATA ((FAIRHD(I,J),I=1,3),J=211,220) / + : 0.000890D-6, 13916.019109642D0, 5.601498297D0, + : 0.000884D-6, -1551.045222648D0, 1.088831705D0, + : 0.000876D-6, 5017.508371365D0, 3.969902609D0, + : 0.000806D-6, 15110.466119866D0, 5.142876744D0, + : 0.000773D-6, -4136.910433516D0, 0.022067765D0, + : 0.001077D-6, 175.166059800D0, 1.844913056D0, + : 0.000954D-6, -6284.056171060D0, 0.968480906D0, + : 0.000737D-6, 5326.786694021D0, 4.923831588D0, + : 0.000845D-6, -433.711737877D0, 4.749245231D0, + : 0.000819D-6, 8662.240323563D0, 5.991247817D0 / + DATA ((FAIRHD(I,J),I=1,3),J=221,230) / + : 0.000852D-6, 199.072001436D0, 2.189604979D0, + : 0.000723D-6, 17256.631536341D0, 6.068719637D0, + : 0.000940D-6, 6037.244203762D0, 6.197428148D0, + : 0.000885D-6, 11712.955318231D0, 3.280414875D0, + : 0.000706D-6, 12559.038152982D0, 2.824848947D0, + : 0.000732D-6, 2379.164473572D0, 2.501813417D0, + : 0.000764D-6, -6127.655450557D0, 2.236346329D0, + : 0.000908D-6, 131.541961686D0, 2.521257490D0, + : 0.000907D-6, 35371.887265976D0, 3.370195967D0, + : 0.000673D-6, 1066.495477190D0, 3.876512374D0 / + DATA ((FAIRHD(I,J),I=1,3),J=231,240) / + : 0.000814D-6, 17654.780539750D0, 4.627122566D0, + : 0.000630D-6, 36.027866677D0, 0.156368499D0, + : 0.000798D-6, 515.463871093D0, 5.151962502D0, + : 0.000798D-6, 148.078724426D0, 5.909225055D0, + : 0.000806D-6, 309.278322656D0, 6.054064447D0, + : 0.000607D-6, -39.617508346D0, 2.839021623D0, + : 0.000601D-6, 412.371096874D0, 3.984225404D0, + : 0.000646D-6, 11403.676995575D0, 3.852959484D0, + : 0.000704D-6, 13521.751441591D0, 2.300991267D0, + : 0.000603D-6, -65147.619767937D0, 4.140083146D0 / + DATA ((FAIRHD(I,J),I=1,3),J=241,250) / + : 0.000609D-6, 10177.257679534D0, 0.437122327D0, + : 0.000631D-6, 5767.611978898D0, 4.026532329D0, + : 0.000576D-6, 11087.285125918D0, 4.760293101D0, + : 0.000674D-6, 14945.316173554D0, 6.270510511D0, + : 0.000726D-6, 5429.879468239D0, 6.039606892D0, + : 0.000710D-6, 28766.924424484D0, 5.672617711D0, + : 0.000647D-6, 11856.218651625D0, 3.397132627D0, + : 0.000678D-6, -5481.254918868D0, 6.249666675D0, + : 0.000618D-6, 22003.914634870D0, 2.466427018D0, + : 0.000738D-6, 6134.997125565D0, 2.242668890D0 / + DATA ((FAIRHD(I,J),I=1,3),J=251,260) / + : 0.000660D-6, 625.670192312D0, 5.864091907D0, + : 0.000694D-6, 3496.032826134D0, 2.668309141D0, + : 0.000531D-6, 6489.261398429D0, 1.681888780D0, + : 0.000611D-6, -143571.324284214D0, 2.424978312D0, + : 0.000575D-6, 12043.574281889D0, 4.216492400D0, + : 0.000553D-6, 12416.588502848D0, 4.772158039D0, + : 0.000689D-6, 4686.889407707D0, 6.224271088D0, + : 0.000495D-6, 7342.457780181D0, 3.817285811D0, + : 0.000567D-6, 3634.621024518D0, 1.649264690D0, + : 0.000515D-6, 18635.928454536D0, 3.945345892D0 / + DATA ((FAIRHD(I,J),I=1,3),J=261,270) / + : 0.000486D-6, -323.505416657D0, 4.061673868D0, + : 0.000662D-6, 25158.601719765D0, 1.794058369D0, + : 0.000509D-6, 846.082834751D0, 3.053874588D0, + : 0.000472D-6, -12569.674818332D0, 5.112133338D0, + : 0.000461D-6, 6179.983075773D0, 0.513669325D0, + : 0.000641D-6, 83467.156352816D0, 3.210727723D0, + : 0.000520D-6, 10344.295065386D0, 2.445597761D0, + : 0.000493D-6, 18422.629359098D0, 1.676939306D0, + : 0.000478D-6, 1265.567478626D0, 5.487314569D0, + : 0.000472D-6, -18.159247265D0, 1.999707589D0 / + DATA ((FAIRHD(I,J),I=1,3),J=271,280) / + : 0.000559D-6, 11190.377900137D0, 5.783236356D0, + : 0.000494D-6, 9623.688276691D0, 3.022645053D0, + : 0.000463D-6, 5739.157790895D0, 1.411223013D0, + : 0.000432D-6, 16858.482532933D0, 1.179256434D0, + : 0.000574D-6, 72140.628666286D0, 1.758191830D0, + : 0.000484D-6, 17267.268201691D0, 3.290589143D0, + : 0.000550D-6, 4907.302050146D0, 0.864024298D0, + : 0.000399D-6, 14.977853527D0, 2.094441910D0, + : 0.000491D-6, 224.344795702D0, 0.878372791D0, + : 0.000432D-6, 20426.571092422D0, 6.003829241D0 / + DATA ((FAIRHD(I,J),I=1,3),J=281,290) / + : 0.000481D-6, 5749.452731634D0, 4.309591964D0, + : 0.000480D-6, 5757.317038160D0, 1.142348571D0, + : 0.000485D-6, 6702.560493867D0, 0.210580917D0, + : 0.000426D-6, 6055.549660552D0, 4.274476529D0, + : 0.000480D-6, 5959.570433334D0, 5.031351030D0, + : 0.000466D-6, 12562.628581634D0, 4.959581597D0, + : 0.000520D-6, 39302.096962196D0, 4.788002889D0, + : 0.000458D-6, 12132.439962106D0, 1.880103788D0, + : 0.000470D-6, 12029.347187887D0, 1.405611197D0, + : 0.000416D-6, -7477.522860216D0, 1.082356330D0 / + DATA ((FAIRHD(I,J),I=1,3),J=291,300) / + : 0.000449D-6, 11609.862544012D0, 4.179989585D0, + : 0.000465D-6, 17253.041107690D0, 0.353496295D0, + : 0.000362D-6, -4535.059436924D0, 1.583849576D0, + : 0.000383D-6, 21954.157609398D0, 3.747376371D0, + : 0.000389D-6, 17.252277143D0, 1.395753179D0, + : 0.000331D-6, 18052.929543158D0, 0.566790582D0, + : 0.000430D-6, 13517.870106233D0, 0.685827538D0, + : 0.000368D-6, -5756.908003246D0, 0.731374317D0, + : 0.000330D-6, 10557.594160824D0, 3.710043680D0, + : 0.000332D-6, 20199.094959633D0, 1.652901407D0 / + DATA ((FAIRHD(I,J),I=1,3),J=301,310) / + : 0.000384D-6, 11933.367960670D0, 5.827781531D0, + : 0.000387D-6, 10454.501386605D0, 2.541182564D0, + : 0.000325D-6, 15671.081759407D0, 2.178850542D0, + : 0.000318D-6, 138.517496871D0, 2.253253037D0, + : 0.000305D-6, 9388.005909415D0, 0.578340206D0, + : 0.000352D-6, 5749.861766548D0, 3.000297967D0, + : 0.000311D-6, 6915.859589305D0, 1.693574249D0, + : 0.000297D-6, 24072.921469776D0, 1.997249392D0, + : 0.000363D-6, -640.877607382D0, 5.071820966D0, + : 0.000323D-6, 12592.450019783D0, 1.072262823D0 / + DATA ((FAIRHD(I,J),I=1,3),J=311,320) / + : 0.000341D-6, 12146.667056108D0, 4.700657997D0, + : 0.000290D-6, 9779.108676125D0, 1.812320441D0, + : 0.000342D-6, 6132.028180148D0, 4.322238614D0, + : 0.000329D-6, 6268.848755990D0, 3.033827743D0, + : 0.000374D-6, 17996.031168222D0, 3.388716544D0, + : 0.000285D-6, -533.214083444D0, 4.687313233D0, + : 0.000338D-6, 6065.844601290D0, 0.877776108D0, + : 0.000276D-6, 24.298513841D0, 0.770299429D0, + : 0.000336D-6, -2388.894020449D0, 5.353796034D0, + : 0.000290D-6, 3097.883822726D0, 4.075291557D0 / + DATA ((FAIRHD(I,J),I=1,3),J=321,330) / + : 0.000318D-6, 709.933048357D0, 5.941207518D0, + : 0.000271D-6, 13095.842665077D0, 3.208912203D0, + : 0.000331D-6, 6073.708907816D0, 4.007881169D0, + : 0.000292D-6, 742.990060533D0, 2.714333592D0, + : 0.000362D-6, 29088.811415985D0, 3.215977013D0, + : 0.000280D-6, 12359.966151546D0, 0.710872502D0, + : 0.000267D-6, 10440.274292604D0, 4.730108488D0, + : 0.000262D-6, 838.969287750D0, 1.327720272D0, + : 0.000250D-6, 16496.361396202D0, 0.898769761D0, + : 0.000325D-6, 20597.243963041D0, 0.180044365D0 / + DATA ((FAIRHD(I,J),I=1,3),J=331,340) / + : 0.000268D-6, 6148.010769956D0, 5.152666276D0, + : 0.000284D-6, 5636.065016677D0, 5.655385808D0, + : 0.000301D-6, 6080.822454817D0, 2.135396205D0, + : 0.000294D-6, -377.373607916D0, 3.708784168D0, + : 0.000236D-6, 2118.763860378D0, 1.733578756D0, + : 0.000234D-6, 5867.523359379D0, 5.575209112D0, + : 0.000268D-6, -226858.238553767D0, 0.069432392D0, + : 0.000265D-6, 167283.761587465D0, 4.369302826D0, + : 0.000280D-6, 28237.233459389D0, 5.304829118D0, + : 0.000292D-6, 12345.739057544D0, 4.096094132D0 / + DATA ((FAIRHD(I,J),I=1,3),J=341,350) / + : 0.000223D-6, 19800.945956225D0, 3.069327406D0, + : 0.000301D-6, 43232.306658416D0, 6.205311188D0, + : 0.000264D-6, 18875.525869774D0, 1.417263408D0, + : 0.000304D-6, -1823.175188677D0, 3.409035232D0, + : 0.000301D-6, 109.945688789D0, 0.510922054D0, + : 0.000260D-6, 813.550283960D0, 2.389438934D0, + : 0.000299D-6, 316428.228673312D0, 5.384595078D0, + : 0.000211D-6, 5756.566278634D0, 3.789392838D0, + : 0.000209D-6, 5750.203491159D0, 1.661943545D0, + : 0.000240D-6, 12489.885628707D0, 5.684549045D0 / + DATA ((FAIRHD(I,J),I=1,3),J=351,360) / + : 0.000216D-6, 6303.851245484D0, 3.862942261D0, + : 0.000203D-6, 1581.959348283D0, 5.549853589D0, + : 0.000200D-6, 5642.198242609D0, 1.016115785D0, + : 0.000197D-6, -70.849445304D0, 4.690702525D0, + : 0.000227D-6, 6287.008003254D0, 2.911891613D0, + : 0.000197D-6, 533.623118358D0, 1.048982898D0, + : 0.000205D-6, -6279.485421340D0, 1.829362730D0, + : 0.000209D-6, -10988.808157535D0, 2.636140084D0, + : 0.000208D-6, -227.526189440D0, 4.127883842D0, + : 0.000191D-6, 415.552490612D0, 4.401165650D0 / + DATA ((FAIRHD(I,J),I=1,3),J=361,370) / + : 0.000190D-6, 29296.615389579D0, 4.175658539D0, + : 0.000264D-6, 66567.485864652D0, 4.601102551D0, + : 0.000256D-6, -3646.350377354D0, 0.506364778D0, + : 0.000188D-6, 13119.721102825D0, 2.032195842D0, + : 0.000185D-6, -209.366942175D0, 4.694756586D0, + : 0.000198D-6, 25934.124331089D0, 3.832703118D0, + : 0.000195D-6, 4061.219215394D0, 3.308463427D0, + : 0.000234D-6, 5113.487598583D0, 1.716090661D0, + : 0.000188D-6, 1478.866574064D0, 5.686865780D0, + : 0.000222D-6, 11823.161639450D0, 1.942386641D0 / + DATA ((FAIRHD(I,J),I=1,3),J=371,380) / + : 0.000181D-6, 10770.893256262D0, 1.999482059D0, + : 0.000171D-6, 6546.159773364D0, 1.182807992D0, + : 0.000206D-6, 70.328180442D0, 5.934076062D0, + : 0.000169D-6, 20995.392966449D0, 2.169080622D0, + : 0.000191D-6, 10660.686935042D0, 5.405515999D0, + : 0.000228D-6, 33019.021112205D0, 4.656985514D0, + : 0.000184D-6, -4933.208440333D0, 3.327476868D0, + : 0.000220D-6, -135.625325010D0, 1.765430262D0, + : 0.000166D-6, 23141.558382925D0, 3.454132746D0, + : 0.000191D-6, 6144.558353121D0, 5.020393445D0 / + DATA ((FAIRHD(I,J),I=1,3),J=381,390) / + : 0.000180D-6, 6084.003848555D0, 0.602182191D0, + : 0.000163D-6, 17782.732072784D0, 4.960593133D0, + : 0.000225D-6, 16460.333529525D0, 2.596451817D0, + : 0.000222D-6, 5905.702242076D0, 3.731990323D0, + : 0.000204D-6, 227.476132789D0, 5.636192701D0, + : 0.000159D-6, 16737.577236597D0, 3.600691544D0, + : 0.000200D-6, 6805.653268085D0, 0.868220961D0, + : 0.000187D-6, 11919.140866668D0, 2.629456641D0, + : 0.000161D-6, 127.471796607D0, 2.862574720D0, + : 0.000205D-6, 6286.666278643D0, 1.742882331D0 / + DATA ((FAIRHD(I,J),I=1,3),J=391,400) / + : 0.000189D-6, 153.778810485D0, 4.812372643D0, + : 0.000168D-6, 16723.350142595D0, 0.027860588D0, + : 0.000149D-6, 11720.068865232D0, 0.659721876D0, + : 0.000189D-6, 5237.921013804D0, 5.245313000D0, + : 0.000143D-6, 6709.674040867D0, 4.317625647D0, + : 0.000146D-6, 4487.817406270D0, 4.815297007D0, + : 0.000144D-6, -664.756045130D0, 5.381366880D0, + : 0.000175D-6, 5127.714692584D0, 4.728443327D0, + : 0.000162D-6, 6254.626662524D0, 1.435132069D0, + : 0.000187D-6, 47162.516354635D0, 1.354371923D0 / + DATA ((FAIRHD(I,J),I=1,3),J=401,410) / + : 0.000146D-6, 11080.171578918D0, 3.369695406D0, + : 0.000180D-6, -348.924420448D0, 2.490902145D0, + : 0.000148D-6, 151.047669843D0, 3.799109588D0, + : 0.000157D-6, 6197.248551160D0, 1.284375887D0, + : 0.000167D-6, 146.594251718D0, 0.759969109D0, + : 0.000133D-6, -5331.357443741D0, 5.409701889D0, + : 0.000154D-6, 95.979227218D0, 3.366890614D0, + : 0.000148D-6, -6418.140930027D0, 3.384104996D0, + : 0.000128D-6, -6525.804453965D0, 3.803419985D0, + : 0.000130D-6, 11293.470674356D0, 0.939039445D0 / + DATA ((FAIRHD(I,J),I=1,3),J=411,420) / + : 0.000152D-6, -5729.506447149D0, 0.734117523D0, + : 0.000138D-6, 210.117701700D0, 2.564216078D0, + : 0.000123D-6, 6066.595360816D0, 4.517099537D0, + : 0.000140D-6, 18451.078546566D0, 0.642049130D0, + : 0.000126D-6, 11300.584221356D0, 3.485280663D0, + : 0.000119D-6, 10027.903195729D0, 3.217431161D0, + : 0.000151D-6, 4274.518310832D0, 4.404359108D0, + : 0.000117D-6, 6072.958148291D0, 0.366324650D0, + : 0.000165D-6, -7668.637425143D0, 4.298212528D0, + : 0.000117D-6, -6245.048177356D0, 5.379518958D0 / + DATA ((FAIRHD(I,J),I=1,3),J=421,430) / + : 0.000130D-6, -5888.449964932D0, 4.527681115D0, + : 0.000121D-6, -543.918059096D0, 6.109429504D0, + : 0.000162D-6, 9683.594581116D0, 5.720092446D0, + : 0.000141D-6, 6219.339951688D0, 0.679068671D0, + : 0.000118D-6, 22743.409379516D0, 4.881123092D0, + : 0.000129D-6, 1692.165669502D0, 0.351407289D0, + : 0.000126D-6, 5657.405657679D0, 5.146592349D0, + : 0.000114D-6, 728.762966531D0, 0.520791814D0, + : 0.000120D-6, 52.596639600D0, 0.948516300D0, + : 0.000115D-6, 65.220371012D0, 3.504914846D0 / + DATA ((FAIRHD(I,J),I=1,3),J=431,440) / + : 0.000126D-6, 5881.403728234D0, 5.577502482D0, + : 0.000158D-6, 163096.180360983D0, 2.957128968D0, + : 0.000134D-6, 12341.806904281D0, 2.598576764D0, + : 0.000151D-6, 16627.370915377D0, 3.985702050D0, + : 0.000109D-6, 1368.660252845D0, 0.014730471D0, + : 0.000131D-6, 6211.263196841D0, 0.085077024D0, + : 0.000146D-6, 5792.741760812D0, 0.708426604D0, + : 0.000146D-6, -77.750543984D0, 3.121576600D0, + : 0.000107D-6, 5341.013788022D0, 0.288231904D0, + : 0.000138D-6, 6281.591377283D0, 2.797450317D0 / + DATA ((FAIRHD(I,J),I=1,3),J=441,450) / + : 0.000113D-6, -6277.552925684D0, 2.788904128D0, + : 0.000115D-6, -525.758811831D0, 5.895222200D0, + : 0.000138D-6, 6016.468808270D0, 6.096188999D0, + : 0.000139D-6, 23539.707386333D0, 2.028195445D0, + : 0.000146D-6, -4176.041342449D0, 4.660008502D0, + : 0.000107D-6, 16062.184526117D0, 4.066520001D0, + : 0.000142D-6, 83783.548222473D0, 2.936315115D0, + : 0.000128D-6, 9380.959672717D0, 3.223844306D0, + : 0.000135D-6, 6205.325306007D0, 1.638054048D0, + : 0.000101D-6, 2699.734819318D0, 5.481603249D0 / + DATA ((FAIRHD(I,J),I=1,3),J=451,460) / + : 0.000104D-6, -568.821874027D0, 2.205734493D0, + : 0.000103D-6, 6321.103522627D0, 2.440421099D0, + : 0.000119D-6, 6321.208885629D0, 2.547496264D0, + : 0.000138D-6, 1975.492545856D0, 2.314608466D0, + : 0.000121D-6, 137.033024162D0, 4.539108237D0, + : 0.000123D-6, 19402.796952817D0, 4.538074405D0, + : 0.000119D-6, 22805.735565994D0, 2.869040566D0, + : 0.000133D-6, 64471.991241142D0, 6.056405489D0, + : 0.000129D-6, -85.827298831D0, 2.540635083D0, + : 0.000131D-6, 13613.804277336D0, 4.005732868D0 / + DATA ((FAIRHD(I,J),I=1,3),J=461,470) / + : 0.000104D-6, 9814.604100291D0, 1.959967212D0, + : 0.000112D-6, 16097.679950283D0, 3.589026260D0, + : 0.000123D-6, 2107.034507542D0, 1.728627253D0, + : 0.000121D-6, 36949.230808424D0, 6.072332087D0, + : 0.000108D-6, -12539.853380183D0, 3.716133846D0, + : 0.000113D-6, -7875.671863624D0, 2.725771122D0, + : 0.000109D-6, 4171.425536614D0, 4.033338079D0, + : 0.000101D-6, 6247.911759770D0, 3.441347021D0, + : 0.000113D-6, 7330.728427345D0, 0.656372122D0, + : 0.000113D-6, 51092.726050855D0, 2.791483066D0 / + DATA ((FAIRHD(I,J),I=1,3),J=471,480) / + : 0.000106D-6, 5621.842923210D0, 1.815323326D0, + : 0.000101D-6, 111.430161497D0, 5.711033677D0, + : 0.000103D-6, 909.818733055D0, 2.812745443D0, + : 0.000101D-6, 1790.642637886D0, 1.965746028D0, + +* T + : 102.156724D-6, 6283.075849991D0, 4.249032005D0, + : 1.706807D-6, 12566.151699983D0, 4.205904248D0, + : 0.269668D-6, 213.299095438D0, 3.400290479D0, + : 0.265919D-6, 529.690965095D0, 5.836047367D0, + : 0.210568D-6, -3.523118349D0, 6.262738348D0, + : 0.077996D-6, 5223.693919802D0, 4.670344204D0 / + DATA ((FAIRHD(I,J),I=1,3),J=481,490) / + : 0.054764D-6, 1577.343542448D0, 4.534800170D0, + : 0.059146D-6, 26.298319800D0, 1.083044735D0, + : 0.034420D-6, -398.149003408D0, 5.980077351D0, + : 0.032088D-6, 18849.227549974D0, 4.162913471D0, + : 0.033595D-6, 5507.553238667D0, 5.980162321D0, + : 0.029198D-6, 5856.477659115D0, 0.623811863D0, + : 0.027764D-6, 155.420399434D0, 3.745318113D0, + : 0.025190D-6, 5746.271337896D0, 2.980330535D0, + : 0.022997D-6, -796.298006816D0, 1.174411803D0, + : 0.024976D-6, 5760.498431898D0, 2.467913690D0 / + DATA ((FAIRHD(I,J),I=1,3),J=491,500) / + : 0.021774D-6, 206.185548437D0, 3.854787540D0, + : 0.017925D-6, -775.522611324D0, 1.092065955D0, + : 0.013794D-6, 426.598190876D0, 2.699831988D0, + : 0.013276D-6, 6062.663207553D0, 5.845801920D0, + : 0.011774D-6, 12036.460734888D0, 2.292832062D0, + : 0.012869D-6, 6076.890301554D0, 5.333425680D0, + : 0.012152D-6, 1059.381930189D0, 6.222874454D0, + : 0.011081D-6, -7.113547001D0, 5.154724984D0, + : 0.010143D-6, 4694.002954708D0, 4.044013795D0, + : 0.009357D-6, 5486.777843175D0, 3.416081409D0 / + DATA ((FAIRHD(I,J),I=1,3),J=501,510) / + : 0.010084D-6, 522.577418094D0, 0.749320262D0, + : 0.008587D-6, 10977.078804699D0, 2.777152598D0, + : 0.008628D-6, 6275.962302991D0, 4.562060226D0, + : 0.008158D-6, -220.412642439D0, 5.806891533D0, + : 0.007746D-6, 2544.314419883D0, 1.603197066D0, + : 0.007670D-6, 2146.165416475D0, 3.000200440D0, + : 0.007098D-6, 74.781598567D0, 0.443725817D0, + : 0.006180D-6, -536.804512095D0, 1.302642751D0, + : 0.005818D-6, 5088.628839767D0, 4.827723531D0, + : 0.004945D-6, -6286.598968340D0, 0.268305170D0 / + DATA ((FAIRHD(I,J),I=1,3),J=511,520) / + : 0.004774D-6, 1349.867409659D0, 5.808636673D0, + : 0.004687D-6, -242.728603974D0, 5.154890570D0, + : 0.006089D-6, 1748.016413067D0, 4.403765209D0, + : 0.005975D-6, -1194.447010225D0, 2.583472591D0, + : 0.004229D-6, 951.718406251D0, 0.931172179D0, + : 0.005264D-6, 553.569402842D0, 2.336107252D0, + : 0.003049D-6, 5643.178563677D0, 1.362634430D0, + : 0.002974D-6, 6812.766815086D0, 1.583012668D0, + : 0.003403D-6, -2352.866153772D0, 2.552189886D0, + : 0.003030D-6, 419.484643875D0, 5.286473844D0 / + DATA ((FAIRHD(I,J),I=1,3),J=521,530) / + : 0.003210D-6, -7.046236698D0, 1.863796539D0, + : 0.003058D-6, 9437.762934887D0, 4.226420633D0, + : 0.002589D-6, 12352.852604545D0, 1.991935820D0, + : 0.002927D-6, 5216.580372801D0, 2.319951253D0, + : 0.002425D-6, 5230.807466803D0, 3.084752833D0, + : 0.002656D-6, 3154.687084896D0, 2.487447866D0, + : 0.002445D-6, 10447.387839604D0, 2.347139160D0, + : 0.002990D-6, 4690.479836359D0, 6.235872050D0, + : 0.002890D-6, 5863.591206116D0, 0.095197563D0, + : 0.002498D-6, 6438.496249426D0, 2.994779800D0 / + DATA ((FAIRHD(I,J),I=1,3),J=531,540) / + : 0.001889D-6, 8031.092263058D0, 3.569003717D0, + : 0.002567D-6, 801.820931124D0, 3.425611498D0, + : 0.001803D-6, -71430.695617928D0, 2.192295512D0, + : 0.001782D-6, 3.932153263D0, 5.180433689D0, + : 0.001694D-6, -4705.732307544D0, 4.641779174D0, + : 0.001704D-6, -1592.596013633D0, 3.997097652D0, + : 0.001735D-6, 5849.364112115D0, 0.417558428D0, + : 0.001643D-6, 8429.241266467D0, 2.180619584D0, + : 0.001680D-6, 38.133035638D0, 4.164529426D0, + : 0.002045D-6, 7084.896781115D0, 0.526323854D0 / + DATA ((FAIRHD(I,J),I=1,3),J=541,550) / + : 0.001458D-6, 4292.330832950D0, 1.356098141D0, + : 0.001437D-6, 20.355319399D0, 3.895439360D0, + : 0.001738D-6, 6279.552731642D0, 0.087484036D0, + : 0.001367D-6, 14143.495242431D0, 3.987576591D0, + : 0.001344D-6, 7234.794256242D0, 0.090454338D0, + : 0.001438D-6, 11499.656222793D0, 0.974387904D0, + : 0.001257D-6, 6836.645252834D0, 1.509069366D0, + : 0.001358D-6, 11513.883316794D0, 0.495572260D0, + : 0.001628D-6, 7632.943259650D0, 4.968445721D0, + : 0.001169D-6, 103.092774219D0, 2.838496795D0 / + DATA ((FAIRHD(I,J),I=1,3),J=551,560) / + : 0.001162D-6, 4164.311989613D0, 3.408387778D0, + : 0.001092D-6, 6069.776754553D0, 3.617942651D0, + : 0.001008D-6, 17789.845619785D0, 0.286350174D0, + : 0.001008D-6, 639.897286314D0, 1.610762073D0, + : 0.000918D-6, 10213.285546211D0, 5.532798067D0, + : 0.001011D-6, -6256.777530192D0, 0.661826484D0, + : 0.000753D-6, 16730.463689596D0, 3.905030235D0, + : 0.000737D-6, 11926.254413669D0, 4.641956361D0, + : 0.000694D-6, 3340.612426700D0, 2.111120332D0, + : 0.000701D-6, 3894.181829542D0, 2.760823491D0 / + DATA ((FAIRHD(I,J),I=1,3),J=561,570) / + : 0.000689D-6, -135.065080035D0, 4.768800780D0, + : 0.000700D-6, 13367.972631107D0, 5.760439898D0, + : 0.000664D-6, 6040.347246017D0, 1.051215840D0, + : 0.000654D-6, 5650.292110678D0, 4.911332503D0, + : 0.000788D-6, 6681.224853400D0, 4.699648011D0, + : 0.000628D-6, 5333.900241022D0, 5.024608847D0, + : 0.000755D-6, -110.206321219D0, 4.370971253D0, + : 0.000628D-6, 6290.189396992D0, 3.660478857D0, + : 0.000635D-6, 25132.303399966D0, 4.121051532D0, + : 0.000534D-6, 5966.683980335D0, 1.173284524D0 / + DATA ((FAIRHD(I,J),I=1,3),J=571,580) / + : 0.000543D-6, -433.711737877D0, 0.345585464D0, + : 0.000517D-6, -1990.745017041D0, 5.414571768D0, + : 0.000504D-6, 5767.611978898D0, 2.328281115D0, + : 0.000485D-6, 5753.384884897D0, 1.685874771D0, + : 0.000463D-6, 7860.419392439D0, 5.297703006D0, + : 0.000604D-6, 515.463871093D0, 0.591998446D0, + : 0.000443D-6, 12168.002696575D0, 4.830881244D0, + : 0.000570D-6, 199.072001436D0, 3.899190272D0, + : 0.000465D-6, 10969.965257698D0, 0.476681802D0, + : 0.000424D-6, -7079.373856808D0, 1.112242763D0 / + DATA ((FAIRHD(I,J),I=1,3),J=581,590) / + : 0.000427D-6, 735.876513532D0, 1.994214480D0, + : 0.000478D-6, -6127.655450557D0, 3.778025483D0, + : 0.000414D-6, 10973.555686350D0, 5.441088327D0, + : 0.000512D-6, 1589.072895284D0, 0.107123853D0, + : 0.000378D-6, 10984.192351700D0, 0.915087231D0, + : 0.000402D-6, 11371.704689758D0, 4.107281715D0, + : 0.000453D-6, 9917.696874510D0, 1.917490952D0, + : 0.000395D-6, 149.563197135D0, 2.763124165D0, + : 0.000371D-6, 5739.157790895D0, 3.112111866D0, + : 0.000350D-6, 11790.629088659D0, 0.440639857D0 / + DATA ((FAIRHD(I,J),I=1,3),J=591,600) / + : 0.000356D-6, 6133.512652857D0, 5.444568842D0, + : 0.000344D-6, 412.371096874D0, 5.676832684D0, + : 0.000383D-6, 955.599741609D0, 5.559734846D0, + : 0.000333D-6, 6496.374945429D0, 0.261537984D0, + : 0.000340D-6, 6055.549660552D0, 5.975534987D0, + : 0.000334D-6, 1066.495477190D0, 2.335063907D0, + : 0.000399D-6, 11506.769769794D0, 5.321230910D0, + : 0.000314D-6, 18319.536584880D0, 2.313312404D0, + : 0.000424D-6, 1052.268383188D0, 1.211961766D0, + : 0.000307D-6, 63.735898303D0, 3.169551388D0 / + DATA ((FAIRHD(I,J),I=1,3),J=601,610) / + : 0.000329D-6, 29.821438149D0, 6.106912080D0, + : 0.000357D-6, 6309.374169791D0, 4.223760346D0, + : 0.000312D-6, -3738.761430108D0, 2.180556645D0, + : 0.000301D-6, 309.278322656D0, 1.499984572D0, + : 0.000268D-6, 12043.574281889D0, 2.447520648D0, + : 0.000257D-6, 12491.370101415D0, 3.662331761D0, + : 0.000290D-6, 625.670192312D0, 1.272834584D0, + : 0.000256D-6, 5429.879468239D0, 1.913426912D0, + : 0.000339D-6, 3496.032826134D0, 4.165930011D0, + : 0.000283D-6, 3930.209696220D0, 4.325565754D0 / + DATA ((FAIRHD(I,J),I=1,3),J=611,620) / + : 0.000241D-6, 12528.018664345D0, 3.832324536D0, + : 0.000304D-6, 4686.889407707D0, 1.612348468D0, + : 0.000259D-6, 16200.772724501D0, 3.470173146D0, + : 0.000238D-6, 12139.553509107D0, 1.147977842D0, + : 0.000236D-6, 6172.869528772D0, 3.776271728D0, + : 0.000296D-6, -7058.598461315D0, 0.460368852D0, + : 0.000306D-6, 10575.406682942D0, 0.554749016D0, + : 0.000251D-6, 17298.182327326D0, 0.834332510D0, + : 0.000290D-6, 4732.030627343D0, 4.759564091D0, + : 0.000261D-6, 5884.926846583D0, 0.298259862D0 / + DATA ((FAIRHD(I,J),I=1,3),J=621,630) / + : 0.000249D-6, 5547.199336460D0, 3.749366406D0, + : 0.000213D-6, 11712.955318231D0, 5.415666119D0, + : 0.000223D-6, 4701.116501708D0, 2.703203558D0, + : 0.000268D-6, -640.877607382D0, 0.283670793D0, + : 0.000209D-6, 5636.065016677D0, 1.238477199D0, + : 0.000193D-6, 10177.257679534D0, 1.943251340D0, + : 0.000182D-6, 6283.143160294D0, 2.456157599D0, + : 0.000184D-6, -227.526189440D0, 5.888038582D0, + : 0.000182D-6, -6283.008539689D0, 0.241332086D0, + : 0.000228D-6, -6284.056171060D0, 2.657323816D0 / + DATA ((FAIRHD(I,J),I=1,3),J=631,640) / + : 0.000166D-6, 7238.675591600D0, 5.930629110D0, + : 0.000167D-6, 3097.883822726D0, 5.570955333D0, + : 0.000159D-6, -323.505416657D0, 5.786670700D0, + : 0.000154D-6, -4136.910433516D0, 1.517805532D0, + : 0.000176D-6, 12029.347187887D0, 3.139266834D0, + : 0.000167D-6, 12132.439962106D0, 3.556352289D0, + : 0.000153D-6, 202.253395174D0, 1.463313961D0, + : 0.000157D-6, 17267.268201691D0, 1.586837396D0, + : 0.000142D-6, 83996.847317911D0, 0.022670115D0, + : 0.000152D-6, 17260.154654690D0, 0.708528947D0 / + DATA ((FAIRHD(I,J),I=1,3),J=641,650) / + : 0.000144D-6, 6084.003848555D0, 5.187075177D0, + : 0.000135D-6, 5756.566278634D0, 1.993229262D0, + : 0.000134D-6, 5750.203491159D0, 3.457197134D0, + : 0.000144D-6, 5326.786694021D0, 6.066193291D0, + : 0.000160D-6, 11015.106477335D0, 1.710431974D0, + : 0.000133D-6, 3634.621024518D0, 2.836451652D0, + : 0.000134D-6, 18073.704938650D0, 5.453106665D0, + : 0.000134D-6, 1162.474704408D0, 5.326898811D0, + : 0.000128D-6, 5642.198242609D0, 2.511652591D0, + : 0.000160D-6, 632.783739313D0, 5.628785365D0 / + DATA ((FAIRHD(I,J),I=1,3),J=651,660) / + : 0.000132D-6, 13916.019109642D0, 0.819294053D0, + : 0.000122D-6, 14314.168113050D0, 5.677408071D0, + : 0.000125D-6, 12359.966151546D0, 5.251984735D0, + : 0.000121D-6, 5749.452731634D0, 2.210924603D0, + : 0.000136D-6, -245.831646229D0, 1.646502367D0, + : 0.000120D-6, 5757.317038160D0, 3.240883049D0, + : 0.000134D-6, 12146.667056108D0, 3.059480037D0, + : 0.000137D-6, 6206.809778716D0, 1.867105418D0, + : 0.000141D-6, 17253.041107690D0, 2.069217456D0, + : 0.000129D-6, -7477.522860216D0, 2.781469314D0 / + DATA ((FAIRHD(I,J),I=1,3),J=661,670) / + : 0.000116D-6, 5540.085789459D0, 4.281176991D0, + : 0.000116D-6, 9779.108676125D0, 3.320925381D0, + : 0.000129D-6, 5237.921013804D0, 3.497704076D0, + : 0.000113D-6, 5959.570433334D0, 0.983210840D0, + : 0.000122D-6, 6282.095528923D0, 2.674938860D0, + : 0.000140D-6, -11.045700264D0, 4.957936982D0, + : 0.000108D-6, 23543.230504682D0, 1.390113589D0, + : 0.000106D-6, -12569.674818332D0, 0.429631317D0, + : 0.000110D-6, -266.607041722D0, 5.501340197D0, + : 0.000115D-6, 12559.038152982D0, 4.691456618D0 / + DATA ((FAIRHD(I,J),I=1,3),J=671,680) / + : 0.000134D-6, -2388.894020449D0, 0.577313584D0, + : 0.000109D-6, 10440.274292604D0, 6.218148717D0, + : 0.000102D-6, -543.918059096D0, 1.477842615D0, + : 0.000108D-6, 21228.392023546D0, 2.237753948D0, + : 0.000101D-6, -4535.059436924D0, 3.100492232D0, + : 0.000103D-6, 76.266071276D0, 5.594294322D0, + : 0.000104D-6, 949.175608970D0, 5.674287810D0, + : 0.000101D-6, 13517.870106233D0, 2.196632348D0, + : 0.000100D-6, 11933.367960670D0, 4.056084160D0, + : 4.322990D-6, 6283.075849991D0, 2.642893748D0 / + DATA ((FAIRHD(I,J),I=1,3),J=681,690) / + : 0.406495D-6, 0.000000000D0, 4.712388980D0, + : 0.122605D-6, 12566.151699983D0, 2.438140634D0, + : 0.019476D-6, 213.299095438D0, 1.642186981D0, + : 0.016916D-6, 529.690965095D0, 4.510959344D0, + : 0.013374D-6, -3.523118349D0, 1.502210314D0, + : 0.008042D-6, 26.298319800D0, 0.478549024D0, + : 0.007824D-6, 155.420399434D0, 5.254710405D0, + : 0.004894D-6, 5746.271337896D0, 4.683210850D0, + : 0.004875D-6, 5760.498431898D0, 0.759507698D0, + : 0.004416D-6, 5223.693919802D0, 6.028853166D0 / + DATA ((FAIRHD(I,J),I=1,3),J=691,700) / + : 0.004088D-6, -7.113547001D0, 0.060926389D0, + : 0.004433D-6, 77713.771467920D0, 3.627734103D0, + : 0.003277D-6, 18849.227549974D0, 2.327912542D0, + : 0.002703D-6, 6062.663207553D0, 1.271941729D0, + : 0.003435D-6, -775.522611324D0, 0.747446224D0, + : 0.002618D-6, 6076.890301554D0, 3.633715689D0, + : 0.003146D-6, 206.185548437D0, 5.647874613D0, + : 0.002544D-6, 1577.343542448D0, 6.232904270D0, + : 0.002218D-6, -220.412642439D0, 1.309509946D0, + : 0.002197D-6, 5856.477659115D0, 2.407212349D0 / + DATA ((FAIRHD(I,J),I=1,3),J=701,710) / + : 0.002897D-6, 5753.384884897D0, 5.863842246D0, + : 0.001766D-6, 426.598190876D0, 0.754113147D0, + : 0.001738D-6, -796.298006816D0, 2.714942671D0, + : 0.001695D-6, 522.577418094D0, 2.629369842D0, + : 0.001584D-6, 5507.553238667D0, 1.341138229D0, + : 0.001503D-6, -242.728603974D0, 0.377699736D0, + : 0.001552D-6, -536.804512095D0, 2.904684667D0, + : 0.001370D-6, -398.149003408D0, 1.265599125D0, + : 0.001889D-6, -5573.142801634D0, 4.413514859D0, + : 0.001722D-6, 6069.776754553D0, 2.445966339D0 / + DATA ((FAIRHD(I,J),I=1,3),J=711,720) / + : 0.001124D-6, 1059.381930189D0, 5.041799657D0, + : 0.001258D-6, 553.569402842D0, 3.849557278D0, + : 0.000831D-6, 951.718406251D0, 2.471094709D0, + : 0.000767D-6, 4694.002954708D0, 5.363125422D0, + : 0.000756D-6, 1349.867409659D0, 1.046195744D0, + : 0.000775D-6, -11.045700264D0, 0.245548001D0, + : 0.000597D-6, 2146.165416475D0, 4.543268798D0, + : 0.000568D-6, 5216.580372801D0, 4.178853144D0, + : 0.000711D-6, 1748.016413067D0, 5.934271972D0, + : 0.000499D-6, 12036.460734888D0, 0.624434410D0 / + DATA ((FAIRHD(I,J),I=1,3),J=721,730) / + : 0.000671D-6, -1194.447010225D0, 4.136047594D0, + : 0.000488D-6, 5849.364112115D0, 2.209679987D0, + : 0.000621D-6, 6438.496249426D0, 4.518860804D0, + : 0.000495D-6, -6286.598968340D0, 1.868201275D0, + : 0.000456D-6, 5230.807466803D0, 1.271231591D0, + : 0.000451D-6, 5088.628839767D0, 0.084060889D0, + : 0.000435D-6, 5643.178563677D0, 3.324456609D0, + : 0.000387D-6, 10977.078804699D0, 4.052488477D0, + : 0.000547D-6, 161000.685737473D0, 2.841633844D0, + : 0.000522D-6, 3154.687084896D0, 2.171979966D0 / + DATA ((FAIRHD(I,J),I=1,3),J=731,740) / + : 0.000375D-6, 5486.777843175D0, 4.983027306D0, + : 0.000421D-6, 5863.591206116D0, 4.546432249D0, + : 0.000439D-6, 7084.896781115D0, 0.522967921D0, + : 0.000309D-6, 2544.314419883D0, 3.172606705D0, + : 0.000347D-6, 4690.479836359D0, 1.479586566D0, + : 0.000317D-6, 801.820931124D0, 3.553088096D0, + : 0.000262D-6, 419.484643875D0, 0.606635550D0, + : 0.000248D-6, 6836.645252834D0, 3.014082064D0, + : 0.000245D-6, -1592.596013633D0, 5.519526220D0, + : 0.000225D-6, 4292.330832950D0, 2.877956536D0 / + DATA ((FAIRHD(I,J),I=1,3),J=741,750) / + : 0.000214D-6, 7234.794256242D0, 1.605227587D0, + : 0.000205D-6, 5767.611978898D0, 0.625804796D0, + : 0.000180D-6, 10447.387839604D0, 3.499954526D0, + : 0.000229D-6, 199.072001436D0, 5.632304604D0, + : 0.000214D-6, 639.897286314D0, 5.960227667D0, + : 0.000175D-6, -433.711737877D0, 2.162417992D0, + : 0.000209D-6, 515.463871093D0, 2.322150893D0, + : 0.000173D-6, 6040.347246017D0, 2.556183691D0, + : 0.000184D-6, 6309.374169791D0, 4.732296790D0, + : 0.000227D-6, 149854.400134205D0, 5.385812217D0 / + DATA ((FAIRHD(I,J),I=1,3),J=751,760) / + : 0.000154D-6, 8031.092263058D0, 5.120720920D0, + : 0.000151D-6, 5739.157790895D0, 4.815000443D0, + : 0.000197D-6, 7632.943259650D0, 0.222827271D0, + : 0.000197D-6, 74.781598567D0, 3.910456770D0, + : 0.000138D-6, 6055.549660552D0, 1.397484253D0, + : 0.000149D-6, -6127.655450557D0, 5.333727496D0, + : 0.000137D-6, 3894.181829542D0, 4.281749907D0, + : 0.000135D-6, 9437.762934887D0, 5.979971885D0, + : 0.000139D-6, -2352.866153772D0, 4.715630782D0, + : 0.000142D-6, 6812.766815086D0, 0.513330157D0 / + DATA ((FAIRHD(I,J),I=1,3),J=761,770) / + : 0.000120D-6, -4705.732307544D0, 0.194160689D0, + : 0.000131D-6, -71430.695617928D0, 0.000379226D0, + : 0.000124D-6, 6279.552731642D0, 2.122264908D0, + : 0.000108D-6, -6256.777530192D0, 0.883445696D0, + : 0.143388D-6, 6283.075849991D0, 1.131453581D0, + : 0.006671D-6, 12566.151699983D0, 0.775148887D0, + : 0.001480D-6, 155.420399434D0, 0.480016880D0, + : 0.000934D-6, 213.299095438D0, 6.144453084D0, + : 0.000795D-6, 529.690965095D0, 2.941595619D0, + : 0.000673D-6, 5746.271337896D0, 0.120415406D0 / + DATA ((FAIRHD(I,J),I=1,3),J=771,780) / + : 0.000672D-6, 5760.498431898D0, 5.317009738D0, + : 0.000389D-6, -220.412642439D0, 3.090323467D0, + : 0.000373D-6, 6062.663207553D0, 3.003551964D0, + : 0.000360D-6, 6076.890301554D0, 1.918913041D0, + : 0.000316D-6, -21.340641002D0, 5.545798121D0, + : 0.000315D-6, -242.728603974D0, 1.884932563D0, + : 0.000278D-6, 206.185548437D0, 1.266254859D0, + : 0.000238D-6, -536.804512095D0, 4.532664830D0, + : 0.000185D-6, 522.577418094D0, 4.578313856D0, + : 0.000245D-6, 18849.227549974D0, 0.587467082D0 / + DATA ((FAIRHD(I,J),I=1,3),J=781,787) / + : 0.000180D-6, 426.598190876D0, 5.151178553D0, + : 0.000200D-6, 553.569402842D0, 5.355983739D0, + : 0.000141D-6, 5223.693919802D0, 1.336556009D0, + : 0.000104D-6, 5856.477659115D0, 4.239842759D0, + : 0.003826D-6, 6283.075849991D0, 5.705257275D0, + : 0.000303D-6, 12566.151699983D0, 5.407132842D0, + : 0.000209D-6, 155.420399434D0, 1.989815753D0 / +* ----------------------------------------------------------------------- + + + +* Time since J2000.0 in Julian millennia + T=(TDB-51544.5D0)/365250D0 + +* -------------------- Topocentric terms ------------------------------- + +* Convert UT1 to local solar time in radians + TSOL = MOD(UT1,1D0)*D2PI - WL + +* Planetary arguments: taken or derived from Bretagnon 1982 + +* RLp = mean longitude, mean equinox of date +* RGp = mean anomaly +* RTp = mean longitude difference, EMB minus planet + +* EMB + RLE = MOD (1.75347031435D0 + 6283.3196666635D0 * T, D2PI) + RGE = MOD (6.24005997418D0 + 6283.0195512850D0 * T, D2PI) +* Jupiter + RTJ = MOD (1.15392381696D0 + 5753.3848591241D0 * T, D2PI) +* Saturn + RTS = MOD (0.87945355785D0 + 6069.7767103654D0 * T, D2PI) + +* Lunar mean elongation: derived from Meeus 1984. + RDMOON = MOD (5.198468D0 + 77713.77144D0 * T, D2PI) + +* Topocentric terms (Moyer 1981 and Murray 1983) + WT = + 0.00029D-10 * U * SIN (TSOL+RTS) + : + 0.00100D-10 * U * SIN (TSOL-2D0*RGE) + : + 0.00133D-10 * U * SIN (TSOL-RDMOON) + : + 0.00133D-10 * U * SIN (TSOL+RTJ) + : - 0.00229D-10 * U * SIN (TSOL+2D0*RLE+RGE) + : - 0.0220 D-10 * V * SIN (RLE+RGE) + : + 0.05312D-10 * U * SIN (TSOL-RGE) + : - 0.13677D-10 * U * SIN (TSOL+2D0*RLE) + : - 1.3184 D-10 * V * COS (RLE) + : + 3.17679D-10 * U * SIN (TSOL) + +* --------------- Fairhead model --------------------------------------- + +* T**0 + W0=0D0 + DO I=474,1,-1 + W0=W0+FAIRHD(1,I)*SIN(FAIRHD(2,I)*T+FAIRHD(3,I)) + END DO + +* T**1 + W1=0D0 + DO I=679,475,-1 + W1=W1+FAIRHD(1,I)*SIN(FAIRHD(2,I)*T+FAIRHD(3,I)) + END DO + +* T**2 + W2=0D0 + DO I=764,680,-1 + W2=W2+FAIRHD(1,I)*SIN(FAIRHD(2,I)*T+FAIRHD(3,I)) + END DO + +* T**3 + W3=0D0 + DO I=784,765,-1 + W3=W3+FAIRHD(1,I)*SIN(FAIRHD(2,I)*T+FAIRHD(3,I)) + END DO + +* T**4 + W4=0D0 + DO I=787,785,-1 + W4=W4+FAIRHD(1,I)*SIN(FAIRHD(2,I)*T+FAIRHD(3,I)) + END DO + +* Multiply by powers of T and combine + WF=T*(T*(T*(T*W4+W3)+W2)+W1)+W0 + +* Adjustments to use JPL planetary masses instead of IAU + WJ= 0.00065D-6 * SIN( 6069.776754D0 *T + 4.021194D0 ) + + : 0.00033D-6 * SIN( 213.299095D0 *T + 5.543132D0 ) + + : (-0.00196D-6 * SIN( 6208.294251D0 *T + 5.696701D0 ))+ + : (-0.00173D-6 * SIN( 74.781599D0 *T + 2.435900D0 ))+ + : 0.03638D-6*T*T + +* ----------------------------------------------------------------------- + +* Final result: TDB-TT in seconds + sla_RCC=WT+WF+WJ + + END diff --git a/src/slalib/rdplan.f b/src/slalib/rdplan.f new file mode 100644 index 0000000..e00ec1d --- /dev/null +++ b/src/slalib/rdplan.f @@ -0,0 +1,183 @@ + SUBROUTINE sla_RDPLAN (DATE, NP, ELONG, PHI, RA, DEC, DIAM) +*+ +* - - - - - - - +* R D P L A N +* - - - - - - - +* +* Approximate topocentric apparent RA,Dec of a planet, and its +* angular diameter. +* +* Given: +* DATE d MJD of observation (JD - 2400000.5) +* NP i planet: 1 = Mercury +* 2 = Venus +* 3 = Moon +* 4 = Mars +* 5 = Jupiter +* 6 = Saturn +* 7 = Uranus +* 8 = Neptune +* 9 = Pluto +* else = Sun +* ELONG,PHI d observer's east longitude and geodetic +* latitude (radians) +* +* Returned: +* RA,DEC d RA, Dec (topocentric apparent, radians) +* DIAM d angular diameter (equatorial, radians) +* +* Notes: +* +* 1 The date is in a dynamical timescale (TDB, formerly ET) and is +* in the form of a Modified Julian Date (JD-2400000.5). For all +* practical purposes, TT can be used instead of TDB, and for many +* applications UT will do (except for the Moon). +* +* 2 The longitude and latitude allow correction for geocentric +* parallax. This is a major effect for the Moon, but in the +* context of the limited accuracy of the present routine its +* effect on planetary positions is small (negligible for the +* outer planets). Geocentric positions can be generated by +* appropriate use of the routines sla_DMOON and sla_PLANET. +* +* 3 The direction accuracy (arcsec, 1000-3000AD) is of order: +* +* Sun 5 +* Mercury 2 +* Venus 10 +* Moon 30 +* Mars 50 +* Jupiter 90 +* Saturn 90 +* Uranus 90 +* Neptune 10 +* Pluto 1 (1885-2099AD only) +* +* The angular diameter accuracy is about 0.4% for the Moon, +* and 0.01% or better for the Sun and planets. +* +* See the sla_PLANET routine for references. +* +* Called: sla_GMST, sla_DT, sla_EPJ, sla_DMOON, sla_PVOBS, sla_PRENUT, +* sla_PLANET, sla_DMXV, sla_DCC2S, sla_DRANRM +* +* P.T.Wallace Starlink 26 May 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE + INTEGER NP + DOUBLE PRECISION ELONG,PHI,RA,DEC,DIAM + +* AU in km + DOUBLE PRECISION AUKM + PARAMETER (AUKM=1.49597870D8) + +* Light time for unit distance (sec) + DOUBLE PRECISION TAU + PARAMETER (TAU=499.004782D0) + + INTEGER IP,J,I + DOUBLE PRECISION EQRAU(0:9),STL,VGM(6),V(6),RMAT(3,3), + : VSE(6),VSG(6),VSP(6),VGO(6),DX,DY,DZ,R,TL + DOUBLE PRECISION sla_GMST,sla_DT,sla_EPJ,sla_DRANRM + +* Equatorial radii (km) + DATA EQRAU / 696000D0,2439.7D0,6051.9D0,1738D0,3397D0,71492D0, + : 60268D0,25559D0,24764D0,1151D0 / + + + +* Classify NP + IP=NP + IF (IP.LT.0.OR.IP.GT.9) IP=0 + +* Approximate local ST + STL=sla_GMST(DATE-sla_DT(sla_EPJ(DATE))/86400D0)+ELONG + +* Geocentre to Moon (mean of date) + CALL sla_DMOON(DATE,V) + +* Nutation to true of date + CALL sla_NUT(DATE,RMAT) + CALL sla_DMXV(RMAT,V,VGM) + CALL sla_DMXV(RMAT,V(4),VGM(4)) + +* Moon? + IF (IP.EQ.3) THEN + +* Yes: geocentre to Moon (true of date) + DO I=1,6 + V(I)=VGM(I) + END DO + ELSE + +* No: precession/nutation matrix, J2000 to date + CALL sla_PRENUT(2000D0,DATE,RMAT) + +* Sun to Earth-Moon Barycentre (J2000) + CALL sla_PLANET(DATE,3,V,J) + +* Precession and nutation to date + CALL sla_DMXV(RMAT,V,VSE) + CALL sla_DMXV(RMAT,V(4),VSE(4)) + +* Sun to geocentre (true of date) + DO I=1,6 + VSG(I)=VSE(I)-0.012150581D0*VGM(I) + END DO + +* Sun? + IF (IP.EQ.0) THEN + +* Yes: geocentre to Sun + DO I=1,6 + V(I)=-VSG(I) + END DO + ELSE + +* No: Sun to Planet (J2000) + CALL sla_PLANET(DATE,IP,V,J) + +* Precession and nutation to date + CALL sla_DMXV(RMAT,V,VSP) + CALL sla_DMXV(RMAT,V(4),VSP(4)) + +* Geocentre to planet + DO I=1,6 + V(I)=VSP(I)-VSG(I) + END DO + END IF + END IF + +* Refer to origin at the observer + CALL sla_PVOBS(PHI,0D0,STL,VGO) + DO I=1,6 + V(I)=V(I)-VGO(I) + END DO + +* Geometric distance (AU) + DX=V(1) + DY=V(2) + DZ=V(3) + R=SQRT(DX*DX+DY*DY+DZ*DZ) + +* Light time (sec) + TL=TAU*R + +* Correct position for planetary aberration + DO I=1,3 + V(I)=V(I)-TL*V(I+3) + END DO + +* To RA,Dec + CALL sla_DCC2S(V,RA,DEC) + RA=sla_DRANRM(RA) + +* Angular diameter (radians) + DIAM=2D0*ASIN(EQRAU(IP)/(R*AUKM)) + + END diff --git a/src/slalib/read.me b/src/slalib/read.me new file mode 100644 index 0000000..bfa92ba --- /dev/null +++ b/src/slalib/read.me @@ -0,0 +1,441 @@ +READ.ME + +Revision date 17 August 1999 SLALIB Version 2.4-0 + +----------------------------------------------------------------------- + +FILES IN THE ORIGINAL SOURCE DIRECTORY (VAX) + + READ.ME this file + *.FOR Fortran source (separate modules) + *.OBS ditto, but obsolete routines + *.NEW ditto, but new and not yet ready for release + *.VAX Fortran source for VAX/VMS + *.CNVX Fortran source for Convex + *.MIPS Fortran source for DECstation + *.SUN4 Fortran source for Sun SPARCstation + *.LNX Fortran source for Linux + *.PCM Microsoft Fortran source for PC + *.C C functions needed for Linux version + PC.BAT rebuilds PC version + REP.BAT on PC, compiles one module and updates library + CREATE.COM complete rebuild of VAX and Unix releases + PUT.COM compile one module and update libraries + VAX_TO_UNIX.USH script to complete transfer to Unix platforms + SLA.NEWS NEWS item for latest release + MAKEFILE Unix make file + MK C-shell script to run make + SUN67.TEX document + +FILES IN [.RELEASE] DIRECTORY ON VAX + + SLALIB.OLB object library + SLALIB.TLB source library + SUN67.TEX document + +FILES IN [.UNIX] DIRECTORY ON VAX + + MAKEFILE make file for DECstation and Sun SPARC + MK C-shell script to run make + SLA.A archive file containing everything else + VAX_TO_UNIX script to complete transfer to Unix platforms + SLA.NEWS NEWS item for latest release + SUN67.TEX document + +FILES IN (INFORMAL) FTP DIRECTORIES + + The files distributed informally through anonymous FTP may differ + slightly in both content and name from the ones listed above. For + example the PC Fortran modules may be stored in archive files and + called xxx.f_pcm rather than XXX.PCM etc. + +----------------------------------------------------------------------- + +DISTRIBUTION - THIS DIRECTORY + + Nothing from this directory needs to be distributed. + +DISTRIBUTION - [.RELEASE] DIRECTORY + + SLALIB.* SLALIB_DIR + SLA.NEWS SLALIB_DIR + SUN67.TEX DOCSDIR + +INSTRUCTIONS FOR SAVING SPACE + + Extract from the SLALIB_DIR BACKUP save set only the file SLALIB.OLB. + +----------------------------------------------------------------------- + +PORTING FORTRAN SLALIB TO OTHER SYSTEMS + +FORTRAN SLALIB runs on VAX (VMS), PC (Linux+f2c), PC (Microsoft FORTRAN), +Convex (ConvexOS), DECstation (Ultrix), DEC Alpha (OSF-1) and Sun +SPARCstation (SunOS and Solaris). + +For most platforms, the required changes are confined to these routines: + + sla_GRESID + sla_RANDOM + sla_WAIT + +VAX, CONVEX, DECSTATION/ALPHA, SUN & PC + +Versions suitable for the above platforms are supplied in the +development directory as *.VAX, *,CNVX, *.MIPS, *.SUN4, *.PCM and +*.LNX respectively. + + +----------------------------------------------------------------------- + +LATEST RELEASE INFORMATION + +The latest release of SLALIB includes the following changes (most recent +at the end): + +* In sla_RCC, the topocentric term of coefficient 1.3184D-10 sec + had the wrong sign. Minus is correct. + +* The IAU decided in 1991 to rename the Terrestrial Dynamical + Time, TDT, which is now called "Terrestrial Time" or TT. + Appropriate changes have been made in the SLALIB documentation. + The same IAU resolutions introduced the timescales TCG and TCB; + there are at present no SLALIB routines to handle these new + timescales. + +* The Keck 1 Telescope has been added to sla_OBS. + +* The handling of the random-number seed in the PC versions of + sla_RANDOM and sla_GRESID was flawed and has been improved. + +* The UTC leap second at the end of June 1993 has been added to the + routine sla_DAT. Existing applications which call sla_DAT or + sla_DTT require relinking. + +* Some unnecessary code in sla_AMPQK has been removed. + +* Minor reorganization of the sla_REFRO code has led to an improvement + in speed of about 20%, and precautions have been taken against + potential arithmetic errors. + +* There have been small revisions to sla_FK425 and sla_FK524. The + results are not significantly affected, except in the pathological + case of large proper motion combined with immense distance, where + sla_FK524 could produce erroneous radial velocity values. The + latest versions are close to the algorithms published in the 1992 + Explanatory Supplement to the Astronomical Almanac. + +* The leap second at the end of June 1994 has been added to sla_DAT. + +* THE SLA_RVLSR ROUTINE HAS BEEN RETIRED. Its place has been taken + by two new routines: sla_RVLSRK and sla_RVLSRD. The original + sla_RVLSR had used a "kinematical" LSR. When this was later changed + to a "dynamical" LSR for (what seemed liked good reasons at the time), + the small differences were noticed by spectral-line radio observers, + who had to fall back on old copies of the routine to remain consistent + with existing practice. The new routines provide both sorts of LSR: + sla_RVLSRK uses a kinematical LSR and sla_RVLSRD uses the dynamical LSR. + +* The sla_PA routine (computation of parallactic angle) used an + unnecessarily complicated formulation, which has been simplified. + The results are unaffected. + +* The sla_ZD routine (computation of zenith distance) used a + straightforward cosine-formula-based method, which suffered from + decreased accuracy near the zenith. A better, vector-derived, + formulation has been substituted, without materially affecting + the results. Because sla_ZD is double precision, the old + formulation was always adequate; however, had anyone transcribed + the code in single precision errors approaching 1 arcmin could + have resulted. The new formulation delivers good results all + over the sky even in a single precision version. + +* Routines have been added to transform equatorial coordinates + (HA,Dec) to horizon coordinates (Az,El) and back. Single and + double precision are both supported. The routines are called + sla_E2H, sla_DE2H, sla_H2E, sla_DH2E. + +* A new routine has been added to the tangent-plane projection set. + The single and double precision versions are called sla_TPRD and + sla_DTPRD respectively. Given the RA,Dec of a star and its + xi,eta coordinates, the routine determines the "plate centre". + +* The existing routine sla_PREC for obtaining the precession matrix + uses the official IAU model and should continue to be used for + canonical purposes. A new version, called sla_PRECL, uses a + more up-to-date model which delivers better accuracy, especially + over intervals of millennia. + +* The routine sla_PVOBS was returning velocities in AU per sidereal + second rather than per UT second. This has been corrected. The + maximum error was equivalent to about 0.001 km/s. + +* In sla_MAPQK and sla_MAPQKZ, the area within which the gravitional + light-deflection term is restrained has been extended from its + original 300 arcsec radius to about 920 arcsec, just inside the + Sun's disc. + +* A chapter of explanation, with examples, has been added to SUN/67, + which has also undergone various cosmetic revisions. + +* There were two discrepancies between the documentation of sla_DCMPF + (program comments and SUN/67) and the code. The first was that the + formulae for the nonperpendicularity used PERP instead of PERP/2; + the documentation has been corrected. The other was that the + documentation showed the zero point corrections being applied first, + whereas the code returned zero point corrections corresponding to + being applied last. The code has been corrected to match the + documentation. + +* The C module slaCldj gave incorrect answers for dates during + January and February. The error, which did not affect the Fortran + version, has been corrected. + +* THE CALLS FOR sla_TPRD AND sla_DTPRD HAS BEEN CHANGED. An integer + status argument has been added; non-zero means the supplied RA,Dec + and Xi,Eta describe an impossible case. (This can only happen + near the pole and with non-zero Xi.) Also, a slightly neater + formulation has been introduced. + +* Three new routines have been added. sla_ALTAZ takes a star's HA,Dec + and produces position, velocity and acceleration for azimuth, + elevation and parallactic angle. sla_PDA2H predicts the HA at which + a given azimuth will be reached. sla_PDQ2H does the same for + position angle. + +* In the sla_OBS routine, the wrong sign was returned for the Perkins + 72 inch telescope at Lowell - fixed. + +* A revised model for the equation of the equinoxes has been + installed in sla_EQEQX, in line with recent IAU resolutions. The + change amounts to less than 3 mas. + +* A bug in sla_DFLTIN has been corrected. A negative number following + an E- or D-format number without intervening spaces lost its sign. + +* Four stations have been added to sla_OBS: + + TAUTENBERG Tautenberg 1.34 metre Schmidt + PALOMAR48 Palomar 48-inch Schmidt + UKST UK 1.2 metre Schmidt, Siding Spring + KISO Kiso 1.05 metre Schmidt, Japan + ESOSCHMIDT ESO 1 metre Schmidt, La Silla + +* The sla_EARTH and sla_MOON routines could give an integer divide by zero + for years before 1 BC. This has been corrected. + +* sla_CALYD (provided to support the sla_EARTH and sla_MOON routines) + has been upgraded to work outside the interval 1900 March 1 to + 2100 February 28. The status value indicating dates outside that + range has been dropped; a new error value for year before -4711 + has been introduced. + +* A new routine, sla_CLYD, has been added. It is a version of sla_CALYD + without the century-default feature and is to enable 1st-century + dates to be supplied to sla_EARTH and sla_MOON. + +* Two new routines, sla_PLANET and sla_RDPLAN, have been added, which + compute approximate planetary ephemerides. + +* A new routine, sla_DMOON, implements the same (Meeus) model as the + sla_MOON routine, but in full and in double precision. The time + argument is a straightforward MJD rather than sla_MOON's year and + day-in-year. + +* The sla_REFRO code has been speeded up by a factor of two (and is + also clearer). + +* sla_REFV and sla_REFZ have, in different ways, been made more accurate + for cases close to the horizon. The improvement to sla_REFV is + relatively modest, but sla_REFZ is now capable of delivering useful + results for rise/set phenomena. + +* sla_AOPQK has been speeded up for low-elevation cases. + +* Versions of the tangent-plane routines working directly in x,y,z + instead of spherical coordinates have been added. They may be + faster in some applications. The routines are sla_DV2TP, sla_V2TP, + sla_DTP2V, sla_TP2V, sla_DTPXYZ, sla_TPXYZ. + +* The coordinates of the Australia Telescope Compact Array have been + added to sla_OBS. The name is 'ATCA'. + +* Despite their recent introduction THE ROUTINES sla_DTPRD, sla_DTPXYZ, + sla_TPRD AND sla_TPXYZ HAVE BEEN WITHDRAWN. They have been replaced + by the new routines sla_DTPS2C, sla_DTPV2C, sla_TPS2C and sla_TPV2C. + These are functionally equivalent to the earlier routines but return + two solutions instead of one: the second solution can arise near a + pole. + +* The UTC leap second at the end of 1995 has been added to sla_DAT. + +* The refraction routine sla_REFRO has been extensively revised. The + principal motivation was to improve the radio predictions by + introducing better humidity models. The models previously in + use had been entirely adequate for the optical case, for which + they had been devised, but improved models were required for + the radio case. None of the changes significantly affects the + optical results with respect to the earlier version of the sla_REFRO + routine. For example, at 70 deg zenith distance the new version + agrees with the old version to better than 0.05 arcsec for any + reasonable combination of parameters. However, the improved + water-vapour expressions do make a significant difference in the + radio band, at 70 deg zenith distance reaching almost 4 arcsec + for a hot, humid, low-altitude site during a period of low pressure. + +* There was a bug in slaRdplan, the (private) C version of sla_RDPLAN. + The answers were unaffected but there could be floating-point + problems on some platforms. + +* A new routine has been added, sla_GMSTA. This gives greater numerical + precision than the existing GMST function by allowing the date and + time to be specified separately rather than as a single MJD. + +* Measures taken in sla_MAPQK to avoid trouble when processing Solar + positions had not been carried through into sla_MAPQKZ. The two + routines now use the same strategy. + +* In sla_REFRO, at zenith distances well beyond 90 deg and under some + conditions, it was possible to encounter arithmetic errors due to + failure of the tropospheric model-atmosphere to deliver sensible + temperatures. This is inherent in the published algorithm. To + avoid the problem, the temperature delivered by the model has been + constrained to the range 200 to 320 deg K. + +* A new routine has been added, sla_ATMDSP, for rapidly recalculating + the A,B refraction coefficients for different wavelengths. + +* The first UTC leap-second date in the sla_DAT routine was one day early. + This will have had no effect on the results for more recent epochs. + +* slaObs, the C version of sla_OBS, had some problems related to character + string handling. A call using the "number" option retured an invalid + station ID, and station ID and name strings of the stipulated 10 + and 40 character lengths were improperly terminated. + +* A new routine, sla_POLMO has been added. This is a specialist tool + to do with Earth polar motion. + +* sla_DC62S and sla_CC62S could give floating point errors if vectors in + unlikely units were supplied. The handling of difficult cases has + been improved. + +* Support for Linux has been added. + +* slaRefreo, the C version of sla_REFRO, was not re-entrant. It is now; + there has been a small (4%) speed penalty. + +* The C routines slaRandom, slaGresid and slaWait have been dropped. + They could not easily be made re-entrant and posed perennial platform- + dependency problems. + +* The value for the arcsec to radians factor in several routines + had an incorrect (and superfluous) 19th digit, which has been + removed. + +* There was a minor bug in sla_DV2TP and sla_V2TP, to do with protection + against the special case where the tangent point is the pole. + +* In sla_OBS, the position of the Parkes radiotelescope has been revised, + and the ATNF Mopra observatory has been added. + +* Two new routines have been added. sla_PAV (single precision) and + sla_DPAV (double precision) are like sla_BEAR and sla_DBEAR but start + with direction cosines rather than spherical coordinates - they return + the position angle of one point with respect to the other. + +* slaRefro, the C version of sla_REFRO, still wasn't re-entrant, but is + now. + +* slaDtf2d, the C version of sla_DTF2D, used to accept 60.0 in the seconds + field; this has been corrected. + +* The sla_PLANET and sla_RDPLAN routines now include Pluto. The ephemeris + is accurate (sub-arcsecond) but covers the 20th and 21st centuries + only. + + !!! IMPORTANT NOTE !!! + + sla_RDPLAN used to interpret any planet number outside the range 1-8 + as meaning the Sun. The new version uses planet number 9. Existing + programs using 9 for the Sun should be changed to use 0. The rule + has not been changed, except that the range is now 1-9 instead of + 1-8, as it is unlikely that the equivalent problem will arise in the + future. + +* Two new routines have been added, sla_PLANEL and sla_PLANTE. They are + analogues of sla_PLANET and sla_RDPLAN but for the case where orbital + elements are available. They can be used for predicting the + positions of asteroids and comets, and, if up-to-date osculating + elements are supplied, more accurate positions for the major + planets than can be provided through the sla_PLANET and sla_RDPLAN + routines. + +* The sla_REFRO routine could give inaccurate results for low temperatures + (subzero C). This was caused by over-cautious defensive programming, + which prevented the tropospheric temperature falling below 200 K. + +* A new routine has been added, sla_REFCOQ. This calculates the coefficients + of a two-term refraction model. It complements the existing sla_REFCO + routine, being much faster at the expense of some accuracy. + +* The 1997 July 1 UTC leap second has been added to the sla_DAT routine. + +* A bug in slaSvd, the C version of sla_SVD, caused occasional false + indications of ill-conditioning. The results of least-squares + fits do not seem to have been affected. The Fortran version did not + have the bug. + +* The Subaru telescope (Japanese National 8-metre telescope, Mauna Kea) + has been added to the sla_OBS routine. + +* The sla_DAT routine has been extended back to the inception of UTC in + 1960. + +* The "earliest date possible" in DJCL sla_was two days out (disagreeing + with sla_DJCAL, which had the correct value). + +* The sla_GMSTA code has been improved. + +* A new routine, sla_PV2EL, takes a heliocentric J2000 equatorial position + and velocity and produces the equivalent set of osculating elements. + +* The 1999 January 1 UTC leap second has been added to the sla_DAT routine. + +* Four new routines have been introduced which transform between the + FK5 system and the ICRS (Hipparcos) system. sla_FK52H and sla_H2FK5 + transform star positions and proper motions from FK5 coordinates to + Hipparcos coordinates and vice versa. sla_FK5HZ and sla_HFK5Z do the + same but for the case where the Hipparcos proper motions are zero. + +* Six new routines have been introduced for dealing with orbital elements. + Four of them (sla_EL2UE, sla_PV2UE, sla_UE2EL and sla_UE2PV) provide + applications with direct access to the "universal variables" method + that was already being used internally. Compared with using conventional + (angular) elements and solving Kepler's equation, the universal variables + approach has a number of advantages, including better handling of near- + parabolic orbits and greater efficiency. The remaining two routines + (sla_PERTEL and sla_PERTUE) generate updated elements by applying + major-planet perturbations. The new elements can then be used to + predict positions that are much more accurate. For minor planets, + sub-arcsecond accuracy over a decade is achievable. + +* Several observatory sites have been added to the OBS routine: CFHT, + Keck 2, Gemini North, FCRAO, IRTF and CSO. The coordinates for all + the Mauna Kea sites have been updated in accordance with recent aerial + photography results made available by the Institute for Astronomy, + University of Hawaii. + +* A bug in sla_DAT has been corrected. It used to give incorrect + results for dates in the first 54 days of 1972. + +* There are new routines for generating permutations (sla_PERMUT) and + combinations (sla_COMBN). + +----------------------------------------------------------------------- + + + P.T.Wallace + + ptw@star.rl.ac.uk + +44-1235-44-5372 diff --git a/src/slalib/refco.f b/src/slalib/refco.f new file mode 100644 index 0000000..3bc8816 --- /dev/null +++ b/src/slalib/refco.f @@ -0,0 +1,70 @@ + SUBROUTINE sla_REFCO (HM, TDK, PMB, RH, WL, PHI, TLR, EPS, + : REFA, REFB) +*+ +* - - - - - - +* R E F C O +* - - - - - - +* +* Determine the constants A and B in the atmospheric refraction +* model dZ = A tan Z + B tan**3 Z. +* +* Z is the "observed" zenith distance (i.e. affected by refraction) +* and dZ is what to add to Z to give the "topocentric" (i.e. in vacuo) +* zenith distance. +* +* Given: +* HM d height of the observer above sea level (metre) +* TDK d ambient temperature at the observer (deg K) +* PMB d pressure at the observer (millibar) +* RH d relative humidity at the observer (range 0-1) +* WL d effective wavelength of the source (micrometre) +* PHI d latitude of the observer (radian, astronomical) +* TLR d temperature lapse rate in the troposphere (degK/metre) +* EPS d precision required to terminate iteration (radian) +* +* Returned: +* REFA d tan Z coefficient (radian) +* REFB d tan**3 Z coefficient (radian) +* +* Called: sla_REFRO +* +* Notes: +* +* 1 Typical values for the TLR and EPS arguments might be 0.0065D0 and +* 1D-10 respectively. +* +* 2 The radio refraction is chosen by specifying WL > 100 micrometres. +* +* 3 The routine is a slower but more accurate alternative to the +* sla_REFCOQ routine. The constants it produces give perfect +* agreement with sla_REFRO at zenith distances arctan(1) (45 deg) +* and arctan(4) (about 76 deg). It achieves 0.5 arcsec accuracy +* for ZD < 80 deg, 0.01 arcsec accuracy for ZD < 60 deg, and +* 0.001 arcsec accuracy for ZD < 45 deg. +* +* P.T.Wallace Starlink 3 June 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION HM,TDK,PMB,RH,WL,PHI,TLR,EPS,REFA,REFB + + DOUBLE PRECISION ATN1,ATN4,R1,R2 + +* Sample zenith distances: arctan(1) and arctan(4) + PARAMETER (ATN1=0.7853981633974483D0, + : ATN4=1.325817663668033D0) + + + +* Determine refraction for the two sample zenith distances + CALL sla_REFRO(ATN1,HM,TDK,PMB,RH,WL,PHI,TLR,EPS,R1) + CALL sla_REFRO(ATN4,HM,TDK,PMB,RH,WL,PHI,TLR,EPS,R2) + +* Solve for refraction constants + REFA = (64D0*R1-R2)/60D0 + REFB = (R2-4D0*R1)/60D0 + + END diff --git a/src/slalib/refcoq.f b/src/slalib/refcoq.f new file mode 100644 index 0000000..15e3af0 --- /dev/null +++ b/src/slalib/refcoq.f @@ -0,0 +1,208 @@ + SUBROUTINE sla_REFCOQ (TDK, PMB, RH, WL, REFA, REFB) +*+ +* - - - - - - - +* R E F C O Q +* - - - - - - - +* +* Determine the constants A and B in the atmospheric refraction +* model dZ = A tan Z + B tan**3 Z. This is a fast alternative +* to the sla_REFCO routine - see notes. +* +* Z is the "observed" zenith distance (i.e. affected by refraction) +* and dZ is what to add to Z to give the "topocentric" (i.e. in vacuo) +* zenith distance. +* +* Given: +* TDK d ambient temperature at the observer (deg K) +* PMB d pressure at the observer (millibar) +* RH d relative humidity at the observer (range 0-1) +* WL d effective wavelength of the source (micrometre) +* +* Returned: +* REFA d tan Z coefficient (radian) +* REFB d tan**3 Z coefficient (radian) +* +* The radio refraction is chosen by specifying WL > 100 micrometres. +* +* Notes: +* +* 1 The model is an approximation, for moderate zenith distances, +* to the predictions of the sla_REFRO routine. The approximation +* is maintained across a range of conditions, and applies to +* both optical/IR and radio. +* +* 2 The algorithm is a fast alternative to the sla_REFCO routine. +* The latter calls the sla_REFRO routine itself: this involves +* integrations through a model atmosphere, and is costly in +* processor time. However, the model which is produced is precisely +* correct for two zenith distance (45 degrees and about 76 degrees) +* and at other zenith distances is limited in accuracy only by the +* A tan Z + B tan**3 Z formulation itself. The present routine +* is not as accurate, though it satisfies most practical +* requirements. +* +* 3 The model omits the effects of (i) height above sea level (apart +* from the reduced pressure itself), (ii) latitude (i.e. the +* flattening of the Earth) and (iii) variations in tropospheric +* lapse rate. +* +* The model was tested using the following range of conditions: +* +* lapse rates 0.0055, 0.0065, 0.0075 deg/metre +* latitudes 0, 25, 50, 75 degrees +* heights 0, 2500, 5000 metres ASL +* pressures mean for height -10% to +5% in steps of 5% +* temperatures -10 deg to +20 deg with respect to 280 deg at SL +* relative humidity 0, 0.5, 1 +* wavelengths 0.4, 0.6, ... 2 micron, + radio +* zenith distances 15, 45, 75 degrees +* +* The accuracy with respect to direct use of the sla_REFRO routine +* was as follows: +* +* worst RMS +* +* optical/IR 62 mas 8 mas +* radio 319 mas 49 mas +* +* For this particular set of conditions: +* +* lapse rate 0.0065 degK/metre +* latitude 50 degrees +* sea level +* pressure 1005 mB +* temperature 280.15 degK +* humidity 80% +* wavelength 5740 Angstroms +* +* the results were as follows: +* +* ZD sla_REFRO sla_REFCOQ Saastamoinen +* +* 10 10.27 10.27 10.27 +* 20 21.19 21.20 21.19 +* 30 33.61 33.61 33.60 +* 40 48.82 48.83 48.81 +* 45 58.16 58.18 58.16 +* 50 69.28 69.30 69.27 +* 55 82.97 82.99 82.95 +* 60 100.51 100.54 100.50 +* 65 124.23 124.26 124.20 +* 70 158.63 158.68 158.61 +* 72 177.32 177.37 177.31 +* 74 200.35 200.38 200.32 +* 76 229.45 229.43 229.42 +* 78 267.44 267.29 267.41 +* 80 319.13 318.55 319.10 +* +* deg arcsec arcsec arcsec +* +* The values for Saastamoinen's formula (which includes terms +* up to tan^5) are taken from Hohenkerk and Sinclair (1985). +* +* The results from the much slower but more accurate sla_REFCO +* routine have not been included in the tabulation as they are +* identical to those in the sla_REFRO column to the 0.01 arcsec +* resolution used. +* +* 4 Outlandish input parameters are silently limited to mathematically +* safe values. Zero pressure is permissible, and causes zeroes to +* be returned. +* +* 5 The algorithm draws on several sources, as follows: +* +* a) The formula for the saturation vapour pressure of water as +* a function of temperature and temperature is taken from +* expressions A4.5-A4.7 of Gill (1982). +* +* b) The formula for the water vapour pressure, given the +* saturation pressure and the relative humidity, is from +* Crane (1976), expression 2.5.5. +* +* c) The refractivity of air is a function of temperature, +* total pressure, water-vapour pressure and, in the case +* of optical/IR but not radio, wavelength. The formulae +* for the two cases are developed from the Essen and Froome +* expressions adopted in Resolution 1 of the 12th International +* Geodesy Association General Assembly (1963). +* +* The above three items are as used in the sla_REFRO routine. +* +* d) The formula for beta, the ratio of the scale height of the +* atmosphere to the geocentric distance of the observer, is +* an adaption of expression 9 from Stone (1996). The +* adaptations, arrived at empirically, consist of (i) a +* small adjustment to the coefficient and (ii) a humidity +* term for the radio case only. +* +* e) The formulae for the refraction constants as a function of +* n-1 and beta are from Green (1987), expression 4.31. +* +* References: +* +* Crane, R.K., Meeks, M.L. (ed), "Refraction Effects in the Neutral +* Atmosphere", Methods of Experimental Physics: Astrophysics 12B, +* Academic Press, 1976. +* +* Gill, Adrian E., "Atmosphere-Ocean Dynamics", Academic Press, 1982. +* +* Hohenkerk, C.Y., & Sinclair, A.T., NAO Technical Note No. 63, 1985. +* +* International Geodesy Association General Assembly, Bulletin +* Geodesique 70 p390, 1963. +* +* Stone, Ronald C., P.A.S.P. 108 1051-1058, 1996. +* +* Green, R.M., "Spherical Astronomy", Cambridge University Press, 1987. +* +* P.T.Wallace Starlink 4 June 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION TDK,PMB,RH,WL,REFA,REFB + + LOGICAL OPTIC + DOUBLE PRECISION T,P,R,W,TDC,PS,PW,WLSQ,GAMMA,BETA + + + +* Decide whether optical/IR or radio case: switch at 100 microns. + OPTIC = WL.LE.100D0 + +* Restrict parameters to safe values. + T = MIN(MAX(TDK,100D0),500D0) + P = MIN(MAX(PMB,0D0),10000D0) + R = MIN(MAX(RH,0D0),1D0) + W = MIN(MAX(WL,0.1D0),1D6) + +* Water vapour pressure at the observer. + IF (P.GT.0D0) THEN + TDC = T-273.15D0 + PS = 10D0**((0.7859D0+0.03477D0*TDC)/(1D0+0.00412D0*TDC))* + : (1D0+P*(4.5D-6+6D-10*TDC*TDC)) + PW = R*PS/(1D0-(1D0-R)*PS/P) + ELSE + PW = 0D0 + END IF + +* Refractive index minus 1 at the observer. + IF (OPTIC) THEN + WLSQ = WL*WL + GAMMA = ((77.532D-6+(4.391D-7+3.57D-9/WLSQ)/WLSQ)*P + : -11.2684D-6*PW)/T + ELSE + GAMMA = (77.624D-6*P-(12.92D-6-0.371897D0/T)*PW)/T + END IF + +* Formula for beta adapted from Stone, with empirical adjustments. + BETA=4.4474D-6*T + IF (.NOT.OPTIC) BETA=BETA-0.0074D0*PW*BETA + +* Refraction constants from Green. + REFA = GAMMA*(1D0-BETA) + REFB = -GAMMA*(BETA-GAMMA/2D0) + + END diff --git a/src/slalib/refro.f b/src/slalib/refro.f new file mode 100644 index 0000000..8d11184 --- /dev/null +++ b/src/slalib/refro.f @@ -0,0 +1,374 @@ + SUBROUTINE sla_REFRO (ZOBS, HM, TDK, PMB, RH, WL, PHI, TLR, + : EPS, REF) +*+ +* - - - - - - +* R E F R O +* - - - - - - +* +* Atmospheric refraction for radio and optical/IR wavelengths. +* +* Given: +* ZOBS d observed zenith distance of the source (radian) +* HM d height of the observer above sea level (metre) +* TDK d ambient temperature at the observer (deg K) +* PMB d pressure at the observer (millibar) +* RH d relative humidity at the observer (range 0-1) +* WL d effective wavelength of the source (micrometre) +* PHI d latitude of the observer (radian, astronomical) +* TLR d temperature lapse rate in the troposphere (degK/metre) +* EPS d precision required to terminate iteration (radian) +* +* Returned: +* REF d refraction: in vacuo ZD minus observed ZD (radian) +* +* Notes: +* +* 1 A suggested value for the TLR argument is 0.0065D0. The +* refraction is significantly affected by TLR, and if studies +* of the local atmosphere have been carried out a better TLR +* value may be available. +* +* 2 A suggested value for the EPS argument is 1D-8. The result is +* usually at least two orders of magnitude more computationally +* precise than the supplied EPS value. +* +* 3 The routine computes the refraction for zenith distances up +* to and a little beyond 90 deg using the method of Hohenkerk +* and Sinclair (NAO Technical Notes 59 and 63, subsequently adopted +* in the Explanatory Supplement, 1992 edition - see section 3.281). +* +* 4 The code is a development of the optical/IR refraction subroutine +* AREF of C.Hohenkerk (HMNAO, September 1984), with extensions to +* support the radio case. Apart from merely cosmetic changes, the +* following modifications to the original HMNAO optical/IR refraction +* code have been made: +* +* . The angle arguments have been changed to radians. +* +* . Any value of ZOBS is allowed (see note 6, below). +* +* . Other argument values have been limited to safe values. +* +* . Murray's values for the gas constants have been used +* (Vectorial Astrometry, Adam Hilger, 1983). +* +* . The numerical integration phase has been rearranged for +* extra clarity. +* +* . A better model for Ps(T) has been adopted (taken from +* Gill, Atmosphere-Ocean Dynamics, Academic Press, 1982). +* +* . More accurate expressions for Pwo have been adopted +* (again from Gill 1982). +* +* . Provision for radio wavelengths has been added using +* expressions devised by A.T.Sinclair, RGO (private +* communication 1989), based on the Essen & Froome +* refractivity formula adopted in Resolution 1 of the +* 13th International Geodesy Association General Assembly +* (Bulletin Geodesique 70 p390, 1963). +* +* . Various small changes have been made to gain speed. +* +* None of the changes significantly affects the optical/IR results +* with respect to the algorithm given in the 1992 Explanatory +* Supplement. For example, at 70 deg zenith distance the present +* routine agrees with the ES algorithm to better than 0.05 arcsec +* for any reasonable combination of parameters. However, the +* improved water-vapour expressions do make a significant difference +* in the radio band, at 70 deg zenith distance reaching almost +* 4 arcsec for a hot, humid, low-altitude site during a period of +* low pressure. +* +* 5 The radio refraction is chosen by specifying WL > 100 micrometres. +* Because the algorithm takes no account of the ionosphere, the +* accuracy deteriorates at low frequencies, below about 30 MHz. +* +* 6 Before use, the value of ZOBS is expressed in the range +/- pi. +* If this ranged ZOBS is -ve, the result REF is computed from its +* absolute value before being made -ve to match. In addition, if +* it has an absolute value greater than 93 deg, a fixed REF value +* equal to the result for ZOBS = 93 deg is returned, appropriately +* signed. +* +* 7 As in the original Hohenkerk and Sinclair algorithm, fixed values +* of the water vapour polytrope exponent, the height of the +* tropopause, and the height at which refraction is negligible are +* used. +* +* 8 The radio refraction has been tested against work done by +* Iain Coulson, JACH, (private communication 1995) for the +* James Clerk Maxwell Telescope, Mauna Kea. For typical conditions, +* agreement at the 0.1 arcsec level is achieved for moderate ZD, +* worsening to perhaps 0.5-1.0 arcsec at ZD 80 deg. At hot and +* humid sea-level sites the accuracy will not be as good. +* +* 9 It should be noted that the relative humidity RH is formally +* defined in terms of "mixing ratio" rather than pressures or +* densities as is often stated. It is the mass of water per unit +* mass of dry air divided by that for saturated air at the same +* temperature and pressure (see Gill 1982). +* +* Called: sla_DRANGE, sla__ATMT, sla__ATMS +* +* P.T.Wallace Starlink 3 June 1997 +* +* Copyright (C) 1997 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION ZOBS,HM,TDK,PMB,RH,WL,PHI,TLR,EPS,REF + +* +* Fixed parameters +* + DOUBLE PRECISION D93,GCR,DMD,DMW,S,DELTA,HT,HS +* 93 degrees in radians + PARAMETER (D93=1.623156204D0) +* Universal gas constant + PARAMETER (GCR=8314.32D0) +* Molecular weight of dry air + PARAMETER (DMD=28.9644D0) +* Molecular weight of water vapour + PARAMETER (DMW=18.0152D0) +* Mean Earth radius (metre) + PARAMETER (S=6378120D0) +* Exponent of temperature dependence of water vapour pressure + PARAMETER (DELTA=18.36D0) +* Height of tropopause (metre) + PARAMETER (HT=11000D0) +* Upper limit for refractive effects (metre) + PARAMETER (HS=80000D0) + + INTEGER IS,K,N,I,J + LOGICAL OPTIC,LOOP + DOUBLE PRECISION ZOBS1,ZOBS2,HMOK,TDKOK,PMBOK,RHOK,WLOK,ALPHA, + : TOL,WLSQ,GB,A,GAMAL,GAMMA,GAMM2,DELM2, + : TDC,PSAT,PWO,W, + : C1,C2,C3,C4,C5,C6,R0,TEMPO,DN0,RDNDR0,SK0,F0, + : RT,TT,DNT,RDNDRT,SINE,ZT,FT,DNTS,RDNDRP,ZTS,FTS, + : RS,DNS,RDNDRS,ZS,FS,REFOLD,Z0,ZRANGE,FB,FF,FO,FE, + : H,R,SZ,RG,DR,TG,DN,RDNDR,T,F,REFP,REFT + + DOUBLE PRECISION sla_DRANGE + +* The refraction integrand + DOUBLE PRECISION REFI + REFI(R,DN,RDNDR) = RDNDR/(DN+RDNDR) + + + +* Transform ZOBS into the normal range. + ZOBS1 = sla_DRANGE(ZOBS) + ZOBS2 = MIN(ABS(ZOBS1),D93) + +* Keep other arguments within safe bounds. + HMOK = MIN(MAX(HM,-1D3),10D3) + TDKOK = MIN(MAX(TDK,100D0),500D0) + PMBOK = MIN(MAX(PMB,0D0),10000D0) + RHOK = MIN(MAX(RH,0D0),1D0) + WLOK = MAX(WL,0.1D0) + ALPHA = MIN(MAX(ABS(TLR),0.001D0),0.01D0) + +* Tolerance for iteration. + TOL = MIN(MAX(ABS(EPS),1D-12),0.1D0)/2D0 + +* Decide whether optical/IR or radio case - switch at 100 microns. + OPTIC = WLOK.LE.100D0 + +* Set up model atmosphere parameters defined at the observer. + WLSQ = WLOK*WLOK + GB = 9.784D0*(1D0-0.0026D0*COS(PHI+PHI)-0.00000028D0*HMOK) + IF (OPTIC) THEN + A = (287.604D0+(1.6288D0+0.0136D0/WLSQ)/WLSQ) + : *273.15D-6/1013.25D0 + ELSE + A = 77.624D-6 + END IF + GAMAL = (GB*DMD)/GCR + GAMMA = GAMAL/ALPHA + GAMM2 = GAMMA-2D0 + DELM2 = DELTA-2D0 + TDC = TDKOK-273.15D0 + PSAT = 10D0**((0.7859D0+0.03477D0*TDC)/(1D0+0.00412D0*TDC))* + : (1D0+PMBOK*(4.5D-6+6D-10*TDC*TDC)) + IF (PMBOK.GT.0D0) THEN + PWO = RHOK*PSAT/(1D0-(1D0-RHOK)*PSAT/PMBOK) + ELSE + PWO = 0D0 + END IF + W = PWO*(1D0-DMW/DMD)*GAMMA/(DELTA-GAMMA) + C1 = A*(PMBOK+W)/TDKOK + IF (OPTIC) THEN + C2 = (A*W+11.2684D-6*PWO)/TDKOK + ELSE + C2 = (A*W+12.92D-6*PWO)/TDKOK + END IF + C3 = (GAMMA-1D0)*ALPHA*C1/TDKOK + C4 = (DELTA-1D0)*ALPHA*C2/TDKOK + IF (OPTIC) THEN + C5 = 0D0 + C6 = 0D0 + ELSE + C5 = 371897D-6*PWO/TDKOK + C6 = C5*DELM2*ALPHA/(TDKOK*TDKOK) + END IF + +* Conditions at the observer. + R0 = S+HMOK + CALL sla__ATMT(R0,TDKOK,ALPHA,GAMM2,DELM2,C1,C2,C3,C4,C5,C6, + : R0,TEMPO,DN0,RDNDR0) + SK0 = DN0*R0*SIN(ZOBS2) + F0 = REFI(R0,DN0,RDNDR0) + +* Conditions in the troposphere at the tropopause. + RT = S+HT + CALL sla__ATMT(R0,TDKOK,ALPHA,GAMM2,DELM2,C1,C2,C3,C4,C5,C6, + : RT,TT,DNT,RDNDRT) + SINE = SK0/(RT*DNT) + ZT = ATAN2(SINE,SQRT(MAX(1D0-SINE*SINE,0D0))) + FT = REFI(RT,DNT,RDNDRT) + +* Conditions in the stratosphere at the tropopause. + CALL sla__ATMS(RT,TT,DNT,GAMAL,RT,DNTS,RDNDRP) + SINE = SK0/(RT*DNTS) + ZTS = ATAN2(SINE,SQRT(MAX(1D0-SINE*SINE,0D0))) + FTS = REFI(RT,DNTS,RDNDRP) + +* Conditions at the stratosphere limit. + RS = S+HS + CALL sla__ATMS(RT,TT,DNT,GAMAL,RS,DNS,RDNDRS) + SINE = SK0/(RS*DNS) + ZS = ATAN2(SINE,SQRT(MAX(1D0-SINE*SINE,0D0))) + FS = REFI(RS,DNS,RDNDRS) + +* +* Integrate the refraction integral in two parts; first in the +* troposphere (K=1), then in the stratosphere (K=2). +* + +* Initialize previous refraction to ensure at least two iterations. + REFOLD = 1D6 + +* Start off with 8 strips for the troposphere integration, and then +* use the final troposphere value for the stratosphere integration, +* which tends to need more strips. + IS = 8 + +* Troposphere then stratosphere. + DO K = 1,2 + +* Start Z, Z range, and start and end values. + IF (K.EQ.1) THEN + Z0 = ZOBS2 + ZRANGE = ZT-Z0 + FB = F0 + FF = FT + ELSE + Z0 = ZTS + ZRANGE = ZS-Z0 + FB = FTS + FF = FS + END IF + +* Sums of odd and even values. + FO = 0D0 + FE = 0D0 + +* First time through the loop we have to do every point. + N = 1 + +* Start of iteration loop (terminates at specified precision). + LOOP = .TRUE. + DO WHILE (LOOP) + +* Strip width. + H = ZRANGE/DBLE(IS) + +* Initialize distance from Earth centre for quadrature pass. + IF (K.EQ.1) THEN + R = R0 + ELSE + R = RT + END IF + +* One pass (no need to compute evens after first time). + DO I=1,IS-1,N + +* Sine of observed zenith distance. + SZ = SIN(Z0+H*DBLE(I)) + +* Find R (to the nearest metre, maximum four iterations). + IF (SZ.GT.1D-20) THEN + W = SK0/SZ + RG = R + DR = 1D6 + J = 0 + DO WHILE (ABS(DR).GT.1D0.AND.J.LT.4) + J=J+1 + IF (K.EQ.1) THEN + CALL sla__ATMT(R0,TDKOK,ALPHA,GAMM2,DELM2, + : C1,C2,C3,C4,C5,C6,RG,TG,DN,RDNDR) + ELSE + CALL sla__ATMS(RT,TT,DNT,GAMAL,RG,DN,RDNDR) + END IF + DR = (RG*DN-W)/(DN+RDNDR) + RG = RG-DR + END DO + R = RG + END IF + +* Find the refractive index and integrand at R. + IF (K.EQ.1) THEN + CALL sla__ATMT(R0,TDKOK,ALPHA,GAMM2,DELM2, + : C1,C2,C3,C4,C5,C6,R,T,DN,RDNDR) + ELSE + CALL sla__ATMS(RT,TT,DNT,GAMAL,R,DN,RDNDR) + END IF + F = REFI(R,DN,RDNDR) + +* Accumulate odd and (first time only) even values. + IF (N.EQ.1.AND.MOD(I,2).EQ.0) THEN + FE = FE+F + ELSE + FO = FO+F + END IF + END DO + +* Evaluate the integrand using Simpson's Rule. + REFP = H*(FB+4D0*FO+2D0*FE+FF)/3D0 + +* Has the required precision been achieved? + IF (ABS(REFP-REFOLD).GT.TOL) THEN + +* No: prepare for next iteration. + +* Save current value for convergence test. + REFOLD = REFP + +* Double the number of strips. + IS = IS+IS + +* Sum of all current values = sum of next pass's even values. + FE = FE+FO + +* Prepare for new odd values. + FO = 0D0 + +* Skip even values next time. + N = 2 + ELSE + +* Yes: save troposphere component and terminate the loop. + IF (K.EQ.1) REFT = REFP + LOOP = .FALSE. + END IF + END DO + END DO + +* Result. + REF = REFT+REFP + IF (ZOBS1.LT.0D0) REF = -REF + + END diff --git a/src/slalib/refv.f b/src/slalib/refv.f new file mode 100644 index 0000000..e81b03c --- /dev/null +++ b/src/slalib/refv.f @@ -0,0 +1,106 @@ + SUBROUTINE sla_REFV (VU, REFA, REFB, VR) +*+ +* - - - - - +* R E F V +* - - - - - +* +* Adjust an unrefracted Cartesian vector to include the effect of +* atmospheric refraction, using the simple A tan Z + B tan**3 Z +* model. +* +* Given: +* VU dp unrefracted position of the source (Az/El 3-vector) +* REFA dp tan Z coefficient (radian) +* REFB dp tan**3 Z coefficient (radian) +* +* Returned: +* VR dp refracted position of the source (Az/El 3-vector) +* +* Notes: +* +* 1 This routine applies the adjustment for refraction in the +* opposite sense to the usual one - it takes an unrefracted +* (in vacuo) position and produces an observed (refracted) +* position, whereas the A tan Z + B tan**3 Z model strictly +* applies to the case where an observed position is to have the +* refraction removed. The unrefracted to refracted case is +* harder, and requires an inverted form of the text-book +* refraction models; the algorithm used here is equivalent to +* one iteration of the Newton-Raphson method applied to the above +* formula. +* +* 2 Though optimized for speed rather than precision, the present +* routine achieves consistency with the refracted-to-unrefracted +* A tan Z + B tan**3 Z model at better than 1 microarcsecond within +* 30 degrees of the zenith and remains within 1 milliarcsecond to +* beyond ZD 70 degrees. The inherent accuracy of the model is, of +* course, far worse than this - see the documentation for sla_REFCO +* for more information. +* +* 3 At low elevations (below about 3 degrees) the refraction +* correction is held back to prevent arithmetic problems and +* wildly wrong results. Over a wide range of observer heights +* and corresponding temperatures and pressures, the following +* levels of accuracy (arcsec) are achieved, relative to numerical +* integration through a model atmosphere: +* +* ZD error +* +* 80 0.4 +* 81 0.8 +* 82 1.6 +* 83 3 +* 84 7 +* 85 17 +* 86 45 +* 87 150 +* 88 340 +* 89 620 +* 90 1100 +* 91 1900 } relevant only to +* 92 3200 } high-elevation sites +* +* 4 See also the routine sla_REFZ, which performs the adjustment to +* the zenith distance rather than in Cartesian Az/El coordinates. +* The present routine is faster than sla_REFZ and, except very low down, +* is equally accurate for all practical purposes. However, beyond +* about ZD 84 degrees sla_REFZ should be used, and for the utmost +* accuracy iterative use of sla_REFRO should be considered. +* +* P.T.Wallace Starlink 26 December 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION VU(3),REFA,REFB,VR(3) + + DOUBLE PRECISION X,Y,Z1,Z,ZSQ,RSQ,R,WB,WT,D,CD,F + + + +* Initial estimate = unrefracted vector + X = VU(1) + Y = VU(2) + Z1 = VU(3) + +* Keep correction approximately constant below about 3 deg elevation + Z = MAX(Z1,0.05D0) + +* One Newton-Raphson iteration + ZSQ = Z*Z + RSQ = X*X+Y*Y + R = SQRT(RSQ) + WB = REFB*RSQ/ZSQ + WT = (REFA+WB)/(1D0+(REFA+3D0*WB)*(ZSQ+RSQ)/ZSQ) + D = WT*R/Z + CD = 1D0-D*D/2D0 + F = CD*(1D0-WT) + +* Post-refraction x,y,z + VR(1) = X*F + VR(2) = Y*F + VR(3) = CD*(Z+D*R)+(Z1-Z) + + END diff --git a/src/slalib/refz.f b/src/slalib/refz.f new file mode 100644 index 0000000..d558c87 --- /dev/null +++ b/src/slalib/refz.f @@ -0,0 +1,139 @@ + SUBROUTINE sla_REFZ (ZU, REFA, REFB, ZR) +*+ +* - - - - - +* R E F Z +* - - - - - +* +* Adjust an unrefracted zenith distance to include the effect of +* atmospheric refraction, using the simple A tan Z + B tan**3 Z +* model (plus special handling for large ZDs). +* +* Given: +* ZU dp unrefracted zenith distance of the source (radian) +* REFA dp tan Z coefficient (radian) +* REFB dp tan**3 Z coefficient (radian) +* +* Returned: +* ZR dp refracted zenith distance (radian) +* +* Notes: +* +* 1 This routine applies the adjustment for refraction in the +* opposite sense to the usual one - it takes an unrefracted +* (in vacuo) position and produces an observed (refracted) +* position, whereas the A tan Z + B tan**3 Z model strictly +* applies to the case where an observed position is to have the +* refraction removed. The unrefracted to refracted case is +* harder, and requires an inverted form of the text-book +* refraction models; the formula used here is based on the +* Newton-Raphson method. For the utmost numerical consistency +* with the refracted to unrefracted model, two iterations are +* carried out, achieving agreement at the 1D-11 arcseconds level +* for a ZD of 80 degrees. The inherent accuracy of the model +* is, of course, far worse than this - see the documentation for +* sla_REFCO for more information. +* +* 2 At ZD 83 degrees, the rapidly-worsening A tan Z + B tan**3 Z +* model is abandoned and an empirical formula takes over. Over a +* wide range of observer heights and corresponding temperatures and +* pressures, the following levels of accuracy (arcsec) are +* typically achieved, relative to numerical integration through a +* model atmosphere: +* +* ZR error +* +* 80 0.4 +* 81 0.8 +* 82 1.5 +* 83 3.2 +* 84 4.9 +* 85 5.8 +* 86 6.1 +* 87 7.1 +* 88 10 +* 89 20 +* 90 40 +* 91 100 } relevant only to +* 92 200 } high-elevation sites +* +* The high-ZD model is scaled to match the normal model at the +* transition point; there is no glitch. +* +* 3 Beyond 93 deg zenith distance, the refraction is held at its +* 93 deg value. +* +* 4 See also the routine sla_REFV, which performs the adjustment in +* Cartesian Az/El coordinates, and with the emphasis on speed +* rather than numerical accuracy. +* +* P.T.Wallace Starlink 19 September 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION ZU,REFA,REFB,ZR + +* Radians to degrees + DOUBLE PRECISION R2D + PARAMETER (R2D=57.29577951308232D0) + +* Largest usable ZD (deg) + DOUBLE PRECISION D93 + PARAMETER (D93=93D0) + +* Coefficients for high ZD model (used beyond ZD 83 deg) + DOUBLE PRECISION C1,C2,C3,C4,C5 + PARAMETER (C1=+0.55445D0, + : C2=-0.01133D0, + : C3=+0.00202D0, + : C4=+0.28385D0, + : C5=+0.02390D0) + +* ZD at which one model hands over to the other (radians) + DOUBLE PRECISION Z83 + PARAMETER (Z83=83D0/R2D) + +* High-ZD-model prediction (deg) for that point + DOUBLE PRECISION REF83 + PARAMETER (REF83=(C1+C2*7D0+C3*49D0)/(1D0+C4*7D0+C5*49D0)) + + DOUBLE PRECISION ZU1,ZL,S,C,T,TSQ,TCU,REF,E,E2 + + + +* Perform calculations for ZU or 83 deg, whichever is smaller + ZU1 = MIN(ZU,Z83) + +* Functions of ZD + ZL = ZU1 + S = SIN(ZL) + C = COS(ZL) + T = S/C + TSQ = T*T + TCU = T*TSQ + +* Refracted ZD (mathematically to better than 1 mas at 70 deg) + ZL = ZL-(REFA*T+REFB*TCU)/(1D0+(REFA+3D0*REFB*TSQ)/(C*C)) + +* Further iteration + S = SIN(ZL) + C = COS(ZL) + T = S/C + TSQ = T*T + TCU = T*TSQ + REF = ZU1-ZL+ + : (ZL-ZU1+REFA*T+REFB*TCU)/(1D0+(REFA+3D0*REFB*TSQ)/(C*C)) + +* Special handling for large ZU + IF (ZU.GT.ZU1) THEN + E = 90D0-MIN(D93,ZU*R2D) + E2 = E*E + REF = (REF/REF83)*(C1+C2*E+C3*E2)/(1D0+C4*E+C5*E2) + END IF + +* Return refracted ZD + ZR = ZU-REF + + END diff --git a/src/slalib/rep.bat b/src/slalib/rep.bat new file mode 100755 index 0000000..0d00777 --- /dev/null +++ b/src/slalib/rep.bat @@ -0,0 +1,21 @@ +@echo off +rem +rem - - - - - - - - +rem R E P . B A T +rem - - - - - - - - +rem +rem Update one module in the SLALIB library +rem +rem Command: +rem +rem REP module +rem +rem File SLALIB.BAK is deleted. +rem +rem P.T.Wallace Starlink 5 April 1992 +rem +fl/c /FPi %1.for +lib slalib -+%1; +del %1.obj +del slalib.bak +echo: diff --git a/src/slalib/rtl_random.c b/src/slalib/rtl_random.c new file mode 100644 index 0000000..a8730c0 --- /dev/null +++ b/src/slalib/rtl_random.c @@ -0,0 +1,33 @@ +#include + +float +random_ ( int *iseed ) +/* +** - - - - - - - +** r a n d o m +** - - - - - - - +** +** Generate pseudo-random real number in the range 0 <= x < 1. +** +** (single precision) +** +** This function is designed to replace the Fortran->C interface routine +** random(3f) on systems which do not have this library (for example Linux) +** +** Fortran call: X = RANDOM(ISEED) +** +** Given: +** iseed int seed value +** +** If iseed !=0 random-number generator is initialised and first number +** is returned. +** iseed == 0 next number in the sequence is returned +** +** B.K.McIlwrath Starlink 12 January 1996 +*/ +{ + if( *iseed != 0 ) + srand(*iseed); + + return (float) rand() / (float) RAND_MAX; +} diff --git a/src/slalib/rverot.f b/src/slalib/rverot.f new file mode 100644 index 0000000..5fbe6d9 --- /dev/null +++ b/src/slalib/rverot.f @@ -0,0 +1,48 @@ + REAL FUNCTION sla_RVEROT (PHI, RA, DA, ST) +*+ +* - - - - - - - +* R V E R O T +* - - - - - - - +* +* Velocity component in a given direction due to Earth rotation +* (single precision) +* +* Given: +* PHI real latitude of observing station (geodetic) +* RA,DA real apparent RA,DEC +* ST real local apparent sidereal time +* +* PHI, RA, DEC and ST are all in radians. +* +* Result: +* Component of Earth rotation in direction RA,DA (km/s) +* +* Sign convention: +* The result is +ve when the observatory is receding from the +* given point on the sky. +* +* Accuracy: +* The simple algorithm used assumes a spherical Earth, of +* a radius chosen to give results accurate to about 0.0005 km/s +* for observing stations at typical latitudes and heights. For +* applications requiring greater precision, use the routine +* sla_PVOBS. +* +* P.T.Wallace Starlink 20 July 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL PHI,RA,DA,ST + +* Nominal mean sidereal speed of Earth equator in km/s (the actual +* value is about 0.4651) + REAL ESPEED + PARAMETER (ESPEED=0.4655) + + + sla_RVEROT=ESPEED*COS(PHI)*SIN(ST-RA)*COS(DA) + + END diff --git a/src/slalib/rvgalc.f b/src/slalib/rvgalc.f new file mode 100644 index 0000000..868c307 --- /dev/null +++ b/src/slalib/rvgalc.f @@ -0,0 +1,69 @@ + REAL FUNCTION sla_RVGALC (R2000, D2000) +*+ +* - - - - - - - +* R V G A L C +* - - - - - - - +* +* Velocity component in a given direction due to the rotation +* of the Galaxy (single precision) +* +* Given: +* R2000,D2000 real J2000.0 mean RA,Dec (radians) +* +* Result: +* Component of dynamical LSR motion in direction R2000,D2000 (km/s) +* +* Sign convention: +* The result is +ve when the dynamical LSR is receding from the +* given point on the sky. +* +* Note: The Local Standard of Rest used here is a point in the +* vicinity of the Sun which is in a circular orbit around +* the Galactic centre. Sometimes called the "dynamical" LSR, +* it is not to be confused with a "kinematical" LSR, which +* is the mean standard of rest of star catalogues or stellar +* populations. +* +* Reference: The orbital speed of 220 km/s used here comes from +* Kerr & Lynden-Bell (1986), MNRAS, 221, p1023. +* +* Called: +* sla_CS2C, sla_VDV +* +* P.T.Wallace Starlink 23 March 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL R2000,D2000 + + REAL VA(3), VB(3) + + REAL sla_VDV + +* +* LSR velocity due to Galactic rotation +* +* Speed = 220 km/s +* Apex = L2,B2 90deg, 0deg +* = RA,Dec 21 12 01.1 +48 19 47 J2000.0 +* +* This is expressed in the form of a J2000.0 x,y,z vector: +* +* VA(1) = X = -SPEED*COS(RA)*COS(DEC) +* VA(2) = Y = -SPEED*SIN(RA)*COS(DEC) +* VA(3) = Z = -SPEED*SIN(DEC) + + DATA VA / -108.70408, +97.86251, -164.33610 / + + + +* Convert given J2000 RA,Dec to x,y,z + CALL sla_CS2C(R2000,D2000,VB) + +* Compute dot product with LSR motion vector + sla_RVGALC=sla_VDV(VA,VB) + + END diff --git a/src/slalib/rvlg.f b/src/slalib/rvlg.f new file mode 100644 index 0000000..ba0216e --- /dev/null +++ b/src/slalib/rvlg.f @@ -0,0 +1,64 @@ + REAL FUNCTION sla_RVLG (R2000, D2000) +*+ +* - - - - - +* R V L G +* - - - - - +* +* Velocity component in a given direction due to the combination +* of the rotation of the Galaxy and the motion of the Galaxy +* relative to the mean motion of the local group (single precision) +* +* Given: +* R2000,D2000 real J2000.0 mean RA,Dec (radians) +* +* Result: +* Component of SOLAR motion in direction R2000,D2000 (km/s) +* +* Sign convention: +* The result is +ve when the Sun is receding from the +* given point on the sky. +* +* Reference: +* IAU Trans 1976, 168, p201. +* +* Called: +* sla_CS2C, sla_VDV +* +* P.T.Wallace Starlink June 1985 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL R2000,D2000 + + REAL VA(3), VB(3) + + REAL sla_VDV + +* +* Solar velocity due to Galactic rotation and translation +* +* Speed = 300 km/s +* +* Apex = L2,B2 90deg, 0deg +* = RA,Dec 21 12 01.1 +48 19 47 J2000.0 +* +* This is expressed in the form of a J2000.0 x,y,z vector: +* +* VA(1) = X = -SPEED*COS(RA)*COS(DEC) +* VA(2) = Y = -SPEED*SIN(RA)*COS(DEC) +* VA(3) = Z = -SPEED*SIN(DEC) + + DATA VA / -148.23284, +133.44888, -224.09467 / + + + +* Convert given J2000 RA,Dec to x,y,z + CALL sla_CS2C(R2000,D2000,VB) + +* Compute dot product with Solar motion vector + sla_RVLG=sla_VDV(VA,VB) + + END diff --git a/src/slalib/rvlsrd.f b/src/slalib/rvlsrd.f new file mode 100644 index 0000000..96f90c9 --- /dev/null +++ b/src/slalib/rvlsrd.f @@ -0,0 +1,78 @@ + REAL FUNCTION sla_RVLSRD (R2000, D2000) +*+ +* - - - - - - - +* R V L S R D +* - - - - - - - +* +* Velocity component in a given direction due to the Sun's motion +* with respect to the dynamical Local Standard of Rest. +* +* (single precision) +* +* Given: +* R2000,D2000 r J2000.0 mean RA,Dec (radians) +* +* Result: +* Component of "peculiar" solar motion in direction R2000,D2000 (km/s) +* +* Sign convention: +* The result is +ve when the Sun is receding from the given point on +* the sky. +* +* Note: The Local Standard of Rest used here is the "dynamical" LSR, +* a point in the vicinity of the Sun which is in a circular +* orbit around the Galactic centre. The Sun's motion with +* respect to the dynamical LSR is called the "peculiar" solar +* motion. +* +* There is another type of LSR, called a "kinematical" LSR. A +* kinematical LSR is the mean standard of rest of specified star +* catalogues or stellar populations, and several slightly +* different kinematical LSRs are in use. The Sun's motion with +* respect to an agreed kinematical LSR is known as the "standard" +* solar motion. To obtain a radial velocity correction with +* respect to an adopted kinematical LSR use the routine sla_RVLSRK. +* +* Reference: Delhaye (1965), in "Stars and Stellar Systems", vol 5, +* p73. +* +* Called: +* sla_CS2C, sla_VDV +* +* P.T.Wallace Starlink 9 March 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL R2000,D2000 + + REAL VA(3), VB(3) + + REAL sla_VDV + +* +* Peculiar solar motion from Delhaye 1965: in Galactic Cartesian +* coordinates (+9,+12,+7) km/s. This corresponds to about 16.6 km/s +* towards Galactic coordinates L2 = 53 deg, B2 = +25 deg, or RA,Dec +* 17 49 58.7 +28 07 04 J2000. +* +* The solar motion is expressed here in the form of a J2000.0 +* equatorial Cartesian vector: +* +* VA(1) = X = -SPEED*COS(RA)*COS(DEC) +* VA(2) = Y = -SPEED*SIN(RA)*COS(DEC) +* VA(3) = Z = -SPEED*SIN(DEC) + + DATA VA / +0.63823, +14.58542, -7.80116 / + + + +* Convert given J2000 RA,Dec to x,y,z + CALL sla_CS2C(R2000,D2000,VB) + +* Compute dot product with solar motion vector + sla_RVLSRD=sla_VDV(VA,VB) + + END diff --git a/src/slalib/rvlsrk.f b/src/slalib/rvlsrk.f new file mode 100644 index 0000000..b484fe8 --- /dev/null +++ b/src/slalib/rvlsrk.f @@ -0,0 +1,77 @@ + REAL FUNCTION sla_RVLSRK (R2000, D2000) +*+ +* - - - - - - - +* R V L S R K +* - - - - - - - +* +* Velocity component in a given direction due to the Sun's motion +* with respect to an adopted kinematic Local Standard of Rest. +* +* (single precision) +* +* Given: +* R2000,D2000 r J2000.0 mean RA,Dec (radians) +* +* Result: +* Component of "standard" solar motion in direction R2000,D2000 (km/s) +* +* Sign convention: +* The result is +ve when the Sun is receding from the given point on +* the sky. +* +* Note: The Local Standard of Rest used here is one of several +* "kinematical" LSRs in common use. A kinematical LSR is the +* mean standard of rest of specified star catalogues or stellar +* populations. The Sun's motion with respect to a kinematical +* LSR is known as the "standard" solar motion. +* +* There is another sort of LSR, the "dynamical" LSR, which is a +* point in the vicinity of the Sun which is in a circular orbit +* around the Galactic centre. The Sun's motion with respect to +* the dynamical LSR is called the "peculiar" solar motion. To +* obtain a radial velocity correction with respect to the +* dynamical LSR use the routine sla_RVLSRD. +* +* Reference: Delhaye (1965), in "Stars and Stellar Systems", vol 5, +* p73. +* +* Called: +* sla_CS2C, sla_VDV +* +* P.T.Wallace Starlink 11 March 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL R2000,D2000 + + REAL VA(3), VB(3) + + REAL sla_VDV + +* +* Standard solar motion (from Methods of Experimental Physics, ed Meeks, +* vol 12, part C, sec 6.1.5.2, p281): +* +* 20 km/s towards RA 18h Dec +30d (1900). +* +* The solar motion is expressed here in the form of a J2000.0 +* equatorial Cartesian vector: +* +* VA(1) = X = -SPEED*COS(RA)*COS(DEC) +* VA(2) = Y = -SPEED*SIN(RA)*COS(DEC) +* VA(3) = Z = -SPEED*SIN(DEC) + + DATA VA / -0.29000, +17.31726, -10.00141 / + + + +* Convert given J2000 RA,Dec to x,y,z + CALL sla_CS2C(R2000,D2000,VB) + +* Compute dot product with solar motion vector + sla_RVLSRK=sla_VDV(VA,VB) + + END diff --git a/src/slalib/s2tp.f b/src/slalib/s2tp.f new file mode 100644 index 0000000..1ec36f2 --- /dev/null +++ b/src/slalib/s2tp.f @@ -0,0 +1,67 @@ + SUBROUTINE sla_S2TP (RA, DEC, RAZ, DECZ, XI, ETA, J) +*+ +* - - - - - +* S 2 T P +* - - - - - +* +* Projection of spherical coordinates onto tangent plane: +* "gnomonic" projection - "standard coordinates" +* (single precision) +* +* Given: +* RA,DEC real spherical coordinates of point to be projected +* RAZ,DECZ real spherical coordinates of tangent point +* +* Returned: +* XI,ETA real rectangular coordinates on tangent plane +* J int status: 0 = OK, star on tangent plane +* 1 = error, star too far from axis +* 2 = error, antistar on tangent plane +* 3 = error, antistar too far from axis +* +* P.T.Wallace Starlink 18 July 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL RA,DEC,RAZ,DECZ,XI,ETA + INTEGER J + + REAL SDECZ,SDEC,CDECZ,CDEC,RADIF,SRADIF,CRADIF,DENOM + + REAL TINY + PARAMETER (TINY=1E-6) + + +* Trig functions + SDECZ=SIN(DECZ) + SDEC=SIN(DEC) + CDECZ=COS(DECZ) + CDEC=COS(DEC) + RADIF=RA-RAZ + SRADIF=SIN(RADIF) + CRADIF=COS(RADIF) + +* Reciprocal of star vector length to tangent plane + DENOM=SDEC*SDECZ+CDEC*CDECZ*CRADIF + +* Handle vectors too far from axis + IF (DENOM.GT.TINY) THEN + J=0 + ELSE IF (DENOM.GE.0.0) THEN + J=1 + DENOM=TINY + ELSE IF (DENOM.GT.-TINY) THEN + J=2 + DENOM=-TINY + ELSE + J=3 + END IF + +* Compute tangent plane coordinates (even in dubious cases) + XI=CDEC*SRADIF/DENOM + ETA=(SDEC*CDECZ-CDEC*SDECZ*CRADIF)/DENOM + + END diff --git a/src/slalib/sep.f b/src/slalib/sep.f new file mode 100644 index 0000000..c977985 --- /dev/null +++ b/src/slalib/sep.f @@ -0,0 +1,48 @@ + REAL FUNCTION sla_SEP (A1, B1, A2, B2) +*+ +* - - - - +* S E P +* - - - - +* +* Angle between two points on a sphere (single precision) +* +* Given: +* A1,B1 real spherical coordinates of one point +* A2,B2 real spherical coordinates of the other point +* +* (The spherical coordinates are RA,Dec, Long,Lat etc, in radians.) +* +* The result is the angle, in radians, between the two points. It +* is always positive. +* +* Called: sla_CS2C +* +* P.T.Wallace Starlink April 1985 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL A1,B1,A2,B2 + + INTEGER I + REAL V1(3),V2(3),W + + + +* Convert coordinates from spherical to Cartesian + CALL sla_CS2C(A1,B1,V1) + CALL sla_CS2C(A2,B2,V2) + +* Modulus squared of half the difference vector + W=0.0 + DO I=1,3 + W=W+(V1(I)-V2(I))**2 + END DO + W=W/4.0 + +* Angle between the vectors + sla_SEP=2.0*ATAN2(SQRT(W),SQRT(MAX(0.0,1.0-W))) + + END diff --git a/src/slalib/sla.news b/src/slalib/sla.news new file mode 100644 index 0000000..51b2888 --- /dev/null +++ b/src/slalib/sla.news @@ -0,0 +1,40 @@ +SLALIB_Version_2.4-0 Expiry 31 December 1999 + +The latest releases of SLALIB include the following changes: + +* Four new routines have been introduced which transform between the + FK5 system and the ICRS (Hipparcos) system. sla_FK52H and sla_H2FK5 + transform star positions and proper motions from FK5 coordinates to + Hipparcos coordinates and vice versa. sla_FK5HZ and sla_HFK5Z do the + same but for the case where the Hipparcos proper motions are zero. + +* Six new routines have been introduced for dealing with orbital elements. + Four of them (sla_EL2UE, sla_PV2UE, sla_UE2EL and sla_UE2PV) provide + applications with direct access to the "universal variables" method + that was already being used internally. Compared with using conventional + (angular) elements and solving Kepler's equation, the universal variables + approach has a number of advantages, including better handling of near- + parabolic orbits and greater efficiency. The remaining two routines + (sla_PERTEL and sla_PERTUE) generate updated elements by applying + major-planet perturbations. The new elements can then be used to + predict positions that are much more accurate. For minor planets, + sub-arcsecond accuracy over a decade is achievable. + +* Several observatory sites have been added to the sla_OBS routine: CFHT, + Keck 2, Gemini North, FCRAO, IRTF and CSO. The coordinates for all + the Mauna Kea sites have been updated in accordance with recent aerial + photography results made available by the Institute for Astronomy, + University of Hawaii. + +* A bug in sla_DAT has been corrected. It used to give incorrect + results for dates in the first 54 days of 1972. + +* There are new routines for generating permutations (sla_PERMUT) and + combinations (sla_COMBN). + + P.T.Wallace + 17 August 1999 + + ptw@star.rl.ac.uk + +44-1235-44-5372 +-------------------------------------------------------------------------- diff --git a/src/slalib/sla_link b/src/slalib/sla_link new file mode 100755 index 0000000..40aa195 --- /dev/null +++ b/src/slalib/sla_link @@ -0,0 +1 @@ +echo -lsla diff --git a/src/slalib/sla_link_adam b/src/slalib/sla_link_adam new file mode 100755 index 0000000..40aa195 --- /dev/null +++ b/src/slalib/sla_link_adam @@ -0,0 +1 @@ +echo -lsla diff --git a/src/slalib/sla_test.f b/src/slalib/sla_test.f new file mode 100644 index 0000000..c094c26 --- /dev/null +++ b/src/slalib/sla_test.f @@ -0,0 +1,28 @@ + PROGRAM SLA_TEST +*+ +* - - - - - +* T E S T +* - - - - - +* +* Simple test of SLALIB library - checks that a program can be +* linked and a correct result returned from at least one subprogram. +* +* P.T.Wallace Starlink 24 August 1992 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION D + INTEGER J + + + CALL sla_CALDJ(1946,4,30,D,J) + IF (J.EQ.0.AND.NINT(D).EQ.31940) THEN + PRINT *,'SLALIB test completed satisfactorily.' + ELSE + PRINT *,'SLALIB test fails!' + END IF + + END diff --git a/src/slalib/smat.f b/src/slalib/smat.f new file mode 100644 index 0000000..93dbee7 --- /dev/null +++ b/src/slalib/smat.f @@ -0,0 +1,141 @@ + SUBROUTINE sla_SMAT (N, A, Y, D, JF, IW) +*+ +* - - - - - +* S M A T +* - - - - - +* +* Matrix inversion & solution of simultaneous equations +* (single precision) +* +* For the set of n simultaneous equations in n unknowns: +* A.Y = X +* +* where: +* A is a non-singular N x N matrix +* Y is the vector of N unknowns +* X is the known vector +* +* SMATRX computes: +* the inverse of matrix A +* the determinant of matrix A +* the vector of N unknowns +* +* Arguments: +* +* symbol type dimension before after +* +* N int no. of unknowns unchanged +* A real (N,N) matrix inverse +* Y real (N) vector solution +* D real - determinant +* * JF int - singularity flag +* IW int (N) - workspace +* +* * JF is the singularity flag. If the matrix is non-singular, +* JF=0 is returned. If the matrix is singular, JF=-1 & D=0.0 are +* returned. In the latter case, the contents of array A on return +* are undefined. +* +* Algorithm: +* Gaussian elimination with partial pivoting. +* +* Speed: +* Very fast. +* +* Accuracy: +* Fairly accurate - errors 1 to 4 times those of routines optimised +* for accuracy. +* +* Note: replaces the obsolete sla_SMATRX routine. +* +* P.T.Wallace Starlink 10 September 1990 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER N + REAL A(N,N),Y(N),D + INTEGER JF + INTEGER IW(N) + + REAL SFA + PARAMETER (SFA=1E-20) + + INTEGER K,IMX,I,J,NP1MK,KI + REAL AMX,T,AKK,YK,AIK + + + JF=0 + D=1.0 + DO K=1,N + AMX=ABS(A(K,K)) + IMX=K + IF (K.NE.N) THEN + DO I=K+1,N + T=ABS(A(I,K)) + IF (T.GT.AMX) THEN + AMX=T + IMX=I + END IF + END DO + END IF + IF (AMX.LT.SFA) THEN + JF=-1 + ELSE + IF (IMX.NE.K) THEN + DO J=1,N + T=A(K,J) + A(K,J)=A(IMX,J) + A(IMX,J)=T + END DO + T=Y(K) + Y(K)=Y(IMX) + Y(IMX)=T + D=-D + END IF + IW(K)=IMX + AKK=A(K,K) + D=D*AKK + IF (ABS(D).LT.SFA) THEN + JF=-1 + ELSE + AKK=1.0/AKK + A(K,K)=AKK + DO J=1,N + IF (J.NE.K) A(K,J)=A(K,J)*AKK + END DO + YK=Y(K)*AKK + Y(K)=YK + DO I=1,N + AIK=A(I,K) + IF (I.NE.K) THEN + DO J=1,N + IF (J.NE.K) A(I,J)=A(I,J)-AIK*A(K,J) + END DO + Y(I)=Y(I)-AIK*YK + END IF + END DO + DO I=1,N + IF (I.NE.K) A(I,K)=-A(I,K)*AKK + END DO + END IF + END IF + END DO + IF (JF.NE.0) THEN + D=0.0 + ELSE + DO K=1,N + NP1MK=N+1-K + KI=IW(NP1MK) + IF (NP1MK.NE.KI) THEN + DO I=1,N + T=A(I,NP1MK) + A(I,NP1MK)=A(I,KI) + A(I,KI)=T + END DO + END IF + END DO + END IF + END diff --git a/src/slalib/subet.f b/src/slalib/subet.f new file mode 100644 index 0000000..e36575b --- /dev/null +++ b/src/slalib/subet.f @@ -0,0 +1,66 @@ + SUBROUTINE sla_SUBET (RC, DC, EQ, RM, DM) +*+ +* - - - - - - +* S U B E T +* - - - - - - +* +* Remove the E-terms (elliptic component of annual aberration) +* from a pre IAU 1976 catalogue RA,Dec to give a mean place +* (double precision) +* +* Given: +* RC,DC dp RA,Dec (radians) with E-terms included +* EQ dp Besselian epoch of mean equator and equinox +* +* Returned: +* RM,DM dp RA,Dec (radians) without E-terms +* +* Called: +* sla_ETRMS, sla_DCS2C, sla_,DVDV, sla_DCC2S, sla_DRANRM +* +* Explanation: +* Most star positions from pre-1984 optical catalogues (or +* derived from astrometry using such stars) embody the +* E-terms. This routine converts such a position to a +* formal mean place (allowing, for example, comparison with a +* pulsar timing position). +* +* Reference: +* Explanatory Supplement to the Astronomical Ephemeris, +* section 2D, page 48. +* +* P.T.Wallace Starlink 10 May 1990 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION RC,DC,EQ,RM,DM + + DOUBLE PRECISION sla_DRANRM,sla_DVDV + DOUBLE PRECISION A(3),V(3),F + + INTEGER I + + + +* E-terms + CALL sla_ETRMS(EQ,A) + +* Spherical to Cartesian + CALL sla_DCS2C(RC,DC,V) + +* Include the E-terms + F=1D0+sla_DVDV(V,A) + DO I=1,3 + V(I)=F*V(I)-A(I) + END DO + +* Cartesian to spherical + CALL sla_DCC2S(V,RM,DM) + +* Bring RA into conventional range + RM=sla_DRANRM(RM) + + END diff --git a/src/slalib/sun67.htx/blueball.gif b/src/slalib/sun67.htx/blueball.gif new file mode 100644 index 0000000..c481395 Binary files /dev/null and b/src/slalib/sun67.htx/blueball.gif differ diff --git a/src/slalib/sun67.htx/change_begin.gif b/src/slalib/sun67.htx/change_begin.gif new file mode 100644 index 0000000..dbe8d7e Binary files /dev/null and b/src/slalib/sun67.htx/change_begin.gif differ diff --git a/src/slalib/sun67.htx/change_begin_right.gif b/src/slalib/sun67.htx/change_begin_right.gif new file mode 100644 index 0000000..331ddf2 Binary files /dev/null and b/src/slalib/sun67.htx/change_begin_right.gif differ diff --git a/src/slalib/sun67.htx/change_delete.gif b/src/slalib/sun67.htx/change_delete.gif new file mode 100644 index 0000000..63398f5 Binary files /dev/null and b/src/slalib/sun67.htx/change_delete.gif differ diff --git a/src/slalib/sun67.htx/change_delete_right.gif b/src/slalib/sun67.htx/change_delete_right.gif new file mode 100644 index 0000000..63398f5 Binary files /dev/null and b/src/slalib/sun67.htx/change_delete_right.gif differ diff --git a/src/slalib/sun67.htx/change_end.gif b/src/slalib/sun67.htx/change_end.gif new file mode 100644 index 0000000..8f1e455 Binary files /dev/null and b/src/slalib/sun67.htx/change_end.gif differ diff --git a/src/slalib/sun67.htx/change_end_right.gif b/src/slalib/sun67.htx/change_end_right.gif new file mode 100644 index 0000000..409246c Binary files /dev/null and b/src/slalib/sun67.htx/change_end_right.gif differ diff --git a/src/slalib/sun67.htx/contents.xbm b/src/slalib/sun67.htx/contents.xbm new file mode 100644 index 0000000..a3aed9f --- /dev/null +++ b/src/slalib/sun67.htx/contents.xbm @@ -0,0 +1,12 @@ +#define contents_width 63 +#define contents_height 16 +static char contents_bits[] = { + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xc0,0x01,0x00,0x08,0x00,0x00,0x01,0x00,0x20,0x02,0x00,0x08,0x00, + 0x00,0x01,0x00,0x20,0xe2,0x74,0x7c,0x9c,0x8e,0x8f,0x03,0x20,0x10,0x99,0x08, + 0x22,0x13,0x41,0x04,0x20,0x10,0x89,0x08,0x3e,0x11,0x81,0x03,0x20,0x12,0x89, + 0x08,0x02,0x11,0x01,0x04,0x20,0x12,0x89,0x88,0x22,0x11,0x51,0x04,0xc0,0xe1, + 0x9c,0x71,0x9c,0x33,0x8e,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00}; diff --git a/src/slalib/sun67.htx/contents_motif.gif b/src/slalib/sun67.htx/contents_motif.gif new file mode 100644 index 0000000..7b3c904 Binary files /dev/null and b/src/slalib/sun67.htx/contents_motif.gif differ diff --git a/src/slalib/sun67.htx/cross_ref_motif.gif b/src/slalib/sun67.htx/cross_ref_motif.gif new file mode 100644 index 0000000..4c074e1 Binary files /dev/null and b/src/slalib/sun67.htx/cross_ref_motif.gif differ diff --git a/src/slalib/sun67.htx/foot_motif.gif b/src/slalib/sun67.htx/foot_motif.gif new file mode 100644 index 0000000..f29222a Binary files /dev/null and b/src/slalib/sun67.htx/foot_motif.gif differ diff --git a/src/slalib/sun67.htx/footnode.html b/src/slalib/sun67.htx/footnode.html new file mode 100644 index 0000000..b6bcb72 --- /dev/null +++ b/src/slalib/sun67.htx/footnode.html @@ -0,0 +1,224 @@ + + + + +Footnotes + + + + + + + + + + +

+
...SLALIB +
The name isn't an acronym; +it just stands for ``Subprogram Library A''. +
.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+
+
...papers; +
One frame not included in +Figure 1 is that of the Hipparcos catalogue. This is currently the +best available implementation in the optical of the International +Celestial Reference System (ICRS), which is based on extragalactic +radio sources observed by VLBI. The distinction between FK5 J2000 +and Hipparcos coordinates only becomes important when accuracies of +50 mas or better are required. More details are given in +Section 4.14. +
.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+
+
...equinox. +
With +the introduction of the International Celestial Reference System (ICRS), the +connection between (i) star coordinates and (ii) the Earth's orientation +and orbit has been broken. However, the orientation of the +International Celestial Reference Frame (ICRF) axes was, for convenience, +chosen to match J2000 FK5, and for most practical purposes ICRF coordinates +(for example entries in the Hipparcos catalogue) can be regarded as +synonymous with J2000 FK5. See Section 4.14 for further details. +
.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+
+
...used. +
An equinox is, however, not required for coordinates +in the International Celestial Reference System. Such coordinates must +be labelled simply ``ICRS'', or the specific catalogue can be mentioned, +such as ``Hipparcos''; constructions such as ``Hipparcos, J2000'' are +redundant and misleading. +
.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+
+
...catalogues. +
This was +true until the inception of the International Celestial Reference +System, which is based on the idea of axes locked into the +distant background. The coordinates +of the extragalactic sources which realize these +axes have no individual significance; there is a ``no net rotation'' +condition which has to be satisfied each time any revisions take +place. +
.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+.
+
+
+SLALIB -- Positional Astronomy Library +
+Starlink User Note 67 +
+P. T. Wallace +
+12 October 1999 +
+E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/greenball.gif b/src/slalib/sun67.htx/greenball.gif new file mode 100644 index 0000000..2ffbb22 Binary files /dev/null and b/src/slalib/sun67.htx/greenball.gif differ diff --git a/src/slalib/sun67.htx/icons.html b/src/slalib/sun67.htx/icons.html new file mode 100644 index 0000000..d6b38c3 --- /dev/null +++ b/src/slalib/sun67.htx/icons.html @@ -0,0 +1,42 @@ + +
+ +

+ +

+ +

+ +

+ +

+ +

+ +

+ +

+ +

+ +

+ +

+ +

+ +

+ + +

+ + + + + + +

+ +changeend

+ +

changeend diff --git a/src/slalib/sun67.htx/image.gif b/src/slalib/sun67.htx/image.gif new file mode 100644 index 0000000..7e6cb1a Binary files /dev/null and b/src/slalib/sun67.htx/image.gif differ diff --git a/src/slalib/sun67.htx/images.aux b/src/slalib/sun67.htx/images.aux new file mode 100644 index 0000000..f23e546 --- /dev/null +++ b/src/slalib/sun67.htx/images.aux @@ -0,0 +1 @@ +\relax diff --git a/src/slalib/sun67.htx/images.log b/src/slalib/sun67.htx/images.log new file mode 100644 index 0000000..6a48021 --- /dev/null +++ b/src/slalib/sun67.htx/images.log @@ -0,0 +1,1727 @@ +This is TeX, Version 3.14159 (C version 6.1) (format=latex 97.3.17) 12 OCT 1999 16:11 +**./images.tex +(images.tex +LaTeX2e <1996/12/01> patch level 1 +Babel and hyphenation patterns for american, german, loaded. + +(/usr/local/teTeX/texmf/tex/latex/base/article.cls +Document Class: article 1996/10/31 v1.3u Standard LaTeX document class +(/usr/local/teTeX/texmf/tex/latex/base/size11.clo +File: size11.clo 1996/10/31 v1.3u Standard LaTeX file (size option) +) +\c@part=\count79 +\c@section=\count80 +\c@subsection=\count81 +\c@subsubsection=\count82 +\c@paragraph=\count83 +\c@subparagraph=\count84 +\c@figure=\count85 +\c@table=\count86 +\abovecaptionskip=\skip41 +\belowcaptionskip=\skip42 +\bibindent=\dimen102 +) (/home/user1/dec/ptw/hypertext/sun67_htx/html.sty) (/home/user1/dec/ptw/hyper +text/sun67_htx/star2html.sty) +! Undefined control sequence. +l.42 \latex + {\renewcommand {\_}{{\tt\symbol{95}}}} +The control sequence at the end of the top line +of your error message was never \def'ed. If you have +misspelled it (e.g., `\hobx'), type `I' and the correct +spelling (e.g., `I\hbox'). Otherwise just continue, +and I'll forget about whatever was undefined. + +\oldspacing=\skip43 +(/home/user1/dec/ptw/hypertext/sun67_htx/star2html.sty) +\sizebox=\box26 +\lthtmlwrite=\write3 +(images.aux) +LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 350. +LaTeX Font Info: ... okay on input line 350. +LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 350. +LaTeX Font Info: ... okay on input line 350. +LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 350. +LaTeX Font Info: ... okay on input line 350. +LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 350. +LaTeX Font Info: ... okay on input line 350. +LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 350. +LaTeX Font Info: ... okay on input line 350. +LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 350. +LaTeX Font Info: ... okay on input line 350. +latex2htmlLength hsize=451.0pt +latex2htmlLength vsize=715.72284pt +latex2htmlLength hoffset=0.0pt +latex2htmlLength voffset=0.0pt +latex2htmlLength topmargin=0.0pt +latex2htmlLength topskip=0.00002pt +latex2htmlLength headheight=0.0pt +latex2htmlLength headsep=0.0pt +latex2htmlLength parskip=6.0pt plus 2.0pt minus 2.0pt +latex2htmlLength oddsidemargin=0.0pt +latex2htmlLength evensidemargin=0.0pt +LaTeX Font Info: External font `cmex10' loaded for size +(Font) <10.95> on input line 374. +LaTeX Font Info: External font `cmex10' loaded for size +(Font) <8> on input line 374. +LaTeX Font Info: External font `cmex10' loaded for size +(Font) <6> on input line 374. +l2hSize :tex2html_wrap_inline417:7.62646pt::0.0pt::10.22507pt. +[1 + + +] +l2hSize :tex2html_wrap_inline419:7.62646pt::7.62646pt::18.74176pt. +[2 + + +] +l2hSize :tex2html_wrap_inline528:8.2125pt::8.2125pt::26.92624pt. +[3 + + +] +l2hSize :tex2html_wrap_inline786:10.13034pt::0.0pt::58.35004pt. +[4 + + +] +l2hSize :tex2html_wrap_inline788:7.07185pt::0.0pt::5.475pt. +[5 + + +] +l2hSize :tex2html_wrap_inline802:8.2125pt::8.2125pt::150.20139pt. +[6 + + +] +l2hSize :tex2html_wrap_inline806:8.2125pt::8.2125pt::155.67639pt. +[7 + + +] +l2hSize :tex2html_wrap_inline893:7.62646pt::7.62646pt::35.89854pt. +[8 + + +] +l2hSize :tex2html_wrap_inline1090:8.2125pt::8.2125pt::42.52638pt. +[9 + + +] +l2hSize :tex2html_wrap_inline1092:7.07185pt::0.0pt::10.95003pt. +[10 + + +] +l2hSize :tex2html_wrap_inline1094:8.2125pt::8.2125pt::117.90274pt. +[11 + + +] +l2hSize :tex2html_wrap_inline1098:9.12923pt::9.12923pt::122.6528pt. +[12 + + +] +l2hSize :tex2html_wrap_inline1102:8.2125pt::8.2125pt::32.18459pt. +[13 + + +] +l2hSize :tex2html_wrap_inline1104:8.2125pt::8.2125pt::26.10136pt. +[14 + + +] +l2hSize :tex2html_wrap_inline1106:8.2125pt::8.2125pt::26.10136pt. +[15 + + +] +l2hSize :tex2html_wrap_inline1373:8.2125pt::8.2125pt::19.4667pt. +[16 + + +] +l2hSize :tex2html_wrap_inline1375:13.58197pt::13.58197pt::46.33769pt. +[17 + + +] +l2hSize :tex2html_wrap_inline1377:7.07185pt::7.07185pt::24.33328pt. +[18 + + +] +l2hSize :tex2html_wrap_inline1701:7.48248pt::0.0pt::9.12502pt. +[19 + + +] +l2hSize :tex2html_wrap_inline1705:8.2125pt::8.2125pt::26.61958pt. +[20 + + +] +l2hSize :tex2html_wrap_inline1707:7.07185pt::7.07185pt::15.72293pt. +[21 + + +] +l2hSize :tex2html_wrap_inline1709:7.62646pt::0.0pt::15.70007pt. +[22 + + +] +l2hSize :tex2html_wrap_inline1711:7.60416pt::0.0pt::5.28107pt. +[23 + + +] +l2hSize :tex2html_wrap_inline1713:7.07185pt::0.0pt::7.04526pt. +[24 + + +] +l2hSize :tex2html_wrap_inline1715:10.13034pt::0.0pt::13.85803pt. +[25 + + +] +l2hSize :tex2html_wrap_inline1717:7.62646pt::7.62646pt::35.89854pt. +[26 + + +] +l2hSize :tex2html_wrap_inline1721:7.62646pt::0.0pt::10.22507pt. +[27 + + +] +l2hSize :tex2html_wrap_inline1725:8.2125pt::8.2125pt::42.40842pt. +[28 + + +] +l2hSize :tex2html_wrap_inline1729:8.2125pt::8.2125pt::26.18991pt. +[29 + + +] +l2hSize :tex2html_wrap_inline1745:7.07185pt::7.07185pt::8.5167pt. +[30 + + +] +l2hSize :tex2html_wrap_inline1747:7.4181pt::0.0pt::14.55948pt. +[31 + + +] +l2hSize :tex2html_wrap_inline1749:10.13034pt::0.0pt::13.85803pt. +[32 + + +] +l2hSize :tex2html_wrap_inline2524:7.62646pt::0.0pt::15.70007pt. +[33 + + +] +l2hSize :tex2html_wrap_inline2704:7.07185pt::7.07185pt::31.53958pt. +[34 + + +] +l2hSize :tex2html_wrap_inline2706:7.07185pt::7.07185pt::31.53958pt. +[35 + + +] +l2hSize :tex2html_wrap_inline2708:7.62646pt::0.0pt::15.70007pt. +[36 + + +] +l2hSize :tex2html_wrap_inline2710:7.62646pt::0.0pt::21.17508pt. +[37 + + +] +l2hSize :tex2html_wrap_inline2712:9.12923pt::0.0pt::56.14227pt. +[38 + + +] +l2hSize :tex2html_wrap_inline2716:7.62646pt::0.0pt::15.70007pt. +[39 + + +] +l2hSize :tex2html_wrap_inline2718:7.07185pt::7.07185pt::31.53958pt. +[40 + + +] +l2hSize :tex2html_wrap_inline2720:7.07185pt::7.07185pt::31.53958pt. +[41 + + +] +l2hSize :tex2html_wrap_inline2722:7.07185pt::7.07185pt::28.49791pt. +[42 + + +] +l2hSize :tex2html_wrap_inline2724:10.13034pt::0.0pt::15.1963pt. +[43 + + +] +l2hSize :tex2html_wrap_inline2726:7.07185pt::7.07185pt::33.97292pt. +[44 + + +] +l2hSize :tex2html_wrap_inline2728:8.2125pt::8.2125pt::33.97289pt. +[45 + + +] +l2hSize :tex2html_wrap_inline2867:8.2125pt::8.2125pt::23.86188pt. +[46 + + +] +l2hSize :tex2html_wrap_inline2869:7.07185pt::7.07185pt::15.15135pt. +[47 + + +] +l2hSize :tex2html_wrap_inline3016:7.07185pt::0.0pt::12.77495pt. +[48 + + +] +l2hSize :tex2html_wrap_inline3160:9.52922pt::0.0pt::10.6973pt. +[49 + + +] +l2hSize :tex2html_wrap_inline3380:8.2125pt::8.2125pt::37.06009pt. +[50 + + +] +l2hSize :tex2html_wrap_inline3493:8.2125pt::8.2125pt::69.25354pt. +[51 + + +] +l2hSize :tex2html_wrap_inline4117:7.07185pt::0.0pt::12.10966pt. +[52 + + +] +l2hSize :tex2html_wrap_inline4123:7.62646pt::0.0pt::21.17508pt. +[53 + + +] +l2hSize :tex2html_wrap_inline5205:9.52922pt::0.0pt::53.15852pt. +[54 + + +] +l2hSize :tex2html_wrap_inline5954:8.2125pt::8.2125pt::33.90187pt. +[55 + + +] +l2hSize :tex2html_wrap_inline5956:8.2125pt::8.2125pt::33.90187pt. +[56 + + +] +l2hSize :tex2html_wrap_inline5962:8.41812pt::8.41812pt::62.95944pt. +[57 + + +] +l2hSize :tex2html_wrap_inline5964:8.41812pt::8.41812pt::61.57301pt. +[58 + + +] +l2hSize :tex2html_wrap_inline5966:8.41812pt::0.0pt::49.32889pt. +[59 + + +] +l2hSize :tex2html_wrap_inline5968:8.41812pt::8.41812pt::48.33533pt. +[60 + + +] +l2hSize :tex2html_wrap_inline5970:8.41812pt::8.41812pt::190.55496pt. +[61 + + +] +l2hSize :tex2html_wrap_inline5972:8.41812pt::8.41812pt::190.05818pt. +[62 + + +] +l2hSize :tex2html_wrap_inline5974:8.41812pt::8.41812pt::197.9745pt. +[63 + + +] +l2hSize :tex2html_wrap_inline5976:8.41812pt::8.41812pt::197.08485pt. +[64 + + +] +l2hSize :tex2html_wrap_inline6230:7.60416pt::7.60416pt::16.45663pt. +[65 + + +] +l2hSize :tex2html_wrap_inline6232:7.07185pt::7.07185pt::27.31801pt. +[66 + + +] +l2hSize :tex2html_wrap_inline6347:7.07185pt::0.0pt::27.98332pt. +[67 + + +] +l2hSize :tex2html_wrap_inline6475:7.07185pt::7.07185pt::50.91757pt. +[68 + + +] +l2hSize :tex2html_wrap_inline6491:7.07185pt::7.07185pt::22.56413pt. +[69 + + +] +l2hSize :tex2html_wrap_inline6713:9.44032pt::0.0pt::9.67093pt. +[70 + + +] +l2hSize :tex2html_wrap_inline6717:7.48248pt::0.0pt::10.03752pt. +[71 + + +] +l2hSize :tex2html_wrap_inline7186:7.07185pt::0.0pt::3.04167pt. +[72 + + +] +l2hSize :tex2html_wrap_inline7188:7.07185pt::7.07185pt::26.52841pt. +[73 + + +] +l2hSize :tex2html_wrap_inline7358:10.13034pt::0.0pt::15.1963pt. +[74 + + +] +l2hSize :tex2html_wrap_inline7360:10.13034pt::0.0pt::9.7213pt. +[75 + + +] +l2hSize :tex2html_wrap_inline7362:10.13034pt::0.0pt::13.85803pt. +[76 + + +] +l2hSize :tex2html_wrap_inline7364:10.13034pt::0.0pt::13.85803pt. +[77 + + +] +l2hSize :tex2html_wrap_inline7366:10.13034pt::0.0pt::13.85803pt. +[78 + + +] +l2hSize :tex2html_wrap_inline7368:10.13034pt::0.0pt::15.1963pt. +[79 + + +] +l2hSize :tex2html_wrap_inline7370:10.13034pt::0.0pt::19.33304pt. +[80 + + +] +l2hSize :tex2html_wrap_inline7374:10.13034pt::0.0pt::19.33304pt. +[81 + + +] +l2hSize :tex2html_wrap_inline7376:10.13034pt::0.0pt::15.1963pt. +[82 + + +] +l2hSize :tex2html_wrap_inline7378:10.13034pt::0.0pt::13.85803pt. +[83 + + +] +l2hSize :tex2html_wrap_inline7465:7.07185pt::7.07185pt::8.5167pt. +[84 + + +] +l2hSize :tex2html_wrap_inline8210:8.2125pt::8.2125pt::25.7242pt. +[85 + + +] +l2hSize :tex2html_wrap_inline8382:7.4181pt::0.0pt::14.80284pt. +[86 + + +] +l2hSize :tex2html_wrap_inline8384:7.4181pt::0.0pt::18.53345pt. +[87 + + +] +l2hSize :tex2html_wrap_inline8386:10.13034pt::10.13034pt::33.32474pt. +[88 + + +] +l2hSize :tex2html_wrap_inline8848:7.07185pt::0.0pt::27.12018pt. +[89 + + +] +l2hSize :tex2html_wrap_inline8993:7.60416pt::7.60416pt::15.99092pt. +[90 + + +] +l2hSize :tex2html_wrap_inline8995:7.60416pt::7.60416pt::17.19296pt. +[91 + + +] +l2hSize :tex2html_wrap_inline9003:7.60416pt::7.60416pt::5.2944pt. +[92 + + +] +l2hSize :tex2html_wrap_inline9812:9.12923pt::9.12923pt::30.82797pt. +[93 + + +] +l2hSize :tex2html_wrap_inline9814:9.12923pt::9.12923pt::35.07803pt. +[94 + + +] +l2hSize :tex2html_wrap_inline9967:7.60416pt::7.60416pt::52.25188pt. +[95 + + +] +l2hSize :tex2html_wrap_inline10116:7.4181pt::0.0pt::20.03448pt. +[96 + + +] +l2hSize :tex2html_wrap_inline10118:7.4181pt::0.0pt::20.03448pt. +[97 + + +] +l2hSize :tex2html_wrap_inline10191:9.44032pt::9.44032pt::38.18771pt. +[98 + + +] +l2hSize :tex2html_wrap_inline10601:7.48248pt::0.0pt::7.90834pt. +[99 + + +] +l2hSize :tex2html_wrap_inline10603:7.07185pt::0.0pt::9.37218pt. +[100 + + +] +l2hSize :tex2html_wrap_inline10605:7.07185pt::0.0pt::7.20874pt. +[101 + + +] +l2hSize :tex2html_wrap_inline10625:7.07185pt::7.07185pt::9.93608pt. +[102 + + +] +l2hSize :tex2html_wrap_inline10627:7.07185pt::7.07185pt::11.39606pt. +[103 + + +] +l2hSize :tex2html_wrap_inline10629:7.07185pt::7.07185pt::24.37381pt. +[104 + + +] +l2hSize :tex2html_wrap_inline10633:7.60416pt::7.60416pt::7.5256pt. +[105 + + +] +l2hSize :tex2html_wrap_inline10663:8.2125pt::8.2125pt::53.76514pt. +[106 + + +] +l2hSize :tex2html_wrap_inline10697:8.2125pt::8.2125pt::59.24014pt. +[107 + + +] +l2hSize :tex2html_wrap_inline11178:7.60416pt::7.60416pt::39.92438pt. +[108 + + +] +l2hSize :tex2html_wrap_inline11337:8.2125pt::8.2125pt::62.61017pt. +[109 + + +] +l2hSize :tex2html_wrap_inline11339:10.13034pt::0.0pt::41.23306pt. +[110 + + +] +l2hSize :tex2html_wrap_inline11594:8.2125pt::8.2125pt::37.06009pt. +[111 + + +] +l2hSize :tex2html_wrap_inline11608:10.13034pt::0.0pt::24.80804pt. +[112 + + +] +l2hSize :tex2html_wrap_inline11828:8.2125pt::8.2125pt::40.43898pt. +[113 + + +] +l2hSize :tex2html_wrap_inline11830:8.2125pt::8.2125pt::33.28798pt. +[114 + + +] +l2hSize :tex2html_wrap_inline12099:7.31305pt::0.0pt::7.04526pt. +[115 + + +] +l2hSize :tex2html_wrap_inline12101:7.60416pt::0.0pt::30.6371pt. +[116 + + +] +l2hSize :tex2html_wrap_inline12103:7.62646pt::0.0pt::15.70007pt. +[117 + + +] +l2hSize :tex2html_wrap_inline12105:7.48248pt::0.0pt::16.17027pt. +[118 + + +] +l2hSize :tex2html_wrap_inline13294:9.44032pt::0.0pt::56.2022pt. +[119 + + +] +l2hSize :tex2html_wrap_inline13534:7.07185pt::0.0pt::61.44164pt. +[120 + + +] +l2hSize :tex2html_wrap_inline13611:8.2125pt::8.2125pt::27.3749pt. +[121 + + +] +l2hSize :tex2html_wrap_inline14280:7.51291pt::0.0pt::11.95369pt. +[122 + + +] +l2hSize :tex2html_wrap_inline14410:7.07185pt::7.07185pt::15.08926pt. +[123 + + +] +l2hSize :tex2html_wrap_inline15250:10.13034pt::0.0pt::20.67131pt. +[124 + + +] +l2hSize :tex2html_wrap_inline15252:10.13034pt::0.0pt::19.33304pt. +[125 + + +] +l2hSize :tex2html_wrap_inline15578:10.13034pt::0.0pt::15.1963pt. +[126 + + +] +l2hSize :tex2html_wrap_inline15582:10.13034pt::0.0pt::9.7213pt. +[127 + + +] +l2hSize :tex2html_wrap_inline16974:9.12923pt::9.12923pt::67.61365pt. +[128 + + +] +l2hSize :tex2html_wrap_inline16980:7.07185pt::7.07185pt::5.66132pt. +[129 + + +] +l2hSize :tex2html_wrap_inline19044:10.13034pt::0.0pt::9.7213pt. +[130 + + +] +l2hSize :tex2html_wrap_inline19046:10.13034pt::0.0pt::9.7213pt. +[131 + + +] +l2hSize :tex2html_wrap_inline19048:10.13034pt::0.0pt::9.7213pt. +[132 + + +] +l2hSize :tex2html_wrap_inline19050:10.13034pt::0.0pt::15.1963pt. +[133 + + +] +l2hSize :tex2html_wrap_inline19052:10.13034pt::0.0pt::15.1963pt. +[134 + + +] +l2hSize :tex2html_wrap_inline19054:10.13034pt::0.0pt::15.1963pt. +[135 + + +] +l2hSize :tex2html_wrap_inline19056:10.13034pt::0.0pt::15.1963pt. +[136 + + +] +l2hSize :tex2html_wrap_inline19060:10.13034pt::0.0pt::13.85803pt. +[137 + + +] +l2hSize :tex2html_wrap_inline19064:8.2125pt::8.2125pt::117.10414pt. +[138 + + +] +l2hSize :tex2html_wrap_inline19834:7.62646pt::0.0pt::21.17508pt. +[139 + + +] +l2hSize :tex2html_wrap_inline20108:10.13034pt::0.0pt::9.7213pt. +[140 + + +] +l2hSize :tex2html_wrap_inline20114:10.13034pt::0.0pt::20.67131pt. +[141 + + +] +l2hSize :tex2html_wrap_inline20116:10.13034pt::0.0pt::26.14632pt. +[142 + + +] +l2hSize :tex2html_wrap_inline20952:7.07185pt::7.07185pt::30.96794pt. +[143 + + +] +l2hSize :tex2html_wrap_inline21527:8.2125pt::8.2125pt::33.95927pt. +[144 + + +] +l2hSize :tex2html_wrap_inline21604:7.07185pt::7.07185pt::46.40807pt. +[145 + + +] +l2hSize :tex2html_wrap_inline21862:7.07185pt::7.07185pt::6.59792pt. +[146 + + +] +l2hSize :tex2html_wrap_inline21866:7.07185pt::7.07185pt::13.9917pt. +[147 + + +] +l2hSize :tex2html_wrap_inline22333:9.12923pt::9.12923pt::108.07462pt. +[148 + + +] +l2hSize :tex2html_wrap_inline22335:7.60416pt::7.60416pt::5.59856pt. +[149 + + +] +l2hSize :tex2html_wrap_inline22337:7.60416pt::7.60416pt::14.72357pt. +[150 + + +] +l2hSize :tex2html_wrap_inline22343:7.60416pt::7.60416pt::23.24022pt. +[151 + + +] +l2hSize :tex2html_wrap_inline22345:9.12923pt::9.12923pt::27.99028pt. +[152 + + +] +l2hSize :tex2html_wrap_inline22353:9.12923pt::0.0pt::34.47794pt. +[153 + + +] +l2hSize :tex2html_wrap_inline22355:7.62646pt::0.0pt::15.70007pt. +[154 + + +] +l2hSize :tex2html_wrap_inline22357:9.12923pt::0.0pt::34.47794pt. +[155 + + +] +l2hSize :tex2html_wrap_inline22359:7.62646pt::0.0pt::27.25838pt. +[156 + + +] +l2hSize :tex2html_wrap_inline22363:7.62646pt::7.62646pt::35.89854pt. +[157 + + +] +l2hSize :tex2html_wrap_inline22365:10.13034pt::0.0pt::19.33304pt. +[158 + + +] +l2hSize :tex2html_wrap_inline22367:7.62646pt::7.62646pt::35.89854pt. +[159 + + +] +l2hSize :tex2html_wrap_inline22371:7.62646pt::7.62646pt::35.89854pt. +[160 + + +] +l2hSize :tex2html_wrap_inline22628:7.62646pt::0.0pt::25.43341pt. +[161 + + +] +l2hSize :tex2html_wrap_inline22638:7.62646pt::0.0pt::15.70007pt. +[162 + + +] +l2hSize :tex2html_wrap_inline22640:7.62646pt::0.0pt::15.70007pt. +[163 + + +] +l2hSize :tex2html_wrap_inline22642:7.62646pt::0.0pt::15.70007pt. +[164 + + +] +l2hSize :tex2html_wrap_inline22656:7.62646pt::7.62646pt::24.21677pt. +[165 + + +] +l2hSize :tex2html_wrap_inline22658:7.62646pt::7.62646pt::24.21677pt. +[166 + + +] +l2hSize :tex2html_wrap_inline22660:7.62646pt::0.0pt::21.17508pt. +[167 + + +] +l2hSize :tex2html_wrap_inline22666:7.07185pt::7.07185pt::21.19794pt. +[168 + + +] +l2hSize :tex2html_wrap_inline22678:9.12923pt::0.0pt::55.84569pt. +[169 + + +] +l2hSize :tex2html_wrap_inline22690:7.62646pt::0.0pt::10.22507pt. +[170 + + +] +l2hSize :tex2html_wrap_inline22698:9.12923pt::0.0pt::20.56676pt. +[171 + + +] +l2hSize :tex2html_wrap_inline22702:8.2125pt::8.2125pt::59.514pt. +[172 + + +] +l2hSize :tex2html_wrap_inline22706:7.60416pt::7.60416pt::6.77151pt. +[173 + + +] +l2hSize :tex2html_wrap_inline22933:7.62646pt::0.0pt::15.70007pt. +[174 + + +] +l2hSize :tex2html_wrap_inline22935:10.13034pt::0.0pt::19.33304pt. +[175 + + +] +l2hSize :tex2html_wrap_inline22947:7.62646pt::0.0pt::15.70007pt. +[176 + + +] +l2hSize :tex2html_wrap_inline22949:7.62646pt::0.0pt::27.25838pt. +[177 + + +] +l2hSize :tex2html_wrap_inline22955:10.13034pt::0.0pt::13.85803pt. +[178 + + +] +l2hSize :tex2html_wrap_inline22957:7.62646pt::0.0pt::15.70007pt. +[179 + + +] +l2hSize :tex2html_wrap_inline22959:8.2125pt::8.2125pt::48.445pt. +[180 + + +] +l2hSize :tex2html_wrap_inline22961:8.2125pt::8.2125pt::48.7492pt. +[181 + + +] +l2hSize :tex2html_wrap_inline23162:7.62646pt::0.0pt::15.70007pt. +[182 + + +] +l2hSize :tex2html_wrap_inline23164:7.62646pt::7.62646pt::35.89854pt. +[183 + + +] +l2hSize :tex2html_wrap_inline23168:7.60416pt::7.60416pt::16.9658pt. +[184 + + +] +l2hSize :tex2html_wrap_inline23172:10.13034pt::0.0pt::13.85803pt. +[185 + + +] +l2hSize :tex2html_wrap_inline23174:7.62646pt::0.0pt::15.70007pt. +[186 + + +] +l2hSize :tex2html_wrap_inline23176:10.13034pt::0.0pt::13.85803pt. +[187 + + +] +l2hSize :tex2html_wrap_inline23178:7.62646pt::0.0pt::15.70007pt. +[188 + + +] +l2hSize :tex2html_wrap_inline23180:10.13034pt::0.0pt::13.85803pt. +[189 + + +] +l2hSize :tex2html_wrap_inline23182:7.62646pt::0.0pt::15.70007pt. +[190 + + +] +l2hSize :tex2html_wrap_inline23186:7.62646pt::0.0pt::15.70007pt. +[191 + + +] +l2hSize :tex2html_wrap_inline23188:10.13034pt::0.0pt::9.7213pt. +[192 + + +] +l2hSize :tex2html_wrap_inline23190:7.62646pt::0.0pt::15.70007pt. +[193 + + +] +l2hSize :tex2html_wrap_inline23194:7.62646pt::0.0pt::15.70007pt. +[194 + + +] +l2hSize :tex2html_wrap_inline23196:10.13034pt::0.0pt::15.1963pt. +[195 + + +] +l2hSize :tex2html_wrap_inline23198:7.62646pt::0.0pt::15.70007pt. +[196 + + +] +l2hSize :tex2html_wrap_inline23200:10.13034pt::0.0pt::20.67131pt. +[197 + + +] +l2hSize :tex2html_wrap_inline23202:7.62646pt::0.0pt::15.70007pt. +[198 + + +] +l2hSize :tex2html_wrap_inline23204:10.13034pt::0.0pt::20.67131pt. +[199 + + +] +l2hSize :tex2html_wrap_inline23206:7.62646pt::0.0pt::15.70007pt. +[200 + + +] +l2hSize :tex2html_wrap_inline23208:10.13034pt::0.0pt::20.67131pt. +[201 + + +] +l2hSize :tex2html_wrap_inline23212:10.13034pt::0.0pt::26.14632pt. +[202 + + +] +l2hSize :tex2html_wrap_inline23214:7.62646pt::0.0pt::15.70007pt. +[203 + + +] +l2hSize :tex2html_wrap_inline23216:10.13034pt::0.0pt::26.14632pt. +[204 + + +] +l2hSize :tex2html_wrap_inline23220:7.62646pt::0.0pt::15.70007pt. +[205 + + +] +l2hSize :tex2html_wrap_inline23222:10.13034pt::0.0pt::26.14632pt. +[206 + + +] +l2hSize :tex2html_wrap_inline23228:7.62646pt::7.62646pt::35.89854pt. +[207 + + +] +l2hSize :tex2html_wrap_inline23469:7.62646pt::7.62646pt::35.89854pt. +[208 + + +] +l2hSize :tex2html_wrap_inline23471:7.62646pt::7.62646pt::35.89854pt. +[209 + + +] +l2hSize :displaymath23457:31.00029pt::0.0pt::451.0pt. +[210 + + +] +l2hSize :tex2html_wrap_inline23475:7.62646pt::7.62646pt::73.69403pt. +[211 + + +] +l2hSize :tex2html_wrap_inline23495:10.13034pt::0.0pt::13.85803pt. +[212 + + +] +l2hSize :tex2html_wrap_inline23499:10.13034pt::0.0pt::13.85803pt. +[213 + + +] +l2hSize :tex2html_wrap_inline23503:10.13034pt::0.0pt::13.85803pt. +[214 + + +] +l2hSize :tex2html_wrap_inline23507:10.13034pt::0.0pt::13.85803pt. +[215 + + +] +l2hSize :tex2html_wrap_inline23511:10.13034pt::0.0pt::13.85803pt. +[216 + + +] +l2hSize :tex2html_wrap_inline23515:10.13034pt::0.0pt::13.85803pt. +[217 + + +] +l2hSize :tex2html_wrap_inline23523:10.13034pt::0.0pt::15.1963pt. +[218 + + +] +l2hSize :tex2html_wrap_inline23527:10.13034pt::0.0pt::15.1963pt. +[219 + + +] +l2hSize :tex2html_wrap_inline23531:10.13034pt::0.0pt::15.1963pt. +[220 + + +] +l2hSize :tex2html_wrap_inline23537:10.13034pt::0.0pt::20.67131pt. +[221 + + +] +l2hSize :tex2html_wrap_inline23720:9.44032pt::0.0pt::41.48557pt. +[222 + + +] +l2hSize :tex2html_wrap_inline23722:9.44032pt::0.0pt::32.47714pt. +[223 + + +] +l2hSize :tex2html_wrap_inline23896:9.44032pt::9.44032pt::97.5711pt. +[224 + + +] +l2hSize :tex2html_wrap_inline23995:9.52922pt::9.52922pt::86.78186pt. +[225 + + +] +l2hSize :tex2html_wrap_inline24798:7.07185pt::7.07185pt::15.08926pt. +[226 + + +] +l2hSize :tex2html_wrap_inline24800:7.07185pt::7.07185pt::30.78673pt. +[227 + + +] +l2hSize :tex2html_wrap_inline24802:7.07185pt::7.07185pt::29.57008pt. +[228 + + +] +l2hSize :tex2html_wrap_inline24806:7.07185pt::7.07185pt::34.20212pt. +[229 + + +] +l2hSize :tex2html_wrap_inline25275:8.2125pt::8.2125pt::45.81715pt. +[230 + + +] +l2hSize :tex2html_wrap_inline25277:8.2125pt::8.2125pt::23.8652pt. +[231 + + +] +l2hSize :tex2html_wrap_inline26731:7.62646pt::0.0pt::14.90933pt. +[232 + + +] +l2hSize :tex2html_wrap_inline26733:7.62646pt::0.0pt::15.70007pt. +[233 + + +] +l2hSize :tex2html_wrap_inline27323:7.07185pt::7.07185pt::21.843pt. +[234 + + +] +l2hSize :tex2html_wrap_inline27383:7.62646pt::0.0pt::15.70007pt. +[235 + + +] +l2hSize :tex2html_wrap_inline27391:7.62646pt::7.62646pt::18.74176pt. +[236 + + +] +l2hSize :tex2html_wrap_inline27397:9.52922pt::0.0pt::73.81409pt. +[237 + + +] +l2hSize :tex2html_wrap_inline27464:8.2125pt::8.2125pt::28.3939pt. +[238 + + +] +l2hSize :tex2html_wrap_inline27478:8.2125pt::8.2125pt::64.43513pt. +[239 + + +] +l2hSize :tex2html_wrap_inline27484:7.51291pt::0.0pt::9.65723pt. +[240 + + +] +l2hSize :tex2html_wrap_inline27486:7.51291pt::0.0pt::15.81656pt. +[241 + + +] +l2hSize :tex2html_wrap_inline27488:7.51291pt::0.0pt::15.81656pt. +[242 + + +] +l2hSize :tex2html_wrap_inline27490:7.51291pt::7.51291pt::61.97366pt. +[243 + + +] +l2hSize :tex2html_wrap_inline27492:8.2125pt::8.2125pt::60.757pt. +[244 + + +] +l2hSize :tex2html_wrap_inline27494:7.60416pt::0.0pt::13.99544pt. +[245 + + +] +l2hSize :tex2html_wrap_inline27498:7.60416pt::0.0pt::60.23245pt. +[246 + + +] +l2hSize :tex2html_wrap_inline27504:7.60416pt::0.0pt::41.02058pt. +[247 + + +] +l2hSize :tex2html_wrap_inline27506:7.60416pt::0.0pt::39.80392pt. +[248 + + +] +l2hSize :tex2html_wrap_inline27512:7.60416pt::0.0pt::30.48125pt. +[249 + + +] +l2hSize :tex2html_wrap_inline27514:9.12923pt::9.12923pt::57.07048pt. +[250 + + +] +l2hSize :tex2html_wrap_inline27518:7.07185pt::0.0pt::8.5167pt. +[251 + + +] +l2hSize :tex2html_wrap_inline27524:10.20264pt::10.20264pt::44.62119pt. +[252 + + +] +l2hSize :tex2html_wrap_inline27750:7.60416pt::7.60416pt::18.02567pt. +[253 + + +] +l2hSize :tex2html_wrap_inline27752:9.44032pt::9.44032pt::28.45444pt. +[254 + + +] +l2hSize :figure27550:643.66522pt::0.0pt::451.0pt. +[255 + + +] +l2hSize :tex2html_wrap_inline27878:7.62646pt::0.0pt::20.38434pt. +[256 + + +] +l2hSize :tex2html_wrap_inline27888:7.07185pt::0.0pt::4.44464pt. +[257 + + +] +l2hSize :tex2html_wrap_inline27890:10.13034pt::0.0pt::30.28305pt. +[258 + + +] +l2hSize :tex2html_wrap_inline27892:8.2125pt::8.2125pt::32.84998pt. +[259 + + +] +l2hSize :tex2html_wrap_inline27894:7.62646pt::0.0pt::14.90933pt. +[260 + + +] +l2hSize :tex2html_wrap_inline27923:10.13034pt::0.0pt::15.1963pt. +[261 + + +] +l2hSize :tex2html_wrap_inline27927:9.52922pt::0.0pt::68.33908pt. +[262 + + +] +l2hSize :tex2html_wrap_inline27929:10.13034pt::10.13034pt::66.86673pt. +[263 + + +] +l2hSize :tex2html_wrap_inline27959:8.2125pt::8.2125pt::34.6663pt. +[264 + + +] +l2hSize :tex2html_wrap_inline28022:10.13034pt::0.0pt::19.33304pt. +[265 + + +] +l2hSize :tex2html_wrap_inline28106:7.07185pt::7.07185pt::35.67386pt. +[266 + + +] +l2hSize :tex2html_wrap_inline28108:7.4181pt::0.0pt::41.93451pt. +[267 + + +] +l2hSize :tex2html_wrap_inline28112:7.4181pt::0.0pt::41.93451pt. +[268 + + +] +l2hSize :tex2html_wrap_inline28114:7.31305pt::7.31305pt::36.30606pt. +[269 + + +] +l2hSize :tex2html_wrap_inline28116:7.4181pt::0.0pt::41.93451pt. +[270 + + +] +l2hSize :tex2html_wrap_inline28118:8.2125pt::8.2125pt::64.15625pt. +[271 + + +] +l2hSize :tex2html_wrap_inline28120:7.4181pt::0.0pt::41.93451pt. +[272 + + +] +l2hSize :tex2html_wrap_inline28122:7.07185pt::7.07185pt::37.52272pt. +[273 + + +] +l2hSize :tex2html_wrap_inline28124:7.4181pt::0.0pt::41.93451pt. +[274 + + +] +l2hSize :tex2html_wrap_inline28126:8.2125pt::8.2125pt::55.03122pt. +[275 + + +] +l2hSize :tex2html_wrap_inline28128:7.07185pt::7.07185pt::36.10065pt. +[276 + + +] +l2hSize :tex2html_wrap_inline28130:10.13034pt::0.0pt::35.75806pt. +[277 + + +] +l2hSize :tex2html_wrap_inline28134:10.13034pt::0.0pt::35.75806pt. +[278 + + +] +l2hSize :tex2html_wrap_inline28136:8.2125pt::8.2125pt::45.43098pt. +[279 + + +] +l2hSize :tex2html_wrap_inline28138:10.13034pt::0.0pt::35.75806pt. +[280 + + +] +l2hSize :tex2html_wrap_inline28140:7.31305pt::7.31305pt::36.30606pt. +[281 + + +] +l2hSize :tex2html_wrap_inline28142:10.13034pt::0.0pt::35.75806pt. +[282 + + +] +l2hSize :tex2html_wrap_inline28146:10.13034pt::0.0pt::35.75806pt. +[283 + + +] +l2hSize :tex2html_wrap_inline28148:7.60416pt::0.0pt::27.24184pt. +[284 + + +] +l2hSize :tex2html_wrap_inline28214:7.07185pt::0.0pt::18.60356pt. +[285 + + +] +l2hSize :tex2html_wrap_inline28216:9.52922pt::0.0pt::68.33908pt. +[286 + + +] +l2hSize :tex2html_wrap_inline28218:7.60416pt::0.0pt::16.83937pt. +[287 + + +] +l2hSize :tex2html_wrap_inline28220:10.13034pt::10.13034pt::66.86673pt. +[288 + + +] +l2hSize :tex2html_wrap_inline28222:7.07185pt::7.07185pt::24.11555pt. +[289 + + +] +l2hSize :tex2html_wrap_inline28224:7.4181pt::7.4181pt::39.50119pt. +[290 + + +] +l2hSize :tex2html_wrap_inline28228:7.07185pt::7.07185pt::22.71738pt. +[291 + + +] +l2hSize :tex2html_wrap_inline28230:10.13034pt::10.13034pt::33.32474pt. +[292 + + +] +l2hSize :tex2html_wrap_inline28234:10.13034pt::0.0pt::24.80804pt. +[293 + + +] +l2hSize :tex2html_wrap_inline28274:10.13034pt::0.0pt::19.33304pt. +[294 + + +] +l2hSize :tex2html_wrap_inline28276:10.13034pt::0.0pt::19.33304pt. +[295 + + +] +l2hSize :tex2html_wrap_inline28278:7.62646pt::0.0pt::15.70007pt. +[296 + + +] +l2hSize :tex2html_wrap_inline28282:7.62646pt::7.62646pt::34.36441pt. +[297 + + +] +l2hSize :tex2html_wrap_inline28386:7.60416pt::0.0pt::5.44458pt. +[298 + + +] +l2hSize :displaymath28366:14.51251pt::0.0pt::451.0pt. +[299 + + +] +l2hSize :tex2html_wrap_inline28394:7.60416pt::7.60416pt::50.96434pt. +[300 + + +] +l2hSize :tex2html_wrap_inline28408:7.62646pt::0.0pt::14.90933pt. +[301 + + +] +l2hSize :displaymath28367:15.72917pt::0.0pt::451.0pt. +[302 + + +] +l2hSize :tex2html_wrap_inline28412:7.60416pt::7.60416pt::17.91302pt. +[303 + + +] +l2hSize :tex2html_wrap_inline28420:10.13034pt::0.0pt::15.1963pt. +[304 + + +] +l2hSize :tex2html_wrap_inline28422:10.13034pt::10.13034pt::27.84973pt. +[305 + + +] +l2hSize :displaymath28368:27.78561pt::0.0pt::451.0pt. +[306 + + +] +l2hSize :tex2html_wrap_inline28444:7.07185pt::7.07185pt::32.63718pt. +[307 + + +] +l2hSize :tex2html_wrap_inline28549:9.52922pt::0.0pt::62.86407pt. +[308 + + +] +l2hSize :tex2html_wrap_inline28551:9.52922pt::0.0pt::62.86407pt. +[309 + + +] +l2hSize :tex2html_wrap_inline28555:7.60416pt::7.60416pt::39.40604pt. +[310 + + +] +l2hSize :tex2html_wrap_inline28561:7.4181pt::0.0pt::30.9845pt. +[311 + + +] +l2hSize :tex2html_wrap_inline28567:7.4181pt::0.0pt::30.9845pt. +[312 + + +] +l2hSize :tex2html_wrap_inline28569:7.4181pt::0.0pt::30.9845pt. +[313 + + +] +l2hSize :tex2html_wrap_inline28571:7.48248pt::7.48248pt::76.49782pt. +[314 + + +] +l2hSize :tex2html_wrap_inline28573:7.48248pt::0.0pt::17.03336pt. +[315 + + +] +l2hSize :tex2html_wrap_inline28650:10.13034pt::0.0pt::9.7213pt. +[316 + + +] +l2hSize :tex2html_wrap_inline28656:7.07185pt::7.07185pt::24.94171pt. +[317 + + +] +l2hSize :tex2html_wrap_inline28664:7.62646pt::0.0pt::10.22507pt. +[318 + + +] +l2hSize :tex2html_wrap_inline28666:10.13034pt::0.0pt::9.7213pt. +[319 + + +] +l2hSize :tex2html_wrap_inline28668:9.52922pt::0.0pt::31.05571pt. +[320 + + +] +l2hSize :tex2html_wrap_inline28728:7.48248pt::7.48248pt::52.47244pt. +[321 + + +] +l2hSize :tex2html_wrap_inline28740:7.48248pt::7.48248pt::56.62431pt. +[322 + + +] +l2hSize :tex2html_wrap_inline28752:7.48248pt::7.48248pt::37.80916pt. +[323 + + +] +l2hSize :tex2html_wrap_inline28769:7.07185pt::0.0pt::22.50832pt. +[324 + + +] +l2hSize :tex2html_wrap_inline28861:7.48248pt::7.48248pt::51.50961pt. +[325 + + +] +l2hSize :tex2html_wrap_inline28863:7.48248pt::7.48248pt::46.0346pt. +[326 + + +] +l2hSize :tex2html_wrap_inline28865:7.48248pt::7.48248pt::51.50961pt. +[327 + + +] +l2hSize :tex2html_wrap_inline28867:7.48248pt::7.48248pt::51.50961pt. +[328 + + +] +l2hSize :tex2html_wrap_inline28869:7.07185pt::0.0pt::35.24144pt. +[329 + + +] +l2hSize :tex2html_wrap_inline28871:7.07185pt::7.07185pt::46.2333pt. +[330 + + +] (images.aux) ) +Here is how much of TeX's memory you used: + 351 strings out of 10906 + 3619 string characters out of 71914 + 61584 words of memory out of 262141 + 3274 multiletter control sequences out of 9500 + 7308 words of font info for 26 fonts, out of 150000 for 255 + 14 hyphenation exceptions out of 607 + 21i,13n,21p,242b,498s stack positions out of 300i,40n,60p,3000b,4000s + +Output written on images.dvi (330 pages, 51052 bytes). diff --git a/src/slalib/sun67.htx/images.pl b/src/slalib/sun67.htx/images.pl new file mode 100644 index 0000000..498f422 --- /dev/null +++ b/src/slalib/sun67.htx/images.pl @@ -0,0 +1,1686 @@ +# LaTeX2HTML 97.1 (release) (July 13th, 1997) +# Associate images original text with physical files. + + +$key = q/{_inline}1hspace-0.05em^'hspace-0.1em'hspace-0.4em.74{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.74$|; + +$key = q/{_inline}cosdeltaE{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\cos \delta E$|; + +$key = q/{_inline}0^rmshspace-0.3em.03{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.03$|; + +$key = q/{_inline}0leqx<1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0 \leq x < 1$|; + +$key = q/{_inline}zeta=80^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta=80^\circ$|; + +$key = q/{_inline}-75^circ,59^',27^''.2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$-75^{\circ}\,59^{'}\,27^{''}.2$|; + +$key = q/{_inline}150hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$150\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}2hspace-0.05em^'hspace-0.1em'hspace-0.4em.3{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$2\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$|; + +$key = q/{_inline}1hspace-0.05em^'hspace-0.1em'hspace-0.4em.6{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.6$|; + +$key = q/{displaymath}zeta_vacapproxzeta_obs+Atanzeta_obs+Btan^3zeta_obs{displaymath}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|\begin{displaymath}
+\zeta _{vac} \approx \zeta _{obs}
+ + A \tan \zeta _{obs}
+ + B \tan ^{3}\zeta _{obs} \end{displaymath}|; + +$key = q/{_inline}1000times20{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1000\times20$|; + +$key = q/{_inline}times3602pi{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\times 360/2\pi$|; + +$key = q/{_inline}21hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$21\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}12^h,07^m,58^s.09{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$12^{h}\,07^{m}\,58^{s}.09$|; + +$key = q/{_inline}81^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$81^\circ$|; + +$key = q/{_inline}omega{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\omega$|; + +$key = q/{_inline}30^rmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$30^{\rm m}$|; + +$key = q/{_inline}89^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$89^\circ$|; + +$key = q/{displaymath}zeta_obsapproxzeta_vac-fracAtanzeta_vac+Btan^3zeta_vac1+(A+3Btan^2zeta_vac)sec^2zeta_vac{displaymath}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|\begin{displaymath}
+\zeta _{obs} \approx \zeta _{vac}
+ - \frac{A \tan \zeta _{va...
+ ...
+ {1 + ( A + 3 B \tan ^{2}\zeta _{vac} ) \sec ^{2}\zeta _{vac}}\end{displaymath}|; + +$key = q/{_inline}1^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1^\circ$|; + +$key = q/{_inline}=Deltapsicosepsilon{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$=\Delta\psi\cos\epsilon$|; + +$key = q/{_inline}(3times3){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$(3\times3)$|; + +$key = q/{_inline}epsilon{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\epsilon$|; + +$key = q/{_inline}290^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$290^\circ$|; + +$key = q/{_inline}+1^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$+1^{\circ}$|; + +$key = q/{_inline}20,murmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$20\,\mu{\rm m}$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.6{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.6$|; + +$key = q/{_inline}7hspace-0.05em^'hspace-0.1em'hspace-0.4em.1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$7\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$|; + +$key = q/{_inline}C_3!=!-10.0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$C_3\!=\!-10.0$|; + +$key = q/{_inline}~sinalpha+({_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$~\sin \alpha +
+ ($|; + +$key = q/{_inline}xi{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\xi$|; + +$key = q/{_inline}1100hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1100\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}[lambda,phi]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\lambda,\phi]$|; + +$key = q/{_inline}30hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$30\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}1.0027379cdots{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1.0027379\cdots$|; + +$key = q/{_inline}90^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$90^{\circ}$|; + +$key = q/{_inline}14hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$14\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}rho=r(1+cr^2){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\rho = r (1 + c r^{2})$|; + +$key = q/{_inline}pmn{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\pm n$|; + +$key = q/{_inline}bfD{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\bf D}$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.24{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.24$|; + +$key = q/{_inline}0^rmshspace-0.3em.015869{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.015869$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.43549{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.43549$|; + +$key = q/{_inline}[,Deltax,Deltay,Deltaz,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,\Delta x,\Delta y, \Delta z\,]$|; + +$key = q/{_inline}86hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$86\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}(0leqe<1){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$( 0 \leq e < 1 )$|; + +$key = q/{_inline}0^rmh{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm h}$|; + +$key = q/{_inline}~cosalpha-{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$~\cos \alpha
+ -$|; + +$key = q/{_inline}[theta,phi,dottheta,dotphi]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\theta,\phi,\dot{\theta},\dot{\phi}]$|; + +$key = q/{_inline}1hspace-0.05em^'hspace-0.1em'hspace-0.4em.0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.0$|; + +$key = q/{_inline}nu=rho_wrho_s{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\nu=\rho_w/\rho_s$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.3{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$|; + +$key = q/{_inline}varpi=Omega+omega{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\varpi = \Omega + \omega$|; + +$key = q/{_inline}6hspace-0.05em^'hspace-0.1em'hspace-0.4em.1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$6\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$|; + +$key = q/{_inline}mu_delta,=+{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\mu_\delta\,=+$|; + +$key = q/{_inline}920hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$920\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}b^I!I=0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$b^{I\!I}=0$|; + +$key = q/{_inline}x'=x_1+rmXZ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$x' = x_{1} + {\rm XZ}$|; + +$key = q/{_inline}mu_alpha={_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\mu_\alpha=$|; + +$key = q/{_inline}rmbfr_0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\rm \bf r}_0$|; + +$key = q/{_inline}zeta_vac{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta _{vac}$|; + +$key = q/{_inline}86^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$86^\circ$|; + +$key = q/{_inline}y'''=+x''sinrmPERP2+y''cosrmPERP2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$y''' = + x'' \sin {\rm PERP}/2 + y'' \cos {\rm PERP}/2$|; + +$key = q/{_inline}C_2!=!-2.0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$C_2\!=\!-2.0$|; + +$key = q/{_inline}0.0065^circm^-1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0.0065^\circ m^{-1}$|; + +$key = q/{_inline}alpha=18^rmh,delta=+30^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\alpha=18^{\rm h},\delta=+30^{\circ}$|; + +$key = q/{_inline}[mu_alpha,mu_delta]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\mu_\alpha,\mu_\delta]$|; + +$key = q/{_inline}5^rmh,25^rmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$5^{\rm h}\,25^{\rm m}$|; + +$key = q/{figure}centertabular|cccccc|hline&&&&&hspace5em&hspace5em&hspace5em&hspace5em&halloftheprecessionandE-termscorrectionsaresuperfluous.{figure}MSF=1.5;FSF=1;AAT;/; +$cached_env_img{$key} = q|\begin{figure}
+\begin{center}
+\begin{tabular}
+{\vert cccccc\vert} \hline
+& & & &...
+ ...2000, all of the precession and E-terms corrections
+are superfluous.\end{figure}|; + +$key = q/{_inline}~sinalpha-{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$~\sin \alpha
+ -$|; + +$key = q/{_inline}equiv123{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\equiv123$|; + +$key = q/{_inline}3hspace-0.05em^'hspace-0.1em'hspace-0.4em.7{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$3\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.7$|; + +$key = q/{_inline}12^circ,34^',56^''.7{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$12^{\circ}\,34^{'}\,56^{''}.7$|; + +$key = q/{_inline}y'=y_1+rmYZ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$y' = y_{1} + {\rm YZ}$|; + +$key = q/{_inline}+0hspace-0.05em^'hspace-0.1em'hspace-0.4em.103{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$+0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.103$|; + +$key = q/{_inline}=93^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$=93^\circ$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.0001{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.0001$|; + +$key = q/{_inline}[x_e,y_e,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[x_{e},y_{e}\,]$|; + +$key = q/{_inline}[,0,,1,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,0,\,1\,]$|; + +$key = q/{_inline}20hspace-0.05em^'hspace-0.1em'hspace-0.4em.5{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$20\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$|; + +$key = q/{_inline}theta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\theta$|; + +$key = q/{_inline}zeta<80^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta<80^{\circ}$|; + +$key = q/{_inline}0^rmshspace-0.3em.000340{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.000340$|; + +$key = q/{_inline}deltaEcosE{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\delta E \cos E$|; + +$key = q/{_inline}[x_m,y_m,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[x_{m},y_{m}\,]$|; + +$key = q/{_inline}-0hspace-0.05em^'hspace-0.1em'hspace-0.4em.06{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$-0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.06$|; + +$key = q/{_inline}340hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$340\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}l^I!I,b^I!I{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$l^{I\!I},b^{I\!I}$|; + +$key = q/{_inline}20^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$20^\circ$|; + +$key = q/{_inline}_j)]cdot({_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$_{j})]
+ \cdot ($|; + +$key = q/{_inline}times{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\times$|; + +$key = q/{_inline}20hspace-0.05em^'hspace-0.1em'hspace-0.4em.49552{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$20\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.49552$|; + +$key = q/{_inline}tan^3zeta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\tan^{3} \zeta$|; + +$key = q/{_inline}E=90^circ-zeta_true{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$E=90^\circ-\zeta_{true}$|; + +$key = q/{_inline}83^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$83^\circ$|; + +$key = q/{_inline}0^rmshspace-0.3em.9{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.9$|; + +$key = q/{_inline}(0leqeleq10){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$( 0 \leq e \leq 10 )$|; + +$key = q/{_inline}17hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$17\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}0.4,murmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0.4\,\mu{\rm m}$|; + +$key = q/{_inline}3^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$3^{\circ}$|; + +$key = q/{_inline}20^rms{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$20^{\rm s}$|; + +$key = q/{_inline}1hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}zeta=70^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta=70^\circ$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.001{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.001$|; + +$key = q/{_inline}DeltarmT{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\Delta {\rm T}$|; + +$key = q/{_inline}pm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\pm$|; + +$key = q/{_inline}C_1!=!+50.0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$C_1\!=\!+50.0$|; + +$key = q/{_inline}l^I!I=90^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$l^{I\!I}=90^{\circ}$|; + +$key = q/{_inline}50^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$50^\circ$|; + +$key = q/{_inline}[,theta,phi~]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,\theta,\phi~]$|; + +$key = q/{_inline}x!pm!n{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$x\!\pm\!n$|; + +$key = q/{_inline}mu_delta={_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\mu_\delta=$|; + +$key = q/{_inline}3times3{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$3\times3$|; + +$key = q/{_inline}50hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$50\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}1.0,murmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1.0\,\mu{\rm m}$|; + +$key = q/{_inline}92^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$92^\circ$|; + +$key = q/{_inline}18hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$18\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}0.7,murmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0.7\,\mu{\rm m}$|; + +$key = q/{_inline}timesn{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\times n$|; + +$key = q/{_inline}rmMJD=(rmJD-2400000.5{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\rm MJD} = ({\rm JD} - 2400000.5$|; + +$key = q/{_inline}0^circhspace-0.37em.hspace0.02em5{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\circ}
+ \hspace{-0.37em}.\hspace{0.02em}5$|; + +$key = q/{_inline}tan^-14{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\tan^{-1} 4$|; + +$key = q/{_inline}0^rmshspace-0.3em.01{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.01$|; + +$key = q/{_inline}100hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$100\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}2hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$2\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}[,xi,eta,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,\xi,\eta\,]$|; + +$key = q/{_inline}00^h,00^m,00^s.0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$00^{h}\,00^{m}\,00^{s}.0$|; + +$key = q/{_inline}0!-!pi{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\!-\!\pi$|; + +$key = q/{_inline}280^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$280^\circ$|; + +$key = q/{_inline}beta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\beta$|; + +$key = q/{_inline}0^rmshspace-0.3em.000083{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.000083$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.00510{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00510$|; + +$key = q/{_inline}zeta=87^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta = 87^{\circ}$|; + +$key = q/{_inline}90^circ-delta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$90^\circ-\delta$|; + +$key = q/{_inline}2murmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$2\mu{\rm m}$|; + +$key = q/{_inline}{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$<{\bf V1}+{\bf D}\gt$|; + +$key = q/{_inline}5hspace-0.05em^'hspace-0.1em'hspace-0.4em.8{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$5\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.8$|; + +$key = q/{_inline}25^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$25^\circ$|; + +$key = q/{_inline}80^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$80^\circ$|; + +$key = q/{_inline}pmpi2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\pm\pi/2$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.01{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.01$|; + +$key = q/{_inline}rho{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\rho$|; + +$key = q/{_inline}152pi=2.3873241463784300365{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$15/{2\pi} = 2.3873241463784300365$|; + +$key = q/{_inline}2pi{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$2\pi$|; + +$key = q/{_inline}43hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$43\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}sim20{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\sim20$|; + +$key = q/{_inline}[,alpha,delta,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,\alpha,\delta\,]$|; + +$key = q/{_inline}dotalpha{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\dot{\alpha}$|; + +$key = q/{_inline}0^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\circ}$|; + +$key = q/{_inline}88^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$88^\circ$|; + +$key = q/{_inline}bfV1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\bf V1}$|; + +$key = q/{_inline}tan^-11{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\tan^{-1} 1$|; + +$key = q/{_inline}0^circhspace-0.37em.hspace0.02em2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\circ}
+ \hspace{-0.37em}.\hspace{0.02em}2$|; + +$key = q/{_inline}-19^circ,44^',37^''.1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$-19^{\circ}\,44^{'}\,37^{''}.1$|; + +$key = q/{_inline}cdot~[diag(1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\cdot~[diag(1/$|; + +$key = q/{_inline}alpha=0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\alpha=0$|; + +$key = q/{_inline}~cosalpha)sindelta-{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$~\cos \alpha ) \sin \delta
+ -$|; + +$key = q/{_inline}zeta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta$|; + +$key = q/{_inline}3hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$3\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}tanzeta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\tan \zeta$|; + +$key = q/{_inline}0^rmshspace-0.3em.000105{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.000105$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.4{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.4$|; + +$key = q/{_inline}~sinalpha)secdelta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$~\sin \alpha ) \sec \delta $|; + +$key = q/{_inline}-1^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$-1^{\circ}$|; + +$key = q/{_inline}times10^-5{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\times10^{-5}$|; + +$key = q/{_inline}C_4!=!+25.0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$C_4\!=\!+25.0$|; + +$key = q/{_inline}60hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$60\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}76^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$76^\circ$|; + +$key = q/{_inline}x'''=+x''cosrmPERP2+y''sinrmPERP2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$x''' = + x'' \cos {\rm PERP}/2 + y'' \sin {\rm PERP}/2$|; + +$key = q/{_inline}deltaE{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\delta E$|; + +$key = q/{_inline}times2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\times 2 / $|; + +$key = q/{_inline}zeta_obs{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta_{obs}$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$|; + +$key = q/{_inline}4hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$4\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}0^rmshspace-0.3em.0016{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.0016$|; + +$key = q/{_inline}zeta=84^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta=84^\circ$|; + +$key = q/{_inline}100mum{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$100\mu m$|; + +$key = q/{_inline}sigma=5.0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\sigma=5.0$|; + +$key = q/{_inline}circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\circ}$|; + +$key = q/{_inline}[x_1,y_1,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[x_{1},y_{1}\,]$|; + +$key = q/{_inline}L=varpi+M{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$L = \varpi + M$|; + +$key = q/{_inline}16^h,09^m,55^s.13{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$16^{h}\,09^{m}\,55^{s}.13$|; + +$key = q/{_inline}times(2pi86400)^2times(3602pi){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\times (2\pi/86400)^2 \times (360/2\pi)$|; + +$key = q/{_inline}xi,eta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\xi,\eta$|; + +$key = q/{_inline}Deltazeta=atanzeta+btan^3zeta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$|; + +$key = q/{_inline}23^circhspace-0.37em.hspace0.02em5{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$23^{\circ}
+ \hspace{-0.37em}.\hspace{0.02em}5$|; + +$key = q/{_inline}rightarrow{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\rightarrow$|; + +$key = q/{_inline}pmn.nxpmn{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\pm n.n x \pm n$|; + +$key = q/{_inline}cdot{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\cdot$|; + +$key = q/{_inline}85^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$85^\circ$|; + +$key = q/{_inline}45hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$45\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}pm3{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\pm3$|; + +$key = q/{_inline}0^rmshspace-0.3em.0013{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.0013$|; + +$key = q/{_inline}zeta<70^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta<70^{\circ}$|; + +$key = q/{_inline}tan^5{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\tan^5$|; + +$key = q/{_inline}5hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$5\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}~sinalpha+{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$~\sin \alpha
+ +$|; + +$key = q/{_inline}620hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$620\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}ntimesn{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$n \times n$|; + +$key = q/{_inline}Deltazeta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\Delta \zeta$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.00125{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00125$|; + +$key = q/{_inline}10^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$10^{\circ}$|; + +$key = q/{_inline}varpi{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\varpi$|; + +$key = q/{_inline}lambda,beta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\lambda,\beta$|; + +$key = q/{_inline}0.3,murmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0.3\,\mu{\rm m}$|; + +$key = q/{_inline}pm100{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\pm100$|; + +$key = q/{_inline}1900hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1900\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}times10^-10{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\times10^{-10}$|; + +$key = q/{_inline}M_odot=1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$M_\odot = 1$|; + +$key = q/{_inline}Deltaalpha{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\Delta\alpha$|; + +$key = q/{displaymath}Deltazeta=Fleft(frac0^circhspace-0.37em.hspace0.02em55445-0^circhsp-0.37em.hspace0.02em00202E^21+0.28385E+0.02390E^2right){displaymath}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|\begin{displaymath}
+\Delta \zeta = F \left(
+ \frac{0^\circ\hspace{-0.37em}.\hspa...
+ ...hspace{0.02em}00202 E^2}
+ {1 + 0.28385 E +0.02390 E^2} \right) \end{displaymath}|; + +$key = q/{_inline}times(2pi86400)times(3602pi){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\times (2\pi/86400) \times (360/2\pi)$|; + +$key = q/{_inline}zeta<45^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta<45^{\circ}$|; + +$key = q/{_inline}[,Az,El~]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,Az,El~]$|; + +$key = q/{_inline}6hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$6\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}^Tcdot{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$^{T}\cdot$|; + +$key = q/{_inline}3hspace-0.05em^'hspace-0.1em'hspace-0.4em.2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$3\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$|; + +$key = q/{_inline}[x_p,y_p,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[x_{p},y_{p}\,]$|; + +$key = q/{_inline}[x_2,y_2,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[x_{2},y_{2}\,]$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.00158{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00158$|; + +$key = q/{_inline}x_2=+x'''cosrmORIENT+y'''sinrmORIENT{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$x_{2} = + x''' \cos {\rm ORIENT} +
+ y''' \sin {\rm ORIENT}$|; + +$key = q/{_inline}61^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$61^\circ$|; + +$key = q/{_inline}y_2=-x'''sinrmORIENT+y'''cosrmORIENT{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$y_{2} = - x''' \sin {\rm ORIENT} +
+ y''' \cos {\rm ORIENT}$|; + +$key = q/{_inline}82^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$82^\circ$|; + +$key = q/{_inline}0!-!2pi{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\!-\!2\pi$|; + +$key = q/{_inline}71hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$71\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.05{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.05$|; + +$key = q/{_inline}sqrt1-left|mboxbfvright|^2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\sqrt{1-\left\vert\mbox{\bf v}\right\vert^2}$|; + +$key = q/{_inline}murmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\mu{\rm m}$|; + +$key = q/{_inline}alpha,deltarightarrowlambda,beta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\alpha,\delta\rightarrow\lambda,\beta$|; + +$key = q/{displaymath}h=theta-alpha{displaymath}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|\begin{displaymath}
+h = \theta - \alpha \end{displaymath}|; + +$key = q/{_inline}2^circhspace-0.37em.hspace0.02em4{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$2^{\circ}
+ \hspace{-0.37em}.\hspace{0.02em}4$|; + +$key = q/{_inline}1hspace-0.05em^'hspace-0.1em'hspace-0.4em.85{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.85$|; + +$key = q/{_inline}+pi2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$+\pi/2$|; + +$key = q/{_inline}sim!76^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\sim\!76^\circ$|; + +$key = q/{_inline}[,x,y,z,dotx,doty,dotz,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$|; + +$key = q/{_inline}6.5^circKkm^-1{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$6.5^\circ K km^{-1}$|; + +$key = q/{_inline}270^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$270^\circ$|; + +$key = q/{_inline}7hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$7\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}tandeltaEapproxdeltaE{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\tan \delta E\approx\delta E}$|; + +$key = q/{_inline}cdots{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\cdots$|; + +$key = q/{_inline}1hspace-0.05em^'hspace-0.1em'hspace-0.4em.5{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.8{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.8$|; + +$key = q/{_inline}(1-deltaE^22){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$(1-\delta E^2 /2)$|; + +$key = q/{_inline}mu{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\mu$|; + +$key = q/{_inline}15^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$15^\circ$|; + +$key = q/{_inline}[Deltax,Deltay,Deltaz,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\Delta x, \Delta y, \Delta z\,]$|; + +$key = q/{_inline}70^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$70^\circ$|; + +$key = q/{_inline}DeltarmT=rmET-rmUT{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\Delta {\rm T} = {\rm ET} - {\rm UT}$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.02{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.02$|; + +$key = q/{_inline}91^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$91^\circ$|; + +$key = q/{_inline}Delta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\Delta$|; + +$key = q/{_inline}l^I!I=53^circ,b^I!I=+25^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$l^{I\!I}=53^{\circ},b^{I\!I}=+25^{\circ}$|; + +$key = q/{_inline}y''=y'rmYS{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$y'' = y' {\rm YS}$|; + +$key = q/{_inline}bfV2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\bf V2}$|; + +$key = q/{_inline}[,0,2pi,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,0,2\pi\,]$|; + +$key = q/{_inline}mgeqn{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$m \geq n$|; + +$key = q/{_inline}360^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$360^{\circ}$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.5{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$|; + +$key = q/{_inline}alpha,delta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\alpha,\delta$|; + +$key = q/{_inline}8hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$8\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}deltaEsinE{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\delta E \sin E$|; + +$key = q/{_inline}alpha={_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\alpha=$|; + +$key = q/{_inline}4hspace-0.05em^'hspace-0.1em'hspace-0.4em.9{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$4\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.9$|; + +$key = q/{_inline}45^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$45^\circ$|; + +$key = q/{_inline}3200hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$3200\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}equiv{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\equiv$|; + +$key = q/{_inline}delta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\delta$|; + +$key = q/{_inline}-26hspace-0.05em^'hspace-0.1em'hspace-0.4em.00{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$-26\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00$|; + +$key = q/{_inline}psi{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\psi$|; + +$key = q/{_inline}-10^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$-10^\circ$|; + +$key = q/{_inline}81hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$81\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}l^I!I=137.37{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$l^{I\!I}=137.37$|; + +$key = q/{_inline}87^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$87^\circ$|; + +$key = q/{_inline}(mu-1){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$(\mu-1)$|; + +$key = q/{_inline}23^h,59^m,60^s.0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$23^{h}\,59^{m}\,60^{s}.0$|; + +$key = q/{_inline}[,x,y,z,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,x,y,z\,]$|; + +$key = q/{_inline}(1-bfDcdotbfV1){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$(1-{\bf D}\cdot{\bf V1})$|; + +$key = q/{_inline}24^h,59^m,59^s.999{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$24^{h}\,59^{m}\,59^{s}.999$|; + +$key = q/{_inline}7^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$7^\circ$|; + +$key = q/{_inline}220hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$220\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.2{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$|; + +$key = q/{_inline}dotalphacosdelta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\dot{\alpha}\cos\delta$|; + +$key = q/{_inline}9hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$9\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}h,delta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$h,\delta$|; + +$key = q/{_inline}beta~(=H_0r_0){_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\beta~(=H_0/r_0)$|; + +$key = q/{_inline}0^rmshspace-0.3em.029032{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0^{\rm s}\hspace{-0.3em}.029032$|; + +$key = q/{_inline}32^rmshspace-0.3em.184{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$32^{\rm s}\hspace{-0.3em}.184$|; + +$key = q/{_inline}10hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$10\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}alpha{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\alpha$|; + +$key = q/{_inline}nu=p_wp_s{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\nu=p_w/p_s$|; + +$key = q/{_inline}0-2pi{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0-2\pi$|; + +$key = q/{_inline}[,dotx,doty,dotz,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,\dot{x},\dot{y},\dot{z}\,]$|; + +$key = q/{_inline}75^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$75^\circ$|; + +$key = q/{_inline}100,murmm{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$100\,\mu{\rm m}$|; + +$key = q/{_inline}x''=x'rmXS{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$x'' = x' {\rm XS}$|; + +$key = q/{_inline}[,x,y,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,x,y\,]$|; + +$key = q/{_inline}Deltapsi,cos,epsilon{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\Delta\psi\,cos\,\epsilon$|; + +$key = q/{_inline}bfrmM{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\bf \rm M}$|; + +$key = q/{_inline}zeta<60^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta<60^{\circ}$|; + +$key = q/{_inline}Deltapsicosepsilon{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\Delta\psi\cos\epsilon$|; + +$key = q/{_inline}zeta=83^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\zeta=83^\circ$|; + +$key = q/{_inline}mtimesn{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$m \times n$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.062{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.062$|; + +$key = q/{_inline}12pi=0.1591549430918953358{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1/{2 \pi} = 0.1591549430918953358$|; + +$key = q/{_inline}42^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$42^{\circ}$|; + +$key = q/{_inline}1000hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$1000\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}11hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$11\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +$key = q/{_inline}29^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$29^\circ$|; + +$key = q/{_inline}84^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$84^\circ$|; + +$key = q/{_inline}[,l^I!I,b^I!I,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,l^{I\!I},b^{I\!I}\,]$|; + +$key = q/{_inline}rmbfv_0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\rm \bf v}_0$|; + +$key = q/{_inline}mu_alpha=-{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\mu_\alpha=-$|; + +$key = q/{_inline}w_iigeq0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$w_{ii} \geq 0$|; + +$key = q/{_inline}sim76^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\sim 76^\circ$|; + +$key = q/{_inline}bfM{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\bf M}$|; + +$key = q/{_inline}pmpi{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\pm \pi$|; + +$key = q/{_inline}23^rmh,59^rmm,59^rms{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$23^{\rm h}\,59^{\rm m}\,59^{\rm s}$|; + +$key = q/{_inline}30^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$30^\circ$|; + +$key = q/{_inline}rmbfr_0.rmbfv_0{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|${\rm \bf r}_0.{\rm \bf v}_0$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.00066{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00066$|; + +$key = q/{_inline}-0^rmshspace-0.3em.0312{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$-0^{\rm s}\hspace{-0.3em}.0312$|; + +$key = q/{_inline}delta={_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\delta=$|; + +$key = q/{_inline}Omega{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$\Omega$|; + +$key = q/{_inline}93^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$93^\circ$|; + +$key = q/{_inline}+20^circ{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$+20^\circ$|; + +$key = q/{_inline}0hspace-0.05em^'hspace-0.1em'hspace-0.4em.50{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.50$|; + +$key = q/{_inline}~cosdelta{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$~\cos \delta $|; + +$key = q/{_inline}[,h,delta,]{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$[\,h,\delta\,]$|; + +$key = q/{_inline}92hspace-0.05em^'hspace-0.1em'{_inline}MSF=1.5;AAT;/; +$cached_env_img{$key} = q|$92\hspace{-0.05em}^{'\hspace{-0.1em}'}$|; + +1; + diff --git a/src/slalib/sun67.htx/images.tex b/src/slalib/sun67.htx/images.tex new file mode 100644 index 0000000..8881d62 --- /dev/null +++ b/src/slalib/sun67.htx/images.tex @@ -0,0 +1,2852 @@ +\batchmode +\documentclass[11pt,twoside]{article} +\makeatletter +\input{/home/user1/dec/ptw/hypertext/sun67_htx/html.sty} +\input{/home/user1/dec/ptw/hypertext/sun67_htx/star2html.sty} +\setcounter{tocdepth}{2} +\pagestyle{myheadings} + +\markright{SUN/67.45} + +\setlength {\textwidth}{160mm} + +\setlength {\textheight}{230mm} + +\setlength {\topmargin}{-5mm} + + +\setlength {\textwidth}{160mm} + + +\setlength {\textheight}{230mm} + + +\setlength {\topmargin}{-2mm} + + +\setlength {\oddsidemargin}{0mm} + + +\setlength {\evensidemargin}{0mm} + + +\setlength {\parindent}{0mm} + + +\setlength {\parskip}{\medskipamount} + + +\setlength {\unitlength}{1mm} + + +\latex{\renewcommand {\_}{{\tt\symbol{95}}}} + +\newlength {\oldspacing} + + +\newcommand{\stardoccategory} {Starlink User Note} + +\newcommand{\stardocinitials} {SUN} + +\newcommand{\stardocsource} {sun67.45} + +\newcommand{\stardocnumber} {67.45} + +\newcommand{\stardocauthors} {P.\,T.\,Wallace} + +\newcommand{\stardocdate} {12 October 1999} + +\newcommand{\stardoctitle} {SLALIB --- Positional Astronomy Library} + +\newcommand{\stardocversion} {2.4-0} + +\newcommand{\stardocmanual} {Programmer's Manual} + +\newcommand{\stardocname}{\stardocinitials /\stardocnumber} + +\newcommand{\htmladdnormallinkfoot}[2]{#1\footnote{#2}} + +\newcommand{\htmladdnormallink}[2]{#1} + +\newcommand{\htmladdimg}[1]{} + +\newenvironment{latexonly}{}{} + +\newcommand{\hyperref}[4]{#2\ref{#4}#3} + +\newcommand{\htmlref}[2]{#1} + +\newcommand{\htmlimage}[1]{} + +\newcommand{\htmladdtonavigation}[1]{} + +\newcommand{\xref}[3]{#1} + +\newcommand{\xlabel}[1]{} + +\newcommand{\latextohtml}{{\bf LaTeX}{2}{\tt{HTML}}} + +\newcommand{\latex}[1]{#1} + +\newcommand{\setunderscore}{\renewcommand {\_}{{\tt\symbol{95}}}} + +\newcommand{\latexonlytoc}[0]{\tableofcontents} + +\newcommand{\nroutines} {183} + +\newcommand{\radec} {$[\,\alpha,\delta\,]$} + +\newcommand{\hadec} {$[\,h,\delta\,]$} + +\newcommand{\xieta} {$[\,\xi,\eta\,]$} + +\newcommand{\azel} {$[\,Az,El~]$} + +\newcommand{\ecl} {$[\,\lambda,\beta~]$} + +\newcommand{\gal} {$[\,l^{I\!I},b^{I\!I}\,]$} + +\newcommand{\xy} {$[\,x,y\,]$} + +\newcommand{\xyz} {$[\,x,y,z\,]$} + +\newcommand{\xyzd} {$[\,\dot{x},\dot{y},\dot{z}\,]$} + +\newcommand{\xyzxyzd} {$[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$} + +\newcommand{\degree}[2] {$#1^{\circ} + \hspace{-0.37em}.\hspace{0.02em}#2$} + +\newcommand{\arcsec}[2] {\arcseci{#1}$\hspace{-0.4em}.#2$} + +\newcommand{\arcseci}[1] {$#1\hspace{-0.05em}$\raisebox{-0.5ex} + {$^{'\hspace{-0.1em}'}$}} + +\renewcommand{\arcseci}[1] {$#1\hspace{-0.05em}^{'\hspace{-0.1em}'}$} + +\newcommand{\dms}[4] {$#1^{\circ}\,#2\raisebox{-0.5ex} + {$^{'}$}\,$\arcsec{#3}{#4}} + +\renewcommand{\dms}[4]{$#1^{\circ}\,#2^{'}\,#3^{''}.#4$} + +\newcommand{\tseci}[1] {$#1$\mbox{$^{\rm s}$}} + +\newcommand{\tsec}[2] {\tseci{#1}$\hspace{-0.3em}.#2$} + +\renewcommand{\tsec}[2] {$#1^{\rm s}\hspace{-0.3em}.#2$} + +\newcommand{\hms}[4] {$#1^{\rm h}\,#2^{\rm m}\,$\tsec{#3}{#4}} + +\renewcommand{\hms}[4] {$#1^{h}\,#2^{m}\,#3^{s}.#4$} + +\newcommand{\callhead}[1]{\goodbreak\vspace{\bigskipamount}{\large\bf{#1}}} + +\newenvironment{callset}{\begin{list}{}{\setlength{\leftmargin}{2cm} + \setlength{\parsep}{\smallskipamount}}}{\end{list}} + +\newcommand{\subp}[1]{\item\hspace{-1cm}#1\\} + +\newcommand{\subq}[2]{\item\hspace{-1cm}#1\\\hspace*{-1cm}#2\\} + +\newcommand{\name}[1]{\mbox{#1}} + +\newcommand{\fortvar}[1]{\mbox{\em #1}} + +\newcommand{\routine}[3] +{\hbadness=10000 + \vbox + { + \rule{\textwidth}{0.3mm}\\ {\Large {\bf #1} \hfill #2 \hfill {\bf #1}}\\ \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + #3 + \end{description} + \setlength{\topsep}{\oldspacing} + } +} + +\renewcommand{\routine}[3] + { + \subsection{#1\xlabel{#1} - #2\label{#1}} + \begin{description} + #3 + \end{description} + } + +\newcommand{\action}[1] +{\item[ACTION]: #1} + +\newcommand{\call}[1] +{\item[CALL]: \hspace{0.4em}{\tt #1}} + +\renewcommand{\call}[1] + { + \item[CALL:] {\tt #1} + } + +\newcommand{\args}[2] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[#1]:\\[1.5ex] + \begin{tabular}{p{7em}p{6em}p{22em}} + #2 + \end{tabular} + \end{description} + \setlength{\topsep}{\oldspacing} +} + +\renewcommand{\args}[2] + { + \begin{description} + \item[#1:]\\ \begin{tabular}{p{7em}p{6em}l} + #2 + \end{tabular} + \end{description} + } + +\newcommand{\spec}[3] +{ + {\em {#1}} & {\bf \mbox{#2}} & {#3} +} + +\newcommand{\specel}[2] +{ + \multicolumn{1}{c}{#1} & {} & {#2} +} + +\newcommand{\anote}[1] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[NOTE]: + #1 + \end{description} + \setlength{\topsep}{\oldspacing} +} + +\renewcommand{\anote}[1] + { + \begin{description} + \item[NOTE:] + #1 + \end{description} + } + +\newcommand{\notes}[1] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[NOTES]: + #1 + \end{description} + \setlength{\topsep}{\oldspacing} +} + +\renewcommand{\notes}[1] + { + \begin{description} + \item[NOTES:] + #1 + \end{description} + } + +\newcommand{\aref}[1] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[REFERENCE]: + #1 + \end{description} + \setlength{\topsep}{\oldspacing} +} + +\newcommand{\refs}[1] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[REFERENCES]: + #1 + \end{description} + \setlength{\topsep}{\oldspacing} +} + +\newcommand{\exampleitem}{\item [EXAMPLE]:} + +\renewcommand{\exampleitem}{\item [EXAMPLE:]} + +\renewcommand{\thepage}{\roman{page}} + +\renewcommand{\latexonlytoc}[0]{} + +\renewcommand{\thepage}{\arabic{page}} +\input{/home/user1/dec/ptw/hypertext/sun67_htx/star2html.sty} + + +\makeatother +\ifx\AtBeginDocument\undefined \newcommand{\AtBeginDocument}[1]{}\fi +\newenvironment{tex2html_wrap}{}{} +\newbox\sizebox +\setlength{\hoffset}{0pt}\setlength{\voffset}{0pt} +\addtolength{\textheight}{\footskip}\setlength{\footskip}{0pt} +\addtolength{\textheight}{\topmargin}\setlength{\topmargin}{0pt} +\addtolength{\textheight}{\headheight}\setlength{\headheight}{0pt} +\addtolength{\textheight}{\headsep}\setlength{\headsep}{0pt} +\setlength{\textwidth}{451pt} +\newwrite\lthtmlwrite +\makeatletter +\let\realnormalsize=\normalsize +\topskip=0pt +\def\preveqno{}\let\real@float=\@float \let\realend@float=\end@float +\def\@float{\let\@savefreelist\@freelist\real@float} +\def\end@float{\realend@float\global\let\@freelist\@savefreelist} +\let\real@dbflt=\@dbflt \let\end@dblfloat=\end@float +\let\@largefloatcheck=\relax +\def\@dbflt{\let\@savefreelist\@freelist\real@dbflt} +\def\adjustnormalsize{\def\normalsize{\mathsurround=0pt \realnormalsize\parindent=0pt\abovedisplayskip=0pt\belowdisplayskip=0pt}\normalsize} +\def\lthtmltypeout#1{{\let\protect\string\immediate\write\lthtmlwrite{#1}}}% +\newcommand\lthtmlhboxmathA{\adjustnormalsize\setbox\sizebox=\hbox\bgroup}% +\newcommand\lthtmlvboxmathA{\adjustnormalsize\setbox\sizebox=\vbox\bgroup% + \let\ifinner=\iffalse }% +\newcommand\lthtmlboxmathZ{\@next\next\@currlist{}{\def\next{\voidb@x}}% + \expandafter\box\next\egroup}% +\newcommand\lthtmlmathtype[1]{\def\lthtmlmathenv{#1}}% +\newcommand\lthtmllogmath{\lthtmltypeout{l2hSize % +:\lthtmlmathenv:\the\ht\sizebox::\the\dp\sizebox::\the\wd\sizebox.\preveqno}}% +\newcommand\lthtmlfigureA[1]{\let\@savefreelist\@freelist + \lthtmlmathtype{#1}\lthtmlvboxmathA}% +\newcommand\lthtmlfigureZ{\lthtmlboxmathZ\lthtmllogmath\copy\sizebox + \global\let\@freelist\@savefreelist}% +\newcommand\lthtmldisplayA[1]{\lthtmlmathtype{#1}\lthtmlvboxmathA}% +\newcommand\lthtmldisplayB[1]{\edef\preveqno{(\theequation)}% + \lthtmldisplayA{#1}\let\@eqnnum\relax}% +\newcommand\lthtmldisplayZ{\lthtmlboxmathZ\lthtmllogmath\lthtmlsetmath}% +\newcommand\lthtmlinlinemathA[1]{\lthtmlmathtype{#1}\lthtmlhboxmathA \vrule height1.5ex width0pt }% +\newcommand\lthtmlinlinemathZ{\egroup\expandafter\ifdim\dp\sizebox>0pt % + \expandafter\centerinlinemath\fi\lthtmllogmath\lthtmlsetmath} +\def\lthtmlsetmath{\hbox{\vrule width.5pt\vtop{\vbox{% + \kern.5pt\kern0.75 pt\hbox{\hglue.5pt\copy\sizebox\hglue0.75 pt}\kern.5pt% + \ifdim\dp\sizebox>0pt\kern0.75 pt\fi}% + \ifdim\hsize>\wd\sizebox \hrule depth1pt\fi}}} +\def\centerinlinemath{\dimen1=\ht\sizebox + \ifdim\dimen1<\dp\sizebox \ht\sizebox=\dp\sizebox + \else \dp\sizebox=\ht\sizebox \fi} + +\def\lthtmlcheckvsize{\ifdim\ht\sizebox<\vsize\expandafter\vfill + \else\expandafter\vss\fi}% +\makeatletter + + +\begin{document} +\pagestyle{empty}\thispagestyle{empty}% +\lthtmltypeout{latex2htmlLength hsize=\the\hsize}% +\lthtmltypeout{latex2htmlLength vsize=\the\vsize}% +\lthtmltypeout{latex2htmlLength hoffset=\the\hoffset}% +\lthtmltypeout{latex2htmlLength voffset=\the\voffset}% +\lthtmltypeout{latex2htmlLength topmargin=\the\topmargin}% +\lthtmltypeout{latex2htmlLength topskip=\the\topskip}% +\lthtmltypeout{latex2htmlLength headheight=\the\headheight}% +\lthtmltypeout{latex2htmlLength headsep=\the\headsep}% +\lthtmltypeout{latex2htmlLength parskip=\the\parskip}% +\lthtmltypeout{latex2htmlLength oddsidemargin=\the\oddsidemargin}% +\makeatletter +\if@twoside\lthtmltypeout{latex2htmlLength evensidemargin=\the\evensidemargin}% +\else\lthtmltypeout{latex2htmlLength evensidemargin=\the\oddsidemargin}\fi% +\makeatother +\setcounter{tocdepth}{2} +\stepcounter{section} +\setcounter{page}{1} +\stepcounter{section} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline417}% +$0^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline419}% +$-1^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{section} +\stepcounter{section} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline528}% +$[\,\alpha,\delta\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} + +\setlength {\oldspacing}{\topsep} +% + + +\setlength {\topsep}{0.3ex} +% + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline786}% +$12^{\circ}\,34^{'}\,56^{''}.7$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + + +\setlength {\topsep}{\oldspacing} +% + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline788}% +${\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline802}% +$1/{2 \pi} = 0.1591549430918953358$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline806}% +$15/{2\pi} = 2.3873241463784300365$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline893}% +$\zeta = 87^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} + +\setlength {\parskip}{\medskipamount} +% + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1090}% +$\times 360/2\pi$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1092}% +$\rightarrow$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1094}% +$\times (2\pi/86400) \times (360/2\pi)$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1098}% +$\times (2\pi/86400)^2 \times (360/2\pi)$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1102}% +$[\,0,2\pi\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1104}% +$+\pi/2$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1106}% +$\pm\pi/2$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1373}% +$\times 2 / $% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1375}% +$\sqrt{1-\left|\mbox{\bf v}\right|^2}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1377}% +$3\times3$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1701}% +$\Delta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1705}% +$[\,x,y\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1707}% +$\mu{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1709}% +$90^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1711}% +$\delta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1713}% +$\alpha$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1715}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1717}% +$\zeta<70^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1721}% +$3^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1725}% +$[\,Az,El~]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1729}% +$[\,h,\delta\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1745}% +$\pm$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1747}% +$0^{\rm s}\hspace{-0.3em}.9$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline1749}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2524}% +$76^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2704}% +$0.7\,\mu{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2706}% +$0.4\,\mu{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2708}% +$29^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2710}% +$290^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2712}% +$0.0065^\circ m^{-1}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2716}% +$15^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2718}% +$1.0\,\mu{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2720}% +$0.3\,\mu{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2722}% +$20\,\mu{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2724}% +$11\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2726}% +$100\,\mu{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2728}% +$(\mu-1)$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2867}% +$[\lambda,\phi]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline2869}% +$\pm \pi$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline3016}% +$\cdots$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline3160}% +$0^{\rm h}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline3380}% +$[\,x,y,z\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline3493}% +$[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline4117}% +$2\pi$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline4123}% +$360^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} + +\setlength {\oldspacing}{\topsep} +% + + +\setlength {\topsep}{0.3ex} +% + + +\setlength {\topsep}{\oldspacing} +% + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5205}% +$23^{\rm h}\,59^{\rm m}\,59^{\rm s}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5954}% +$[x_{1},y_{1}\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5956}% +$[x_{2},y_{2}\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5962}% +$x' = x_{1} + {\rm XZ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5964}% +$y' = y_{1} + {\rm YZ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5966}% +$x'' = x' {\rm XS}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5968}% +$y'' = y' {\rm YS}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5970}% +$x''' = + x'' \cos {\rm PERP}/2 + y'' \sin {\rm PERP}/2$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5972}% +$y''' = + x'' \sin {\rm PERP}/2 + y'' \cos {\rm PERP}/2$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5974}% +$x_{2} = + x''' \cos {\rm ORIENT} + + y''' \sin {\rm ORIENT}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline5976}% +$y_{2} = - x''' \sin {\rm ORIENT} + + y''' \cos {\rm ORIENT}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline6230}% +$h,\delta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline6232}% +$0\!-\!2\pi$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline6347}% +$\equiv123$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline6475}% +$\pm n.n x \pm n$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline6491}% +$x\!\pm\!n$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline6713}% +$^{T}\cdot$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline6717}% +${\bf \rm M}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7186}% +$\cdot$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7188}% +$n \times n$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7358}% +$10\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7360}% +$3\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7362}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7364}% +$3\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.7$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7366}% +$2\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7368}% +$18\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7370}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.50$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7374}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.24$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7376}% +$30\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7378}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline7465}% +$\times$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline8210}% +$[\,\xi,\eta\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline8382}% +$20^{\rm s}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline8384}% +$30^{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline8386}% +$-26\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline8848}% +$\alpha=0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline8993}% +$\xi,\eta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline8995}% +$\alpha,\delta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline9003}% +$\xi$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline9812}% +$\times10^{-5}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline9814}% +$\times10^{-10}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline9967}% +$\alpha,\delta\rightarrow\lambda,\beta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10116}% +$0^{\rm s}\hspace{-0.3em}.03$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10118}% +$0^{\rm s}\hspace{-0.3em}.01$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10191}% +$[\,l^{I\!I},b^{I\!I}\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10601}% +$\Omega$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10603}% +$\varpi$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10605}% +$\omega$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10625}% +${\rm \bf r}_0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10627}% +${\rm \bf v}_0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10629}% +${\rm \bf r}_0.{\rm \bf v}_0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10633}% +$\psi$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10663}% +$( 0 \leq e < 1 )$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline10697}% +$( 0 \leq e \leq 10 )$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline11178}% +$\Delta\psi\,cos\,\epsilon$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline11337}% +$[\Delta x, \Delta y, \Delta z\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline11339}% +$20\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.49552$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline11594}% +$[\,\dot{x},\dot{y},\dot{z}\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline11608}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.001$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline11828}% +$[x_{m},y_{m}\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline11830}% +$[x_{e},y_{e}\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline12099}% +$\dot{\alpha}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline12101}% +$\dot{\alpha}\cos\delta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline12103}% +$10^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline12105}% +$\Delta\alpha$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline13294}% +$l^{I\!I}=137.37$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline13534}% +$1.0027379\cdots$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline13611}% +$[\,0,\,1\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline14280}% +${\bf M}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline14410}% +$\pm n$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline15250}% +$920\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline15252}% +$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.85$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline15578}% +$14\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline15582}% +$9\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline16974}% +$\rho = r (1 + c r^{2})$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline16980}% +$\rho$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} + +\setlength {\parskip}{\medskipamount} +% + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19044}% +$4\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19046}% +$5\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19048}% +$6\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19050}% +$17\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19052}% +$71\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19054}% +$81\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19056}% +$86\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19060}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.6$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19064}% +${\rm MJD} = ({\rm JD} - 2400000.5$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline19834}% +$270^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline20108}% +$1\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline20114}% +$100\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline20116}% +$1000\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline20952}% +$0-2\pi$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline21527}% +$[x_{p},y_{p}\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline21604}% +$0 \leq x < 1$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline21862}% +$\mu$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline21866}% +$\pm3$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22333}% +$\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22335}% +$\zeta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22337}% +$\Delta \zeta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22343}% +$\tan \zeta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22345}% +$\tan^{3} \zeta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22353}% +$\tan^{-1} 1$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22355}% +$45^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22357}% +$\tan^{-1} 4$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22359}% +$\sim 76^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22363}% +$\zeta<80^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22365}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.01$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22367}% +$\zeta<60^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22371}% +$\zeta<45^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22628}% +$\sim\!76^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22638}% +$25^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22640}% +$50^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22642}% +$75^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22656}% +$-10^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22658}% +$+20^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22660}% +$280^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22666}% +$2\mu{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22678}% +$6.5^\circ K km^{-1}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22690}% +$7^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22698}% +$\tan^5$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22702}% +$\beta~(=H_0/r_0)$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22706}% +$\beta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22933}% +$70^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22935}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.05$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22947}% +$93^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22949}% +$=93^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22955}% +$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22957}% +$80^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22959}% +$\nu=p_w/p_s$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline22961}% +$\nu=\rho_w/\rho_s$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23162}% +$30^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23164}% +$\zeta=70^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23168}% +$\zeta_{obs}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23172}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.4$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23174}% +$81^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23176}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.8$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23178}% +$82^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23180}% +$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.6$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23182}% +$83^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23186}% +$84^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23188}% +$7\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23190}% +$85^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23194}% +$86^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23196}% +$45\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23198}% +$87^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23200}% +$150\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23202}% +$88^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23204}% +$340\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23206}% +$89^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23208}% +$620\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23212}% +$1100\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23214}% +$91^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23216}% +$1900\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23220}% +$92^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23222}% +$3200\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23228}% +$\zeta=84^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23469}% +$\zeta=80^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23471}% +$\zeta=83^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmldisplayA{displaymath23457}% +\begin{displaymath}\Delta \zeta = F \left( + \frac{0^\circ\hspace{-0.37em}.\hspace{0.02em}55445 + - 0^\circ\hspace{-0.37em}.\hspace{0.02em}01133 E + + 0^\circ\hspace{-0.37em}.\hspace{0.02em}00202 E^2} + {1 + 0.28385 E +0.02390 E^2} \right) \end{displaymath}% +\lthtmldisplayZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23475}% +$E=90^\circ-\zeta_{true}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23495}% +$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23499}% +$3\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23503}% +$4\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.9$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23507}% +$5\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.8$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23511}% +$6\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23515}% +$7\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23523}% +$21\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23527}% +$43\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23531}% +$92\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23537}% +$220\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23720}% +$l^{I\!I}=90^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23722}% +$b^{I\!I}=0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23896}% +$l^{I\!I}=53^{\circ},b^{I\!I}=+25^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline23995}% +$\alpha=18^{\rm h},\delta=+30^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline24798}% +$\times n$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline24800}% +$m \geq n$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline24802}% +$m \times n$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline24806}% +$w_{ii} \geq 0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline25275}% +$\cdot~[diag(1/$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline25277}% +$_{j})] + \cdot ($% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} + +\setlength {\parskip}{\medskipamount} +% + +\stepcounter{subsection} + +\setlength {\parskip}{\medskipamount} +% + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline26731}% +$2^{\circ} + \hspace{-0.37em}.\hspace{0.02em}4$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline26733}% +$42^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27323}% +$0\!-\!\pi$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{section} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27383}% +$61^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsubsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27391}% +$+1^{\circ}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27397}% +$24^{h}\,59^{m}\,59^{s}.999$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27464}% +$[\,\theta,\phi~]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsubsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27478}% +$[\,\Delta x,\Delta y, \Delta z\,]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27484}% +${\bf D}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27486}% +${\bf V1}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27488}% +${\bf V2}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27490}% +$<{\bf V1}+{\bf D}>$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27492}% +$(1-{\bf D}\cdot{\bf V1})$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27494}% +$\delta E$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27498}% +${\tan \delta E\approx\delta E}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27504}% +$\delta E \cos E$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27506}% +$\delta E \sin E$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27512}% +$\cos \delta E$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27514}% +$(1-\delta E^2 /2)$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27518}% +$\equiv$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27524}% +$[\theta,\phi,\dot{\theta},\dot{\phi}]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27750}% +$\lambda,\beta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27752}% +$l^{I\!I},b^{I\!I}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlfigureA{figure27550}% +\begin{figure}\begin{center} +\begin{tabular}{|cccccc|} \hline +& & & & & \\\hspace{5em} & \hspace{5em} & \hspace{5em} & + \hspace{5em} & \hspace{5em} & \hspace{5em} \\\multicolumn{2}{|c}{\hspace{0em} +\fbox {\parbox{8.5em}{\center \vspace{-2ex} + mean $[\,\alpha,\delta\,]$, FK4, \\ any equinox + \vspace{0.5ex}}} +} & + \multicolumn{2}{c}{\hspace{0em} +\fbox {\parbox{8.5em}{\center \vspace{-2ex} + mean $[\,\alpha,\delta\,]$, FK4, + no $\mu$, any equinox + \vspace{0.5ex}}} +} & +\multicolumn{2}{c|}{\hspace{0em} +\fbox {\parbox{8.5em}{\center \vspace{-2ex} + mean $[\,\alpha,\delta\,]$, FK5, \\ any equinox + \vspace{0.5ex}}} +} \\& \multicolumn{2}{|c|}{} & \multicolumn{2}{c|}{} & \\\multicolumn{2}{|c}{space motion} & \multicolumn{1}{c|}{} & & + \multicolumn{2}{c|}{space motion} \\\multicolumn{2}{|c}{-- E-terms} & + \multicolumn{2}{c}{-- E-terms} & \multicolumn{1}{c|}{} & \\\multicolumn{2}{|c}{precess to B1950} & \multicolumn{2}{c}{precess to B1950} & + \multicolumn{2}{c|}{precess to J2000} \\\multicolumn{2}{|c}{+ E-terms} & + \multicolumn{2}{c}{+ E-terms} & \multicolumn{1}{c|}{} & \\\multicolumn{2}{|c}{FK4 to FK5, no $\mu$} & + \multicolumn{2}{c}{FK4 to FK5, no $\mu$} & \multicolumn{1}{c|}{} & \\\multicolumn{2}{|c}{parallax} & \multicolumn{1}{c|}{} & & + \multicolumn{2}{c|}{parallax} \\& \multicolumn{2}{|c|}{} & \multicolumn{2}{c|}{} & \\ \cline{2-5} +\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{ +\fbox {\parbox{18em}{\center \vspace{-2ex} + FK5, J2000, current epoch, geocentric + \vspace{0.5ex}}} +} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{light deflection} & \\& \multicolumn{4}{c}{annual aberration} & \\& \multicolumn{4}{c}{precession/nutation} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{ +\fbox {Apparent $[\,\alpha,\delta\,]$} +} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{Earth rotation} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{ +\fbox {Apparent $[\,h,\delta\,]$} +} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{diurnal aberration} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{ +\fbox {Topocentric $[\,h,\delta\,]$} +} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{$[\,h,\delta\,]$\ to $[\,Az,El~]$} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{ +\fbox {Topocentric $[\,Az,El~]$} +} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{refraction} & \\\multicolumn{3}{|c|}{} & & & \\& \multicolumn{4}{c}{ +\fbox {Observed $[\,Az,El~]$} +} & \\& & & & & \\& & & & & \\ \hline +\end{tabular} +\end{center} +\vspace{-0.5ex} +Star positions are published or catalogued using +one of the mean $[\,\alpha,\delta\,]$\ systems shown at +the top. The ``FK4'' systems +were used before about 1980 and are usually +equinox B1950. The ``FK5'' system, equinox J2000, is now preferred, +or rather its modern equivalent, the International Celestial Reference +Frame (in the optical, the Hipparcos catalogue). +The figure relates a star's mean $[\,\alpha,\delta\,]$\ to the actual +line-of-sight to the star. +Note that for the conventional choices of equinox, namely +B1950 or J2000, all of the precession and E-terms corrections +are superfluous. +\end{figure}% +\lthtmlfigureZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27878}% +$23^{\circ} + \hspace{-0.37em}.\hspace{0.02em}5$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27888}% +$\epsilon$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27890}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.0001$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsubsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27892}% +$(3\times3)$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27894}% +$0^{\circ} + \hspace{-0.37em}.\hspace{0.02em}2$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27923}% +$50\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27927}% +$12^{h}\,07^{m}\,58^{s}.09$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27929}% +$-19^{\circ}\,44^{'}\,37^{''}.1$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline27959}% +$[\mu_\alpha,\mu_\delta]$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28022}% +$20\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28106}% +$\mu_\alpha=-$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28108}% +$0^{\rm s}\hspace{-0.3em}.015869$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28112}% +$0^{\rm s}\hspace{-0.3em}.029032$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28114}% +$~\sin \alpha + +$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28116}% +$0^{\rm s}\hspace{-0.3em}.000340$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28118}% +$~\cos \alpha ) \sin \delta + -$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28120}% +$0^{\rm s}\hspace{-0.3em}.000105$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28122}% +$~\cos \alpha + -$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28124}% +$0^{\rm s}\hspace{-0.3em}.000083$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28126}% +$~\sin \alpha ) \sec \delta $% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28128}% +$\mu_\delta\,=+$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28130}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.43549$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28134}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00510$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28136}% +$~\sin \alpha + + ($% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28138}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00158$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28140}% +$~\sin \alpha + -$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28142}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00125$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28146}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00066$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28148}% +$~\cos \delta $% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28214}% +$\alpha=$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28216}% +$16^{h}\,09^{m}\,55^{s}.13$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28218}% +$\delta=$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28220}% +$-75^{\circ}\,59^{'}\,27^{''}.2$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28222}% +$\mu_\alpha=$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28224}% +$-0^{\rm s}\hspace{-0.3em}.0312$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28228}% +$\mu_\delta=$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28230}% +$+0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.103$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28234}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.062$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28274}% +$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.74$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28276}% +$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.02$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28278}% +$20^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28282}% +$90^\circ-\delta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28386}% +$\theta$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmldisplayA{displaymath28366}% +\begin{displaymath}h = \theta - \alpha \end{displaymath}% +\lthtmldisplayZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28394}% +$=\Delta\psi\cos\epsilon$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsubsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28408}% +$0^{\circ} + \hspace{-0.37em}.\hspace{0.02em}5$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmldisplayA{displaymath28367}% +\begin{displaymath}\zeta _{vac} \approx \zeta _{obs} + + A \tan \zeta _{obs} + + B \tan ^{3}\zeta _{obs} \end{displaymath}% +\lthtmldisplayZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28412}% +$\zeta _{vac}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28420}% +$60\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28422}% +$-0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.06$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmldisplayA{displaymath28368}% +\begin{displaymath}\zeta _{obs} \approx \zeta _{vac} + - \frac{A \tan \zeta _{vac} + B \tan ^{3}\zeta _{vac}} + {1 + ( A + 3 B \tan ^{2}\zeta _{vac} ) \sec ^{2}\zeta _{vac}}\end{displaymath}% +\lthtmldisplayZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28444}% +$100\mu m$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsubsection} +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsubsection} +\stepcounter{subsubsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28549}% +$23^{h}\,59^{m}\,60^{s}.0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28551}% +$00^{h}\,00^{m}\,00^{s}.0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsubsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28555}% +$\Delta\psi\cos\epsilon$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsubsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28561}% +$32^{\rm s}\hspace{-0.3em}.184$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28567}% +$0^{\rm s}\hspace{-0.3em}.0016$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28569}% +$0^{\rm s}\hspace{-0.3em}.0013$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28571}% +$\Delta {\rm T} = {\rm ET} - {\rm UT}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28573}% +$\Delta {\rm T}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28650}% +$2\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28656}% +$\pm100$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28664}% +$1^\circ$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28666}% +$8\hspace{-0.05em}^{'\hspace{-0.1em}'}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28668}% +$5^{\rm h}\,25^{\rm m}$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28728}% +$\varpi = \Omega + \omega$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28740}% +$L = \varpi + M$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28752}% +$M_\odot = 1$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28769}% +$\sim20$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{subsection} +\stepcounter{subsection} +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28861}% +$C_1\!=\!+50.0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28863}% +$C_2\!=\!-2.0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28865}% +$C_3\!=\!-10.0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28867}% +$C_4\!=\!+25.0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28869}% +$\sigma=5.0$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +{\newpage\clearpage +\lthtmlinlinemathA{tex2html_wrap_inline28871}% +$1000\times20$% +\lthtmlinlinemathZ +\hfill\lthtmlcheckvsize\clearpage} + +\stepcounter{section} + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\setlength {\leftmargin}{2cm} +% + + +\setlength {\parsep}{\smallskipamount} +% + + +\end{document} diff --git a/src/slalib/sun67.htx/img1.gif b/src/slalib/sun67.htx/img1.gif new file mode 100644 index 0000000..d7b5e28 Binary files /dev/null and b/src/slalib/sun67.htx/img1.gif differ diff --git a/src/slalib/sun67.htx/img10.gif b/src/slalib/sun67.htx/img10.gif new file mode 100644 index 0000000..b62f1a8 Binary files /dev/null and b/src/slalib/sun67.htx/img10.gif differ diff --git a/src/slalib/sun67.htx/img100.gif b/src/slalib/sun67.htx/img100.gif new file mode 100644 index 0000000..398505a Binary files /dev/null and b/src/slalib/sun67.htx/img100.gif differ diff --git a/src/slalib/sun67.htx/img101.gif b/src/slalib/sun67.htx/img101.gif new file mode 100644 index 0000000..f058067 Binary files /dev/null and b/src/slalib/sun67.htx/img101.gif differ diff --git a/src/slalib/sun67.htx/img102.gif b/src/slalib/sun67.htx/img102.gif new file mode 100644 index 0000000..8be43bb Binary files /dev/null and b/src/slalib/sun67.htx/img102.gif differ diff --git a/src/slalib/sun67.htx/img103.gif b/src/slalib/sun67.htx/img103.gif new file mode 100644 index 0000000..709f499 Binary files /dev/null and b/src/slalib/sun67.htx/img103.gif differ diff --git a/src/slalib/sun67.htx/img104.gif b/src/slalib/sun67.htx/img104.gif new file mode 100644 index 0000000..12ef0a3 Binary files /dev/null and b/src/slalib/sun67.htx/img104.gif differ diff --git a/src/slalib/sun67.htx/img105.gif b/src/slalib/sun67.htx/img105.gif new file mode 100644 index 0000000..ddcae42 Binary files /dev/null and b/src/slalib/sun67.htx/img105.gif differ diff --git a/src/slalib/sun67.htx/img106.gif b/src/slalib/sun67.htx/img106.gif new file mode 100644 index 0000000..0ef06d5 Binary files /dev/null and b/src/slalib/sun67.htx/img106.gif differ diff --git a/src/slalib/sun67.htx/img107.gif b/src/slalib/sun67.htx/img107.gif new file mode 100644 index 0000000..ddef7b5 Binary files /dev/null and b/src/slalib/sun67.htx/img107.gif differ diff --git a/src/slalib/sun67.htx/img108.gif b/src/slalib/sun67.htx/img108.gif new file mode 100644 index 0000000..791b66a Binary files /dev/null and b/src/slalib/sun67.htx/img108.gif differ diff --git a/src/slalib/sun67.htx/img109.gif b/src/slalib/sun67.htx/img109.gif new file mode 100644 index 0000000..ed30950 Binary files /dev/null and b/src/slalib/sun67.htx/img109.gif differ diff --git a/src/slalib/sun67.htx/img11.gif b/src/slalib/sun67.htx/img11.gif new file mode 100644 index 0000000..f7ed3a1 Binary files /dev/null and b/src/slalib/sun67.htx/img11.gif differ diff --git a/src/slalib/sun67.htx/img110.gif b/src/slalib/sun67.htx/img110.gif new file mode 100644 index 0000000..6dc29fe Binary files /dev/null and b/src/slalib/sun67.htx/img110.gif differ diff --git a/src/slalib/sun67.htx/img111.gif b/src/slalib/sun67.htx/img111.gif new file mode 100644 index 0000000..bf7b222 Binary files /dev/null and b/src/slalib/sun67.htx/img111.gif differ diff --git a/src/slalib/sun67.htx/img112.gif b/src/slalib/sun67.htx/img112.gif new file mode 100644 index 0000000..cb0fc50 Binary files /dev/null and b/src/slalib/sun67.htx/img112.gif differ diff --git a/src/slalib/sun67.htx/img113.gif b/src/slalib/sun67.htx/img113.gif new file mode 100644 index 0000000..0bac8a0 Binary files /dev/null and b/src/slalib/sun67.htx/img113.gif differ diff --git a/src/slalib/sun67.htx/img114.gif b/src/slalib/sun67.htx/img114.gif new file mode 100644 index 0000000..d9fb000 Binary files /dev/null and b/src/slalib/sun67.htx/img114.gif differ diff --git a/src/slalib/sun67.htx/img115.gif b/src/slalib/sun67.htx/img115.gif new file mode 100644 index 0000000..5d01c21 Binary files /dev/null and b/src/slalib/sun67.htx/img115.gif differ diff --git a/src/slalib/sun67.htx/img116.gif b/src/slalib/sun67.htx/img116.gif new file mode 100644 index 0000000..243eba0 Binary files /dev/null and b/src/slalib/sun67.htx/img116.gif differ diff --git a/src/slalib/sun67.htx/img117.gif b/src/slalib/sun67.htx/img117.gif new file mode 100644 index 0000000..8b4d249 Binary files /dev/null and b/src/slalib/sun67.htx/img117.gif differ diff --git a/src/slalib/sun67.htx/img118.gif b/src/slalib/sun67.htx/img118.gif new file mode 100644 index 0000000..1c78304 Binary files /dev/null and b/src/slalib/sun67.htx/img118.gif differ diff --git a/src/slalib/sun67.htx/img119.gif b/src/slalib/sun67.htx/img119.gif new file mode 100644 index 0000000..d6338e5 Binary files /dev/null and b/src/slalib/sun67.htx/img119.gif differ diff --git a/src/slalib/sun67.htx/img12.gif b/src/slalib/sun67.htx/img12.gif new file mode 100644 index 0000000..91e6c1e Binary files /dev/null and b/src/slalib/sun67.htx/img12.gif differ diff --git a/src/slalib/sun67.htx/img120.gif b/src/slalib/sun67.htx/img120.gif new file mode 100644 index 0000000..140c0d3 Binary files /dev/null and b/src/slalib/sun67.htx/img120.gif differ diff --git a/src/slalib/sun67.htx/img121.gif b/src/slalib/sun67.htx/img121.gif new file mode 100644 index 0000000..3f69858 Binary files /dev/null and b/src/slalib/sun67.htx/img121.gif differ diff --git a/src/slalib/sun67.htx/img122.gif b/src/slalib/sun67.htx/img122.gif new file mode 100644 index 0000000..b6ea2e4 Binary files /dev/null and b/src/slalib/sun67.htx/img122.gif differ diff --git a/src/slalib/sun67.htx/img123.gif b/src/slalib/sun67.htx/img123.gif new file mode 100644 index 0000000..b575d67 Binary files /dev/null and b/src/slalib/sun67.htx/img123.gif differ diff --git a/src/slalib/sun67.htx/img124.gif b/src/slalib/sun67.htx/img124.gif new file mode 100644 index 0000000..d4a6904 Binary files /dev/null and b/src/slalib/sun67.htx/img124.gif differ diff --git a/src/slalib/sun67.htx/img125.gif b/src/slalib/sun67.htx/img125.gif new file mode 100644 index 0000000..cd22fb5 Binary files /dev/null and b/src/slalib/sun67.htx/img125.gif differ diff --git a/src/slalib/sun67.htx/img126.gif b/src/slalib/sun67.htx/img126.gif new file mode 100644 index 0000000..aa02dc1 Binary files /dev/null and b/src/slalib/sun67.htx/img126.gif differ diff --git a/src/slalib/sun67.htx/img127.gif b/src/slalib/sun67.htx/img127.gif new file mode 100644 index 0000000..9ce71a6 Binary files /dev/null and b/src/slalib/sun67.htx/img127.gif differ diff --git a/src/slalib/sun67.htx/img128.gif b/src/slalib/sun67.htx/img128.gif new file mode 100644 index 0000000..f79525b Binary files /dev/null and b/src/slalib/sun67.htx/img128.gif differ diff --git a/src/slalib/sun67.htx/img129.gif b/src/slalib/sun67.htx/img129.gif new file mode 100644 index 0000000..3c59b23 Binary files /dev/null and b/src/slalib/sun67.htx/img129.gif differ diff --git a/src/slalib/sun67.htx/img13.gif b/src/slalib/sun67.htx/img13.gif new file mode 100644 index 0000000..a68c1d9 Binary files /dev/null and b/src/slalib/sun67.htx/img13.gif differ diff --git a/src/slalib/sun67.htx/img130.gif b/src/slalib/sun67.htx/img130.gif new file mode 100644 index 0000000..882e609 Binary files /dev/null and b/src/slalib/sun67.htx/img130.gif differ diff --git a/src/slalib/sun67.htx/img131.gif b/src/slalib/sun67.htx/img131.gif new file mode 100644 index 0000000..c223db8 Binary files /dev/null and b/src/slalib/sun67.htx/img131.gif differ diff --git a/src/slalib/sun67.htx/img132.gif b/src/slalib/sun67.htx/img132.gif new file mode 100644 index 0000000..b4ff911 Binary files /dev/null and b/src/slalib/sun67.htx/img132.gif differ diff --git a/src/slalib/sun67.htx/img133.gif b/src/slalib/sun67.htx/img133.gif new file mode 100644 index 0000000..6df3c7a Binary files /dev/null and b/src/slalib/sun67.htx/img133.gif differ diff --git a/src/slalib/sun67.htx/img134.gif b/src/slalib/sun67.htx/img134.gif new file mode 100644 index 0000000..10b35b5 Binary files /dev/null and b/src/slalib/sun67.htx/img134.gif differ diff --git a/src/slalib/sun67.htx/img135.gif b/src/slalib/sun67.htx/img135.gif new file mode 100644 index 0000000..3269790 Binary files /dev/null and b/src/slalib/sun67.htx/img135.gif differ diff --git a/src/slalib/sun67.htx/img136.gif b/src/slalib/sun67.htx/img136.gif new file mode 100644 index 0000000..d6fded5 Binary files /dev/null and b/src/slalib/sun67.htx/img136.gif differ diff --git a/src/slalib/sun67.htx/img137.gif b/src/slalib/sun67.htx/img137.gif new file mode 100644 index 0000000..6b68965 Binary files /dev/null and b/src/slalib/sun67.htx/img137.gif differ diff --git a/src/slalib/sun67.htx/img138.gif b/src/slalib/sun67.htx/img138.gif new file mode 100644 index 0000000..3f3e31c Binary files /dev/null and b/src/slalib/sun67.htx/img138.gif differ diff --git a/src/slalib/sun67.htx/img139.gif b/src/slalib/sun67.htx/img139.gif new file mode 100644 index 0000000..3e56ce2 Binary files /dev/null and b/src/slalib/sun67.htx/img139.gif differ diff --git a/src/slalib/sun67.htx/img14.gif b/src/slalib/sun67.htx/img14.gif new file mode 100644 index 0000000..9bc0336 Binary files /dev/null and b/src/slalib/sun67.htx/img14.gif differ diff --git a/src/slalib/sun67.htx/img140.gif b/src/slalib/sun67.htx/img140.gif new file mode 100644 index 0000000..1e6348f Binary files /dev/null and b/src/slalib/sun67.htx/img140.gif differ diff --git a/src/slalib/sun67.htx/img141.gif b/src/slalib/sun67.htx/img141.gif new file mode 100644 index 0000000..278957d Binary files /dev/null and b/src/slalib/sun67.htx/img141.gif differ diff --git a/src/slalib/sun67.htx/img142.gif b/src/slalib/sun67.htx/img142.gif new file mode 100644 index 0000000..7c140ef Binary files /dev/null and b/src/slalib/sun67.htx/img142.gif differ diff --git a/src/slalib/sun67.htx/img143.gif b/src/slalib/sun67.htx/img143.gif new file mode 100644 index 0000000..39ecd67 Binary files /dev/null and b/src/slalib/sun67.htx/img143.gif differ diff --git a/src/slalib/sun67.htx/img144.gif b/src/slalib/sun67.htx/img144.gif new file mode 100644 index 0000000..6ab1623 Binary files /dev/null and b/src/slalib/sun67.htx/img144.gif differ diff --git a/src/slalib/sun67.htx/img145.gif b/src/slalib/sun67.htx/img145.gif new file mode 100644 index 0000000..ad8e73e Binary files /dev/null and b/src/slalib/sun67.htx/img145.gif differ diff --git a/src/slalib/sun67.htx/img146.gif b/src/slalib/sun67.htx/img146.gif new file mode 100644 index 0000000..c65c07a Binary files /dev/null and b/src/slalib/sun67.htx/img146.gif differ diff --git a/src/slalib/sun67.htx/img147.gif b/src/slalib/sun67.htx/img147.gif new file mode 100644 index 0000000..de63550 Binary files /dev/null and b/src/slalib/sun67.htx/img147.gif differ diff --git a/src/slalib/sun67.htx/img148.gif b/src/slalib/sun67.htx/img148.gif new file mode 100644 index 0000000..4adf366 Binary files /dev/null and b/src/slalib/sun67.htx/img148.gif differ diff --git a/src/slalib/sun67.htx/img149.gif b/src/slalib/sun67.htx/img149.gif new file mode 100644 index 0000000..7bbadd9 Binary files /dev/null and b/src/slalib/sun67.htx/img149.gif differ diff --git a/src/slalib/sun67.htx/img15.gif b/src/slalib/sun67.htx/img15.gif new file mode 100644 index 0000000..55a91f6 Binary files /dev/null and b/src/slalib/sun67.htx/img15.gif differ diff --git a/src/slalib/sun67.htx/img150.gif b/src/slalib/sun67.htx/img150.gif new file mode 100644 index 0000000..215d6bd Binary files /dev/null and b/src/slalib/sun67.htx/img150.gif differ diff --git a/src/slalib/sun67.htx/img151.gif b/src/slalib/sun67.htx/img151.gif new file mode 100644 index 0000000..34d893a Binary files /dev/null and b/src/slalib/sun67.htx/img151.gif differ diff --git a/src/slalib/sun67.htx/img152.gif b/src/slalib/sun67.htx/img152.gif new file mode 100644 index 0000000..a4cd7b2 Binary files /dev/null and b/src/slalib/sun67.htx/img152.gif differ diff --git a/src/slalib/sun67.htx/img153.gif b/src/slalib/sun67.htx/img153.gif new file mode 100644 index 0000000..7d5fc3d Binary files /dev/null and b/src/slalib/sun67.htx/img153.gif differ diff --git a/src/slalib/sun67.htx/img154.gif b/src/slalib/sun67.htx/img154.gif new file mode 100644 index 0000000..e10d26d Binary files /dev/null and b/src/slalib/sun67.htx/img154.gif differ diff --git a/src/slalib/sun67.htx/img155.gif b/src/slalib/sun67.htx/img155.gif new file mode 100644 index 0000000..8a36cb9 Binary files /dev/null and b/src/slalib/sun67.htx/img155.gif differ diff --git a/src/slalib/sun67.htx/img156.gif b/src/slalib/sun67.htx/img156.gif new file mode 100644 index 0000000..b920388 Binary files /dev/null and b/src/slalib/sun67.htx/img156.gif differ diff --git a/src/slalib/sun67.htx/img157.gif b/src/slalib/sun67.htx/img157.gif new file mode 100644 index 0000000..9c2a20e Binary files /dev/null and b/src/slalib/sun67.htx/img157.gif differ diff --git a/src/slalib/sun67.htx/img158.gif b/src/slalib/sun67.htx/img158.gif new file mode 100644 index 0000000..08323ac Binary files /dev/null and b/src/slalib/sun67.htx/img158.gif differ diff --git a/src/slalib/sun67.htx/img159.gif b/src/slalib/sun67.htx/img159.gif new file mode 100644 index 0000000..9bb4943 Binary files /dev/null and b/src/slalib/sun67.htx/img159.gif differ diff --git a/src/slalib/sun67.htx/img16.gif b/src/slalib/sun67.htx/img16.gif new file mode 100644 index 0000000..db11f13 Binary files /dev/null and b/src/slalib/sun67.htx/img16.gif differ diff --git a/src/slalib/sun67.htx/img160.gif b/src/slalib/sun67.htx/img160.gif new file mode 100644 index 0000000..45bf04c Binary files /dev/null and b/src/slalib/sun67.htx/img160.gif differ diff --git a/src/slalib/sun67.htx/img161.gif b/src/slalib/sun67.htx/img161.gif new file mode 100644 index 0000000..39801d7 Binary files /dev/null and b/src/slalib/sun67.htx/img161.gif differ diff --git a/src/slalib/sun67.htx/img162.gif b/src/slalib/sun67.htx/img162.gif new file mode 100644 index 0000000..e36f849 Binary files /dev/null and b/src/slalib/sun67.htx/img162.gif differ diff --git a/src/slalib/sun67.htx/img163.gif b/src/slalib/sun67.htx/img163.gif new file mode 100644 index 0000000..d2f8408 Binary files /dev/null and b/src/slalib/sun67.htx/img163.gif differ diff --git a/src/slalib/sun67.htx/img164.gif b/src/slalib/sun67.htx/img164.gif new file mode 100644 index 0000000..371d870 Binary files /dev/null and b/src/slalib/sun67.htx/img164.gif differ diff --git a/src/slalib/sun67.htx/img165.gif b/src/slalib/sun67.htx/img165.gif new file mode 100644 index 0000000..1fc8b8a Binary files /dev/null and b/src/slalib/sun67.htx/img165.gif differ diff --git a/src/slalib/sun67.htx/img166.gif b/src/slalib/sun67.htx/img166.gif new file mode 100644 index 0000000..b2066f3 Binary files /dev/null and b/src/slalib/sun67.htx/img166.gif differ diff --git a/src/slalib/sun67.htx/img167.gif b/src/slalib/sun67.htx/img167.gif new file mode 100644 index 0000000..69baa0b Binary files /dev/null and b/src/slalib/sun67.htx/img167.gif differ diff --git a/src/slalib/sun67.htx/img168.gif b/src/slalib/sun67.htx/img168.gif new file mode 100644 index 0000000..9c77a9f Binary files /dev/null and b/src/slalib/sun67.htx/img168.gif differ diff --git a/src/slalib/sun67.htx/img169.gif b/src/slalib/sun67.htx/img169.gif new file mode 100644 index 0000000..2757ee2 Binary files /dev/null and b/src/slalib/sun67.htx/img169.gif differ diff --git a/src/slalib/sun67.htx/img17.gif b/src/slalib/sun67.htx/img17.gif new file mode 100644 index 0000000..f7e5825 Binary files /dev/null and b/src/slalib/sun67.htx/img17.gif differ diff --git a/src/slalib/sun67.htx/img170.gif b/src/slalib/sun67.htx/img170.gif new file mode 100644 index 0000000..7975d4a Binary files /dev/null and b/src/slalib/sun67.htx/img170.gif differ diff --git a/src/slalib/sun67.htx/img171.gif b/src/slalib/sun67.htx/img171.gif new file mode 100644 index 0000000..e72edbd Binary files /dev/null and b/src/slalib/sun67.htx/img171.gif differ diff --git a/src/slalib/sun67.htx/img172.gif b/src/slalib/sun67.htx/img172.gif new file mode 100644 index 0000000..70f8874 Binary files /dev/null and b/src/slalib/sun67.htx/img172.gif differ diff --git a/src/slalib/sun67.htx/img173.gif b/src/slalib/sun67.htx/img173.gif new file mode 100644 index 0000000..1bbbe94 Binary files /dev/null and b/src/slalib/sun67.htx/img173.gif differ diff --git a/src/slalib/sun67.htx/img174.gif b/src/slalib/sun67.htx/img174.gif new file mode 100644 index 0000000..25dff75 Binary files /dev/null and b/src/slalib/sun67.htx/img174.gif differ diff --git a/src/slalib/sun67.htx/img175.gif b/src/slalib/sun67.htx/img175.gif new file mode 100644 index 0000000..6a485af Binary files /dev/null and b/src/slalib/sun67.htx/img175.gif differ diff --git a/src/slalib/sun67.htx/img176.gif b/src/slalib/sun67.htx/img176.gif new file mode 100644 index 0000000..9d0834f Binary files /dev/null and b/src/slalib/sun67.htx/img176.gif differ diff --git a/src/slalib/sun67.htx/img177.gif b/src/slalib/sun67.htx/img177.gif new file mode 100644 index 0000000..bbd3a2b Binary files /dev/null and b/src/slalib/sun67.htx/img177.gif differ diff --git a/src/slalib/sun67.htx/img178.gif b/src/slalib/sun67.htx/img178.gif new file mode 100644 index 0000000..7ebec9c Binary files /dev/null and b/src/slalib/sun67.htx/img178.gif differ diff --git a/src/slalib/sun67.htx/img179.gif b/src/slalib/sun67.htx/img179.gif new file mode 100644 index 0000000..c1ac88a Binary files /dev/null and b/src/slalib/sun67.htx/img179.gif differ diff --git a/src/slalib/sun67.htx/img18.gif b/src/slalib/sun67.htx/img18.gif new file mode 100644 index 0000000..b2b8324 Binary files /dev/null and b/src/slalib/sun67.htx/img18.gif differ diff --git a/src/slalib/sun67.htx/img180.gif b/src/slalib/sun67.htx/img180.gif new file mode 100644 index 0000000..6af2413 Binary files /dev/null and b/src/slalib/sun67.htx/img180.gif differ diff --git a/src/slalib/sun67.htx/img181.gif b/src/slalib/sun67.htx/img181.gif new file mode 100644 index 0000000..b5ac444 Binary files /dev/null and b/src/slalib/sun67.htx/img181.gif differ diff --git a/src/slalib/sun67.htx/img182.gif b/src/slalib/sun67.htx/img182.gif new file mode 100644 index 0000000..c5013f7 Binary files /dev/null and b/src/slalib/sun67.htx/img182.gif differ diff --git a/src/slalib/sun67.htx/img183.gif b/src/slalib/sun67.htx/img183.gif new file mode 100644 index 0000000..baa2252 Binary files /dev/null and b/src/slalib/sun67.htx/img183.gif differ diff --git a/src/slalib/sun67.htx/img184.gif b/src/slalib/sun67.htx/img184.gif new file mode 100644 index 0000000..c90b68f Binary files /dev/null and b/src/slalib/sun67.htx/img184.gif differ diff --git a/src/slalib/sun67.htx/img185.gif b/src/slalib/sun67.htx/img185.gif new file mode 100644 index 0000000..113fa7c Binary files /dev/null and b/src/slalib/sun67.htx/img185.gif differ diff --git a/src/slalib/sun67.htx/img186.gif b/src/slalib/sun67.htx/img186.gif new file mode 100644 index 0000000..6a3576d Binary files /dev/null and b/src/slalib/sun67.htx/img186.gif differ diff --git a/src/slalib/sun67.htx/img187.gif b/src/slalib/sun67.htx/img187.gif new file mode 100644 index 0000000..f380409 Binary files /dev/null and b/src/slalib/sun67.htx/img187.gif differ diff --git a/src/slalib/sun67.htx/img188.gif b/src/slalib/sun67.htx/img188.gif new file mode 100644 index 0000000..6da976c Binary files /dev/null and b/src/slalib/sun67.htx/img188.gif differ diff --git a/src/slalib/sun67.htx/img189.gif b/src/slalib/sun67.htx/img189.gif new file mode 100644 index 0000000..3175bde Binary files /dev/null and b/src/slalib/sun67.htx/img189.gif differ diff --git a/src/slalib/sun67.htx/img19.gif b/src/slalib/sun67.htx/img19.gif new file mode 100644 index 0000000..8f39094 Binary files /dev/null and b/src/slalib/sun67.htx/img19.gif differ diff --git a/src/slalib/sun67.htx/img190.gif b/src/slalib/sun67.htx/img190.gif new file mode 100644 index 0000000..b4ad9b4 Binary files /dev/null and b/src/slalib/sun67.htx/img190.gif differ diff --git a/src/slalib/sun67.htx/img191.gif b/src/slalib/sun67.htx/img191.gif new file mode 100644 index 0000000..2f75e01 Binary files /dev/null and b/src/slalib/sun67.htx/img191.gif differ diff --git a/src/slalib/sun67.htx/img192.gif b/src/slalib/sun67.htx/img192.gif new file mode 100644 index 0000000..8e73a57 Binary files /dev/null and b/src/slalib/sun67.htx/img192.gif differ diff --git a/src/slalib/sun67.htx/img193.gif b/src/slalib/sun67.htx/img193.gif new file mode 100644 index 0000000..6cfd3d7 Binary files /dev/null and b/src/slalib/sun67.htx/img193.gif differ diff --git a/src/slalib/sun67.htx/img194.gif b/src/slalib/sun67.htx/img194.gif new file mode 100644 index 0000000..8c60dba Binary files /dev/null and b/src/slalib/sun67.htx/img194.gif differ diff --git a/src/slalib/sun67.htx/img195.gif b/src/slalib/sun67.htx/img195.gif new file mode 100644 index 0000000..e61b714 Binary files /dev/null and b/src/slalib/sun67.htx/img195.gif differ diff --git a/src/slalib/sun67.htx/img196.gif b/src/slalib/sun67.htx/img196.gif new file mode 100644 index 0000000..eb4f3bd Binary files /dev/null and b/src/slalib/sun67.htx/img196.gif differ diff --git a/src/slalib/sun67.htx/img197.gif b/src/slalib/sun67.htx/img197.gif new file mode 100644 index 0000000..c8e679f Binary files /dev/null and b/src/slalib/sun67.htx/img197.gif differ diff --git a/src/slalib/sun67.htx/img198.gif b/src/slalib/sun67.htx/img198.gif new file mode 100644 index 0000000..6ef5f3a Binary files /dev/null and b/src/slalib/sun67.htx/img198.gif differ diff --git a/src/slalib/sun67.htx/img199.gif b/src/slalib/sun67.htx/img199.gif new file mode 100644 index 0000000..13d024d Binary files /dev/null and b/src/slalib/sun67.htx/img199.gif differ diff --git a/src/slalib/sun67.htx/img2.gif b/src/slalib/sun67.htx/img2.gif new file mode 100644 index 0000000..cd0188c Binary files /dev/null and b/src/slalib/sun67.htx/img2.gif differ diff --git a/src/slalib/sun67.htx/img20.gif b/src/slalib/sun67.htx/img20.gif new file mode 100644 index 0000000..92345b7 Binary files /dev/null and b/src/slalib/sun67.htx/img20.gif differ diff --git a/src/slalib/sun67.htx/img200.gif b/src/slalib/sun67.htx/img200.gif new file mode 100644 index 0000000..895bb1e Binary files /dev/null and b/src/slalib/sun67.htx/img200.gif differ diff --git a/src/slalib/sun67.htx/img201.gif b/src/slalib/sun67.htx/img201.gif new file mode 100644 index 0000000..e321eae Binary files /dev/null and b/src/slalib/sun67.htx/img201.gif differ diff --git a/src/slalib/sun67.htx/img202.gif b/src/slalib/sun67.htx/img202.gif new file mode 100644 index 0000000..ee8b36c Binary files /dev/null and b/src/slalib/sun67.htx/img202.gif differ diff --git a/src/slalib/sun67.htx/img203.gif b/src/slalib/sun67.htx/img203.gif new file mode 100644 index 0000000..0953ef2 Binary files /dev/null and b/src/slalib/sun67.htx/img203.gif differ diff --git a/src/slalib/sun67.htx/img204.gif b/src/slalib/sun67.htx/img204.gif new file mode 100644 index 0000000..3f2f023 Binary files /dev/null and b/src/slalib/sun67.htx/img204.gif differ diff --git a/src/slalib/sun67.htx/img205.gif b/src/slalib/sun67.htx/img205.gif new file mode 100644 index 0000000..4c352e9 Binary files /dev/null and b/src/slalib/sun67.htx/img205.gif differ diff --git a/src/slalib/sun67.htx/img206.gif b/src/slalib/sun67.htx/img206.gif new file mode 100644 index 0000000..04a0557 Binary files /dev/null and b/src/slalib/sun67.htx/img206.gif differ diff --git a/src/slalib/sun67.htx/img207.gif b/src/slalib/sun67.htx/img207.gif new file mode 100644 index 0000000..91d7a83 Binary files /dev/null and b/src/slalib/sun67.htx/img207.gif differ diff --git a/src/slalib/sun67.htx/img208.gif b/src/slalib/sun67.htx/img208.gif new file mode 100644 index 0000000..eb1fd5f Binary files /dev/null and b/src/slalib/sun67.htx/img208.gif differ diff --git a/src/slalib/sun67.htx/img209.gif b/src/slalib/sun67.htx/img209.gif new file mode 100644 index 0000000..602560b Binary files /dev/null and b/src/slalib/sun67.htx/img209.gif differ diff --git a/src/slalib/sun67.htx/img21.gif b/src/slalib/sun67.htx/img21.gif new file mode 100644 index 0000000..88688bd Binary files /dev/null and b/src/slalib/sun67.htx/img21.gif differ diff --git a/src/slalib/sun67.htx/img210.gif b/src/slalib/sun67.htx/img210.gif new file mode 100644 index 0000000..e0f60e8 Binary files /dev/null and b/src/slalib/sun67.htx/img210.gif differ diff --git a/src/slalib/sun67.htx/img211.gif b/src/slalib/sun67.htx/img211.gif new file mode 100644 index 0000000..b3b874b Binary files /dev/null and b/src/slalib/sun67.htx/img211.gif differ diff --git a/src/slalib/sun67.htx/img212.gif b/src/slalib/sun67.htx/img212.gif new file mode 100644 index 0000000..b0513df Binary files /dev/null and b/src/slalib/sun67.htx/img212.gif differ diff --git a/src/slalib/sun67.htx/img213.gif b/src/slalib/sun67.htx/img213.gif new file mode 100644 index 0000000..5a952ee Binary files /dev/null and b/src/slalib/sun67.htx/img213.gif differ diff --git a/src/slalib/sun67.htx/img214.gif b/src/slalib/sun67.htx/img214.gif new file mode 100644 index 0000000..663a28e Binary files /dev/null and b/src/slalib/sun67.htx/img214.gif differ diff --git a/src/slalib/sun67.htx/img215.gif b/src/slalib/sun67.htx/img215.gif new file mode 100644 index 0000000..00510af Binary files /dev/null and b/src/slalib/sun67.htx/img215.gif differ diff --git a/src/slalib/sun67.htx/img216.gif b/src/slalib/sun67.htx/img216.gif new file mode 100644 index 0000000..3732254 Binary files /dev/null and b/src/slalib/sun67.htx/img216.gif differ diff --git a/src/slalib/sun67.htx/img217.gif b/src/slalib/sun67.htx/img217.gif new file mode 100644 index 0000000..2a73dca Binary files /dev/null and b/src/slalib/sun67.htx/img217.gif differ diff --git a/src/slalib/sun67.htx/img218.gif b/src/slalib/sun67.htx/img218.gif new file mode 100644 index 0000000..3e8e21c Binary files /dev/null and b/src/slalib/sun67.htx/img218.gif differ diff --git a/src/slalib/sun67.htx/img219.gif b/src/slalib/sun67.htx/img219.gif new file mode 100644 index 0000000..c34ded4 Binary files /dev/null and b/src/slalib/sun67.htx/img219.gif differ diff --git a/src/slalib/sun67.htx/img22.gif b/src/slalib/sun67.htx/img22.gif new file mode 100644 index 0000000..3dd46fa Binary files /dev/null and b/src/slalib/sun67.htx/img22.gif differ diff --git a/src/slalib/sun67.htx/img220.gif b/src/slalib/sun67.htx/img220.gif new file mode 100644 index 0000000..c00a9e4 Binary files /dev/null and b/src/slalib/sun67.htx/img220.gif differ diff --git a/src/slalib/sun67.htx/img221.gif b/src/slalib/sun67.htx/img221.gif new file mode 100644 index 0000000..b6a457c Binary files /dev/null and b/src/slalib/sun67.htx/img221.gif differ diff --git a/src/slalib/sun67.htx/img222.gif b/src/slalib/sun67.htx/img222.gif new file mode 100644 index 0000000..241b1e9 Binary files /dev/null and b/src/slalib/sun67.htx/img222.gif differ diff --git a/src/slalib/sun67.htx/img223.gif b/src/slalib/sun67.htx/img223.gif new file mode 100644 index 0000000..095bdda Binary files /dev/null and b/src/slalib/sun67.htx/img223.gif differ diff --git a/src/slalib/sun67.htx/img224.gif b/src/slalib/sun67.htx/img224.gif new file mode 100644 index 0000000..3e54f3c Binary files /dev/null and b/src/slalib/sun67.htx/img224.gif differ diff --git a/src/slalib/sun67.htx/img225.gif b/src/slalib/sun67.htx/img225.gif new file mode 100644 index 0000000..5e132ae Binary files /dev/null and b/src/slalib/sun67.htx/img225.gif differ diff --git a/src/slalib/sun67.htx/img226.gif b/src/slalib/sun67.htx/img226.gif new file mode 100644 index 0000000..b256d3d Binary files /dev/null and b/src/slalib/sun67.htx/img226.gif differ diff --git a/src/slalib/sun67.htx/img227.gif b/src/slalib/sun67.htx/img227.gif new file mode 100644 index 0000000..7d27a2c Binary files /dev/null and b/src/slalib/sun67.htx/img227.gif differ diff --git a/src/slalib/sun67.htx/img228.gif b/src/slalib/sun67.htx/img228.gif new file mode 100644 index 0000000..22b47de Binary files /dev/null and b/src/slalib/sun67.htx/img228.gif differ diff --git a/src/slalib/sun67.htx/img229.gif b/src/slalib/sun67.htx/img229.gif new file mode 100644 index 0000000..cc99808 Binary files /dev/null and b/src/slalib/sun67.htx/img229.gif differ diff --git a/src/slalib/sun67.htx/img23.gif b/src/slalib/sun67.htx/img23.gif new file mode 100644 index 0000000..0f08bbb Binary files /dev/null and b/src/slalib/sun67.htx/img23.gif differ diff --git a/src/slalib/sun67.htx/img230.gif b/src/slalib/sun67.htx/img230.gif new file mode 100644 index 0000000..7485114 Binary files /dev/null and b/src/slalib/sun67.htx/img230.gif differ diff --git a/src/slalib/sun67.htx/img231.gif b/src/slalib/sun67.htx/img231.gif new file mode 100644 index 0000000..8697b87 Binary files /dev/null and b/src/slalib/sun67.htx/img231.gif differ diff --git a/src/slalib/sun67.htx/img232.gif b/src/slalib/sun67.htx/img232.gif new file mode 100644 index 0000000..27ff60f Binary files /dev/null and b/src/slalib/sun67.htx/img232.gif differ diff --git a/src/slalib/sun67.htx/img233.gif b/src/slalib/sun67.htx/img233.gif new file mode 100644 index 0000000..9c8cba5 Binary files /dev/null and b/src/slalib/sun67.htx/img233.gif differ diff --git a/src/slalib/sun67.htx/img234.gif b/src/slalib/sun67.htx/img234.gif new file mode 100644 index 0000000..459ccad Binary files /dev/null and b/src/slalib/sun67.htx/img234.gif differ diff --git a/src/slalib/sun67.htx/img235.gif b/src/slalib/sun67.htx/img235.gif new file mode 100644 index 0000000..b225074 Binary files /dev/null and b/src/slalib/sun67.htx/img235.gif differ diff --git a/src/slalib/sun67.htx/img236.gif b/src/slalib/sun67.htx/img236.gif new file mode 100644 index 0000000..a784467 Binary files /dev/null and b/src/slalib/sun67.htx/img236.gif differ diff --git a/src/slalib/sun67.htx/img237.gif b/src/slalib/sun67.htx/img237.gif new file mode 100644 index 0000000..3683e0a Binary files /dev/null and b/src/slalib/sun67.htx/img237.gif differ diff --git a/src/slalib/sun67.htx/img238.gif b/src/slalib/sun67.htx/img238.gif new file mode 100644 index 0000000..7f5312d Binary files /dev/null and b/src/slalib/sun67.htx/img238.gif differ diff --git a/src/slalib/sun67.htx/img239.gif b/src/slalib/sun67.htx/img239.gif new file mode 100644 index 0000000..6127867 Binary files /dev/null and b/src/slalib/sun67.htx/img239.gif differ diff --git a/src/slalib/sun67.htx/img24.gif b/src/slalib/sun67.htx/img24.gif new file mode 100644 index 0000000..259482f Binary files /dev/null and b/src/slalib/sun67.htx/img24.gif differ diff --git a/src/slalib/sun67.htx/img240.gif b/src/slalib/sun67.htx/img240.gif new file mode 100644 index 0000000..6ed8940 Binary files /dev/null and b/src/slalib/sun67.htx/img240.gif differ diff --git a/src/slalib/sun67.htx/img241.gif b/src/slalib/sun67.htx/img241.gif new file mode 100644 index 0000000..b381cfb Binary files /dev/null and b/src/slalib/sun67.htx/img241.gif differ diff --git a/src/slalib/sun67.htx/img242.gif b/src/slalib/sun67.htx/img242.gif new file mode 100644 index 0000000..ef74cab Binary files /dev/null and b/src/slalib/sun67.htx/img242.gif differ diff --git a/src/slalib/sun67.htx/img243.gif b/src/slalib/sun67.htx/img243.gif new file mode 100644 index 0000000..c2ea4ad Binary files /dev/null and b/src/slalib/sun67.htx/img243.gif differ diff --git a/src/slalib/sun67.htx/img244.gif b/src/slalib/sun67.htx/img244.gif new file mode 100644 index 0000000..5f3f596 Binary files /dev/null and b/src/slalib/sun67.htx/img244.gif differ diff --git a/src/slalib/sun67.htx/img245.gif b/src/slalib/sun67.htx/img245.gif new file mode 100644 index 0000000..cb55533 Binary files /dev/null and b/src/slalib/sun67.htx/img245.gif differ diff --git a/src/slalib/sun67.htx/img246.gif b/src/slalib/sun67.htx/img246.gif new file mode 100644 index 0000000..567566b Binary files /dev/null and b/src/slalib/sun67.htx/img246.gif differ diff --git a/src/slalib/sun67.htx/img247.gif b/src/slalib/sun67.htx/img247.gif new file mode 100644 index 0000000..3a037ac Binary files /dev/null and b/src/slalib/sun67.htx/img247.gif differ diff --git a/src/slalib/sun67.htx/img248.gif b/src/slalib/sun67.htx/img248.gif new file mode 100644 index 0000000..56d7052 Binary files /dev/null and b/src/slalib/sun67.htx/img248.gif differ diff --git a/src/slalib/sun67.htx/img249.gif b/src/slalib/sun67.htx/img249.gif new file mode 100644 index 0000000..410a2e1 Binary files /dev/null and b/src/slalib/sun67.htx/img249.gif differ diff --git a/src/slalib/sun67.htx/img25.gif b/src/slalib/sun67.htx/img25.gif new file mode 100644 index 0000000..c23b91f Binary files /dev/null and b/src/slalib/sun67.htx/img25.gif differ diff --git a/src/slalib/sun67.htx/img250.gif b/src/slalib/sun67.htx/img250.gif new file mode 100644 index 0000000..7f14038 Binary files /dev/null and b/src/slalib/sun67.htx/img250.gif differ diff --git a/src/slalib/sun67.htx/img251.gif b/src/slalib/sun67.htx/img251.gif new file mode 100644 index 0000000..d6b6e3b Binary files /dev/null and b/src/slalib/sun67.htx/img251.gif differ diff --git a/src/slalib/sun67.htx/img252.gif b/src/slalib/sun67.htx/img252.gif new file mode 100644 index 0000000..6498340 Binary files /dev/null and b/src/slalib/sun67.htx/img252.gif differ diff --git a/src/slalib/sun67.htx/img253.gif b/src/slalib/sun67.htx/img253.gif new file mode 100644 index 0000000..0bebbe9 Binary files /dev/null and b/src/slalib/sun67.htx/img253.gif differ diff --git a/src/slalib/sun67.htx/img254.gif b/src/slalib/sun67.htx/img254.gif new file mode 100644 index 0000000..14c9013 Binary files /dev/null and b/src/slalib/sun67.htx/img254.gif differ diff --git a/src/slalib/sun67.htx/img255.gif b/src/slalib/sun67.htx/img255.gif new file mode 100644 index 0000000..8d24328 Binary files /dev/null and b/src/slalib/sun67.htx/img255.gif differ diff --git a/src/slalib/sun67.htx/img256.gif b/src/slalib/sun67.htx/img256.gif new file mode 100644 index 0000000..fc390da Binary files /dev/null and b/src/slalib/sun67.htx/img256.gif differ diff --git a/src/slalib/sun67.htx/img257.gif b/src/slalib/sun67.htx/img257.gif new file mode 100644 index 0000000..5f3d164 Binary files /dev/null and b/src/slalib/sun67.htx/img257.gif differ diff --git a/src/slalib/sun67.htx/img258.gif b/src/slalib/sun67.htx/img258.gif new file mode 100644 index 0000000..24d889b Binary files /dev/null and b/src/slalib/sun67.htx/img258.gif differ diff --git a/src/slalib/sun67.htx/img259.gif b/src/slalib/sun67.htx/img259.gif new file mode 100644 index 0000000..74f348d Binary files /dev/null and b/src/slalib/sun67.htx/img259.gif differ diff --git a/src/slalib/sun67.htx/img26.gif b/src/slalib/sun67.htx/img26.gif new file mode 100644 index 0000000..c9c0f27 Binary files /dev/null and b/src/slalib/sun67.htx/img26.gif differ diff --git a/src/slalib/sun67.htx/img260.gif b/src/slalib/sun67.htx/img260.gif new file mode 100644 index 0000000..1b6f66e Binary files /dev/null and b/src/slalib/sun67.htx/img260.gif differ diff --git a/src/slalib/sun67.htx/img261.gif b/src/slalib/sun67.htx/img261.gif new file mode 100644 index 0000000..746b653 Binary files /dev/null and b/src/slalib/sun67.htx/img261.gif differ diff --git a/src/slalib/sun67.htx/img262.gif b/src/slalib/sun67.htx/img262.gif new file mode 100644 index 0000000..254abab Binary files /dev/null and b/src/slalib/sun67.htx/img262.gif differ diff --git a/src/slalib/sun67.htx/img263.gif b/src/slalib/sun67.htx/img263.gif new file mode 100644 index 0000000..4d4381b Binary files /dev/null and b/src/slalib/sun67.htx/img263.gif differ diff --git a/src/slalib/sun67.htx/img264.gif b/src/slalib/sun67.htx/img264.gif new file mode 100644 index 0000000..8558d6d Binary files /dev/null and b/src/slalib/sun67.htx/img264.gif differ diff --git a/src/slalib/sun67.htx/img265.gif b/src/slalib/sun67.htx/img265.gif new file mode 100644 index 0000000..a1ece2d Binary files /dev/null and b/src/slalib/sun67.htx/img265.gif differ diff --git a/src/slalib/sun67.htx/img266.gif b/src/slalib/sun67.htx/img266.gif new file mode 100644 index 0000000..fb6e395 Binary files /dev/null and b/src/slalib/sun67.htx/img266.gif differ diff --git a/src/slalib/sun67.htx/img267.gif b/src/slalib/sun67.htx/img267.gif new file mode 100644 index 0000000..ffb5689 Binary files /dev/null and b/src/slalib/sun67.htx/img267.gif differ diff --git a/src/slalib/sun67.htx/img268.gif b/src/slalib/sun67.htx/img268.gif new file mode 100644 index 0000000..939b3b0 Binary files /dev/null and b/src/slalib/sun67.htx/img268.gif differ diff --git a/src/slalib/sun67.htx/img269.gif b/src/slalib/sun67.htx/img269.gif new file mode 100644 index 0000000..332c9c2 Binary files /dev/null and b/src/slalib/sun67.htx/img269.gif differ diff --git a/src/slalib/sun67.htx/img27.gif b/src/slalib/sun67.htx/img27.gif new file mode 100644 index 0000000..4bef4a6 Binary files /dev/null and b/src/slalib/sun67.htx/img27.gif differ diff --git a/src/slalib/sun67.htx/img270.gif b/src/slalib/sun67.htx/img270.gif new file mode 100644 index 0000000..d8f8eae Binary files /dev/null and b/src/slalib/sun67.htx/img270.gif differ diff --git a/src/slalib/sun67.htx/img271.gif b/src/slalib/sun67.htx/img271.gif new file mode 100644 index 0000000..fd26501 Binary files /dev/null and b/src/slalib/sun67.htx/img271.gif differ diff --git a/src/slalib/sun67.htx/img272.gif b/src/slalib/sun67.htx/img272.gif new file mode 100644 index 0000000..446ed83 Binary files /dev/null and b/src/slalib/sun67.htx/img272.gif differ diff --git a/src/slalib/sun67.htx/img273.gif b/src/slalib/sun67.htx/img273.gif new file mode 100644 index 0000000..b2fae8a Binary files /dev/null and b/src/slalib/sun67.htx/img273.gif differ diff --git a/src/slalib/sun67.htx/img274.gif b/src/slalib/sun67.htx/img274.gif new file mode 100644 index 0000000..283bafa Binary files /dev/null and b/src/slalib/sun67.htx/img274.gif differ diff --git a/src/slalib/sun67.htx/img275.gif b/src/slalib/sun67.htx/img275.gif new file mode 100644 index 0000000..577f461 Binary files /dev/null and b/src/slalib/sun67.htx/img275.gif differ diff --git a/src/slalib/sun67.htx/img276.gif b/src/slalib/sun67.htx/img276.gif new file mode 100644 index 0000000..7f22c78 Binary files /dev/null and b/src/slalib/sun67.htx/img276.gif differ diff --git a/src/slalib/sun67.htx/img277.gif b/src/slalib/sun67.htx/img277.gif new file mode 100644 index 0000000..18d807e Binary files /dev/null and b/src/slalib/sun67.htx/img277.gif differ diff --git a/src/slalib/sun67.htx/img278.gif b/src/slalib/sun67.htx/img278.gif new file mode 100644 index 0000000..c6ed15c Binary files /dev/null and b/src/slalib/sun67.htx/img278.gif differ diff --git a/src/slalib/sun67.htx/img279.gif b/src/slalib/sun67.htx/img279.gif new file mode 100644 index 0000000..351f567 Binary files /dev/null and b/src/slalib/sun67.htx/img279.gif differ diff --git a/src/slalib/sun67.htx/img28.gif b/src/slalib/sun67.htx/img28.gif new file mode 100644 index 0000000..4b6919a Binary files /dev/null and b/src/slalib/sun67.htx/img28.gif differ diff --git a/src/slalib/sun67.htx/img280.gif b/src/slalib/sun67.htx/img280.gif new file mode 100644 index 0000000..c228be9 Binary files /dev/null and b/src/slalib/sun67.htx/img280.gif differ diff --git a/src/slalib/sun67.htx/img281.gif b/src/slalib/sun67.htx/img281.gif new file mode 100644 index 0000000..8d51a56 Binary files /dev/null and b/src/slalib/sun67.htx/img281.gif differ diff --git a/src/slalib/sun67.htx/img282.gif b/src/slalib/sun67.htx/img282.gif new file mode 100644 index 0000000..aa9287e Binary files /dev/null and b/src/slalib/sun67.htx/img282.gif differ diff --git a/src/slalib/sun67.htx/img283.gif b/src/slalib/sun67.htx/img283.gif new file mode 100644 index 0000000..fb8d1b1 Binary files /dev/null and b/src/slalib/sun67.htx/img283.gif differ diff --git a/src/slalib/sun67.htx/img284.gif b/src/slalib/sun67.htx/img284.gif new file mode 100644 index 0000000..fbd698f Binary files /dev/null and b/src/slalib/sun67.htx/img284.gif differ diff --git a/src/slalib/sun67.htx/img285.gif b/src/slalib/sun67.htx/img285.gif new file mode 100644 index 0000000..5685c53 Binary files /dev/null and b/src/slalib/sun67.htx/img285.gif differ diff --git a/src/slalib/sun67.htx/img286.gif b/src/slalib/sun67.htx/img286.gif new file mode 100644 index 0000000..3af2f57 Binary files /dev/null and b/src/slalib/sun67.htx/img286.gif differ diff --git a/src/slalib/sun67.htx/img287.gif b/src/slalib/sun67.htx/img287.gif new file mode 100644 index 0000000..a908eb7 Binary files /dev/null and b/src/slalib/sun67.htx/img287.gif differ diff --git a/src/slalib/sun67.htx/img288.gif b/src/slalib/sun67.htx/img288.gif new file mode 100644 index 0000000..5c741bf Binary files /dev/null and b/src/slalib/sun67.htx/img288.gif differ diff --git a/src/slalib/sun67.htx/img289.gif b/src/slalib/sun67.htx/img289.gif new file mode 100644 index 0000000..851a6bd Binary files /dev/null and b/src/slalib/sun67.htx/img289.gif differ diff --git a/src/slalib/sun67.htx/img29.gif b/src/slalib/sun67.htx/img29.gif new file mode 100644 index 0000000..79608f4 Binary files /dev/null and b/src/slalib/sun67.htx/img29.gif differ diff --git a/src/slalib/sun67.htx/img290.gif b/src/slalib/sun67.htx/img290.gif new file mode 100644 index 0000000..9d978a9 Binary files /dev/null and b/src/slalib/sun67.htx/img290.gif differ diff --git a/src/slalib/sun67.htx/img291.gif b/src/slalib/sun67.htx/img291.gif new file mode 100644 index 0000000..558f6bd Binary files /dev/null and b/src/slalib/sun67.htx/img291.gif differ diff --git a/src/slalib/sun67.htx/img292.gif b/src/slalib/sun67.htx/img292.gif new file mode 100644 index 0000000..7d1dea2 Binary files /dev/null and b/src/slalib/sun67.htx/img292.gif differ diff --git a/src/slalib/sun67.htx/img293.gif b/src/slalib/sun67.htx/img293.gif new file mode 100644 index 0000000..9bdcea6 Binary files /dev/null and b/src/slalib/sun67.htx/img293.gif differ diff --git a/src/slalib/sun67.htx/img294.gif b/src/slalib/sun67.htx/img294.gif new file mode 100644 index 0000000..405e13e Binary files /dev/null and b/src/slalib/sun67.htx/img294.gif differ diff --git a/src/slalib/sun67.htx/img295.gif b/src/slalib/sun67.htx/img295.gif new file mode 100644 index 0000000..3ed0af7 Binary files /dev/null and b/src/slalib/sun67.htx/img295.gif differ diff --git a/src/slalib/sun67.htx/img296.gif b/src/slalib/sun67.htx/img296.gif new file mode 100644 index 0000000..a627d43 Binary files /dev/null and b/src/slalib/sun67.htx/img296.gif differ diff --git a/src/slalib/sun67.htx/img297.gif b/src/slalib/sun67.htx/img297.gif new file mode 100644 index 0000000..9975e0d Binary files /dev/null and b/src/slalib/sun67.htx/img297.gif differ diff --git a/src/slalib/sun67.htx/img298.gif b/src/slalib/sun67.htx/img298.gif new file mode 100644 index 0000000..c3b3df9 Binary files /dev/null and b/src/slalib/sun67.htx/img298.gif differ diff --git a/src/slalib/sun67.htx/img299.gif b/src/slalib/sun67.htx/img299.gif new file mode 100644 index 0000000..26aea95 Binary files /dev/null and b/src/slalib/sun67.htx/img299.gif differ diff --git a/src/slalib/sun67.htx/img3.gif b/src/slalib/sun67.htx/img3.gif new file mode 100644 index 0000000..28305ee Binary files /dev/null and b/src/slalib/sun67.htx/img3.gif differ diff --git a/src/slalib/sun67.htx/img30.gif b/src/slalib/sun67.htx/img30.gif new file mode 100644 index 0000000..58742b5 Binary files /dev/null and b/src/slalib/sun67.htx/img30.gif differ diff --git a/src/slalib/sun67.htx/img300.gif b/src/slalib/sun67.htx/img300.gif new file mode 100644 index 0000000..efe55e8 Binary files /dev/null and b/src/slalib/sun67.htx/img300.gif differ diff --git a/src/slalib/sun67.htx/img301.gif b/src/slalib/sun67.htx/img301.gif new file mode 100644 index 0000000..0f38885 Binary files /dev/null and b/src/slalib/sun67.htx/img301.gif differ diff --git a/src/slalib/sun67.htx/img302.gif b/src/slalib/sun67.htx/img302.gif new file mode 100644 index 0000000..7007302 Binary files /dev/null and b/src/slalib/sun67.htx/img302.gif differ diff --git a/src/slalib/sun67.htx/img303.gif b/src/slalib/sun67.htx/img303.gif new file mode 100644 index 0000000..ceca088 Binary files /dev/null and b/src/slalib/sun67.htx/img303.gif differ diff --git a/src/slalib/sun67.htx/img304.gif b/src/slalib/sun67.htx/img304.gif new file mode 100644 index 0000000..d468e94 Binary files /dev/null and b/src/slalib/sun67.htx/img304.gif differ diff --git a/src/slalib/sun67.htx/img305.gif b/src/slalib/sun67.htx/img305.gif new file mode 100644 index 0000000..eea091b Binary files /dev/null and b/src/slalib/sun67.htx/img305.gif differ diff --git a/src/slalib/sun67.htx/img306.gif b/src/slalib/sun67.htx/img306.gif new file mode 100644 index 0000000..03e13a7 Binary files /dev/null and b/src/slalib/sun67.htx/img306.gif differ diff --git a/src/slalib/sun67.htx/img307.gif b/src/slalib/sun67.htx/img307.gif new file mode 100644 index 0000000..cb79407 Binary files /dev/null and b/src/slalib/sun67.htx/img307.gif differ diff --git a/src/slalib/sun67.htx/img308.gif b/src/slalib/sun67.htx/img308.gif new file mode 100644 index 0000000..1cd3549 Binary files /dev/null and b/src/slalib/sun67.htx/img308.gif differ diff --git a/src/slalib/sun67.htx/img309.gif b/src/slalib/sun67.htx/img309.gif new file mode 100644 index 0000000..4233e9b Binary files /dev/null and b/src/slalib/sun67.htx/img309.gif differ diff --git a/src/slalib/sun67.htx/img31.gif b/src/slalib/sun67.htx/img31.gif new file mode 100644 index 0000000..428c955 Binary files /dev/null and b/src/slalib/sun67.htx/img31.gif differ diff --git a/src/slalib/sun67.htx/img310.gif b/src/slalib/sun67.htx/img310.gif new file mode 100644 index 0000000..309e909 Binary files /dev/null and b/src/slalib/sun67.htx/img310.gif differ diff --git a/src/slalib/sun67.htx/img311.gif b/src/slalib/sun67.htx/img311.gif new file mode 100644 index 0000000..f00e788 Binary files /dev/null and b/src/slalib/sun67.htx/img311.gif differ diff --git a/src/slalib/sun67.htx/img312.gif b/src/slalib/sun67.htx/img312.gif new file mode 100644 index 0000000..16e6dc2 Binary files /dev/null and b/src/slalib/sun67.htx/img312.gif differ diff --git a/src/slalib/sun67.htx/img313.gif b/src/slalib/sun67.htx/img313.gif new file mode 100644 index 0000000..8c3bfe9 Binary files /dev/null and b/src/slalib/sun67.htx/img313.gif differ diff --git a/src/slalib/sun67.htx/img314.gif b/src/slalib/sun67.htx/img314.gif new file mode 100644 index 0000000..181b5dd Binary files /dev/null and b/src/slalib/sun67.htx/img314.gif differ diff --git a/src/slalib/sun67.htx/img315.gif b/src/slalib/sun67.htx/img315.gif new file mode 100644 index 0000000..73700d7 Binary files /dev/null and b/src/slalib/sun67.htx/img315.gif differ diff --git a/src/slalib/sun67.htx/img316.gif b/src/slalib/sun67.htx/img316.gif new file mode 100644 index 0000000..abcc748 Binary files /dev/null and b/src/slalib/sun67.htx/img316.gif differ diff --git a/src/slalib/sun67.htx/img317.gif b/src/slalib/sun67.htx/img317.gif new file mode 100644 index 0000000..67607bd Binary files /dev/null and b/src/slalib/sun67.htx/img317.gif differ diff --git a/src/slalib/sun67.htx/img318.gif b/src/slalib/sun67.htx/img318.gif new file mode 100644 index 0000000..9d0e3ab Binary files /dev/null and b/src/slalib/sun67.htx/img318.gif differ diff --git a/src/slalib/sun67.htx/img319.gif b/src/slalib/sun67.htx/img319.gif new file mode 100644 index 0000000..12cac0b Binary files /dev/null and b/src/slalib/sun67.htx/img319.gif differ diff --git a/src/slalib/sun67.htx/img32.gif b/src/slalib/sun67.htx/img32.gif new file mode 100644 index 0000000..9fe70ea Binary files /dev/null and b/src/slalib/sun67.htx/img32.gif differ diff --git a/src/slalib/sun67.htx/img320.gif b/src/slalib/sun67.htx/img320.gif new file mode 100644 index 0000000..2fa40fa Binary files /dev/null and b/src/slalib/sun67.htx/img320.gif differ diff --git a/src/slalib/sun67.htx/img321.gif b/src/slalib/sun67.htx/img321.gif new file mode 100644 index 0000000..14a0607 Binary files /dev/null and b/src/slalib/sun67.htx/img321.gif differ diff --git a/src/slalib/sun67.htx/img322.gif b/src/slalib/sun67.htx/img322.gif new file mode 100644 index 0000000..bc4b6b5 Binary files /dev/null and b/src/slalib/sun67.htx/img322.gif differ diff --git a/src/slalib/sun67.htx/img323.gif b/src/slalib/sun67.htx/img323.gif new file mode 100644 index 0000000..301d22c Binary files /dev/null and b/src/slalib/sun67.htx/img323.gif differ diff --git a/src/slalib/sun67.htx/img324.gif b/src/slalib/sun67.htx/img324.gif new file mode 100644 index 0000000..ac2beb5 Binary files /dev/null and b/src/slalib/sun67.htx/img324.gif differ diff --git a/src/slalib/sun67.htx/img325.gif b/src/slalib/sun67.htx/img325.gif new file mode 100644 index 0000000..257bb36 Binary files /dev/null and b/src/slalib/sun67.htx/img325.gif differ diff --git a/src/slalib/sun67.htx/img326.gif b/src/slalib/sun67.htx/img326.gif new file mode 100644 index 0000000..9e40eb5 Binary files /dev/null and b/src/slalib/sun67.htx/img326.gif differ diff --git a/src/slalib/sun67.htx/img327.gif b/src/slalib/sun67.htx/img327.gif new file mode 100644 index 0000000..0489499 Binary files /dev/null and b/src/slalib/sun67.htx/img327.gif differ diff --git a/src/slalib/sun67.htx/img328.gif b/src/slalib/sun67.htx/img328.gif new file mode 100644 index 0000000..adbcf42 Binary files /dev/null and b/src/slalib/sun67.htx/img328.gif differ diff --git a/src/slalib/sun67.htx/img329.gif b/src/slalib/sun67.htx/img329.gif new file mode 100644 index 0000000..10d6367 Binary files /dev/null and b/src/slalib/sun67.htx/img329.gif differ diff --git a/src/slalib/sun67.htx/img33.gif b/src/slalib/sun67.htx/img33.gif new file mode 100644 index 0000000..60cc80f Binary files /dev/null and b/src/slalib/sun67.htx/img33.gif differ diff --git a/src/slalib/sun67.htx/img330.gif b/src/slalib/sun67.htx/img330.gif new file mode 100644 index 0000000..894b280 Binary files /dev/null and b/src/slalib/sun67.htx/img330.gif differ diff --git a/src/slalib/sun67.htx/img34.gif b/src/slalib/sun67.htx/img34.gif new file mode 100644 index 0000000..3dca0ca Binary files /dev/null and b/src/slalib/sun67.htx/img34.gif differ diff --git a/src/slalib/sun67.htx/img35.gif b/src/slalib/sun67.htx/img35.gif new file mode 100644 index 0000000..19639cd Binary files /dev/null and b/src/slalib/sun67.htx/img35.gif differ diff --git a/src/slalib/sun67.htx/img36.gif b/src/slalib/sun67.htx/img36.gif new file mode 100644 index 0000000..2d50927 Binary files /dev/null and b/src/slalib/sun67.htx/img36.gif differ diff --git a/src/slalib/sun67.htx/img37.gif b/src/slalib/sun67.htx/img37.gif new file mode 100644 index 0000000..e5d5bf1 Binary files /dev/null and b/src/slalib/sun67.htx/img37.gif differ diff --git a/src/slalib/sun67.htx/img38.gif b/src/slalib/sun67.htx/img38.gif new file mode 100644 index 0000000..4bb025e Binary files /dev/null and b/src/slalib/sun67.htx/img38.gif differ diff --git a/src/slalib/sun67.htx/img39.gif b/src/slalib/sun67.htx/img39.gif new file mode 100644 index 0000000..395cb4c Binary files /dev/null and b/src/slalib/sun67.htx/img39.gif differ diff --git a/src/slalib/sun67.htx/img4.gif b/src/slalib/sun67.htx/img4.gif new file mode 100644 index 0000000..fdb8e23 Binary files /dev/null and b/src/slalib/sun67.htx/img4.gif differ diff --git a/src/slalib/sun67.htx/img40.gif b/src/slalib/sun67.htx/img40.gif new file mode 100644 index 0000000..50874f2 Binary files /dev/null and b/src/slalib/sun67.htx/img40.gif differ diff --git a/src/slalib/sun67.htx/img41.gif b/src/slalib/sun67.htx/img41.gif new file mode 100644 index 0000000..aa024b5 Binary files /dev/null and b/src/slalib/sun67.htx/img41.gif differ diff --git a/src/slalib/sun67.htx/img42.gif b/src/slalib/sun67.htx/img42.gif new file mode 100644 index 0000000..e5df416 Binary files /dev/null and b/src/slalib/sun67.htx/img42.gif differ diff --git a/src/slalib/sun67.htx/img43.gif b/src/slalib/sun67.htx/img43.gif new file mode 100644 index 0000000..793fdfe Binary files /dev/null and b/src/slalib/sun67.htx/img43.gif differ diff --git a/src/slalib/sun67.htx/img44.gif b/src/slalib/sun67.htx/img44.gif new file mode 100644 index 0000000..077f340 Binary files /dev/null and b/src/slalib/sun67.htx/img44.gif differ diff --git a/src/slalib/sun67.htx/img45.gif b/src/slalib/sun67.htx/img45.gif new file mode 100644 index 0000000..e3ff749 Binary files /dev/null and b/src/slalib/sun67.htx/img45.gif differ diff --git a/src/slalib/sun67.htx/img46.gif b/src/slalib/sun67.htx/img46.gif new file mode 100644 index 0000000..b0cf7e0 Binary files /dev/null and b/src/slalib/sun67.htx/img46.gif differ diff --git a/src/slalib/sun67.htx/img47.gif b/src/slalib/sun67.htx/img47.gif new file mode 100644 index 0000000..12601c3 Binary files /dev/null and b/src/slalib/sun67.htx/img47.gif differ diff --git a/src/slalib/sun67.htx/img48.gif b/src/slalib/sun67.htx/img48.gif new file mode 100644 index 0000000..a582489 Binary files /dev/null and b/src/slalib/sun67.htx/img48.gif differ diff --git a/src/slalib/sun67.htx/img49.gif b/src/slalib/sun67.htx/img49.gif new file mode 100644 index 0000000..ed7025f Binary files /dev/null and b/src/slalib/sun67.htx/img49.gif differ diff --git a/src/slalib/sun67.htx/img5.gif b/src/slalib/sun67.htx/img5.gif new file mode 100644 index 0000000..b692faf Binary files /dev/null and b/src/slalib/sun67.htx/img5.gif differ diff --git a/src/slalib/sun67.htx/img50.gif b/src/slalib/sun67.htx/img50.gif new file mode 100644 index 0000000..da83b3f Binary files /dev/null and b/src/slalib/sun67.htx/img50.gif differ diff --git a/src/slalib/sun67.htx/img51.gif b/src/slalib/sun67.htx/img51.gif new file mode 100644 index 0000000..eabbd1e Binary files /dev/null and b/src/slalib/sun67.htx/img51.gif differ diff --git a/src/slalib/sun67.htx/img52.gif b/src/slalib/sun67.htx/img52.gif new file mode 100644 index 0000000..5a84c00 Binary files /dev/null and b/src/slalib/sun67.htx/img52.gif differ diff --git a/src/slalib/sun67.htx/img53.gif b/src/slalib/sun67.htx/img53.gif new file mode 100644 index 0000000..384c210 Binary files /dev/null and b/src/slalib/sun67.htx/img53.gif differ diff --git a/src/slalib/sun67.htx/img54.gif b/src/slalib/sun67.htx/img54.gif new file mode 100644 index 0000000..da4e988 Binary files /dev/null and b/src/slalib/sun67.htx/img54.gif differ diff --git a/src/slalib/sun67.htx/img55.gif b/src/slalib/sun67.htx/img55.gif new file mode 100644 index 0000000..b312800 Binary files /dev/null and b/src/slalib/sun67.htx/img55.gif differ diff --git a/src/slalib/sun67.htx/img56.gif b/src/slalib/sun67.htx/img56.gif new file mode 100644 index 0000000..2faf373 Binary files /dev/null and b/src/slalib/sun67.htx/img56.gif differ diff --git a/src/slalib/sun67.htx/img57.gif b/src/slalib/sun67.htx/img57.gif new file mode 100644 index 0000000..84883c2 Binary files /dev/null and b/src/slalib/sun67.htx/img57.gif differ diff --git a/src/slalib/sun67.htx/img58.gif b/src/slalib/sun67.htx/img58.gif new file mode 100644 index 0000000..f2dc064 Binary files /dev/null and b/src/slalib/sun67.htx/img58.gif differ diff --git a/src/slalib/sun67.htx/img59.gif b/src/slalib/sun67.htx/img59.gif new file mode 100644 index 0000000..b17eac6 Binary files /dev/null and b/src/slalib/sun67.htx/img59.gif differ diff --git a/src/slalib/sun67.htx/img6.gif b/src/slalib/sun67.htx/img6.gif new file mode 100644 index 0000000..d06343f Binary files /dev/null and b/src/slalib/sun67.htx/img6.gif differ diff --git a/src/slalib/sun67.htx/img60.gif b/src/slalib/sun67.htx/img60.gif new file mode 100644 index 0000000..9367888 Binary files /dev/null and b/src/slalib/sun67.htx/img60.gif differ diff --git a/src/slalib/sun67.htx/img61.gif b/src/slalib/sun67.htx/img61.gif new file mode 100644 index 0000000..34173ab Binary files /dev/null and b/src/slalib/sun67.htx/img61.gif differ diff --git a/src/slalib/sun67.htx/img62.gif b/src/slalib/sun67.htx/img62.gif new file mode 100644 index 0000000..03d3e12 Binary files /dev/null and b/src/slalib/sun67.htx/img62.gif differ diff --git a/src/slalib/sun67.htx/img63.gif b/src/slalib/sun67.htx/img63.gif new file mode 100644 index 0000000..b64b4d8 Binary files /dev/null and b/src/slalib/sun67.htx/img63.gif differ diff --git a/src/slalib/sun67.htx/img64.gif b/src/slalib/sun67.htx/img64.gif new file mode 100644 index 0000000..69bef85 Binary files /dev/null and b/src/slalib/sun67.htx/img64.gif differ diff --git a/src/slalib/sun67.htx/img65.gif b/src/slalib/sun67.htx/img65.gif new file mode 100644 index 0000000..8faeca4 Binary files /dev/null and b/src/slalib/sun67.htx/img65.gif differ diff --git a/src/slalib/sun67.htx/img66.gif b/src/slalib/sun67.htx/img66.gif new file mode 100644 index 0000000..0437749 Binary files /dev/null and b/src/slalib/sun67.htx/img66.gif differ diff --git a/src/slalib/sun67.htx/img67.gif b/src/slalib/sun67.htx/img67.gif new file mode 100644 index 0000000..63fedd9 Binary files /dev/null and b/src/slalib/sun67.htx/img67.gif differ diff --git a/src/slalib/sun67.htx/img68.gif b/src/slalib/sun67.htx/img68.gif new file mode 100644 index 0000000..bd0d18f Binary files /dev/null and b/src/slalib/sun67.htx/img68.gif differ diff --git a/src/slalib/sun67.htx/img69.gif b/src/slalib/sun67.htx/img69.gif new file mode 100644 index 0000000..65f6ac6 Binary files /dev/null and b/src/slalib/sun67.htx/img69.gif differ diff --git a/src/slalib/sun67.htx/img7.gif b/src/slalib/sun67.htx/img7.gif new file mode 100644 index 0000000..4d54546 Binary files /dev/null and b/src/slalib/sun67.htx/img7.gif differ diff --git a/src/slalib/sun67.htx/img70.gif b/src/slalib/sun67.htx/img70.gif new file mode 100644 index 0000000..5711ca9 Binary files /dev/null and b/src/slalib/sun67.htx/img70.gif differ diff --git a/src/slalib/sun67.htx/img71.gif b/src/slalib/sun67.htx/img71.gif new file mode 100644 index 0000000..dcbde3c Binary files /dev/null and b/src/slalib/sun67.htx/img71.gif differ diff --git a/src/slalib/sun67.htx/img72.gif b/src/slalib/sun67.htx/img72.gif new file mode 100644 index 0000000..c58e3d1 Binary files /dev/null and b/src/slalib/sun67.htx/img72.gif differ diff --git a/src/slalib/sun67.htx/img73.gif b/src/slalib/sun67.htx/img73.gif new file mode 100644 index 0000000..37e1e89 Binary files /dev/null and b/src/slalib/sun67.htx/img73.gif differ diff --git a/src/slalib/sun67.htx/img74.gif b/src/slalib/sun67.htx/img74.gif new file mode 100644 index 0000000..01fee78 Binary files /dev/null and b/src/slalib/sun67.htx/img74.gif differ diff --git a/src/slalib/sun67.htx/img75.gif b/src/slalib/sun67.htx/img75.gif new file mode 100644 index 0000000..722695e Binary files /dev/null and b/src/slalib/sun67.htx/img75.gif differ diff --git a/src/slalib/sun67.htx/img76.gif b/src/slalib/sun67.htx/img76.gif new file mode 100644 index 0000000..50dea3d Binary files /dev/null and b/src/slalib/sun67.htx/img76.gif differ diff --git a/src/slalib/sun67.htx/img77.gif b/src/slalib/sun67.htx/img77.gif new file mode 100644 index 0000000..236375c Binary files /dev/null and b/src/slalib/sun67.htx/img77.gif differ diff --git a/src/slalib/sun67.htx/img78.gif b/src/slalib/sun67.htx/img78.gif new file mode 100644 index 0000000..d48830d Binary files /dev/null and b/src/slalib/sun67.htx/img78.gif differ diff --git a/src/slalib/sun67.htx/img79.gif b/src/slalib/sun67.htx/img79.gif new file mode 100644 index 0000000..26c8df8 Binary files /dev/null and b/src/slalib/sun67.htx/img79.gif differ diff --git a/src/slalib/sun67.htx/img8.gif b/src/slalib/sun67.htx/img8.gif new file mode 100644 index 0000000..aaabf5c Binary files /dev/null and b/src/slalib/sun67.htx/img8.gif differ diff --git a/src/slalib/sun67.htx/img80.gif b/src/slalib/sun67.htx/img80.gif new file mode 100644 index 0000000..a3d56cb Binary files /dev/null and b/src/slalib/sun67.htx/img80.gif differ diff --git a/src/slalib/sun67.htx/img81.gif b/src/slalib/sun67.htx/img81.gif new file mode 100644 index 0000000..e968ec3 Binary files /dev/null and b/src/slalib/sun67.htx/img81.gif differ diff --git a/src/slalib/sun67.htx/img82.gif b/src/slalib/sun67.htx/img82.gif new file mode 100644 index 0000000..7f9efc5 Binary files /dev/null and b/src/slalib/sun67.htx/img82.gif differ diff --git a/src/slalib/sun67.htx/img83.gif b/src/slalib/sun67.htx/img83.gif new file mode 100644 index 0000000..c8fb2dc Binary files /dev/null and b/src/slalib/sun67.htx/img83.gif differ diff --git a/src/slalib/sun67.htx/img84.gif b/src/slalib/sun67.htx/img84.gif new file mode 100644 index 0000000..567d43d Binary files /dev/null and b/src/slalib/sun67.htx/img84.gif differ diff --git a/src/slalib/sun67.htx/img85.gif b/src/slalib/sun67.htx/img85.gif new file mode 100644 index 0000000..a7fe52c Binary files /dev/null and b/src/slalib/sun67.htx/img85.gif differ diff --git a/src/slalib/sun67.htx/img86.gif b/src/slalib/sun67.htx/img86.gif new file mode 100644 index 0000000..dce1c63 Binary files /dev/null and b/src/slalib/sun67.htx/img86.gif differ diff --git a/src/slalib/sun67.htx/img87.gif b/src/slalib/sun67.htx/img87.gif new file mode 100644 index 0000000..063722f Binary files /dev/null and b/src/slalib/sun67.htx/img87.gif differ diff --git a/src/slalib/sun67.htx/img88.gif b/src/slalib/sun67.htx/img88.gif new file mode 100644 index 0000000..3ef4f13 Binary files /dev/null and b/src/slalib/sun67.htx/img88.gif differ diff --git a/src/slalib/sun67.htx/img89.gif b/src/slalib/sun67.htx/img89.gif new file mode 100644 index 0000000..ed6e37c Binary files /dev/null and b/src/slalib/sun67.htx/img89.gif differ diff --git a/src/slalib/sun67.htx/img9.gif b/src/slalib/sun67.htx/img9.gif new file mode 100644 index 0000000..b608337 Binary files /dev/null and b/src/slalib/sun67.htx/img9.gif differ diff --git a/src/slalib/sun67.htx/img90.gif b/src/slalib/sun67.htx/img90.gif new file mode 100644 index 0000000..b3b96dc Binary files /dev/null and b/src/slalib/sun67.htx/img90.gif differ diff --git a/src/slalib/sun67.htx/img91.gif b/src/slalib/sun67.htx/img91.gif new file mode 100644 index 0000000..b5bf656 Binary files /dev/null and b/src/slalib/sun67.htx/img91.gif differ diff --git a/src/slalib/sun67.htx/img92.gif b/src/slalib/sun67.htx/img92.gif new file mode 100644 index 0000000..8105c30 Binary files /dev/null and b/src/slalib/sun67.htx/img92.gif differ diff --git a/src/slalib/sun67.htx/img93.gif b/src/slalib/sun67.htx/img93.gif new file mode 100644 index 0000000..8f0e16c Binary files /dev/null and b/src/slalib/sun67.htx/img93.gif differ diff --git a/src/slalib/sun67.htx/img94.gif b/src/slalib/sun67.htx/img94.gif new file mode 100644 index 0000000..1dbd091 Binary files /dev/null and b/src/slalib/sun67.htx/img94.gif differ diff --git a/src/slalib/sun67.htx/img95.gif b/src/slalib/sun67.htx/img95.gif new file mode 100644 index 0000000..3ace0ea Binary files /dev/null and b/src/slalib/sun67.htx/img95.gif differ diff --git a/src/slalib/sun67.htx/img96.gif b/src/slalib/sun67.htx/img96.gif new file mode 100644 index 0000000..cf79e82 Binary files /dev/null and b/src/slalib/sun67.htx/img96.gif differ diff --git a/src/slalib/sun67.htx/img97.gif b/src/slalib/sun67.htx/img97.gif new file mode 100644 index 0000000..a1b4481 Binary files /dev/null and b/src/slalib/sun67.htx/img97.gif differ diff --git a/src/slalib/sun67.htx/img98.gif b/src/slalib/sun67.htx/img98.gif new file mode 100644 index 0000000..4acedf7 Binary files /dev/null and b/src/slalib/sun67.htx/img98.gif differ diff --git a/src/slalib/sun67.htx/img99.gif b/src/slalib/sun67.htx/img99.gif new file mode 100644 index 0000000..308e155 Binary files /dev/null and b/src/slalib/sun67.htx/img99.gif differ diff --git a/src/slalib/sun67.htx/index_motif.gif b/src/slalib/sun67.htx/index_motif.gif new file mode 100644 index 0000000..b9b3108 Binary files /dev/null and b/src/slalib/sun67.htx/index_motif.gif differ diff --git a/src/slalib/sun67.htx/internals.pl b/src/slalib/sun67.htx/internals.pl new file mode 100644 index 0000000..d340e74 --- /dev/null +++ b/src/slalib/sun67.htx/internals.pl @@ -0,0 +1,1482 @@ +# LaTeX2HTML 97.1 (release) (July 13th, 1997) +# Associate internals original text with physical files. + + +$key = q/SLA_DR2TF/; +$ref_files{$key} = "$dir".q|node67.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_OBS/; +$ref_files{$key} = "$dir".q|node137.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DD2TF/; +$ref_files{$key} = "$dir".q|node52.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DIMXV/; +$ref_files{$key} = "$dir".q|node57.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PRECL/; +$ref_files{$key} = "$dir".q|node154.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EVP/; +$ref_files{$key} = "$dir".q|node102.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FLOTIN/; +$ref_files{$key} = "$dir".q|node110.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTP2S/; +$ref_files{$key} = "$dir".q|node76.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RANGE/; +$ref_files{$key} = "$dir".q|node161.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_NUTC/; +$ref_files{$key} = "$dir".q|node134.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_TPV2C/; +$ref_files{$key} = "$dir".q|node186.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTP2V/; +$ref_files{$key} = "$dir".q|node77.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_VDV/; +$ref_files{$key} = "$dir".q|node191.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK52H/; +$ref_files{$key} = "$dir".q|node107.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DVN/; +$ref_files{$key} = "$dir".q|node83.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PREC/; +$ref_files{$key} = "$dir".q|node152.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EQECL/; +$ref_files{$key} = "$dir".q|node97.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_H2E/; +$ref_files{$key} = "$dir".q|node118.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AOP/; +$ref_files{$key} = "$dir".q|node20.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DS2C6/; +$ref_files{$key} = "$dir".q|node70.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DRANRM/; +$ref_files{$key} = "$dir".q|node69.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PAV/; +$ref_files{$key} = "$dir".q|node139.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FITXY/; +$ref_files{$key} = "$dir".q|node103.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CS2C/; +$ref_files{$key} = "$dir".q|node38.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CC2S/; +$ref_files{$key} = "$dir".q|node30.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DT/; +$ref_files{$key} = "$dir".q|node73.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PDA2H/; +$ref_files{$key} = "$dir".q|node141.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVLSRD/; +$ref_files{$key} = "$dir".q|node173.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EG50/; +$ref_files{$key} = "$dir".q|node90.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DMOON/; +$ref_files{$key} = "$dir".q|node62.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DJCAL/; +$ref_files{$key} = "$dir".q|node58.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AMP/; +$ref_files{$key} = "$dir".q|node18.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CD2TF/; +$ref_files{$key} = "$dir".q|node32.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EARTH/; +$ref_files{$key} = "$dir".q|node86.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_OAP/; +$ref_files{$key} = "$dir".q|node135.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RANDOM/; +$ref_files{$key} = "$dir".q|node160.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_WAIT/; +$ref_files{$key} = "$dir".q|node194.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AV2M/; +$ref_files{$key} = "$dir".q|node25.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_NUT/; +$ref_files{$key} = "$dir".q|node133.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SUBET/; +$ref_files{$key} = "$dir".q|node178.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVLSRK/; +$ref_files{$key} = "$dir".q|node174.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_BEAR/; +$ref_files{$key} = "$dir".q|node26.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PDQ2H/; +$ref_files{$key} = "$dir".q|node142.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CLYD/; +$ref_files{$key} = "$dir".q|node34.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_V2TP/; +$ref_files{$key} = "$dir".q|node190.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_INTIN/; +$ref_files{$key} = "$dir".q|node122.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_COMBN/; +$ref_files{$key} = "$dir".q|node35.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CTF2D/; +$ref_files{$key} = "$dir".q|node40.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK45Z/; +$ref_files{$key} = "$dir".q|node105.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DVXV/; +$ref_files{$key} = "$dir".q|node84.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_S2TP/; +$ref_files{$key} = "$dir".q|node175.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CALYD/; +$ref_files{$key} = "$dir".q|node29.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DCS2C/; +$ref_files{$key} = "$dir".q|node51.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DCC2S/; +$ref_files{$key} = "$dir".q|node49.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DAF2R/; +$ref_files{$key} = "$dir".q|node42.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFRO/; +$ref_files{$key} = "$dir".q|node167.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MXM/; +$ref_files{$key} = "$dir".q|node131.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CTF2R/; +$ref_files{$key} = "$dir".q|node41.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DC62S/; +$ref_files{$key} = "$dir".q|node48.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PCD/; +$ref_files{$key} = "$dir".q|node140.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_OBS/; +$ref_files{$key} = "$dir".q|node137.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DT/; +$ref_files{$key} = "$dir".q|node73.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DAV2M/; +$ref_files{$key} = "$dir".q|node45.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MXV/; +$ref_files{$key} = "$dir".q|node132.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_OAPQK/; +$ref_files{$key} = "$dir".q|node136.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EL2UE/; +$ref_files{$key} = "$dir".q|node91.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EULER/; +$ref_files{$key} = "$dir".q|node101.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVLSRD/; +$ref_files{$key} = "$dir".q|node173.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DBEAR/; +$ref_files{$key} = "$dir".q|node46.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EQGAL/; +$ref_files{$key} = "$dir".q|node99.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EVP/; +$ref_files{$key} = "$dir".q|node102.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RANDOM/; +$ref_files{$key} = "$dir".q|node160.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CR2AF/; +$ref_files{$key} = "$dir".q|node36.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFCO/; +$ref_files{$key} = "$dir".q|node165.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVLSRK/; +$ref_files{$key} = "$dir".q|node174.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_VDV/; +$ref_files{$key} = "$dir".q|node191.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPCO/; +$ref_files{$key} = "$dir".q|node94.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK54Z/; +$ref_files{$key} = "$dir".q|node108.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_M2AV/; +$ref_files{$key} = "$dir".q|node125.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK425/; +$ref_files{$key} = "$dir".q|node104.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DS2TP/; +$ref_files{$key} = "$dir".q|node71.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AOPPA/; +$ref_files{$key} = "$dir".q|node21.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GE50/; +$ref_files{$key} = "$dir".q|node113.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_H2E/; +$ref_files{$key} = "$dir".q|node118.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AOP/; +$ref_files{$key} = "$dir".q|node20.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DFLTIN/; +$ref_files{$key} = "$dir".q|node55.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_VN/; +$ref_files{$key} = "$dir".q|node192.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_UNPCD/; +$ref_files{$key} = "$dir".q|node189.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GMST/; +$ref_files{$key} = "$dir".q|node115.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PAV/; +$ref_files{$key} = "$dir".q|node139.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ALTAZ/; +$ref_files{$key} = "$dir".q|node17.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DJCL/; +$ref_files{$key} = "$dir".q|node59.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CC62S/; +$ref_files{$key} = "$dir".q|node31.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MAPPA/; +$ref_files{$key} = "$dir".q|node127.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DRANGE/; +$ref_files{$key} = "$dir".q|node68.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_UE2PV/; +$ref_files{$key} = "$dir".q|node188.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTPV2C/; +$ref_files{$key} = "$dir".q|node79.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DVDV/; +$ref_files{$key} = "$dir".q|node82.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_NUT/; +$ref_files{$key} = "$dir".q|node133.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ETRMS/; +$ref_files{$key} = "$dir".q|node100.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PRECES/; +$ref_files{$key} = "$dir".q|node153.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DAFIN/; +$ref_files{$key} = "$dir".q|node43.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PREBN/; +$ref_files{$key} = "$dir".q|node151.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DH2E/; +$ref_files{$key} = "$dir".q|node56.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AOPPAT/; +$ref_files{$key} = "$dir".q|node22.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AOPQK/; +$ref_files{$key} = "$dir".q|node23.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ECMAT/; +$ref_files{$key} = "$dir".q|node88.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DPAV/; +$ref_files{$key} = "$dir".q|node65.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_TPS2C/; +$ref_files{$key} = "$dir".q|node185.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SUPGAL/; +$ref_files{$key} = "$dir".q|node179.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DFLTIN/; +$ref_files{$key} = "$dir".q|node55.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_VXV/; +$ref_files{$key} = "$dir".q|node193.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_VN/; +$ref_files{$key} = "$dir".q|node192.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EQEQX/; +$ref_files{$key} = "$dir".q|node98.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MXM/; +$ref_files{$key} = "$dir".q|node131.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_POLMO/; +$ref_files{$key} = "$dir".q|node150.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_INVF/; +$ref_files{$key} = "$dir".q|node123.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DBJIN/; +$ref_files{$key} = "$dir".q|node47.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_XY2XY/; +$ref_files{$key} = "$dir".q|node195.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MAPQKZ/; +$ref_files{$key} = "$dir".q|node129.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ECOR/; +$ref_files{$key} = "$dir".q|node89.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PVOBS/; +$ref_files{$key} = "$dir".q|node158.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DCMPF/; +$ref_files{$key} = "$dir".q|node50.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PCD/; +$ref_files{$key} = "$dir".q|node140.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK524/; +$ref_files{$key} = "$dir".q|node106.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MAPQK/; +$ref_files{$key} = "$dir".q|node128.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MXV/; +$ref_files{$key} = "$dir".q|node132.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DRANGE/; +$ref_files{$key} = "$dir".q|node68.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GEOC/; +$ref_files{$key} = "$dir".q|node114.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTPV2C/; +$ref_files{$key} = "$dir".q|node79.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DD2TF/; +$ref_files{$key} = "$dir".q|node52.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SMAT/; +$ref_files{$key} = "$dir".q|node177.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RDPLAN/; +$ref_files{$key} = "$dir".q|node164.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PRECL/; +$ref_files{$key} = "$dir".q|node154.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PLANTE/; +$ref_files{$key} = "$dir".q|node148.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_IMXV/; +$ref_files{$key} = "$dir".q|node121.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MOON/; +$ref_files{$key} = "$dir".q|node130.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CLDJ/; +$ref_files{$key} = "$dir".q|node33.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_TP2S/; +$ref_files{$key} = "$dir".q|node183.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK52H/; +$ref_files{$key} = "$dir".q|node107.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_TP2V/; +$ref_files{$key} = "$dir".q|node184.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPB2D/; +$ref_files{$key} = "$dir".q|node93.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PRECES/; +$ref_files{$key} = "$dir".q|node153.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AOPPAT/; +$ref_files{$key} = "$dir".q|node22.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTF2D/; +$ref_files{$key} = "$dir".q|node74.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPJ2D/; +$ref_files{$key} = "$dir".q|node96.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DMXM/; +$ref_files{$key} = "$dir".q|node63.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EQECL/; +$ref_files{$key} = "$dir".q|node97.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SUPGAL/; +$ref_files{$key} = "$dir".q|node179.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVLG/; +$ref_files{$key} = "$dir".q|node172.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PLANEL/; +$ref_files{$key} = "$dir".q|node146.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DMXV/; +$ref_files{$key} = "$dir".q|node64.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FITXY/; +$ref_files{$key} = "$dir".q|node103.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MAPQKZ/; +$ref_files{$key} = "$dir".q|node129.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DEULER/; +$ref_files{$key} = "$dir".q|node54.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_/; +$ref_files{$key} = "$dir".q|sun67.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CR2TF/; +$ref_files{$key} = "$dir".q|node37.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTF2R/; +$ref_files{$key} = "$dir".q|node75.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PLANET/; +$ref_files{$key} = "$dir".q|node147.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RCC/; +$ref_files{$key} = "$dir".q|node163.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DMOON/; +$ref_files{$key} = "$dir".q|node62.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DJCAL/; +$ref_files{$key} = "$dir".q|node58.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ECLEQ/; +$ref_files{$key} = "$dir".q|node87.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RDPLAN/; +$ref_files{$key} = "$dir".q|node164.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DR2AF/; +$ref_files{$key} = "$dir".q|node66.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SUBET/; +$ref_files{$key} = "$dir".q|node178.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DV2TP/; +$ref_files{$key} = "$dir".q|node81.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PLANTE/; +$ref_files{$key} = "$dir".q|node148.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_COMBN/; +$ref_files{$key} = "$dir".q|node35.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CALDJ/; +$ref_files{$key} = "$dir".q|node28.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ZD/; +$ref_files{$key} = "$dir".q|node196.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CTF2D/; +$ref_files{$key} = "$dir".q|node40.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFV/; +$ref_files{$key} = "$dir".q|node168.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVGALC/; +$ref_files{$key} = "$dir".q|node171.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK45Z/; +$ref_files{$key} = "$dir".q|node105.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFCOQ/; +$ref_files{$key} = "$dir".q|node166.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CS2C6/; +$ref_files{$key} = "$dir".q|node39.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVEROT/; +$ref_files{$key} = "$dir".q|node170.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_KBJ/; +$ref_files{$key} = "$dir".q|node124.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFZ/; +$ref_files{$key} = "$dir".q|node169.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_VXV/; +$ref_files{$key} = "$dir".q|node193.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK5HZ/; +$ref_files{$key} = "$dir".q|node109.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PLANEL/; +$ref_files{$key} = "$dir".q|node146.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PV2EL/; +$ref_files{$key} = "$dir".q|node156.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFRO/; +$ref_files{$key} = "$dir".q|node167.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CC2S/; +$ref_files{$key} = "$dir".q|node30.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CS2C/; +$ref_files{$key} = "$dir".q|node38.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CTF2R/; +$ref_files{$key} = "$dir".q|node41.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DEULER/; +$ref_files{$key} = "$dir".q|node54.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DC62S/; +$ref_files{$key} = "$dir".q|node48.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DE2H/; +$ref_files{$key} = "$dir".q|node53.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PLANET/; +$ref_files{$key} = "$dir".q|node147.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EG50/; +$ref_files{$key} = "$dir".q|node90.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PV2UE/; +$ref_files{$key} = "$dir".q|node157.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DMAT/; +$ref_files{$key} = "$dir".q|node61.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_WAIT/; +$ref_files{$key} = "$dir".q|node194.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AV2M/; +$ref_files{$key} = "$dir".q|node25.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EQGAL/; +$ref_files{$key} = "$dir".q|node99.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DSEP/; +$ref_files{$key} = "$dir".q|node72.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_BEAR/; +$ref_files{$key} = "$dir".q|node26.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CR2AF/; +$ref_files{$key} = "$dir".q|node36.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DM2AV/; +$ref_files{$key} = "$dir".q|node60.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFCO/; +$ref_files{$key} = "$dir".q|node165.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_UE2EL/; +$ref_files{$key} = "$dir".q|node187.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK54Z/; +$ref_files{$key} = "$dir".q|node108.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_H2FK5/; +$ref_files{$key} = "$dir".q|node119.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DAT/; +$ref_files{$key} = "$dir".q|node44.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DVXV/; +$ref_files{$key} = "$dir".q|node84.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_S2TP/; +$ref_files{$key} = "$dir".q|node175.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ZD/; +$ref_files{$key} = "$dir".q|node196.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AFIN/; +$ref_files{$key} = "$dir".q|node15.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GALEQ/; +$ref_files{$key} = "$dir".q|node111.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVGALC/; +$ref_files{$key} = "$dir".q|node171.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFCOQ/; +$ref_files{$key} = "$dir".q|node166.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GALSUP/; +$ref_files{$key} = "$dir".q|node112.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PXY/; +$ref_files{$key} = "$dir".q|node159.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVEROT/; +$ref_files{$key} = "$dir".q|node170.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CAF2R/; +$ref_files{$key} = "$dir".q|node27.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RCC/; +$ref_files{$key} = "$dir".q|node163.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AMPQK/; +$ref_files{$key} = "$dir".q|node19.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MAPPA/; +$ref_files{$key} = "$dir".q|node127.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_UE2PV/; +$ref_files{$key} = "$dir".q|node188.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ADDET/; +$ref_files{$key} = "$dir".q|node14.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPB/; +$ref_files{$key} = "$dir".q|node92.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_NUTC/; +$ref_files{$key} = "$dir".q|node134.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPCO/; +$ref_files{$key} = "$dir".q|node94.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_HFK5Z/; +$ref_files{$key} = "$dir".q|node120.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ATMDSP/; +$ref_files{$key} = "$dir".q|node24.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPJ/; +$ref_files{$key} = "$dir".q|node95.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PERTEL/; +$ref_files{$key} = "$dir".q|node144.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DAFIN/; +$ref_files{$key} = "$dir".q|node43.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GE50/; +$ref_files{$key} = "$dir".q|node113.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PERTUE/; +$ref_files{$key} = "$dir".q|node145.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PREC/; +$ref_files{$key} = "$dir".q|node152.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ECMAT/; +$ref_files{$key} = "$dir".q|node88.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_KBJ/; +$ref_files{$key} = "$dir".q|node124.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_TPS2C/; +$ref_files{$key} = "$dir".q|node185.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GALSUP/; +$ref_files{$key} = "$dir".q|node112.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GMST/; +$ref_files{$key} = "$dir".q|node115.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GMSTA/; +$ref_files{$key} = "$dir".q|node116.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DJCL/; +$ref_files{$key} = "$dir".q|node59.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_XY2XY/; +$ref_files{$key} = "$dir".q|node195.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DR2TF/; +$ref_files{$key} = "$dir".q|node67.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MAPQK/; +$ref_files{$key} = "$dir".q|node128.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DIMXV/; +$ref_files{$key} = "$dir".q|node57.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MAP/; +$ref_files{$key} = "$dir".q|node126.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_E2H/; +$ref_files{$key} = "$dir".q|node85.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RANGE/; +$ref_files{$key} = "$dir".q|node161.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTP2S/; +$ref_files{$key} = "$dir".q|node76.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_TPV2C/; +$ref_files{$key} = "$dir".q|node186.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RANORM/; +$ref_files{$key} = "$dir".q|node162.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTP2V/; +$ref_files{$key} = "$dir".q|node77.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SEP/; +$ref_files{$key} = "$dir".q|node176.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SVDCOV/; +$ref_files{$key} = "$dir".q|node181.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ATMDSP/; +$ref_files{$key} = "$dir".q|node24.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_V2TP/; +$ref_files{$key} = "$dir".q|node190.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PERTEL/; +$ref_files{$key} = "$dir".q|node144.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CLYD/; +$ref_files{$key} = "$dir".q|node34.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DAT/; +$ref_files{$key} = "$dir".q|node44.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPB2D/; +$ref_files{$key} = "$dir".q|node93.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SVDSOL/; +$ref_files{$key} = "$dir".q|node182.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GRESID/; +$ref_files{$key} = "$dir".q|node117.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PRENUT/; +$ref_files{$key} = "$dir".q|node155.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTF2D/; +$ref_files{$key} = "$dir".q|node74.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPJ2D/; +$ref_files{$key} = "$dir".q|node96.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PERTUE/; +$ref_files{$key} = "$dir".q|node145.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PXY/; +$ref_files{$key} = "$dir".q|node159.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DS2C6/; +$ref_files{$key} = "$dir".q|node70.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ECOR/; +$ref_files{$key} = "$dir".q|node89.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CR2TF/; +$ref_files{$key} = "$dir".q|node37.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTF2R/; +$ref_files{$key} = "$dir".q|node75.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PDA2H/; +$ref_files{$key} = "$dir".q|node141.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CD2TF/; +$ref_files{$key} = "$dir".q|node32.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EARTH/; +$ref_files{$key} = "$dir".q|node86.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SMAT/; +$ref_files{$key} = "$dir".q|node177.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ECLEQ/; +$ref_files{$key} = "$dir".q|node87.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPB/; +$ref_files{$key} = "$dir".q|node92.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTT/; +$ref_files{$key} = "$dir".q|node80.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MOON/; +$ref_files{$key} = "$dir".q|node130.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SVD/; +$ref_files{$key} = "$dir".q|node180.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DR2AF/; +$ref_files{$key} = "$dir".q|node66.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RANORM/; +$ref_files{$key} = "$dir".q|node162.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DV2TP/; +$ref_files{$key} = "$dir".q|node81.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AIRMAS/; +$ref_files{$key} = "$dir".q|node16.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CLDJ/; +$ref_files{$key} = "$dir".q|node33.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PERMUT/; +$ref_files{$key} = "$dir".q|node143.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPJ/; +$ref_files{$key} = "$dir".q|node95.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PDQ2H/; +$ref_files{$key} = "$dir".q|node142.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SVDCOV/; +$ref_files{$key} = "$dir".q|node181.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_M2AV/; +$ref_files{$key} = "$dir".q|node125.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_INTIN/; +$ref_files{$key} = "$dir".q|node122.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SVDSOL/; +$ref_files{$key} = "$dir".q|node182.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GRESID/; +$ref_files{$key} = "$dir".q|node117.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CALDJ/; +$ref_files{$key} = "$dir".q|node28.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PRENUT/; +$ref_files{$key} = "$dir".q|node155.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CALYD/; +$ref_files{$key} = "$dir".q|node29.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CS2C6/; +$ref_files{$key} = "$dir".q|node39.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DAF2R/; +$ref_files{$key} = "$dir".q|node42.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DCC2S/; +$ref_files{$key} = "$dir".q|node49.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DCS2C/; +$ref_files{$key} = "$dir".q|node51.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PA/; +$ref_files{$key} = "$dir".q|node138.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK5HZ/; +$ref_files{$key} = "$dir".q|node109.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PV2EL/; +$ref_files{$key} = "$dir".q|node156.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DAV2M/; +$ref_files{$key} = "$dir".q|node45.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_OAPQK/; +$ref_files{$key} = "$dir".q|node136.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EULER/; +$ref_files{$key} = "$dir".q|node101.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EL2UE/; +$ref_files{$key} = "$dir".q|node91.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PM/; +$ref_files{$key} = "$dir".q|node149.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MAP/; +$ref_files{$key} = "$dir".q|node126.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DBEAR/; +$ref_files{$key} = "$dir".q|node46.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PV2UE/; +$ref_files{$key} = "$dir".q|node157.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_E2H/; +$ref_files{$key} = "$dir".q|node85.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DVDV/; +$ref_files{$key} = "$dir".q|node82.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DM2AV/; +$ref_files{$key} = "$dir".q|node60.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SEP/; +$ref_files{$key} = "$dir".q|node176.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AIRMAS/; +$ref_files{$key} = "$dir".q|node16.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PERMUT/; +$ref_files{$key} = "$dir".q|node143.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_UE2EL/; +$ref_files{$key} = "$dir".q|node187.html|; +$noresave{$key} = "$nosave"; + +$key = q/stardoccontents/; +$ref_files{$key} = "$dir".q|sun67.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_H2FK5/; +$ref_files{$key} = "$dir".q|node119.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK425/; +$ref_files{$key} = "$dir".q|node104.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DS2TP/; +$ref_files{$key} = "$dir".q|node71.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DH2E/; +$ref_files{$key} = "$dir".q|node56.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTPS2C/; +$ref_files{$key} = "$dir".q|node78.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AOPPA/; +$ref_files{$key} = "$dir".q|node21.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFV/; +$ref_files{$key} = "$dir".q|node168.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DVN/; +$ref_files{$key} = "$dir".q|node83.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_abstract/; +$ref_files{$key} = "$dir".q|node1.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GALEQ/; +$ref_files{$key} = "$dir".q|node111.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DPAV/; +$ref_files{$key} = "$dir".q|node65.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFZ/; +$ref_files{$key} = "$dir".q|node169.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CAF2R/; +$ref_files{$key} = "$dir".q|node27.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_UNPCD/; +$ref_files{$key} = "$dir".q|node189.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ALTAZ/; +$ref_files{$key} = "$dir".q|node17.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PA/; +$ref_files{$key} = "$dir".q|node138.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_INVF/; +$ref_files{$key} = "$dir".q|node123.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CC62S/; +$ref_files{$key} = "$dir".q|node31.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DE2H/; +$ref_files{$key} = "$dir".q|node53.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AMPQK/; +$ref_files{$key} = "$dir".q|node19.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DMAT/; +$ref_files{$key} = "$dir".q|node61.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PM/; +$ref_files{$key} = "$dir".q|node149.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GEOC/; +$ref_files{$key} = "$dir".q|node114.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AMP/; +$ref_files{$key} = "$dir".q|node18.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ETRMS/; +$ref_files{$key} = "$dir".q|node100.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_OAP/; +$ref_files{$key} = "$dir".q|node135.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FLOTIN/; +$ref_files{$key} = "$dir".q|node110.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTT/; +$ref_files{$key} = "$dir".q|node80.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DSEP/; +$ref_files{$key} = "$dir".q|node72.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SVD/; +$ref_files{$key} = "$dir".q|node180.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ADDET/; +$ref_files{$key} = "$dir".q|node14.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_IMXV/; +$ref_files{$key} = "$dir".q|node121.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_HFK5Z/; +$ref_files{$key} = "$dir".q|node120.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_TP2S/; +$ref_files{$key} = "$dir".q|node183.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PREBN/; +$ref_files{$key} = "$dir".q|node151.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_TP2V/; +$ref_files{$key} = "$dir".q|node184.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTPS2C/; +$ref_files{$key} = "$dir".q|node78.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AOPQK/; +$ref_files{$key} = "$dir".q|node23.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AFIN/; +$ref_files{$key} = "$dir".q|node15.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DMXM/; +$ref_files{$key} = "$dir".q|node63.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EQEQX/; +$ref_files{$key} = "$dir".q|node98.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DRANRM/; +$ref_files{$key} = "$dir".q|node69.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DBJIN/; +$ref_files{$key} = "$dir".q|node47.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_POLMO/; +$ref_files{$key} = "$dir".q|node150.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVLG/; +$ref_files{$key} = "$dir".q|node172.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GMSTA/; +$ref_files{$key} = "$dir".q|node116.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DCMPF/; +$ref_files{$key} = "$dir".q|node50.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PVOBS/; +$ref_files{$key} = "$dir".q|node158.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DMXV/; +$ref_files{$key} = "$dir".q|node64.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK524/; +$ref_files{$key} = "$dir".q|node106.html|; +$noresave{$key} = "$nosave"; + +1; + diff --git a/src/slalib/sun67.htx/invis_anchor.xbm b/src/slalib/sun67.htx/invis_anchor.xbm new file mode 100644 index 0000000..cc208a3 --- /dev/null +++ b/src/slalib/sun67.htx/invis_anchor.xbm @@ -0,0 +1,4 @@ +#define dot_anchor_width 1 +#define dot_anchor_height 1 +static char dot_anchor_bits[] = { + 0xfe}; diff --git a/src/slalib/sun67.htx/labels.pl b/src/slalib/sun67.htx/labels.pl new file mode 100644 index 0000000..ab31648 --- /dev/null +++ b/src/slalib/sun67.htx/labels.pl @@ -0,0 +1,1482 @@ +# LaTeX2HTML 97.1 (release) (July 13th, 1997) +# Associate labels original text with physical files. + + +$key = q/SLA_DR2TF/; +$external_labels{$key} = "$URL/" . q|node67.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_OBS/; +$external_labels{$key} = "$URL/" . q|node137.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DD2TF/; +$external_labels{$key} = "$URL/" . q|node52.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DIMXV/; +$external_labels{$key} = "$URL/" . q|node57.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PRECL/; +$external_labels{$key} = "$URL/" . q|node154.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EVP/; +$external_labels{$key} = "$URL/" . q|node102.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FLOTIN/; +$external_labels{$key} = "$URL/" . q|node110.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTP2S/; +$external_labels{$key} = "$URL/" . q|node76.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RANGE/; +$external_labels{$key} = "$URL/" . q|node161.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_NUTC/; +$external_labels{$key} = "$URL/" . q|node134.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_TPV2C/; +$external_labels{$key} = "$URL/" . q|node186.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTP2V/; +$external_labels{$key} = "$URL/" . q|node77.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_VDV/; +$external_labels{$key} = "$URL/" . q|node191.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK52H/; +$external_labels{$key} = "$URL/" . q|node107.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DVN/; +$external_labels{$key} = "$URL/" . q|node83.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PREC/; +$external_labels{$key} = "$URL/" . q|node152.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EQECL/; +$external_labels{$key} = "$URL/" . q|node97.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_H2E/; +$external_labels{$key} = "$URL/" . q|node118.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AOP/; +$external_labels{$key} = "$URL/" . q|node20.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DS2C6/; +$external_labels{$key} = "$URL/" . q|node70.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DRANRM/; +$external_labels{$key} = "$URL/" . q|node69.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PAV/; +$external_labels{$key} = "$URL/" . q|node139.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FITXY/; +$external_labels{$key} = "$URL/" . q|node103.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CS2C/; +$external_labels{$key} = "$URL/" . q|node38.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CC2S/; +$external_labels{$key} = "$URL/" . q|node30.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DT/; +$external_labels{$key} = "$URL/" . q|node73.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PDA2H/; +$external_labels{$key} = "$URL/" . q|node141.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVLSRD/; +$external_labels{$key} = "$URL/" . q|node173.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EG50/; +$external_labels{$key} = "$URL/" . q|node90.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DMOON/; +$external_labels{$key} = "$URL/" . q|node62.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DJCAL/; +$external_labels{$key} = "$URL/" . q|node58.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AMP/; +$external_labels{$key} = "$URL/" . q|node18.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CD2TF/; +$external_labels{$key} = "$URL/" . q|node32.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EARTH/; +$external_labels{$key} = "$URL/" . q|node86.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_OAP/; +$external_labels{$key} = "$URL/" . q|node135.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RANDOM/; +$external_labels{$key} = "$URL/" . q|node160.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_WAIT/; +$external_labels{$key} = "$URL/" . q|node194.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AV2M/; +$external_labels{$key} = "$URL/" . q|node25.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_NUT/; +$external_labels{$key} = "$URL/" . q|node133.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SUBET/; +$external_labels{$key} = "$URL/" . q|node178.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVLSRK/; +$external_labels{$key} = "$URL/" . q|node174.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_BEAR/; +$external_labels{$key} = "$URL/" . q|node26.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PDQ2H/; +$external_labels{$key} = "$URL/" . q|node142.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CLYD/; +$external_labels{$key} = "$URL/" . q|node34.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_V2TP/; +$external_labels{$key} = "$URL/" . q|node190.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_INTIN/; +$external_labels{$key} = "$URL/" . q|node122.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_COMBN/; +$external_labels{$key} = "$URL/" . q|node35.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CTF2D/; +$external_labels{$key} = "$URL/" . q|node40.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK45Z/; +$external_labels{$key} = "$URL/" . q|node105.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DVXV/; +$external_labels{$key} = "$URL/" . q|node84.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_S2TP/; +$external_labels{$key} = "$URL/" . q|node175.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CALYD/; +$external_labels{$key} = "$URL/" . q|node29.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DCS2C/; +$external_labels{$key} = "$URL/" . q|node51.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DCC2S/; +$external_labels{$key} = "$URL/" . q|node49.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DAF2R/; +$external_labels{$key} = "$URL/" . q|node42.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFRO/; +$external_labels{$key} = "$URL/" . q|node167.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MXM/; +$external_labels{$key} = "$URL/" . q|node131.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CTF2R/; +$external_labels{$key} = "$URL/" . q|node41.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DC62S/; +$external_labels{$key} = "$URL/" . q|node48.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PCD/; +$external_labels{$key} = "$URL/" . q|node140.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_OBS/; +$external_labels{$key} = "$URL/" . q|node137.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DT/; +$external_labels{$key} = "$URL/" . q|node73.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DAV2M/; +$external_labels{$key} = "$URL/" . q|node45.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MXV/; +$external_labels{$key} = "$URL/" . q|node132.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_OAPQK/; +$external_labels{$key} = "$URL/" . q|node136.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EL2UE/; +$external_labels{$key} = "$URL/" . q|node91.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EULER/; +$external_labels{$key} = "$URL/" . q|node101.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVLSRD/; +$external_labels{$key} = "$URL/" . q|node173.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DBEAR/; +$external_labels{$key} = "$URL/" . q|node46.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EQGAL/; +$external_labels{$key} = "$URL/" . q|node99.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EVP/; +$external_labels{$key} = "$URL/" . q|node102.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RANDOM/; +$external_labels{$key} = "$URL/" . q|node160.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CR2AF/; +$external_labels{$key} = "$URL/" . q|node36.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFCO/; +$external_labels{$key} = "$URL/" . q|node165.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVLSRK/; +$external_labels{$key} = "$URL/" . q|node174.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_VDV/; +$external_labels{$key} = "$URL/" . q|node191.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPCO/; +$external_labels{$key} = "$URL/" . q|node94.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK54Z/; +$external_labels{$key} = "$URL/" . q|node108.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_M2AV/; +$external_labels{$key} = "$URL/" . q|node125.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK425/; +$external_labels{$key} = "$URL/" . q|node104.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DS2TP/; +$external_labels{$key} = "$URL/" . q|node71.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AOPPA/; +$external_labels{$key} = "$URL/" . q|node21.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GE50/; +$external_labels{$key} = "$URL/" . q|node113.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_H2E/; +$external_labels{$key} = "$URL/" . q|node118.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AOP/; +$external_labels{$key} = "$URL/" . q|node20.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DFLTIN/; +$external_labels{$key} = "$URL/" . q|node55.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_VN/; +$external_labels{$key} = "$URL/" . q|node192.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_UNPCD/; +$external_labels{$key} = "$URL/" . q|node189.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GMST/; +$external_labels{$key} = "$URL/" . q|node115.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PAV/; +$external_labels{$key} = "$URL/" . q|node139.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ALTAZ/; +$external_labels{$key} = "$URL/" . q|node17.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DJCL/; +$external_labels{$key} = "$URL/" . q|node59.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CC62S/; +$external_labels{$key} = "$URL/" . q|node31.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MAPPA/; +$external_labels{$key} = "$URL/" . q|node127.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DRANGE/; +$external_labels{$key} = "$URL/" . q|node68.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_UE2PV/; +$external_labels{$key} = "$URL/" . q|node188.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTPV2C/; +$external_labels{$key} = "$URL/" . q|node79.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DVDV/; +$external_labels{$key} = "$URL/" . q|node82.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_NUT/; +$external_labels{$key} = "$URL/" . q|node133.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ETRMS/; +$external_labels{$key} = "$URL/" . q|node100.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PRECES/; +$external_labels{$key} = "$URL/" . q|node153.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DAFIN/; +$external_labels{$key} = "$URL/" . q|node43.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PREBN/; +$external_labels{$key} = "$URL/" . q|node151.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DH2E/; +$external_labels{$key} = "$URL/" . q|node56.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AOPPAT/; +$external_labels{$key} = "$URL/" . q|node22.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AOPQK/; +$external_labels{$key} = "$URL/" . q|node23.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ECMAT/; +$external_labels{$key} = "$URL/" . q|node88.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DPAV/; +$external_labels{$key} = "$URL/" . q|node65.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_TPS2C/; +$external_labels{$key} = "$URL/" . q|node185.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SUPGAL/; +$external_labels{$key} = "$URL/" . q|node179.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DFLTIN/; +$external_labels{$key} = "$URL/" . q|node55.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_VXV/; +$external_labels{$key} = "$URL/" . q|node193.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_VN/; +$external_labels{$key} = "$URL/" . q|node192.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EQEQX/; +$external_labels{$key} = "$URL/" . q|node98.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MXM/; +$external_labels{$key} = "$URL/" . q|node131.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_POLMO/; +$external_labels{$key} = "$URL/" . q|node150.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_INVF/; +$external_labels{$key} = "$URL/" . q|node123.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DBJIN/; +$external_labels{$key} = "$URL/" . q|node47.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_XY2XY/; +$external_labels{$key} = "$URL/" . q|node195.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MAPQKZ/; +$external_labels{$key} = "$URL/" . q|node129.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ECOR/; +$external_labels{$key} = "$URL/" . q|node89.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PVOBS/; +$external_labels{$key} = "$URL/" . q|node158.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DCMPF/; +$external_labels{$key} = "$URL/" . q|node50.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PCD/; +$external_labels{$key} = "$URL/" . q|node140.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK524/; +$external_labels{$key} = "$URL/" . q|node106.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MAPQK/; +$external_labels{$key} = "$URL/" . q|node128.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MXV/; +$external_labels{$key} = "$URL/" . q|node132.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DRANGE/; +$external_labels{$key} = "$URL/" . q|node68.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GEOC/; +$external_labels{$key} = "$URL/" . q|node114.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTPV2C/; +$external_labels{$key} = "$URL/" . q|node79.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DD2TF/; +$external_labels{$key} = "$URL/" . q|node52.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SMAT/; +$external_labels{$key} = "$URL/" . q|node177.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RDPLAN/; +$external_labels{$key} = "$URL/" . q|node164.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PRECL/; +$external_labels{$key} = "$URL/" . q|node154.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PLANTE/; +$external_labels{$key} = "$URL/" . q|node148.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_IMXV/; +$external_labels{$key} = "$URL/" . q|node121.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MOON/; +$external_labels{$key} = "$URL/" . q|node130.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CLDJ/; +$external_labels{$key} = "$URL/" . q|node33.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_TP2S/; +$external_labels{$key} = "$URL/" . q|node183.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK52H/; +$external_labels{$key} = "$URL/" . q|node107.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_TP2V/; +$external_labels{$key} = "$URL/" . q|node184.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPB2D/; +$external_labels{$key} = "$URL/" . q|node93.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PRECES/; +$external_labels{$key} = "$URL/" . q|node153.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AOPPAT/; +$external_labels{$key} = "$URL/" . q|node22.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTF2D/; +$external_labels{$key} = "$URL/" . q|node74.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPJ2D/; +$external_labels{$key} = "$URL/" . q|node96.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DMXM/; +$external_labels{$key} = "$URL/" . q|node63.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EQECL/; +$external_labels{$key} = "$URL/" . q|node97.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SUPGAL/; +$external_labels{$key} = "$URL/" . q|node179.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVLG/; +$external_labels{$key} = "$URL/" . q|node172.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PLANEL/; +$external_labels{$key} = "$URL/" . q|node146.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DMXV/; +$external_labels{$key} = "$URL/" . q|node64.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FITXY/; +$external_labels{$key} = "$URL/" . q|node103.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MAPQKZ/; +$external_labels{$key} = "$URL/" . q|node129.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DEULER/; +$external_labels{$key} = "$URL/" . q|node54.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_/; +$external_labels{$key} = "$URL/" . q|sun67.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CR2TF/; +$external_labels{$key} = "$URL/" . q|node37.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTF2R/; +$external_labels{$key} = "$URL/" . q|node75.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PLANET/; +$external_labels{$key} = "$URL/" . q|node147.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RCC/; +$external_labels{$key} = "$URL/" . q|node163.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DMOON/; +$external_labels{$key} = "$URL/" . q|node62.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DJCAL/; +$external_labels{$key} = "$URL/" . q|node58.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ECLEQ/; +$external_labels{$key} = "$URL/" . q|node87.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RDPLAN/; +$external_labels{$key} = "$URL/" . q|node164.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DR2AF/; +$external_labels{$key} = "$URL/" . q|node66.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SUBET/; +$external_labels{$key} = "$URL/" . q|node178.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DV2TP/; +$external_labels{$key} = "$URL/" . q|node81.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PLANTE/; +$external_labels{$key} = "$URL/" . q|node148.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_COMBN/; +$external_labels{$key} = "$URL/" . q|node35.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CALDJ/; +$external_labels{$key} = "$URL/" . q|node28.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ZD/; +$external_labels{$key} = "$URL/" . q|node196.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CTF2D/; +$external_labels{$key} = "$URL/" . q|node40.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFV/; +$external_labels{$key} = "$URL/" . q|node168.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVGALC/; +$external_labels{$key} = "$URL/" . q|node171.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK45Z/; +$external_labels{$key} = "$URL/" . q|node105.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFCOQ/; +$external_labels{$key} = "$URL/" . q|node166.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CS2C6/; +$external_labels{$key} = "$URL/" . q|node39.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RVEROT/; +$external_labels{$key} = "$URL/" . q|node170.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_KBJ/; +$external_labels{$key} = "$URL/" . q|node124.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFZ/; +$external_labels{$key} = "$URL/" . q|node169.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_VXV/; +$external_labels{$key} = "$URL/" . q|node193.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK5HZ/; +$external_labels{$key} = "$URL/" . q|node109.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PLANEL/; +$external_labels{$key} = "$URL/" . q|node146.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PV2EL/; +$external_labels{$key} = "$URL/" . q|node156.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFRO/; +$external_labels{$key} = "$URL/" . q|node167.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CC2S/; +$external_labels{$key} = "$URL/" . q|node30.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CS2C/; +$external_labels{$key} = "$URL/" . q|node38.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CTF2R/; +$external_labels{$key} = "$URL/" . q|node41.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DEULER/; +$external_labels{$key} = "$URL/" . q|node54.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DC62S/; +$external_labels{$key} = "$URL/" . q|node48.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DE2H/; +$external_labels{$key} = "$URL/" . q|node53.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PLANET/; +$external_labels{$key} = "$URL/" . q|node147.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EG50/; +$external_labels{$key} = "$URL/" . q|node90.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PV2UE/; +$external_labels{$key} = "$URL/" . q|node157.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DMAT/; +$external_labels{$key} = "$URL/" . q|node61.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_WAIT/; +$external_labels{$key} = "$URL/" . q|node194.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AV2M/; +$external_labels{$key} = "$URL/" . q|node25.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EQGAL/; +$external_labels{$key} = "$URL/" . q|node99.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DSEP/; +$external_labels{$key} = "$URL/" . q|node72.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_BEAR/; +$external_labels{$key} = "$URL/" . q|node26.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CR2AF/; +$external_labels{$key} = "$URL/" . q|node36.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DM2AV/; +$external_labels{$key} = "$URL/" . q|node60.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFCO/; +$external_labels{$key} = "$URL/" . q|node165.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_UE2EL/; +$external_labels{$key} = "$URL/" . q|node187.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK54Z/; +$external_labels{$key} = "$URL/" . q|node108.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_H2FK5/; +$external_labels{$key} = "$URL/" . q|node119.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DAT/; +$external_labels{$key} = "$URL/" . q|node44.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DVXV/; +$external_labels{$key} = "$URL/" . q|node84.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_S2TP/; +$external_labels{$key} = "$URL/" . q|node175.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ZD/; +$external_labels{$key} = "$URL/" . q|node196.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AFIN/; +$external_labels{$key} = "$URL/" . q|node15.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GALEQ/; +$external_labels{$key} = "$URL/" . q|node111.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVGALC/; +$external_labels{$key} = "$URL/" . q|node171.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_REFCOQ/; +$external_labels{$key} = "$URL/" . q|node166.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GALSUP/; +$external_labels{$key} = "$URL/" . q|node112.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PXY/; +$external_labels{$key} = "$URL/" . q|node159.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVEROT/; +$external_labels{$key} = "$URL/" . q|node170.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CAF2R/; +$external_labels{$key} = "$URL/" . q|node27.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RCC/; +$external_labels{$key} = "$URL/" . q|node163.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AMPQK/; +$external_labels{$key} = "$URL/" . q|node19.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MAPPA/; +$external_labels{$key} = "$URL/" . q|node127.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_UE2PV/; +$external_labels{$key} = "$URL/" . q|node188.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ADDET/; +$external_labels{$key} = "$URL/" . q|node14.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPB/; +$external_labels{$key} = "$URL/" . q|node92.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_NUTC/; +$external_labels{$key} = "$URL/" . q|node134.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPCO/; +$external_labels{$key} = "$URL/" . q|node94.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_HFK5Z/; +$external_labels{$key} = "$URL/" . q|node120.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ATMDSP/; +$external_labels{$key} = "$URL/" . q|node24.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPJ/; +$external_labels{$key} = "$URL/" . q|node95.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PERTEL/; +$external_labels{$key} = "$URL/" . q|node144.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DAFIN/; +$external_labels{$key} = "$URL/" . q|node43.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GE50/; +$external_labels{$key} = "$URL/" . q|node113.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PERTUE/; +$external_labels{$key} = "$URL/" . q|node145.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PREC/; +$external_labels{$key} = "$URL/" . q|node152.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ECMAT/; +$external_labels{$key} = "$URL/" . q|node88.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_KBJ/; +$external_labels{$key} = "$URL/" . q|node124.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_TPS2C/; +$external_labels{$key} = "$URL/" . q|node185.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GALSUP/; +$external_labels{$key} = "$URL/" . q|node112.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GMST/; +$external_labels{$key} = "$URL/" . q|node115.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GMSTA/; +$external_labels{$key} = "$URL/" . q|node116.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DJCL/; +$external_labels{$key} = "$URL/" . q|node59.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_XY2XY/; +$external_labels{$key} = "$URL/" . q|node195.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DR2TF/; +$external_labels{$key} = "$URL/" . q|node67.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MAPQK/; +$external_labels{$key} = "$URL/" . q|node128.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DIMXV/; +$external_labels{$key} = "$URL/" . q|node57.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_MAP/; +$external_labels{$key} = "$URL/" . q|node126.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_E2H/; +$external_labels{$key} = "$URL/" . q|node85.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RANGE/; +$external_labels{$key} = "$URL/" . q|node161.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTP2S/; +$external_labels{$key} = "$URL/" . q|node76.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_TPV2C/; +$external_labels{$key} = "$URL/" . q|node186.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_RANORM/; +$external_labels{$key} = "$URL/" . q|node162.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTP2V/; +$external_labels{$key} = "$URL/" . q|node77.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SEP/; +$external_labels{$key} = "$URL/" . q|node176.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SVDCOV/; +$external_labels{$key} = "$URL/" . q|node181.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ATMDSP/; +$external_labels{$key} = "$URL/" . q|node24.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_V2TP/; +$external_labels{$key} = "$URL/" . q|node190.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PERTEL/; +$external_labels{$key} = "$URL/" . q|node144.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CLYD/; +$external_labels{$key} = "$URL/" . q|node34.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DAT/; +$external_labels{$key} = "$URL/" . q|node44.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPB2D/; +$external_labels{$key} = "$URL/" . q|node93.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SVDSOL/; +$external_labels{$key} = "$URL/" . q|node182.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_GRESID/; +$external_labels{$key} = "$URL/" . q|node117.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PRENUT/; +$external_labels{$key} = "$URL/" . q|node155.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTF2D/; +$external_labels{$key} = "$URL/" . q|node74.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_EPJ2D/; +$external_labels{$key} = "$URL/" . q|node96.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PERTUE/; +$external_labels{$key} = "$URL/" . q|node145.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PXY/; +$external_labels{$key} = "$URL/" . q|node159.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DS2C6/; +$external_labels{$key} = "$URL/" . q|node70.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ECOR/; +$external_labels{$key} = "$URL/" . q|node89.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CR2TF/; +$external_labels{$key} = "$URL/" . q|node37.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTF2R/; +$external_labels{$key} = "$URL/" . q|node75.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PDA2H/; +$external_labels{$key} = "$URL/" . q|node141.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CD2TF/; +$external_labels{$key} = "$URL/" . q|node32.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EARTH/; +$external_labels{$key} = "$URL/" . q|node86.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SMAT/; +$external_labels{$key} = "$URL/" . q|node177.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ECLEQ/; +$external_labels{$key} = "$URL/" . q|node87.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPB/; +$external_labels{$key} = "$URL/" . q|node92.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTT/; +$external_labels{$key} = "$URL/" . q|node80.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MOON/; +$external_labels{$key} = "$URL/" . q|node130.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SVD/; +$external_labels{$key} = "$URL/" . q|node180.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DR2AF/; +$external_labels{$key} = "$URL/" . q|node66.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RANORM/; +$external_labels{$key} = "$URL/" . q|node162.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DV2TP/; +$external_labels{$key} = "$URL/" . q|node81.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AIRMAS/; +$external_labels{$key} = "$URL/" . q|node16.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CLDJ/; +$external_labels{$key} = "$URL/" . q|node33.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PERMUT/; +$external_labels{$key} = "$URL/" . q|node143.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EPJ/; +$external_labels{$key} = "$URL/" . q|node95.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PDQ2H/; +$external_labels{$key} = "$URL/" . q|node142.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SVDCOV/; +$external_labels{$key} = "$URL/" . q|node181.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_M2AV/; +$external_labels{$key} = "$URL/" . q|node125.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_INTIN/; +$external_labels{$key} = "$URL/" . q|node122.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_SVDSOL/; +$external_labels{$key} = "$URL/" . q|node182.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GRESID/; +$external_labels{$key} = "$URL/" . q|node117.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CALDJ/; +$external_labels{$key} = "$URL/" . q|node28.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PRENUT/; +$external_labels{$key} = "$URL/" . q|node155.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CALYD/; +$external_labels{$key} = "$URL/" . q|node29.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CS2C6/; +$external_labels{$key} = "$URL/" . q|node39.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DAF2R/; +$external_labels{$key} = "$URL/" . q|node42.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DCC2S/; +$external_labels{$key} = "$URL/" . q|node49.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DCS2C/; +$external_labels{$key} = "$URL/" . q|node51.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PA/; +$external_labels{$key} = "$URL/" . q|node138.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_FK5HZ/; +$external_labels{$key} = "$URL/" . q|node109.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PV2EL/; +$external_labels{$key} = "$URL/" . q|node156.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DAV2M/; +$external_labels{$key} = "$URL/" . q|node45.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_OAPQK/; +$external_labels{$key} = "$URL/" . q|node136.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EULER/; +$external_labels{$key} = "$URL/" . q|node101.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EL2UE/; +$external_labels{$key} = "$URL/" . q|node91.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PM/; +$external_labels{$key} = "$URL/" . q|node149.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_MAP/; +$external_labels{$key} = "$URL/" . q|node126.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DBEAR/; +$external_labels{$key} = "$URL/" . q|node46.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PV2UE/; +$external_labels{$key} = "$URL/" . q|node157.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_E2H/; +$external_labels{$key} = "$URL/" . q|node85.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DVDV/; +$external_labels{$key} = "$URL/" . q|node82.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DM2AV/; +$external_labels{$key} = "$URL/" . q|node60.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SEP/; +$external_labels{$key} = "$URL/" . q|node176.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AIRMAS/; +$external_labels{$key} = "$URL/" . q|node16.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PERMUT/; +$external_labels{$key} = "$URL/" . q|node143.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_UE2EL/; +$external_labels{$key} = "$URL/" . q|node187.html|; +$noresave{$key} = "$nosave"; + +$key = q/stardoccontents/; +$external_labels{$key} = "$URL/" . q|sun67.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_H2FK5/; +$external_labels{$key} = "$URL/" . q|node119.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK425/; +$external_labels{$key} = "$URL/" . q|node104.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DS2TP/; +$external_labels{$key} = "$URL/" . q|node71.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DH2E/; +$external_labels{$key} = "$URL/" . q|node56.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTPS2C/; +$external_labels{$key} = "$URL/" . q|node78.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AOPPA/; +$external_labels{$key} = "$URL/" . q|node21.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFV/; +$external_labels{$key} = "$URL/" . q|node168.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DVN/; +$external_labels{$key} = "$URL/" . q|node83.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_abstract/; +$external_labels{$key} = "$URL/" . q|node1.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GALEQ/; +$external_labels{$key} = "$URL/" . q|node111.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DPAV/; +$external_labels{$key} = "$URL/" . q|node65.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_REFZ/; +$external_labels{$key} = "$URL/" . q|node169.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_CAF2R/; +$external_labels{$key} = "$URL/" . q|node27.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_UNPCD/; +$external_labels{$key} = "$URL/" . q|node189.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ALTAZ/; +$external_labels{$key} = "$URL/" . q|node17.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PA/; +$external_labels{$key} = "$URL/" . q|node138.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_INVF/; +$external_labels{$key} = "$URL/" . q|node123.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_CC62S/; +$external_labels{$key} = "$URL/" . q|node31.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DE2H/; +$external_labels{$key} = "$URL/" . q|node53.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AMPQK/; +$external_labels{$key} = "$URL/" . q|node19.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DMAT/; +$external_labels{$key} = "$URL/" . q|node61.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_PM/; +$external_labels{$key} = "$URL/" . q|node149.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GEOC/; +$external_labels{$key} = "$URL/" . q|node114.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_AMP/; +$external_labels{$key} = "$URL/" . q|node18.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_ETRMS/; +$external_labels{$key} = "$URL/" . q|node100.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_OAP/; +$external_labels{$key} = "$URL/" . q|node135.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FLOTIN/; +$external_labels{$key} = "$URL/" . q|node110.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DTT/; +$external_labels{$key} = "$URL/" . q|node80.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DSEP/; +$external_labels{$key} = "$URL/" . q|node72.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_SVD/; +$external_labels{$key} = "$URL/" . q|node180.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_ADDET/; +$external_labels{$key} = "$URL/" . q|node14.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_IMXV/; +$external_labels{$key} = "$URL/" . q|node121.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_HFK5Z/; +$external_labels{$key} = "$URL/" . q|node120.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_TP2S/; +$external_labels{$key} = "$URL/" . q|node183.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PREBN/; +$external_labels{$key} = "$URL/" . q|node151.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_TP2V/; +$external_labels{$key} = "$URL/" . q|node184.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DTPS2C/; +$external_labels{$key} = "$URL/" . q|node78.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AOPQK/; +$external_labels{$key} = "$URL/" . q|node23.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_AFIN/; +$external_labels{$key} = "$URL/" . q|node15.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DMXM/; +$external_labels{$key} = "$URL/" . q|node63.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_EQEQX/; +$external_labels{$key} = "$URL/" . q|node98.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DRANRM/; +$external_labels{$key} = "$URL/" . q|node69.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DBJIN/; +$external_labels{$key} = "$URL/" . q|node47.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_POLMO/; +$external_labels{$key} = "$URL/" . q|node150.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_RVLG/; +$external_labels{$key} = "$URL/" . q|node172.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_GMSTA/; +$external_labels{$key} = "$URL/" . q|node116.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_DCMPF/; +$external_labels{$key} = "$URL/" . q|node50.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_PVOBS/; +$external_labels{$key} = "$URL/" . q|node158.html|; +$noresave{$key} = "$nosave"; + +$key = q/SLA_DMXV/; +$external_labels{$key} = "$URL/" . q|node64.html|; +$noresave{$key} = "$nosave"; + +$key = q/xref_SLA_FK524/; +$external_labels{$key} = "$URL/" . q|node106.html|; +$noresave{$key} = "$nosave"; + +1; + diff --git a/src/slalib/sun67.htx/next_group_motif.gif b/src/slalib/sun67.htx/next_group_motif.gif new file mode 100644 index 0000000..833af4d Binary files /dev/null and b/src/slalib/sun67.htx/next_group_motif.gif differ diff --git a/src/slalib/sun67.htx/next_group_motif_gr.gif b/src/slalib/sun67.htx/next_group_motif_gr.gif new file mode 100644 index 0000000..c04fec3 Binary files /dev/null and b/src/slalib/sun67.htx/next_group_motif_gr.gif differ diff --git a/src/slalib/sun67.htx/next_motif.gif b/src/slalib/sun67.htx/next_motif.gif new file mode 100644 index 0000000..7a2dbe9 Binary files /dev/null and b/src/slalib/sun67.htx/next_motif.gif differ diff --git a/src/slalib/sun67.htx/next_motif_gr.gif b/src/slalib/sun67.htx/next_motif_gr.gif new file mode 100644 index 0000000..1416b1c Binary files /dev/null and b/src/slalib/sun67.htx/next_motif_gr.gif differ diff --git a/src/slalib/sun67.htx/node1.html b/src/slalib/sun67.htx/node1.html new file mode 100644 index 0000000..0a5b6da --- /dev/null +++ b/src/slalib/sun67.htx/node1.html @@ -0,0 +1,65 @@ + + + + +Abstract + + + + + + + + + + + + +


+ +next + +up + +previous +
+ Next: INTRODUCTION +
+Up: SLALIB Positional Astronomy Library +
+ Previous: SLALIB Positional Astronomy Library +

+

+

Abstract +  +

+SLALIB is a library used by writers of positional-astronomy applications. +Most of the 183 routines are concerned with astronomical position and time, +but a number have wider trigonometrical, numerical or general applications. +

+


+ +next + +up + +previous +
+ Next: INTRODUCTION +
+Up: SLALIB Positional Astronomy Library +
+ Previous: SLALIB Positional Astronomy Library +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node10.html b/src/slalib/sun67.htx/node10.html new file mode 100644 index 0000000..4a6a393 --- /dev/null +++ b/src/slalib/sun67.htx/node10.html @@ -0,0 +1,75 @@ + + + + +New Functions + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Acknowledgements +
+Up: INTRODUCTION +
+ Previous: Future Versions +

+

+

+New Functions +

+In a package like SLALIB it is difficult to know how far to go. Is it +enough to provide the primitive operations, or should more +complicated functions be packaged? Is it worth encroaching on +specialist areas, where individual experts have all written their +own software already? To what extent should CPU efficiency be +an issue? How much support of different numerical precisions is +required? And so on. +

+In practice, almost all the routines in SLALIB are there because they were +needed for some specific application, and this is likely to remain the +pattern for any enhancements in the future. +Suggestions for additional SLALIB routines should be addressed to the +author. +

+


+ +next + +up + +previous +
+ Next: Acknowledgements +
+Up: INTRODUCTION +
+ Previous: Future Versions +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node100.html b/src/slalib/sun67.htx/node100.html new file mode 100644 index 0000000..104db1d --- /dev/null +++ b/src/slalib/sun67.htx/node100.html @@ -0,0 +1,110 @@ + + + + +SLA_ETRMS - E-terms of Aberration + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EULER - Rotation Matrix from Euler Angles +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EQGAL - J2000 to Galactic +

+

+

SLA_ETRMS - E-terms of Aberration +   +

+
+
ACTION: +
Compute the E-terms vector - the part of the annual +aberration which arises from the eccentricity of the + Earth's orbit. +

CALL: +
CALL sla_ETRMS (EP, EV) +

+

+
GIVEN: +
+
+ + + + + +
EPDBesselian epoch
+

+
RETURNED: +
+
+ + + + + +
EVD(3)E-terms as $[\Delta x, \Delta y, \Delta z\,]$
+

+
NOTE: +
Note the use of the J2000 aberration constant ( +$20\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.49552$ ). + This is a reflection of the fact that the E-terms embodied in + existing star catalogues were computed from a variety of + aberration constants. Rather than adopting one of the old + constants the latest value is used here. +
+

+
REFERENCES: +
+
1. +
Smith, C.A. et al., 1989. Astr.J. 97, 265. +
2. +
Yallop, B.D. et al., 1989. Astr.J. 97, 274. +
+

+ +next + +up + +previous +
+ Next: SLA_EULER - Rotation Matrix from Euler Angles +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EQGAL - J2000 to Galactic +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node101.html b/src/slalib/sun67.htx/node101.html new file mode 100644 index 0000000..e5bdda2 --- /dev/null +++ b/src/slalib/sun67.htx/node101.html @@ -0,0 +1,132 @@ + + + + +SLA_EULER - Rotation Matrix from Euler Angles + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EVP - Earth Position & Velocity +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ETRMS - E-terms of Aberration +

+

+

SLA_EULER - Rotation Matrix from Euler Angles +   +

+
+
ACTION: +
Form a rotation matrix from the Euler angles - three +successive rotations about specified Cartesian axes + (single precision). +

CALL: +
CALL sla_EULER (ORDER, PHI, THETA, PSI, RMAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
ORDERC*(*)specifies about which axes the rotations occur
PHIR1st rotation (radians)
THETAR2nd rotation (radians)
PSIR3rd rotation (radians)
+

+
RETURNED: +
+
+ + + + + +
RMATR(3,3)rotation matrix
+

+
NOTES: +
+
1. +
A rotation is positive when the reference frame rotates +anticlockwise as seen looking towards the origin from the +positive region of the specified axis. +
2. +
The characters of ORDER define which axes the three successive + rotations are about. A typical value is `ZXZ', indicating that + RMAT is to become the direction cosine matrix corresponding to + rotations of the reference frame through PHI radians about the + old z-axis, followed by THETA radians about the resulting + x-axis, + then PSI radians about the resulting z-axis. In detail: +
    +
  • The axis names can be any of the following, in any order or + combination: X, Y, Z, uppercase or lowercase, 1, 2, 3. Normal + axis labelling/numbering conventions apply; + the xyz ($\equiv123$) triad is right-handed. Thus, the `ZXZ' example given above + could be written `zxz' or `313' (or even `ZxZ' or `3xZ'). +
  • ORDER is terminated by length or by the first unrecognized + character. +
  • Fewer than three rotations are acceptable, in which case + the later angle arguments are ignored. +
+
3. +
Zero rotations produces a unit RMAT. +
+

+ +next + +up + +previous +
+ Next: SLA_EVP - Earth Position & Velocity +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ETRMS - E-terms of Aberration +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node102.html b/src/slalib/sun67.htx/node102.html new file mode 100644 index 0000000..d22b187 --- /dev/null +++ b/src/slalib/sun67.htx/node102.html @@ -0,0 +1,149 @@ + + + + +SLA_EVP - Earth Position & Velocity + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_FITXY - Fit Linear Model to Two Sets +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EULER - Rotation Matrix from Euler Angles +

+

+

SLA_EVP - Earth Position & Velocity +   +

+
+
ACTION: +
Barycentric and heliocentric velocity and position of the Earth. +
CALL: +
CALL sla_EVP (DATE, DEQX, DVB, DPB, DVH, DPH) +

+

+
GIVEN: +
+
+ + + + + + + + + +
DATEDTDB (formerly ET) as a Modified Julian Date +(JD-2400000.5)
DEQXDJulian Epoch (e.g. 2000D0) of mean equator and +equinox of the vectors returned. If DEQX <0, +all vectors are referred to the mean equator and +equinox (FK5) of date DATE.
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
DVBD(3)barycentric $[\,\dot{x},\dot{y},\dot{z}\,]$, AU s-1
DPBD(3)barycentric $[\,x,y,z\,]$, AU
DVHD(3)heliocentric $[\,\dot{x},\dot{y},\dot{z}\,]$, AU s-1
DPHD(3)heliocentric $[\,x,y,z\,]$, AU
+

+
NOTES: +
+
1. +
This routine is used when accuracy is more important +than CPU time, yet the extra complication of reading a +pre-computed ephemeris is not justified. The maximum + deviations from the JPL DE96 ephemeris are as follows: +
    +
  • velocity (barycentric or heliocentric): 420 mm s-1 +
  • position (barycentric): 6900 km +
  • position (heliocentric): 1600 km +
+
2. +
The routine is an adaption of the BARVEL and BARCOR + subroutines of P.Stumpff, which are described in + Astr.Astrophys.Suppl.Ser. 41, 1-8 (1980). + Most of the changes are merely cosmetic and do not affect + the results at all. However, some adjustments have been + made so as to give results that refer to the new (IAU 1976 + `FK5') equinox and precession, although the differences these + changes make relative to the results from Stumpff's original + `FK4' version are smaller than the inherent accuracy of the + algorithm. One minor shortcoming in the original routines + that has not been corrected is that slightly better + numerical accuracy could be achieved if the various polynomial + evaluations were to be so arranged that the smallest terms were + computed first. Note also that one of Stumpff's precession + constants differs by + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.001$ from the value given in the + Explanatory Supplement. +
+

+ +next + +up + +previous +
+ Next: SLA_FITXY - Fit Linear Model to Two Sets +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EULER - Rotation Matrix from Euler Angles +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node103.html b/src/slalib/sun67.htx/node103.html new file mode 100644 index 0000000..4525328 --- /dev/null +++ b/src/slalib/sun67.htx/node103.html @@ -0,0 +1,170 @@ + + + + +SLA_FITXY - Fit Linear Model to Two Sets + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_FK425 - FK4 to FK5 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EVP - Earth Position & Velocity +

+

+

    +
+SLA_FITXY - Fit Linear Model to Two $[\,x,y\,]$ Sets +

+
+
ACTION: +
Fit a linear model to relate two sets of $[\,x,y\,]$ coordinates. +
CALL: +
CALL sla_FITXY (ITYPE,NP,XYE,XYM,COEFFS,J) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
ITYPEItype of model: 4 or 6 (note 1)
NPInumber of samples (note 2)
XYED(2,NP)expected $[\,x,y\,]$ for each sample
XYMD(2,NP)measured $[\,x,y\,]$ for each sample
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
COEFFSD(6)coefficients of model (note 3)
JIstatus:
0 = OK
-1 = illegal ITYPE
-2 = insufficient data
-3 = singular solution
+

+
NOTES: +
+
1. +
ITYPE, which must be either 4 or 6, selects the type of model +fitted. Both allowed ITYPE values produce a model COEFFS which +consists of six coefficients, namely the zero points and, for + each of XE and YE, the coefficient of XM and YM. For ITYPE=6, + all six coefficients are independent, modelling squash and shear + as well as origin, scale, and orientation. However, ITYPE=4 + selects the solid body rotation option; the model COEFFS + still consists of the same six coefficients, but now two of + them are used twice (appropriately signed). Origin, scale + and orientation are still modelled, but not squash or shear - + the units of X and Y have to be the same. +
2. +
For NC=4, NP must be at least 2. For NC=6, NP must be at + least 3. +
3. +
The model is returned in the array COEFFS. Naming the + six elements of COEFFS a,b,c,d,e & f, + the model transforms measured coordinates + $[x_{m},y_{m}\,]$ into expected coordinates + $[x_{e},y_{e}\,]$ as follows: +
xe = a + bxm + cym
+ ye = d + exm + fym
+ For the solid body rotation option (ITYPE=4), the + magnitudes of b and f, and of c and e, are equal. The + signs of these coefficients depend on whether there is a + sign reversal between [xe,ye] and [xm,ym]; + fits are performed + with and without a sign reversal and the best one chosen. +
4. +
Error status values J=-1 and -2 leave COEFFS unchanged; + if J=-3 COEFFS may have been changed. +
5. +
See also sla_PXY, sla_INVF, sla_XY2XY, sla_DCMPF. +
+

+ +next + +up + +previous +
+ Next: SLA_FK425 - FK4 to FK5 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EVP - Earth Position & Velocity +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node104.html b/src/slalib/sun67.htx/node104.html new file mode 100644 index 0000000..0a2f9ca --- /dev/null +++ b/src/slalib/sun67.htx/node104.html @@ -0,0 +1,208 @@ + + + + +SLA_FK425 - FK4 to FK5 + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_FK45Z - FK4 to FK5, no P.M. or Parallax +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FITXY - Fit Linear Model to Two Sets +

+

+

SLA_FK425 - FK4 to FK5 +   +

+
+
ACTION: +
Convert B1950.0 FK4 star data to J2000.0 FK5. +This routine converts stars from the old, Bessel-Newcomb, FK4 + system to the new, IAU 1976, FK5, Fricke system. The precepts + of Smith et al. (see reference 1) are followed, + using the implementation + by Yallop et al. (reference 2) of a matrix method + due to Standish. + Kinoshita's development of Andoyer's post-Newcomb precession is + used. The numerical constants from + Seidelmann et al. (reference 3) are used canonically. +

CALL: +
CALL sla_FK425 ( + R1950,D1950,DR1950,DD1950,P1950,V1950, + R2000,D2000,DR2000,DD2000,P2000,V2000) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
R1950DB1950.0 $\alpha$ (radians)
D1950DB1950.0 $\delta$ (radians)
DR1950DB1950.0 proper motion in $\alpha$(radians per tropical year)
DD1950DB1950.0 proper motion in $\delta$(radians per tropical year)
P1950DB1950.0 parallax (arcsec)
V1950DB1950.0 radial velocity (km s-1, +ve = moving away)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
R2000DJ2000.0 $\alpha$ (radians)
D2000DJ2000.0 $\delta$ (radians)
DR2000DJ2000.0 proper motion in $\alpha$(radians per Julian year)
DD2000DJ2000.0 proper motion in $\delta$(radians per Julian year)
P2000DJ2000.0 parallax (arcsec)
V2000DJ2000.0 radial velocity (km s-1, +ve = moving away)
+

+
NOTES: +
+
1. +
The $\alpha$ proper motions are $\dot{\alpha}$ rather than +$\dot{\alpha}\cos\delta$, and are per year rather than per century. +
2. +
Conversion from Besselian epoch 1950.0 to Julian epoch + 2000.0 only is provided for. Conversions involving other + epochs will require use of the appropriate precession, + proper motion, and E-terms routines before and/or after FK425 + is called. +
3. +
In the FK4 catalogue the proper motions of stars within + $10^{\circ}$ of the poles do not include the differential + E-terms effect and should, strictly speaking, be handled + in a different manner from stars outside these regions. + However, given the general lack of homogeneity of the star + data available for routine astrometry, the difficulties of + handling positions that may have been determined from + astrometric fields spanning the polar and non-polar regions, + the likelihood that the differential E-terms effect was not + taken into account when allowing for proper motion in past + astrometry, and the undesirability of a discontinuity in + the algorithm, the decision has been made in this routine to + include the effect of differential E-terms on the proper + motions for all stars, whether polar or not. At epoch J2000, + and measuring on the sky rather than in terms of $\Delta\alpha$, the errors resulting from this simplification are less than + 1 milliarcsecond in position and 1 milliarcsecond per + century in proper motion. +
4. +
See also sla_FK45Z, sla_FK524, sla_FK54Z. +
+

+
REFERENCES: +
+
1. +
Smith, C.A. et al., 1989. Astr.J. 97, 265. +
2. +
Yallop, B.D. et al., 1989. Astr.J. 97, 274. +
3. +
Seidelmann, P.K. (ed), 1992. Explanatory + Supplement to the Astronomical Almanac, ISBN 0-935702-68-7. +
+

+ +next + +up + +previous +
+ Next: SLA_FK45Z - FK4 to FK5, no P.M. or Parallax +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FITXY - Fit Linear Model to Two Sets +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node105.html b/src/slalib/sun67.htx/node105.html new file mode 100644 index 0000000..dde5fc9 --- /dev/null +++ b/src/slalib/sun67.htx/node105.html @@ -0,0 +1,166 @@ + + + + +SLA_FK45Z - FK4 to FK5, no P.M. or Parallax + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_FK524 - FK5 to FK4 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK425 - FK4 to FK5 +

+

+

SLA_FK45Z - FK4 to FK5, no P.M. or Parallax +   +

+
+
ACTION: +
Convert B1950.0 FK4 star data to J2000.0 FK5 assuming zero +proper motion in the FK5 frame. + This routine converts stars from the old, Bessel-Newcomb, FK4 + system to the new, IAU 1976, FK5, Fricke system, in such a + way that the FK5 proper motion is zero. Because such a star + has, in general, a non-zero proper motion in the FK4 system, + the routine requires the epoch at which the position in the + FK4 system was determined. The method is from appendix 2 of + reference 1, but using the constants of reference 4. +

CALL: +
CALL sla_FK45Z (R1950,D1950,BEPOCH,R2000,D2000) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
R1950DB1950.0 FK4 $\alpha$ at epoch BEPOCH (radians)
D1950DB1950.0 FK4 $\delta$ at epoch BEPOCH (radians)
BEPOCHDBesselian epoch (e.g. 1979.3D0)
+

+
RETURNED: +
+
+ + + + + + + + + +
R2000DJ2000.0 FK5 $\alpha$ (radians)
D2000DJ2000.0 FK5 $\delta$ (radians)
+

+
NOTES: +
+
1. +
The epoch BEPOCH is strictly speaking Besselian, but +if a Julian epoch is supplied the result will be +affected only to a negligible extent. +
2. +
Conversion from Besselian epoch 1950.0 to Julian epoch + 2000.0 only is provided for. Conversions involving other + epochs will require use of the appropriate precession, + proper motion, and E-terms routines before and/or + after FK45Z is called. +
3. +
In the FK4 catalogue the proper motions of stars within + $10^{\circ}$ of the poles do not include the differential + E-terms effect and should, strictly speaking, be handled + in a different manner from stars outside these regions. + However, given the general lack of homogeneity of the star + data available for routine astrometry, the difficulties of + handling positions that may have been determined from + astrometric fields spanning the polar and non-polar regions, + the likelihood that the differential E-terms effect was not + taken into account when allowing for proper motion in past + astrometry, and the undesirability of a discontinuity in + the algorithm, the decision has been made in this routine to + include the effect of differential E-terms on the proper + motions for all stars, whether polar or not. At epoch 2000, + and measuring on the sky rather than in terms of $\Delta\alpha$, the errors resulting from this simplification are less than + 1 milliarcsecond in position and 1 milliarcsecond per + century in proper motion. +
4. +
See also sla_FK425, sla_FK524, sla_FK54Z. +
+

+
REFERENCES: +
+
1. +
Aoki, S., et al., 1983. Astr.Astrophys., 128, 263. +
2. +
Smith, C.A. et al., 1989. Astr.J. 97, 265. +
3. +
Yallop, B.D. et al., 1989. Astr.J. 97, 274. +
4. +
Seidelmann, P.K. (ed), 1992. Explanatory + Supplement to the Astronomical Almanac, ISBN 0-935702-68-7. +
+

+ +next + +up + +previous +
+ Next: SLA_FK524 - FK5 to FK4 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK425 - FK4 to FK5 +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node106.html b/src/slalib/sun67.htx/node106.html new file mode 100644 index 0000000..8c1e64a --- /dev/null +++ b/src/slalib/sun67.htx/node106.html @@ -0,0 +1,207 @@ + + + + +SLA_FK524 - FK5 to FK4 + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_FK52H - FK5 to Hipparcos +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK45Z - FK4 to FK5, no P.M. or Parallax +

+

+

SLA_FK524 - FK5 to FK4 +   +

+
+
ACTION: +
Convert J2000.0 FK5 star data to B1950.0 FK4. +This routine converts stars from the new, IAU 1976, FK5, Fricke + system, to the old, Bessel-Newcomb, FK4 system. + The precepts of Smith et al. (reference 1) are followed, + using the implementation by Yallop et al. (reference 2) + of a matrix method due to Standish. Kinoshita's development of + Andoyer's post-Newcomb precession is used. The numerical + constants from Seidelmann et al. (reference 3) are + used canonically. +

CALL: +
CALL sla_FK524 ( + R2000,D2000,DR2000,DD2000,P2000,V2000, + R1950,D1950,DR1950,DD1950,P1950,V1950) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
R2000DJ2000.0 $\alpha$ (radians)
D2000DJ2000.0 $\delta$ (radians)
DR2000DJ2000.0 proper motion in $\alpha$(radians per Julian year)
DD2000DJ2000.0 proper motion in $\delta$(radians per Julian year)
P2000DJ2000.0 parallax (arcsec)
V2000DJ2000 radial velocity (km s-1, +ve = moving away)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
R1950DB1950.0 $\alpha$ (radians)
D1950DB1950.0 $\delta$ (radians)
DR1950DB1950.0 proper motion in $\alpha$(radians per tropical year)
DD1950DB1950.0 proper motion in $\delta$(radians per tropical year)
P1950DB1950.0 parallax (arcsec)
V1950Dradial velocity (km s-1, +ve = moving away)
+

+
NOTES: +
+
1. +
The $\alpha$ proper motions are $\dot{\alpha}$ rather than +$\dot{\alpha}\cos\delta$, and are per year rather than per century. +
2. +
Note that conversion from Julian epoch 2000.0 to Besselian + epoch 1950.0 only is provided for. Conversions involving + other epochs will require use of the appropriate precession, + proper motion, and E-terms routines before and/or after + FK524 is called. +
3. +
In the FK4 catalogue the proper motions of stars within + $10^{\circ}$ of the poles do not include the differential + E-terms effect and should, strictly speaking, be handled + in a different manner from stars outside these regions. + However, given the general lack of homogeneity of the star + data available for routine astrometry, the difficulties of + handling positions that may have been determined from + astrometric fields spanning the polar and non-polar regions, + the likelihood that the differential E-terms effect was not + taken into account when allowing for proper motion in past + astrometry, and the undesirability of a discontinuity in + the algorithm, the decision has been made in this routine to + include the effect of differential E-terms on the proper + motions for all stars, whether polar or not. At epoch 2000, + and measuring on the sky rather than in terms of $\Delta\alpha$, the errors resulting from this simplification are less than + 1 milliarcsecond in position and 1 milliarcsecond per + century in proper motion. +
4. +
See also sla_FK425, sla_FK45Z, sla_FK54Z. +
+

+
REFERENCES: +
+
1. +
Smith, C.A. et al., 1989. Astr.J. 97, 265. +
2. +
Yallop, B.D. et al., 1989. Astr.J. 97, 274. +
3. +
Seidelmann, P.K. (ed), 1992. Explanatory + Supplement to the Astronomical Almanac, ISBN 0-935702-68-7. +
+

+ +next + +up + +previous +
+ Next: SLA_FK52H - FK5 to Hipparcos +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK45Z - FK4 to FK5, no P.M. or Parallax +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node107.html b/src/slalib/sun67.htx/node107.html new file mode 100644 index 0000000..e63af95 --- /dev/null +++ b/src/slalib/sun67.htx/node107.html @@ -0,0 +1,188 @@ + + + + +SLA_FK52H - FK5 to Hipparcos + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_FK54Z - FK5 to FK4, no P.M. or Parallax +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK524 - FK5 to FK4 +

+

+

SLA_FK52H - FK5 to Hipparcos +   +

+
+
ACTION: +
Transform an FK5 (J2000) position and proper motion +into the frame of the Hipparcos catalogue. +

CALL: +
CALL sla_FK52H (R5,D5,DR5,DD5,RH,DH,DRH,DDH) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
R5DJ2000.0 FK5 $\alpha$ (radians)
D5DJ2000.0 FK5 $\delta$ (radians)
DR5DJ2000.0 FK5 proper motion in $\alpha$(radians per Julian year)
DD5DJ2000.0 FK5 proper motion in $\delta$(radians per Julian year)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
RHDHipparcos $\alpha$ (radians)
DHDHipparcos $\delta$ (radians)
DRHDHipparcos proper motion in $\alpha$(radians per Julian year)
DDHDHipparcos proper motion in $\delta$(radians per Julian year)
+

+
NOTES: +
+
1. +
The $\alpha$ proper motions are $\dot{\alpha}$ rather than +$\dot{\alpha}\cos\delta$, and are per year rather than per century. +
2. +
The FK5 to Hipparcos + transformation consists of a pure rotation and spin; + zonal errors in the FK5 catalogue are not taken into account. +
3. +
The adopted epoch J2000.0 FK5 to Hipparcos orientation and spin + values are as follows (see reference): +


+
+
+

             + + + + + + + + + + + + + + + + + + + + + +
 orientation   spin   
x-19.9     -0.30  
y-9.1     +0.60  
z+22.9     +0.70  
 mas      mas/y 
+


+
+
+
+

+These orientation and spin components are interpreted as + axial vectors. An axial vector points at the pole of + the rotation and its length is the amount of rotation in radians. +

4. +
See also sla_FK5HZ, sla_H2FK5, sla_HFK5Z. +
+

+
REFERENCE: +
Feissel, M. & Mignard, F., 1998., Astron.Astrophys. 331, L33-L36. +
+

+ +next + +up + +previous +
+ Next: SLA_FK54Z - FK5 to FK4, no P.M. or Parallax +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK524 - FK5 to FK4 +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node108.html b/src/slalib/sun67.htx/node108.html new file mode 100644 index 0000000..504a1a6 --- /dev/null +++ b/src/slalib/sun67.htx/node108.html @@ -0,0 +1,156 @@ + + + + +SLA_FK54Z - FK5 to FK4, no P.M. or Parallax + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_FK5HZ - FK5 to Hipparcos, no P.M. +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK52H - FK5 to Hipparcos +

+

+

SLA_FK54Z - FK5 to FK4, no P.M. or Parallax +   +

+
+
ACTION: +
Convert a J2000.0 FK5 star position to B1950.0 FK4 assuming +FK5 zero proper motion and parallax. + This routine converts star positions from the new, IAU 1976, + FK5, Fricke system to the old, Bessel-Newcomb, FK4 system. +

CALL: +
CALL sla_FK54Z (R2000,D2000,BEPOCH,R1950,D1950,DR1950,DD1950) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
R2000DJ2000.0 FK5 $\alpha$ (radians)
D2000DJ2000.0 FK5 $\delta$ (radians)
BEPOCHDBesselian epoch (e.g. 1950D0)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
R1950DB1950.0 FK4 $\alpha$ at epoch BEPOCH (radians)
D1950DB1950.0 FK4 $\delta$ at epoch BEPOCH (radians)
DR1950DB1950.0 FK4 proper motion in $\alpha$(radians per tropical year)
DD1950DB1950.0 FK4 proper motion in $\delta$(radians per tropical year)
+

+
NOTES: +
+
1. +
The $\alpha$ proper motions are $\dot{\alpha}$ rather than +$\dot{\alpha}\cos\delta$, and are per year rather than per century. +
2. +
Conversion from Julian epoch 2000.0 to Besselian epoch 1950.0 + only is provided for. Conversions involving other epochs will + require use of the appropriate precession routines before and + after this routine is called. +
3. +
Unlike in the sla_FK524 routine, the FK5 proper motions, the + parallax and the radial velocity are presumed zero. +
4. +
It was the intention that FK5 should be a close approximation + to an inertial frame, so that distant objects have zero proper + motion; such objects have (in general) non-zero proper motion + in FK4, and this routine returns those fictitious proper + motions. +
5. +
The position returned by this routine is in the B1950 + reference frame but at Besselian epoch BEPOCH. For + comparison with catalogues the BEPOCH argument will + frequently be 1950D0. +
6. +
See also sla_FK425, sla_FK45Z, sla_FK524. +
+

+ +next + +up + +previous +
+ Next: SLA_FK5HZ - FK5 to Hipparcos, no P.M. +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK52H - FK5 to Hipparcos +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node109.html b/src/slalib/sun67.htx/node109.html new file mode 100644 index 0000000..ddda44d --- /dev/null +++ b/src/slalib/sun67.htx/node109.html @@ -0,0 +1,168 @@ + + + + +SLA_FK5HZ - FK5 to Hipparcos, no P.M. + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_FLOTIN - Decode a Real Number +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK54Z - FK5 to FK4, no P.M. or Parallax +

+

+

SLA_FK5HZ - FK5 to Hipparcos, no P.M. +   +

+
+
ACTION: +
Transform an FK5 (J2000) star position into the frame of the +Hipparcos catalogue, assuming zero Hipparcos proper motion. +

CALL: +
CALL sla_FK52H (R5,D5,EPOCH,RH,DH) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
R5DJ2000.0 FK5 $\alpha$ (radians)
D5DJ2000.0 FK5 $\delta$ (radians)
EPOCHDJulian epoch (TDB)
+

+
RETURNED: +
+
+ + + + + + + + + +
RHDHipparcos $\alpha$ (radians)
DHDHipparcos $\delta$ (radians)
+

+
NOTES: +
+
1. +
The $\alpha$ proper motions are $\dot{\alpha}$ rather than +$\dot{\alpha}\cos\delta$, and are per year rather than per century. +
2. +
The FK5 to Hipparcos + transformation consists of a pure rotation and spin; + zonal errors in the FK5 catalogue are not taken into account. +
3. +
The adopted epoch J2000.0 FK5 to Hipparcos orientation and spin + values are as follows (see reference): +


+
+
+

             + + + + + + + + + + + + + + + + + + + + + +
 orientation   spin   
x-19.9     -0.30  
y-9.1     +0.60  
z+22.9     +0.70  
 mas      mas/y 
+


+
+
+
+

+These orientation and spin components are interpreted as + axial vectors. An axial vector points at the pole of + the rotation and its length is the amount of rotation in radians. +

4. +
See also sla_FK52H, sla_H2FK5, sla_HFK5Z. +
+

+
REFERENCE: +
Feissel, M. & Mignard, F., 1998., Astron.Astrophys. 331, L33-L36. +
+

+ +next + +up + +previous +
+ Next: SLA_FLOTIN - Decode a Real Number +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK54Z - FK5 to FK4, no P.M. or Parallax +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node11.html b/src/slalib/sun67.htx/node11.html new file mode 100644 index 0000000..a950b04 --- /dev/null +++ b/src/slalib/sun67.htx/node11.html @@ -0,0 +1,102 @@ + + + + +Acknowledgements + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: LINKING +
+Up: INTRODUCTION +
+ Previous: New Functions +

+

+

+Acknowledgements +

+SLALIB is descended from a package of routines written +for the AAO 16-bit minicomputers +in the mid-1970s. The coming of the VAX +allowed a much more comprehensive and thorough package +to be designed for Starlink, especially important +at a time when the adoption +of the IAU 1976 resolutions meant that astronomers +would have to cope with a mixture of reference frames, +timescales and nomenclature. +

+Much of the preparatory work on SLALIB was done by +Althea Wilkinson of Manchester University. +During its development, +Andrew Murray, +Catherine Hohenkerk, +Andrew Sinclair, +Bernard Yallop +and +Brian Emerson of Her Majesty's Nautical Almanac Office were consulted +on many occasions; their advice was indispensable. +I am especially grateful to +Catherine Hohenkerk +for supplying preprints of papers, and test data. A number of +enhancements to SLALIB were at the suggestion of +Russell Owen, University of Washington, +the late Phil Hill, St Andrews University, +Bill Vacca, JILA, Boulder and +Ron Maddalena, NRAO. +Mark Calabretta, CSIRO Radiophysics, Sydney supplied changes to suit Convex. +I am indebted to Derek Jones (RGO) for introducing me to the +``universal variables'' method of calculating orbits. +

+The first C version of SLALIB was a hand-coded transcription +of the Starlink Fortran version carried out by +Steve Eaton (University of Leeds) in the course of +MSc work. This was later +enhanced by John Straede (AAO) and Martin Shepherd (Caltech). +The current C SLALIB is a complete rewrite by the present author and +includes a comprehensive validation suite. +Additional comments on the C version came from Bob Payne (NRAO) and +Jeremy Bailey (AAO). +

+


+ +next + +up + +previous +
+ Next: LINKING +
+Up: INTRODUCTION +
+ Previous: New Functions +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node110.html b/src/slalib/sun67.htx/node110.html new file mode 100644 index 0000000..c13c949 --- /dev/null +++ b/src/slalib/sun67.htx/node110.html @@ -0,0 +1,200 @@ + + + + +SLA_FLOTIN - Decode a Real Number + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_GALEQ - Galactic to J2000 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK5HZ - FK5 to Hipparcos, no P.M. +

+

+

SLA_FLOTIN - Decode a Real Number +   +

+
+
ACTION: +
Convert free-format input into single precision floating point. +
CALL: +
CALL sla_FLOTIN (STRING, NSTRT, RESLT, JFLAG) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
STRINGCstring containing number to be decoded
NSTRTIpointer to where decoding is to commence
RESLTRcurrent value of result
+

+
RETURNED: +
+
+ + + + + + + + + + + + + +
NSTRTIadvanced to next number
RESLTRresult
JFLAGIstatus: -1 = -OK, 0 = +OK, 1 = null result, 2 = error
+

+
NOTES: +
+
1. +
The reason sla_FLOTIN has separate `OK' status values +for + and - is to enable minus zero to be detected. +This is of crucial importance + when decoding mixed-radix numbers. For example, an angle + expressed as degrees, arcminutes and arcseconds may have a + leading minus sign but a zero degrees field. +
2. +
A TAB is interpreted as a space, and lowercase characters are + interpreted as uppercase. n.b. The test for TAB is + ASCII-specific. +
3. +
The basic format is the sequence of fields $\pm n.n x \pm n$, where $\pm$ is a sign + character `+' or `-', n means a string of decimal digits, + `.' is a decimal point, and x, which indicates an exponent, + means `D' or `E'. Various combinations of these fields can be + omitted, and embedded blanks are permissible in certain places. +
4. +
Spaces: +
    +
  • Leading spaces are ignored. +
  • Embedded spaces are allowed only after +, -, D or E, + and after the decimal point if the first sequence of + digits is absent. +
  • Trailing spaces are ignored; the first signifies + end of decoding and subsequent ones are skipped. +
+
5. +
Delimiters: +
    +
  • Any character other than +,-,0-9,.,D,E or space may be + used to signal the end of the number and terminate decoding. +
  • Comma is recognized by sla_FLOTIN as a special case; it + is skipped, leaving the pointer on the next character. See + 13, below. +
  • Decoding will in all cases terminate if end of string + is reached. +
+
6. +
Both signs are optional. The default is +. +
7. +
The mantissa n.n defaults to unity. +
8. +
The exponent $x\!\pm\!n$ defaults to `E0'. +
9. +
The strings of decimal digits may be of any length. +
10. +
The decimal point is optional for whole numbers. +
11. +
A null result occurs when the string of characters + being decoded does not begin with +,-,0-9,.,D or E, or + consists entirely of spaces. When this condition is + detected, JFLAG is set to 1 and RESLT is left untouched. +
12. +
NSTRT = 1 for the first character in the string. +
13. +
On return from sla_FLOTIN, NSTRT is set ready for the next + decode - following trailing blanks and any comma. If a + delimiter other than comma is being used, NSTRT must be + incremented before the next call to sla_FLOTIN, otherwise + all subsequent calls will return a null result. +
14. +
Errors (JFLAG=2) occur when: +
    +
  • a +, -, D or E is left unsatisfied; or +
  • the decimal point is present without at least + one decimal digit before or after it; or +
  • an exponent more than 100 has been presented. +
+
15. +
When an error has been detected, NSTRT is left + pointing to the character following the last + one used before the error came to light. This + may be after the point at which a more sophisticated + program could have detected the error. For example, + sla_FLOTIN does not detect that `1E999' is unacceptable + (on a computer where this is so) + until the entire number has been decoded. +
16. +
Certain highly unlikely combinations of mantissa and + exponent can cause arithmetic faults during the + decode, in some cases despite the fact that they + together could be construed as a valid number. +
17. +
Decoding is left to right, one pass. +
18. +
See also sla_DFLTIN and sla_INTIN. +
+

+ +next + +up + +previous +
+ Next: SLA_GALEQ - Galactic to J2000 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FK5HZ - FK5 to Hipparcos, no P.M. +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node111.html b/src/slalib/sun67.htx/node111.html new file mode 100644 index 0000000..6e7927c --- /dev/null +++ b/src/slalib/sun67.htx/node111.html @@ -0,0 +1,104 @@ + + + + +SLA_GALEQ - Galactic to J2000 + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_GALSUP - Galactic to Supergalactic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FLOTIN - Decode a Real Number +

+

+

    +
+SLA_GALEQ - Galactic to J2000 $\alpha,\delta$

+
+
ACTION: +
Transformation from IAU 1958 galactic coordinates +to J2000.0 FK5 equatorial coordinates. +

CALL: +
CALL sla_GALEQ (DL, DB, DR, DD) +

+

+
GIVEN: +
+
+ + + + + +
DL,DBDgalactic longitude and latitude $[\,l^{I\!I},b^{I\!I}\,]$
+

+
RETURNED: +
+
+ + + + + +
DR,DDDJ2000.0 $[\,\alpha,\delta\,]$
+

+
NOTES: +
+
1. +
All arguments are in radians. +
2. +
The equatorial coordinates are J2000.0 FK5. Use the routine +sla_GE50 if conversion to B1950.0 FK4 coordinates is + required. +
+

+ +next + +up + +previous +
+ Next: SLA_GALSUP - Galactic to Supergalactic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_FLOTIN - Decode a Real Number +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node112.html b/src/slalib/sun67.htx/node112.html new file mode 100644 index 0000000..cfbdd9b --- /dev/null +++ b/src/slalib/sun67.htx/node112.html @@ -0,0 +1,107 @@ + + + + +SLA_GALSUP - Galactic to Supergalactic + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_GE50 - Galactic to B1950 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GALEQ - Galactic to J2000 +

+

+

SLA_GALSUP - Galactic to Supergalactic +   +

+
+
ACTION: +
Transformation from IAU 1958 galactic coordinates to +de Vaucouleurs supergalactic coordinates. +

CALL: +
CALL sla_GALSUP (DL, DB, DSL, DSB) +

+

+
GIVEN: +
+
+ + + + + +
DL,DBDgalactic longitude and latitude $[\,l^{I\!I},b^{I\!I}\,]$ (radians)
+

+
RETURNED: +
+
+ + + + + +
DSL,DSBDsupergalactic longitude and latitude (radians)
+

+
REFERENCES: +
+
1. +
de Vaucouleurs, de Vaucouleurs, & Corwin, Second Reference +Catalogue of Bright Galaxies, U.Texas, p8. +
2. +
Systems & Applied Sciences Corp., documentation for the + machine-readable version of the above catalogue, + Contract NAS 5-26490. +
+ (These two references give different values for the galactic + longitude of the supergalactic origin. Both are wrong; the + correct value is $l^{I\!I}=137.37$.) +

+

+ +next + +up + +previous +
+ Next: SLA_GE50 - Galactic to B1950 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GALEQ - Galactic to J2000 +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node113.html b/src/slalib/sun67.htx/node113.html new file mode 100644 index 0000000..e12bf51 --- /dev/null +++ b/src/slalib/sun67.htx/node113.html @@ -0,0 +1,109 @@ + + + + +SLA_GE50 - Galactic to B1950 + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_GEOC - Geodetic to Geocentric +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GALSUP - Galactic to Supergalactic +

+

+

    +
+SLA_GE50 - Galactic to B1950 $\alpha,\delta$

+
+
ACTION: +
Transformation from IAU 1958 galactic coordinates to +B1950.0 FK4 equatorial coordinates. +

CALL: +
CALL sla_GE50 (DL, DB, DR, DD) +

+

+
GIVEN: +
+
+ + + + + +
DL,DBDgalactic longitude and latitude $[\,l^{I\!I},b^{I\!I}\,]$
+

+
RETURNED: +
+
+ + + + + +
DR,DDDB1950.0 $[\,\alpha,\delta\,]$
+

+
NOTES: +
+
1. +
All arguments are in radians. +
2. +
The equatorial coordinates are B1950.0 FK4. Use the +routine sla_GALEQ if conversion to J2000.0 FK5 coordinates + is required. +
+

+
REFERENCE: +
Blaauw et al., 1960, Mon.Not.R.astr.Soc., +121, 123. +
+

+ +next + +up + +previous +
+ Next: SLA_GEOC - Geodetic to Geocentric +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GALSUP - Galactic to Supergalactic +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node114.html b/src/slalib/sun67.htx/node114.html new file mode 100644 index 0000000..a2e570a --- /dev/null +++ b/src/slalib/sun67.htx/node114.html @@ -0,0 +1,107 @@ + + + + +SLA_GEOC - Geodetic to Geocentric + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_GMST - UT to GMST +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GE50 - Galactic to B1950 +

+

+

SLA_GEOC - Geodetic to Geocentric +   +

+
+
ACTION: +
Convert geodetic position to geocentric. +
CALL: +
CALL sla_GEOC (P, H, R, Z) +

+

+
GIVEN: +
+
+ + + + + + + + + +
PDlatitude (geodetic, radians)
HDheight above reference spheroid (geodetic, metres)
+

+
RETURNED: +
+
+ + + + + + + + + +
RDdistance from Earth axis (AU)
ZDdistance from plane of Earth equator (AU)
+

+
NOTES: +
+
1. +
Geocentric latitude can be obtained by evaluating ATAN2(Z,R). +
2. +
IAU 1976 constants are used. +
+

+
REFERENCE: +
Green, R.M., 1985. Spherical Astronomy, Cambridge U.P., p98. +
+

+ +next + +up + +previous +
+ Next: SLA_GMST - UT to GMST +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GE50 - Galactic to B1950 +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node115.html b/src/slalib/sun67.htx/node115.html new file mode 100644 index 0000000..cee01cc --- /dev/null +++ b/src/slalib/sun67.htx/node115.html @@ -0,0 +1,115 @@ + + + + +SLA_GMST - UT to GMST + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_GMSTA - UT to GMST (extra precision) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GEOC - Geodetic to Geocentric +

+

+

SLA_GMST - UT to GMST +   +

+
+
ACTION: +
Conversion from universal time UT1 to Greenwich mean +sidereal time. +

CALL: +
D = sla_GMST (UT1) +

+

+
GIVEN: +
+
+ + + + + +
UT1Duniversal time (strictly UT1) expressed as +modified Julian Date (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
sla_GMSTDGreenwich mean sidereal time (radians)
+

+
NOTES: +
+
1. +
The IAU 1982 expression +(see page S15 of the 1984 Astronomical +Almanac) is used, but rearranged to reduce rounding errors. This + expression is always described as giving the GMST at $0^{\rm h}$UT; + in fact, it gives the difference between the + GMST and the UT, which happens to equal the GMST (modulo + 24 hours) at $0^{\rm h}$UT each day. In sla_GMST, the + entire UT is used directly as the argument for the + canonical formula, and the fractional part of the UT is + added separately; note that the factor $1.0027379\cdots$ does + not appear. +
2. +
See also the routine sla_GMSTA, which + delivers better numerical + precision by accepting the UT date and time as separate arguments. +
+

+ +next + +up + +previous +
+ Next: SLA_GMSTA - UT to GMST (extra precision) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GEOC - Geodetic to Geocentric +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node116.html b/src/slalib/sun67.htx/node116.html new file mode 100644 index 0000000..5055ecb --- /dev/null +++ b/src/slalib/sun67.htx/node116.html @@ -0,0 +1,116 @@ + + + + +SLA_GMSTA - UT to GMST (extra precision) + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_GRESID - Gaussian Residual +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GMST - UT to GMST +

+

+

SLA_GMSTA - UT to GMST (extra precision) +   +

+
+
ACTION: +
Conversion from universal time UT1 to Greenwich Mean +sidereal time, with rounding errors minimized. +

CALL: +
D = sla_GMSTA (DATE, UT1) +

+

+
GIVEN: +
+
+ + + + + + + + + +
DATEDUT1 date as Modified Julian Date (integer part +of JD-2400000.5)
UT1DUT1 time (fraction of a day)
+

+
RETURNED: +
+
+ + + + + +
sla_GMSTDGreenwich mean sidereal time (radians)
+

+
NOTES: +
+
1. +
The algorithm is derived from the IAU 1982 expression +(see page S15 of the 1984 Astronomical Almanac). +
2. +
There is no restriction on how the UT is apportioned between the + DATE and UT1 arguments. Either of the two arguments could, for + example, be zero and the entire date+time supplied in the other. + However, the routine is designed to deliver maximum accuracy when + the DATE argument is a whole number and the UT1 argument + lies in the range $[\,0,\,1\,]$, or vice versa. +
3. +
See also the routine sla_GMST, which accepts the UT1 as a single + argument. Compared with sla_GMST, the extra numerical precision + delivered by the present routine is unlikely to be important in + an absolute sense, but may be useful when critically comparing + algorithms and in applications where two sidereal times close + together are differenced. +
+

+ +next + +up + +previous +
+ Next: SLA_GRESID - Gaussian Residual +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GMST - UT to GMST +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node117.html b/src/slalib/sun67.htx/node117.html new file mode 100644 index 0000000..980f93a --- /dev/null +++ b/src/slalib/sun67.htx/node117.html @@ -0,0 +1,92 @@ + + + + +SLA_GRESID - Gaussian Residual + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_H2E - Az,El to +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GMSTA - UT to GMST (extra precision) +

+

+

SLA_GRESID - Gaussian Residual +   +

+
+
ACTION: +
Generate pseudo-random normal deviate or Gaussian residual. +
CALL: +
R = sla_GRESID (S) +

+

+
GIVEN: +
+
+ + + + + +
SRstandard deviation
+

+
NOTES: +
+
1. +
The results of many calls to this routine will be +normally distributed with mean zero and standard deviation S. +
2. +
The Box-Muller algorithm is used. +
3. +
The implementation is machine-dependent. +
+

+
REFERENCE: +
Ahrens & Dieter, 1972. Comm.A.C.M. 15, 873. +
+

+ +next + +up + +previous +
+ Next: SLA_H2E - Az,El to +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GMSTA - UT to GMST (extra precision) +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node118.html b/src/slalib/sun67.htx/node118.html new file mode 100644 index 0000000..83df4b3 --- /dev/null +++ b/src/slalib/sun67.htx/node118.html @@ -0,0 +1,146 @@ + + + + +SLA_H2E - Az,El to + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_H2FK5 - Hipparcos to FK5 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GRESID - Gaussian Residual +

+

+

    +
+SLA_H2E - Az,El to $h,\delta$

+
+
ACTION: +
Horizon to equatorial coordinates +(single precision). +

CALL: +
CALL sla_H2E (AZ, EL, PHI, HA, DEC) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
AZRazimuth (radians)
ELRelevation (radians)
PHIRlatitude (radians)
+

+
RETURNED: +
+
+ + + + + + + + + +
HARhour angle (radians)
DECRdeclination (radians)
+

+
NOTES: +
+
1. +
The sign convention for azimuth is north zero, east $+\pi/2$.
2. +
HA is returned in the range $\pm \pi$. Declination is returned +in the range $\pm \pi$.
3. +
The latitude is (in principle) geodetic. In critical + applications, corrections for polar motion should be applied + (see sla_POLMO). +
4. +
In some applications it will be important to specify the + correct type of elevation in order to produce the required + type of $[\,h,\delta\,]$. In particular, it may be important to + distinguish between the elevation as affected by refraction, + which will yield the observed $[\,h,\delta\,]$, and the elevation + in vacuo, which will yield the topocentric + $[\,h,\delta\,]$. If the + effects of diurnal aberration can be neglected, the + topocentric $[\,h,\delta\,]$ may be used as an approximation to the + apparent $[\,h,\delta\,]$.
5. +
No range checking of arguments is carried out. +
6. +
In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude. +
+

+ +next + +up + +previous +
+ Next: SLA_H2FK5 - Hipparcos to FK5 +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_GRESID - Gaussian Residual +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node119.html b/src/slalib/sun67.htx/node119.html new file mode 100644 index 0000000..9133db9 --- /dev/null +++ b/src/slalib/sun67.htx/node119.html @@ -0,0 +1,188 @@ + + + + +SLA_H2FK5 - Hipparcos to FK5 + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_HFK5Z - Hipparcos to FK5, no P.M. +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_H2E - Az,El to +

+

+

SLA_H2FK5 - Hipparcos to FK5 +   +

+
+
ACTION: +
Transform a Hipparcos star position and proper motion +into the FK5 (J2000) frame. +

CALL: +
CALL sla_H2FK5 (RH,DH,DRH,DDH,R5,D5,DR5,DD5) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
RHDHipparcos $\alpha$ (radians)
DHDHipparcos $\delta$ (radians)
DRHDHipparcos proper motion in $\alpha$(radians per Julian year)
DDHDHipparcos proper motion in $\delta$(radians per Julian year)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
R5DJ2000.0 FK5 $\alpha$ (radians)
D5DJ2000.0 FK5 $\delta$ (radians)
DR5DJ2000.0 FK5 proper motion in $\alpha$(radians per Julian year)
DD5DFK5 J2000.0 proper motion in $\delta$(radians per Julian year)
+

+
NOTES: +
+
1. +
The $\alpha$ proper motions are $\dot{\alpha}$ rather than +$\dot{\alpha}\cos\delta$, and are per year rather than per century. +
2. +
The FK5 to Hipparcos + transformation consists of a pure rotation and spin; + zonal errors in the FK5 catalogue are not taken into account. +
3. +
The adopted epoch J2000.0 FK5 to Hipparcos orientation and spin + values are as follows (see reference): +


+
+
+

             + + + + + + + + + + + + + + + + + + + + + +
 orientation   spin   
x-19.9     -0.30  
y-9.1     +0.60  
z+22.9     +0.70  
 mas      mas/y 
+


+
+
+
+

+These orientation and spin components are interpreted as + axial vectors. An axial vector points at the pole of + the rotation and its length is the amount of rotation in radians. +

4. +
See also sla_FK52H, sla_FK5HZ, sla_HFK5Z. +
+

+
REFERENCE: +
Feissel, M. & Mignard, F., 1998., Astron.Astrophys. 331, L33-L36. +
+

+ +next + +up + +previous +
+ Next: SLA_HFK5Z - Hipparcos to FK5, no P.M. +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_H2E - Az,El to +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node12.html b/src/slalib/sun67.htx/node12.html new file mode 100644 index 0000000..d75415d --- /dev/null +++ b/src/slalib/sun67.htx/node12.html @@ -0,0 +1,75 @@ + + + + +LINKING + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SUBPROGRAM SPECIFICATIONS +
+Up: SLALIB Positional Astronomy Library +
+ Previous: Acknowledgements +

+

+

+LINKING +

+

+On Unix systems (Sun, DEC Alpha etc.): +

%  f77 progname.o -L/star/lib `sla_link` -o progname +
+(The above assumes that all Starlink directories have been added to +the LD_LIBRARY_PATH and PATH environment variables +as described in SUN/202.) +

+On VAX/VMS: +

$  LINK progname,SLALIB_DIR:SLALIB/LIB +
+

+
+

+


+ +next + +up + +previous +
+ Next: SUBPROGRAM SPECIFICATIONS +
+Up: SLALIB Positional Astronomy Library +
+ Previous: Acknowledgements +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node120.html b/src/slalib/sun67.htx/node120.html new file mode 100644 index 0000000..ffd038a --- /dev/null +++ b/src/slalib/sun67.htx/node120.html @@ -0,0 +1,190 @@ + + + + +SLA_HFK5Z - Hipparcos to FK5, no P.M. + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_IMXV - Apply 3D Reverse Rotation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_H2FK5 - Hipparcos to FK5 +

+

+

SLA_HFK5Z - Hipparcos to FK5, no P.M. +   +

+
+
ACTION: +
Transform a Hipparcos star position +into the FK5 (J2000) frame assuming zero Hipparcos proper motion. +

CALL: +
CALL sla_HFK5Z (RH,DH,EPOCH,R5,D5,DR5,DD5) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
RHDHipparcos $\alpha$ (radians)
DHDHipparcos $\delta$ (radians)
EPOCHDJulian epoch (TDB)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
R5DJ2000.0 FK5 $\alpha$ (radians)
D5DJ2000.0 FK5 $\delta$ (radians)
DR5DJ2000.0 FK5 proper motion in $\alpha$(radians per Julian year)
DD5DFK5 J2000.0 proper motion in $\delta$(radians per Julian year)
+

+
NOTES: +
+
1. +
The $\alpha$ proper motions are $\dot{\alpha}$ rather than +$\dot{\alpha}\cos\delta$, and are per year rather than per century. +
2. +
The FK5 to Hipparcos + transformation consists of a pure rotation and spin; + zonal errors in the FK5 catalogue are not taken into account. +
3. +
The adopted epoch J2000.0 FK5 to Hipparcos orientation and spin + values are as follows (see reference): +


+
+
+

             + + + + + + + + + + + + + + + + + + + + + +
 orientation   spin   
x-19.9     -0.30  
y-9.1     +0.60  
z+22.9     +0.70  
 mas      mas/y 
+


+
+
+
+

+These orientation and spin components are interpreted as + axial vectors. An axial vector points at the pole of + the rotation and its length is the amount of rotation in radians. + The order of the rotations, which are very small, +

4. +
It was the intention that Hipparcos should be a close + approximation to an inertial frame, so that distant objects + have zero proper motion; such objects have (in general) + non-zero proper motion in FK5, and this routine returns those + fictitious proper motions. +
5. +
The position returned by this routine is in the FK5 J2000 + reference frame but at Julian epoch EPOCH. +
6. +
See also sla_FK52H, sla_FK5HZ, sla_H2FK5. +
+

+
REFERENCE: +
Feissel, M. & Mignard, F., 1998., Astron.Astrophys. 331, L33-L36. +
+

+ +next + +up + +previous +
+ Next: SLA_IMXV - Apply 3D Reverse Rotation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_H2FK5 - Hipparcos to FK5 +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node121.html b/src/slalib/sun67.htx/node121.html new file mode 100644 index 0000000..68ace5b --- /dev/null +++ b/src/slalib/sun67.htx/node121.html @@ -0,0 +1,118 @@ + + + + +SLA_IMXV - Apply 3D Reverse Rotation + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_INTIN - Decode an Integer Number +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_HFK5Z - Hipparcos to FK5, no P.M. +

+

+

SLA_IMXV - Apply 3D Reverse Rotation +   +

+
+
ACTION: +
Multiply a 3-vector by the inverse of a rotation +matrix (single precision). +

CALL: +
CALL sla_IMXV (RM, VA, VB) +

+

+
GIVEN: +
+
+ + + + + + + + + +
RMR(3,3)rotation matrix
VAR(3)vector to be rotated
+

+
RETURNED: +
+
+ + + + + +
VBR(3)result vector
+

+
NOTES: +
+
1. +
This routine performs the operation: +
b = M$^{T}\cdot$a +
+ where a and b are the 3-vectors VA and VB + respectively, and M is the $3\times3$ matrix RM. +
2. +
The main function of this routine is apply an inverse + rotation; under these circumstances, ${\bf M}$ is + orthogonal, with its inverse the same as its transpose. +
3. +
To comply with the ANSI Fortran 77 standard, VA and VB must + not be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is not, however, + recommended. +
+

+ +next + +up + +previous +
+ Next: SLA_INTIN - Decode an Integer Number +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_HFK5Z - Hipparcos to FK5, no P.M. +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node122.html b/src/slalib/sun67.htx/node122.html new file mode 100644 index 0000000..b06d5d3 --- /dev/null +++ b/src/slalib/sun67.htx/node122.html @@ -0,0 +1,170 @@ + + + + +SLA_INTIN - Decode an Integer Number + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_INVF - Invert Linear Model +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_IMXV - Apply 3D Reverse Rotation +

+

+

SLA_INTIN - Decode an Integer Number +   +

+
+
ACTION: +
Convert free-format input into an integer. +
CALL: +
CALL sla_INTIN (STRING, NSTRT, IRESLT, JFLAG) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
STRINGCstring containing number to be decoded
NSTRTIpointer to where decoding is to commence
IRESLTIcurrent value of result
+

+
RETURNED: +
+
+ + + + + + + + + + + + + +
NSTRTIadvanced to next number
IRESLTIresult
JFLAGIstatus: -1 = -OK, 0 = +OK, 1 = null result, 2 = error
+

+
NOTES: +
+
1. +
The reason sla_INTIN has separate `OK' status values +for + and - is to enable minus zero to be detected. +This is of crucial importance + when decoding mixed-radix numbers. For example, an angle + expressed as degrees, arcminutes and arcseconds may have a + leading minus sign but a zero degrees field. +
2. +
A TAB is interpreted as a space. n.b. The test for TAB is + ASCII-specific. +
3. +
The basic format is the sequence of fields $\pm n$, where $\pm$ is a sign + character `+' or `-', and n means a string of decimal digits. +
4. +
Spaces: +
    +
  • Leading spaces are ignored. +
  • Spaces between the sign and the number are allowed. +
  • Trailing spaces are ignored; the first signifies + end of decoding and subsequent ones are skipped. +
+
5. +
Delimiters: +
    +
  • Any character other than +,-,0-9 or space may be + used to signal the end of the number and terminate decoding. +
  • Comma is recognized by sla_INTIN as a special case; it + is skipped, leaving the pointer on the next character. See + 9, below. +
  • Decoding will in all cases terminate if end of string + is reached. +
+
6. +
The sign is optional. The default is +. +
7. +
A null result occurs when the string of characters + being decoded does not begin with +,- or 0-9, or + consists entirely of spaces. When this condition is + detected, JFLAG is set to 1 and IRESLT is left untouched. +
8. +
NSTRT = 1 for the first character in the string. +
9. +
On return from sla_INTIN, NSTRT is set ready for the next + decode - following trailing blanks and any comma. If a + delimiter other than comma is being used, NSTRT must be + incremented before the next call to sla_INTIN, otherwise + all subsequent calls will return a null result. +
10. +
Errors (JFLAG=2) occur when: +
    +
  • there is a + or - but no number; or +
  • the number is greater than 231-1. +
+
11. +
When an error has been detected, NSTRT is left + pointing to the character following the last + one used before the error came to light. +
12. +
See also sla_FLOTIN and sla_DFLTIN. +
+

+ +next + +up + +previous +
+ Next: SLA_INVF - Invert Linear Model +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_IMXV - Apply 3D Reverse Rotation +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node123.html b/src/slalib/sun67.htx/node123.html new file mode 100644 index 0000000..a3d1a77 --- /dev/null +++ b/src/slalib/sun67.htx/node123.html @@ -0,0 +1,122 @@ + + + + +SLA_INVF - Invert Linear Model + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_KBJ - Select Epoch Prefix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_INTIN - Decode an Integer Number +

+

+

SLA_INVF - Invert Linear Model +   +

+
+
ACTION: +
Invert a linear model of the type produced by the +sla_FITXY routine. +

CALL: +
CALL sla_INVF (FWDS,BKWDS,J) +

+

+
GIVEN: +
+
+ + + + + +
FWDSD(6)model coefficients
+

+
RETURNED: +
+
+ + + + + + + + + +
BKWDSD(6)inverse model
JIstatus: 0 = OK, -1 = no inverse
+

+
NOTES: +
+
1. +
The models relate two sets of $[\,x,y\,]$ coordinates as follows. +Naming the six elements of FWDS a,b,c,d,e & f, +where two sets of coordinates [x1,y1] and + $[x_{2},y_{2}\,]$ are related thus: +
x2 = a + bx1 + cy1
+ y2 = d + ex1 + fy1
+ The present routine generates a new set of coefficients + p,q,r,s,t & u (the array BKWDS) such that: +
x1 = p + qx2 + ry2
+ y1 = s + tx2 + uy2
+
2. +
Two successive calls to this routine will deliver a set + of coefficients equal to the starting values. +
3. +
To comply with the ANSI Fortran 77 standard, FWDS and BKWDS must + not be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is not, however, + recommended. +
4. +
See also sla_FITXY, sla_PXY, sla_XY2XY, sla_DCMPF. +
+

+ +next + +up + +previous +
+ Next: SLA_KBJ - Select Epoch Prefix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_INTIN - Decode an Integer Number +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node124.html b/src/slalib/sun67.htx/node124.html new file mode 100644 index 0000000..6337e94 --- /dev/null +++ b/src/slalib/sun67.htx/node124.html @@ -0,0 +1,104 @@ + + + + +SLA_KBJ - Select Epoch Prefix + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_M2AV - Rotation Matrix to Axial Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_INVF - Invert Linear Model +

+

+

SLA_KBJ - Select Epoch Prefix +   +

+
+
ACTION: +
Select epoch prefix `B' or `J'. +
CALL: +
CALL sla_KBJ (JB, E, K, J) +

+

+
GIVEN: +
+
+ + + + + + + + + +
JBIsla_DBJIN prefix status: 0=none, 1=`B', 2=`J'
EDepoch - Besselian or Julian
+

+
RETURNED: +
+
+ + + + + + + + + +
KC`B' or `J'
JIstatus: 0=OK
+

+
NOTE: +
The routine is mainly intended for use in conjunction with the +sla_DBJIN routine. If the value of JB indicates that an explicit + B or J prefix was detected by sla_DBJIN, a `B' or `J' + is returned to match. If JB indicates that no explicit B or J + was supplied, the choice is made on the basis of the epoch + itself; B is assumed for E <1984, otherwise J. +
+

+ +next + +up + +previous +
+ Next: SLA_M2AV - Rotation Matrix to Axial Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_INVF - Invert Linear Model +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node125.html b/src/slalib/sun67.htx/node125.html new file mode 100644 index 0000000..2542649 --- /dev/null +++ b/src/slalib/sun67.htx/node125.html @@ -0,0 +1,107 @@ + + + + +SLA_M2AV - Rotation Matrix to Axial Vector + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_MAP - Mean to Apparent +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_KBJ - Select Epoch Prefix +

+

+

SLA_M2AV - Rotation Matrix to Axial Vector +   +

+
+
ACTION: +
From a rotation matrix, determine the corresponding axial vector +(single precision). +

CALL: +
CALL sla_M2AV (RMAT, AXVEC) +

+

+
GIVEN: +
+
+ + + + + +
RMATR(3,3)rotation matrix
+

+
RETURNED: +
+
+ + + + + +
AXVECR(3)axial vector (radians)
+

+
NOTES: +
+
1. +
A rotation matrix describes a rotation about some arbitrary axis. +The axis is called the Euler axis, and the angle through +which the reference frame rotates is called the Euler angle. + The axial vector returned by this routine has the same + direction as the Euler axis, and its magnitude is the Euler angle + in radians. +
2. +
The magnitude and direction of the axial vector can be separated + by means of the routine sla_VN. +
3. +
The reference frame rotates clockwise as seen looking along + the axial vector from the origin. +
4. +
If RMAT is null, so is the result. +
+

+ +next + +up + +previous +
+ Next: SLA_MAP - Mean to Apparent +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_KBJ - Select Epoch Prefix +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node126.html b/src/slalib/sun67.htx/node126.html new file mode 100644 index 0000000..abe5fb6 --- /dev/null +++ b/src/slalib/sun67.htx/node126.html @@ -0,0 +1,157 @@ + + + + +SLA_MAP - Mean to Apparent + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_MAPPA - Mean to Apparent Parameters +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_M2AV - Rotation Matrix to Axial Vector +

+

+

SLA_MAP - Mean to Apparent +   +

+
+
ACTION: +
Transform star $[\,\alpha,\delta\,]$ from mean place to geocentric apparent. +The reference frames and timescales used are post IAU 1976. +

CALL: +
CALL sla_MAP (RM, DM, PR, PD, PX, RV, EQ, DATE, RA, DA) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
RM,DMDmean $[\,\alpha,\delta\,]$ (radians)
PR,PDDproper motions: $[\,\alpha,\delta\,]$ changes per Julian year
PXDparallax (arcsec)
RVDradial velocity (km s-1, +ve if receding)
EQDepoch and equinox of star data (Julian)
DATEDTDB for apparent place (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
RA,DADapparent $[\,\alpha,\delta\,]$ (radians)
+

+
NOTES: +
+
1. +
EQ is the Julian epoch specifying both the reference +frame and the epoch of the position - usually 2000. +For positions where the epoch and equinox are + different, use the routine sla_PM to apply proper + motion corrections before using this routine. +
2. +
The distinction between the required TDB and TT is + always negligible. Moreover, for all but the most + critical applications UTC is adequate. +
3. +
The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are per year rather than per century. +
4. +
This routine may be wasteful for some applications + because it recomputes the Earth position/velocity and + the precession/nutation matrix each time, and because + it allows for parallax and proper motion. Where + multiple transformations are to be carried out for one + epoch, a faster method is to call the sla_MAPPA routine + once and then either the sla_MAPQK routine (which includes + parallax and proper motion) or sla_MAPQKZ (which assumes + zero parallax and FK5 proper motion). +
+

+
REFERENCES: +
+
1. +
1984 Astronomical Almanac, pp B39-B41. +
2. +
Lederle & Schwan, 1984. Astr.Astrophys. 134, 1-6. +
+

+ +next + +up + +previous +
+ Next: SLA_MAPPA - Mean to Apparent Parameters +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_M2AV - Rotation Matrix to Axial Vector +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node127.html b/src/slalib/sun67.htx/node127.html new file mode 100644 index 0000000..6ed5222 --- /dev/null +++ b/src/slalib/sun67.htx/node127.html @@ -0,0 +1,159 @@ + + + + +SLA_MAPPA - Mean to Apparent Parameters + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_MAPQK - Quick Mean to Apparent +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MAP - Mean to Apparent +

+

+

SLA_MAPPA - Mean to Apparent Parameters +   +

+
+
ACTION: +
Compute star-independent parameters in preparation for +conversions between mean place and geocentric apparent place. + The parameters produced by this routine are required in the + parallax, light deflection, aberration, and precession/nutation + parts of the mean/apparent transformations. + The reference frames and timescales used are post IAU 1976. +

CALL: +
CALL sla_MAPPA (EQ, DATE, AMPRMS) +

+

+
GIVEN: +
+
+ + + + + + + + + +
EQDepoch of mean equinox to be used (Julian)
DATEDTDB (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AMPRMSD(21)star-independent mean-to-apparent parameters:
(1)time interval for proper motion (Julian years)
(2-4)barycentric position of the Earth (AU)
(5-7)heliocentric direction of the Earth (unit vector)
(8)(gravitational radius of +Sun)$\times 2 / $(Sun-Earth distance)
(9-11)v: barycentric Earth velocity in units of c
(12)$\sqrt{1-\left\vert\mbox{\bf v}\right\vert^2}$
(13-21)precession/nutation $3\times3$ matrix
+

+
NOTES: +
+
1. +
For DATE, the distinction between the required TDB and TT +is always negligible. Moreover, for all but the most +critical applications UTC is adequate. +
2. +
The accuracy of the routines using the parameters AMPRMS is + limited by the routine sla_EVP, used here to compute the + Earth position and velocity by the methods of Stumpff. + The maximum error in the resulting aberration corrections is + about 0.3 milliarcsecond. +
3. +
The vectors AMPRMS(2-4) and AMPRMS(5-7) are referred to + the mean equinox and equator of epoch EQ. +
4. +
The parameters produced by this routine are used by + sla_MAPQK and sla_MAPQKZ. +
+

+
REFERENCES: +
+
1. +
1984 Astronomical Almanac, pp B39-B41. +
2. +
Lederle & Schwan, 1984. Astr.Astrophys. 134, 1-6. +
+

+ +next + +up + +previous +
+ Next: SLA_MAPQK - Quick Mean to Apparent +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MAP - Mean to Apparent +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node128.html b/src/slalib/sun67.htx/node128.html new file mode 100644 index 0000000..b705fa9 --- /dev/null +++ b/src/slalib/sun67.htx/node128.html @@ -0,0 +1,187 @@ + + + + +SLA_MAPQK - Quick Mean to Apparent + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_MAPQKZ - Quick Mean-Appt, no PM etc. +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MAPPA - Mean to Apparent Parameters +

+

+

SLA_MAPQK - Quick Mean to Apparent +   +

+
+
ACTION: +
Quick mean to apparent place: transform a star $[\,\alpha,\delta\,]$ from +mean place to geocentric apparent place, given the + star-independent parameters. The reference frames and + timescales used are post IAU 1976. +

CALL: +
CALL sla_MAPQK (RM, DM, PR, PD, PX, RV, AMPRMS, RA, DA) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
RM,DMDmean $[\,\alpha,\delta\,]$ (radians)
PR,PDDproper motions: $[\,\alpha,\delta\,]$ changes per Julian year
PXDparallax (arcsec)
RVDradial velocity (km s-1, +ve if receding)
AMPRMSD(21)star-independent mean-to-apparent parameters:
(1)time interval for proper motion (Julian years)
(2-4)barycentric position of the Earth (AU)
(5-7)heliocentric direction of the Earth (unit vector)
(8)(gravitational radius of +Sun)$\times 2 / $(Sun-Earth distance)
(9-11)v: barycentric Earth velocity in units of c
(12)$\sqrt{1-\left\vert\mbox{\bf v}\right\vert^2}$
(13-21)precession/nutation $3\times3$ matrix
+

+
RETURNED: +
+
+ + + + + +
RA,DAD apparent $[\,\alpha,\delta\,]$ (radians)
+

+
NOTES: +
+
1. +
Use of this routine is appropriate when efficiency is important +and where many star positions, all referred to the same equator +and equinox, are to be transformed for one epoch. The + star-independent parameters can be obtained by calling the + sla_MAPPA routine. +
2. +
If the parallax and proper motions are zero the sla_MAPQKZ + routine can be used instead. +
3. +
The vectors AMPRMS(2-4) and AMPRMS(5-7) are referred to + the mean equinox and equator of epoch EQ. +
4. +
Strictly speaking, the routine is not valid for solar-system + sources, though the error will usually be extremely small. + However, to prevent gross errors in the case where the + position of the Sun is specified, the gravitational + deflection term is restrained within about $920\hspace{-0.05em}^{'\hspace{-0.1em}'}$ of the + centre of the Sun's disc. The term has a maximum value of + about + $1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.85$ at this radius, and decreases to zero as + the centre of the disc is approached. +
+

+
REFERENCES: +
+
1. +
1984 Astronomical Almanac, pp B39-B41. +
2. +
Lederle & Schwan, 1984. Astr.Astrophys. 134, 1-6. +
+

+ +next + +up + +previous +
+ Next: SLA_MAPQKZ - Quick Mean-Appt, no PM etc. +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MAPPA - Mean to Apparent Parameters +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node129.html b/src/slalib/sun67.htx/node129.html new file mode 100644 index 0000000..6cb5fed --- /dev/null +++ b/src/slalib/sun67.htx/node129.html @@ -0,0 +1,175 @@ + + + + +SLA_MAPQKZ - Quick Mean-Appt, no PM etc. + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_MOON - Approx Moon Pos/Vel +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MAPQK - Quick Mean to Apparent +

+

+

SLA_MAPQKZ - Quick Mean-Appt, no PM etc. +   +

+
+
ACTION: +
Quick mean to apparent place: transform a star $[\,\alpha,\delta\,]$ from +mean place to geocentric apparent place, given the + star-independent parameters, and assuming zero parallax + and FK5 proper motion. + The reference frames and timescales used are post IAU 1976. +

CALL: +
CALL sla_MAPQKZ (RM, DM, AMPRMS, RA, DA) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
RM,DMDmean $[\,\alpha,\delta\,]$ (radians)
AMPRMSD(21)star-independent mean-to-apparent parameters:
(1)time interval for proper motion (Julian years)
(2-4)barycentric position of the Earth (AU)
(5-7)heliocentric direction of the Earth (unit vector)
(8)(gravitational radius of +Sun)$\times 2 / $(Sun-Earth distance)
(9-11)v: barycentric Earth velocity in units of c
(12)$\sqrt{1-\left\vert\mbox{\bf v}\right\vert^2}$
(13-21)precession/nutation $3\times3$ matrix
+

+
RETURNED: +
+
+ + + + + +
RA,DADapparent $[\,\alpha,\delta\,]$ (radians)
+

+
NOTES: +
+
1. +
Use of this routine is appropriate when efficiency is important +and where many star positions, all with parallax and proper +motion either zero or already allowed for, and all referred to + the same equator and equinox, are to be transformed for one + epoch. The star-independent parameters can be obtained by + calling the sla_MAPPA routine. +
2. +
The corresponding routine for the case of non-zero parallax + and FK5 proper motion is sla_MAPQK. +
3. +
The vectors AMPRMS(2-4) and AMPRMS(5-7) are referred to the + mean equinox and equator of epoch EQ. +
4. +
Strictly speaking, the routine is not valid for solar-system + sources, though the error will usually be extremely small. + However, to prevent gross errors in the case where the + position of the Sun is specified, the gravitational + deflection term is restrained within about $920\hspace{-0.05em}^{'\hspace{-0.1em}'}$ of the + centre of the Sun's disc. The term has a maximum value of + about + $1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.85$ at this radius, and decreases to zero as + the centre of the disc is approached. +
+

+
REFERENCES: +
+
1. +
1984 Astronomical Almanac, pp B39-B41. +
2. +
Lederle & Schwan, 1984. Astr.Astrophys. 134, 1-6. +
+

+ +next + +up + +previous +
+ Next: SLA_MOON - Approx Moon Pos/Vel +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MAPQK - Quick Mean to Apparent +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node13.html b/src/slalib/sun67.htx/node13.html new file mode 100644 index 0000000..c8106bf --- /dev/null +++ b/src/slalib/sun67.htx/node13.html @@ -0,0 +1,489 @@ + + + + +SUBPROGRAM SPECIFICATIONS + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_ADDET - Add E-terms of Aberration +
+Up: SLALIB Positional Astronomy Library +
+ Previous: LINKING +

+

+

+SUBPROGRAM SPECIFICATIONS +

+



+ +  + + +

+ +next + +up + +previous +
+ Next: SLA_ADDET - Add E-terms of Aberration +
+Up: SLALIB Positional Astronomy Library +
+ Previous: LINKING +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node130.html b/src/slalib/sun67.htx/node130.html new file mode 100644 index 0000000..99d6086 --- /dev/null +++ b/src/slalib/sun67.htx/node130.html @@ -0,0 +1,140 @@ + + + + +SLA_MOON - Approx Moon Pos/Vel + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_MXM - Multiply Matrices +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MAPQKZ - Quick Mean-Appt, no PM etc. +

+

+

SLA_MOON - Approx Moon Pos/Vel +   +

+
+
ACTION: +
Approximate geocentric position and velocity of the Moon +(single precision). +

CALL: +
CALL sla_MOON (IY, ID, FD, PV) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
IYIyear
IDIday in year (1 = Jan 1st)
FDR fraction of day
+

+
RETURNED: +
+
+ + + + + +
PVR(6)Moon $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$, mean equator and equinox of +date (AU, AU s-1)
+

+
NOTES: +
+
1. +
The date and time is TDB (loosely ET) in a Julian calendar +which has been aligned to the ordinary Gregorian +calendar for the interval 1900 March 1 to 2100 February 28. + The year and day can be obtained by calling sla_CALYD or + sla_CLYD. +
2. +
The position is accurate to better than 0.5 arcminute + in direction and 1000 km in distance. The velocity + is accurate to better than + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$ per hour in direction + and 4 metres per socond in distance. (RMS figures with respect + to JPL DE200 for the interval 1960-2025 are $14\hspace{-0.05em}^{'\hspace{-0.1em}'}$ and +

$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$ per hour in longitude, $9\hspace{-0.05em}^{'\hspace{-0.1em}'}$ and + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$

+per hour in latitude, 350 km and 2 metres per second in distance.) + Note that the distance accuracy is comparatively poor because this + routine is principally intended for computing topocentric direction. +

3. +
This routine is only a partial implementation of the original + Meeus algorithm (reference below), which offers 4 times the + accuracy in direction and 20 times the accuracy in distance + when fully implemented (as it is in sla_DMOON). +
+

+
REFERENCE: +
Meeus, l'Astronomie, June 1984, p348. +
+

+ +next + +up + +previous +
+ Next: SLA_MXM - Multiply Matrices +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MAPQKZ - Quick Mean-Appt, no PM etc. +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node131.html b/src/slalib/sun67.htx/node131.html new file mode 100644 index 0000000..7ee2c74 --- /dev/null +++ b/src/slalib/sun67.htx/node131.html @@ -0,0 +1,106 @@ + + + + +SLA_MXM - Multiply Matrices + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_MXV - Apply 3D Rotation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MOON - Approx Moon Pos/Vel +

+

+

    +
+SLA_MXM - Multiply $3\times3$ Matrices +

+
+
ACTION: +
Product of two $3\times3$ matrices (single precision). +
CALL: +
CALL sla_MXM (A, B, C) +

+

+
GIVEN: +
+
+ + + + + + + + + +
AR(3,3)matrix A
BR(3,3)matrix B
+

+
RETURNED: +
+
+ + + + + +
CR(3,3)matrix result: A$\times$B
+

+
NOTE: +
To comply with the ANSI Fortran 77 standard, A, B and C must +be different arrays. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is not, however, + recommended. +
+

+ +next + +up + +previous +
+ Next: SLA_MXV - Apply 3D Rotation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MOON - Approx Moon Pos/Vel +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node132.html b/src/slalib/sun67.htx/node132.html new file mode 100644 index 0000000..5084d3d --- /dev/null +++ b/src/slalib/sun67.htx/node132.html @@ -0,0 +1,117 @@ + + + + +SLA_MXV - Apply 3D Rotation + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_NUT - Nutation Matrix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MXM - Multiply Matrices +

+

+

SLA_MXV - Apply 3D Rotation +   +

+
+
ACTION: +
Multiply a 3-vector by a rotation matrix (single precision). +
CALL: +
CALL sla_MXV (RM, VA, VB) +

+

+
GIVEN: +
+
+ + + + + + + + + +
RMR(3,3)rotation matrix
VAR(3)vector to be rotated
+

+
RETURNED: +
+
+ + + + + +
VBR(3)result vector
+

+
NOTES: +
+
1. +
This routine performs the operation: +
b = M$\cdot$a +
+ where a and b are the 3-vectors VA and VB + respectively, and M is the $3\times3$ matrix RM. +
2. +
The main function of this routine is apply a + rotation; under these circumstances, ${\bf M}$ is a + proper real orthogonal matrix. +
3. +
To comply with the ANSI Fortran 77 standard, VA and VB must + not be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is not, however, + recommended. +
+

+ +next + +up + +previous +
+ Next: SLA_NUT - Nutation Matrix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MXM - Multiply Matrices +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node133.html b/src/slalib/sun67.htx/node133.html new file mode 100644 index 0000000..a849a15 --- /dev/null +++ b/src/slalib/sun67.htx/node133.html @@ -0,0 +1,111 @@ + + + + +SLA_NUT - Nutation Matrix + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_NUTC - Nutation Components +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MXV - Apply 3D Rotation +

+

+

SLA_NUT - Nutation Matrix +   +

+
+
ACTION: +
Form the matrix of nutation (IAU 1980 theory) for a given date. +
CALL: +
CALL sla_NUT (DATE, RMATN) +

+

+
GIVEN: +
+
+ + + + + +
DATEDTDB (formerly ET) as Modified Julian Date +(JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
RMATND(3,3)nutation matrix
+

+
NOTE: +
The matrix is in the sense: +
vtrue = M$\cdot$vmean
+ where vtrue is the star vector relative to the + true equator and equinox of date, M is the + $3\times3$ matrix RMATN and + vmean is the star vector relative to the + mean equator and equinox of date. +
+

+
REFERENCES: +
+
1. +
Final report of the IAU Working Group on Nutation, +chairman P.K.Seidelmann, 1980. +
2. +
Kaplan, G.H., 1981. USNO circular No. 163, pA3-6. +
+

+ +next + +up + +previous +
+ Next: SLA_NUTC - Nutation Components +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_MXV - Apply 3D Rotation +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node134.html b/src/slalib/sun67.htx/node134.html new file mode 100644 index 0000000..a2b5df6 --- /dev/null +++ b/src/slalib/sun67.htx/node134.html @@ -0,0 +1,102 @@ + + + + +SLA_NUTC - Nutation Components + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_OAP - Observed to Apparent +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_NUT - Nutation Matrix +

+

+

SLA_NUTC - Nutation Components +   +

+
+
ACTION: +
Nutation (IAU 1980 theory): longitude & obliquity +components, and mean obliquity. +

CALL: +
CALL sla_NUTC (DATE, DPSI, DEPS, EPS0) +

+

+
GIVEN: +
+
+ + + + + +
DATEDTDB (formerly ET) as Modified Julian Date +(JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + + + + + +
DPSI,DEPSDnutation in longitude and obliquity (radians)
EPS0Dmean obliquity (radians)
+

+
REFERENCES: +
+
1. +
Final report of the IAU Working Group on Nutation, +chairman P.K.Seidelmann, 1980. +
2. +
Kaplan, G.H., 1981. USNO circular no. 163, pA3-6. +
+

+ +next + +up + +previous +
+ Next: SLA_OAP - Observed to Apparent +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_NUT - Nutation Matrix +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node135.html b/src/slalib/sun67.htx/node135.html new file mode 100644 index 0000000..753bc4c --- /dev/null +++ b/src/slalib/sun67.htx/node135.html @@ -0,0 +1,319 @@ + + + + +SLA_OAP - Observed to Apparent + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_OAPQK - Quick Observed to Apparent +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_NUTC - Nutation Components +

+

+

SLA_OAP - Observed to Apparent +   +

+
+
ACTION: +
Observed to apparent place. +
CALL: +
CALL sla_OAP ( + TYPE, OB1, OB2, DATE, DUT, ELONGM, PHIM, + HM, XP, YP, TDK, PMB, RH, WL, TLR, RAP, DAP) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TYPEC*(*)type of coordinates - `R', `H' or `A' (see below)
OB1Dobserved Az, HA or RA (radians; Az is N=0, E=$90^{\circ}$)
OB2Dobserved zenith distance or $\delta$ (radians)
DATED UTC date/time (Modified Julian Date, JD-2400000.5)
DUTD$\Delta$UT: UT1-UTC (UTC seconds)
ELONGMDobserver's mean longitude (radians, east +ve)
PHIMDobserver's mean geodetic latitude (radians)
HMDobserver's height above sea level (metres)
XP,YPDpolar motion $[\,x,y\,]$ coordinates (radians)
TDKDlocal ambient temperature (degrees K; std=273.155D0)
PMBDlocal atmospheric pressure (mB; std=1013.25D0)
RHDlocal relative humidity (in the range 0D0-1D0)
WLDeffective wavelength ($\mu{\rm m}$, e.g. 0.55D0)
TLRDtropospheric lapse rate (degrees K per metre, +e.g. 0.0065D0)
+

+
RETURNED: +
+
+ + + + + +
RAP,DAPDgeocentric apparent $[\,\alpha,\delta\,]$
+

+
NOTES: +
+
1. +
Only the first character of the TYPE argument is significant. +`R' or `r' indicates that OBS1 and OBS2 are the observed Right +Ascension and Declination; `H' or `h' indicates that they are + Hour Angle (west +ve) and Declination; anything else (`A' or + `a' is recommended) indicates that OBS1 and OBS2 are Azimuth + (north zero, east is $90^{\circ}$) and Zenith Distance. (Zenith + distance is used rather than elevation in order to reflect the + fact that no allowance is made for depression of the horizon.) +
2. +
The accuracy of the result is limited by the corrections for + refraction. Providing the meteorological parameters are + known accurately and there are no gross local effects, the + predicted azimuth and elevation should be within about +

$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$ for $\zeta<70^{\circ}$. Even + at a topocentric zenith distance of + $90^{\circ}$, the accuracy in elevation should be better than + 1 arcminute; useful results are available for a further + $3^{\circ}$, beyond which the sla_REFRO routine returns a + fixed value of the refraction. The complementary + routines sla_AOP (or sla_AOPQK) and sla_OAP (or sla_OAPQK) + are self-consistent to better than 1 microarcsecond all over + the celestial sphere. +

3. +
It is advisable to take great care with units, as even + unlikely values of the input parameters are accepted and + processed in accordance with the models used. +
4. +
Observed $[\,Az,El~]$ means the position that would be seen by a + perfect theodolite located at the observer. This is + related to the observed $[\,h,\delta\,]$ via the standard rotation, using + the geodetic latitude (corrected for polar motion), while the + observed HA and RA are related simply through the local + apparent ST. Observed $[\,\alpha,\delta\,]$ or $[\,h,\delta\,]$ thus means the + position that would be seen by a perfect equatorial located + at the observer and with its polar axis aligned to the + Earth's axis of rotation (n.b. not to the refracted pole). + By removing from the observed place the effects of + atmospheric refraction and diurnal aberration, the + geocentric apparent $[\,\alpha,\delta\,]$ is obtained. +
5. +
Frequently, mean rather than apparent + $[\,\alpha,\delta\,]$ will be required, + in which case further transformations will be necessary. The + sla_AMP etc. routines will convert + the apparent $[\,\alpha,\delta\,]$ produced + by the present routine into an FK5 J2000 mean place, by + allowing for the Sun's gravitational lens effect, annual + aberration, nutation and precession. Should FK4 B1950 + coordinates be needed, the routines sla_FK524 etc. will also + need to be applied. +
6. +
To convert to apparent $[\,\alpha,\delta\,]$ the coordinates read from a + real telescope, corrections would have to be applied for + encoder zero points, gear and encoder errors, tube flexure, + the position of the rotator axis and the pointing axis + relative to it, non-perpendicularity between the mounting + axes, and finally for the tilt of the azimuth or polar axis + of the mounting (with appropriate corrections for mount + flexures). Some telescopes would, of course, exhibit other + properties which would need to be accounted for at the + appropriate point in the sequence. +
7. +
The star-independent apparent-to-observed-place parameters + in AOPRMS may be computed by means of the sla_AOPPA routine. + If nothing has changed significantly except the time, the + sla_AOPPAT routine may be used to perform the requisite + partial recomputation of AOPRMS. +
8. +
The DATE argument is UTC expressed as an MJD. This is, + strictly speaking, wrong, because of leap seconds. However, + as long as the $\Delta$UT and the UTC are consistent there + are no difficulties, except during a leap second. In this + case, the start of the 61st second of the final minute should + begin a new MJD day and the old pre-leap $\Delta$UT should + continue to be used. As the 61st second completes, the MJD + should revert to the start of the day as, simultaneously, + the $\Delta$UT changes by one second to its post-leap new value. +
9. +
The $\Delta$UT (UT1-UTC) is tabulated in IERS circulars and + elsewhere. It increases by exactly one second at the end of + each UTC leap second, introduced in order to keep $\Delta$UT + within $\pm$$0^{\rm s}\hspace{-0.3em}.9$.
10. +
IMPORTANT - TAKE CARE WITH THE LONGITUDE SIGN CONVENTION. The + longitude required by the present routine is east-positive, + in accordance with geographical convention (and right-handed). + In particular, note that the longitudes returned by the + sla_OBS routine are west-positive (as in the Astronomical + Almanac before 1984) and must be reversed in sign before use + in the present routine. +
11. +
The polar coordinates XP,YP can be obtained from IERS + circulars and equivalent publications. The + maximum amplitude is about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$ . If XP,YP values + are unavailable, use XP=YP=0D0. See page B60 of the 1988 + Astronomical Almanac for a definition of the two angles. +
12. +
The height above sea level of the observing station, HM, + can be obtained from the Astronomical Almanac (Section J + in the 1988 edition), or via the routine sla_OBS. If P, + the pressure in mB, is available, an adequate + estimate of HM can be obtained from the following expression: +
HM=-29.3D0*TSL*LOG(P/1013.25D0) +
+ where TSL is the approximate sea-level air temperature in degrees K + (see Astrophysical Quantities, C.W.Allen, 3rd edition, + §52). Similarly, if the pressure P is not known, + it can be estimated from the height of the observing + station, HM as follows: +
P=1013.25D0*EXP(-HM/(29.3D0*TSL)) +
+ Note, however, that the refraction is proportional to the + pressure and that an accurate P value is important for + precise work. +
13. +
The azimuths etc. used by the present routine are with + respect to the celestial pole. Corrections from the terrestrial pole + can be computed using sla_POLMO. +
+

+ +next + +up + +previous +
+ Next: SLA_OAPQK - Quick Observed to Apparent +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_NUTC - Nutation Components +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node136.html b/src/slalib/sun67.htx/node136.html new file mode 100644 index 0000000..dbf0e88 --- /dev/null +++ b/src/slalib/sun67.htx/node136.html @@ -0,0 +1,258 @@ + + + + +SLA_OAPQK - Quick Observed to Apparent + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_OBS - Observatory Parameters +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_OAP - Observed to Apparent +

+

+

SLA_OAPQK - Quick Observed to Apparent +   +

+
+
ACTION: +
Quick observed to apparent place. +
CALL: +
CALL sla_OAPQK (TYPE, OB1, OB2, AOPRMS, RAP, DAP) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TYPEC*(*)type of coordinates - `R', `H' or `A' (see below)
OB1Dobserved Az, HA or RA (radians; Az is N=0, E=$90^{\circ}$)
OB2Dobserved zenith distance or $\delta$ (radians)
AOPRMSD(14)star-independent apparent-to-observed parameters:
(1)geodetic latitude (radians)
(2,3)sine and cosine of geodetic latitude
(4)magnitude of diurnal aberration vector
(5)height (HM)
(6)ambient temperature (TDK)
(7)pressure (PMB)
(8)relative humidity (RH)
(9)wavelength (WL)
(10)lapse rate (TLR)
(11,12)refraction constants A and B (radians)
(13)longitude + eqn of equinoxes + +``sidereal $\Delta$UT'' (radians)
(14)local apparent sidereal time (radians)
+

+
RETURNED: +
+
+ + + + + +
RAP,DAPDgeocentric apparent $[\,\alpha,\delta\,]$
+

+
NOTES: +
+
1. +
Only the first character of the TYPE argument is significant. +`R' or `r' indicates that OBS1 and OBS2 are the observed Right +Ascension and Declination; `H' or `h' indicates that they are + Hour Angle (west +ve) and Declination; anything else (`A' or + `a' is recommended) indicates that OBS1 and OBS2 are Azimuth + (north zero, east is $90^{\circ}$) and Zenith Distance. (Zenith + distance is used rather than elevation in order to reflect the + fact that no allowance is made for depression of the horizon.) +
2. +
The accuracy of the result is limited by the corrections for + refraction. Providing the meteorological parameters are + known accurately and there are no gross local effects, the + predicted azimuth and elevation should be within about +

$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$ for $\zeta<70^{\circ}$. Even + at a topocentric zenith distance of + $90^{\circ}$, the accuracy in elevation should be better than + 1 arcminute; useful results are available for a further + $3^{\circ}$, beyond which the sla_REFRO routine returns a + fixed value of the refraction. The complementary + routines sla_AOP (or sla_AOPQK) and sla_OAP (or sla_OAPQK) + are self-consistent to better than 1 microarcsecond all over + the celestial sphere. +

3. +
It is advisable to take great care with units, as even + unlikely values of the input parameters are accepted and + processed in accordance with the models used. +
4. +
Observed $[\,Az,El~]$ means the position that would be seen by a + perfect theodolite located at the observer. This is + related to the observed $[\,h,\delta\,]$ via the standard rotation, using + the geodetic latitude (corrected for polar motion), while the + observed HA and RA are related simply through the local + apparent ST. Observed $[\,\alpha,\delta\,]$ or $[\,h,\delta\,]$ thus means the + position that would be seen by a perfect equatorial located + at the observer and with its polar axis aligned to the + Earth's axis of rotation (n.b. not to the refracted pole). + By removing from the observed place the effects of + atmospheric refraction and diurnal aberration, the + geocentric apparent $[\,\alpha,\delta\,]$ is obtained. +
5. +
Frequently, mean rather than apparent + $[\,\alpha,\delta\,]$ will be required, + in which case further transformations will be necessary. The + sla_AMP etc. routines will convert + the apparent $[\,\alpha,\delta\,]$ produced + by the present routine into an FK5 J2000 mean place, by + allowing for the Sun's gravitational lens effect, annual + aberration, nutation and precession. Should FK4 B1950 + coordinates be needed, the routines sla_FK524 etc. will also + need to be applied. +
6. +
To convert to apparent $[\,\alpha,\delta\,]$ the coordinates read from a + real telescope, corrections would have to be applied for + encoder zero points, gear and encoder errors, tube flexure, + the position of the rotator axis and the pointing axis + relative to it, non-perpendicularity between the mounting + axes, and finally for the tilt of the azimuth or polar axis + of the mounting (with appropriate corrections for mount + flexures). Some telescopes would, of course, exhibit other + properties which would need to be accounted for at the + appropriate point in the sequence. +
7. +
The star-independent apparent-to-observed-place parameters + in AOPRMS may be computed by means of the sla_AOPPA routine. + If nothing has changed significantly except the time, the + sla_AOPPAT routine may be used to perform the requisite + partial recomputation of AOPRMS. +
8. +
The azimuths etc. used by the present routine are with + respect to the celestial pole. Corrections from the terrestrial pole + can be computed using sla_POLMO. +
+

+ +next + +up + +previous +
+ Next: SLA_OBS - Observatory Parameters +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_OAP - Observed to Apparent +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node137.html b/src/slalib/sun67.htx/node137.html new file mode 100644 index 0000000..eda8158 --- /dev/null +++ b/src/slalib/sun67.htx/node137.html @@ -0,0 +1,247 @@ + + + + +SLA_OBS - Observatory Parameters + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PA - to Parallactic Angle +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_OAPQK - Quick Observed to Apparent +

+

+

SLA_OBS - Observatory Parameters +   +

+
+
ACTION: +
Look up an entry in a standard list of +groundbased observing stations parameters. +

CALL: +
CALL sla_OBS (N, C, NAME, W, P, H) +

+

+
GIVEN: +
+
+ + + + + +
NInumber specifying observing station
+

+
GIVEN or RETURNED: +
+
+ + + + + +
CC*(*)identifier specifying observing station
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
NAMEC*(*)name of specified observing station
WDlongitude (radians, west +ve)
PDgeodetic latitude (radians, north +ve)
HDheight above sea level (metres)
+

+
NOTES: +
+
1. +
Station identifiers C may be up to 10 characters long, +and station names NAME may be up to 40 characters long. +
2. +
C and N are alternative ways of specifying the observing + station. The C option, which is the most generally useful, + may be selected by specifying an N value of zero or less. + If N is 1 or more, the parameters of the Nth station + in the currently supported list are interrogated, and + the station identifier C is returned as well as NAME, W, + P and H. +
3. +
If the station parameters are not available, either because + the station identifier C is not recognized, or because an + N value greater than the number of stations supported is + given, a name of `?' is returned and W, P and H are left in + their current states. +
4. +
Programs can obtain a list of all currently supported + stations by calling the routine repeatedly, with N=1,2,3... + When NAME=`?' is seen, the list of stations has been + exhausted. The stations at the time of writing are listed + below. +
5. +
Station numbers, identifiers, names and other details are + subject to change and should not be hardwired into + application programs. +
6. +
All station identifiers C are uppercase only; lower case + characters must be converted to uppercase by the calling + program. The station names returned may contain both upper- + and lowercase. All characters up to the first space are + checked; thus an abbreviated ID will return the parameters + for the first station in the list which matches the + abbreviation supplied, and no station in the list will ever + contain embedded spaces. C must not have leading spaces. +
7. +
IMPORTANT - BEWARE OF THE LONGITUDE SIGN CONVENTION. The + longitude returned by sla_OBS is + west-positive, following the pre-1984 Astronomical + Almanac. However, this sign convention is left-handed and is + the opposite of the one now used; elsewhere in + SLALIB the preferable east-positive convention is used. In + particular, note that for use in sla_AOP, sla_AOPPA and + sla_OAP the sign of the longitude must be reversed. +
8. +
Users are urged to inform the author of any improvements + they would like to see made. For example: +
    +
  • typographical corrections +
  • more accurate parameters +
  • better station identifiers or names +
  • additional stations +
+Stations supported by sla_OBS at the time of writing: +

+ID 		 NAME 
+ 
+AAT 		 Anglo-Australian 3.9m Telescope 
+ANU2.3 		 Siding Spring 2.3 metre 
+APO3.5 		 Apache Point 3.5m 
+ARECIBO 		 Arecibo 1000 foot 
+ATCA 		 Australia Telescope Compact Array 
+BLOEMF 		 Bloemfontein 1.52 metre 
+BOSQALEGRE 		 Bosque Alegre 1.54 metre 
+CAMB1MILE 		 Cambridge 1 mile 
+CAMB5KM 		 Cambridge 5km 
+CATALINA61 		 Catalina 61 inch 
+CFHT 		 Canada-France-Hawaii 3.6m Telescope 
+CSO 		 Caltech Sub-mm Observatory, Mauna Kea 
+DAO72 		 DAO Victoria BC 1.85 metre 
+DUNLAP74 		 David Dunlap 74 inch 
+DUPONT 		 Du Pont 2.5m Telescope, Las Campanas 
+EFFELSBERG 		 Effelsberg 100 metre 
+ESO3.6 		 ESO 3.6 metre 
+ESONTT 		 ESO 3.5 metre NTT 
+ESOSCHM 		 ESO 1 metre Schmidt, La Silla 
+FCRAO 		 Five College Radio Astronomy Obs 
+FLAGSTF61 		 USNO 61 inch astrograph, Flagstaff 
+GBVA140 		 Greenbank 140 foot 
+GBVA300 		 Greenbank 300 foot 
+GEMININ 		 Gemini North 8-m telescope 
+HARVARD 		 Harvard College Observatory 1.55m 
+HPROV1.52 		 Haute Provence 1.52 metre 
+HPROV1.93 		 Haute Provence 1.93 metre 
+IRTF 		 NASA IR Telescope Facility, Mauna Kea 
+JCMT 		 JCMT 15 metre 
+JODRELL1 		 Jodrell Bank 250 foot 
+KECK1 		 Keck 10m Telescope 1 
+KECK2 		 Keck 10m Telescope 2 
+KISO 		 Kiso 1.05 metre Schmidt, Japan 
+KOTTAMIA 		 Kottamia 74 inch 
+KPNO158 		 Kitt Peak 158 inch 
+KPNO36FT 		 Kitt Peak 36 foot 
+KPNO84 		 Kitt Peak 84 inch 
+KPNO90 		 Kitt Peak 90 inch 
+LICK120 		 Lick 120 inch 
+LOWELL72 		 Perkins 72 inch, Lowell 
+LPO1 		 Jacobus Kapteyn 1m Telescope 
+LPO2.5 		 Isaac Newton 2.5m Telescope 
+LPO4.2 		 William Herschel 4.2m Telescope 
+MAUNAK88 		 Mauna Kea 88 inch 
+MCDONLD2.1 		 McDonald 2.1 metre 
+MCDONLD2.7 		 McDonald 2.7 metre 
+MMT 		 MMT, Mt Hopkins 
+MOPRA 		 ATNF Mopra Observatory 
+MTEKAR 		 Mt Ekar 1.82 metre 
+MTHOP1.5 		 Mt Hopkins 1.5 metre 
+MTLEMMON60 		 Mt Lemmon 60 inch 
+NOBEYAMA 		 Nobeyama 45 metre 
+OKAYAMA 		 Okayama 1.88 metre 
+PALOMAR200 		 Palomar 200 inch 
+PALOMAR48 		 Palomar 48-inch Schmidt 
+PALOMAR60 		 Palomar 60 inch 
+PARKES 		 Parkes 64 metre 
+QUEBEC1.6 		 Quebec 1.6 metre 
+SAAO74 		 Sutherland 74 inch 
+SANPM83 		 San Pedro Martir 83 inch 
+ST.ANDREWS 		 St Andrews University Observatory 
+STEWARD90 		 Steward 90 inch 
+STROMLO74 		 Mount Stromlo 74 inch 
+SUBARU 		 Subaru 8 metre 
+SUGARGROVE 		 Sugar Grove 150 foot 
+TAUTNBG 		 Tautenburg 2 metre 
+TAUTSCHM 		 Tautenberg 1.34 metre Schmidt 
+TIDBINBLA 		 Tidbinbilla 64 metre 
+TOLOLO1.5M 		 Cerro Tololo 1.5 metre 
+TOLOLO4M 		 Cerro Tololo 4 metre 
+UKIRT 		 UK Infra Red Telescope 
+UKST 		 UK 1.2 metre Schmidt, Siding Spring 
+USSR6 		 USSR 6 metre 
+USSR600 		 USSR 600 foot 
+VLA 		 Very Large Array
+
+

+ +next + +up + +previous +
+ Next: SLA_PA - to Parallactic Angle +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_OAPQK - Quick Observed to Apparent +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node138.html b/src/slalib/sun67.htx/node138.html new file mode 100644 index 0000000..d363298 --- /dev/null +++ b/src/slalib/sun67.htx/node138.html @@ -0,0 +1,116 @@ + + + + +SLA_PA - to Parallactic Angle + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PAV - Position-Angle Between Two Directions +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_OBS - Observatory Parameters +

+

+

    +
+SLA_PA - $h,\delta$ to Parallactic Angle +

+
+
ACTION: +
Hour angle and declination to parallactic angle +(double precision). +

CALL: +
D = sla_PA (HA, DEC, PHI) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
HADhour angle in radians (geocentric apparent)
DECDdeclination in radians (geocentric apparent)
PHIDlatitude in radians (geodetic)
+

+
RETURNED: +
+
+ + + + + +
sla_PADparallactic angle (radians, in the range $\pm \pi$)
+

+
NOTES: +
+
1. +
The parallactic angle at a point in the sky is the position +angle of the vertical, i.e. the angle between the direction to +the pole and to the zenith. In precise applications care must + be taken only to use geocentric apparent $[\,h,\delta\,]$ and to consider + separately the effects of atmospheric refraction and telescope + mount errors. +
2. +
At the pole a zero result is returned. +
+

+ +next + +up + +previous +
+ Next: SLA_PAV - Position-Angle Between Two Directions +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_OBS - Observatory Parameters +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node139.html b/src/slalib/sun67.htx/node139.html new file mode 100644 index 0000000..13d3907 --- /dev/null +++ b/src/slalib/sun67.htx/node139.html @@ -0,0 +1,117 @@ + + + + +SLA_PAV - Position-Angle Between Two Directions + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PCD - Apply Radial Distortion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PA - to Parallactic Angle +

+

+

SLA_PAV - Position-Angle Between Two Directions +   +

+
+
ACTION: +
Returns the bearing (position angle) of one celestial +direction with respect to another (single precision). +

CALL: +
R = sla_PAV (V1, V2) +

+

+
GIVEN: +
+
+ + + + + + + + + +
V1R(3)direction cosines of one point
V2R(3)directions cosines of the other point
+

+
RETURNED: +
+
+ + + + + +
sla_PAVRposition-angle of 2nd point with respect to 1st
+

+
NOTES: +
+
1. +
The coordinate frames correspond to $[\,\alpha,\delta\,]$,$[\lambda,\phi]$ etc.. +
2. +
The result is the bearing (position angle), in radians, + of point V2 as seen + from point V1. It is in the range $\pm \pi$. The sense + is such that if V2 + is a small distance due east of V1 the result + is about $+\pi/2$. Zero is returned + if the two points are coincident. +
3. +
The routine sla_BEAR performs an equivalent function except + that the points are specified in the form of spherical coordinates. +
+

+ +next + +up + +previous +
+ Next: SLA_PCD - Apply Radial Distortion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PA - to Parallactic Angle +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node14.html b/src/slalib/sun67.htx/node14.html new file mode 100644 index 0000000..9a2b861 --- /dev/null +++ b/src/slalib/sun67.htx/node14.html @@ -0,0 +1,112 @@ + + + + +SLA_ADDET - Add E-terms of Aberration + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_AFIN - Sexagesimal character string to angle +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SUBPROGRAM SPECIFICATIONS +

+

+

SLA_ADDET - Add E-terms of Aberration +   +

+
+
ACTION: +
Add the E-terms (elliptic component of annual aberration) to a +pre IAU 1976 mean place to conform to the old catalogue convention. +

CALL: +
CALL sla_ADDET (RM, DM, EQ, RC, DC) +

+

+
GIVEN: +
+
+ + + + + + + + + +
RM,DMD$[\,\alpha,\delta\,]$ without E-terms (radians)
EQDBesselian epoch of mean equator and equinox
+

+
RETURNED: +
+
+ + + + + +
RC,DCD$[\,\alpha,\delta\,]$ with E-terms included (radians)
+

+
NOTE: +
Most star positions from pre-1984 optical catalogues (or +obtained by astrometry with respect to such stars) have the + E-terms built-in. If it is necessary to convert a formal mean + place (for example a pulsar timing position) to one + consistent with such a star catalogue, then the + $[\,\alpha,\delta\,]$ should be adjusted using this routine. +
+

+
REFERENCE: +
Explanatory Supplement to the Astronomical Ephemeris, +section 2D, page 48. +
+

+ +next + +up + +previous +
+ Next: SLA_AFIN - Sexagesimal character string to angle +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SUBPROGRAM SPECIFICATIONS +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node140.html b/src/slalib/sun67.htx/node140.html new file mode 100644 index 0000000..aaf99dc --- /dev/null +++ b/src/slalib/sun67.htx/node140.html @@ -0,0 +1,148 @@ + + + + +SLA_PCD - Apply Radial Distortion + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PDA2H - H.A. for a Given Azimuth +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PAV - Position-Angle Between Two Directions +

+

+

SLA_PCD - Apply Radial Distortion +   +

+
+
ACTION: +
Apply pincushion/barrel distortion to a tangent-plane $[\,x,y\,]$.
CALL: +
CALL sla_PCD (DISCO,X,Y) +

+

+
GIVEN: +
+
+ + + + + + + + + +
DISCODpincushion/barrel distortion coefficient
X,YDtangent-plane $[\,x,y\,]$
+

+
RETURNED: +
+
+ + + + + +
X,YDdistorted $[\,x,y\,]$
+

+
NOTES: +
+
1. +
The distortion is of the form $\rho = r (1 + c r^{2})$, where r is +the radial distance from the tangent point, c is the DISCO +argument, and $\rho$ is the radial distance in the presence of + the distortion. +
2. +
For pincushion distortion, C is +ve; for + barrel distortion, C is -ve. +
3. +
For X,Y in units of one projection radius (in the case of + a photographic plate, the focal length), the following + DISCO values apply: +


+
+
+

+ + + + + + + + + + + + + + + + + + + + + +
GeometryDISCO
astrograph0.0
Schmidt-0.3333
AAT PF doublet+147.069
AAT PF triplet+178.585
AAT f/8+21.20
JKT f/8+14.6
+


+
+
+

4. +
There is a companion routine, sla_UNPCD, which performs + an approximately inverse operation. +
+

+ +next + +up + +previous +
+ Next: SLA_PDA2H - H.A. for a Given Azimuth +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PAV - Position-Angle Between Two Directions +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node141.html b/src/slalib/sun67.htx/node141.html new file mode 100644 index 0000000..6e011b5 --- /dev/null +++ b/src/slalib/sun67.htx/node141.html @@ -0,0 +1,107 @@ + + + + +SLA_PDA2H - H.A. for a Given Azimuth + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PDQ2H - H.A. for a Given P.A. +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PCD - Apply Radial Distortion +

+

+

SLA_PDA2H - H.A. for a Given Azimuth +   +

+
+
ACTION: +
Hour Angle corresponding to a given azimuth (double precision). +
CALL: +
CALL sla_PDA2H (P, D, A, H1, J1, H2, J2) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
PDlatitude
DDdeclination
ADazimuth
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
H1Dhour angle: first solution if any
J1Iflag: 0 = solution 1 is valid
H2Dhour angle: second solution if any
J2Iflag: 0 = solution 2 is valid
+

+ +next + +up + +previous +
+ Next: SLA_PDQ2H - H.A. for a Given P.A. +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PCD - Apply Radial Distortion +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node142.html b/src/slalib/sun67.htx/node142.html new file mode 100644 index 0000000..f105cf4 --- /dev/null +++ b/src/slalib/sun67.htx/node142.html @@ -0,0 +1,108 @@ + + + + +SLA_PDQ2H - H.A. for a Given P.A. + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PERMUT - Next Permutation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PDA2H - H.A. for a Given Azimuth +

+

+

SLA_PDQ2H - H.A. for a Given P.A. +   +

+
+
ACTION: +
Hour Angle corresponding to a given parallactic angle +(double precision). +

CALL: +
CALL sla_PDQ2H (P, D, Q, H1, J1, H2, J2) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
PDlatitude
DDdeclination
QDazimuth
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
H1Dhour angle: first solution if any
J1Iflag: 0 = solution 1 is valid
H2Dhour angle: second solution if any
J2Iflag: 0 = solution 2 is valid
+

+ +next + +up + +previous +
+ Next: SLA_PERMUT - Next Permutation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PDA2H - H.A. for a Given Azimuth +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node143.html b/src/slalib/sun67.htx/node143.html new file mode 100644 index 0000000..46f3e9e --- /dev/null +++ b/src/slalib/sun67.htx/node143.html @@ -0,0 +1,133 @@ + + + + +SLA_PERMUT - Next Permutation + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PERTEL - Perturbed Orbital Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PDQ2H - H.A. for a Given P.A. +

+

+

SLA_PERMUT - Next Permutation +   +

+
+
ACTION: +
Generate the next permutation of a specified number of items. +
CALL: +
CALL sla_PERMUT (N, ISTATE, IORDER, J) +

+

+
GIVEN: +
+
+ + + + + + + + + +
NInumber of items: there will be N! permutations
ISTATEI(N)state, ISTATE(1)=-1 to initialize
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
ISTATEI(N)state, updated ready for next time
IORDERI(N)next permutation of numbers 1,2,...,N
JIstatus:
-1 = illegal N (zero or less is illegal)
0 = OK
+1 = no more permutations available
+

+
NOTES: +
+
1. +
This routine returns, in the IORDER array, the integers 1 to N +inclusive, in an order that depends on the current contents of +the ISTATE array. Before calling the routine for the first + time, the caller must set the first element of the ISTATE array + to -1 (any negative number will do) to cause the ISTATE array + to be fully initialized. +
2. +
The first permutation to be generated is: +
IORDER(1)=N, IORDER(2)=N-1, ..., IORDER(N)=1 +
+ This is also the permutation returned for the ``finished'' (J=1) case. + The final permutation to be generated is: +
IORDER(1)=1, IORDER(2)=2, ..., IORDER(N)=N +
+
3. +
If the ``finished'' (J=1) status is ignored, the routine continues + to deliver permutations, the pattern repeating every N! calls. +
+

+ +next + +up + +previous +
+ Next: SLA_PERTEL - Perturbed Orbital Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PDQ2H - H.A. for a Given P.A. +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node144.html b/src/slalib/sun67.htx/node144.html new file mode 100644 index 0000000..eb511e6 --- /dev/null +++ b/src/slalib/sun67.htx/node144.html @@ -0,0 +1,310 @@ + + + + +SLA_PERTEL - Perturbed Orbital Elements + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PERTUE - Perturbed Universal Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PERMUT - Next Permutation +

+

+

SLA_PERTEL - Perturbed Orbital Elements +   +

+
+
ACTION: +
Update the osculating elements of an asteroid or comet by +applying planetary perturbations. +

CALL: +
CALL sla_PERTEL ( + JFORM, DATE0, DATE1, + EPOCH0, ORBI0, ANODE0, PERIH0, AORQ0, E0, AM0, + EPOCH1, ORBI1, ANODE1, PERIH1, AORQ1, E1, AM1, + JSTAT) +

+

+
GIVEN (format and dates): +
+
+ + + + + + + + + + + + + + + + + + + + + +
JFORMIchoice of element set (2 or 3; Note 1)
DATE0Ddate of osculation (TT MJD) for the given
elements
DATE1Ddate of osculation (TT MJD) for the updated
elements
+

+
GIVEN (the unperturbed elements): +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EPOCH0Depoch of the given element set +(t0 or T, TT MJD;
Note 2)
ORBI0Dinclination (i, radians)
ANODE0Dlongitude of the ascending node ($\Omega$, radians)
PERIH0Dargument of perihelion +($\omega$, radians)
AORQ0Dmean distance or perihelion distance (a or q, AU)
E0Deccentricity (e)
AM0Dmean anomaly (M, radians, JFORM=2 only)
+

+
RETURNED (the updated elements): +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EPOCH1Depoch of the updated element set +(t0 or T,
TT MJD; Note 2)
ORBI1Dinclination (i, radians)
ANODE1Dlongitude of the ascending node ($\Omega$, radians)
PERIH1Dargument of perihelion +($\omega$, radians)
AORQ1Dmean distance or perihelion distance (a or q, AU)
E1Deccentricity (e)
AM1Dmean anomaly (M, radians, JFORM=2 only)
+

+
RETURNED (status flag): +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
JSTATIstatus:
+102 = warning, distant epoch
+101 = warning, large timespan +(>100 years)
+1 to +8 = coincident with major planet +(Note 6)
0 = OK
-1 = illegal JFORM
-2 = illegal E0
-3 = illegal AORQ0
-4 = internal error
-5 = numerical error
+

+
NOTES: +
+
1. +
Two different element-format options are supported, as follows.
+JFORM=2, suitable for minor planets: +

+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e < 1 )$ 
+		 AORL 		 = 		 mean anomaly M (radians)        
+
+

+JFORM=3, suitable for comets: +


+ 		 EPOCH 		 = 		 epoch of perihelion T (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 perihelion distance q (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e \leq 10 )$
+
2. +
DATE0, DATE1, EPOCH0 and EPOCH1 are all instants of time in + the TT timescale (formerly Ephemeris Time, ET), expressed + as Modified Julian Dates (JD-2400000.5). +
    +
  • DATE0 is the instant at which the given + (i.e. unperturbed) osculating elements are correct. +
  • DATE1 is the specified instant at which the updated osculating + elements are correct. +
  • EPOCH0 and EPOCH1 will be the same as DATE0 and DATE1 + (respectively) for the JFORM=2 case, normally used for minor + planets. For the JFORM=3 case, the two epochs will refer to + perihelion passage and so will not, in general, be the same as + DATE0 and/or DATE1 though they may be similar to one another. +
+
3. +
The elements are with respect to the J2000 ecliptic and mean equinox. +
4. +
Unused elements (AM0 and AM1 for JFORM=3) are not accessed. +
5. +
See the sla_PERTUE routine for details of the algorithm used. +
6. +
This routine is not intended to be used for major planets, which + is why JFORM=1 is not available and why there is no opportunity + to specify either the longitude of perihelion or the daily + motion. However, if JFORM=2 elements are somehow obtained for a + major planet and supplied to the routine, sensible results will, + in fact, be produced. This happens because the sla_PERTUE routine + that is called to perform the calculations checks the separation + between the body and each of the planets and interprets a + suspiciously small value (0.001 AU) as an attempt to apply it to + the planet concerned. If this condition is detected, the + contribution from that planet is ignored, and the status is set to + the planet number (Mercury=1,...,Neptune=8) as a warning. +
+

+
REFERENCE: +
Sterne, Theodore E., An Introduction to Celestial Mechanics, +Interscience Publishers, 1960. Section 6.7, p199. +
+

+ +next + +up + +previous +
+ Next: SLA_PERTUE - Perturbed Universal Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PERMUT - Next Permutation +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node145.html b/src/slalib/sun67.htx/node145.html new file mode 100644 index 0000000..8fbb853 --- /dev/null +++ b/src/slalib/sun67.htx/node145.html @@ -0,0 +1,279 @@ + + + + +SLA_PERTUE - Perturbed Universal Elements + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PLANEL - Planet Position from Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PERTEL - Perturbed Orbital Elements +

+

+

SLA_PERTUE - Perturbed Universal Elements +   +

+
+
ACTION: +
Update the universal elements of an asteroid or comet by +applying planetary perturbations. +

CALL: +
CALL sla_PERTUE (DATE, U, JSTAT) +

+

+
GIVEN: +
+
+ + + + + +
DATE1Dfinal epoch (TT MJD) for the updated elements
+

+
GIVEN and RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
UD(13)universal elements (updated in place)
(1)combined mass (M+m)
(2)total energy of the orbit ($\alpha$)
(3)reference (osculating) epoch (t0)
(4-6)position at reference epoch (${\rm \bf r}_0$)
(7-9)velocity at reference epoch (${\rm \bf v}_0$)
(10)heliocentric distance at reference epoch
(11)${\rm \bf r}_0.{\rm \bf v}_0$
(12)date (t)
(13)universal eccentric anomaly ($\psi$) of date, approx
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
JSTATIstatus:
+102 = warning, distant epoch
+101 = warning, large timespan +(>100 years)
+1 to +8 = coincident with major planet +(Note 5)
0 = OK
-1 = numerical error
+

+
NOTES: +
+
1. +
The ``universal'' elements are those which define the orbit for the +purposes of the method of universal variables (see reference 2). +They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i) $\alpha$, which is proportional to the total energy of the + orbit, (ii) the heliocentric distance at epoch, + (iii) the outwards component of the velocity at the given epoch, + (iv) an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v) that date. +
2. +
The universal elements are with respect to the J2000 equator and + equinox. +
3. +
The epochs DATE, U(3) and U(12) are all Modified Julian Dates + (JD-2400000.5). +
4. +
The algorithm is a simplified form of Encke's method. It takes as + a basis the unperturbed motion of the body, and numerically + integrates the perturbing accelerations from the major planets. + The expression used is essentially Sterne's 6.7-2 (reference 1). + Everhart and Pitkin (reference 2) suggest rectifying the orbit at + each integration step by propagating the new perturbed position + and velocity as the new universal variables. In the present + routine the orbit is rectified less frequently than this, in order + to gain a slight speed advantage. However, the rectification is + done directly in terms of position and velocity, as suggested by + Everhart and Pitkin, bypassing the use of conventional orbital + elements. +

+The f(q) part of the full Encke method is not used. The purpose + of this part is to avoid subtracting two nearly equal quantities + when calculating the ``indirect member'', which takes account of the + small change in the Sun's attraction due to the slightly displaced + position of the perturbed body. A simpler, direct calculation in + double precision proves to be faster and not significantly less + accurate. +

+Apart from employing a variable timestep, and occasionally + ``rectifying the orbit'' to keep the indirect member small, the + integration is done in a fairly straightforward way. The + acceleration estimated for the middle of the timestep is assumed + to apply throughout that timestep; it is also used in the + extrapolation of the perturbations to the middle of the next + timestep, to predict the new disturbed position. There is no + iteration within a timestep. +

+Measures are taken to reach a compromise between execution time + and accuracy. The starting-point is the goal of achieving + arcsecond accuracy for ordinary minor planets over a ten-year + timespan. This goal dictates how large the timesteps can be, + which in turn dictates how frequently the unperturbed motion has + to be recalculated from the osculating elements. +

+Within predetermined limits, the timestep for the numerical + integration is varied in length in inverse proportion to the + magnitude of the net acceleration on the body from the major + planets. +

+The numerical integration requires estimates of the major-planet + motions. Approximate positions for the major planets (Pluto + alone is omitted) are obtained from the routine sla_PLANET. Two + levels of interpolation are used, to enhance speed without + significantly degrading accuracy. At a low frequency, the routine + sla_PLANET is called to generate updated position+velocity ``state + vectors''. The only task remaining to be carried out at the full + frequency (i.e. at each integration step) is to use the state + vectors to extrapolate the planetary positions. In place of a + strictly linear extrapolation, some allowance is made for the + curvature of the orbit by scaling back the radius vector as the + linear extrapolation goes off at a tangent. +

+Various other approximations are made. For example, perturbations + by Pluto and the minor planets are neglected, relativistic effects + are not taken into account and the Earth-Moon system is treated as + a single body. +

+In the interests of simplicity, the background calculations for + the major planets are carried out en masse. + The mean elements and + state vectors for all the planets are refreshed at the same time, + without regard for orbit curvature, mass or proximity. +

5. +
This routine is not intended to be used for major planets. + However, if major-planet elements are supplied, sensible results + will, in fact, be produced. This happens because the routine + checks the separation between the body and each of the planets and + interprets a suspiciously small value (0.001 AU) as an attempt to + apply the routine to the planet concerned. If this condition + is detected, the + contribution from that planet is ignored, and the status is set to + the planet number (Mercury=1,...,Neptune=8) as a warning. +
+

+
REFERENCES: +
+
1. +
Sterne, Theodore E., An Introduction to Celestial Mechanics, +Interscience Publishers, 1960. Section 6.7, p199. +
2. +
Everhart, E. & Pitkin, E.T., Am. J. Phys. 51, 712, 1983. +
+

+ +next + +up + +previous +
+ Next: SLA_PLANEL - Planet Position from Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PERTEL - Perturbed Orbital Elements +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node146.html b/src/slalib/sun67.htx/node146.html new file mode 100644 index 0000000..70b9139 --- /dev/null +++ b/src/slalib/sun67.htx/node146.html @@ -0,0 +1,255 @@ + + + + +SLA_PLANEL - Planet Position from Elements + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PLANET - Planetary Ephemerides +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PERTUE - Perturbed Universal Elements +

+

+

SLA_PLANEL - Planet Position from Elements +   +

+
+
ACTION: +
Heliocentric position and velocity of a planet, +asteroid or comet, starting from orbital elements. +

CALL: +
CALL sla_PLANEL ( + DATE, JFORM, EPOCH, ORBINC, ANODE, PERIH, + AORQ, E, AORL, DM, PV, JSTAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
DATEDModified Julian Date (JD-2400000.5)
JFORMIchoice of element set (1-3, see Note 3, below)
EPOCHDepoch of elements (t0 or T, TT MJD)
ORBINCDinclination (i, radians)
ANODEDlongitude of the ascending node ($\Omega$, radians)
PERIHDlongitude or argument of perihelion +($\varpi$ or $\omega$,
radians)
AORQDmean distance or perihelion distance (a or q, AU)
EDeccentricity (e)
AORLDmean anomaly or longitude +(M or L, radians,
JFORM=1,2 only)
DMDdaily motion (n, radians, JFORM=1 only)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
PVD(6)heliocentric $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$, equatorial, J2000
(AU, AU/s)
JSTATIstatus:
0 = OK
-1 = illegal JFORM
-2 = illegal E
-3 = illegal AORQ
-4 = illegal DM
-5 = numerical error
+

+
NOTES: +
+
1. +
DATE is the instant for which the prediction is +required. It is in the TT timescale (formerly +Ephemeris Time, ET) and is a + Modified Julian Date (JD-2400000.5). +
2. +
The elements are with respect to + the J2000 ecliptic and equinox. +
3. +
Three different element-format options are available, as + follows.
+

+JFORM=1, suitable for the major planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 longitude of perihelion $\varpi$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e < 1 )$ 
+		 AORL 		 = 		 mean longitude L (radians)
+		 DM 		 = 		 daily motion n (radians)        
+
+

+JFORM=2, suitable for minor planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e < 1 )$ 
+		 AORL 		 = 		 mean anomaly M (radians)        
+
+

+JFORM=3, suitable for comets: +


+ 		 EPOCH 		 = 		 epoch of perihelion T (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 perihelion distance q (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e \leq 10 )$
+
4. +
Unused elements (DM for JFORM=2, AORL and DM for JFORM=3) are + not accessed. +
5. +
The reference frame for the result is equatorial and is with + respect to the mean equinox and ecliptic of epoch J2000. +
6. +
The algorithm was originally adapted from the EPHSLA program of + D.H.P.Jones (private communication, 1996). The method + is based on Stumpff's Universal Variables. +
+

+
REFERENCE: +
Everhart, E. & Pitkin, E.T., Am. J. Phys. 51, 712, 1983. +
+

+ +next + +up + +previous +
+ Next: SLA_PLANET - Planetary Ephemerides +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PERTUE - Perturbed Universal Elements +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node147.html b/src/slalib/sun67.htx/node147.html new file mode 100644 index 0000000..b9d19fb --- /dev/null +++ b/src/slalib/sun67.htx/node147.html @@ -0,0 +1,278 @@ + + + + +SLA_PLANET - Planetary Ephemerides + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PLANTE - of Planet from Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PLANEL - Planet Position from Elements +

+

+

SLA_PLANET - Planetary Ephemerides +   +

+
+
ACTION: +
Approximate heliocentric position and velocity of a planet. +
CALL: +
CALL sla_PLANET (DATE, NP, PV, JSTAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
DATEDModified Julian Date (JD-2400000.5)
NPIplanet:
1=Mercury
2=Venus
3=Earth-Moon Barycentre
4=Mars
5=Jupiter
6=Saturn
7=Uranus
8=Neptune
9=Pluto
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
PVD(6)heliocentric $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$, equatorial, J2000
(AU, AU/s)
JSTATIstatus:
+1 = warning: date outside of range
0 = OK
-1 = illegal NP (outside 1-9)
-2 = solution didn't converge
+

+
NOTES: +
+
1. +
The epoch, DATE, is in the TDB timescale and is in the form +of a Modified Julian Date (JD-2400000.5). +
2. +
The reference frame is equatorial and is with respect to + the mean equinox and ecliptic of epoch J2000. +
3. +
If a planet number, NP, outside the range 1-9 is supplied, an error + status is returned (JSTAT = -1) and the PV vector + is set to zeroes. +
4. +
The algorithm for obtaining the mean elements of the + planets from Mercury to Neptune is due to + J.L.Simon, P.Bretagnon, J.Chapront, + M.Chapront-Touze, G.Francou and J.Laskar (Bureau des + Longitudes, Paris, France). The (completely different) + algorithm for calculating the ecliptic coordinates of + Pluto is by Meeus. +
5. +
Comparisons of the present routine with the JPL DE200 ephemeris + give the following RMS errors over the interval 1960-2025: +

+ 		 		 position (km) 		 speed (metre/sec) 
+ 
+		 Mercury 		  334 		  0.437
+		 Venus 		  1060 		  0.855
+		 EMB 		  2010 		  0.815
+		 Mars 		  7690 		  1.98
+		 Jupiter 		  71700 		  7.70
+		 Saturn 		  199000 		  19.4
+		 Uranus 		  564000 		  16.4
+		 Neptune 		  158000 		  14.4
+		 Pluto 		  36400 		  0.137        
+
+ From comparisons with DE102, Simon et al. quote the following + longitude accuracies over the interval 1800-2200: +

+ 		 Mercury 		  $4\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
+		 Venus 		  $5\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
+		 EMB 		  $6\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
+		 Mars 		 $17\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
+		 Jupiter 		 $71\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
+		 Saturn 		 $81\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
+		 Uranus 		 $86\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
+		 Neptune 		 $11\hspace{-0.05em}^{'\hspace{-0.1em}'}$
+ In the case of Pluto, Meeus quotes an accuracy of + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.6$

+in longitude and + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$ in latitude for the period + 1885-2099. +

+For all except Pluto, over the period 1000-3000, + the accuracy is better than 1.5 + times that over 1800-2200. Outside the interval 1000-3000 the + accuracy declines. For Pluto the accuracy declines rapidly + outside the period 1885-2099. Outside these ranges + (1885-2099 for Pluto, 1000-3000 for the rest) a ``date out + of range'' warning status (JSTAT=+1) is returned. +

6. +
The algorithms for (i) Mercury through Neptune and + (ii) Pluto are completely independent. In the Mercury + through Neptune case, the present SLALIB + implementation differs from the original + Simon et al. Fortran code in the following respects: +
    +
  • The date is supplied as a Modified Julian Date rather + a Julian Date (${\rm MJD} = ({\rm JD} - 2400000.5$). +
  • The result is returned only in equatorial + Cartesian form; the ecliptic + longitude, latitude and radius vector are not returned. +
  • The velocity is in AU per second, not AU per day. +
  • Different error/warning status values are used. +
  • Kepler's Equation is not solved inline. +
  • Polynomials in T are nested to minimize rounding errors. +
  • Explicit double-precision constants are used to avoid + mixed-mode expressions. +
  • There are other, cosmetic, changes to comply with + Starlink/SLALIB style guidelines. +
+ None of the above changes affects the result significantly. +
7. +
NP=3 the result is for the Earth-Moon Barycentre. To + obtain the heliocentric position and velocity of the Earth, + either use the SLALIB routine sla_EVP or call sla_DMOON and + subtract 0.012150581 times the geocentric Moon vector from + the EMB vector produced by the present routine. (The Moon + vector should be precessed to J2000 first, but this can + be omitted for modern epochs without introducing significant + inaccuracy.) +
+

+
REFERENCES: +
+
1. +
Simon et al., +Astron. Astrophys. 282, 663 (1994). +
2. +
Meeus, J., + Astronomical Algorithms, Willmann-Bell (1991). +
+

+ +next + +up + +previous +
+ Next: SLA_PLANTE - of Planet from Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PLANEL - Planet Position from Elements +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node148.html b/src/slalib/sun67.htx/node148.html new file mode 100644 index 0000000..70ca411 --- /dev/null +++ b/src/slalib/sun67.htx/node148.html @@ -0,0 +1,256 @@ + + + + +SLA_PLANTE - of Planet from Elements + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PM - Proper Motion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PLANET - Planetary Ephemerides +

+

+

    +
+SLA_PLANTE - $[\,\alpha,\delta\,]$ of Planet from Elements +

+
+
ACTION: +
Topocentric apparent $[\,\alpha,\delta\,]$ of a Solar-System object whose +heliocentric orbital elements are known. +

CALL: +
CALL sla_PLANTE ( + DATE, ELONG, PHI, JFORM, EPOCH, ORBINC, ANODE, PERIH, + AORQ, E, AORL, DM, RA, DEC, R, JSTAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
DATEDMJD of observation (JD-2400000.5)
ELONG,PHIDobserver's longitude (east +ve) and latitude
radians)
JFORMIchoice of element set (1-3, see Note 4, below)
EPOCHDepoch of elements (t0 or T, TT MJD)
ORBINCDinclination (i, radians)
ANODEDlongitude of the ascending node ($\Omega$, radians)
PERIHDlongitude or argument of perihelion +($\varpi$ or $\omega$,
radians)
AORQDmean distance or perihelion distance (a or q, AU)
EDeccentricity (e)
AORLDmean anomaly or longitude (M or L,
radians, JFORM=1,2 only)
DMDdaily motion (n, radians, JFORM=1 only)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
RA,DECDtopocentric apparent $[\,\alpha,\delta\,]$ (radians)
RDdistance from observer (AU)
JSTATIstatus:
0 = OK
-1 = illegal JFORM
-2 = illegal E
-3 = illegal AORQ
-4 = illegal DM
-5 = numerical error
+

+
NOTES: +
+
1. +
DATE is the instant for which the prediction is +required. It is in the TT timescale (formerly +Ephemeris Time, ET) and is a + Modified Julian Date (JD-2400000.5). +
2. +
The longitude and latitude allow correction for geocentric + parallax. This is usually a small effect, but can become + important for Earth-crossing asteroids. Geocentric positions + can be generated by appropriate use of the routines + sla_EVP and sla_PLANEL. +
3. +
The elements are with respect to the J2000 ecliptic and equinox. +
4. +
Three different element-format options are available, as + follows.
+

+JFORM=1, suitable for the major planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 longitude of perihelion $\varpi$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e 
+		 AORL 		 = 		 mean longitude L (radians)
+		 DM 		 = 		 daily motion n (radians)        
+
+

+JFORM=2, suitable for minor planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e 
+		 AORL 		 = 		 mean anomaly M (radians)        
+
+

+JFORM=3, suitable for comets: +


+ 		 EPOCH 		 = 		 epoch of perihelion T (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 perihelion distance q (AU)
+		 E 		 = 		 eccentricity e
+
+
5. +
Unused elements (DM for JFORM=2, AORL and DM for JFORM=3) are + not accessed. +
+

+ +next + +up + +previous +
+ Next: SLA_PM - Proper Motion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PLANET - Planetary Ephemerides +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node149.html b/src/slalib/sun67.htx/node149.html new file mode 100644 index 0000000..999078a --- /dev/null +++ b/src/slalib/sun67.htx/node149.html @@ -0,0 +1,135 @@ + + + + +SLA_PM - Proper Motion + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_POLMO - Polar Motion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PLANTE - of Planet from Elements +

+

+

SLA_PM - Proper Motion +   +

+
+
ACTION: +
Apply corrections for proper motion to a star $[\,\alpha,\delta\,]$.
CALL: +
CALL sla_PM (R0, D0, PR, PD, PX, RV, EP0, EP1, R1, D1) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
R0,D0D$[\,\alpha,\delta\,]$ at epoch EP0 (radians)
PR,PDDproper motions: rate of change of +$[\,\alpha,\delta\,]$ (radians per year)
PXDparallax (arcsec)
RVDradial velocity (km s-1, +ve if receding)
EP0Dstart epoch in years (e.g. Julian epoch)
EP1Dend epoch in years (same system as EP0)
+

+
RETURNED: +
+
+ + + + + +
R1,D1D$[\,\alpha,\delta\,]$ at epoch EP1 (radians)
+

+
NOTE: +
The $\alpha$ proper motions are $\dot{\alpha}$ rather than +$\dot{\alpha}\cos\delta$, and are in the same coordinate + system as R0,D0. +
+

+
REFERENCES: +
+
1. +
1984 Astronomical Almanac, pp B39-B41. +
2. +
Lederle & Schwan, 1984. Astr. Astrophys. 134, 1-6. +
+

+ +next + +up + +previous +
+ Next: SLA_POLMO - Polar Motion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PLANTE - of Planet from Elements +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node15.html b/src/slalib/sun67.htx/node15.html new file mode 100644 index 0000000..45c1aeb --- /dev/null +++ b/src/slalib/sun67.htx/node15.html @@ -0,0 +1,230 @@ + + + + +SLA_AFIN - Sexagesimal character string to angle + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_AIRMAS - Air Mass +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ADDET - Add E-terms of Aberration +

+

+

SLA_AFIN - Sexagesimal character string to angle +   +

+
+
ACTION: +
Decode a free-format sexagesimal string (degrees, arcminutes, +arcseconds) into a single precision floating point + number (radians). +

CALL: +
CALL sla_AFIN (STRING, NSTRT, RESLT, JF) +

+

+
GIVEN: +
+
+ + + + + + + + + +
STRINGC*(*)string containing deg, arcmin, arcsec fields
NSTRTIpointer to start of decode (beginning of STRING = 1)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NSTRTIadvanced past the decoded angle
RESLTRangle in radians
JFIstatus:
0 = OK
+1 = default, RESLT unchanged (note 2)
-1 = bad degrees (note 3)
-2 = bad arcminutes (note 3)
-3 = bad arcseconds (note 3)
+

+
EXAMPLE: +
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
argumentbeforeafter
   
STRING'-57 17 44.806 12 34 56.7'unchanged
NSTRT116 (i.e. pointing to 12...)
RESLT--1.00000
JF- 
+
A further call to sla_AFIN, without adjustment of NSTRT, will + decode the second angle, $12^{\circ}\,34^{'}\,56^{''}.7$.
+

+
NOTES: +
+
1. +
The first three ``fields'' in STRING are degrees, arcminutes, +arcseconds, separated by spaces or commas. The degrees field +may be signed, but not the others. The decoding is carried + out by the sla_DFLTIN routine and is free-format. +
2. +
Successive fields may be absent, defaulting to zero. For + zero status, the only combinations allowed are degrees alone, + degrees and arcminutes, and all three fields present. If all + three fields are omitted, a status of +1 is returned and RESLT is + unchanged. In all other cases RESLT is changed. +
3. +
Range checking: +
    +
  • The degrees field is not range checked. However, it is + expected to be integral unless the other two fields are absent. +
  • The arcminutes field is expected to be 0-59, and integral if + the arcseconds field is present. If the arcseconds field + is absent, the arcminutes is expected to be 0-59.9999... +
  • The arcseconds field is expected to be 0-59.9999... +
  • Decoding continues even when a check has failed. Under these + circumstances the field takes the supplied value, defaulting to + zero, and the result RESLT is computed and returned. +
+
4. +
Further fields after the three expected ones are not treated as + an error. The pointer NSTRT is left in the correct state for + further decoding with the present routine or with sla_DFLTIN + etc. See the example, above. +
5. +
If STRING contains hours, minutes, seconds instead of + degrees etc, + or if the required units are turns (or days) instead of radians, + the result RESLT should be multiplied as follows:
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
for STRINGto obtainmultiply RESLT by
   
${\circ}$  '  ''radians1.0
${\circ}$  '  ''turns$1/{2 \pi} = 0.1591549430918953358$
h m sradians15.0
h m sdays$15/{2\pi} = 2.3873241463784300365$
+

+ +next + +up + +previous +
+ Next: SLA_AIRMAS - Air Mass +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ADDET - Add E-terms of Aberration +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node150.html b/src/slalib/sun67.htx/node150.html new file mode 100644 index 0000000..4750c08 --- /dev/null +++ b/src/slalib/sun67.htx/node150.html @@ -0,0 +1,202 @@ + + + + +SLA_POLMO - Polar Motion + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PREBN - Precession Matrix (FK4) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PM - Proper Motion +

+

+

SLA_POLMO - Polar Motion +   +

+
+
ACTION: +
Polar motion: correct site longitude and latitude for polar +motion and calculate azimuth difference between celestial and + terrestrial poles. +

CALL: +
CALL sla_POLMO (ELONGM, PHIM, XP, YP, ELONG, PHI, DAZ) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
ELONGMDmean longitude of the site (radians, east +ve)
PHIMDmean geodetic latitude of the site (radians)
XPDpolar motion x-coordinate (radians)
YPDpolar motion y-coordinate (radians)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + +
ELONGDtrue longitude of the site (radians, east +ve)
PHIDtrue geodetic latitude of the site (radians)
DAZDazimuth correction (terrestrial-celestial, radians)
+

+
NOTES: +
+
1. +
``Mean'' longitude and latitude are the (fixed) values for the +site's location with respect to the IERS terrestrial reference +frame; the latitude is geodetic. TAKE CARE WITH THE LONGITUDE + SIGN CONVENTION. The longitudes used by the present routine + are east-positive, in accordance with geographical convention + (and right-handed). In particular, note that the longitudes + returned by the sla_OBS routine are west-positive, following + astronomical usage, and must be reversed in sign before use in + the present routine. +
2. +
XP and YP are the (changing) coordinates of the Celestial + Ephemeris Pole with respect to the IERS Reference Pole. + XP is positive along the meridian at longitude $0^{\circ}$, and YP is positive along the meridian at longitude + $270^\circ$ (i.e. $90^{\circ}$ west). Values for XP,YP can + be obtained from IERS circulars and equivalent publications; + the maximum amplitude observed so far is about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$ . +
3. +
``True'' longitude and latitude are the (moving) values for + the site's location with respect to the celestial ephemeris + pole and the meridian which corresponds to the Greenwich + apparent sidereal time. The true longitude and latitude + link the terrestrial coordinates with the standard celestial + models (for precession, nutation, sidereal time etc). +
4. +
The azimuths produced by sla_AOP and sla_AOPQK are with + respect to due north as defined by the Celestial Ephemeris + Pole, and can therefore be called ``celestial azimuths''. + However, a telescope fixed to the Earth measures azimuth + essentially with respect to due north as defined by the + IERS Reference Pole, and can therefore be called ``terrestrial + azimuth''. Uncorrected, this would manifest itself as a + changing ``azimuth zero-point error''. The value DAZ is the + correction to be added to a celestial azimuth to produce + a terrestrial azimuth. +
5. +
The present routine is rigorous. For most practical + purposes, the following simplified formulae provide an + adequate approximation:
+
+
+ + + + + + + + + + + + + +
ELONG=ELONGM+XP*COS(ELONGM)-YP*SIN(ELONGM)
PHI =PHIM+(XP*SIN(ELONGM)+YP*COS(ELONGM))*TAN(PHIM)
DAZ =-SQRT(XP*XP+YP*YP)*COS(ELONGM-ATAN2(XP,YP))/COS(PHIM)

+
+
+An alternative formulation for DAZ is: +
+
+
+ + + + + + + + + + + + + +
X =COS(ELONGM)*COS(PHIM)
Y =SIN(ELONGM)*COS(PHIM)
DAZ=ATAN2(-X*YP-Y*XP,X*X+Y*Y)
+

+
REFERENCE: +
Seidelmann, P.K. (ed), 1992. Explanatory +Supplement to the Astronomical Almanac, ISBN 0-935702-68-7, + sections 3.27, 4.25, 4.52. +
+

+ +next + +up + +previous +
+ Next: SLA_PREBN - Precession Matrix (FK4) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PM - Proper Motion +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node151.html b/src/slalib/sun67.htx/node151.html new file mode 100644 index 0000000..f7c9a66 --- /dev/null +++ b/src/slalib/sun67.htx/node151.html @@ -0,0 +1,111 @@ + + + + +SLA_PREBN - Precession Matrix (FK4) + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PREC - Precession Matrix (FK5) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_POLMO - Polar Motion +

+

+

SLA_PREBN - Precession Matrix (FK4) +   +

+
+
ACTION: +
Generate the matrix of precession between two epochs, +using the old, pre IAU 1976, Bessel-Newcomb model, in + Andoyer's formulation. +

CALL: +
CALL sla_PREBN (BEP0, BEP1, RMATP) +

+

+
GIVEN: +
+
+ + + + + + + + + +
BEP0Dbeginning Besselian epoch
BEP1Dending Besselian epoch
+

+
RETURNED: +
+
+ + + + + +
RMATPD(3,3)precession matrix
+

+
NOTE: +
The matrix is in the sense: +
v1 = M$\cdot$v0
+ where v1 is the star vector relative to the + mean equator and equinox of epoch BEP1, M is the + $3\times3$ matrix RMATP and + v0 is the star vector relative to the + mean equator and equinox of epoch BEP0. +
+

+
REFERENCE: +
Smith et al., 1989. Astr.J. 97, 269. +
+

+ +next + +up + +previous +
+ Next: SLA_PREC - Precession Matrix (FK5) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_POLMO - Polar Motion +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node152.html b/src/slalib/sun67.htx/node152.html new file mode 100644 index 0000000..9e5ea39 --- /dev/null +++ b/src/slalib/sun67.htx/node152.html @@ -0,0 +1,145 @@ + + + + +SLA_PREC - Precession Matrix (FK5) + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PRECES - Precession +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PREBN - Precession Matrix (FK4) +

+

+

SLA_PREC - Precession Matrix (FK5) +   +

+
+
ACTION: +
Form the matrix of precession between two epochs (IAU 1976, FK5). +
CALL: +
CALL sla_PREC (EP0, EP1, RMATP) +

+

+
GIVEN: +
+
+ + + + + + + + + +
EP0Dbeginning epoch
EP1Dending epoch
+

+
RETURNED: +
+
+ + + + + +
RMATPD(3,3)precession matrix
+

+
NOTES: +
+
1. +
The epochs are TDB Julian epochs. +
2. +
The matrix is in the sense: +
v1 = M$\cdot$v0
+ where v1 is the star vector relative to the + mean equator and equinox of epoch EP1, M is the + $3\times3$ matrix RMATP and + v0 is the star vector relative to the + mean equator and equinox of epoch EP0. +
3. +
Though the matrix method itself is rigorous, the precession + angles are expressed through canonical polynomials which are + valid only for a limited time span. There are also known + errors in the IAU precession rate. The absolute accuracy + of the present formulation is better than + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$ from + 1960AD to 2040AD, better than $1\hspace{-0.05em}^{'\hspace{-0.1em}'}$ from 1640AD to 2360AD, + and remains below $3\hspace{-0.05em}^{'\hspace{-0.1em}'}$ for the whole of the period + 500BC to 3000AD. The errors exceed $10\hspace{-0.05em}^{'\hspace{-0.1em}'}$ outside the + range 1200BC to 3900AD, exceed $100\hspace{-0.05em}^{'\hspace{-0.1em}'}$ outside 4200BC to + 5600AD and exceed $1000\hspace{-0.05em}^{'\hspace{-0.1em}'}$ outside 6800BC to 8200AD. + The SLALIB routine sla_PRECL implements a more elaborate + model which is suitable for problems spanning several + thousand years. +
+

+
REFERENCES: +
+
1. +
Lieske, J.H., 1979. Astr.Astrophys. 73, 282; +equations 6 & 7, p283. +
2. +
Kaplan, G.H., 1981. USNO circular no. 163, pA2. +
+

+ +next + +up + +previous +
+ Next: SLA_PRECES - Precession +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PREBN - Precession Matrix (FK4) +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node153.html b/src/slalib/sun67.htx/node153.html new file mode 100644 index 0000000..e63959a --- /dev/null +++ b/src/slalib/sun67.htx/node153.html @@ -0,0 +1,120 @@ + + + + +SLA_PRECES - Precession + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PRECL - Precession Matrix (latest) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PREC - Precession Matrix (FK5) +

+

+

SLA_PRECES - Precession +   +

+
+
ACTION: +
Precession - either the old ``FK4'' (Bessel-Newcomb, pre IAU 1976) +or new ``FK5'' (Fricke, post IAU 1976) as required. +

CALL: +
CALL sla_PRECES (SYSTEM, EP0, EP1, RA, DC) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
SYSTEMCprecession to be applied: `FK4' or `FK5'
EP0,EP1Dstarting and ending epoch
RA,DCD$[\,\alpha,\delta\,]$, mean equator & equinox of epoch EP0
+

+
RETURNED: +
+
+ + + + + +
RA,DCD$[\,\alpha,\delta\,]$, mean equator & equinox of epoch EP1
+

+
NOTES: +
+
1. +
Lowercase characters in SYSTEM are acceptable. +
2. +
The epochs are Besselian if SYSTEM=`FK4' and Julian if `FK5'. +For example, to precess coordinates in the old system from + equinox 1900.0 to 1950.0 the call would be: +
CALL sla_PRECES ('FK4', 1900D0, 1950D0, RA, DC) +
+
3. +
This routine will NOT correctly convert between the old and + the new systems - for example conversion from B1950 to J2000. + For these purposes see sla_FK425, sla_FK524, sla_FK45Z and + sla_FK54Z. +
4. +
If an invalid SYSTEM is supplied, values of -99D0,-99D0 are + returned for both RA and DC. +
+

+ +next + +up + +previous +
+ Next: SLA_PRECL - Precession Matrix (latest) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PREC - Precession Matrix (FK5) +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node154.html b/src/slalib/sun67.htx/node154.html new file mode 100644 index 0000000..a20e26a --- /dev/null +++ b/src/slalib/sun67.htx/node154.html @@ -0,0 +1,131 @@ + + + + +SLA_PRECL - Precession Matrix (latest) + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PRENUT - Precession/Nutation Matrix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PRECES - Precession +

+

+

SLA_PRECL - Precession Matrix (latest) +   +

+
+
ACTION: +
Form the matrix of precession between two epochs, using the +model of Simon et al. (1994), which is suitable for long + periods of time. +

CALL: +
CALL sla_PRECL (EP0, EP1, RMATP) +

+

+
GIVEN: +
+
+ + + + + + + + + +
EP0Dbeginning epoch
EP1Dending epoch
+

+
RETURNED: +
+
+ + + + + +
RMATPD(3,3)precession matrix
+

+
NOTES: +
+
1. +
The epochs are TDB Julian epochs. +
2. +
The matrix is in the sense: +
v1 = M$\cdot$v0
+ where v1 is the star vector relative to the + mean equator and equinox of epoch EP1, M is the + $3\times3$ matrix RMATP and + v0 is the star vector relative to the + mean equator and equinox of epoch EP0. +
3. +
The absolute accuracy of the model is limited by the + uncertainty in the general precession, about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$ per + 1000 years. The remainder of the formulation provides a + precision of 1 milliarcsecond over the interval from 1000AD + to 3000AD, + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$ from 1000BC to 5000AD and + $1\hspace{-0.05em}^{'\hspace{-0.1em}'}$ from 4000BC to 8000AD. +
+

+
REFERENCE: +
Simon, J.L. et al., 1994. Astr.Astrophys. 282, +663. +
+

+ +next + +up + +previous +
+ Next: SLA_PRENUT - Precession/Nutation Matrix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PRECES - Precession +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node155.html b/src/slalib/sun67.htx/node155.html new file mode 100644 index 0000000..e7dc899 --- /dev/null +++ b/src/slalib/sun67.htx/node155.html @@ -0,0 +1,110 @@ + + + + +SLA_PRENUT - Precession/Nutation Matrix + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PV2EL - Orbital Elements from Position/Velocity +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PRECL - Precession Matrix (latest) +

+

+

SLA_PRENUT - Precession/Nutation Matrix +   +

+
+
ACTION: +
Form the matrix of precession and nutation (IAU 1976, FK5). +
CALL: +
CALL sla_PRENUT (EPOCH, DATE, RMATPN) +

+

+
GIVEN: +
+
+ + + + + + + + + +
EPOCHDJulian Epoch for mean coordinates
DATEDModified Julian Date (JD-2400000.5) +for true coordinates
+

+
RETURNED: +
+
+ + + + + +
RMATPND(3,3)combined precession/nutation matrix
+

+
NOTES: +
+
1. +
The epoch and date are TDB. +
2. +
The matrix is in the sense: +
vtrue = M$\cdot$vmean
+ where vtrue is the star vector relative to the + true equator and equinox of epoch DATE, M is the + $3\times3$ matrix RMATPN and + vmean is the star vector relative to the + mean equator and equinox of epoch EPOCH. +
+

+ +next + +up + +previous +
+ Next: SLA_PV2EL - Orbital Elements from Position/Velocity +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PRECL - Precession Matrix (latest) +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node156.html b/src/slalib/sun67.htx/node156.html new file mode 100644 index 0000000..ab897bc --- /dev/null +++ b/src/slalib/sun67.htx/node156.html @@ -0,0 +1,323 @@ + + + + +SLA_PV2EL - Orbital Elements from Position/Velocity + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PV2UE - Position/Velocity to Universal Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PRENUT - Precession/Nutation Matrix +

+

+

SLA_PV2EL - Orbital Elements from Position/Velocity +   +

+
+
ACTION: +
Heliocentric osculating elements obtained from instantaneous +position and velocity. +

CALL: +
CALL sla_PV2EL ( + PV, DATE, PMASS, JFORMR, JFORM, EPOCH, ORBINC, + ANODE, PERIH, AORQ, E, AORL, DM, JSTAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + +
PVD(6)heliocentric $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$, equatorial, J2000
(AU, AU/s; Note 1)
DATEDdate (TT Modified Julian Date = JD-2400000.5)
PMASSDmass of the planet (Sun = 1; Note 2)
JFORMRIrequested element set (1-3; Note 3)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
JFORMIelement set actually returned (1-3; Note 4)
EPOCHDepoch of elements (t0 or T, TT MJD)
ORBINCDinclination (i, radians)
ANODEDlongitude of the ascending node ($\Omega$, radians)
PERIHDlongitude or argument of perihelion +($\varpi$ or $\omega$,
radians)
AORQDmean distance or perihelion distance (a or q, AU)
EDeccentricity (e)
AORLDmean anomaly or longitude +(M or L, radians,
JFORM=1,2 only)
DMDdaily motion (n, radians, JFORM=1 only)
JSTATIstatus:
0 = OK
-1 = illegal PMASS
-2 = illegal JFORMR
-3 = position/velocity out of allowed range
+

+
NOTES: +
+
1. +
The PV 6-vector is with respect to the mean equator and equinox of +epoch J2000. The orbital elements produced are with respect to +the J2000 ecliptic and mean equinox. +
2. +
The mass, PMASS, is important only for the larger planets. For + most purposes (e.g. asteroids) use 0D0. Values less than zero + are illegal. +
3. +
Three different element-format options are supported, as + follows.
+

+JFORM=1, suitable for the major planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 longitude of perihelion $\varpi$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e < 1 )$ 
+		 AORL 		 = 		 mean longitude L (radians)
+		 DM 		 = 		 daily motion n (radians)        
+
+

+JFORM=2, suitable for minor planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e < 1 )$ 
+		 AORL 		 = 		 mean anomaly M (radians)        
+
+

+JFORM=3, suitable for comets: +


+ 		 EPOCH 		 = 		 epoch of perihelion T (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 perihelion distance q (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e \leq 10 )$
+
4. +
It may not be possible to generate elements in the form + requested through JFORMR. The caller is notified of the form + of elements actually returned by means of the JFORM argument: +


+ 		 JFORMR 		 JFORM 		 meaning 
+ 
+		      1 		      1 		 OK: elements are in the requested format
+		      1 		      2 		 never happens
+		      1 		      3 		 orbit not elliptical
+		      2 		      1 		 never happens
+		      2 		      2 		 OK: elements are in the requested format
+		      2 		      3 		 orbit not elliptical
+		      3 		      1 		 never happens
+		      3 		      2 		 never happens
+		      3 		      3 		 OK: elements are in the requested format        
+
+
5. +
The arguments returned for each value of JFORM (cf Note 5: + JFORM may not be the same as JFORMR) are as follows: +


+ 		 JFORM 		 1 		 2 		 3 
+ 
+		 EPOCH 		 t0 t0 T 
+		 ORBINC 		 i i i 
+		 ANODE 		 $\Omega$ $\Omega$ $\Omega$ 
+		 PERIH 		 $\varpi$ $\omega$ $\omega$ 
+		 AORQ 		 a a q 
+		 E 		 e e e 
+		 AORL 		 L M -
+		 DM 		 n - 		 -        
+
+

+where: +


+ 		 t0 is the epoch of the elements (MJD, TT)
+		 T is the epoch of perihelion (MJD, TT)
+		 i is the inclination (radians)
+		 $\Omega$ is the longitude of the ascending node (radians)
+		 $\varpi$ is the longitude of perihelion (radians)
+		 $\omega$ is the argument of perihelion (radians)
+		 a is the mean distance (AU)
+		 q is the perihelion distance (AU)
+		 e is the eccentricity
+		 L is the longitude (radians, $0-2\pi$)		 M is the mean anomaly (radians, $0-2\pi$)		 n is the daily motion (radians)
+		 - 		 means no value is set        
+
+
6. +
At very small inclinations, the longitude of the ascending node + ANODE becomes indeterminate and under some circumstances may be + set arbitrarily to zero. Similarly, if the orbit is close to + circular, the true anomaly becomes indeterminate and under some + circumstances may be set arbitrarily to zero. In such cases, + the other elements are automatically adjusted to compensate, + and so the elements remain a valid description of the orbit. +
+

+
REFERENCE: +
Sterne, Theodore E., An Introduction to Celestial Mechanics, +Interscience Publishers, 1960. +
+

+ +next + +up + +previous +
+ Next: SLA_PV2UE - Position/Velocity to Universal Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PRENUT - Precession/Nutation Matrix +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node157.html b/src/slalib/sun67.htx/node157.html new file mode 100644 index 0000000..08c25e9 --- /dev/null +++ b/src/slalib/sun67.htx/node157.html @@ -0,0 +1,203 @@ + + + + +SLA_PV2UE - Position/Velocity to Universal Elements + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PVOBS - Observatory Position & Velocity +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PV2EL - Orbital Elements from Position/Velocity +

+

+

SLA_PV2UE - Position/Velocity to Universal Elements +   +

+
+
ACTION: +
Construct a universal element set based on an instantaneous +position and velocity. +

CALL: +
CALL sla_PV2UE (PV, DATE, PMASS, U, JSTAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
PVD(6)heliocentric $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$, equatorial, J2000
(AU, AU/s; Note 1)
DATEDdate (TT Modified Julian Date = JD-2400000.5)
PMASSDmass of the planet (Sun = 1; Note 2)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
UD(13)universal orbital elements (Note 3)
(1)combined mass (M+m)
(2)total energy of the orbit ($\alpha$)
(3)reference (osculating) epoch (t0)
(4-6)position at reference epoch (${\rm \bf r}_0$)
(7-9)velocity at reference epoch (${\rm \bf v}_0$)
(10)heliocentric distance at reference epoch
(11)${\rm \bf r}_0.{\rm \bf v}_0$
(12)date (t)
(13)universal eccentric anomaly ($\psi$) of date, approx
JSTATIstatus:
0 = OK
-1 = illegal PMASS
-2 = too close to Sun
-3 = too slow
+

+
NOTES: +
+
1. +
The PV 6-vector can be with respect to any chosen inertial frame, +and the resulting universal-element set will be with respect to +the same frame. A common choice will be mean equator and ecliptic + of epoch J2000. +
2. +
The mass, PMASS, is important only for the larger planets. For + most purposes (e.g. asteroids) use 0D0. Values less than zero + are illegal. +
3. +
The ``universal'' elements are those which define the orbit for the + purposes of the method of universal variables (see reference). + They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i) $\alpha$, which is proportional to the total energy of the + orbit, (ii) the heliocentric distance at epoch, + (iii) the outwards component of the velocity at the given epoch, + (iv) an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v) that date. +
+

+
REFERENCE: +
Everhart, E. & Pitkin, E.T., Am. J. Phys. 51, 712, 1983. +
+

+ +next + +up + +previous +
+ Next: SLA_PVOBS - Observatory Position & Velocity +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PV2EL - Orbital Elements from Position/Velocity +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node158.html b/src/slalib/sun67.htx/node158.html new file mode 100644 index 0000000..02b37a3 --- /dev/null +++ b/src/slalib/sun67.htx/node158.html @@ -0,0 +1,102 @@ + + + + +SLA_PVOBS - Observatory Position & Velocity + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_PXY - Apply Linear Model +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PV2UE - Position/Velocity to Universal Elements +

+

+

SLA_PVOBS - Observatory Position & Velocity +   +

+
+
ACTION: +
Position and velocity of an observing station. +
CALL: +
CALL sla_PVOBS (P, H, STL, PV) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
PDlatitude (geodetic, radians)
HDheight above reference spheroid (geodetic, metres)
STLDlocal apparent sidereal time (radians)
+

+
RETURNED: +
+
+ + + + + +
PVD(6)$[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ (AU, AU s-1, true equator and equinox +of date)
+

+
NOTE: +
IAU 1976 constants are used. +
+

+ +next + +up + +previous +
+ Next: SLA_PXY - Apply Linear Model +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PV2UE - Position/Velocity to Universal Elements +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node159.html b/src/slalib/sun67.htx/node159.html new file mode 100644 index 0000000..6cf76da --- /dev/null +++ b/src/slalib/sun67.htx/node159.html @@ -0,0 +1,145 @@ + + + + +SLA_PXY - Apply Linear Model + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RANDOM - Random Number +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PVOBS - Observatory Position & Velocity +

+

+

SLA_PXY - Apply Linear Model +   +

+
+
ACTION: +
Given arrays of expected and measured +$[\,x,y\,]$ coordinates, and a + linear model relating them (as produced by sla_FITXY), compute + the array of predicted coordinates and the RMS residuals. +

CALL: +
CALL sla_PXY (NP,XYE,XYM,COEFFS,XYP,XRMS,YRMS,RRMS) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
NPInumber of samples
XYED(2,NP)expected $[\,x,y\,]$ for each sample
XYMD(2,NP)measured $[\,x,y\,]$ for each sample
COEFFSD(6)coefficients of model (see below)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
XYPD(2,NP)predicted $[\,x,y\,]$ for each sample
XRMSDRMS in X
YRMSDRMS in Y
RRMSD total RMS (vector sum of XRMS and YRMS)
+

+
NOTES: +
+
1. +
The model is supplied in the array COEFFS. Naming the +six elements of COEFFS a,b,c,d,e & f, +the model transforms measured coordinates + $[x_{m},y_{m}\,]$ into predicted coordinates + $[x_{p},y_{p}\,]$ as follows: +
xp = a + bxm + cym
+ yp = d + exm + fym
+
2. +
The residuals are (xp-xe) and (yp-ye). +
3. +
If NP is less than or equal to zero, no coordinates are + transformed, and the RMS residuals are all zero. +
4. +
See also sla_FITXY, sla_INVF, sla_XY2XY, sla_DCMPF +
+

+ +next + +up + +previous +
+ Next: SLA_RANDOM - Random Number +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PVOBS - Observatory Position & Velocity +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node16.html b/src/slalib/sun67.htx/node16.html new file mode 100644 index 0000000..682e1dd --- /dev/null +++ b/src/slalib/sun67.htx/node16.html @@ -0,0 +1,121 @@ + + + + +SLA_AIRMAS - Air Mass + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_ALTAZ - Velocities etc. for Altazimuth Mount +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AFIN - Sexagesimal character string to angle +

+

+

SLA_AIRMAS - Air Mass +   +

+
+
ACTION: +
Air mass at given zenith distance (double precision). +
CALL: +
D = sla_AIRMAS (ZD) +

+

+
GIVEN: +
+
+ + + + + +
ZDDobserved zenith distance (radians)
+

+
RETURNED: +
+
+ + + + + +
sla_AIRMASDair mass (1 at zenith)
+

+
NOTES: +
+
1. +
The observed zenith distance referred to above means +``as affected by refraction''. +
2. +
The routine uses Hardie's (1962) polynomial fit to Bemporad's + data for the relative air mass, X, in units of thickness at the + zenith as tabulated by Schoenberg (1929). This is adequate for all + normal needs as it is accurate to better than + 0.1% up to X = 6.8 and better than 1% up to X = 10. + Bemporad's tabulated values are unlikely to be trustworthy + to such accuracy + because of variations in density, pressure and other + conditions in the atmosphere from those assumed in his work. +
3. +
The sign of the ZD is ignored. +
4. +
At zenith distances greater than about $\zeta = 87^{\circ}$ the + air mass is held constant to avoid arithmetic overflows. +
+

+
REFERENCES: +
+
1. +
Hardie, R.H., 1962, in Astronomical Techniques +ed. W.A. Hiltner, University of Chicago Press, p180. +
2. +
Schoenberg, E., 1929, Hdb. d. Ap., + Berlin, Julius Springer, 2, 268. +
+

+ +next + +up + +previous +
+ Next: SLA_ALTAZ - Velocities etc. for Altazimuth Mount +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AFIN - Sexagesimal character string to angle +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node160.html b/src/slalib/sun67.htx/node160.html new file mode 100644 index 0000000..972237c --- /dev/null +++ b/src/slalib/sun67.htx/node160.html @@ -0,0 +1,98 @@ + + + + +SLA_RANDOM - Random Number + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RANGE - Put Angle into Range +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PXY - Apply Linear Model +

+

+

SLA_RANDOM - Random Number +   +

+
+
ACTION: +
Generate pseudo-random real number in the range $0 \leq x < 1$.
CALL: +
R = sla_RANDOM (SEED) +

+

+
GIVEN: +
+
+ + + + + +
SEEDRan arbitrary real number
+

+
RETURNED: +
+
+ + + + + + + + + +
SEEDRa new arbitrary value
sla_RANDOMRPseudo-random real number $0 \leq x < 1$.
+

+
NOTE: +
The implementation is machine-dependent. +
+

+ +next + +up + +previous +
+ Next: SLA_RANGE - Put Angle into Range +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_PXY - Apply Linear Model +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node161.html b/src/slalib/sun67.htx/node161.html new file mode 100644 index 0000000..b8c2cb4 --- /dev/null +++ b/src/slalib/sun67.htx/node161.html @@ -0,0 +1,93 @@ + + + + +SLA_RANGE - Put Angle into Range + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RANORM - Put Angle into Range +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RANDOM - Random Number +

+

+

    +
+SLA_RANGE - Put Angle into Range $\pm \pi$

+
+
ACTION: +
Normalize an angle into the range $\pm \pi$ (single precision). +
CALL: +
R = sla_RANGE (ANGLE) +

+

+
GIVEN: +
+
+ + + + + +
ANGLERangle in radians
+

+
RETURNED: +
+
+ + + + + +
sla_RANGERANGLE expressed in the range $\pm \pi$.
+

+ +next + +up + +previous +
+ Next: SLA_RANORM - Put Angle into Range +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RANDOM - Random Number +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node162.html b/src/slalib/sun67.htx/node162.html new file mode 100644 index 0000000..3317041 --- /dev/null +++ b/src/slalib/sun67.htx/node162.html @@ -0,0 +1,93 @@ + + + + +SLA_RANORM - Put Angle into Range + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RCC - Barycentric Coordinate Time +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RANGE - Put Angle into Range +

+

+

    +
+SLA_RANORM - Put Angle into Range $0\!-\!2\pi$

+
+
ACTION: +
Normalize an angle into the range $0\!-\!2\pi$ (single precision). +
CALL: +
R = sla_RANORM (ANGLE) +

+

+
GIVEN: +
+
+ + + + + +
ANGLERangle in radians
+

+
RETURNED: +
+
+ + + + + +
sla_RANORMRANGLE expressed in the range $0\!-\!2\pi$
+

+ +next + +up + +previous +
+ Next: SLA_RCC - Barycentric Coordinate Time +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RANGE - Put Angle into Range +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node163.html b/src/slalib/sun67.htx/node163.html new file mode 100644 index 0000000..4f6cf04 --- /dev/null +++ b/src/slalib/sun67.htx/node163.html @@ -0,0 +1,166 @@ + + + + +SLA_RCC - Barycentric Coordinate Time + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RDPLAN - Apparent of Planet +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RANORM - Put Angle into Range +

+

+

SLA_RCC - Barycentric Coordinate Time +   +

+
+
CALL: +
D = sla_RCC (TDB, UT1, WL, U, V) +
ACTION: +
The relativistic clock correction TDB-TT, the + difference between proper time + on Earth and coordinate time in the solar system barycentric + space-time frame of reference. The proper time is TT; the + coordinate time is an implementation of TDB. +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + +
TDBDcoordinate time (MJD: JD-2400000.5)
UT1Duniversal time (fraction of one day)
WLDclock longitude (radians west)
UDclock distance from Earth spin axis (km)
VDclock distance north of Earth equatorial plane (km)
+

+
RETURNED: +
+
+ + + + + +
sla_RCCDTDB-TT (sec)
+

+
NOTES: +
+
1. +
TDB may be considered to +be the coordinate time in the solar system barycentre frame of +reference, and TT is the proper time given by clocks at mean sea + level on the Earth. +
2. +
The result has a main (annual) sinusoidal term of amplitude + approximately 1.66ms, plus planetary terms up to about + 20$\mu$s, and lunar and diurnal terms up to 2$\mu$s. The + variation arises from the transverse Doppler effect and the + gravitational red-shift as the observer varies in speed and + moves through different gravitational potentials. +
3. +
The argument TDB is, strictly, the barycentric coordinate time; + however, the terrestrial proper time (TT) can in practice be used. +
4. +
The geocentric model is that of Fairhead & Bretagnon (1990), + in its full + form. It was supplied by Fairhead (private communication) + as a Fortran subroutine. A number of coding changes were made to + this subroutine in order + match the calling sequence of previous versions of the present + routine, to comply with Starlink programming standards and to + avoid compilation problems on certain machines. On the supported + computer types, + the numerical results are essentially unaffected by the + changes. The topocentric model is from Moyer (1981) and Murray (1983). + During the interval 1950-2050, the absolute accuracy of the + geocentric model is better than $\pm3$ nanoseconds + relative to direct numerical integrations using the JPL DE200/LE200 + solar system ephemeris. +
5. +
The IAU definition of TDB is that it must differ from TT only by + periodic terms. Though practical, this is an imprecise definition + which ignores the existence of very long-period and secular effects + in the dynamics of the solar system. As a consequence, different + implementations of TDB will, in general, differ in zero-point and + will drift linearly relative to one other. +
+

+
REFERENCES: +
+
1. +
Fairhead, L. & +Bretagnon, P., 1990. Astr.Astrophys. 229, 240-247. +
2. +
Moyer, T.D., 1981. Cel.Mech. 23, 33. +
3. +
Murray, C.A., 1983, Vectorial Astrometry, Adam Hilger. +
+

+ +next + +up + +previous +
+ Next: SLA_RDPLAN - Apparent of Planet +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RANORM - Put Angle into Range +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node164.html b/src/slalib/sun67.htx/node164.html new file mode 100644 index 0000000..d45ee2f --- /dev/null +++ b/src/slalib/sun67.htx/node164.html @@ -0,0 +1,184 @@ + + + + +SLA_RDPLAN - Apparent of Planet + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_REFCO - Refraction Constants +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RCC - Barycentric Coordinate Time +

+

+

    +
+SLA_RDPLAN - Apparent $[\,\alpha,\delta\,]$ of Planet +

+
+
ACTION: +
Approximate topocentric apparent $[\,\alpha,\delta\,]$ and angular +size of a planet. +

CALL: +
CALL sla_RDPLAN (DATE, NP, ELONG, PHI, RA, DEC, DIAM) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
DATEDMJD of observation (JD-2400000.5)
NPIplanet:
1=Mercury
2=Venus
3=Moon
4=Mars
5=Jupiter
6=Saturn
7=Uranus
8=Neptune
9=Pluto
else=Sun
ELONG,PHIDobserver's longitude (east +ve) and latitude +(radians)
+

+
RETURNED: +
+
+ + + + + + + + + +
RA,DECDtopocentric apparent $[\,\alpha,\delta\,]$ (radians)
DIAMDangular diameter (equatorial, radians)
+

+
NOTES: +
+
1. +
The date is in a dynamical timescale (TDB, formerly ET) +and is in the form of a Modified +Julian Date (JD-2400000.5). For all practical purposes, TT can + be used instead of TDB, and for many applications UT will do + (except for the Moon). +
2. +
The longitude and latitude allow correction for geocentric + parallax. This is a major effect for the Moon, but in the + context of the limited accuracy of the present routine its + effect on planetary positions is small (negligible for the + outer planets). Geocentric positions can be generated by + appropriate use of the routines sla_DMOON and sla_PLANET. +
3. +
The direction accuracy (arcsec, 1000-3000AD) is of order: +

+ 		 Sun 		   5
+		 Mercury 		   2
+		 Venus 		 10
+		 Moon 		 30
+		 Mars 		 50
+		 Jupiter 		 90
+		 Saturn 		 90
+		 Uranus 		 90
+		 Neptune 		 10
+		 Pluto 		  1   (1885-2099AD only)        
+
+ The angular diameter accuracy is about 0.4% for the Moon, + and 0.01% or better for the Sun and planets. + For more information on accuracy, + refer to the routines sla_PLANET and sla_DMOON, + which the present routine uses. +
+

+ +next + +up + +previous +
+ Next: SLA_REFCO - Refraction Constants +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RCC - Barycentric Coordinate Time +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node165.html b/src/slalib/sun67.htx/node165.html new file mode 100644 index 0000000..1fadca0 --- /dev/null +++ b/src/slalib/sun67.htx/node165.html @@ -0,0 +1,176 @@ + + + + +SLA_REFCO - Refraction Constants + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_REFCOQ - Refraction Constants (fast) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RDPLAN - Apparent of Planet +

+

+

SLA_REFCO - Refraction Constants +   +

+
+
ACTION: +
Determine the constants a and b in the +atmospheric refraction model + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$, where $\zeta$ is the observed zenith distance + (i.e. affected by refraction) and $\Delta \zeta$ is + what to add to $\zeta$ to give the topocentric + (i.e. in vacuo) zenith distance. +

CALL: +
CALL sla_REFCO (HM, TDK, PMB, RH, WL, PHI, TLR, EPS, REFA, REFB) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
HMDheight of the observer above sea level (metre)
TDKDambient temperature at the observer (degrees K)
PMBDpressure at the observer (mB)
RHDrelative humidity at the observer (range 0-1)
WLDeffective wavelength of the source ($\mu{\rm m}$)
PHIDlatitude of the observer (radian, astronomical)
TLRDtemperature lapse rate in the troposphere +(degrees K per metre)
EPSDprecision required to terminate iteration (radian)
+

+
RETURNED: +
+
+ + + + + + + + + +
REFAD$\tan \zeta$ coefficient (radians)
REFBD$\tan^{3} \zeta$ coefficient (radians)
+

+
NOTES: +
+
1. +
Suggested values for the TLR and EPS arguments are 0.0065D0 and +1D-8 respectively. +
2. +
The radio refraction is chosen by specifying WL >100 $\mu{\rm m}$.
3. +
The routine is a slower but more accurate alternative to the + sla_REFCOQ routine. The constants it produces give perfect + agreement with sla_REFRO at zenith distances + $\tan^{-1} 1$ ($45^\circ$) and $\tan^{-1} 4$ ($\sim 76^\circ$). + At other zenith distances, the model achieves: +

$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$ accuracy for $\zeta<80^{\circ}$,

$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.01$ accuracy for $\zeta<60^{\circ}$, and +

$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.001$ accuracy for $\zeta<45^{\circ}$.

+

+ +next + +up + +previous +
+ Next: SLA_REFCOQ - Refraction Constants (fast) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RDPLAN - Apparent of Planet +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node166.html b/src/slalib/sun67.htx/node166.html new file mode 100644 index 0000000..4dd74d2 --- /dev/null +++ b/src/slalib/sun67.htx/node166.html @@ -0,0 +1,428 @@ + + + + +SLA_REFCOQ - Refraction Constants (fast) + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_REFRO - Refraction +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFCO - Refraction Constants +

+

+

SLA_REFCOQ - Refraction Constants (fast) +   +

+
+
ACTION: +
Determine the constants a and b in the +atmospheric refraction model + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$, where $\zeta$ is the observed zenith distance + (i.e. affected by refraction) and $\Delta \zeta$ is + what to add to $\zeta$ to give the topocentric + (i.e. in vacuo) zenith distance. (This is a fast + alternative to the sla_REFCO routine - see notes.) +

CALL: +
CALL sla_REFCOQ (TDK, PMB, RH, WL, REFA, REFB) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
TDKDambient temperature at the observer (degrees K)
PMBDpressure at the observer (mB)
RHDrelative humidity at the observer (range 0-1)
WLDeffective wavelength of the source ($\mu{\rm m}$)
+

+
RETURNED: +
+
+ + + + + + + + + +
REFAD$\tan \zeta$ coefficient (radians)
REFBD$\tan^{3} \zeta$ coefficient (radians)
+

+
NOTES: +
+
1. +
The radio refraction is chosen by specifying WL >100 $\mu{\rm m}$.
2. +
The model is an approximation, for moderate zenith distances, +to the predictions of the sla_REFRO routine. The approximation + is maintained across a range of conditions, and applies to + both optical/IR and radio. +
3. +
The algorithm is a fast alternative to the sla_REFCO routine. + The latter calls the sla_REFRO routine itself: this involves + integrations through a model atmosphere, and is costly in + processor time. However, the model which is produced is precisely + correct for two zenith distances ($45^\circ$ and $\sim\!76^\circ$) and at other zenith distances is limited in accuracy only by the + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ formulation + itself. The present routine is not as accurate, though it + satisfies most practical requirements. +
4. +
The model omits the effects of (i) height above sea level (apart + from the reduced pressure itself), (ii) latitude (i.e. the + flattening of the Earth) and (iii) variations in tropospheric + lapse rate. +
5. +
The model has been tested using the following range of conditions: +
+
$\cdot$
lapse rates 0.0055, 0.0065, 0.0075 degrees K per metre +
$\cdot$
latitudes $0^{\circ}$, $25^\circ$, $50^\circ$, $75^\circ$
$\cdot$
heights 0, 2500, 5000 metres above sea level +
$\cdot$
pressures mean for height -10% to +5% in steps of 5% +
$\cdot$
temperatures $-10^\circ$ to $+20^\circ$ with respect to + $280^\circ$K at sea level +
$\cdot$
relative humidity 0, 0.5, 1 +
$\cdot$
wavelength 0.4, 0.6, ... $2\mu{\rm m}$, + radio +
$\cdot$
zenith distances $15^\circ$, $45^\circ$, $75^\circ$
+ For the above conditions, the comparison with sla_REFRO + was as follows: +


+
+
+

           + + + + + + + + + + + + + + + + + +
 worstRMS
optical/IR628
radio31949
 masmas
+


+
+
+
+

+For this particular set of conditions: +

+
$\cdot$
lapse rate $6.5^\circ K km^{-1}$
$\cdot$
latitude $50^\circ$
$\cdot$
sea level +
$\cdot$
pressure 1005mB +
$\cdot$
temperature $7^\circ$C +
$\cdot$
humidity 80% +
$\cdot$
wavelength 5740A +
+ the results were as follows: +


+
+
+

           + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
$\zeta$sla_REFROsla_REFCOQSaastamoinen
1010.2710.2710.27
2021.1921.2021.19
3033.6133.6133.60
4048.8248.8348.81
4558.1658.1858.16
5069.2869.3069.27
5582.9782.9982.95
60100.51100.54100.50
65124.23124.26124.20
70158.63158.68158.61
72177.32177.37177.31
74200.35200.38200.32
76229.45229.43229.42
78267.44267.29267.41
80319.13318.55319.10
degarcsecarcsecarcsec
+


+
+
+
+

+The values for Saastamoinen's formula (which includes terms + up to $\tan^5$) are taken from Hohenkerk and Sinclair (1985). +

+The results from the much slower but more accurate sla_REFCO + routine have not been included in the tabulation as they are + identical to those in the sla_REFRO column to the + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.01$

+resolution used. +

6. +
Outlandish input parameters are silently limited + to mathematically safe values. Zero pressure is permissible, + and causes zeroes to be returned. +
7. +
The algorithm draws on several sources, as follows: +
    +
  • The formula for the saturation vapour pressure of water as + a function of temperature and temperature is taken from + expressions A4.5-A4.7 of Gill (1982). +
  • The formula for the water vapour pressure, given the + saturation pressure and the relative humidity is from + Crane (1976), expression 2.5.5. +
  • The refractivity of air is a function of temperature, + total pressure, water-vapour pressure and, in the case + of optical/IR but not radio, wavelength. The formulae + for the two cases are developed from the Essen and Froome + expressions adopted in Resolution 1 of the 12th International + Geodesy Association General Assembly (1963). +
+ The above three items are as used in the sla_REFRO routine. +
    +
  • The formula for $\beta~(=H_0/r_0)$ is + an adaption of expression 9 from Stone (1996). The + adaptations, arrived at empirically, consist of (i) a + small adjustment to the coefficient and (ii) a humidity + term for the radio case only. +
  • The formulae for the refraction constants as a function of + n-1 and $\beta$ are from Green (1987), expression 4.31. +
+

+
REFERENCES: +
+
1. +
Crane, R.K., Meeks, M.L. (ed), ``Refraction Effects in +the Neutral Atmosphere'', +Methods of Experimental Physics: Astrophysics 12B, + Academic Press, 1976. +
2. +
Gill, Adrian E., Atmosphere-Ocean Dynamics, + Academic Press, 1982. +
3. +
Hohenkerk, C.Y., & Sinclair, A.T., NAO Technical Note + No. 63, 1985. +
4. +
International Geodesy Association General Assembly, Bulletin + Géodésique 70 p390, 1963. +
5. +
Stone, Ronald C., P.A.S.P. 108 1051-1058, 1996. +
6. +
Green, R.M., Spherical Astronomy, Cambridge + University Press, 1987. +
+

+ +next + +up + +previous +
+ Next: SLA_REFRO - Refraction +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFCO - Refraction Constants +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node167.html b/src/slalib/sun67.htx/node167.html new file mode 100644 index 0000000..f422ec8 --- /dev/null +++ b/src/slalib/sun67.htx/node167.html @@ -0,0 +1,232 @@ + + + + +SLA_REFRO - Refraction + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_REFV - Apply Refraction to Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFCOQ - Refraction Constants (fast) +

+

+

SLA_REFRO - Refraction +   +

+
+
ACTION: +
Atmospheric refraction, for radio or optical/IR wavelengths. +
CALL: +
CALL sla_REFRO (ZOBS, HM, TDK, PMB, RH, WL, PHI, TLR, EPS, REF) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ZOBSDobserved zenith distance of the source (radians)
HMDheight of the observer above sea level (metre)
TDKDambient temperature at the observer (degrees K)
PMBDpressure at the observer (mB)
RHDrelative humidity at the observer (range 0-1)
WLDeffective wavelength of the source ($\mu{\rm m}$)
PHIDlatitude of the observer (radian, astronomical)
TLRDtemperature lapse rate in the troposphere +(degrees K per metre)
EPSDprecision required to terminate iteration (radian)
+

+
RETURNED: +
+
+ + + + + +
REFDrefraction: in vacuo ZD minus observed ZD (radians)
+

+
NOTES: +
+
1. +
A suggested value for the TLR argument is 0.0065D0. The +refraction is significantly affected by TLR, and if studies +of the local atmosphere have been carried out a better TLR + value may be available. +
2. +
A suggested value for the EPS argument is 1D-8. The result is + usually at least two orders of magnitude more computationally + precise than the supplied EPS value. +
3. +
The routine computes the refraction for zenith distances up + to and a little beyond $90^{\circ}$ using the method of Hohenkerk + & Sinclair (NAO Technical Notes 59 and 63, subsequently adopted + in the Explanatory Supplement to the Astronomical Almanac, + 1992 - see section 3.281). +
4. +
The code is based on the AREF optical/IR refraction subroutine + of C.Hohenkerk (HMNAO, September 1984), with extensions to + support the radio case. The modifications to the original HMNAO + optical/IR refraction code which affect the results are: +
    +
  • Murray's values for the gas constants have been used + (Vectorial Astrometry, Adam Hilger, 1983). +
  • A better model for Ps(T) has been adopted (taken from + Gill, Atmosphere-Ocean Dynamics, Academic Press, 1982). +
  • More accurate expressions for Pwo have been adopted + (again from Gill 1982). +
  • Provision for radio wavelengths has been added using + expressions devised by A.T.Sinclair, RGO (private + communication 1989), based on the Essen & Froome + refractivity formula adopted in Resolution 1 of the + 12th International Geodesy Association General Assembly + (Bulletin Géodésique 70 p390, 1963). +
+ None of the changes significantly affects the optical/IR results + with respect to the algorithm given in the 1992 Explanatory + Supplement. For example, at $70^\circ$ zenith distance the present + routine agrees with the ES algorithm to better than + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.05$

+for any reasonable combination of parameters. However, the + improved water-vapour expressions do make a significant difference + in the radio band, at $70^\circ$ zenith distance reaching almost + $4\hspace{-0.05em}^{'\hspace{-0.1em}'}$ for a hot, humid, low-altitude site during a period of + low pressure. +

5. +
The radio refraction is chosen by specifying WL >100 $\mu{\rm m}$. Because the algorithm takes no account of the ionosphere, the + accuracy deteriorates at low frequencies, below about 30MHz. +
6. +
Before use, the value of ZOBS is expressed in the range $\pm \pi$. If this ranged ZOBS is negative, the result REF is computed from its + absolute value before being made negative to match. In addition, if + it has an absolute value greater than $93^\circ$, a fixed REF value + equal to the result for ZOBS $=93^\circ$ is returned, appropriately + signed. +
7. +
As in the original Hohenkerk and Sinclair algorithm, fixed values + of the water vapour polytrope exponent, the height of the + tropopause, and the height at which refraction is negligible are + used. +
8. +
The radio refraction has been tested against work done by + Iain Coulson, JACH, (private communication 1995) for the + James Clerk Maxwell Telescope, Mauna Kea. For typical conditions, + agreement at the + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$ level is achieved for moderate ZD, + worsening to perhaps + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$ - + $1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.0$ at ZD $80^\circ$. At hot and humid sea-level sites the accuracy will not be as good. +
9. +
It should be noted that the relative humidity RH is formally + defined in terms of ``mixing ratio'' rather than pressures or + densities as is often stated. It is the mass of water per unit + mass of dry air divided by that for saturated air at the same + temperature and pressure (see Gill 1982). The familiar + $\nu=p_w/p_s$ or $\nu=\rho_w/\rho_s$ expressions can differ from + the formal definition by several percent, significant in the + radio case. +
+

+ +next + +up + +previous +
+ Next: SLA_REFV - Apply Refraction to Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFCOQ - Refraction Constants (fast) +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node168.html b/src/slalib/sun67.htx/node168.html new file mode 100644 index 0000000..c695ed9 --- /dev/null +++ b/src/slalib/sun67.htx/node168.html @@ -0,0 +1,276 @@ + + + + +SLA_REFV - Apply Refraction to Vector + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_REFZ - Apply Refraction to ZD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFRO - Refraction +

+

+

SLA_REFV - Apply Refraction to Vector +   +

+
+
ACTION: +
Adjust an unrefracted Cartesian vector to include the effect of +atmospheric refraction, using the simple + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ model. +

CALL: +
CALL sla_REFV (VU, REFA, REFB, VR) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
VUDunrefracted position of the source ($[\,Az,El~]$ 3-vector)
REFAD$\tan \zeta$ coefficient (radians)
REFBD$\tan^{3} \zeta$ coefficient (radians)
+

+
RETURNED: +
+
+ + + + + +
VRDrefracted position of the source ($[\,Az,El~]$ 3-vector)
+

+
NOTES: +
+
1. +
This routine applies the adjustment for refraction in the +opposite sense to the usual one - it takes an unrefracted +(in vacuo) position and produces an observed (refracted) + position, whereas the + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ model strictly + applies to the case where an observed position is to have the + refraction removed. The unrefracted to refracted case is + harder, and requires an inverted form of the text-book + refraction models; the algorithm used here is equivalent to + one iteration of the Newton-Raphson method applied to the + above formula. +
2. +
Though optimized for speed rather than precision, the present + routine achieves consistency with the refracted-to-unrefracted + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ model at better than 1 microarcsecond within + $30^\circ$ of the zenith and remains within 1 milliarcsecond to + $\zeta=70^\circ$. The inherent accuracy of the model is, of + course, far worse than this - see the documentation for sla_REFCO + for more information. +
3. +
At low elevations (below about $3^{\circ}$) the refraction + correction is held back to prevent arithmetic problems and + wildly wrong results. Over a wide range of observer heights + and corresponding temperatures and pressures, the following + levels of accuracy are achieved, relative to numerical + integration through a model atmosphere: +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
$\zeta_{obs}$error 
   
$80^\circ$$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.4$ 
$81^\circ$$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.8$ 
$82^\circ$$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.6$ 
$83^\circ$$3\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$84^\circ$$7\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$85^\circ$$17\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$86^\circ$$45\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$87^\circ$$150\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$88^\circ$$340\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$89^\circ$$620\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$90^{\circ}$$1100\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$91^\circ$$1900\hspace{-0.05em}^{'\hspace{-0.1em}'}$< high-altitude
$92^\circ$$3200\hspace{-0.05em}^{'\hspace{-0.1em}'}$< sites only
+
4. +
See also the routine sla_REFZ, which performs the adjustment to + the zenith distance rather than in $[\,x,y,z\,]$. The present routine is faster than sla_REFZ and, + except very low down, + is equally accurate for all practical purposes. However, beyond + about $\zeta=84^\circ$ sla_REFZ should be used, and for the utmost + accuracy iterative use of sla_REFRO should be considered. +
+

+ +next + +up + +previous +
+ Next: SLA_REFZ - Apply Refraction to ZD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFRO - Refraction +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node169.html b/src/slalib/sun67.htx/node169.html new file mode 100644 index 0000000..6180ab0 --- /dev/null +++ b/src/slalib/sun67.htx/node169.html @@ -0,0 +1,275 @@ + + + + +SLA_REFZ - Apply Refraction to ZD + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RVEROT - RV Corrn to Earth Centre +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFV - Apply Refraction to Vector +

+

+

SLA_REFZ - Apply Refraction to ZD +   +

+
+
ACTION: +
Adjust an unrefracted zenith distance to include the effect of +atmospheric refraction, using the simple + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ model. +

CALL: +
CALL sla_REFZ (ZU, REFA, REFB, ZR) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
ZUDunrefracted zenith distance of the source (radians)
REFAD$\tan \zeta$ coefficient (radians)
REFBD$\tan^{3} \zeta$ coefficient (radians)
+

+
RETURNED: +
+
+ + + + + +
ZRDrefracted zenith distance (radians)
+

+
NOTES: +
+
1. +
This routine applies the adjustment for refraction in the +opposite sense to the usual one - it takes an unrefracted +(in vacuo) position and produces an observed (refracted) + position, whereas the + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ model strictly + applies to the case where an observed position is to have the + refraction removed. The unrefracted to refracted case is + harder, and requires an inverted form of the text-book + refraction models; the formula used here is based on the + Newton-Raphson method. For the utmost numerical consistency + with the refracted to unrefracted model, two iterations are + carried out, achieving agreement at the 10-11 arcsecond level + for $\zeta=80^\circ$. The inherent accuracy of the model + is, of course, far worse than this - see the documentation for + sla_REFCO for more information. +
2. +
At $\zeta=83^\circ$, the rapidly-worsening + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ model is abandoned and an empirical formula takes over: +

+

\begin{displaymath}
+\Delta \zeta = F \left(
+ \frac{0^\circ\hspace{-0.37em}.\hspa...
+ ...hspace{0.02em}00202 E^2}
+ {1 + 0.28385 E +0.02390 E^2} \right) \end{displaymath}

+where $E=90^\circ-\zeta_{true}$ and F is a factor chosen to meet the + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ formula at $\zeta=83^\circ$. Over a + wide range of observer heights and corresponding temperatures and + pressures, the following levels of accuracy are achieved, + relative to numerical integration through a model atmosphere: +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
$\zeta_{obs}$error 
   
$80^\circ$$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.4$ 
$81^\circ$$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.8$ 
$82^\circ$$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$ 
$83^\circ$$3\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$ 
$84^\circ$$4\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.9$ 
$85^\circ$$5\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.8$ 
$86^\circ$$6\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$ 
$87^\circ$$7\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$ 
$88^\circ$$11\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$89^\circ$$21\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$90^{\circ}$$43\hspace{-0.05em}^{'\hspace{-0.1em}'}$ 
$91^\circ$$92\hspace{-0.05em}^{'\hspace{-0.1em}'}$< high-altitude
$92^\circ$$220\hspace{-0.05em}^{'\hspace{-0.1em}'}$< sites only
+
3. +
See also the routine sla_REFV, which performs the adjustment in + $[\,x,y,z\,]$, and with the emphasis on speed rather than numerical accuracy. +
+

+ +next + +up + +previous +
+ Next: SLA_RVEROT - RV Corrn to Earth Centre +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFV - Apply Refraction to Vector +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node17.html b/src/slalib/sun67.htx/node17.html new file mode 100644 index 0000000..c44bc9c --- /dev/null +++ b/src/slalib/sun67.htx/node17.html @@ -0,0 +1,205 @@ + + + + +SLA_ALTAZ - Velocities etc. for Altazimuth Mount + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_AMP - Apparent to Mean +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AIRMAS - Air Mass +

+

+

SLA_ALTAZ - Velocities etc. for Altazimuth Mount +   +

+
+
ACTION: +
Positions, velocities and accelerations for an altazimuth +telescope mount tracking a star (double precision). +

CALL: +
CALL sla_ALTAZ ( + HA, DEC, PHI, + AZ, AZD, AZDD, EL, ELD, ELDD, PA, PAD, PADD) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
HADhour angle
DECDdeclination
PHIDobservatory latitude
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AZDazimuth
AZDDazimuth velocity
AZDDDazimuth acceleration
ELDelevation
ELDDelevation velocity
ELDDDelevation acceleration
PADparallactic angle
PADDparallactic angle velocity
PADDDparallactic angle acceleration
+

+
NOTES: +
+
1. +
Natural units are used throughout. HA, DEC, PHI, AZ, EL +and ZD are in radians. The velocities and accelerations +assume constant declination and constant rate of change of + hour angle (as for tracking a star); the units of AZD, ELD + and PAD are radians per radian of HA, while the units of AZDD, + ELDD and PADD are radians per radian of HA squared. To + convert into practical degree- and second-based units: +

+ + + + + + + + + + + + + + + + +
angles$\times 360/2\pi$$\rightarrow$degrees
velocities$\times (2\pi/86400) \times (360/2\pi)$$\rightarrow$degree/sec
accelerations$\times (2\pi/86400)^2 \times (360/2\pi)$$\rightarrow$degree/sec/sec
+

+Note that the seconds here are sidereal rather than SI. One + sidereal second is about 0.99727 SI seconds. +

+The velocity and acceleration factors assume the sidereal + tracking case. Their respective numerical values are (exactly) + 1/240 and (approximately) 1/3300236.9. +

2. +
Azimuth is returned in the range $[\,0,2\pi\,]$; north is zero, + and east is $+\pi/2$. Elevation and parallactic angle are + returned in the range $\pm\pi/2$. Position angle is +ve + for a star west of the meridian and is the angle NP-star-zenith. +
3. +
The latitude is geodetic as opposed to geocentric. The + hour angle and declination are topocentric. Refraction and + deficiencies in the telescope mounting are ignored. The + purpose of the routine is to give the general form of the + quantities. The details of a real telescope could profoundly + change the results, especially close to the zenith. +
4. +
No range checking of arguments is carried out. +
5. +
In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude, and (for tracking a star) + sine and cosine of declination. +
+

+ +next + +up + +previous +
+ Next: SLA_AMP - Apparent to Mean +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AIRMAS - Air Mass +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node170.html b/src/slalib/sun67.htx/node170.html new file mode 100644 index 0000000..3f0f1a1 --- /dev/null +++ b/src/slalib/sun67.htx/node170.html @@ -0,0 +1,111 @@ + + + + +SLA_RVEROT - RV Corrn to Earth Centre + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RVGALC - RV Corrn to Galactic Centre +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFZ - Apply Refraction to ZD +

+

+

SLA_RVEROT - RV Corrn to Earth Centre +   +

+
+
ACTION: +
Velocity component in a given direction due to Earth rotation. +
CALL: +
R = sla_RVEROT (PHI, RA, DA, ST) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
PHIRgeodetic latitude of observing station (radians)
RA,DARapparent $[\,\alpha,\delta\,]$ (radians)
STRlocal apparent sidereal time (radians)
+

+
RETURNED: +
+
+ + + + + +
sla_RVEROTRComponent of Earth rotation in +direction RA,DA (km s-1)
+

+
NOTES: +
+
1. +
Sign convention: the result is positive when the observatory +is receding from the given point on the sky. +
2. +
Accuracy: the simple algorithm used assumes a spherical Earth and + an observing station at sea level; for actual observing + sites, the error is unlikely to be greater than 0.0005 km s-1. + For applications requiring greater precision, use the routine + sla_PVOBS. +
+

+ +next + +up + +previous +
+ Next: SLA_RVGALC - RV Corrn to Galactic Centre +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_REFZ - Apply Refraction to ZD +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node171.html b/src/slalib/sun67.htx/node171.html new file mode 100644 index 0000000..307d861 --- /dev/null +++ b/src/slalib/sun67.htx/node171.html @@ -0,0 +1,115 @@ + + + + +SLA_RVGALC - RV Corrn to Galactic Centre + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RVLG - RV Corrn to Local Group +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVEROT - RV Corrn to Earth Centre +

+

+

SLA_RVGALC - RV Corrn to Galactic Centre +   +

+
+
ACTION: +
Velocity component in a given direction due to the rotation +of the Galaxy. +

CALL: +
R = sla_RVGALC (R2000, D2000) +

+

+
GIVEN: +
+
+ + + + + +
R2000,D2000RJ2000.0 mean $[\,\alpha,\delta\,]$ (radians)
+

+
RETURNED: +
+
+ + + + + +
sla_RVGALCRComponent of dynamical LSR motion in direction +R2000,D2000 (km s-1)
+

+
NOTES: +
+
1. +
Sign convention: the result is positive when the LSR +is receding from the given point on the sky. +
2. +
The Local Standard of Rest used here is a point in the + vicinity of the Sun which is in a circular orbit around + the Galactic centre. Sometimes called the dynamical LSR, + it is not to be confused with a kinematical LSR, which + is the mean standard of rest of star catalogues or stellar + populations. +
3. +
The dynamical LSR velocity due to Galactic rotation is assumed to + be 220 km s-1 towards $l^{I\!I}=90^{\circ}$, $b^{I\!I}=0$.
+

+
REFERENCE: +
Kerr & Lynden-Bell (1986), MNRAS, 221, p1023. +
+

+ +next + +up + +previous +
+ Next: SLA_RVLG - RV Corrn to Local Group +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVEROT - RV Corrn to Earth Centre +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node172.html b/src/slalib/sun67.htx/node172.html new file mode 100644 index 0000000..561680e --- /dev/null +++ b/src/slalib/sun67.htx/node172.html @@ -0,0 +1,101 @@ + + + + +SLA_RVLG - RV Corrn to Local Group + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RVLSRD - RV Corrn to Dynamical LSR +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVGALC - RV Corrn to Galactic Centre +

+

+

SLA_RVLG - RV Corrn to Local Group +   +

+
+
ACTION: +
Velocity component in a given direction due to the combination +of the rotation of the Galaxy and the motion of the Galaxy + relative to the mean motion of the local group. +

CALL: +
R = sla_RVLG (R2000, D2000) +

+

+
GIVEN: +
+
+ + + + + +
R2000,D2000RJ2000.0 mean $[\,\alpha,\delta\,]$ (radians)
+

+
RETURNED: +
+
+ + + + + +
sla_RVLGRComponent of solar (n.b.) +motion in direction R2000,D2000 (km s-1)
+

+
NOTE: +
Sign convention: the result is positive when +the Sun is receding from the given point on the sky. +
+

+
REFERENCE: +
IAU Trans. 1976. 16B, p201. +
+

+ +next + +up + +previous +
+ Next: SLA_RVLSRD - RV Corrn to Dynamical LSR +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVGALC - RV Corrn to Galactic Centre +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node173.html b/src/slalib/sun67.htx/node173.html new file mode 100644 index 0000000..2ae01da --- /dev/null +++ b/src/slalib/sun67.htx/node173.html @@ -0,0 +1,121 @@ + + + + +SLA_RVLSRD - RV Corrn to Dynamical LSR + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_RVLSRK - RV Corrn to Kinematical LSR +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVLG - RV Corrn to Local Group +

+

+

SLA_RVLSRD - RV Corrn to Dynamical LSR +   +

+
+
ACTION: +
Velocity component in a given direction due to the Sun's +motion with respect to the ``dynamical'' Local Standard of Rest. +

CALL: +
R = sla_RVLSRD (R2000, D2000) +

+

+
GIVEN: +
+
+ + + + + +
R2000,D2000RJ2000.0 mean $[\,\alpha,\delta\,]$ (radians)
+

+
RETURNED: +
+
+ + + + + +
sla_RVLSRDRComponent of peculiar solar motion +in direction R2000,D2000 (km s-1)
+

+
NOTES: +
+
1. +
Sign convention: the result is positive when +the Sun is receding from the given point on the sky. +
2. +
The Local Standard of Rest used here is the dynamical LSR, + a point in the vicinity of the Sun which is in a circular + orbit around the Galactic centre. The Sun's motion with + respect to the dynamical LSR is called the peculiar solar + motion. +
3. +
There is another type of LSR, called a kinematical LSR. A + kinematical LSR is the mean standard of rest of specified star + catalogues or stellar populations, and several slightly + different kinematical LSRs are in use. The Sun's motion with + respect to an agreed kinematical LSR is known as the + standard solar motion. + The dynamical LSR is seldom used by observational astronomers, + who conventionally use a kinematical LSR such as the one implemented + in the routine sla_RVLSRK. +
4. +
The peculiar solar motion is from Delhaye (1965), in Stars + and Stellar Systems, vol 5, p73: in Galactic Cartesian + coordinates (+9,+12,+7) km s-1. + This corresponds to about 16.6 km s-1 + towards Galactic coordinates $l^{I\!I}=53^{\circ},b^{I\!I}=+25^{\circ}$.
+

+ +next + +up + +previous +
+ Next: SLA_RVLSRK - RV Corrn to Kinematical LSR +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVLG - RV Corrn to Local Group +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node174.html b/src/slalib/sun67.htx/node174.html new file mode 100644 index 0000000..f243766 --- /dev/null +++ b/src/slalib/sun67.htx/node174.html @@ -0,0 +1,126 @@ + + + + +SLA_RVLSRK - RV Corrn to Kinematical LSR + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_S2TP - Spherical to Tangent Plane +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVLSRD - RV Corrn to Dynamical LSR +

+

+

SLA_RVLSRK - RV Corrn to Kinematical LSR +   +

+
+
ACTION: +
Velocity component in a given direction due to the Sun's +motion with respect to a kinematical Local Standard of Rest. +

CALL: +
R = sla_RVLSRK (R2000, D2000) +

+

+
GIVEN: +
+
+ + + + + +
R2000,D2000RJ2000.0 mean $[\,\alpha,\delta\,]$ (radians)
+

+
RETURNED: +
+
+ + + + + +
sla_RVLSRKRComponent of standard solar motion +in direction R2000,D2000 (km s-1)
+

+
NOTES: +
+
1. +
Sign convention: the result is positive when +the Sun is receding from the given point on the sky. +
2. +
The Local Standard of Rest used here is one of several + kinematical LSRs in common use. A kinematical LSR is the + mean standard of rest of specified star catalogues or stellar + populations. The Sun's motion with respect to a kinematical + LSR is known as the standard solar motion. +
3. +
There is another sort of LSR, seldom used by observational + astronomers, called the dynamical LSR. This is a + point in the vicinity of the Sun which is in a circular orbit + around the Galactic centre. The Sun's motion with respect to + the dynamical LSR is called the peculiar solar motion. To + obtain a radial velocity correction with respect to the + dynamical LSR use the routine sla_RVLSRD. +
4. +
The adopted standard solar motion is 20 km s-1 + towards $\alpha=18^{\rm h},\delta=+30^{\circ}$ (1900). +
+

+
REFERENCES: +
+
1. +
Delhaye (1965), in Stars and Stellar Systems, vol 5, p73. +
2. +
Methods of Experimental Physics (ed Meeks), vol 12, +part C, sec 6.1.5.2, p281. +
+

+ +next + +up + +previous +
+ Next: SLA_S2TP - Spherical to Tangent Plane +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVLSRD - RV Corrn to Dynamical LSR +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node175.html b/src/slalib/sun67.htx/node175.html new file mode 100644 index 0000000..5c3e6c7 --- /dev/null +++ b/src/slalib/sun67.htx/node175.html @@ -0,0 +1,129 @@ + + + + +SLA_S2TP - Spherical to Tangent Plane + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_SEP - Angle Between 2 Points on Sphere +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVLSRK - RV Corrn to Kinematical LSR +

+

+

SLA_S2TP - Spherical to Tangent Plane +   +

+
+
ACTION: +
Projection of spherical coordinates onto the tangent plane +(single precision). +

CALL: +
CALL sla_S2TP (RA, DEC, RAZ, DECZ, XI, ETA, J) +

+

+
GIVEN: +
+
+ + + + + + + + + +
RA,DECRspherical coordinates of star (radians)
RAZ,DECZRspherical coordinates of tangent point (radians)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
XI,ETARtangent plane coordinates (radians)
JIstatus:
0 = OK, star on tangent plane
1 = error, star too far from axis
2 = error, antistar on tangent plane
3 = error, antistar too far from axis
+

+
NOTES: +
+
1. +
The projection is called the gnomonic projection; the +Cartesian coordinates $[\,\xi,\eta\,]$ are called +standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
2. +
When working in $[\,x,y,z\,]$ rather than spherical coordinates, the + equivalent Cartesian routine sla_V2TP is available. +
+

+ +next + +up + +previous +
+ Next: SLA_SEP - Angle Between 2 Points on Sphere +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_RVLSRK - RV Corrn to Kinematical LSR +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node176.html b/src/slalib/sun67.htx/node176.html new file mode 100644 index 0000000..a12d2ab --- /dev/null +++ b/src/slalib/sun67.htx/node176.html @@ -0,0 +1,100 @@ + + + + +SLA_SEP - Angle Between 2 Points on Sphere + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_SMAT - Solve Simultaneous Equations +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_S2TP - Spherical to Tangent Plane +

+

+

SLA_SEP - Angle Between 2 Points on Sphere +   +

+
+
ACTION: +
Angle between two points on a sphere (single precision). +
CALL: +
R = sla_SEP (A1, B1, A2, B2) +

+

+
GIVEN: +
+
+ + + + + + + + + +
A1,B1Rspherical coordinates of one point (radians)
A2,B2Rspherical coordinates of the other point (radians)
+

+
RETURNED: +
+
+ + + + + +
sla_SEPRangle between [A1,B1] and [A2,B2] in radians
+

+
NOTES: +
+
1. +
The spherical coordinates are right ascension and declination, +longitude and latitude, etc. in radians. +
2. +
The result is always positive. +
+

+ +next + +up + +previous +
+ Next: SLA_SMAT - Solve Simultaneous Equations +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_S2TP - Spherical to Tangent Plane +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node177.html b/src/slalib/sun67.htx/node177.html new file mode 100644 index 0000000..733a9c6 --- /dev/null +++ b/src/slalib/sun67.htx/node177.html @@ -0,0 +1,152 @@ + + + + +SLA_SMAT - Solve Simultaneous Equations + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_SUBET - Remove E-terms +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SEP - Angle Between 2 Points on Sphere +

+

+

SLA_SMAT - Solve Simultaneous Equations +   +

+
+
ACTION: +
Matrix inversion and solution of simultaneous equations +(single precision). +

CALL: +
CALL sla_SMAT (N, A, Y, D, JF, IW) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
NInumber of unknowns
AR(N,N)matrix
YR(N)vector
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + +
AR(N,N)matrix inverse
YR(N)solution
DRdeterminant
JFIsingularity flag: 0=OK
IWI(N)workspace
+

+
NOTES: +
+
1. +
For the set of n simultaneous linear equations in n unknowns: +
A$\cdot$y = x +
+ where: +
    +
  • A is a non-singular $n \times n$ matrix, +
  • y is the vector of n unknowns, and +
  • x is the known vector, +
+ sla_SMAT computes: +
    +
  • the inverse of matrix A, +
  • the determinant of matrix A, and +
  • the vector of n unknowns y. +
+ Argument N is the order n, A (given) is the matrix A, + Y (given) is the vector x and Y (returned) + is the vector y. + The argument A (returned) is the inverse matrix A-1, + and D is det(A). +
2. +
JF is the singularity flag. If the matrix is non-singular, + JF=0 is returned. If the matrix is singular, JF=-1 + and D=0.0 are returned. In the latter case, the contents + of array A on return are undefined. +
3. +
The algorithm is Gaussian elimination with partial pivoting. + This method is very fast; some much slower algorithms can give + better accuracy, but only by a small factor. +
4. +
This routine replaces the obsolete sla_SMATRX. +
+

+ +next + +up + +previous +
+ Next: SLA_SUBET - Remove E-terms +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SEP - Angle Between 2 Points on Sphere +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node178.html b/src/slalib/sun67.htx/node178.html new file mode 100644 index 0000000..3d7a547 --- /dev/null +++ b/src/slalib/sun67.htx/node178.html @@ -0,0 +1,111 @@ + + + + +SLA_SUBET - Remove E-terms + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_SUPGAL - Supergalactic to Galactic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SMAT - Solve Simultaneous Equations +

+

+

SLA_SUBET - Remove E-terms +   +

+
+
ACTION: +
Remove the E-terms (elliptic component of annual aberration) +from a pre IAU 1976 catalogue $[\,\alpha,\delta\,]$ to give a mean place. +

CALL: +
CALL sla_SUBET (RC, DC, EQ, RM, DM) +

+

+
GIVEN: +
+
+ + + + + + + + + +
RC,DCD$[\,\alpha,\delta\,]$ with E-terms included (radians)
EQDBesselian epoch of mean equator and equinox
+

+
RETURNED: +
+
+ + + + + +
RM,DMD$[\,\alpha,\delta\,]$ without E-terms (radians)
+

+
NOTE: +
Most star positions from pre-1984 optical catalogues (or +obtained by astrometry with respect to such stars) have the + E-terms built-in. This routine converts such a position to a + formal mean place (allowing, for example, comparison with a + pulsar timing position). +
+

+
REFERENCE: +
Explanatory Supplement to the Astronomical Ephemeris, +section 2D, page 48. +
+

+ +next + +up + +previous +
+ Next: SLA_SUPGAL - Supergalactic to Galactic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SMAT - Solve Simultaneous Equations +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node179.html b/src/slalib/sun67.htx/node179.html new file mode 100644 index 0000000..1b5da60 --- /dev/null +++ b/src/slalib/sun67.htx/node179.html @@ -0,0 +1,107 @@ + + + + +SLA_SUPGAL - Supergalactic to Galactic + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_SVD - Singular Value Decomposition +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SUBET - Remove E-terms +

+

+

SLA_SUPGAL - Supergalactic to Galactic +   +

+
+
ACTION: +
Transformation from de Vaucouleurs supergalactic coordinates +to IAU 1958 galactic coordinates. +

CALL: +
CALL sla_GALSUP (DL, DB, DSL, DSB) +

+

+
GIVEN: +
+
+ + + + + +
DSL,DSBDsupergalactic longitude and latitude (radians)
+

+
RETURNED: +
+
+ + + + + +
DL,DBDgalactic longitude and latitude $[\,l^{I\!I},b^{I\!I}\,]$ (radians)
+

+
REFERENCES: +
+
1. +
de Vaucouleurs, de Vaucouleurs, & Corwin, Second Reference +Catalogue of Bright Galaxies, U.Texas, p8. +
2. +
Systems & Applied Sciences Corp., documentation for the + machine-readable version of the above catalogue, + Contract NAS 5-26490. +
+ (These two references give different values for the galactic + longitude of the supergalactic origin. Both are wrong; the + correct value is $l^{I\!I}=137.37$.) +

+

+ +next + +up + +previous +
+ Next: SLA_SVD - Singular Value Decomposition +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SUBET - Remove E-terms +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node18.html b/src/slalib/sun67.htx/node18.html new file mode 100644 index 0000000..e3aee75 --- /dev/null +++ b/src/slalib/sun67.htx/node18.html @@ -0,0 +1,135 @@ + + + + +SLA_AMP - Apparent to Mean + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_AMPQK - Quick Apparent to Mean +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ALTAZ - Velocities etc. for Altazimuth Mount +

+

+

SLA_AMP - Apparent to Mean +   +

+
+
ACTION: +
Convert star $[\,\alpha,\delta\,]$ from geocentric apparent to +mean place (post IAU 1976). +

CALL: +
CALL sla_AMP (RA, DA, DATE, EQ, RM, DM) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
RA,DADapparent $[\,\alpha,\delta\,]$ (radians)
DATEDTDB for apparent place (JD-2400000.5)
EQDequinox: Julian epoch of mean place
+

+
RETURNED: +
+
+ + + + + +
RM,DMDmean $[\,\alpha,\delta\,]$ (radians)
+

+
NOTES: +
+
1. +
The distinction between the required TDB and TT is +always negligible. Moreover, for all but the most +critical applications UTC is adequate. +
2. +
The accuracy is limited by the routine sla_EVP, called + by sla_MAPPA, which computes the Earth position and + velocity using the methods of Stumpff. The maximum + error is about 0.3 milliarcsecond. +
3. +
Iterative techniques are used for the aberration and + light deflection corrections so that the routines + sla_AMP (or sla_AMPQK) and sla_MAP (or sla_MAPQK) are + accurate inverses; even at the edge of the Sun's disc + the discrepancy is only about 1 nanoarcsecond. +
4. +
Where multiple apparent places are to be converted to + mean places, for a fixed date and equinox, it is more + efficient to use the sla_MAPPA routine to compute the + required parameters once, followed by one call to + sla_AMPQK per star. +
+

+
REFERENCES: +
+
1. +
1984 Astronomical Almanac, pp B39-B41. +
2. +
Lederle & Schwan, 1984. Astr.Astrophys. 134, 1-6. +
+

+ +next + +up + +previous +
+ Next: SLA_AMPQK - Quick Apparent to Mean +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ALTAZ - Velocities etc. for Altazimuth Mount +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node180.html b/src/slalib/sun67.htx/node180.html new file mode 100644 index 0000000..2372b60 --- /dev/null +++ b/src/slalib/sun67.htx/node180.html @@ -0,0 +1,184 @@ + + + + +SLA_SVD - Singular Value Decomposition + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_SVDCOV - Covariance Matrix from SVD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SUPGAL - Supergalactic to Galactic +

+

+

SLA_SVD - Singular Value Decomposition +   +

+
+
ACTION: +
Singular value decomposition. +This routine expresses a given matrix A as the product of + three matrices U, W, VT: +

+ 		 A = U $\cdot$ W $\cdot$ VT
+
+ where: +

+ 		 A 		 is any m (rows) $\times n$ (columns) matrix,                       where $m \geq n$ 
+		 U 		 is an $m \times n$ column-orthogonal matrix
+		 W 		 is an $n \times n$ diagonal matrix with                       $w_{ii} \geq 0$ 
+		 VT is the transpose of an $n \times n$                             orthogonal matrix
+
+

CALL: +
CALL sla_SVD (M, N, MP, NP, A, W, V, WORK, JSTAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
M,NIm, n, the numbers of rows and columns in matrix A
MP,NPIphysical dimensions of array containing matrix A
AD(MP,NP)array containing $m \times n$ matrix A
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + +
AD(MP,NP)array containing $m \times n$ column-orthogonal +matrix U
WD(N)$n \times n$ diagonal matrix W +(diagonal elements only)
VD(NP,NP)array containing $n \times n$ orthogonal +matrix V (n.b. not VT)
WORKD(N)workspace
JSTATI0 = OK, -1 = array A wrong shape, >0 = index of W +for which convergence failed (see note 3, below)
+

+
NOTES: +
+
1. +
M and N are the logical dimensions of the +matrices and vectors concerned, which can be located in +arrays of larger physical dimensions, given by MP and NP. +
2. +
V contains matrix V, not the transpose of matrix V. +
3. +
If the status JSTAT is greater than zero, this need not + necessarily be treated as a failure. It means that, due to + chance properties of the matrix A, the QR transformation + phase of the routine did not fully converge in a predefined + number of iterations, something that very seldom occurs. + When this condition does arise, it is possible that the + elements of the diagonal matrix W have not been correctly + found. However, in practice the results are likely to + be trustworthy. Applications should report the condition + as a warning, but then proceed normally. +
+

+
REFERENCES: +
The algorithm is an adaptation of the routine SVD in the EISPACK +library (Garbow et al. 1977, EISPACK Guide Extension, + Springer Verlag), which is a FORTRAN 66 implementation of the Algol + routine SVD of Wilkinson & Reinsch 1971 (Handbook for Automatic + Computation, vol 2, ed Bauer et al., Springer Verlag). These + references give full details of the algorithm used here. + A good account of the use of SVD in least squares problems is given + in Numerical Recipes (Press et al. 1987, Cambridge + University Press), which includes another variant of the EISPACK code. +
+

+ +next + +up + +previous +
+ Next: SLA_SVDCOV - Covariance Matrix from SVD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SUPGAL - Supergalactic to Galactic +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node181.html b/src/slalib/sun67.htx/node181.html new file mode 100644 index 0000000..76e49b9 --- /dev/null +++ b/src/slalib/sun67.htx/node181.html @@ -0,0 +1,122 @@ + + + + +SLA_SVDCOV - Covariance Matrix from SVD + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_SVDSOL - Solution Vector from SVD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SVD - Singular Value Decomposition +

+

+

SLA_SVDCOV - Covariance Matrix from SVD +   +

+
+
ACTION: +
From the W and V matrices from the SVD +factorization of a matrix + (as obtained from the sla_SVD routine), obtain + the covariance matrix. +

CALL: +
CALL sla_SVDCOV (N, NP, NC, W, V, WORK, CVM) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + +
NIn, the number of rows and columns in +matrices W and V
NPIfirst dimension of array containing $n \times n$matrix V
NCIfirst dimension of array CVM
WD(N)$n \times n$ diagonal matrix W +(diagonal elements only)
VD(NP,NP)array containing $n \times n$ orthogonal matrix V
+

+
RETURNED: +
+
+ + + + + + + + + +
WORKD(N)workspace
CVMD(NC,NC)array to receive covariance matrix
+

+
REFERENCE: +
Numerical Recipes, section 14.3. +
+

+ +next + +up + +previous +
+ Next: SLA_SVDSOL - Solution Vector from SVD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SVD - Singular Value Decomposition +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node182.html b/src/slalib/sun67.htx/node182.html new file mode 100644 index 0000000..f99ea3f --- /dev/null +++ b/src/slalib/sun67.htx/node182.html @@ -0,0 +1,201 @@ + + + + +SLA_SVDSOL - Solution Vector from SVD + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_TP2S - Tangent Plane to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SVDCOV - Covariance Matrix from SVD +

+

+

SLA_SVDSOL - Solution Vector from SVD +   +

+
+
ACTION: +
From a given vector and the SVD of a matrix (as obtained from +the sla_SVD routine), obtain the solution vector. + This routine solves the equation: +

+ 		 A $\cdot$ x = b         
+
+ where: +

+ 		 A 		 is a given m (rows) $\times n$ (columns)                       matrix, where $m \geq n$ 
+		 x 		 is the n-vector we wish to find, and
+		 b 		 is a given m-vector         
+
+ by means of the Singular Value Decomposition method (SVD). +

CALL: +
CALL sla_SVDSOL (M, N, MP, NP, B, U, W, V, WORK, X) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
M,NIm, n, the numbers of rows and columns in matrix A
MP,NPIphysical dimensions of array containing matrix A
BD(M)known vector b
UD(MP,NP)array containing $m \times n$ matrix U
WD(N)$n \times n$ diagonal matrix W +(diagonal elements only)
VD(NP,NP)array containing $n \times n$ orthogonal matrix V
+

+
RETURNED: +
+
+ + + + + + + + + +
WORKD(N)workspace
XD(N)unknown vector x
+

+
NOTES: +
+
1. +
In the Singular Value Decomposition method (SVD), +the matrix A is first factorized (for example by +the routine sla_SVD) into the following components: +

+ 		 A = U $\cdot$ W $\cdot$ VT
+
+ where: +

+ 		 A 		 is any m (rows) $\times n$ (columns) matrix,                      where m > n 
+		 U 		 is an $m \times n$ column-orthogonal matrix
+		 W 		 is an $n \times n$ diagonal matrix with                      $w_{ii} \geq 0$ 
+		 VT is the transpose of an $n \times n$                            orthogonal matrix        
+
+ Note that m and n are the logical dimensions of the + matrices and vectors concerned, which can be located in + arrays of larger physical dimensions MP and NP. + The solution is then found from the expression: +

+ 		 x = V $\cdot~[diag(1/$W$_{j})]
+ \cdot ($U$^{T}\cdot$b)        
+
+
2. +
If matrix A is square, and if the diagonal matrix W is not + altered, the method is equivalent to conventional solution + of simultaneous equations. +
3. +
If m > n, the result is a least-squares fit. +
4. +
If the solution is poorly determined, this shows up in the + SVD factorization as very small or zero Wj values. Where + a Wj value is small but non-zero it can be set to zero to + avoid ill effects. The present routine detects such zero + Wj values and produces a sensible solution, with highly + correlated terms kept under control rather than being allowed + to elope to infinity, and with meaningful values for the + other terms. +
+

+
REFERENCE: +
Numerical Recipes, section 2.9. +
+

+ +next + +up + +previous +
+ Next: SLA_TP2S - Tangent Plane to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SVDCOV - Covariance Matrix from SVD +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node183.html b/src/slalib/sun67.htx/node183.html new file mode 100644 index 0000000..ae3acd0 --- /dev/null +++ b/src/slalib/sun67.htx/node183.html @@ -0,0 +1,109 @@ + + + + +SLA_TP2S - Tangent Plane to Spherical + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_TP2V - Tangent Plane to Direction Cosines +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SVDSOL - Solution Vector from SVD +

+

+

SLA_TP2S - Tangent Plane to Spherical +   +

+
+
ACTION: +
Transform tangent plane coordinates into spherical +coordinates (single precision) +

CALL: +
CALL sla_TP2S (XI, ETA, RAZ, DECZ, RA, DEC) +

+

+
GIVEN: +
+
+ + + + + + + + + +
XI,ETARtangent plane rectangular coordinates (radians)
RAZ,DECZRspherical coordinates of tangent point (radians)
+

+
RETURNED: +
+
+ + + + + +
RA,DECRspherical coordinates (radians)
+

+
NOTES: +
+
1. +
The projection is called the gnomonic projection; the +Cartesian coordinates $[\,\xi,\eta\,]$ are called +standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
2. +
When working in $[\,x,y,z\,]$ rather than spherical coordinates, the + equivalent Cartesian routine sla_TP2V is available. +
+

+ +next + +up + +previous +
+ Next: SLA_TP2V - Tangent Plane to Direction Cosines +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_SVDSOL - Solution Vector from SVD +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node184.html b/src/slalib/sun67.htx/node184.html new file mode 100644 index 0000000..f069a46 --- /dev/null +++ b/src/slalib/sun67.htx/node184.html @@ -0,0 +1,117 @@ + + + + +SLA_TP2V - Tangent Plane to Direction Cosines + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_TPS2C - Plate centre from and +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_TP2S - Tangent Plane to Spherical +

+

+

SLA_TP2V - Tangent Plane to Direction Cosines +   +

+
+
ACTION: +
Given the tangent-plane coordinates of a star and the direction +cosines of the tangent point, determine the direction cosines + of the star + (single precision). +

CALL: +
CALL sla_TP2V (XI, ETA, V0, V) +

+

+
GIVEN: +
+
+ + + + + + + + + +
XI,ETARtangent plane coordinates of star (radians)
V0R(3)direction cosines of tangent point
+

+
RETURNED: +
+
+ + + + + +
VR(3)direction cosines of star
+

+
NOTES: +
+
1. +
If vector V0 is not of unit length, the returned vector V will +be wrong. +
2. +
If vector V0 points at a pole, the returned vector V will be + based on the arbitrary assumption that $\alpha=0$ at + the tangent point. +
3. +
The projection is called the gnomonic projection; the + Cartesian coordinates $[\,\xi,\eta\,]$ are called + standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
4. +
This routine is the Cartesian equivalent of the routine sla_TP2S. +
+

+ +next + +up + +previous +
+ Next: SLA_TPS2C - Plate centre from and +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_TP2S - Tangent Plane to Spherical +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node185.html b/src/slalib/sun67.htx/node185.html new file mode 100644 index 0000000..0313e77 --- /dev/null +++ b/src/slalib/sun67.htx/node185.html @@ -0,0 +1,168 @@ + + + + +SLA_TPS2C - Plate centre from and + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_TPV2C - Plate centre from and x,y,z +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_TP2V - Tangent Plane to Direction Cosines +

+

+

    +
+SLA_TPS2C - Plate centre from $\xi,\eta$ and $\alpha,\delta$

+
+
ACTION: +
From the tangent plane coordinates of a star of known $[\,\alpha,\delta\,]$,determine the $[\,\alpha,\delta\,]$ of the tangent point (single precision) +

CALL: +
CALL sla_TPS2C (XI, ETA, RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2, N) +

+

+
GIVEN: +
+
+ + + + + + + + + +
XI,ETARtangent plane rectangular coordinates (radians)
RA,DECRspherical coordinates (radians)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
RAZ1,DECZ1Rspherical coordinates of tangent point, +solution 1
RAZ2,DECZ2Rspherical coordinates of tangent point, +solution 2
NInumber of solutions:
0 = no solutions returned (note 2)
1 = only the first solution is useful (note 3)
2 = there are two useful solutions (note 3)
+

+
NOTES: +
+
1. +
The RAZ1 and RAZ2 values returned are in the range $0\!-\!2\pi$.
2. +
Cases where there is no solution can only arise near the poles. +For example, it is clearly impossible for a star at the pole + itself to have a non-zero $\xi$ value, and hence it is + meaningless to ask where the tangent point would have to be + to bring about this combination of $\xi$ and $\delta$.
3. +
Also near the poles, cases can arise where there are two useful + solutions. The argument N indicates whether the second of the + two solutions returned is useful. N=1 + indicates only one useful solution, the usual case; under + these circumstances, the second solution corresponds to the + ``over-the-pole'' case, and this is reflected in the values + of RAZ2 and DECZ2 which are returned. +
4. +
The DECZ1 and DECZ2 values returned are in the range $\pm \pi$, but in the ordinary, non-pole-crossing, case, the range is + $\pm\pi/2$.
5. +
RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2 are all in radians. +
6. +
The projection is called the gnomonic projection; the + Cartesian coordinates $[\,\xi,\eta\,]$ are called + standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
7. +
When working in $[\,x,y,z\,]$ rather than spherical coordinates, the + equivalent Cartesian routine sla_TPV2C is available. +
+

+ +next + +up + +previous +
+ Next: SLA_TPV2C - Plate centre from and x,y,z +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_TP2V - Tangent Plane to Direction Cosines +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node186.html b/src/slalib/sun67.htx/node186.html new file mode 100644 index 0000000..32d0e60 --- /dev/null +++ b/src/slalib/sun67.htx/node186.html @@ -0,0 +1,144 @@ + + + + +SLA_TPV2C - Plate centre from and x,y,z + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_UE2EL - Universal to Conventional Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_TPS2C - Plate centre from and +

+

+

    +
+SLA_TPV2C - Plate centre from $\xi,\eta$ and x,y,z +

+
+
ACTION: +
From the tangent plane coordinates of a star of known +direction cosines, determine the direction cosines + of the tangent point (single precision) +

CALL: +
CALL sla_TPV2C (XI, ETA, V, V01, V02, N) +

+

+
GIVEN: +
+
+ + + + + + + + + +
XI,ETARtangent plane coordinates of star (radians)
VR(3)direction cosines of star
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
V01R(3)direction cosines of tangent point, solution 1
V01R(3)direction cosines of tangent point, solution 2
NInumber of solutions:
0 = no solutions returned (note 2)
1 = only the first solution is useful (note 3)
2 = there are two useful solutions (note 3)
+

+
NOTES: +
+
1. +
The vector V must be of unit length or the result will be wrong. +
2. +
Cases where there is no solution can only arise near the poles. +For example, it is clearly impossible for a star at the pole + itself to have a non-zero XI value. +
3. +
Also near the poles, cases can arise where there are two useful + solutions. The argument N indicates whether the second of the + two solutions returned is useful. + N=1 + indicates only one useful solution, the usual case; under these + circumstances, the second solution can be regarded as valid if + the vector V02 is interpreted as the ``over-the-pole'' case. +
4. +
The projection is called the gnomonic projection; the + Cartesian coordinates $[\,\xi,\eta\,]$ are called + standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
5. +
This routine is the Cartesian equivalent of the routine sla_TPS2C. +
+

+ +next + +up + +previous +
+ Next: SLA_UE2EL - Universal to Conventional Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_TPS2C - Plate centre from and +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node187.html b/src/slalib/sun67.htx/node187.html new file mode 100644 index 0000000..9b71eb3 --- /dev/null +++ b/src/slalib/sun67.htx/node187.html @@ -0,0 +1,378 @@ + + + + +SLA_UE2EL - Universal to Conventional Elements + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_UE2PV - Pos/Vel from Universal Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_TPV2C - Plate centre from and x,y,z +

+

+

SLA_UE2EL - Universal to Conventional Elements +   +

+
+
ACTION: +
Transform universal elements into conventional heliocentric +osculating elements. +

CALL: +
CALL sla_UE2EL ( + U, JFORMR, + JFORM, EPOCH, ORBINC, ANODE, PERIH, + AORQ, E, AORL, DM, JSTAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
UD(13)universal orbital elements (updated; Note 1)
(1)combined mass (M+m)
(2)total energy of the orbit ($\alpha$)
(3)reference (osculating) epoch (t0)
(4-6)position at reference epoch (${\rm \bf r}_0$)
(7-9)velocity at reference epoch (${\rm \bf v}_0$)
(10)heliocentric distance at reference epoch
(11)${\rm \bf r}_0.{\rm \bf v}_0$
(12)date (t)
(13)universal eccentric anomaly ($\psi$) of date, approx
   
JFORMRIrequested element set (1-3; Note 3)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
JFORMIelement set actually returned (1-3; Note 4)
EPOCHDepoch of elements (t0 or T, TT MJD)
ORBINCDinclination (i, radians)
ANODEDlongitude of the ascending node ($\Omega$, radians)
PERIHDlongitude or argument of perihelion +($\varpi$ or $\omega$,
radians)
AORQDmean distance or perihelion distance (a or q, AU)
EDeccentricity (e)
AORLDmean anomaly or longitude +(M or L, radians,
JFORM=1,2 only)
DMDdaily motion (n, radians, JFORM=1 only)
JSTATIstatus:
0 = OK
-1 = illegal PMASS
-2 = illegal JFORMR
-3 = position/velocity out of allowed range
+

+
NOTES: +
+
1. +
The ``universal'' elements are those which define the orbit for the +purposes of the method of universal variables (see reference 2). +They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i) $\alpha$, which is proportional to the total energy of the + orbit, (ii) the heliocentric distance at epoch, + (iii) the outwards component of the velocity at the given epoch, + (iv) an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v) that date. +
2. +
The universal elements are with respect to the mean equator and + equinox of epoch J2000. The orbital elements produced are with + respect to the J2000 ecliptic and mean equinox. +
3. +
Three different element-format options are supported, as + follows.
+

+JFORM=1, suitable for the major planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 longitude of perihelion $\varpi$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e < 1 )$ 
+		 AORL 		 = 		 mean longitude L (radians)
+		 DM 		 = 		 daily motion n (radians)        
+
+

+JFORM=2, suitable for minor planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e < 1 )$ 
+		 AORL 		 = 		 mean anomaly M (radians)        
+
+

+JFORM=3, suitable for comets: +


+ 		 EPOCH 		 = 		 epoch of perihelion T (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 perihelion distance q (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e \leq 10 )$
+
4. +
It may not be possible to generate elements in the form + requested through JFORMR. The caller is notified of the form + of elements actually returned by means of the JFORM argument: +


+ 		 JFORMR 		 JFORM 		 meaning 
+ 
+		      1 		      1 		 OK: elements are in the requested format
+		      1 		      2 		 never happens
+		      1 		      3 		 orbit not elliptical
+		      2 		      1 		 never happens
+		      2 		      2 		 OK: elements are in the requested format
+		      2 		      3 		 orbit not elliptical
+		      3 		      1 		 never happens
+		      3 		      2 		 never happens
+		      3 		      3 		 OK: elements are in the requested format        
+
+
5. +
The arguments returned for each value of JFORM (cf Note 5: + JFORM may not be the same as JFORMR) are as follows: +


+ 		 JFORM 		 1 		 2 		 3 
+ 
+		 EPOCH 		 t0 t0 T 
+		 ORBINC 		 i i i 
+		 ANODE 		 $\Omega$ $\Omega$ $\Omega$ 
+		 PERIH 		 $\varpi$ $\omega$ $\omega$ 
+		 AORQ 		 a a q 
+		 E 		 e e e 
+		 AORL 		 L M -
+		 DM 		 n - 		 -        
+
+

+where: +


+ 		 t0 is the epoch of the elements (MJD, TT)
+		 T is the epoch of perihelion (MJD, TT)
+		 i is the inclination (radians)
+		 $\Omega$ is the longitude of the ascending node (radians)
+		 $\varpi$ is the longitude of perihelion (radians)
+		 $\omega$ is the argument of perihelion (radians)
+		 a is the mean distance (AU)
+		 q is the perihelion distance (AU)
+		 e is the eccentricity
+		 L is the longitude (radians, $0-2\pi$)		 M is the mean anomaly (radians, $0-2\pi$)		 n is the daily motion (radians)
+		 - 		 means no value is set        
+
+
6. +
At very small inclinations, the longitude of the ascending node + ANODE becomes indeterminate and under some circumstances may be + set arbitrarily to zero. Similarly, if the orbit is close to + circular, the true anomaly becomes indeterminate and under some + circumstances may be set arbitrarily to zero. In such cases, + the other elements are automatically adjusted to compensate, + and so the elements remain a valid description of the orbit. +
+

+
REFERENCES: +
+
1. +
Sterne, Theodore E., An Introduction to Celestial Mechanics, +Interscience Publishers, 1960. Section 6.7, p199. +
2. +
Everhart, E. & Pitkin, E.T., Am. J. Phys. 51, 712, 1983. +
+

+ +next + +up + +previous +
+ Next: SLA_UE2PV - Pos/Vel from Universal Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_TPV2C - Plate centre from and x,y,z +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node188.html b/src/slalib/sun67.htx/node188.html new file mode 100644 index 0000000..bc0c8bd --- /dev/null +++ b/src/slalib/sun67.htx/node188.html @@ -0,0 +1,220 @@ + + + + +SLA_UE2PV - Pos/Vel from Universal Elements + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_UNPCD - Remove Radial Distortion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_UE2EL - Universal to Conventional Elements +

+

+

SLA_UE2PV - Pos/Vel from Universal Elements +   +

+
+
ACTION: +
Heliocentric position and velocity of a planet, asteroid or comet, +starting from orbital elements in the ``universal variables'' form. +

CALL: +
CALL sla_UE2PV (DATE, U, PV, JSTAT) +

+

+
GIVEN: +
+
+ + + + + +
DATEDdate (TT Modified Julian Date = JD-2400000.5)
+

+
GIVEN and RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
UD(13)universal orbital elements (updated; Note 1)
(1)combined mass (M+m)
(2)total energy of the orbit ($\alpha$)
(3)reference (osculating) epoch (t0)
(4-6)position at reference epoch (${\rm \bf r}_0$)
(7-9)velocity at reference epoch (${\rm \bf v}_0$)
(10)heliocentric distance at reference epoch
(11)${\rm \bf r}_0.{\rm \bf v}_0$
(12)date (t)
(13)universal eccentric anomaly ($\psi$) of date, approx
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
PVD(6)heliocentric $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$, equatorial, J2000
(AU, AU/s; Note 1)
JSTATIstatus:
0 = OK
-1 = radius vector zero
-2 = failed to converge
+

+
NOTES: +
+
1. +
The ``universal'' elements are those which define the orbit for the +purposes of the method of universal variables (see reference). +They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i) $\alpha$, which is proportional to the total energy of the + orbit, (ii) the heliocentric distance at epoch, + (iii) the outwards component of the velocity at the given epoch, + (iv) an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v) that date. +
2. +
The companion routine is sla_EL2UE. This takes the conventional + orbital elements and transforms them into the set of numbers + needed by the present routine. A single prediction requires one + one call to sla_EL2UE followed by one call to the present routine; + for convenience, the two calls are packaged as the routine + sla_PLANEL. Multiple predictions may be made by again + calling sla_EL2UE once, but then calling the present routine + multiple times, which is faster than multiple calls to sla_PLANEL. +

+It is not obligatory to use sla_EL2UE to obtain the parameters. + However, it should be noted that because sla_EL2UE performs its + own validation, no checks on the contents of the array U are made + by the present routine. +

3. +
DATE is the instant for which the prediction is required. It is + in the TT timescale (formerly Ephemeris Time, ET) and is a + Modified Julian Date (JD-2400000.5). +
4. +
The universal elements supplied in the array U are in canonical + units (solar masses, AU and canonical days). The position and + velocity are not sensitive to the choice of reference frame. The + sla_EL2UE routine in fact produces coordinates with respect to the + J2000 equator and equinox. +
5. +
The algorithm was originally adapted from the EPHSLA program of + D.H.P.Jones (private communication, 1996). The method + is based on Stumpff's Universal Variables. +
+

+
REFERENCE: +
Everhart, E. & Pitkin, E.T., Am. J. Phys. 51, 712, 1983. +
+

+ +next + +up + +previous +
+ Next: SLA_UNPCD - Remove Radial Distortion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_UE2EL - Universal to Conventional Elements +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node189.html b/src/slalib/sun67.htx/node189.html new file mode 100644 index 0000000..a19516f --- /dev/null +++ b/src/slalib/sun67.htx/node189.html @@ -0,0 +1,160 @@ + + + + +SLA_UNPCD - Remove Radial Distortion + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_V2TP - Direction Cosines to Tangent Plane +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_UE2PV - Pos/Vel from Universal Elements +

+

+

SLA_UNPCD - Remove Radial Distortion +   +

+
+
ACTION: +
Remove pincushion/barrel distortion from a distorted +$[\,x,y\,]$ to give tangent-plane $[\,x,y\,]$.

CALL: +
CALL sla_UNPCD (DISCO,X,Y) +

+

+
GIVEN: +
+
+ + + + + + + + + +
DISCODpincushion/barrel distortion coefficient
X,YDdistorted $[\,x,y\,]$
+

+
RETURNED: +
+
+ + + + + +
X,YDtangent-plane $[\,x,y\,]$
+

+
NOTES: +
+
1. +
The distortion is of the form $\rho = r (1 + c r^{2})$, where r is +the radial distance from the tangent point, c is the DISCO +argument, and $\rho$ is the radial distance in the presence of + the distortion. +
2. +
For pincushion distortion, C is +ve; for + barrel distortion, C is -ve. +
3. +
For X,Y in units of one projection radius (in the case of + a photographic plate, the focal length), the following + DISCO values apply: +


+
+
+

+ + + + + + + + + + + + + + + + + + + + + +
GeometryDISCO
astrograph0.0
Schmidt-0.3333
AAT PF doublet+147.069
AAT PF triplet+178.585
AAT f/8+21.20
JKT f/8+14.6
+


+
+
+

4. +
The present routine is an approximate inverse to the + companion routine sla_PCD, obtained from two iterations + of Newton's method. The mismatch between the sla_PCD + and sla_UNPCD is negligible for astrometric applications; + to reach 1 milliarcsec at the edge of the AAT triplet or + Schmidt field would require field diameters of $2^{\circ}
+ \hspace{-0.37em}.\hspace{0.02em}4$ and $42^{\circ}$ respectively. +
+

+ +next + +up + +previous +
+ Next: SLA_V2TP - Direction Cosines to Tangent Plane +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_UE2PV - Pos/Vel from Universal Elements +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node19.html b/src/slalib/sun67.htx/node19.html new file mode 100644 index 0000000..3a52cd9 --- /dev/null +++ b/src/slalib/sun67.htx/node19.html @@ -0,0 +1,160 @@ + + + + +SLA_AMPQK - Quick Apparent to Mean + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_AOP - Apparent to Observed +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AMP - Apparent to Mean +

+

+

SLA_AMPQK - Quick Apparent to Mean +   +

+
+
ACTION: +
Convert star $[\,\alpha,\delta\,]$ from geocentric apparent to mean place +(post IAU 1976). Use of this routine is appropriate when + efficiency is important and where many star positions are + all to be transformed for one epoch and equinox. The + star-independent parameters can be obtained by calling + the sla_MAPPA routine. +

CALL: +
CALL sla_AMPQK (RA, DA, AMPRMS, RM, DM) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
RA,DADapparent $[\,\alpha,\delta\,]$ (radians)
AMPRMSD(21)star-independent mean-to-apparent parameters:
(1)time interval for proper motion (Julian years)
(2-4)barycentric position of the Earth (AU)
(5-7)heliocentric direction of the Earth (unit vector)
(8)(gravitational radius of +Sun)$\times 2 / $(Sun-Earth distance)
(9-11)v: barycentric Earth velocity in units of c
(12)$\sqrt{1-\left\vert\mbox{\bf v}\right\vert^2}$
(13-21)precession/nutation $3\times3$ matrix
+

+
RETURNED: +
+
+ + + + + +
RM,DMDmean $[\,\alpha,\delta\,]$ (radians)
+

+
NOTES: +
+
1. +
The accuracy is limited by the routine sla_EVP, called +by sla_MAPPA, which computes the Earth position and +velocity using the methods of Stumpff. The maximum + error is about 0.3 milliarcsecond. +
2. +
Iterative techniques are used for the aberration and + light deflection corrections so that the routines + sla_AMP (or sla_AMPQK) and sla_MAP (or sla_MAPQK) are + accurate inverses; even at the edge of the Sun's disc + the discrepancy is only about 1 nanoarcsecond. +
+

+
REFERENCES: +
+
1. +
1984 Astronomical Almanac, pp B39-B41. +
2. +
Lederle & Schwan, 1984. Astr.Astrophys. 134, 1-6. +
+

+ +next + +up + +previous +
+ Next: SLA_AOP - Apparent to Observed +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AMP - Apparent to Mean +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node190.html b/src/slalib/sun67.htx/node190.html new file mode 100644 index 0000000..09def53 --- /dev/null +++ b/src/slalib/sun67.htx/node190.html @@ -0,0 +1,137 @@ + + + + +SLA_V2TP - Direction Cosines to Tangent Plane + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_VDV - Scalar Product +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_UNPCD - Remove Radial Distortion +

+

+

SLA_V2TP - Direction Cosines to Tangent Plane +   +

+
+
ACTION: +
Given the direction cosines of a star and of the tangent point, +determine the star's tangent-plane coordinates + (single precision). +

CALL: +
CALL sla_V2TP (V, V0, XI, ETA, J) +

+

+
GIVEN: +
+
+ + + + + + + + + +
VR(3)direction cosines of star
V0R(3)direction cosines of tangent point
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
XI,ETARtangent plane coordinates (radians)
JIstatus:
0 = OK, star on tangent plane
1 = error, star too far from axis
2 = error, antistar on tangent plane
3 = error, antistar too far from axis
+

+
NOTES: +
+
1. +
If vector V0 is not of unit length, or if vector V is of zero +length, the results will be wrong. +
2. +
If V0 points at a pole, the returned $\xi,\eta$ will be based on the + arbitrary assumption that $\alpha=0$ at the tangent point. +
3. +
The projection is called the gnomonic projection; the + Cartesian coordinates $[\,\xi,\eta\,]$ are called + standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
4. +
This routine is the Cartesian equivalent of the routine sla_S2TP. +
+

+ +next + +up + +previous +
+ Next: SLA_VDV - Scalar Product +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_UNPCD - Remove Radial Distortion +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node191.html b/src/slalib/sun67.htx/node191.html new file mode 100644 index 0000000..427bf46 --- /dev/null +++ b/src/slalib/sun67.htx/node191.html @@ -0,0 +1,91 @@ + + + + +SLA_VDV - Scalar Product + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_VN - Normalize Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_V2TP - Direction Cosines to Tangent Plane +

+

+

SLA_VDV - Scalar Product +   +

+
+
ACTION: +
Scalar product of two 3-vectors (single precision). +
CALL: +
R = sla_VDV (VA, VB) +

+

+
GIVEN: +
+
+ + + + + + + + + +
VAR(3)first vector
VBR(3)second vector
+

+
RETURNED: +
+
+ + + + + +
sla_VDVRscalar product VA.VB
+

+ +next + +up + +previous +
+ Next: SLA_VN - Normalize Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_V2TP - Direction Cosines to Tangent Plane +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node192.html b/src/slalib/sun67.htx/node192.html new file mode 100644 index 0000000..dd4d9b6 --- /dev/null +++ b/src/slalib/sun67.htx/node192.html @@ -0,0 +1,95 @@ + + + + +SLA_VN - Normalize Vector + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_VXV - Vector Product +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_VDV - Scalar Product +

+

+

SLA_VN - Normalize Vector +   +

+
+
ACTION: +
Normalize a 3-vector, also giving the modulus (single precision). +
CALL: +
CALL sla_VN (V, UV, VM) +

+

+
GIVEN: +
+
+ + + + + +
VR(3)vector
+

+
RETURNED: +
+
+ + + + + + + + + +
UVR(3)unit vector in direction of V
VMRmodulus of V
+

+
NOTE: +
If the modulus of V is zero, UV is set to zero as well. +
+

+ +next + +up + +previous +
+ Next: SLA_VXV - Vector Product +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_VDV - Scalar Product +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node193.html b/src/slalib/sun67.htx/node193.html new file mode 100644 index 0000000..8f27978 --- /dev/null +++ b/src/slalib/sun67.htx/node193.html @@ -0,0 +1,93 @@ + + + + +SLA_VXV - Vector Product + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_WAIT - Time Delay +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_VN - Normalize Vector +

+

+

SLA_VXV - Vector Product +   +

+
+
ACTION: +
Vector product of two 3-vectors (single precision). +
CALL: +
CALL sla_VXV (VA, VB, VC) +

+

+
GIVEN: +
+
+ + + + + + + + + +
VAR(3)first vector
VBR(3)second vector
+

+
RETURNED: +
+
+ + + + + +
VCR(3)vector product VA$\times$VB
+

+ +next + +up + +previous +
+ Next: SLA_WAIT - Time Delay +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_VN - Normalize Vector +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node194.html b/src/slalib/sun67.htx/node194.html new file mode 100644 index 0000000..55a0ed7 --- /dev/null +++ b/src/slalib/sun67.htx/node194.html @@ -0,0 +1,91 @@ + + + + +SLA_WAIT - Time Delay + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_XY2XY - Apply Linear Model to an +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_VXV - Vector Product +

+

+

SLA_WAIT - Time Delay +   +

+
+
ACTION: +
Wait for a specified interval. +
CALL: +
CALL sla_WAIT (DELAY) +

+

+
GIVEN: +
+
+ + + + + +
DELAYRdelay in seconds
+

+
NOTES: +
+
1. +
The implementation is machine-specific. +
2. +
The delay actually requested is restricted to the range +100ns-200s in the present implementation. +
3. +
There is no guarantee of accuracy, though on almost all + types of computer the program will certainly not + resume execution before the stated interval has + elapsed. +
+

+ +next + +up + +previous +
+ Next: SLA_XY2XY - Apply Linear Model to an +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_VXV - Vector Product +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node195.html b/src/slalib/sun67.htx/node195.html new file mode 100644 index 0000000..2b33ece --- /dev/null +++ b/src/slalib/sun67.htx/node195.html @@ -0,0 +1,114 @@ + + + + +SLA_XY2XY - Apply Linear Model to an + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_ZD - to Zenith Distance +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_WAIT - Time Delay +

+

+

    +
+SLA_XY2XY - Apply Linear Model to an $[\,x,y\,]$

+
+
ACTION: +
Transform one $[\,x,y\,]$ into another using a linear model of the type +produced by the sla_FITXY routine. +

CALL: +
CALL sla_XY2XY (X1,Y1,COEFFS,X2,Y2) +

+

+
GIVEN: +
+
+ + + + + + + + + +
X1,Y1D$[\,x,y\,]$ before transformation
COEFFSD(6)transformation coefficients (see note)
+

+
RETURNED: +
+
+ + + + + +
X2,Y2D$[\,x,y\,]$ after transformation
+

+
NOTES: +
+
1. +
The model relates two sets of $[\,x,y\,]$ coordinates as follows. +Naming the six elements of COEFFS a,b,c,d,e & f, +the present routine performs the transformation: +
x2 = a + bx1 + cy1
+ y2 = d + ex1 + fy1
+
2. +
See also sla_FITXY, sla_PXY, sla_INVF, sla_DCMPF. +
+

+ +next + +up + +previous +
+ Next: SLA_ZD - to Zenith Distance +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_WAIT - Time Delay +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node196.html b/src/slalib/sun67.htx/node196.html new file mode 100644 index 0000000..0dc168b --- /dev/null +++ b/src/slalib/sun67.htx/node196.html @@ -0,0 +1,137 @@ + + + + +SLA_ZD - to Zenith Distance + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: EXPLANATION AND EXAMPLES +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_XY2XY - Apply Linear Model to an +

+

+

    +
+SLA_ZD - $h,\delta$ to Zenith Distance +

+
+
ACTION: +
Hour angle and declination to zenith distance +(double precision). +

CALL: +
D = sla_ZD (HA, DEC, PHI) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
HADhour angle in radians
DECDdeclination in radians
PHIDlatitude in radians
+

+
RETURNED: +
+
+ + + + + +
sla_ZDDzenith distance (radians, $0\!-\!\pi$)
+

+
NOTES: +
+
1. +
The latitude must be geodetic. In critical applications, +corrections for polar motion should be applied (see sla_POLMO). +
2. +
In some applications it will be important to specify the + correct type of hour angle and declination in order to + produce the required type + of zenith distance. In particular, it may be + important to distinguish between the zenith distance + as affected by refraction, which would require the + observed $[\,h,\delta\,]$, and the zenith distance in vacuo, + which would require the topocentric $[\,h,\delta\,]$. If + the effects of diurnal aberration can be neglected, the + apparent $[\,h,\delta\,]$ may be used instead of the + topocentric $[\,h,\delta\,]$.
3. +
No range checking of arguments is done. +
4. +
In applications which involve many zenith distance calculations, + rather than calling the present routine it will be more + efficient to use inline code, having previously computed fixed + terms such as sine and cosine of latitude, and perhaps sine and + cosine of declination. +
+

+
+

+


+ +next + +up + +previous +
+ Next: EXPLANATION AND EXAMPLES +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_XY2XY - Apply Linear Model to an +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node197.html b/src/slalib/sun67.htx/node197.html new file mode 100644 index 0000000..ae8cd55 --- /dev/null +++ b/src/slalib/sun67.htx/node197.html @@ -0,0 +1,171 @@ + + + + +EXPLANATION AND EXAMPLES + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Spherical Trigonometry +
+Up: SLALIB Positional Astronomy Library +
+ Previous: SLA_ZD - to Zenith Distance +

+

+

+EXPLANATION AND EXAMPLES +

+To guide the writer of positional-astronomy applications software, +this final chapter puts the SLALIB routines into the context of +astronomical phenomena and techniques, and presents a few +``cookbook'' examples +of the SLALIB calls in action. The astronomical content of the chapter +is not, of course, intended to be a substitute for specialist text-books on +positional astronomy, but may help bridge the gap between +such books and the SLALIB routines. For further reading, the following +cover a wide range of material and styles: + +Also of considerable value, though out of date in places, are: + +Only brief details of individual SLALIB routines are given here, and +readers will find it useful to refer to the subprogram specifications +elsewhere in this document. The source code for the SLALIB routines +(available in both Fortran and C) is also intended to be used as +documentation. +

+


+ +  + + +

+ +next + +up + +previous +
+ Next: Spherical Trigonometry +
+Up: SLALIB Positional Astronomy Library +
+ Previous: SLA_ZD - to Zenith Distance +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node198.html b/src/slalib/sun67.htx/node198.html new file mode 100644 index 0000000..30aa3e8 --- /dev/null +++ b/src/slalib/sun67.htx/node198.html @@ -0,0 +1,167 @@ + + + + +Spherical Trigonometry + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Formatting angles +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: EXPLANATION AND EXAMPLES +

+

+

+Spherical Trigonometry +

+Celestial phenomena occur at such vast distances from the +observer that for most practical purposes there is no need to +work in 3D; only the direction +of a source matters, not how far away it is. Things can +therefore be viewed as if they were happening +on the inside of sphere with the observer at the centre - +the celestial sphere. Problems involving +positions and orientations in the sky can then be solved by +using the formulae of spherical trigonometry, which +apply to spherical triangles, the sides of which are +great circles. +

+Positions on the celestial sphere may be specified by using +a spherical polar coordinate system, defined in terms of +some fundamental plane and a line in that plane chosen to +represent zero longitude. Mathematicians usually work with the +co-latitude, with zero at the principal pole, whereas most +astronomical coordinate systems use latitude, reckoned plus and +minus from the equator. +Astronomical coordinate systems may be either right-handed +(e.g. right ascension and declination $[\,\alpha,\delta\,]$,Galactic longitude and latitude $[\,l^{I\!I},b^{I\!I}\,]$)or left-handed (e.g. hour angle and +declination $[\,h,\delta\,]$). In some cases +different conventions have been used in the past, a fruitful source of +mistakes. Azimuth and geographical longitude are examples; azimuth +is now generally reckoned north through east +(making a left-handed system); geographical longitude is now usually +taken to increase eastwards (a right-handed system) but astronomers +used to employ a west-positive convention. In reports +and program comments it is wise to spell out what convention +is being used, if there is any possibility of confusion. +

+When applying spherical trigonometry formulae, attention must be +paid to +rounding errors (for example it is a bad idea to find a +small angle through its cosine) and to the possibility of +problems close to poles. +Also, if a formulation relies on inspection to establish +the quadrant of the result, it is an indication that a vector-related +method might be preferable. +

+As well as providing many routines which work in terms of specific +spherical coordinates such as $[\,\alpha,\delta\,]$, SLALIB provides +two routines which operate directly on generic spherical +coordinates: +sla_SEP +computes the separation between +two points (the distance along a great circle) and +sla_BEAR +computes the bearing (or position angle) +of one point seen from the other. The routines +sla_DSEP +and +sla_DBEAR +are double precision equivalents. As a simple demonstration +of SLALIB, we will use these facilities to estimate the distance from +London to Sydney and the initial compass heading: +

+            IMPLICIT NONE
+
+      *  Degrees to radians
+            REAL D2R
+            PARAMETER (D2R=0.01745329252)
+
+      *  Longitudes and latitudes (radians) for London and Sydney
+            REAL AL,BL,AS,BS
+            PARAMETER (AL=-0.2*D2R,BL=51.5*D2R,AS=151.2*D2R,BS=-33.9*D2R)
+
+      *  Earth radius in km (spherical approximation)
+            REAL RKM
+            PARAMETER (RKM=6375.0)
+
+            REAL sla_SEP,sla_BEAR
+
+
+      *  Distance and initial heading (N=0, E=90)
+            WRITE (*,'(1X,I5,'' km,'',I4,'' deg'')')
+           :    NINT(sla_SEP(AL,BL,AS,BS)*RKM),NINT(sla_BEAR(AL,BL,AS,BS)/D2R)
+
+            END
+
+

(The result is 17011 km, $61^\circ$.) +

+The routines +sla_PAV and +sla_DPAV +are equivalents of sla_BEAR and sla_DBEAR but starting from +direction-cosines instead of spherical coordinates. +

+


+ +  + + +

+ +next + +up + +previous +
+ Next: Formatting angles +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: EXPLANATION AND EXAMPLES +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node199.html b/src/slalib/sun67.htx/node199.html new file mode 100644 index 0000000..93a4839 --- /dev/null +++ b/src/slalib/sun67.htx/node199.html @@ -0,0 +1,174 @@ + + + + +Formatting angles + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Vectors and Matrices +
+Up: Spherical Trigonometry +
+ Previous: Spherical Trigonometry +

+

+

+Formatting angles +

+SLALIB has routines for decoding decimal numbers +from character form and for converting angles to and from +sexagesimal form (hours, minutes, seconds or degrees, +arcminutes, arcseconds). These apparently straightforward +operations contain hidden traps which the SLALIB routines +avoid. +

+There are five routines for decoding numbers from a character +string, such as might be entered using a keyboard. +They all work in the same style, and successive calls +can work their way along a single string decoding +a sequence of numbers of assorted types. Number +fields can be separated by spaces or commas, and can be defaulted +to previous values or to preset defaults. +

+Three of the routines decode single numbers: +sla_INTIN +(integer), +sla_FLOTIN +(single precision floating point) and +sla_DFLTIN +(double precision). A minus sign can be +detected even when the number is zero; this avoids +the frequently-encountered ``minus zero'' bug, where +declinations etc. in +the range $0^{\circ}$ to $-1^{\circ}$ mysteriously migrate to +the range $0^{\circ}$ to $+1^{\circ}$.Here is an example (in Fortran) where we wish to +read two numbers, and integer IX and a real, Y, +with X defaulting to zero and Y defaulting to +X: +

+            DOUBLE PRECISION Y
+            CHARACTER*80 A
+            INTEGER IX,I,J
+
+      *  Input the string to be decoded
+            READ (*,'(A)') A
+
+      *  Preset IX to its default value
+            IX = 0
+
+      *  Point to the start of the string
+            I = 1
+
+      *  Decode an integer
+            CALL sla_INTIN(A,I,IX,J)
+            IF (J.GT.1) GO TO ... (bad IX)
+
+      *  Preset Y to its default value
+            Y = DBLE(IX)
+
+      *  Decode a double precision number
+            CALL sla_DFLTIN(A,I,Y,J)
+            IF (J.GT.1) GO TO ... (bad Y)
+
+

+Two additional routines decode a 3-field sexagesimal number: +sla_AFIN +(degrees, arcminutes, arcseconds to single +precision radians) and +sla_DAFIN +(the same but double precision). They also +work using other units such as hours etc. if +you multiply the result by the appropriate factor. An example +Fortran program which uses +sla_DAFIN +was given earlier, in section 1.2. +

+SLALIB provides four routines for expressing an angle in radians +in a preferred range. The function +sla_RANGE +expresses an angle +in the range $\pm \pi$;sla_RANORM +expresses an angle in the range +$0-2\pi$. The functions +sla_DRANGE +and +sla_DRANRM +are double precision versions. +

+Several routines +(sla_CTF2D, +sla_CR2AF +etc.) are provided to convert +angles to and from +sexagesimal form (hours, minute, seconds or degrees, +arcminutes and arcseconds). +They avoid the common +``converting from integer to real at the wrong time'' +bug, which produces angles like $24^{h}\,59^{m}\,59^{s}.999$.Here is a program which displays an hour angle +stored in radians: +

+            DOUBLE PRECISION HA
+            CHARACTER SIGN
+            INTEGER IHMSF(4)
+            :
+            CALL sla_DR2TF(3,HA,SIGN,IHMSF)
+            WRITE (*,'(1X,A,3I3.2,''.'',I3.3)') SIGN,IHMSF
+
+

+


+ +next + +up + +previous +
+ Next: Vectors and Matrices +
+Up: Spherical Trigonometry +
+ Previous: Spherical Trigonometry +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node2.html b/src/slalib/sun67.htx/node2.html new file mode 100644 index 0000000..2e1859d --- /dev/null +++ b/src/slalib/sun67.htx/node2.html @@ -0,0 +1,85 @@ + + + + +INTRODUCTION + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Purpose +
+Up: SLALIB Positional Astronomy Library +
+ Previous: Abstract +

+

+

+INTRODUCTION +

+

+ +  + + +

+ +next + +up + +previous +
+ Next: Purpose +
+Up: SLALIB Positional Astronomy Library +
+ Previous: Abstract +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node20.html b/src/slalib/sun67.htx/node20.html new file mode 100644 index 0000000..e544154 --- /dev/null +++ b/src/slalib/sun67.htx/node20.html @@ -0,0 +1,320 @@ + + + + +SLA_AOP - Apparent to Observed + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_AOPPA - Appt-to-Obs Parameters +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AMPQK - Quick Apparent to Mean +

+

+

SLA_AOP - Apparent to Observed +   +

+
+
ACTION: +
Apparent to observed place, for optical sources distant from +the solar system. +

CALL: +
CALL sla_AOP ( + RAP, DAP, DATE, DUT, ELONGM, PHIM, HM, XP, YP, + TDK, PMB, RH, WL, TLR, AOB, ZOB, HOB, DOB, ROB) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
RAP,DAPDgeocentric apparent $[\,\alpha,\delta\,]$ (radians)
DATEDUTC date/time (Modified Julian Date, JD-2400000.5)
DUTD$\Delta$UT: UT1-UTC (UTC seconds)
ELONGMDobserver's mean longitude (radians, east +ve)
PHIMDobserver's mean geodetic latitude (radians)
HMDobserver's height above sea level (metres)
XP,YPDpolar motion $[\,x,y\,]$ coordinates (radians)
TDKDlocal ambient temperature (degrees K; std=273.155D0)
PMBDlocal atmospheric pressure (mB; std=1013.25D0)
RHDlocal relative humidity (in the range 0D0-1D0)
WLDeffective wavelength ($\mu{\rm m}$, e.g. 0.55D0)
TLRDtropospheric lapse rate (degrees K per metre, +e.g. 0.0065D0)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + +
AOBDobserved azimuth (radians: N=0, E=$90^{\circ}$)
ZOBDobserved zenith distance (radians)
HOBDobserved Hour Angle (radians)
DOBDobserved $\delta$ (radians)
ROBDobserved $\alpha$ (radians)
+

+
NOTES: +
+
1. +
This routine returns zenith distance rather than elevation +in order to reflect the fact that no allowance is made for +depression of the horizon. +
2. +
The accuracy of the result is limited by the corrections for + refraction. Providing the meteorological parameters are + known accurately and there are no gross local effects, the + predicted azimuth and elevation should be within about +

$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$ for $\zeta<70^{\circ}$. Even + at a topocentric zenith distance of + $90^{\circ}$, the accuracy in elevation should be better than + 1 arcminute; useful results are available for a further + $3^{\circ}$, beyond which the sla_REFRO routine returns a + fixed value of the refraction. The complementary + routines sla_AOP (or sla_AOPQK) and sla_OAP (or sla_OAPQK) + are self-consistent to better than 1 microarcsecond all over + the celestial sphere. +

3. +
It is advisable to take great care with units, as even + unlikely values of the input parameters are accepted and + processed in accordance with the models used. +
4. +
Apparent $[\,\alpha,\delta\,]$ means the geocentric apparent right ascension + and declination, which is obtained from a catalogue mean place + by allowing for space motion, parallax, precession, nutation, + annual aberration, and the Sun's gravitational lens effect. For + star positions in the FK5 system (i.e. J2000), these effects can + be applied by means of the sla_MAP etc. routines. Starting from + other mean place systems, additional transformations will be + needed; for example, FK4 (i.e. B1950) mean places would first + have to be converted to FK5, which can be done with the + sla_FK425 etc. routines. +
5. +
Observed $[\,Az,El~]$ means the position that would be seen by a + perfect theodolite located at the observer. This is obtained + from the geocentric apparent $[\,\alpha,\delta\,]$ by allowing for Earth + orientation and diurnal aberration, rotating from equator + to horizon coordinates, and then adjusting for refraction. + The $[\,h,\delta\,]$ is obtained by rotating back into equatorial + coordinates, using the geodetic latitude corrected for polar + motion, and is the position that would be seen by a perfect + equatorial located at the observer and with its polar axis + aligned to the Earth's axis of rotation (n.b. not to the + refracted pole). Finally, the $\alpha$ is obtained by subtracting + the h from the local apparent ST. +
6. +
To predict the required setting of a real telescope, the + observed place produced by this routine would have to be + adjusted for the tilt of the azimuth or polar axis of the + mounting (with appropriate corrections for mount flexures), + for non-perpendicularity between the mounting axes, for the + position of the rotator axis and the pointing axis relative + to it, for tube flexure, for gear and encoder errors, and + finally for encoder zero points. Some telescopes would, of + course, exhibit other properties which would need to be + accounted for at the appropriate point in the sequence. +
7. +
This routine takes time to execute, due mainly to the + rigorous integration used to evaluate the refraction. + For processing multiple stars for one location and time, + call sla_AOPPA once followed by one call per star to sla_AOPQK. + Where a range of times within a limited period of a few hours + is involved, and the highest precision is not required, call + sla_AOPPA once, followed by a call to sla_AOPPAT each time the + time changes, followed by one call per star to sla_AOPQK. +
8. +
The DATE argument is UTC expressed as an MJD. This is, + strictly speaking, wrong, because of leap seconds. However, + as long as the $\Delta$UT and the UTC are consistent there + are no difficulties, except during a leap second. In this + case, the start of the 61st second of the final minute should + begin a new MJD day and the old pre-leap $\Delta$UT should + continue to be used. As the 61st second completes, the MJD + should revert to the start of the day as, simultaneously, + the $\Delta$UT changes by one second to its post-leap new value. +
9. +
The $\Delta$UT (UT1-UTC) is tabulated in IERS circulars and + elsewhere. It increases by exactly one second at the end of + each UTC leap second, introduced in order to keep $\Delta$UT + within $\pm$$0^{\rm s}\hspace{-0.3em}.9$.
10. +
IMPORTANT - TAKE CARE WITH THE LONGITUDE SIGN CONVENTION. The + longitude required by the present routine is east-positive, + in accordance with geographical convention (and right-handed). + In particular, note that the longitudes returned by the + sla_OBS routine are west-positive (as in the Astronomical + Almanac before 1984) and must be reversed in sign before use + in the present routine. +
11. +
The polar coordinates XP,YP can be obtained from IERS + circulars and equivalent publications. The + maximum amplitude is about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$ . If XP,YP values + are unavailable, use XP=YP=0D0. See page B60 of the 1988 + Astronomical Almanac for a definition of the two angles. +
12. +
The height above sea level of the observing station, HM, + can be obtained from the Astronomical Almanac (Section J + in the 1988 edition), or via the routine sla_OBS. If P, + the pressure in mB, is available, an adequate + estimate of HM can be obtained from the following expression: +
HM=-29.3D0*TSL*LOG(P/1013.25D0) +
+ where TSL is the approximate sea-level air temperature in degrees K + (see Astrophysical Quantities, C.W.Allen, 3rd edition, + §52). Similarly, if the pressure P is not known, + it can be estimated from the height of the observing + station, HM as follows: +
P=1013.25D0*EXP(-HM/(29.3D0*TSL)) +
+ Note, however, that the refraction is proportional to the + pressure and that an accurate P value is important for + precise work. +
13. +
The azimuths etc. used by the present routine are with + respect to the celestial pole. Corrections to the terrestrial pole + can be computed using sla_POLMO. +
+

+ +next + +up + +previous +
+ Next: SLA_AOPPA - Appt-to-Obs Parameters +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AMPQK - Quick Apparent to Mean +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node200.html b/src/slalib/sun67.htx/node200.html new file mode 100644 index 0000000..cbbad9d --- /dev/null +++ b/src/slalib/sun67.htx/node200.html @@ -0,0 +1,168 @@ + + + + +Vectors and Matrices + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Using vectors +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Formatting angles +

+

+

+Vectors and Matrices +

+As an alternative to employing a spherical polar coordinate system, +the direction of an object can be defined in terms of the sum of any +three vectors as long as they are different and +not coplanar. In practice, three vectors at right angles are +usually chosen, forming a system +of Cartesian coordinates. The x- and y-axes +lie in the fundamental plane (e.g. the equator in the +case of $[\,\alpha,\delta\,]$), with the x-axis pointing to zero longitude. +The z-axis is normal to the fundamental plane and points +towards positive latitudes. The y-axis can lie in either +of the two possible directions, depending on whether the +coordinate system is right-handed or left-handed. +The three axes are sometimes called +a triad. For most applications involving arbitrarily +distant objects such as stars, the vector which defines +the direction concerned is constrained to have unit length. +The x-, y- and z-components +can be regarded as the scalar (dot) product of this vector +onto the three axes of the triad in turn. Because the vector +is a unit vector, +each of the three dot-products is simply the cosine of the angle +between the unit vector and the axis concerned, and the +x-, y- and z-components are sometimes +called direction cosines. +

+For some applications involving objects +with the Solar System, unit vectors are inappropriate, and +it is necessary to use vectors scaled in length-units such as +AU, km etc. +In these cases the origin of the coordinate system may not be +the observer, but instead might be the Sun, the Solar-System +barycentre, the centre of the Earth etc. But whatever the application, +the final direction in which the observer sees the object can be +expressed as direction cosines. +

+But where has this got us? Instead of two numbers - a longitude and +a latitude - we now have three numbers to look after +- the x-, y- and +z-components - whose quadratic sum we have somehow to contrive to +be unity. And, in addition to this apparent redundancy, +most people find it harder to visualize +problems in terms of $[\,x,y,z\,]$ than in $[\,\theta,\phi~]$.Despite these objections, the vector approach turns out to have +significant advantages over the spherical trigonometry approach: +

+A number of important transformations in positional +astronomy turn out to be nothing more than changes of coordinate +system, something which is especially convenient if +the vector approach is used. A direction with respect +to one triad can be expressed relative to another triad simply +by multiplying the $[\,x,y,z\,]$ column vector by the appropriate +$3\times3$ orthogonal matrix +(a tensor of Rank 2, or dyadic). The three rows of this +rotation matrix +are the vectors in the old coordinate system of the three +new axes, and the transformation amounts to obtaining the +dot-product of the direction-vector with each of the three +new axes. Precession, nutation, $[\,h,\delta\,]$ to $[\,Az,El~]$,$[\,\alpha,\delta\,]$ to $[\,l^{I\!I},b^{I\!I}\,]$ and so on are typical examples of the +technique. A useful property of the rotation matrices +is that they can be inverted simply by taking the transpose. +

+The elements of these vectors and matrices are assorted combinations of +the sines and cosines of the various angles involved (hour angle, +declination and so on, depending on which transformation is +being applied). If you write out the matrix multiplications +in full you get expressions which are essentially the same as the +equivalent spherical trigonometry formulae. Indeed, many of the +standard formulae of spherical trigonometry are most easily +derived by expressing the problem initially in +terms of vectors. +

+


+ +  + + +

+ +next + +up + +previous +
+ Next: Using vectors +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Formatting angles +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node201.html b/src/slalib/sun67.htx/node201.html new file mode 100644 index 0000000..4613125 --- /dev/null +++ b/src/slalib/sun67.htx/node201.html @@ -0,0 +1,215 @@ + + + + +Using vectors + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Celestial Coordinate Systems +
+Up: Vectors and Matrices +
+ Previous: Vectors and Matrices +

+

+

+Using vectors +

+SLALIB provides conversions between spherical and vector +form +(sla_CS2C, +sla_CC2S +etc.), plus an assortment +of standard vector and matrix operations +(sla_VDV, +sla_MXV +etc.). +There are also routines +(sla_EULER +etc.) for creating a rotation matrix +from three Euler angles (successive rotations about +specified Cartesian axes). Instead of Euler angles, a rotation +matrix can be expressed as an axial vector (the pole of the rotation, +and the amount of rotation), and routines are provided for this +(sla_AV2M, +sla_M2AV +etc.). +

+Here is an example where spherical coordinates P1 and Q1 +undergo a coordinate transformation and become P2 and Q2; +the transformation consists of a rotation of the coordinate system +through angles A, B and C about the +z, new y and new z axes respectively: +

+            REAL A,B,C,R(3,3),P1,Q1,V1(3),V2(3),P2,Q2
+             :
+      *  Create rotation matrix
+            CALL sla_EULER('ZYZ',A,B,C,R)
+
+      *  Transform position (P,Q) from spherical to Cartesian
+            CALL sla_CS2C(P1,Q1,V1)
+
+      *  Multiply by rotation matrix
+            CALL sla_MXV(R,V1,V2)
+
+      *  Back to spherical
+            CALL sla_CC2S(V2,P2,Q2)
+
+

+Small adjustments to the direction of a position +vector are often most conveniently described in terms of +$[\,\Delta x,\Delta y, \Delta z\,]$. Adding the correction +vector needs careful handling if the position +vector is to remain of length unity, an advisable precaution which +ensures that +the $[\,x,y,z\,]$ components are always available to mean the cosines of +the angles between the vector and the axis concerned. Two types +of shifts are commonly used, +the first where a small vector of arbitrary direction is +added to the unit vector, and the second where there is a displacement +in the latitude coordinate (declination, elevation etc.) alone. +

+For a shift produced by adding a small $[\,x,y,z\,]$ vector ${\bf D}$ to a +unit vector ${\bf V1}$, the resulting vector ${\bf V2}$ has direction +$<{\bf V1}+{\bf D}\gt$ but is no longer of unit length. A better approximation +is available if the result is multiplied by a scaling factor of +$(1-{\bf D}\cdot{\bf V1})$, where the dot +means scalar product. In Fortran: +

+            F = (1D0-(DX*V1X+DY*V1Y+DZ*V1Z))
+            V2X = F*(V1X+DX)
+            V2Y = F*(V1Y+DY)
+            V2Z = F*(V1Z+DZ)
+
+

+The correction for diurnal aberration (discussed later) is +an example of this form of shift. +

+As an example of the second kind of displacement +we will apply a small change in elevation $\delta E$ to an +$[\,Az,El~]$ direction vector. The direction of the +result can be obtained by making the allowable approximation +${\tan \delta E\approx\delta E}$ and adding a adjustment +vector of length $\delta E$ normal +to the direction vector in the vertical plane containing the direction +vector. The z-component of the adjustment vector is +$\delta E \cos E$,and the horizontal component is +$\delta E \sin E$ which has then to be +resolved into x and y in proportion to their current sizes. To +approximate a unit vector more closely, a correction factor of +$\cos \delta E$ can then be applied, which is nearly +$(1-\delta E^2 /2)$ for +small $\delta E$. Expressed in Fortran, for initial vector +V1X,V1Y,V1Z, change in elevation DEL +(+ve $\equiv$ upwards), and result +vector V2X,V2Y,V2Z: +

+            COSDEL = 1D0-DEL*DEL/2D0
+            R1 = SQRT(V1X*V1X+V1Y*V1Y)
+            F = COSDEL*(R1-DEL*V1Z)/R1
+            V2X = F*V1X
+            V2Y = F*V1Y
+            V2Z = COSDEL*(V1Z+DEL*R1)
+
+

+An example of this type of shift is the correction for atmospheric +refraction (see later). +Depending on the relationship between $\delta E$ and E, special +handling at the pole (the zenith for our example) may be required. +

+SLALIB includes routines for the case where both a position +and a velocity are involved. The routines +sla_CS2C6 +and +sla_CC62S +convert from $[\theta,\phi,\dot{\theta},\dot{\phi}]$to $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ and back; +sla_DCS26 +and +sla_DC62S +are double precision equivalents. +

+


+ +next + +up + +previous +
+ Next: Celestial Coordinate Systems +
+Up: Vectors and Matrices +
+ Previous: Vectors and Matrices +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node202.html b/src/slalib/sun67.htx/node202.html new file mode 100644 index 0000000..a161c65 --- /dev/null +++ b/src/slalib/sun67.htx/node202.html @@ -0,0 +1,254 @@ + + + + +Celestial Coordinate Systems + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Precession and Nutation +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Using vectors +

+

+

+Celestial Coordinate Systems +

+SLALIB has routines to perform transformations +of celestial positions between different spherical +coordinate systems, including those shown in the following table: +

+

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
systemsymbolslongitudelatitudex-y planelong. zeroRH/LH
horizon-azimuthelevationhorizontalnorthL
equatorial$\alpha,\delta$R.A.Dec.equatorequinoxR
local equ.$h,\delta$H.A.Dec.equatormeridianL
ecliptic$\lambda,\beta$ecl. long.ecl. lat.eclipticequinoxR
galactic$l^{I\!I},b^{I\!I}$gal. long.gal. lat.gal. equatorgal. centreR
supergalacticSGL,SGBSG long.SG lat.SG equatornode w. gal. equ.R
+Transformations between $[\,h,\delta\,]$ and $[\,Az,El~]$ can be performed by +calling +sla_E2H +and +sla_H2E, +or, in double precision, +sla_DE2H +and +sla_DH2E. +There is also a routine for obtaining +zenith distance alone for a given $[\,h,\delta\,]$,sla_ZD, +and one for determining the parallactic angle, +sla_PA. +Three routines are included which relate to altazimuth telescope +mountings. For a given $[\,h,\delta\,]$ and latitude, +sla_ALTAZ +returns the azimuth, elevation and parallactic angle, plus +velocities and accelerations for sidereal tracking. +The routines +sla_PDA2H +and +sla_PDQ2H +predict at what hour angle a given azimuth or +parallactic angle will be reached. +

+The routines +sla_EQECL +and +sla_ECLEQ +transform between ecliptic +coordinates and $[\,\alpha,\delta\,]$; there is also a routine for generating the +equatorial to ecliptic rotation matrix for a given date: +sla_ECMAT. +

+For conversion between Galactic coordinates and $[\,\alpha,\delta\,]$ there are +two sets of routines, depending on whether the $[\,\alpha,\delta\,]$ is +old-style, B1950, or new-style, J2000; +sla_EG50 +and +sla_GE50 +are $[\,\alpha,\delta\,]$ to $[\,l^{I\!I},b^{I\!I}\,]$ and vice versa for the B1950 case, while +sla_EQGAL +and +sla_GALEQ +are the J2000 equivalents. +

+Finally, the routines +sla_GALSUP +and +sla_SUPGAL +transform $[\,l^{I\!I},b^{I\!I}\,]$ to de Vaucouleurs supergalactic longitude and latitude +and vice versa. +

+It should be appreciated that the table, above, constitutes +a gross oversimplification. Apparently +simple concepts such as equator, equinox etc. are apt to be very hard to +pin down precisely (polar motion, orbital perturbations ...) and +some have several interpretations, all subtly different. The various +frames move in complicated ways with respect to one another or to +the stars (themselves in motion). And in some instances the +coordinate system is slightly distorted, so that the +ordinary rules of spherical trigonometry no longer strictly apply. +

+These caveats +apply particularly to the bewildering variety of different +$[\,\alpha,\delta\,]$ systems that are in use. Figure 1 shows how +some of these systems are related, to one another and +to the direction in which a celestial source actually +appears in the sky. At the top of the diagram are +the various sorts of mean place +found in star catalogues and papers;[*] at the bottom is the +observed $[\,Az,El~]$, where a perfect theodolite would +be pointed to see the source; and in the body of +the diagram are +the intermediate processing steps and coordinate +systems. To help +understand this diagram, and the SLALIB routines that can +be used to carry out the various calculations, we will look at the coordinate +systems involved, and the astronomical phenomena that +affect them. +

+
+

  + + + +
Figure 1: +Relationship Between Celestial Coordinates
\begin{figure}
+\begin{center}
+\begin{tabular}
+{\vert cccccc\vert} \hline
+& & & &...
+ ...2000, all of the precession and E-terms corrections
+are superfluous.\end{figure}
+
+
+

+ +next + +up + +previous +
+ Next: Precession and Nutation +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Using vectors +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node203.html b/src/slalib/sun67.htx/node203.html new file mode 100644 index 0000000..fd18b48 --- /dev/null +++ b/src/slalib/sun67.htx/node203.html @@ -0,0 +1,187 @@ + + + + +Precession and Nutation + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLALIB support for precession and nutation +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Celestial Coordinate Systems +

+

+

+Precession and Nutation +

+Right ascension and declination, ($[\,\alpha,\delta\,]$), are the names +of the longitude and latitude in a spherical +polar coordinate system based on the Earth's axis of rotation. +The zero point of $\alpha$ is the point of intersection of +the celestial +equator and the ecliptic (the apparent path of the Sun +through the year) where the Sun moves into the northern +hemisphere. This point is called the +first point of Aries, +the vernal equinox (with apologies to +southern-hemisphere readers) or simply the equinox.[*] +

+This simple picture is unfortunately +complicated by the difficulty of defining +a suitable equator and equinox. One problem is that the +Sun's apparent motion is not completely regular, due to the +ellipticity of the Earth's orbit and its continuous disturbance +by the Moon and planets. This is dealt with by +separating the motion into (i) a smooth and steady mean Sun +and (ii) a set of periodic corrections and perturbations; only the former +is involved in establishing reference frames and timescales. +A second, far larger problem, is that +the celestial equator and the ecliptic +are both moving with respect to the stars. +These motions arise because of the gravitational +interactions between the Earth and the other solar-system bodies. +

+By far the largest effect is the +so-called ``precession of the equinoxes'', where the Earth's +rotation axis sweeps out a cone centred on the ecliptic +pole, completing one revolution in about 26,000 years. The +cause of the motion is the torque exerted on the distorted and +spinning Earth by the Sun and the Moon. Consider the effect of the +Sun alone, at or near the northern summer solstice. The Sun +`sees' the top (north pole) of the Earth tilted towards it +(by about $23^{\circ}
+ \hspace{-0.37em}.\hspace{0.02em}5$, the obliquity of the +ecliptic), +and sees the nearer part of the Earth's equatorial bulge +below centre and the further part above centre. +Although the Earth is in free fall, +the gravitational force on the nearer part of the +equatorial bulge is greater than that on the further part, and +so there is a net torque acting +as if to eliminate the tilt. Six months later the same thing +is happening in reverse, except that the torque is still +trying to eliminate the tilt. In between (at the equinoxes) the +torque shrinks to zero. A torque acting on a spinning body +is gyroscopically translated +into a precessional motion of the spin axis at right-angles to the torque, +and this happens to the Earth. +The motion varies during the +year, going through two maxima, but always acts in the +same direction. The Moon produces the same effect, +adding a contribution to the precession which peaks twice +per month. The Moon's proximity to the Earth more than compensates +for its smaller mass and gravitational attraction, so that it +in fact contributes most of the precessional effect. +

+The complex interactions between the three bodies produce a +precessional motion that is wobbly rather than completely smooth. +However, the main 26,000-year component is on such a grand scale that +it dwarfs the remaining terms, the biggest of +which has an amplitude of only $17\hspace{-0.05em}^{'\hspace{-0.1em}'}$ and a period of +about 18.6 years. This difference of scale makes it convenient to treat +these two components of the motion separately. The main 26,000-year +effect is called luni-solar precession; the smaller, +faster, periodic terms are called the nutation. +

+Note that precession and nutation are simply +different frequency components of the same physical effect. It is +a common misconception that precession is caused +by the Sun and nutation is caused by the Moon. In fact +the Moon is responsible for two-thirds of the precession, and, +while it is true that much of the complex detail of the nutation is +a reflection of the intricacies of the lunar orbit, there are +nonetheless important solar terms in the nutation. +

+In addition to and quite separate +from the precession/nutation effect, the orbit of the Earth-Moon system +is not fixed in orientation, a result of the attractions of the +planets. This slow (about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$  per year) +secular rotation of the ecliptic about a slowly-moving diameter is called, +confusingly, planetary +precession and, along with the luni-solar precession is +included in the general precession. The equator and +ecliptic as affected by general precession +are what define the various ``mean'' $[\,\alpha,\delta\,]$ reference frames. +

+The models for precession and nutation come from a combination +of observation and theory, and are subject to continuous +refinement. Nutation models in particular have reached a high +degree of sophistication, taking into account such things as +the non-rigidity of the Earth and the effects of +the planets; SLALIB's nutation +model (IAU 1980) involves 106 terms in each of $\psi$ (longitude) +and $\epsilon$ (obliquity), some as small as + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.0001$ . +

+


+ +  + + +

+ +next + +up + +previous +
+ Next: SLALIB support for precession and nutation +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Celestial Coordinate Systems +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node204.html b/src/slalib/sun67.htx/node204.html new file mode 100644 index 0000000..cc880e2 --- /dev/null +++ b/src/slalib/sun67.htx/node204.html @@ -0,0 +1,127 @@ + + + + +SLALIB support for precession and nutation + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Mean Places +
+Up: Precession and Nutation +
+ Previous: Precession and Nutation +

+

+

+SLALIB support for precession and nutation +

+SLALIB offers a choice of three precession models: + +In each case, the named SLALIB routine generates the $(3\times3)$precession +matrix for a given start and finish time. For example, +here is the Fortran code for generating the rotation +matrix which describes the precession between the epochs +J2000 and J1985.372 (IAU 1976 model): +

+            DOUBLE PRECISION PMAT(3,3)
+             :
+            CALL sla_PREC(2000D0,1985.372D0,PMAT)
+
+

+It is instructive to examine the resulting matrix: +

+            +0.9999936402  +0.0032709208  +0.0014214694
+            -0.0032709208  +0.9999946505  -0.0000023247
+            -0.0014214694  -0.0000023248  +0.9999989897
+
+

+Note that the diagonal elements are close to unity, and the +other elements are small. This shows that over an interval as +short as 15 years the precession isn't going to move a +position vector very far (in this case about $0^{\circ}
+ \hspace{-0.37em}.\hspace{0.02em}2$). +

+For convenience, a direct $[\,\alpha,\delta\,]$ to $[\,\alpha,\delta\,]$ precession routine is +also provided +(sla_PRECES), +suitable for either the old or the new system (but not a +mixture of the two). +

+SLALIB provides only one nutation model, the new, IAU 1980 model, +implemented in the routine +sla_NUTC. +This returns the components of nutation +in longitude and latitude (and also provides the obliquity) from +which a nutation matrix can be generated by calling +sla_DEULER +(and from which the equation of the equinoxes, described +later, can be found). Alternatively, +the nutation matrix can be generated in a single call by using +sla_NUT. +

+A rotation matrix for applying the entire precession/nutation +transformation in one go can be generated by calling +sla_PRENUT. +

+


+ +next + +up + +previous +
+ Next: Mean Places +
+Up: Precession and Nutation +
+ Previous: Precession and Nutation +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node205.html b/src/slalib/sun67.htx/node205.html new file mode 100644 index 0000000..6da5021 --- /dev/null +++ b/src/slalib/sun67.htx/node205.html @@ -0,0 +1,92 @@ + + + + +Mean Places + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Epoch +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: SLALIB support for precession and nutation +

+

+

+Mean Places +

+The main effect of the precession/nutation is a steady increase of about +$50\hspace{-0.05em}^{'\hspace{-0.1em}'}$/year in the ecliptic longitudes of the stars. It is therefore +essential, when reporting the position of an astronomical target, to +qualify the coordinates with a date, or epoch. +Specifying the epoch ties down the equator and +equinox which define the $[\,\alpha,\delta\,]$ coordinate system that is +being used. +[*] For simplicity, only +the smooth and steady ``general +precession'' part of the complete precession/nutation effect is +included, thereby defining what is called the mean +equator and equinox for the epoch concerned. We say a star +has a mean place of (for example) +$12^{h}\,07^{m}\,58^{s}.09$ $-19^{\circ}\,44^{'}\,37^{''}.1$ ``with respect to the mean equator +and equinox of epoch J2000''. The short way of saying +this is ``$[\,\alpha,\delta\,]$ equinox J2000'' (not ``$[\,\alpha,\delta\,]$ epoch J2000'', +which means something different to do with +proper motion). +

+


+ +next + +up + +previous +
+ Next: Epoch +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: SLALIB support for precession and nutation +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node206.html b/src/slalib/sun67.htx/node206.html new file mode 100644 index 0000000..9a94a3d --- /dev/null +++ b/src/slalib/sun67.htx/node206.html @@ -0,0 +1,125 @@ + + + + +Epoch + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Proper Motion +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Mean Places +

+

+

+Epoch +

+The word ``epoch'' just means a moment in time, and can be supplied +in a variety of forms, using different calendar systems and timescales. +

+For the purpose of specifying the epochs associated with the +mean place of a star, two conventions exist. Both sorts of epoch +superficially resemble years AD but are not tied to the civil +(Gregorian) calendar; to distinguish them from ordinary calendar-years +there is often +a ``.0'' suffix (as in ``1950.0''), although any other fractional +part is perfectly legal (e.g. 1987.5). +

+The older system, +Besselian epoch, is defined in such a way that its units are +tropical years of about 365.2422 days and its timescale is the +obsolete Ephemeris Time. +The start of the Besselian year is the moment +when the ecliptic longitude of the mean Sun is +$280^\circ$; this happens near the start of the +calendar year (which is why $280^\circ$ was chosen). +

+The new system, Julian epoch, was adopted as +part of the IAU 1976 revisions (about which more will be said +in due course) and came formally into use at the +beginning of 1984. It uses the Julian year of exactly +365.25 days; Julian epoch 2000 is defined to be 2000 January 1.5 in the +TT timescale. +

+For specifying mean places, various standard epochs are in use, the +most common ones being Besselian epoch 1950.0 and Julian epoch 2000.0. +To distinguish the two systems, Besselian epochs +are now prefixed ``B'' and Julian epochs are prefixed ``J''. +Epochs without an initial letter can be assumed to be Besselian +if before 1984.0, otherwise Julian. These details are supported by +the SLALIB routines +sla_DBJIN +(decodes numbers from a +character string, accepting an optional leading B or J), +sla_KBJ +(decides whether B or J depending on prefix or range) and +sla_EPCO +(converts one epoch to match another). +

+SLALIB has four routines for converting +Besselian and Julian epochs into other forms. +The functions +sla_EPB2D +and +sla_EPJ2D +convert Besselian and Julian epochs into MJD; the functions +sla_EPB +and +sla_EPJ +do the reverse. For example, to express B1950 as a Julian epoch: +

+            DOUBLE PRECISION sla_EPJ,sla_EPB2D
+             :
+            WRITE (*,'(1X,''J'',F10.5)') sla_EPJ(sla_EPB2D(1950D0))
+
+

(The answer is J1949.99979.) +

+


+ +next + +up + +previous +
+ Next: Proper Motion +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Mean Places +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node207.html b/src/slalib/sun67.htx/node207.html new file mode 100644 index 0000000..6c74c4e --- /dev/null +++ b/src/slalib/sun67.htx/node207.html @@ -0,0 +1,119 @@ + + + + +Proper Motion + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Parallax and Radial Velocity +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Epoch +

+

+

+Proper Motion +

+Stars in catalogues usually have, in addition to the +$[\,\alpha,\delta\,]$ coordinates, a proper motion $[\mu_\alpha,\mu_\delta]$.This is an intrinsic motion +of the star across the background. Very few stars have a +proper motion which exceeds $1\hspace{-0.05em}^{'\hspace{-0.1em}'}$/year, and most are +far below this level. A star observed as part of normal +astronomy research will, as a rule, have a proper motion +which is unknown. +

+Mean $[\,\alpha,\delta\,]$ and rate of change are not sufficient to pin +down a star; the epoch at which the $[\,\alpha,\delta\,]$ was or will +be correct is also needed. Note the distinction +between the epoch which specifies the +coordinate system and the epoch at which the star passed +through the given $[\,\alpha,\delta\,]$. The full specification for a star +is $[\,\alpha,\delta\,]$, proper motions, equinox and epoch (plus something to +identify which set of models for the precession etc. is +being used - see the next section). +For convenience, coordinates given in star catalogues are almost +always adjusted to make the equinox and epoch the same - for +example B1950 in the case of the SAO catalogue. +

+SLALIB provides one routine to handle proper motion on its own, +sla_PM. +Proper motion is also allowed for in various other +routines as appropriate, for example +sla_MAP +and +sla_FK425. +Note that in all SLALIB routines which involve proper motion +the units are radians per year and the +$\alpha$ component is in the form $\dot{\alpha}$ (i.e. big +numbers near the poles). +Some star catalogues have proper motion per century, and +in some catalogues the $\alpha$ component is in the form +$\dot{\alpha}\cos\delta$ (i.e. angle on the sky). +

+


+ +next + +up + +previous +
+ Next: Parallax and Radial Velocity +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Epoch +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node208.html b/src/slalib/sun67.htx/node208.html new file mode 100644 index 0000000..cc2b337 --- /dev/null +++ b/src/slalib/sun67.htx/node208.html @@ -0,0 +1,92 @@ + + + + +Parallax and Radial Velocity + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Aberration +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Proper Motion +

+

+

+Parallax and Radial Velocity +

+For the utmost accuracy and the nearest stars, allowance can +be made for annual parallax and for the effects of perspective +on the proper motion. +

+Parallax is appreciable only for nearby stars; even +the nearest, Proxima Centauri, is displaced from its average +position by less than +an arcsecond as the Earth revolves in its orbit. +

+For stars with a known parallax, knowledge of the radial velocity +allows the proper motion to be expressed as an actual space +motion in 3 dimensions. The proper motion is, +in fact, a snapshot of the transverse component of the +space motion, and in the case of nearby stars will +change with time due to perspective. +

+SLALIB does not provide facilities for handling parallax +and radial-velocity on their own, but their contribution is +allowed for in such routines as +sla_PM, +sla_MAP +and +sla_FK425. +Catalogue mean +places do not include the effects of parallax and are therefore +barycentric; when pointing telescopes etc. it is +usually most efficient to apply the slowly-changing +parallax correction to the mean place of the target early on +and to work with the geocentric mean place. This latter +approach is implied in Figure 1. +

+


+ +next + +up + +previous +
+ Next: Aberration +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Proper Motion +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node209.html b/src/slalib/sun67.htx/node209.html new file mode 100644 index 0000000..4790dda --- /dev/null +++ b/src/slalib/sun67.htx/node209.html @@ -0,0 +1,147 @@ + + + + +Aberration + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Different Sorts of Mean Place +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Parallax and Radial Velocity +

+

+

+Aberration +

+The finite speed of light combined with the motion of the observer +around the Sun during the year causes apparent displacements of +the positions of the stars. The effect is called +the annual aberration (or ``stellar'' +aberration). Its maximum size, about + $20\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$ , +occurs for stars $90^{\circ}$ from the point towards which +the Earth is headed as it orbits the Sun; a star exactly in line with +the Earth's motion is not displaced. To receive the light of +a star, the telescope has to be offset slightly in the direction of +the Earth's motion. A familiar analogy is the need to tilt your +umbrella forward when on the move, to avoid getting wet. This +Newtonian model is, +in fact, highly misleading in the context of light as opposed +to rain, but happens to give the same answer as a relativistic +treatment to first order (better than 1 milliarcsecond). +

+Before the IAU 1976 resolutions, different +values for the approximately +

$20\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$ aberration constant were employed +at different times, and this can complicate comparisons +between different catalogues. Another complication comes from +the so-called E-terms of aberration, +that small part of the annual aberration correction that is a +function of the eccentricity of the Earth's orbit. The E-terms, +maximum amplitude about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$ , +happen to be approximately constant for a given star, and so they +used to be incorporated in the catalogue $[\,\alpha,\delta\,]$to reduce the labour of converting to and from apparent place. +The E-terms can be removed from a catalogue $[\,\alpha,\delta\,]$ by +calling +sla_SUBET +or applied (for example to allow a pulsar +timing-position to be plotted on a B1950 finding chart) +by calling +sla_ADDET; +the E-terms vector itself can be obtained by calling +sla_ETRMS. +Star positions post IAU 1976 are free of these distortions, and to +apply corrections for annual aberration involves the actual +barycentric velocity of the Earth rather than the use of +canonical circular-orbit models. +

+The annual aberration is the aberration correction for +an imaginary observer at the Earth's centre. +The motion of a real observer around the Earth's rotation axis in +the course of the day makes a small extra contribution to the total +aberration effect called the diurnal aberration. Its +maximum amplitude is about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$ . +

+No SLALIB routine is provided for calculating the aberration on +its own, though the required velocity vectors can be +generated using +sla_EVP +and +sla_GEOC. +Annual and diurnal aberration are allowed for where required, for example in +sla_MAP +etc. and +sla_AOP +etc. Note that this sort +of aberration is different from the planetary +aberration, which is the apparent displacement of a solar-system +body, with respect to the ephemeris position, as a consequence +of the motion of both the Earth and the source. The +planetary aberration can be computed either by correcting the +position of the solar-system body for light-time, followed by +the ordinary stellar aberration correction, or more +directly by expressing the position and velocity of the source +in the observer's frame and correcting for light-time alone. +

+


+ +next + +up + +previous +
+ Next: Different Sorts of Mean Place +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Parallax and Radial Velocity +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node21.html b/src/slalib/sun67.htx/node21.html new file mode 100644 index 0000000..13ef3e2 --- /dev/null +++ b/src/slalib/sun67.htx/node21.html @@ -0,0 +1,264 @@ + + + + +SLA_AOPPA - Appt-to-Obs Parameters + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_AOPPAT - Update Appt-to-Obs Parameters +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AOP - Apparent to Observed +

+

+

SLA_AOPPA - Appt-to-Obs Parameters +   +

+
+
ACTION: +
Pre-compute the set of apparent to observed place parameters +required by the ``quick'' routines sla_AOPQK and sla_OAPQK. +

CALL: +
CALL sla_AOPPA ( + DATE, DUT, ELONGM, PHIM, HM, XP, YP, + TDK, PMB, RH, WL, TLR, AOPRMS) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
DATEDUTC date/time (Modified Julian Date, JD-2400000.5)
DUTD$\Delta$UT: UT1-UTC (UTC seconds)
ELONGMDobserver's mean longitude (radians, east +ve)
PHIMDobserver's mean geodetic latitude (radians)
HMDobserver's height above sea level (metres)
XP,YPDpolar motion $[\,x,y\,]$ coordinates (radians)
TDKDlocal ambient temperature (degrees K; std=273.155D0)
PMBDlocal atmospheric pressure (mB; std=1013.25D0)
RHDlocal relative humidity (in the range 0D0-1D0)
WLDeffective wavelength ($\mu{\rm m}$, e.g. 0.55D0)
TLRDtropospheric lapse rate (degrees K per metre, +e.g. 0.0065D0)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AOPRMSD(14)star-independent apparent-to-observed parameters:
(1)geodetic latitude (radians)
(2,3)sine and cosine of geodetic latitude
(4)magnitude of diurnal aberration vector
(5)height (HM)
(6)ambient temperature (TDK)
(7)pressure (PMB)
(8)relative humidity (RH)
(9)wavelength (WL)
(10)lapse rate (TLR)
(11,12)refraction constants A and B (radians)
(13)longitude + eqn of equinoxes + +``sidereal $\Delta$UT'' (radians)
(14)local apparent sidereal time (radians)
+

+
NOTES: +
+
1. +
It is advisable to take great care with units, as even +unlikely values of the input parameters are accepted and +processed in accordance with the models used. +
2. +
The DATE argument is UTC expressed as an MJD. This is, + strictly speaking, wrong, because of leap seconds. However, + as long as the $\Delta$UT and the UTC are consistent there + are no difficulties, except during a leap second. In this + case, the start of the 61st second of the final minute should + begin a new MJD day and the old pre-leap $\Delta$UT should + continue to be used. As the 61st second completes, the MJD + should revert to the start of the day as, simultaneously, + the $\Delta$UT changes by one second to its post-leap new value. +
3. +
The $\Delta$UT (UT1-UTC) is tabulated in IERS circulars and + elsewhere. It increases by exactly one second at the end of + each UTC leap second, introduced in order to keep $\Delta$UT + within $\pm$$0^{\rm s}\hspace{-0.3em}.9$. The ``sidereal $\Delta$UT'' which forms + part of AOPRMS(13) is the same quantity, but converted from solar + to sidereal seconds and expressed in radians. +
4. +
IMPORTANT - TAKE CARE WITH THE LONGITUDE SIGN CONVENTION. The + longitude required by the present routine is east-positive, + in accordance with geographical convention (and right-handed). + In particular, note that the longitudes returned by the + sla_OBS routine are west-positive (as in the Astronomical + Almanac before 1984) and must be reversed in sign before use in + the present routine. +
5. +
The polar coordinates XP,YP can be obtained from IERS + circulars and equivalent publications. The + maximum amplitude is about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$ . If XP,YP values + are unavailable, use XP=YP=0D0. See page B60 of the 1988 + Astronomical Almanac for a definition of the two angles. +
6. +
The height above sea level of the observing station, HM, + can be obtained from the Astronomical Almanac (Section J + in the 1988 edition), or via the routine sla_OBS. If P, + the pressure in mB, is available, an adequate + estimate of HM can be obtained from the following expression: +
HM=-29.3D0*TSL*LOG(P/1013.25D0) +
+ where TSL is the approximate sea-level air temperature in degrees K + (see Astrophysical Quantities, C.W.Allen, 3rd edition, + §52). Similarly, if the pressure P is not known, + it can be estimated from the height of the observing + station, HM as follows: +
P=1013.25D0*EXP(-HM/(29.3D0*TSL)) +
+ Note, however, that the refraction is proportional to the + pressure and that an accurate P value is important for + precise work. +
+

+ +next + +up + +previous +
+ Next: SLA_AOPPAT - Update Appt-to-Obs Parameters +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AOP - Apparent to Observed +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node210.html b/src/slalib/sun67.htx/node210.html new file mode 100644 index 0000000..1a8e19e --- /dev/null +++ b/src/slalib/sun67.htx/node210.html @@ -0,0 +1,177 @@ + + + + +Different Sorts of Mean Place + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Mean Place Transformations +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Aberration +

+

+

+Different Sorts of Mean Place +

+A particularly confusing aspect of published mean places is that they +are sensitive to the precise way they were determined. A mean +place is not directly observable, even with fundamental +instruments such as transit circles, and to produce a mean +place will involve relying on some existing star catalogue, +for example the fundamental catalogues FK4 and FK5, +and applying given mathematical models of precession, nutation, +aberration and so on. +Note in particular that no star catalogue, +even a fundamental catalogue such as FK4 or +FK5, defines a coordinate system, strictly speaking; +it is merely a list of star positions and proper motions. +However, once the stars from a given catalogue +are used as position calibrators, e.g. for +transit-circle observations or for plate reductions, then a +broader sense of there being a coordinate grid naturally +arises, and such phrases as ``in the system of +the FK4'' can legitimately be employed. However, +there is no formal link between the +two concepts - no ``standard least squares fit'' between +reality and the inevitably flawed catalogues.[*] All such +catalogues suffer at some level from systematic, zonal distortions +of both the star positions and of the proper motions, +and include measurement errors peculiar to individual +stars. +

+Many of these complications are of little significance except to +specialists. However, observational astronomers cannot +escape exposure to at least the two main varieties of +mean place, loosely called +FK4 and FK5, and should be aware of +certain pitfalls. For most practical purposes the more recent +system, FK5, is free of surprises and tolerates naive +use well. FK4, in contrast, contains two important traps: +

+The change from the old FK4-based system to FK5 +occurred at the beginning +of 1984 as part of a package of resolutions made by the IAU in 1976, +along with the adoption of J2000 as the reference epoch. Star +positions in the newer, FK5, system are free from the E-terms, and +the system is a much better approximation to an +inertial frame (about five times better). +

+It may occasionally be convenient to specify the FK4 fictitious proper +motion directly. In FK4, the centennial proper motion of (for example) +a QSO is: +

$\mu_\alpha=-$$0^{\rm s}\hspace{-0.3em}.015869$+(($0^{\rm s}\hspace{-0.3em}.029032$$~\sin \alpha
+ +$$0^{\rm s}\hspace{-0.3em}.000340$$~\cos \alpha ) \sin \delta
+ -$$0^{\rm s}\hspace{-0.3em}.000105$$~\cos \alpha
+ -$$0^{\rm s}\hspace{-0.3em}.000083$$~\sin \alpha ) \sec \delta $
+$\mu_\delta\,=+$ $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.43549$ $~\cos \alpha
+ -$ $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00510$ $~\sin \alpha +
+ ($ $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00158$ $~\sin \alpha
+ -$ $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00125$ $~\cos \alpha ) \sin \delta
+ -$ $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00066$ $~\cos \delta $ +


+ +next + +up + +previous +
+ Next: Mean Place Transformations +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Aberration +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node211.html b/src/slalib/sun67.htx/node211.html new file mode 100644 index 0000000..2a8cbee --- /dev/null +++ b/src/slalib/sun67.htx/node211.html @@ -0,0 +1,232 @@ + + + + +Mean Place Transformations + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Mean Place to Apparent Place +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Different Sorts of Mean Place +

+

+

+Mean Place Transformations +

+Figure 1 is based upon three varieties of mean $[\,\alpha,\delta\,]$ all of which are +of practical significance to observing astronomers in the present era: + +The figure outlines the steps required to convert positions in +any of these systems to a J2000 $[\,\alpha,\delta\,]$ for the current +epoch, as might be required in a telescope-control +program for example. +Most of the steps can be carried out by calling a single +SLALIB routines; there are other SLALIB routines which +offer set-piece end-to-end transformation routines for common cases. +Note, however, that SLALIB does not set out to provide the capability +for arbitrary transformations of star-catalogue data +between all possible systems of mean $[\,\alpha,\delta\,]$.Only in the (common) cases of FK4, equinox and epoch B1950, +to FK5, equinox and epoch J2000, and vice versa are +proper motion, parallax and radial velocity transformed +along with the star position itself, the +focus of SLALIB support. +

+As an example of using SLALIB to transform mean places, here is +a program which implements the top-left path of Figure 1. +An FK4 $[\,\alpha,\delta\,]$ of arbitrary equinox and epoch and with +known proper motion and +parallax is transformed into an FK5 J2000 $[\,\alpha,\delta\,]$ for the current +epoch. As a test star we will use $\alpha=$$16^{h}\,09^{m}\,55^{s}.13$,$\delta=$$-75^{\circ}\,59^{'}\,27^{''}.2$, equinox 1900, epoch 1963.087, +$\mu_\alpha=$$-0^{\rm s}\hspace{-0.3em}.0312$/y, $\mu_\delta=$ $+0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.103$ /y, +parallax = + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.062$ , radial velocity = -34.22 km/s. The +epoch of observation is 1994.35. +

+            IMPLICIT NONE
+            DOUBLE PRECISION AS2R,S2R
+            PARAMETER (AS2R=4.8481368110953599D-6,S2R=7.2722052166430399D-5)
+            INTEGER J,I
+            DOUBLE PRECISION R0,D0,EQ0,EP0,PR,PD,PX,RV,EP1,R1,D1,R2,D2,R3,D3,
+           :                 R4,D4,R5,D5,R6,D6,EP1D,EP1B,W(3),EB(3),PXR,V(3)
+            DOUBLE PRECISION sla_EPB,sla_EPJ2D
+
+      *  RA, Dec etc of example star
+            CALL sla_DTF2R(16,09,55.13D0,R0,J)
+            CALL sla_DAF2R(75,59,27.2D0,D0,J)
+            D0=-D0
+            EQ0=1900D0
+            EP0=1963.087D0
+            PR=-0.0312D0*S2R
+            PD=+0.103D0*AS2R
+            PX=0.062D0
+            RV=-34.22D0
+            EP1=1994.35D0
+
+      *  Epoch of observation as MJD and Besselian epoch
+            EP1D=sla_EPJ2D(EP1)
+            EP1B=sla_EPB(EP1D)
+
+      *  Space motion to the current epoch
+            CALL sla_PM(R0,D0,PR,PD,PX,RV,EP0,EP1B,R1,D1)
+
+      *  Remove E-terms of aberration for the original equinox
+            CALL sla_SUBET(R1,D1,EQ0,R2,D2)
+
+      *  Precess to B1950
+            R3=R2
+            D3=D2
+            CALL sla_PRECES('FK4',EQ0,1950D0,R3,D3)
+
+      *  Add E-terms for the standard equinox B1950
+            CALL sla_ADDET(R3,D3,1950D0,R4,D4)
+
+      *  Transform to J2000, no proper motion
+            CALL sla_FK45Z(R4,D4,EP1B,R5,D5)
+
+      *  Parallax
+            CALL sla_EVP(sla_EPJ2D(EP1),2000D0,W,EB,W,W)
+            PXR=PX*AS2R
+            CALL sla_DCS2C(R5,D5,V)
+            DO I=1,3
+               V(I)=V(I)-PXR*EB(I)
+            END DO
+            CALL sla_DCC2S(V,R6,D6)
+             :
+
+

+It is interesting to look at how the $[\,\alpha,\delta\,]$ changes during the +course of the calculation: +


+		 16 09 55.130 -75 59 27.20 		 		 original equinox and epoch
+		 16 09 54.155 -75 59 23.98 		 		 with space motion
+		 16 09 54.229 -75 59 24.18 		 		 with old E-terms removed
+		 16 16 28.213 -76 06 54.57 		 		 precessed to 1950.0
+		 16 16 28.138 -76 06 54.37 		 		 with new E-terms
+		 16 23 07.901 -76 13 58.87 		 		 J2000, current epoch
+		 16 23 07.907 -76 13 58.92 		 		 including parallax
+
+

+Other remarks about the above (unusually complicated) example: +

+

+ +next + +up + +previous +
+ Next: Mean Place to Apparent Place +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Different Sorts of Mean Place +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node212.html b/src/slalib/sun67.htx/node212.html new file mode 100644 index 0000000..35a5044 --- /dev/null +++ b/src/slalib/sun67.htx/node212.html @@ -0,0 +1,171 @@ + + + + +Mean Place to Apparent Place + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Apparent Place to Observed Place +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Mean Place Transformations +

+

+

+Mean Place to Apparent Place +

+The geocentric apparent place of a source, or apparent place +for short, +is the $[\,\alpha,\delta\,]$ if viewed from the centre of the Earth, +with respect to the true equator and equinox of date. +Transformation of an FK5 mean $[\,\alpha,\delta\,]$, equinox J2000, +current epoch, to apparent place involves the following effects: +

+The light deflection is seldom significant. Its value +at the limb of the Sun is about +

$1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.74$ ; it falls off rapidly with distance from the +Sun and has shrunk to about +

$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.02$ at an elongation of $20^\circ$.

+As already described, the annual aberration +is a function of the Earth's velocity +relative to the solar system barycentre (available through the +SLALIB routine +sla_EVP) +and produces shifts of up to about + $20\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$ . +

+The precession/nutation, from J2000 to the current epoch, is +expressed by a rotation matrix which is available through the +SLALIB routine +sla_PRENUT. +

+The whole mean-to-apparent transformation can be done using the SLALIB +routine +sla_MAP. As a demonstration, here is a program which lists the +North Polar Distance ($90^\circ-\delta$) of Polaris for +the decade of closest approach to the Pole: +

+            IMPLICIT NONE
+            DOUBLE PRECISION PI,PIBY2,D2R,S2R,AS2R
+            PARAMETER (PI=3.141592653589793238462643D0)
+            PARAMETER (D2R=PI/180D0,
+           :           PIBY2=PI/2D0,
+           :           S2R=PI/(12D0*3600D0),
+           :           AS2R=PI/(180D0*3600D0))
+            DOUBLE PRECISION RM,DM,PR,PD,DATE,RA,DA
+            INTEGER J,IDS,IDE,ID,IYMDF(4),I
+            DOUBLE PRECISION sla_EPJ2D
+
+            CALL sla_DTF2R(02,31,49.8131D0,RM,J)
+            CALL sla_DAF2R(89,15,50.661D0,DM,J)
+            PR=+21.7272D0*S2R/100D0
+            PD=-1.571D0*AS2R/100D0
+            WRITE (*,'(1X,'//
+           :            '''Polaris north polar distance (deg) 2096-2105''/)')
+            WRITE (*,'(4X,''Date'',7X''NPD''/)')
+            CALL sla_CLDJ(2096,1,1,DATE,J)
+            IDS=NINT(DATE)
+            CALL sla_CLDJ(2105,12,31,DATE,J)
+            IDE=NINT(DATE)
+            DO ID=IDS,IDE,10
+               DATE=DBLE(ID)
+               CALL sla_DJCAL(0,DATE,IYMDF,J)
+               CALL sla_MAP(RM,DM,PR,PD,0D0,0D0,2000D0,DATE,RA,DA)
+               WRITE (*,'(1X,I4,2I3.2,F9.5)') (IYMDF(I),I=1,3),(PIBY2-DA)/D2R
+            END DO
+
+            END
+
+

+For cases where the transformation has to be repeated for different +times or for more than one star, the straightforward +sla_MAP +approach is apt to be +wasteful as both the Earth velocity and the +precession/nutation matrix can be re-calculated relatively +infrequently without ill effect. A more efficient method is to +perform the target-independent calculations only when necessary, +by calling +sla_MAPPA, +and then to use either +sla_MAPQKZ, +when only the $[\,\alpha,\delta\,]$ is known, or +sla_MAPQK, +when full catalogue positions, including proper motion, parallax and +radial velocity, are available. How frequently to call +sla_MAPPA +depends on the accuracy objectives; once per +night will deliver sub-arcsecond accuracy for example. +

+The routines +sla_AMP +and +sla_AMPQK +allow the reverse transformation, from apparent to mean place. +

+


+ +next + +up + +previous +
+ Next: Apparent Place to Observed Place +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Mean Place Transformations +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node213.html b/src/slalib/sun67.htx/node213.html new file mode 100644 index 0000000..4d2a0e1 --- /dev/null +++ b/src/slalib/sun67.htx/node213.html @@ -0,0 +1,181 @@ + + + + +Apparent Place to Observed Place + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Refraction +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Mean Place to Apparent Place +

+

+

+Apparent Place to Observed Place +

+The observed place of a source is its position as +seen by a perfect theodolite at the location of the +observer. Transformation of an apparent $[\,\alpha,\delta\,]$ to observed +place involves the following effects: +

+The transformation from apparent $[\,\alpha,\delta\,]$ to +apparent $[\,h,\delta\,]$ is made by allowing for +Earth rotation through the sidereal time, $\theta$: +

\begin{displaymath}
+h = \theta - \alpha \end{displaymath}

+For this equation to work, $\alpha$ must be the apparent right +ascension for the time of observation, and $\theta$ must be +the local apparent sidereal time. The latter is obtained +as follows: +
+
1. +
from civil time obtain the coordinated universal time, UTC +(more later on this); +
2. +
add the UT1-UTC (typically a few tenths of a second) to + give the UT; +
3. +
from the UT compute the Greenwich mean sidereal time (using +sla_GMST); +
4. +
add the observer's (east) longitude, giving the local mean + sidereal time; +
5. +
add the equation of the equinoxes (using +sla_EQEQX). +
+The equation of the equinoxes ($=\Delta\psi\cos\epsilon$ plus +small terms) +is the effect of nutation on the sidereal time. +Its value is typically a second or less. It is +interesting to note that if the object of the exercise is to +transform a mean place all the way into an observed place (very +often the case), +then the equation of the +equinoxes and the longitude component of nutation can both be +omitted, removing a great deal of computation. However, SLALIB +follows the normal convention and works via the apparent place. +

+Note that for very precise work the observer's longitude should +be corrected for polar motion. This can be done with +sla_POLMO. +The corrections are always less than about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$ , and +are futile unless the position of the observer's telescope is known +to better than a few metres. +

+Tables of observed and +predicted UT1-UTC corrections and polar motion data +are published every few weeks by the International Earth Rotation Service. +

+The transformation from apparent $[\,h,\delta\,]$ to topocentric +$[\,h,\delta\,]$ consists of allowing for +diurnal aberration. This effect, maximum amplitude + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$ , +was described earlier. There is no specific SLALIB routine +for computing the diurnal aberration, +though the routines +sla_AOP etc. include it, and the required velocity vector can be +determined by calling +sla_GEOC. +

+The next stage is the major coordinate rotation from local equatorial +coordinates $[\,h,\delta\,]$ into horizon coordinates. The SLALIB routines +sla_E2H +etc. can be used for this. For high-precision +applications the mean geodetic latitude should be corrected for polar +motion. +

+


+ +  + + +

+ +next + +up + +previous +
+ Next: Refraction +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Mean Place to Apparent Place +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node214.html b/src/slalib/sun67.htx/node214.html new file mode 100644 index 0000000..41b8d99 --- /dev/null +++ b/src/slalib/sun67.htx/node214.html @@ -0,0 +1,189 @@ + + + + +Refraction + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Efficiency considerations +
+Up: Apparent Place to Observed Place +
+ Previous: Apparent Place to Observed Place +

+

+

+Refraction +

+The final correction is for atmospheric refraction. +This effect, which depends on local meteorological conditions and +the effective colour of the source/detector combination, +increases the observed elevation of the source by a +significant effect even at moderate zenith distances, and near the +horizon by over $0^{\circ}
+ \hspace{-0.37em}.\hspace{0.02em}5$. The amount of refraction can by +computed by calling the SLALIB routine +sla_REFRO; +however, +this requires as input the observed zenith distance, which is what +we are trying to predict. For high precision it is +therefore necessary to iterate, using the topocentric +zenith distance as the initial estimate of the +observed zenith distance. +

+The full +sla_REFRO refraction calculation is onerous, and for +zenith distances of less than, say, $75^\circ$ the following +model can be used instead: +

+

\begin{displaymath}
+\zeta _{vac} \approx \zeta _{obs}
+ + A \tan \zeta _{obs}
+ + B \tan ^{3}\zeta _{obs} \end{displaymath}

+where $\zeta _{vac}$ is the topocentric +zenith distance (i.e. in vacuo), +$\zeta_{obs}$ is the observed +zenith distance (i.e. affected by refraction), and A and B are +constants, about $60\hspace{-0.05em}^{'\hspace{-0.1em}'}$and + $-0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.06$ respectively for a sea-level site. +The two constants can be calculated for a given set of conditions +by calling either +sla_REFCO or +sla_REFCOQ. +

+sla_REFCO works by calling +sla_REFRO for two zenith distances and fitting A and B +to match. The calculation is onerous, but delivers accurate +results whatever the conditions. +sla_REFCOQ uses a direct formulation of A and B and +is much faster; it is slightly less accurate than +sla_REFCO but more than adequate for most practical purposes. +

+Like the full refraction model, the two-term formulation works in the wrong +direction for our purposes, predicting +the in vacuo (topocentric) zenith distance +given the refracted (observed) zenith distance, +rather than vice versa. The obvious approach of +interchanging $\zeta _{vac}$ and $\zeta_{obs}$ and +reversing the signs, though approximately +correct, gives avoidable errors which are just significant in +some applications; for +example about + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$ at $70^\circ$ zenith distance. A +much better result can easily be obtained, by using one Newton-Raphson +iteration as follows: +

+

\begin{displaymath}
+\zeta _{obs} \approx \zeta _{vac}
+ - \frac{A \tan \zeta _{va...
+ ...
+ {1 + ( A + 3 B \tan ^{2}\zeta _{vac} ) \sec ^{2}\zeta _{vac}}\end{displaymath}

+

+The effect of refraction can be applied to an unrefracted +zenith distance by calling +sla_REFZ or to an unrefracted +$[\,x,y,z\,]$ by calling +sla_REFV. +Over most of the sky these two routines deliver almost identical +results, but beyond $\zeta=83^\circ$sla_REFV +becomes unacceptably inaccurate while +sla_REFZ +remains usable. (However +sla_REFV +is significantly faster, which may be important in some applications.) +SLALIB also provides a routine for computing the airmass, the function +sla_AIRMAS. +

+The refraction ``constants'' returned by +sla_REFCO and +sla_REFCOQ +are slightly affected by colour, especially at the blue end +of the spectrum. Where values for more than one +wavelength are needed, rather than calling +sla_REFCO +several times it is more efficient to call +sla_REFCO +just once, for a selected ``base'' wavelength, and then to call +sla_ATMDSP +once for each wavelength of interest. +

+All the SLALIB refraction routines work for radio wavelengths as well +as the optical/IR band. The radio refraction is very dependent on +humidity, and an accurate value must be supplied. There is no +wavelength dependence, however. The choice of optical/IR or +radio is made by specifying a wavelength greater than $100\mu m$for the radio case. +

+


+ +next + +up + +previous +
+ Next: Efficiency considerations +
+Up: Apparent Place to Observed Place +
+ Previous: Apparent Place to Observed Place +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node215.html b/src/slalib/sun67.htx/node215.html new file mode 100644 index 0000000..020487b --- /dev/null +++ b/src/slalib/sun67.htx/node215.html @@ -0,0 +1,87 @@ + + + + +Efficiency considerations + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: The Hipparcos Catalogue and the ICRS +
+Up: Apparent Place to Observed Place +
+ Previous: Refraction +

+

+

+Efficiency considerations +

+The complete apparent place to observed place transformation +can be carried out by calling +sla_AOP. +For improved efficiency +in cases of more than one star or a sequence of times, the +target-independent calculations can be done once by +calling +sla_AOPPA, +the time can be updated by calling +sla_AOPPAT, +and +sla_AOPQK +can then be used to perform the +apparent-to-observed transformation. The reverse transformation +is available through +sla_OAP +and +sla_OAPQK. +(n.b. These routines use accurate but computationally-expensive +refraction algorithms for zenith distances beyond about $76^\circ$.For many purposes, in-line code tailored to the accuracy requirements +of the application will be preferable, for example ignoring UT1-UTC, +omitting diurnal aberration and using +sla_REFZ +to apply the refraction.) +

+


+ +next + +up + +previous +
+ Next: The Hipparcos Catalogue and the ICRS +
+Up: Apparent Place to Observed Place +
+ Previous: Refraction +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node216.html b/src/slalib/sun67.htx/node216.html new file mode 100644 index 0000000..ab75104 --- /dev/null +++ b/src/slalib/sun67.htx/node216.html @@ -0,0 +1,110 @@ + + + + +The Hipparcos Catalogue and the ICRS + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Timescales +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Efficiency considerations +

+

+

+The Hipparcos Catalogue and the ICRS +

+With effect from the beginning of 1998, the IAU adopted a new +reference system to replace FK5 J2000. The new system, called the +International Celestial Reference System (ICRS), differs profoundly +from all predecessors in that the link with solar-system dynamics +was broken; the ICRS axes are defined in terms of the directions +of a set of extragalactic sources, not in terms of the mean equator and +equinox at a given reference epoch. Although the ICRS and FK5 coordinates +of any given object are almost the same, the orientation of the new frame +was essentially arbitrary, and the close match to FK5 J2000 was contrived +purely for reasons of continuity and convenience. +

+A distinction is made between the reference system (the ICRS) +and frame (ICRF). The ICRS is the set of prescriptions and +conventions together with the modelling required to define, at any +time, a triad of axes. The ICRF is a practical realization, and +currently consists of a catalogue of equatorial coordinates for 608 +extragalactic radio sources observed by VLBI. +

+The best optical realization of the ICRF currently available is the +Hipparcos catalogue. The extragalactic sources were not directly +observable by the Hipparcos satellite and so the link from Hipparcos +to ICRF was established through a variety of indirect techniques: VLBI and +conventional interferometry of radio stars, photographic astrometry +and so on. The Hipparcos frame is aligned to the ICRF to within about +0.5 mas and 0.5 mas/year (at epoch 1991.25). +

+The Hipparcos catalogue includes all of the FK5 stars, which has enabled +the orientation and spin of the latter to be studied. At epoch J2000, +the misalignment of the FK5 frame with respect to Hipparcos +(and hence ICRS) are about 32 mas and 1 mas/year respectively. +Consequently, for many practical purposes, including pointing +telescopes, the IAU 1976-1982 conventions on reference frames and +Earth orientation remain adequate and there is no need to change to +Hipparcos coordinates, new precession/nutation models and so on. +However, for the most exacting astrometric applications, SLALIB +provides some support for Hipparcos coordinates in the form of +four new routines: +sla_FK52H and +sla_H2FK5, +which transform FK5 positions and proper motions to the Hipparcos frame +and vice versa, and +sla_FK5HZ and +sla_HFK5Z, +where the transformations are for stars whose Hipparcos proper motion is +zero. +

+Further information on the ICRS can be found in the paper by M.Feissel +and F.Mignard, Astron.Astrophys. 331, L33-L36 (1988). +

+


+ +next + +up + +previous +
+ Next: Timescales +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Efficiency considerations +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node217.html b/src/slalib/sun67.htx/node217.html new file mode 100644 index 0000000..b6fbe6c --- /dev/null +++ b/src/slalib/sun67.htx/node217.html @@ -0,0 +1,92 @@ + + + + +Timescales + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Atomic Time: TAI +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: The Hipparcos Catalogue and the ICRS +

+

+

+Timescales +

+SLALIB provides for conversion between several timescales, and involves +use of one or two others. The full list is as follows: + +Three obsolete timescales should be mentioned here to avoid confusion. + +

+ +  + + +

+ +next + +up + +previous +
+ Next: Atomic Time: TAI +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: The Hipparcos Catalogue and the ICRS +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node218.html b/src/slalib/sun67.htx/node218.html new file mode 100644 index 0000000..106412e --- /dev/null +++ b/src/slalib/sun67.htx/node218.html @@ -0,0 +1,91 @@ + + + + +Atomic Time: TAI + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Universal Time: UTC, UT1 +
+Up: Timescales +
+ Previous: Timescales +

+

+

+Atomic Time: TAI +

+International Atomic Time TAI is a laboratory timescale. Its +unit is the SI second, which is defined in terms of a +defined number +of wavelengths of the radiation produced by a certain electronic +transition in the caesium 133 atom. It +is realized through a changing +population of high-precision atomic clocks held +at standards institutes in various countries. There is an +elaborate process of continuous intercomparison, leading to +a weighted average of all the clocks involved. +

+Though TAI shares the same second as the more familiar UTC, the +two timescales are noticeably separated in epoch because of the +build-up of leap seconds. At the time of writing, UTC +lags about half a minute behind TAI. +

+For any given date, the difference TAI-UTC +can be obtained by calling the SLALIB routine +sla_DAT. +Note, however, that an up-to-date copy of the routine must be used if +the most recent leap seconds are required. For applications +where this is critical, mechanisms independent of SLALIB +and under local control must +be set up; in such cases +sla_DAT +can be useful as an +independent check, for test dates within the range of the +available version. Up-to-date information on TAI-UTC is available +from ftp://maia.usno.navy.mil/ser7/tai-utc.dat. +

+


+ +next + +up + +previous +
+ Next: Universal Time: UTC, UT1 +
+Up: Timescales +
+ Previous: Timescales +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node219.html b/src/slalib/sun67.htx/node219.html new file mode 100644 index 0000000..4214aaa --- /dev/null +++ b/src/slalib/sun67.htx/node219.html @@ -0,0 +1,184 @@ + + + + +Universal Time: UTC, UT1 + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Sidereal Time: GMST, LAST +
+Up: Timescales +
+ Previous: Atomic Time: TAI +

+

+

+Universal Time: UTC, UT1 +

+Coordinated Universal Time UTC is the basis of civil timekeeping. +Most time zones differ from UTC by an integer number +of hours, though a few (e.g. parts of Canada and Australia) differ +by n+0.5 hours. The UTC second is the same as the SI second, +as for TAI. In the long term, UTC keeps in step with the +Sun. It does so even though the Earth's rotation is slightly +variable (due to large scale movements of water and atmosphere +among other things) by occasionally introducing a leap +second. +

Universal Time UT, or more specifically UT1, +is in effect the mean solar time. It is continuous +(i.e. there are no leap seconds) but has a variable +rate because of the Earth's non-uniform rotation period. It is +needed for computing the sidereal time, an essential part of +pointing a telescope at a celestial source. To obtain UT1, you +have to look up the value of UT1-UTC for the date concerned +in tables published by the International Earth Rotation +Service; this quantity, kept in the range +$\pm$$0^{\rm s}\hspace{-0.3em}.9$ by means of UTC leap +seconds, is then added to the UTC. The quantity UT1-UTC, +which typically changes by 1 or 2 ms per day, +can only be obtained by observation, though seasonal trends +are known and the IERS listings are able to predict some way into +the future with adequate accuracy for pointing telescopes. +

+UTC leap seconds are introduced as necessary, +usually at the end of December or June. +On the average the solar day is slightly longer +than the nominal 86,400 SI seconds and so leap seconds are always positive; +however, provision exists for negative leap seconds if needed. +The form of a leap second can be seen from the +following description of the end of June 1994: +

  + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Figure 1: +Relationship Between Celestial Coordinates
      
   UTCUT1-UTCUT1
      
1994June3023 59 58-0.21823 59 57.782
   23 59 59-0.21823 59 58.782
   23 59 60-0.21823 59 59.782
 July100 00 00+0.78200 00 00.782
   00 00 01+0.78200 00 01.782
+

+Note that UTC has to be expressed as hours, minutes and +seconds (or at least in seconds for a given date) if leap seconds +are to be taken into account. It is improper to express a UTC as a +Julian Date, for example, because there will be an ambiguity +during a leap second (in the above example, +1994 June 30 $23^{h}\,59^{m}\,60^{s}.0$ and +1994 July 1 $00^{h}\,00^{m}\,00^{s}.0$ would both come out as +MJD 49534.00000). Although in the vast majority of +cases this won't matter, there are potential problems in +on-line data acquisition systems and in applications involving +taking the difference between two times. Note that although the routines +sla_DAT +and +sla_DTT +expect UTC in the form of an MJD, the meaning here is really a +whole-number date rather than a time. Though the routines will accept +a fractional part and will almost always function correctly, on a day +which ends with a leap +second incorrect results would be obtained during the leap second +itself because by then the MJD would have moved into the next day. +

+


+ +next + +up + +previous +
+ Next: Sidereal Time: GMST, LAST +
+Up: Timescales +
+ Previous: Atomic Time: TAI +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node22.html b/src/slalib/sun67.htx/node22.html new file mode 100644 index 0000000..4e96061 --- /dev/null +++ b/src/slalib/sun67.htx/node22.html @@ -0,0 +1,119 @@ + + + + +SLA_AOPPAT - Update Appt-to-Obs Parameters + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_AOPQK - Quick Appt-to-Observed +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AOPPA - Appt-to-Obs Parameters +

+

+

SLA_AOPPAT - Update Appt-to-Obs Parameters +   +

+
+
ACTION: +
Recompute the sidereal time in the apparent to observed place +star-independent parameter block. +

CALL: +
CALL sla_AOPPAT (DATE, AOPRMS) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + +
DATEDUTC date/time (Modified Julian Date, JD-2400000.5)
AOPRMSD(14)star-independent apparent-to-observed parameters:
(1-12)not required
(13)longitude + eqn of equinoxes + +``sidereal $\Delta$UT'' (radians)
(14)not required
+

+
RETURNED: +
+
+ + + + + + + + + + + + + +
AOPRMSD(14)star-independent apparent-to-observed parameters:
(1-13)not changed
(14)local apparent sidereal time (radians)
+

+
NOTE: +
For more information, see sla_AOPPA. +
+

+ +next + +up + +previous +
+ Next: SLA_AOPQK - Quick Appt-to-Observed +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AOPPA - Appt-to-Obs Parameters +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node220.html b/src/slalib/sun67.htx/node220.html new file mode 100644 index 0000000..84db99f --- /dev/null +++ b/src/slalib/sun67.htx/node220.html @@ -0,0 +1,96 @@ + + + + +Sidereal Time: GMST, LAST + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Dynamical Time: TT, TDB +
+Up: Timescales +
+ Previous: Universal Time: UTC, UT1 +

+

+

+Sidereal Time: GMST, LAST +

+Sidereal Time is the ``time of day'' relative to the +stars rather than to the Sun. After +one sidereal day the stars come back to the same place in the +sky, apart from sub-arcsecond precession effects. Because the Earth +rotates faster relative to the stars than to the Sun by one day +per year, the sidereal second is shorter than the solar +second; the ratio is about 0.9973. +

+The Greenwich Mean Sidereal Time GMST is +linked to UT1 by a numerical formula which +is implemented in the SLALIB routines +sla_GMST +and +sla_GMSTA. +There are, of course, no leap seconds in GMST, but the second +changes in length along with the UT1 second, and also varies +over long periods of time because of slow changes in the Earth's +orbit. This makes the timescale unsuitable for everything except +predicting the apparent directions of celestial sources. +

+The Local Apparent Sidereal Time LAST is the apparent right +ascension of the local meridian, from which the hour angle of any +star can be determined knowing its $\alpha$. It can be obtained from the +GMST by adding the east longitude (corrected for polar motion +in precise work) and the equation of the equinoxes. The +latter, already described, is an aspect of the nutation effect +and can be predicted by calling the SLALIB routine +sla_EQEQX +or, neglecting certain very small terms, by calling +sla_NUTC +and using the expression $\Delta\psi\cos\epsilon$.

+


+ +next + +up + +previous +
+ Next: Dynamical Time: TT, TDB +
+Up: Timescales +
+ Previous: Universal Time: UTC, UT1 +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node221.html b/src/slalib/sun67.htx/node221.html new file mode 100644 index 0000000..926f2ce --- /dev/null +++ b/src/slalib/sun67.htx/node221.html @@ -0,0 +1,158 @@ + + + + +Dynamical Time: TT, TDB + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Calendars +
+Up: Timescales +
+ Previous: Sidereal Time: GMST, LAST +

+

+

+Dynamical Time: TT, TDB +

+Dynamical time is the independent variable in the theories +which describe the motions of bodies in the solar system. When +you use published formulae which model the position of the +Earth in its orbit, for example, or look up +the Moon's position in a precomputed ephemeris, the date and time +you use must be in terms of one of the dynamical timescales. It +is a common but understandable mistake to use UT directly, in which +case the results will be about 1 minute out (in the present +era). +

+It is not hard to see why such timescales are necessary. +UTC would clearly be unsuitable as the argument of an +ephemeris because of leap seconds. +A solar-system ephemeris based on UT1 or sidereal time would somehow +have to include the unpredictable variations of the Earth's rotation. +TAI would work, but eventually +the ephemeris and the ensemble of atomic clocks would drift apart. +In effect, the ephemeris is a clock, with the bodies of +the solar system the hands. +

+Only two of the dynamical timescales are of any great importance to +observational astronomers, TT and TDB. (The obsolete +timescale ET, ephemeris time, was more or less the same as TT.) +

Terrestrial Time TT is +the theoretical timescale of apparent geocentric ephemerides of solar +system bodies. It applies, in principle, +to an Earthbound clock, at sea-level, and for practical purposes +it is tied to +Atomic Time TAI through the formula TT = TAI + $32^{\rm s}\hspace{-0.3em}.184$.In practice, therefore, the units of TT are ordinary SI seconds, and +the offset of $32^{\rm s}\hspace{-0.3em}.184$ with respect to TAI is fixed. +The SLALIB routine +sla_DTT +returns TT-UTC for a given UTC +(n.b. sla_DTT +calls +sla_DAT, +and the latter must be an up-to-date version if recent leap seconds are +to be taken into account). +

Barycentric Dynamical Time TDB differs from TT by an amount which +cycles back and forth by a millisecond or two due to +relativistic effects. The variation is +negligible for most purposes, but unless taken into +account would swamp +long-term analysis of pulse arrival times from the +millisecond pulsars. It is a consequence of +the TT clock being on the Earth rather than in empty +space: the ellipticity of +the Earth's orbit means that the TT clock's speed and +gravitational potential vary slightly +during the course of the year, and as a consequence +its rate as seen from an outside observer +varies due to transverse Doppler effect and gravitational +redshift. By definition, TDB and TT differ only +by periodic terms, and the main effect +is a sinusoidal variation of amplitude $0^{\rm s}\hspace{-0.3em}.0016$; the +largest planetary terms are nearly two orders of magnitude +smaller. The SLALIB routine +sla_RCC +provides a model of +TDB-TT accurate to a few nanoseconds. +There are other dynamical timescales, not supported by +SLALIB routines, which include allowance also for the secular terms. +These timescales gain on TT and TDB by about $0^{\rm s}\hspace{-0.3em}.0013$/day. +

+For most purposes the more accessible TT is the timescale to use, +for example when calling +sla_PRENUT +to generate a precession/nutation matrix or when calling +sla_EVP +to predict the +Earth's position and velocity. For some purposes TDB is the +correct timescale, for example when interrogating the JPL planetary +ephemeris (see Starlink User Note 87), though in most cases +TT will be near enough and will involve less computation. +

+Investigations of topocentric solar-system phenomena such as +occultations and eclipses require solar time as well as dynamical +time. TT/TDB/ET is all that is required in order to compute the geocentric +circumstances, but if horizon coordinates or geocentric parallax +are to be tackled UT is also needed. A rough estimate +of $\Delta {\rm T} = {\rm ET} - {\rm UT}$ is +available via the routine +sla_DT. +For a given epoch (e.g. 1650) this returns an approximation +to $\Delta {\rm T}$ in seconds. +

+


+ +next + +up + +previous +
+ Next: Calendars +
+Up: Timescales +
+ Previous: Sidereal Time: GMST, LAST +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node222.html b/src/slalib/sun67.htx/node222.html new file mode 100644 index 0000000..7cc8f58 --- /dev/null +++ b/src/slalib/sun67.htx/node222.html @@ -0,0 +1,113 @@ + + + + +Calendars + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Geocentric Coordinates +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Dynamical Time: TT, TDB +

+

+

+Calendars +

+The ordinary Gregorian Calendar Date, +together with a time of day, can be +used to express an epoch in any desired timescale. For many purposes, +however, a continuous count of days is more convenient, and for +this purpose the system of Julian Day Number can be used. +JD zero is located about 7000 years ago, well before the +historical era, and is formally defined in terms of Greenwich noon; +Julian Day Number 2449444 began at noon on 1994 April 1. Julian Date +is the same system but with a fractional part appended; +Julian Date 2449443.5 was the midnight on which 1994 April 1 +commenced. Because of the unwieldy size of Julian Dates +and the awkwardness of the half-day offset, it is +accepted practice to remove the leading `24' and the trailing `.5', +producing what is called the Modified Julian Date: +MJD = JD-2400000.5. SLALIB routines use MJD, as opposed to +JD, throughout, largely to avoid loss of precision. +1994 April 1 commenced at MJD 49443.0. +

+Despite JD (and hence MJD) being defined in terms of (in effect) +UT, the system can be used in conjunction with other timescales +such as TAI, TT and TDB (and even sidereal time through the +concept of Greenwich Sidereal Date). However, it is improper +to express a UTC as a JD or MJD because of leap seconds. +

+SLALIB has six routines for converting to and from dates in +the Gregorian calendar. The routines +sla_CLDJ +and +sla_CALDJ +both convert a calendar date into an MJD, the former interpreting +years between 0 and 99 as 1st century and the latter as late 20th or +early 21st century. The routines sla_DJCL +and +sla_DJCAL +both convert an MJD into calendar year, month, day and fraction of a day; +the latter performs rounding to a specified precision, important +to avoid dates like `94 04 01.***' appearing in messages. +Some of SLALIB's low-precision ephemeris routines +(sla_EARTH, +sla_MOON +and +sla_ECOR) +work in terms of year plus day-in-year (where +day 1 = January 1st, at least for the modern era). +This form of date can be generated by +calling +sla_CALYD +(which defaults years 0-99 into 1950-2049) +or +sla_CLYD +(which covers the full range from prehistoric times). +

+


+ +next + +up + +previous +
+ Next: Geocentric Coordinates +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Dynamical Time: TT, TDB +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node223.html b/src/slalib/sun67.htx/node223.html new file mode 100644 index 0000000..497a385 --- /dev/null +++ b/src/slalib/sun67.htx/node223.html @@ -0,0 +1,139 @@ + + + + +Geocentric Coordinates + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Ephemerides +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Calendars +

+

+

+Geocentric Coordinates +

+The location of the observer on the Earth is significant in a +number of ways. The most obvious, of course, is the effect of latitude +on the observed $[\,Az,El~]$ of a star. Less obvious is the need to +allow for geocentric parallax when finding the Moon with a +telescope (and when doing high-precision work involving the +Sun or planets), and the need to correct observed radial +velocities and apparent pulsar periods for the effects +of the Earth's rotation. +

+The SLALIB routine +sla_OBS +supplies details of groundbased observatories from an internal +list. This is useful when writing applications that apply to +more than one observatory; the user can enter a brief name, +or browse through a list, and be spared the trouble of typing +in the full latitude, longitude etc. The following +Fortran code returns the full name, longitude and latitude +of a specified observatory: +

+            CHARACTER IDENT*10,NAME*40
+            DOUBLE PRECISION W,P,H
+             :
+            CALL sla_OBS(0,IDENT,NAME,W,P,H)
+            IF (NAME.EQ.'?') ...             (not recognized)
+
+

(Beware of the longitude sign convention, which is west +ve +for historical reasons.) The following lists all +the supported observatories: +

+             :
+            INTEGER N
+             :
+            N=1
+            NAME=' '
+            DO WHILE (NAME.NE.'?')
+               CALL sla_OBS(N,IDENT,NAME,W,P,H)
+               IF (NAME.NE.'?') THEN
+                  WRITE (*,'(1X,I3,4X,A,4X,A)') N,IDENT,NAME
+                  N=N+1
+               END IF
+            END DO
+
+

+The routine +sla_GEOC +converts a geodetic latitude +(one referred to the local horizon) to a geocentric position, +taking into account the Earth's oblateness and also the height +above sea level of the observer. The results are expressed in +vector form, namely as the distance of the observer from +the spin axis and equator respectively. The geocentric +latitude can be found be evaluating ATAN2 of the +two numbers. A full 3-D vector description of the position +and velocity of the observer is available through the routine +sla_PVOBS. +For a specified geodetic latitude, height above +sea level, and local sidereal time, +sla_PVOBS +generates a 6-element vector containing the position and +velocity with respect to the true equator and equinox of +date (i.e. compatible with apparent $[\,\alpha,\delta\,]$). For +some applications it will be necessary to convert to a +mean $[\,\alpha,\delta\,]$ frame (notably FK5, J2000) by multiplying +elements 1-3 and 4-6 respectively with the appropriate +precession matrix. (In theory an additional correction to the +velocity vector is needed to allow for differential precession, +but this correction is always negligible.) +

+See also the discussion of the routine +sla_RVEROT, +later. +

+


+ +next + +up + +previous +
+ Next: Ephemerides +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Calendars +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node224.html b/src/slalib/sun67.htx/node224.html new file mode 100644 index 0000000..4cb8678 --- /dev/null +++ b/src/slalib/sun67.htx/node224.html @@ -0,0 +1,617 @@ + + + + +Ephemerides + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Radial Velocity and Light-Time Corrections +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Geocentric Coordinates +

+

+

+Ephemerides +

+SLALIB includes routines for generating positions and +velocities of Solar-System bodies. The accuracy objectives are +modest, and the SLALIB facilities do not attempt +to compete with precomputed ephemerides such as +those provided by JPL, or with models containing +thousands of terms. It is also worth noting +that SLALIB's very accurate star coordinate conversion +routines are not strictly applicable to solar-system cases, +though they are adequate for most practical purposes. +

+Earth/Sun ephemerides can be generated using the routine +sla_EVP, +which predicts Earth position and velocity with respect to both the +solar-system barycentre and the +Sun. Maximum velocity error is 0.42 metres per second; maximum +heliocentric position error is 1600 km (about $2\hspace{-0.05em}^{'\hspace{-0.1em}'}$), with +barycentric position errors about 4 times worse. +(The Sun's position as +seen from the Earth can, of course, be obtained simply by +reversing the signs of the Cartesian components of the +Earth:Sun vector.) +

+Geocentric Moon ephemerides are available from +sla_DMOON, +which predicts the Moon's position and velocity with respect to +the Earth's centre. Direction accuracy is usually better than +10 km ($5\hspace{-0.05em}^{'\hspace{-0.1em}'}$) and distance accuracy a little worse. +

+Lower-precision but faster predictions for the Sun and Moon +can be made by calling +sla_EARTH +and +sla_MOON. +Both are single precision and accept dates in the form of +year, day-in-year and fraction of day +(starting from a calendar date you need to call +sla_CLYD +or +sla_CALYD +to get the required year and day). +The +sla_EARTH +routine returns the heliocentric position and velocity +of the Earth's centre for the mean equator and +equinox of date. The accuracy is better than 20,000 km in position +and 10 metres per second in speed. +The +position and velocity of the Moon with respect to the +Earth's centre for the mean equator and ecliptic of date +can be obtained by calling +sla_MOON. +The positional accuracy is better than $30\hspace{-0.05em}^{'\hspace{-0.1em}'}$ in direction +and 1000 km in distance. +

+Approximate ephemerides for all the major planets +can be generated by calling +sla_PLANET +or +sla_RDPLAN. These routines offer arcminute accuracy (much +better for the inner planets and for Pluto) over a span of several +millennia (but only $\pm100$ years for Pluto). +The routine +sla_PLANET produces heliocentric position and +velocity in the form of equatorial $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ for the +mean equator and equinox of J2000. The vectors +produced by +sla_PLANET +can be used in a variety of ways according to the +requirements of the application concerned. The routine +sla_RDPLAN +uses +sla_PLANET +and +sla_DMOON +to deal with the common case of predicting +a planet's apparent $[\,\alpha,\delta\,]$ and angular size as seen by a +terrestrial observer. +

+Note that in predicting the position in the sky of a solar-system body +it is necessary to allow for geocentric parallax. This correction +is essential in the case of the Moon, where the observer's +position on the Earth can affect the Moon's $[\,\alpha,\delta\,]$ by up to +$1^\circ$. The calculation can most conveniently be done by calling +sla_PVOBS and subtracting the resulting 6-vector from the +one produced by +sla_DMOON, as is demonstrated by the following example: +

+      *  Demonstrate the size of the geocentric parallax correction
+      *  in the case of the Moon.  The test example is for the AAT,
+      *  before midnight, in summer, near first quarter.
+
+            IMPLICIT NONE
+            CHARACTER NAME*40,SH,SD
+            INTEGER J,I,IHMSF(4),IDMSF(4)
+            DOUBLE PRECISION SLONGW,SLAT,H,DJUTC,FDUTC,DJUT1,DJTT,STL,
+           :                 RMATN(3,3),PMM(6),PMT(6),RM,DM,PVO(6),TL
+            DOUBLE PRECISION sla_DTT,sla_GMST,sla_EQEQX,sla_DRANRM
+
+      *  Get AAT longitude and latitude in radians and height in metres
+            CALL sla_OBS(0,'AAT',NAME,SLONGW,SLAT,H)
+
+      *  UTC (1992 January 13, 11 13 59) to MJD
+            CALL sla_CLDJ(1992,1,13,DJUTC,J)
+            CALL sla_DTF2D(11,13,59.0D0,FDUTC,J)
+            DJUTC=DJUTC+FDUTC
+
+      *  UT1 (UT1-UTC value of -0.152 sec is from IERS Bulletin B)
+            DJUT1=DJUTC+(-0.152D0)/86400D0
+
+      *  TT
+            DJTT=DJUTC+sla_DTT(DJUTC)/86400D0
+
+      *  Local apparent sidereal time
+            STL=sla_GMST(DJUT1)-SLONGW+sla_EQEQX(DJTT)
+
+      *  Geocentric position/velocity of Moon (mean of date)
+            CALL sla_DMOON(DJTT,PMM)
+
+      *  Nutation to true equinox of date
+            CALL sla_NUT(DJTT,RMATN)
+            CALL sla_DMXV(RMATN,PMM,PMT)
+            CALL sla_DMXV(RMATN,PMM(4),PMT(4))
+
+      *  Report geocentric HA,Dec
+            CALL sla_DCC2S(PMT,RM,DM)
+            CALL sla_DR2TF(2,sla_DRANRM(STL-RM),SH,IHMSF)
+            CALL sla_DR2AF(1,DM,SD,IDMSF)
+            WRITE (*,'(1X,'' geocentric:'',2X,A,I2.2,2I3.2,''.'',I2.2,'//
+           :                              '1X,A,I2.2,2I3.2,''.'',I1)')
+           :                                                SH,IHMSF,SD,IDMSF
+
+      *  Geocentric position of observer (true equator and equinox of date)
+            CALL sla_PVOBS(SLAT,H,STL,PVO)
+
+      *  Place origin at observer
+            DO I=1,6
+               PMT(I)=PMT(I)-PVO(I)
+            END DO
+
+      *  Allow for planetary aberration
+            TL=499.004782D0*SQRT(PMT(1)**2+PMT(2)**2+PMT(3)**2)
+            DO I=1,3
+               PMT(I)=PMT(I)-TL*PMT(I+3)
+            END DO
+
+      *  Report topocentric HA,Dec
+            CALL sla_DCC2S(PMT,RM,DM)
+            CALL sla_DR2TF(2,sla_DRANRM(STL-RM),SH,IHMSF)
+            CALL sla_DR2AF(1,DM,SD,IDMSF)
+            WRITE (*,'(1X,''topocentric:'',2X,A,I2.2,2I3.2,''.'',I2.2,'//
+           :                              '1X,A,I2.2,2I3.2,''.'',I1)')
+           :                                                SH,IHMSF,SD,IDMSF
+            END
+
+

+The output produced is as follows: +

+       geocentric:  +03 06 55.59 +15 03 39.0
+      topocentric:  +03 09 23.79 +15 40 51.5
+
+

(An easier but +less instructive method of estimating the topocentric apparent place of the +Moon is to call the routine +sla_RDPLAN.) +

+As an example of using +sla_PLANET, +the following program estimates the geocentric separation +between Venus and Jupiter during a close conjunction +in 2BC, which is a star-of-Bethlehem candidate: +

+      *  Compute time and minimum geocentric apparent separation
+      *  between Venus and Jupiter during the close conjunction of 2 BC.
+
+            IMPLICIT NONE
+
+            DOUBLE PRECISION SEPMIN,DJD0,FD,DJD,DJDM,DF,PV(6),RMATP(3,3),
+           :                 PVM(6),PVE(6),TL,RV,DV,RJ,DJ,SEP
+            INTEGER IHOUR,IMIN,J,I,IHMIN,IMMIN
+            DOUBLE PRECISION sla_EPJ,sla_DSEP
+
+
+      *  Search for closest approach on the given day
+            DJD0=1720859.5D0
+            SEPMIN=1D10
+            DO IHOUR=20,22
+               DO IMIN=0,59
+                  CALL sla_DTF2D(IHOUR,IMIN,0D0,FD,J)
+
+      *        Julian date and MJD
+                  DJD=DJD0+FD
+                  DJDM=DJD-2400000.5D0
+
+      *        Earth to Moon (mean of date)
+                  CALL sla_DMOON(DJDM,PV)
+
+      *        Precess Moon position to J2000
+                  CALL sla_PRECL(sla_EPJ(DJDM),2000D0,RMATP)
+                  CALL sla_DMXV(RMATP,PV,PVM)
+
+      *        Sun to Earth-Moon Barycentre (mean J2000)
+                  CALL sla_PLANET(DJDM,3,PVE,J)
+
+      *        Correct from EMB to Earth
+                  DO I=1,3
+                     PV(I)=PVE(I)-0.012150581D0*PVM(I)
+                  END DO
+
+      *        Sun to Venus
+                  CALL sla_PLANET(DJDM,2,PV,J)
+
+      *        Earth to Venus
+                  DO I=1,6
+                     PV(I)=PV(I)-PVE(I)
+                  END DO
+
+      *        Light time to Venus (sec)
+                  TL=499.004782D0*SQRT((PV(1)-PVE(1))**2+
+           :                           (PV(2)-PVE(2))**2+
+           :                           (PV(3)-PVE(3))**2)
+
+      *        Extrapolate backwards in time by that much
+                  DO I=1,3
+                     PV(I)=PV(I)-TL*PV(I+3)
+                  END DO
+
+      *       To RA,Dec
+                  CALL sla_DCC2S(PV,RV,DV)
+
+      *        Same for Jupiter
+                  CALL sla_PLANET(DJDM,5,PV,J)
+                  DO I=1,6
+                     PV(I)=PV(I)-PVE(I)
+                  END DO
+                  TL=499.004782D0*SQRT((PV(1)-PVE(1))**2+
+           :                           (PV(2)-PVE(2))**2+
+           :                           (PV(3)-PVE(3))**2)
+                  DO I=1,3
+                     PV(I)=PV(I)-TL*PV(I+3)
+                  END DO
+                  CALL sla_DCC2S(PV,RJ,DJ)
+
+      *        Separation (arcsec)
+                  SEP=sla_DSEP(RV,DV,RJ,DJ)
+
+      *        Keep if smallest so far
+                  IF (SEP.LT.SEPMIN) THEN
+                     IHMIN=IHOUR
+                     IMMIN=IMIN
+                     SEPMIN=SEP
+                  END IF
+               END DO
+            END DO
+
+      *  Report
+            WRITE (*,'(1X,I2.2,'':'',I2.2,F6.1)') IHMIN,IMMIN,
+           :                                      206264.8062D0*SEPMIN
+
+            END
+
+

+The output produced (the Ephemeris Time on the day in question, and +the closest approach in arcseconds) is as follows: +

+      21:19  33.7
+
+

+For comparison, accurate predictions based on the JPL DE102 ephemeris +give a separation about $8\hspace{-0.05em}^{'\hspace{-0.1em}'}$ less than +the above estimate, occurring about half an hour earlier +(see Sky and Telescope, April 1987, p357). +

+The following program demonstrates +sla_RDPLAN. +

+      *  For a given date, time and geographical location, output
+      *  a table of planetary positions and diameters.
+
+            IMPLICIT NONE
+            CHARACTER PNAMES(0:9)*7,B*80,S
+            INTEGER I,NP,IY,J,IM,ID,IHMSF(4),IDMSF(4)
+            DOUBLE PRECISION R2AS,FD,DJM,ELONG,PHI,RA,DEC,DIAM
+            PARAMETER (R2AS=206264.80625D0)
+            DATA PNAMES / 'Sun','Mercury','Venus','Moon','Mars','Jupiter',
+           :              'Saturn','Uranus','Neptune', 'Pluto' /
+
+
+      *  Loop until 'end' typed
+            B=' '
+            DO WHILE (B.NE.'END'.AND.B.NE.'end')
+
+      *     Get date, time and observer's location
+               PRINT *,'Date? (Y,M,D, Gregorian)'
+               READ (*,'(A)') B
+               IF (B.NE.'END'.AND.B.NE.'end') THEN
+                  I=1
+                  CALL sla_INTIN(B,I,IY,J)
+                  CALL sla_INTIN(B,I,IM,J)
+                  CALL sla_INTIN(B,I,ID,J)
+                  PRINT *,'Time? (H,M,S, dynamical)'
+                  READ (*,'(A)') B
+                  I=1
+                  CALL sla_DAFIN(B,I,FD,J)
+                  FD=FD*2.3873241463784300365D0
+                  CALL sla_CLDJ(IY,IM,ID,DJM,J)
+                  DJM=DJM+FD
+                  PRINT *,'Longitude? (D,M,S, east +ve)'
+                  READ (*,'(A)') B
+                  I=1
+                  CALL sla_DAFIN(B,I,ELONG,J)
+                  PRINT *,'Latitude? (D,M,S, (geodetic)'
+                  READ (*,'(A)') B
+                  I=1
+                  CALL sla_DAFIN(B,I,PHI,J)
+
+      *        Loop planet by planet
+                  DO NP=0,8
+
+      *           Get RA,Dec and diameter
+                     CALL sla_RDPLAN(DJM,NP,ELONG,PHI,RA,DEC,DIAM)
+
+      *           One line of report
+                     CALL sla_DR2TF(2,RA,S,IHMSF)
+                     CALL sla_DR2AF(1,DEC,S,IDMSF)
+                     WRITE (*,
+           : '(1X,A,2X,3I3.2,''.'',I2.2,2X,A,I2.2,2I3.2,''.'',I1,F8.1)')
+           :                          PNAMES(NP),IHMSF,S,IDMSF,R2AS*DIAM
+
+      *           Next planet
+                  END DO
+                  PRINT *,' '
+               END IF
+
+      *     Next case
+            END DO
+
+            END
+
+Entering the following data (for 1927 June 29 at $5^{\rm h}\,25^{\rm m}$ ET +and the position of Preston, UK.): +
+      1927 6 29
+      5 25
+      -2 42
+      53 46
+
+produces the following report: +
+      Sun       06 28 14.03  +23 17 17.5  1887.8
+      Mercury   08 08 58.62  +19 20 57.3     9.3
+      Venus     09 38 53.64  +15 35 32.9    22.8
+      Moon      06 28 18.30  +23 18 37.3  1903.9
+      Mars      09 06 49.34  +17 52 26.7     4.0
+      Jupiter   00 11 12.06  -00 10 57.5    41.1
+      Saturn    16 01 43.34  -18 36 55.9    18.2
+      Uranus    00 13 33.53  +00 39 36.0     3.5
+      Neptune   09 49 35.75  +13 38 40.8     2.2
+      Pluto     07 05 29.50  +21 25 04.2      .1
+
+Inspection of the Sun and Moon data reveals that +a total solar eclipse is in progress. +

+SLALIB also provides for the case where orbital elements (with respect +to the J2000 equinox and ecliptic) +are available. This allows predictions to be made for minor-planets and +(if you ignore non-gravitational effects) +comets. Furthermore, if major-planet elements for an epoch close to the date +in question are available, more accurate predictions can be made than +are offered by +sla_RDPLAN and +sla_PLANET. +

+The SLALIB planetary-prediction +routines that work with orbital elements are +sla_PLANTE (the orbital-elements equivalent of +sla_RDPLAN), which predicts the topocentric $[\,\alpha,\delta\,]$, and +sla_PLANEL (the orbital-elements equivalent of +sla_PLANET), which predicts the heliocentric $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ with respect to the +J2000 equinox and equator. In addition, the routine +sla_PV2EL does the inverse of +sla_PLANEL, transforming $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ into osculating elements. +

+Osculating elements describe the unperturbed 2-body orbit. This is +a good approximation to the actual orbit for a few weeks either +side of the specified epoch, outside which perturbations due to +the other bodies of the Solar System lead to +increasing errors. Given a minor planet's osculating elements for +a particular date, predictions for a date even just +100 days earlier or later +are likely to be in error by several arcseconds. +These errors can +be reduced if new elements are generated which take account of +the perturbations of the major planets, and this is what the routine +sla_PERTEL does. Once +sla_PERTEL has been called, to provide osculating elements +close to the required date, the elements can be passed to +sla_PLANEL or +sla_PLANTE in the normal way. Predictions of arcsecond accuracy +over a span of a decade or more are available using this +technique. +

+Three different combinations of orbital elements are +provided for, matching the usual conventions +for major planets, minor planets and +comets respectively. The choice is made through the +argument JFORM: +
+

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
JFORM=1JFORM=2JFORM=3
t0t0T
iii
$\Omega$$\Omega$$\Omega$
$\varpi$$\omega$$\omega$
aaq
eee
LM 
n  
+
+
+
+
+
+
+The symbols have the following meanings: +


+		 t0 epoch at which the elements were correct
+		 T epoch of perihelion passage
+		 i inclination of the orbit
+		 $\Omega$ longitude of the ascending node
+		 $\varpi$ longitude of perihelion ($\varpi = \Omega + \omega$)		 $\omega$ argument of perihelion
+		 a semi-major axis of the orbital ellipse
+		 q perihelion distance
+		 e orbital eccentricity
+		 L mean longitude ($L = \varpi + M$)		 M mean anomaly
+		 n mean motion 
+
+

+The mean motion, n, tells sla_PLANEL the mass of the planet. +If it is not available, it should be claculated +from n2 a3 = k2 (1+m), where k = 0.01720209895 and +m is the mass of the planet ($M_\odot = 1$); a is in AU. +

+Conventional elements are not the only way of specifying an orbit. +The $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ state vector is an equally valid specification, +and the so-called method of universal variables allows +orbital calculations to be made directly, bypassing angular +quantities and avoiding Kepler's Equation. The universal-variables +approach has various advantages, including better handling of +near-parabolic cases and greater efficiency. +SLALIB uses universal variables for its internal +calculations and also offers a number of routines which +applications can call. +

+The universal elements are the $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ and its epoch, plus the mass +of the body. The SLALIB routines supplement these elements with +certain redundant values in order to +avoid unnecessary recomputation when the elements are next used. +

+The routines +sla_EL2UE and +sla_UE2EL transform conventional elements into the +universal form and vice versa. +The routine +sla_PV2UE takes an $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ and forms the set of universal +elements; +sla_UE2PV takes a set of universal elements and predicts the $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ for a specified epoch. +The routine +sla_PERTUE provides updated universal elements, +taking into account perturbations from the major planets. +

+


+ +next + +up + +previous +
+ Next: Radial Velocity and Light-Time Corrections +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Geocentric Coordinates +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node225.html b/src/slalib/sun67.htx/node225.html new file mode 100644 index 0000000..ce716c7 --- /dev/null +++ b/src/slalib/sun67.htx/node225.html @@ -0,0 +1,143 @@ + + + + +Radial Velocity and Light-Time Corrections + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Focal-Plane Astrometry +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Ephemerides +

+

+

+Radial Velocity and Light-Time Corrections +

+When publishing high-resolution spectral observations +it is necessary to refer them to a specified standard of rest. +This involves knowing the component in the direction of the +source of the velocity of the observer. SLALIB provides a number +of routines for this purpose, allowing observations to be +referred to the Earth's centre, the Sun, a Local Standard of Rest +(either dynamical or kinematical), the centre of the Galaxy, and +the mean motion of the Local Group. +

+The routine +sla_RVEROT +corrects for the diurnal rotation of +the observer around the Earth's axis. This is always less than 0.5 km/s. +

+No specific routine is provided to correct a radial velocity +from geocentric to heliocentric, but this can easily be done by calling +sla_EVP +as follows (array declarations etc. omitted): +

+             :
+      *  Star vector, J2000
+            CALL sla_DCS2C(RM,DM,V)
+
+      *  Earth/Sun velocity and position, J2000
+            CALL sla_EVP(TDB,2000D0,DVB,DPB,DVH,DPH)
+
+      *  Radial velocity correction due to Earth orbit (km/s)
+            VCORB = -sla_DVDV(V,DVH)*149.597870D6
+             :
+
+

+The maximum value of this correction is the Earth's orbital speed +of about 30 km/s. A related routine, +sla_ECOR, +computes the light-time correction with respect to the Sun. It +would be used when reducing observations of a rapid variable-star +for instance. +Note, however, that the accuracy objectives for pulsar work are +beyond the scope of these SLALIB routines, and even the superior +sla_EVP +routine is unsuitable for arrival-time calculations of better +than 25 millisecond accuracy. +

+To remove the intrinsic $\sim20$ km/s motion of the Sun relative +to other stars in the solar neighbourhood, +a velocity correction to a +local standard of rest (LSR) is required. There are +opportunities for mistakes here. There are two sorts of LSR, +dynamical and kinematical, and +multiple definitions exist for the latter. The +dynamical LSR is a point near the Sun which is in a circular +orbit around the Galactic centre; the Sun has a ``peculiar'' +motion relative to the dynamical LSR. A kinematical LSR is +the mean standard of rest of specified star catalogues or stellar +populations, and its precise definition depends on which +catalogues or populations were used and how the analysis was +carried out. The Sun's motion with respect to a kinematical +LSR is called the ``standard'' solar motion. Radial +velocity corrections to the dynamical LSR are produced by the routine +sla_RVLSRD +and to the adopted kinematical LSR by +sla_RVLSRK. +See the individual specifications for these routines for the +precise definition of the LSR in each case. +

+For extragalactic sources, the centre of the Galaxy can be used as +a standard of rest. The radial velocity correction from the +dynamical LSR to the Galactic centre can be obtained by calling +sla_RVGALC. +Its maximum value is 220 km/s. +

+For very distant sources it is appropriate to work relative +to the mean motion of the Local Group. The routine for +computing the radial velocity correction in this case is +sla_RVLG. +Note that in this case the correction is with respect to the +dynamical LSR, not the Galactic centre as might be expected. +This conforms to the IAU definition, and confers immunity from +revisions of the Galactic rotation speed. +

+


+ +next + +up + +previous +
+ Next: Focal-Plane Astrometry +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Ephemerides +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node226.html b/src/slalib/sun67.htx/node226.html new file mode 100644 index 0000000..41baa89 --- /dev/null +++ b/src/slalib/sun67.htx/node226.html @@ -0,0 +1,212 @@ + + + + +Focal-Plane Astrometry + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Numerical Methods +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Radial Velocity and Light-Time Corrections +

+

+

+Focal-Plane Astrometry +

+The relationship between the position of a star image in +the focal plane of a telescope and the star's celestial +coordinates is usually described in terms of the tangent plane +or gnomonic projection. This is the projection produced +by a pin-hole camera and is a good approximation to the projection +geometry of a traditional large f-ratio astrographic refractor. +SLALIB includes a group of routines which transform +star positions between their observed places on the celestial +sphere and their $[\,x,y\,]$ coordinates in the tangent plane. The +spherical coordinate system does not have to be $[\,\alpha,\delta\,]$ but +usually is. The so-called standard coordinates of a star +are the tangent plane $[\,x,y\,]$, in radians, with respect to an origin +at the tangent point, with the y-axis pointing north and +the x-axis pointing east (in the direction of increasing $\alpha$). +The factor relating the standard coordinates to +the actual $[\,x,y\,]$ coordinates in, say, millimetres is simply +the focal length of the telescope. +

+Given the $[\,\alpha,\delta\,]$ of the plate centre (the tangent point) +and the $[\,\alpha,\delta\,]$ of a star within the field, the standard +coordinates can be determined by calling +sla_S2TP +(single precision) or +sla_DS2TP +(double precision). The reverse transformation, where the +$[\,x,y\,]$ is known and we wish to find the $[\,\alpha,\delta\,]$, is carried out by calling +sla_TP2S +or +sla_DTP2S. +Occasionally we know the both the $[\,x,y\,]$ and the $[\,\alpha,\delta\,]$ of a +star and need to deduce the $[\,\alpha,\delta\,]$ of the tangent point; +this can be done by calling +sla_TPS2C +or +sla_DTPS2C. +(All of these transformations apply not just to $[\,\alpha,\delta\,]$ but to +other spherical coordinate systems, of course.) +Equivalent (and faster) +routines are provided which work directly in $[\,x,y,z\,]$ instead of +spherical coordinates: +sla_V2TP and +sla_DV2TP, +sla_TP2V and +sla_DTP2V, +sla_TPV2C and +sla_DTPV2C. +

+Even at the best of times, the tangent plane projection is merely an +approximation. Some telescopes and cameras exhibit considerable pincushion +or barrel distortion and some have a curved focal surface. +For example, neither Schmidt cameras nor (especially) +large reflecting telescopes with wide-field corrector lenses +are adequately modelled by tangent-plane geometry. In such +cases, however, it is still possible to do most of the work +using the (mathematically convenient) tangent-plane +projection by inserting an extra step which applies or +removes the distortion peculiar to the system concerned. +A simple r1=r0(1+Kr02) law works well in the +majority of cases; r0 is the radial distance in the +tangent plane, r1 is the radial distance after adding +the distortion, and K is a constant which depends on the +telescope ($\theta$ is unaffected). The routine +sla_PCD +applies the distortion to an $[\,x,y\,]$ and +sla_UNPCD +removes it. For $[\,x,y\,]$ in radians, K values range from -1/3 for the +tiny amount of barrel distortion in Schmidt geometry to several +hundred for the serious pincushion distortion +produced by wide-field correctors in big reflecting telescopes +(the AAT prime focus triplet corrector is about K=+178.6). +

+SLALIB includes a group of routines which can be put together +to build a simple plate-reduction program. The heart of the group is +sla_FITXY, +which fits a linear model to relate two sets of $[\,x,y\,]$ coordinates, +in the case of a plate reduction the measured positions of the +images of a set of +reference stars and the standard +coordinates derived from their catalogue positions. The +model is of the form: + +

+xp = a + bxm + cym +

+ +

+yp = d + exm + fym +

+

+where the p subscript indicates ``predicted'' coordinates +(the model's approximation to the ideal ``expected'' coordinates) and the +m subscript indicates ``measured coordinates''. The +six coefficients a-f can optionally be +constrained to represent a ``solid body rotation'' free of +any squash or shear distortions. Without this constraint +the model can, to some extent, accommodate effects like refraction, +allowing mean places to be used directly and +avoiding the extra complications of a +full mean-apparent-observed transformation for each star. +Having obtained the linear model, +sla_PXY +can be used to process the set of measured and expected +coordinates, giving the predicted coordinates and determining +the RMS residuals in x and y. +The routine +sla_XY2XY +transforms one $[\,x,y\,]$ into another using the linear model. A model +can be inverted by calling +sla_INVF, +and decomposed into zero points, scales, x/y nonperpendicularity +and orientation by calling +sla_DCMPF. +

+


+ +next + +up + +previous +
+ Next: Numerical Methods +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Radial Velocity and Light-Time Corrections +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node227.html b/src/slalib/sun67.htx/node227.html new file mode 100644 index 0000000..9ed563a --- /dev/null +++ b/src/slalib/sun67.htx/node227.html @@ -0,0 +1,230 @@ + + + + +Numerical Methods + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SUMMARY OF CALLS +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Focal-Plane Astrometry +

+

+

+Numerical Methods +

+SLALIB contains a small number of simple, general-purpose +numerical-methods routines. They have no specific +connection with positional astronomy but have proved useful in +applications to do with simulation and fitting. +

+At the heart of many simulation programs is the generation of +pseudo-random numbers, evenly distributed in a given range: +sla_RANDOM +does this. Pseudo-random normal deviates, or ``Gaussian +residuals'', are often required to simulate noise and +can be generated by means of the function +sla_GRESID. +Neither routine will pass super-sophisticated +statistical tests, but they work adequately for most +practical purposes and avoid the need to call non-standard +library routines peculiar to one sort of computer. +

+Applications which perform a least-squares fit using a traditional +normal-equations methods can accomplish the required matrix-inversion +by calling either +sla_SMAT +(single precision) or +sla_DMAT +(double). A generally better way to perform such fits is +to use singular value decomposition. SLALIB provides a routine +to do the decomposition itself, +sla_SVD, +and two routines to use the results: +sla_SVDSOL +generates the solution, and +sla_SVDCOV +produces the covariance matrix. +A simple demonstration of the use of the SLALIB SVD +routines is given below. It generates 500 simulated data +points and fits them to a model which has 4 unknown coefficients. +(The arrays in the example are sized to accept up to 1000 +points and 20 unknowns.) The model is: + +

+y = C1 +C2x +C3sinx +C4cosx +

+The test values for the four coefficients are +$C_1\!=\!+50.0$,$C_2\!=\!-2.0$,$C_3\!=\!-10.0$ and +$C_4\!=\!+25.0$.Gaussian noise, $\sigma=5.0$, is added to each ``observation''. +

+            IMPLICIT NONE
+
+      *  Sizes of arrays, physical and logical
+            INTEGER MP,NP,NC,M,N
+            PARAMETER (MP=1000,NP=10,NC=20,M=500,N=4)
+
+      *  The unknowns we are going to solve for
+            DOUBLE PRECISION C1,C2,C3,C4
+            PARAMETER (C1=50D0,C2=-2D0,C3=-10D0,C4=25D0)
+
+      *  Arrays
+            DOUBLE PRECISION A(MP,NP),W(NP),V(NP,NP),
+           :                 WORK(NP),B(MP),X(NP),CVM(NC,NC)
+
+            DOUBLE PRECISION VAL,BF1,BF2,BF3,BF4,SD2,D,VAR
+            REAL sla_GRESID
+            INTEGER I,J
+
+      *  Fill the design matrix
+            DO I=1,M
+
+      *     Dummy independent variable
+               VAL=DBLE(I)/10D0
+
+      *     The basis functions
+               BF1=1D0
+               BF2=VAL
+               BF3=SIN(VAL)
+               BF4=COS(VAL)
+
+      *     The observed value, including deliberate Gaussian noise
+               B(I)=C1*BF1+C2*BF2+C3*BF3+C4*BF4+DBLE(sla_GRESID(5.0))
+
+      *     Fill one row of the design matrix
+               A(I,1)=BF1
+               A(I,2)=BF2
+               A(I,3)=BF3
+               A(I,4)=BF4
+            END DO
+
+      *  Factorize the design matrix, solve and generate covariance matrix
+            CALL sla_SVD(M,N,MP,NP,A,W,V,WORK,J)
+            CALL sla_SVDSOL(M,N,MP,NP,B,A,W,V,WORK,X)
+            CALL sla_SVDCOV(N,NP,NC,W,V,WORK,CVM)
+
+      *  Compute the variance
+            SD2=0D0
+            DO I=1,M
+               VAL=DBLE(I)/10D0
+               BF1=1D0
+               BF2=VAL
+               BF3=SIN(VAL)
+               BF4=COS(VAL)
+               D=B(I)-(X(1)*BF1+X(2)*BF2+X(3)*BF3+X(4)*BF4)
+               SD2=SD2+D*D
+            END DO
+            VAR=SD2/DBLE(M)
+
+      *  Report the RMS and the solution
+            WRITE (*,'(1X,''RMS ='',F5.2/)') SQRT(VAR)
+            DO I=1,N
+               WRITE (*,'(1X,''C'',I1,'' ='',F7.3,'' +/-'',F6.3)')
+           :                                         I,X(I),SQRT(VAR*CVM(I,I))
+            END DO
+            END
+
+

+The program produces the following output: +

+            RMS = 4.88
+
+            C1 = 50.192 +/- 0.439
+            C2 = -2.002 +/- 0.015
+            C3 = -9.771 +/- 0.310
+            C4 = 25.275 +/- 0.310
+
+

+In this above example, essentially +identical results would be obtained if the more +commonplace normal-equations method had been used, and the large +$1000\times20$ array would have been avoided. However, the SVD method +comes into its own when the opportunity is taken to edit the W-matrix +(the so-called ``singular values'') in order to control +possible ill-conditioning. The procedure involves replacing with +zeroes any W-elements smaller than a nominated value, for example +0.001 times the largest W-element. Small W-elements indicate +ill-conditioning, which in the case of the normal-equations +method would produce spurious large coefficient values and +possible arithmetic overflows. Using SVD, the effect on the solution +of setting suspiciously small W-elements to zero is to restrain +the offending coefficients from moving very far. The +fact that action was taken can be reported to show the program user that +something is amiss. Furthermore, if element W(J) was set to zero, +the row numbers of the two biggest elements in the Jth column of the +V-matrix identify the pair of solution coefficients that are +dependent. +

+A more detailed description of SVD and its use in least-squares +problems would be out of place here, and the reader is urged +to refer to the relevant sections of the book Numerical Recipes +(Press et al., Cambridge University Press, 1987). +

+The routines +sla_COMBN +and +sla_PERMUT +are useful for problems which involve combinations (different subsets) +and permutations (different orders). +Both return the next in a sequence of results, cycling through all the +possible results as the routine is called repeatedly. +

+
+

+


+ +next + +up + +previous +
+ Next: SUMMARY OF CALLS +
+Up: EXPLANATION AND EXAMPLES +
+ Previous: Focal-Plane Astrometry +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node228.html b/src/slalib/sun67.htx/node228.html new file mode 100644 index 0000000..f21ae0e --- /dev/null +++ b/src/slalib/sun67.htx/node228.html @@ -0,0 +1,696 @@ + + + + +SUMMARY OF CALLS + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: About this document ... +
+Up: SLALIB Positional Astronomy Library +
+ Previous: Numerical Methods +

+

+

+SUMMARY OF CALLS +

+The basic trigonometrical and numerical facilities are supplied in both single +and double precision versions. +Most of the more esoteric position and time routines use double precision +arguments only, even in cases where single precision would normally be adequate +in practice. +Certain routines with modest accuracy objectives are supplied in +single precision versions only. +In the calling sequences which follow, no attempt has been made +to distinguish between single and double precision argument names, +and frequently the same name is used on different occasions to +mean different things. +However, none of the routines uses a mixture of single and +double precision arguments; each routine is either wholly +single precision or wholly double precision. +

+In the classified list, below, +subroutine subprograms are those whose names and argument lists +are preceded by `CALL', whereas function subprograms are +those beginning `R=' (when the result is REAL) or `D=' (when +the result is DOUBLE PRECISION). +

+The list is, of course, merely for quick reference; inexperienced +users must refer to the detailed specifications given later. +In particular, don't guess whether arguments are single or +double precision; the result could be a program that happens to +works on one sort of machine but not on another. +

+
String Decoding

+
Sexagesimal Conversions +
Angles, Vectors and Rotation Matrices +
Calendars +
Timescales +
Precession and Nutation +
Proper Motion +
FK4/FK5/Hipparcos Conversions +
Elliptic Aberration +
Geographical and Geocentric Coordinates +
Apparent and Observed Place +
Azimuth and Elevation +
Refraction and Air Mass +
Ecliptic Coordinates +
Galactic Coordinates +
Supergalactic Coordinates +
Ephemerides +
Astrometry +
Numerical Methods +
Real-time +

+ +next + +up + +previous +
+ Next: About this document ... +
+Up: SLALIB Positional Astronomy Library +
+ Previous: Numerical Methods +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node229.html b/src/slalib/sun67.htx/node229.html new file mode 100644 index 0000000..ac949b4 --- /dev/null +++ b/src/slalib/sun67.htx/node229.html @@ -0,0 +1,65 @@ + + + + +About this document ... + + + + + + + + + + +

+next + +up + +previous +
+Up: SLALIB Positional Astronomy Library +
+ Previous: SUMMARY OF CALLS +

+

+

+About this document ... +

+

+This document was generated using the +LaTeX2HTML translator Version 97.1 (release) (July 13th, 1997) +

+Copyright © 1993, 1994, 1995, 1996, 1997, +Nikos Drakos, +Computer Based Learning Unit, University of Leeds. +

+The command line arguments were:
+ latex2html -init_file .star2html-init -no_subdir -no_auto_link /home/user1/dec/ptw/hypertext/sun67_htx//sun67.tex. +

+The translation was initiated by Pat Wallace on 10/12/1999 +


+next + +up + +previous +
+Up: SLALIB Positional Astronomy Library +
+ Previous: SUMMARY OF CALLS +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node23.html b/src/slalib/sun67.htx/node23.html new file mode 100644 index 0000000..dfb0e24 --- /dev/null +++ b/src/slalib/sun67.htx/node23.html @@ -0,0 +1,278 @@ + + + + +SLA_AOPQK - Quick Appt-to-Observed + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_ATMDSP - Atmospheric Dispersion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AOPPAT - Update Appt-to-Obs Parameters +

+

+

SLA_AOPQK - Quick Appt-to-Observed +   +

+
+
ACTION: +
Quick apparent to observed place (but see Note 8, below). +
CALL: +
CALL sla_AOPQK (RAP, DAP, AOPRMS, AOB, ZOB, HOB, DOB, ROB) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
RAP,DAPDgeocentric apparent $[\,\alpha,\delta\,]$ (radians)
AOPRMSD(14)star-independent apparent-to-observed parameters:
(1)geodetic latitude (radians)
(2,3)sine and cosine of geodetic latitude
(4)magnitude of diurnal aberration vector
(5)height (metres)
(6)ambient temperature (degrees K)
(7)pressure (mB)
(8)relative humidity (0-1)
(9)wavelength ($\mu{\rm m}$)
(10)lapse rate (degrees K per metre)
(11,12)refraction constants A and B (radians)
(13)longitude + eqn of equinoxes + +``sidereal $\Delta$UT'' (radians)
(14)local apparent sidereal time (radians)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + +
AOBDobserved azimuth (radians: N=0, E=$90^{\circ}$)
ZOBDobserved zenith distance (radians)
HOBDobserved Hour Angle (radians)
DOBDobserved Declination (radians)
ROBDobserved Right Ascension (radians)
+

+
NOTES: +
+
1. +
This routine returns zenith distance rather than elevation +in order to reflect the fact that no allowance is made for +depression of the horizon. +
2. +
The accuracy of the result is limited by the corrections for + refraction. Providing the meteorological parameters are + known accurately and there are no gross local effects, the + predicted azimuth and elevation should be within about +

$0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.1$ for $\zeta<70^{\circ}$. Even + at a topocentric zenith distance of + $90^{\circ}$, the accuracy in elevation should be better than + 1 arcminute; useful results are available for a further + $3^{\circ}$, beyond which the sla_REFRO routine returns a + fixed value of the refraction. The complementary + routines sla_AOP (or sla_AOPQK) and sla_OAP (or sla_OAPQK) + are self-consistent to better than 1 microarcsecond all over + the celestial sphere. +

3. +
It is advisable to take great care with units, as even + unlikely values of the input parameters are accepted and + processed in accordance with the models used. +
4. +
Apparent $[\,\alpha,\delta\,]$ means the geocentric apparent right ascension + and declination, which is obtained from a catalogue mean place + by allowing for space motion, parallax, precession, nutation, + annual aberration, and the Sun's gravitational lens effect. For + star positions in the FK5 system (i.e. J2000), these effects can + be applied by means of the sla_MAP etc. routines. Starting from + other mean place systems, additional transformations will be + needed; for example, FK4 (i.e. B1950) mean places would first + have to be converted to FK5, which can be done with the + sla_FK425 etc. routines. +
5. +
Observed $[\,Az,El~]$ means the position that would be seen by a + perfect theodolite located at the observer. This is obtained + from the geocentric apparent $[\,\alpha,\delta\,]$ by allowing for Earth + orientation and diurnal aberration, rotating from equator + to horizon coordinates, and then adjusting for refraction. + The $[\,h,\delta\,]$ is obtained by rotating back into equatorial + coordinates, using the geodetic latitude corrected for polar + motion, and is the position that would be seen by a perfect + equatorial located at the observer and with its polar axis + aligned to the Earth's axis of rotation (n.b. not to the + refracted pole). Finally, the $\alpha$ is obtained by subtracting + the h from the local apparent ST. +
6. +
To predict the required setting of a real telescope, the + observed place produced by this routine would have to be + adjusted for the tilt of the azimuth or polar axis of the + mounting (with appropriate corrections for mount flexures), + for non-perpendicularity between the mounting axes, for the + position of the rotator axis and the pointing axis relative + to it, for tube flexure, for gear and encoder errors, and + finally for encoder zero points. Some telescopes would, of + course, exhibit other properties which would need to be + accounted for at the appropriate point in the sequence. +
7. +
The star-independent apparent-to-observed-place parameters + in AOPRMS may be computed by means of the sla_AOPPA routine. + If nothing has changed significantly except the time, the + sla_AOPPAT routine may be used to perform the requisite + partial recomputation of AOPRMS. +
8. +
The ``sidereal $\Delta$UT'' which forms part of AOPRMS(13) + is UT1-UTC converted from solar to + sidereal seconds and expressed in radians. +
9. +
At zenith distances beyond about $76^\circ$, the need for + special care with the corrections for refraction causes a + marked increase in execution time. Moreover, the effect + gets worse with increasing zenith distance. Adroit + programming in the calling application may allow the + problem to be reduced. Prepare an alternative AOPRMS array, + computed for zero air-pressure; this will disable the + refraction corrections and cause rapid execution. Using + this AOPRMS array, a preliminary call to the present routine + will, depending on the application, produce a rough position + which may be enough to establish whether the full, slow + calculation (using the real AOPRMS array) is worthwhile. + For example, there would be no need for the full calculation + if the preliminary call had already established that the + source was well below the elevation limits for a particular + telescope. +
10. +
The azimuths etc. used by the present routine are with + respect to the celestial pole. Corrections to the terrestrial pole + can be computed using sla_POLMO. +
+

+ +next + +up + +previous +
+ Next: SLA_ATMDSP - Atmospheric Dispersion +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AOPPAT - Update Appt-to-Obs Parameters +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node24.html b/src/slalib/sun67.htx/node24.html new file mode 100644 index 0000000..aecbb98 --- /dev/null +++ b/src/slalib/sun67.htx/node24.html @@ -0,0 +1,213 @@ + + + + +SLA_ATMDSP - Atmospheric Dispersion + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_AV2M - Rotation Matrix from Axial Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AOPQK - Quick Appt-to-Observed +

+

+

SLA_ATMDSP - Atmospheric Dispersion +   +

+
+
ACTION: +
Apply atmospheric-dispersion adjustments to refraction coefficients. +
CALL: +
CALL sla_ATMDSP (TDK, PMB, RH, WL1, A1, B1, WL2, A2, B2) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TDKDambient temperature at the observer (degrees K)
PMBDpressure at the observer (mB)
RHDrelative humidity at the observer (range 0-1)
WL1Dbase wavelength ($\mu{\rm m}$)
A1Drefraction coefficient A for wavelength WL1 (radians)
B1Drefraction coefficient B for wavelength WL1 (radians)
WL2Dwavelength for which adjusted A,B required ($\mu{\rm m}$)
+

+
RETURNED: +
+
+ + + + + + + + + +
A2Drefraction coefficient A for wavelength WL2 (radians)
B2Drefraction coefficient B for wavelength WL2 (radians)
+

+
NOTES: +
+
1. +
To use this routine, first call sla_REFCO specifying WL1 as the +wavelength. This yields refraction coefficients A1, B1, correct +for that wavelength. Subsequently, calls to sla_ATMDSP specifying + different wavelengths will produce new, slightly adjusted + refraction coefficients A2, B2, which apply to the specified wavelength. +
2. +
Most of the atmospheric dispersion happens between $0.7\,\mu{\rm m}$ and the UV atmospheric cutoff, and the effect increases strongly + towards the UV end. For this reason a blue reference wavelength + is recommended, for example $0.4\,\mu{\rm m}$.
3. +
The accuracy, for this set of conditions:
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
height above sea level 2000m
latitude $29^\circ$
pressure 793mB
temperature $290^\circ$K
humidity 0.5 (50%)
lapse rate $0.0065^\circ m^{-1}$
reference wavelength $0.4\,\mu{\rm m}$
star elevation $15^\circ$
+
+
+is about 2.5mas RMS between 0.3 and $1.0\,\mu{\rm m}$, and stays + within 4mas for the whole range longward of $0.3\,\mu{\rm m}$ (compared with a total dispersion from 0.3 to $20\,\mu{\rm m}$ of about $11\hspace{-0.05em}^{'\hspace{-0.1em}'}$). These errors are typical for ordinary + conditions; in extreme conditions values a few times this size + may occur. +
4. +
If either wavelength exceeds $100\,\mu{\rm m}$, the radio case + is assumed and the returned refraction coefficients are the + same as the given ones. +
5. +
The algorithm consists of calculation of the refractivity of the + air at the observer for the two wavelengths, using the methods + of the sla_REFRO routine, and then scaling of the two refraction + coefficients according to classical refraction theory. This + amounts to scaling the A coefficient in proportion to $(\mu-1)$ and + the B coefficient almost in the same ratio (see R.M.Green, + Spherical Astronomy, Cambridge University Press, 1985). +
+

+ +next + +up + +previous +
+ Next: SLA_AV2M - Rotation Matrix from Axial Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AOPQK - Quick Appt-to-Observed +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node25.html b/src/slalib/sun67.htx/node25.html new file mode 100644 index 0000000..f557394 --- /dev/null +++ b/src/slalib/sun67.htx/node25.html @@ -0,0 +1,103 @@ + + + + +SLA_AV2M - Rotation Matrix from Axial Vector + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_BEAR - Direction Between Points on a Sphere +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ATMDSP - Atmospheric Dispersion +

+

+

SLA_AV2M - Rotation Matrix from Axial Vector +   +

+
+
ACTION: +
Form the rotation matrix corresponding to a given axial vector +(single precision). +

CALL: +
CALL sla_AV2M (AXVEC, RMAT) +

+

+
GIVEN: +
+
+ + + + + +
AXVECR(3)axial vector (radians)
+

+
RETURNED: +
+
+ + + + + +
RMATR(3,3)rotation matrix
+

+
NOTES: +
+
1. +
A rotation matrix describes a rotation about some arbitrary axis. +The axis is called the Euler axis, and the angle through which the +reference frame rotates is called the Euler angle. The axial + vector supplied to this routine has the same direction as the + Euler axis, and its magnitude is the Euler angle in radians. +
2. +
If AXVEC is null, the unit matrix is returned. +
3. +
The reference frame rotates clockwise as seen looking along + the axial vector from the origin. +
+

+ +next + +up + +previous +
+ Next: SLA_BEAR - Direction Between Points on a Sphere +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ATMDSP - Atmospheric Dispersion +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node26.html b/src/slalib/sun67.htx/node26.html new file mode 100644 index 0000000..8296b32 --- /dev/null +++ b/src/slalib/sun67.htx/node26.html @@ -0,0 +1,123 @@ + + + + +SLA_BEAR - Direction Between Points on a Sphere + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CAF2R - Deg,Arcmin,Arcsec to Radians +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AV2M - Rotation Matrix from Axial Vector +

+

+

SLA_BEAR - Direction Between Points on a Sphere +   +

+
+
ACTION: +
Returns the bearing (position angle) of one point on a +sphere seen from another (single precision). +

CALL: +
R = sla_BEAR (A1, B1, A2, B2) +

+

+
GIVEN: +
+
+ + + + + + + + + +
A1,B1Rspherical coordinates of one point
A2,B2Rspherical coordinates of the other point
+

+
RETURNED: +
+
+ + + + + +
sla_BEARRbearing from first point to second
+

+
NOTES: +
+
1. +
The spherical coordinates are $[\,\alpha,\delta\,]$,$[\lambda,\phi]$ etc., in radians. +
2. +
The result is the bearing (position angle), in radians, + of point [A2,B2] as seen + from point [A1,B1]. It is in the range $\pm \pi$. The sense + is such that if [A2,B2] + is a small distance due east of [A1,B1] the result + is about $+\pi/2$. Zero is returned + if the two points are coincident. +
3. +
If either B-coordinate is outside the range $\pm\pi/2$, the + result may correspond to ``the long way round''. +
4. +
The routine sla_PAV performs an equivalent function except + that the points are specified in the form of Cartesian unit + vectors. +
+

+ +next + +up + +previous +
+ Next: SLA_CAF2R - Deg,Arcmin,Arcsec to Radians +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_AV2M - Rotation Matrix from Axial Vector +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node27.html b/src/slalib/sun67.htx/node27.html new file mode 100644 index 0000000..6c176b5 --- /dev/null +++ b/src/slalib/sun67.htx/node27.html @@ -0,0 +1,122 @@ + + + + +SLA_CAF2R - Deg,Arcmin,Arcsec to Radians + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CALDJ - Calendar Date to MJD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_BEAR - Direction Between Points on a Sphere +

+

+

SLA_CAF2R - Deg,Arcmin,Arcsec to Radians +   +

+
+
ACTION: +
Convert degrees, arcminutes, arcseconds to radians +(single precision). +

CALL: +
CALL sla_CAF2R (IDEG, IAMIN, ASEC, RAD, J) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
IDEGIdegrees
IAMINIarcminutes
ASECRarcseconds
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + +
RADRangle in radians
JIstatus:
1 = IDEG outside range 0-359
2 = IAMIN outside range 0-59
3 = ASEC outside range 0-59.999$\cdots$
+

+
NOTES: +
+
1. +
The result is computed even if any of the range checks fail. +
2. +
The sign must be dealt with outside this routine. +
+

+ +next + +up + +previous +
+ Next: SLA_CALDJ - Calendar Date to MJD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_BEAR - Direction Between Points on a Sphere +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node28.html b/src/slalib/sun67.htx/node28.html new file mode 100644 index 0000000..33bc93d --- /dev/null +++ b/src/slalib/sun67.htx/node28.html @@ -0,0 +1,128 @@ + + + + +SLA_CALDJ - Calendar Date to MJD + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CALYD - Calendar to Year, Day +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CAF2R - Deg,Arcmin,Arcsec to Radians +

+

+

SLA_CALDJ - Calendar Date to MJD +   +

+
+
ACTION: +
Gregorian Calendar to Modified Julian Date, with century default. +
CALL: +
CALL sla_CALDJ (IY, IM, ID, DJM, J) +

+

+
GIVEN: +
+
+ + + + + +
IY,IM,IDIyear, month, day in Gregorian calendar
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
DJMDmodified Julian Date (JD-2400000.5) for $0^{\rm h}$
JIstatus:
0 = OK
1 = bad year (MJD not computed)
2 = bad month (MJD not computed)
3 = bad day (MJD computed)
+

+
NOTES: +
+
1. +
This routine supports the century default feature. +Acceptable years are: +
    +
  • 00-49, interpreted as 2000-2049, +
  • 50-99, interpreted as 1950-1999, and +
  • 100 upwards, interpreted literally. +
+ For 1-100AD use the routine sla_CLDJ instead. +
2. +
For year nBC use IY = -(n-1). +
3. +
When an invalid year or month is supplied (status J = 1 or 2) + the MJD is not computed. When an invalid day is supplied + (status J = 3) the MJD is computed. +
+

+ +next + +up + +previous +
+ Next: SLA_CALYD - Calendar to Year, Day +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CAF2R - Deg,Arcmin,Arcsec to Radians +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node29.html b/src/slalib/sun67.htx/node29.html new file mode 100644 index 0000000..f831e5a --- /dev/null +++ b/src/slalib/sun67.htx/node29.html @@ -0,0 +1,140 @@ + + + + +SLA_CALYD - Calendar to Year, Day + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CC2S - Cartesian to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CALDJ - Calendar Date to MJD +

+

+

SLA_CALYD - Calendar to Year, Day +   +

+
+
ACTION: +
Gregorian calendar date to year and day in year, in a Julian +calendar aligned to the 20th/21st century Gregorian calendar, + with century default. +

CALL: +
CALL sla_CALYD (IY, IM, ID, NY, ND, J) +

+

+
GIVEN: +
+
+ + + + + +
IY,IM,IDIyear, month, day in Gregorian calendar: +year may optionally omit the century
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NYIyear (re-aligned Julian calendar)
NDIday in year (1 = January 1st)
JIstatus:
0 = OK
1 = bad year (before -4711)
2 = bad month
3 = bad day
+

+
NOTES: +
+
1. +
This routine supports the century default feature. +Acceptable years are: +
    +
  • 00-49, interpreted as 2000-2049, +
  • 50-99, interpreted as 1950-1999, and +
  • other years after -4712 , interpreted literally. +
+ Use sla_CLYD for years before 100AD. +
2. +
The purpose of sla_CALDJ is to support + sla_EARTH, sla_MOON and sla_ECOR. +
3. +
Between 1900 March 1 and 2100 February 28 it returns answers + which are consistent with the ordinary Gregorian calendar. + Outside this range there will be a discrepancy which increases + by one day for every non-leap century year. +
4. +
When an invalid year or month is supplied (status J = 1 or J = 2) + the results are not computed. When a day is + supplied which is outside the conventional range (status J = 3) + the results are computed. +
+

+ +next + +up + +previous +
+ Next: SLA_CC2S - Cartesian to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CALDJ - Calendar Date to MJD +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node3.html b/src/slalib/sun67.htx/node3.html new file mode 100644 index 0000000..886a149 --- /dev/null +++ b/src/slalib/sun67.htx/node3.html @@ -0,0 +1,76 @@ + + + + +Purpose + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Example Application +
+Up: INTRODUCTION +
+ Previous: INTRODUCTION +

+

+

+Purpose +

+SLALIB[*] +is a library of routines +intended to make accurate and reliable positional-astronomy +applications easier to write. +Most SLALIB routines are concerned with astronomical position and time, but a +number have wider trigonometrical, numerical or general applications. +The applications ASTROM, COCO, RV and TPOINT +all make extensive use of the SLALIB +routines, as do a number of telescope control systems around the world. +The SLALIB versions currently in service are written in +Fortran 77 and run on VAX/VMS, several Unix platforms and PC. +A generic ANSI C version is also available from the author; it is +functionally similar to the Fortran version upon which the present +document concentrates. +

+


+ +next + +up + +previous +
+ Next: Example Application +
+Up: INTRODUCTION +
+ Previous: INTRODUCTION +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node30.html b/src/slalib/sun67.htx/node30.html new file mode 100644 index 0000000..21b121e --- /dev/null +++ b/src/slalib/sun67.htx/node30.html @@ -0,0 +1,103 @@ + + + + +SLA_CC2S - Cartesian to Spherical + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CC62S - Cartesian 6-Vector to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CALYD - Calendar to Year, Day +

+

+

SLA_CC2S - Cartesian to Spherical +   +

+
+
ACTION: +
Cartesian coordinates to spherical coordinates (single precision). +
CALL: +
CALL sla_CC2S (V, A, B) +

+

+
GIVEN: +
+
+ + + + + +
VR(3)$[\,x,y,z\,]$ vector
+

+
RETURNED: +
+
+ + + + + +
A,BRspherical coordinates in radians
+

+
NOTES: +
+
1. +
The spherical coordinates are longitude (+ve anticlockwise +looking from the +ve latitude pole) and latitude. The +Cartesian coordinates are right handed, with the x-axis + at zero longitude and latitude, and the z-axis at the + +ve latitude pole. +
2. +
If V is null, zero A and B are returned. +
3. +
At either pole, zero A is returned. +
+

+ +next + +up + +previous +
+ Next: SLA_CC62S - Cartesian 6-Vector to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CALYD - Calendar to Year, Day +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node31.html b/src/slalib/sun67.htx/node31.html new file mode 100644 index 0000000..1877958 --- /dev/null +++ b/src/slalib/sun67.htx/node31.html @@ -0,0 +1,114 @@ + + + + +SLA_CC62S - Cartesian 6-Vector to Spherical + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CD2TF - Days to Hour,Min,Sec +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CC2S - Cartesian to Spherical +

+

+

SLA_CC62S - Cartesian 6-Vector to Spherical +   +

+
+
ACTION: +
Conversion of position & velocity in Cartesian coordinates +to spherical coordinates (single precision). +

CALL: +
CALL sla_CC62S (V, A, B, R, AD, BD, RD) +

+

+
GIVEN: +
+
+ + + + + +
VR(6)$[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
ARlongitude (radians) - for example $\alpha$
BRlatitude (radians) - for example $\delta$
RRradial coordinate
ADRlongitude derivative (radians per unit time)
BDRlatitude derivative (radians per unit time)
RDRradial derivative
+

+ +next + +up + +previous +
+ Next: SLA_CD2TF - Days to Hour,Min,Sec +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CC2S - Cartesian to Spherical +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node32.html b/src/slalib/sun67.htx/node32.html new file mode 100644 index 0000000..9d7f8ab --- /dev/null +++ b/src/slalib/sun67.htx/node32.html @@ -0,0 +1,115 @@ + + + + +SLA_CD2TF - Days to Hour,Min,Sec + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CLDJ - Calendar to MJD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CC62S - Cartesian 6-Vector to Spherical +

+

+

SLA_CD2TF - Days to Hour,Min,Sec +   +

+
+
ACTION: +
Convert an interval in days to hours, minutes, seconds +(single precision). +

CALL: +
CALL sla_CD2TF (NDP, DAYS, SIGN, IHMSF) +

+

+
GIVEN: +
+
+ + + + + + + + + +
NDPInumber of decimal places of seconds
DAYSRinterval in days
+

+
RETURNED: +
+
+ + + + + + + + + +
SIGNC`+' or `-'
IHMSFI(4)hours, minutes, seconds, fraction
+

+
NOTES: +
+
1. +
NDP less than zero is interpreted as zero. +
2. +
The largest useful value for NDP is determined by the size of +DAYS, the format of REAL floating-point numbers on the target + machine, and the risk of overflowing IHMSF(4). For example, + on a VAX computer, for DAYS up to 1.0, the available floating-point + precision corresponds roughly to NDP=3. This is well below + the ultimate limit of NDP=9 set by the capacity of the 32-bit + integer IHMSF(4). +
3. +
The absolute value of DAYS may exceed 1.0. In cases where it + does not, it is up to the caller to test for and handle the + case where DAYS is very nearly 1.0 and rounds up to 24 hours, + by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +
+

+ +next + +up + +previous +
+ Next: SLA_CLDJ - Calendar to MJD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CC62S - Cartesian 6-Vector to Spherical +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node33.html b/src/slalib/sun67.htx/node33.html new file mode 100644 index 0000000..556eb23 --- /dev/null +++ b/src/slalib/sun67.htx/node33.html @@ -0,0 +1,128 @@ + + + + +SLA_CLDJ - Calendar to MJD + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CLYD - Calendar to Year, Day +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CD2TF - Days to Hour,Min,Sec +

+

+

SLA_CLDJ - Calendar to MJD +   +

+
+
ACTION: +
Gregorian Calendar to Modified Julian Date. +
CALL: +
CALL sla_CLDJ (IY, IM, ID, DJM, J) +

+

+
GIVEN: +
+
+ + + + + +
IY,IM,IDIyear, month, day in Gregorian calendar
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
DJMDmodified Julian Date (JD-2400000.5) for $0^{\rm h}$
JIstatus:
0 = OK
1 = bad year
2 = bad month
3 = bad day
+

+
NOTES: +
+
1. +
When an invalid year or month is supplied (status J = 1 or 2) +the MJD is not computed. When an invalid day is supplied +(status J = 3) the MJD is computed. +
2. +
The year must be -4699 (i.e. 4700BC) or later. + For year nBC use IY = -(n-1). +
3. +
An alternative to the present routine is sla_CALDJ, which + accepts a year with the century missing. +
+

+
REFERENCE: +
The algorithm is derived from that of Hatcher, +Q.Jl.R.astr.Soc. (1984) 25, 53-55. +
+

+ +next + +up + +previous +
+ Next: SLA_CLYD - Calendar to Year, Day +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CD2TF - Days to Hour,Min,Sec +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node34.html b/src/slalib/sun67.htx/node34.html new file mode 100644 index 0000000..266f38a --- /dev/null +++ b/src/slalib/sun67.htx/node34.html @@ -0,0 +1,129 @@ + + + + +SLA_CLYD - Calendar to Year, Day + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_COMBN - Next Combination +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CLDJ - Calendar to MJD +

+

+

SLA_CLYD - Calendar to Year, Day +   +

+
+
ACTION: +
Gregorian calendar date to year and day in year, in a Julian +calendar aligned to the 20th/21st century Gregorian calendar. +

CALL: +
CALL sla_CLYD (IY, IM, ID, NY, ND, J) +

+

+
GIVEN: +
+
+ + + + + +
IY,IM,IDIyear, month, day in Gregorian calendar
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NYIyear (re-aligned Julian calendar)
NDIday in year (1 = January 1st)
JIstatus:
0 = OK
1 = bad year (before -4711)
2 = bad month
3 = bad day
+

+
NOTES: +
+
1. +
The purpose of sla_CLYD is to support sla_EARTH, +sla_MOON and sla_ECOR. +
2. +
Between 1900 March 1 and 2100 February 28 it returns answers + which are consistent with the ordinary Gregorian calendar. + Outside this range there will be a discrepancy which increases + by one day for every non-leap century year. +
3. +
When an invalid year or month is supplied (status J = 1 or J = 2) + the results are not computed. When a day is + supplied which is outside the conventional range (status J = 3) + the results are computed. +
+

+ +next + +up + +previous +
+ Next: SLA_COMBN - Next Combination +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CLDJ - Calendar to MJD +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node35.html b/src/slalib/sun67.htx/node35.html new file mode 100644 index 0000000..8723385 --- /dev/null +++ b/src/slalib/sun67.htx/node35.html @@ -0,0 +1,142 @@ + + + + +SLA_COMBN - Next Combination + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CR2AF - Radians to Deg,Arcmin,Arcsec +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CLYD - Calendar to Year, Day +

+

+

SLA_COMBN - Next Combination +   +

+
+
ACTION: +
Generate the next combination, a subset of a specified size chosen +from a specified number of items. +

CALL: +
CALL sla_COMBN (NSEL, NCAND, LIST, J) +

+

+
GIVEN: +
+
+ + + + + + + + + +
NSELInumber of items (subset size)
NCANDInumber of candidates (set size)
+

+
GIVEN and RETURNED: +
+
+ + + + + +
LISTI(NSEL)latest combination, LIST(1)=0 to initialize
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + +
JIstatus:
-1 = illegal NSEL or NCAND
0 = OK
+1 = no more combinations available
+

+
NOTES: +
+
1. +
NSEL and NCAND must both be at least 1, and NSEL must be less +than or equal to NCAND. +
2. +
This routine returns, in the LIST array, a subset of NSEL integers + chosen from the range 1 to NCAND inclusive, in ascending order. + Before calling the routine for the first time, the caller must set + the first element of the LIST array to zero (any value less than 1 + will do) to cause initialization. +
3. +
The first combination to be generated is: +
LIST(1)=1, LIST(2)=2, ..., LIST(NSEL)=NSEL +
+ This is also the combination returned for the ``finished'' (J=1) case. + The final permutation to be generated is: +
LIST(1)=NCAND, LIST(2)=NCAND-1, ...,
+                                LIST(NSEL)=NCAND-NSEL+1 +
+
4. +
If the ``finished'' (J=1) status is ignored, the routine + continues to deliver combinations, the pattern repeating + every NCAND!/(NSEL!(NCAND-NSEL)!) calls. +
5. +
The algorithm is by R.F.Warren-Smith (private communication). +
+

+ +next + +up + +previous +
+ Next: SLA_CR2AF - Radians to Deg,Arcmin,Arcsec +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CLYD - Calendar to Year, Day +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node36.html b/src/slalib/sun67.htx/node36.html new file mode 100644 index 0000000..0932642 --- /dev/null +++ b/src/slalib/sun67.htx/node36.html @@ -0,0 +1,122 @@ + + + + +SLA_CR2AF - Radians to Deg,Arcmin,Arcsec + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CR2TF - Radians to Hour,Min,Sec +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_COMBN - Next Combination +

+

+

SLA_CR2AF - Radians to Deg,Arcmin,Arcsec +   +

+
+
ACTION: +
Convert an angle in radians to degrees, arcminutes, +arcseconds (single precision). +

CALL: +
CALL sla_CR2AF (NDP, ANGLE, SIGN, IDMSF) +

+

+
GIVEN: +
+
+ + + + + + + + + +
NDPInumber of decimal places of arcseconds
ANGLERangle in radians
+

+
RETURNED: +
+
+ + + + + + + + + +
SIGNC`+' or `-'
IDMSFI(4)degrees, arcminutes, arcseconds, fraction
+

+
NOTES: +
+
1. +
NDP less than zero is interpreted as zero. +
2. +
The largest useful value for NDP is determined by the size of +ANGLE, the format of REAL floating-point numbers on the target + machine, and the risk of overflowing IDMSF(4). For example, + on a VAX computer, for ANGLE up to $2\pi$, the available floating-point + precision corresponds roughly to NDP=3. This is well below + the ultimate limit of NDP=9 set by the capacity of the 32-bit + integer IHMSF(4). +
3. +
The absolute value of ANGLE may exceed $2\pi$. In cases where it + does not, it is up to the caller to test for and handle the + case where ANGLE is very nearly $2\pi$ and rounds up to $360^{\circ}$, by testing for IDMSF(1)=360 and setting IDMSF(1-4) to zero. +
+

+ +next + +up + +previous +
+ Next: SLA_CR2TF - Radians to Hour,Min,Sec +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_COMBN - Next Combination +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node37.html b/src/slalib/sun67.htx/node37.html new file mode 100644 index 0000000..cd25af4 --- /dev/null +++ b/src/slalib/sun67.htx/node37.html @@ -0,0 +1,121 @@ + + + + +SLA_CR2TF - Radians to Hour,Min,Sec + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CS2C - Spherical to Cartesian +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CR2AF - Radians to Deg,Arcmin,Arcsec +

+

+

SLA_CR2TF - Radians to Hour,Min,Sec +   +

+
+
ACTION: +
Convert an angle in radians to hours, minutes, seconds +(single precision). +

CALL: +
CALL sla_CR2TF (NDP, ANGLE, SIGN, IHMSF) +

+

+
GIVEN: +
+
+ + + + + + + + + +
NDPInumber of decimal places of seconds
ANGLERangle in radians
+

+
RETURNED: +
+
+ + + + + + + + + +
SIGNC`+' or `-'
IHMSFI(4)hours, minutes, seconds, fraction
+

+
NOTES: +
+
1. +
NDP less than zero is interpreted as zero. +
2. +
The largest useful value for NDP is determined by the size of +ANGLE, the format of REAL floating-point numbers on the target + machine, and the risk of overflowing IHMSF(4). For example, + on a VAX computer, for ANGLE up to $2\pi$, the available floating-point + precision corresponds roughly to NDP=3. This is well below + the ultimate limit of NDP=9 set by the capacity of the 32-bit + integer IHMSF(4). +
3. +
The absolute value of ANGLE may exceed $2\pi$. In cases where it + does not, it is up to the caller to test for and handle the + case where ANGLE is very nearly $2\pi$ and rounds up to 24 hours, + by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +
+

+ +next + +up + +previous +
+ Next: SLA_CS2C - Spherical to Cartesian +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CR2AF - Radians to Deg,Arcmin,Arcsec +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node38.html b/src/slalib/sun67.htx/node38.html new file mode 100644 index 0000000..93d4f63 --- /dev/null +++ b/src/slalib/sun67.htx/node38.html @@ -0,0 +1,99 @@ + + + + +SLA_CS2C - Spherical to Cartesian + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CS2C6 - Spherical Pos/Vel to Cartesian +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CR2TF - Radians to Hour,Min,Sec +

+

+

SLA_CS2C - Spherical to Cartesian +   +

+
+
ACTION: +
Spherical coordinates to Cartesian coordinates (single precision). +
CALL: +
CALL sla_CS2C (A, B, V) +

+

+
GIVEN: +
+
+ + + + + +
A,BRspherical coordinates in radians: $[\,\alpha,\delta\,]$ etc.
+

+
RETURNED: +
+
+ + + + + +
VR(3)$[\,x,y,z\,]$ unit vector
+

+
NOTE: +
The spherical coordinates are longitude (+ve anticlockwise +looking from the +ve latitude pole) and latitude. The + Cartesian coordinates are right handed, with the x-axis + at zero longitude and latitude, and the z-axis at the + +ve latitude pole. +
+

+ +next + +up + +previous +
+ Next: SLA_CS2C6 - Spherical Pos/Vel to Cartesian +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CR2TF - Radians to Hour,Min,Sec +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node39.html b/src/slalib/sun67.htx/node39.html new file mode 100644 index 0000000..51bbf4f --- /dev/null +++ b/src/slalib/sun67.htx/node39.html @@ -0,0 +1,114 @@ + + + + +SLA_CS2C6 - Spherical Pos/Vel to Cartesian + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CTF2D - Hour,Min,Sec to Days +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CS2C - Spherical to Cartesian +

+

+

SLA_CS2C6 - Spherical Pos/Vel to Cartesian +   +

+
+
ACTION: +
Conversion of position & velocity in spherical coordinates +to Cartesian coordinates (single precision). +

CALL: +
CALL sla_CS2C6 (A, B, R, AD, BD, RD, V) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
ARlongitude (radians) - for example $\alpha$
BRlatitude (radians) - for example $\delta$
RRradial coordinate
ADRlongitude derivative (radians per unit time)
BDRlatitude derivative (radians per unit time)
RDRradial derivative
+

+
RETURNED: +
+
+ + + + + +
VR(6)$[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$
+

+ +next + +up + +previous +
+ Next: SLA_CTF2D - Hour,Min,Sec to Days +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CS2C - Spherical to Cartesian +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node4.html b/src/slalib/sun67.htx/node4.html new file mode 100644 index 0000000..81c9586 --- /dev/null +++ b/src/slalib/sun67.htx/node4.html @@ -0,0 +1,131 @@ + + + + +Example Application + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Scope +
+Up: INTRODUCTION +
+ Previous: Purpose +

+

+

+Example Application +

+Here is a simple example of an application program written +using SLALIB calls: +

+         PROGRAM FK4FK5
+   *
+   *  Read a B1950 position from I/O unit 5 and reply on I/O unit 6
+   *  with the J2000 equivalent.  Enter a period to quit.
+   *
+         IMPLICIT NONE
+         CHARACTER C*80,S
+         INTEGER I,J,IHMSF(4),IDMSF(4)
+         DOUBLE PRECISION R4,D4,R5,D5
+         LOGICAL BAD
+
+   *   Loop until a period is entered
+         C = ' '
+         DO WHILE (C(:1).NE.'.')
+
+   *     Read h m s d ' "
+            READ (5,'(A)') C
+            IF (C(:1).NE.'.') THEN
+               BAD = .TRUE.
+
+   *        Decode the RA
+               I = 1
+               CALL sla_DAFIN(C,I,R4,J)
+               IF (J.EQ.0) THEN
+                  R4 = 15D0*R4
+
+   *           Decode the Dec
+                  CALL sla_DAFIN(C,I,D4,J)
+                  IF (J.EQ.0) THEN
+
+   *              FK4 to FK5
+                     CALL sla_FK45Z(R4,D4,1950D0,R5,D5)
+
+   *              Format and output the result
+                     CALL sla_DR2TF(2,R5,S,IHMSF)
+                     CALL sla_DR2AF(1,D5,S,IDMSF)
+                     WRITE (6,
+        :       '(1X,I2.2,2I3.2,''.'',I2.2,2X,A,I2.2,2I3.2,''.'',I1)')
+        :                                                     IHMSF,S,IDMSF
+                     BAD = .FALSE.
+                  END IF
+               END IF
+               IF (BAD) WRITE (6,'(1X,''?'')')
+            END IF
+         END DO
+
+         END
+
+In this example, SLALIB not only provides the complicated FK4 to +FK5 transformation but also +simplifies the tedious and error-prone tasks +of decoding and formatting angles +expressed as hours, minutes etc. The +example incorporates range checking, and avoids the +notorious ``minus zero'' problem (an often-perpetrated bug where +declinations between $0^{\circ}$ and $-1^{\circ}$ lose their minus +sign). +With a little extra elaboration and a few more calls to SLALIB, +defaulting can be provided (enabling unused fields to +be replaced with commas to avoid retyping), proper motions +can be handled, different epochs can be specified, and +so on. See the program COCO (SUN/56) for further ideas. +

+


+ +next + +up + +previous +
+ Next: Scope +
+Up: INTRODUCTION +
+ Previous: Purpose +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node40.html b/src/slalib/sun67.htx/node40.html new file mode 100644 index 0000000..438541e --- /dev/null +++ b/src/slalib/sun67.htx/node40.html @@ -0,0 +1,125 @@ + + + + +SLA_CTF2D - Hour,Min,Sec to Days + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_CTF2R - Hour,Min,Sec to Radians +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CS2C6 - Spherical Pos/Vel to Cartesian +

+

+

SLA_CTF2D - Hour,Min,Sec to Days +   +

+
+
ACTION: +
Convert hours, minutes, seconds to days (single precision). +
CALL: +
CALL sla_CTF2D (IHOUR, IMIN, SEC, DAYS, J) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
IHOURIhours
IMINIminutes
SECRseconds
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
DAYSRinterval in days
JIstatus:
0 = OK
1 = IHOUR outside range 0-23
2 = IMIN outside range 0-59
3 = SEC outside range 0-59.999$\cdots$
+

+
NOTES: +
+
1. +
The result is computed even if any of the range checks fail. +
2. +
The sign must be dealt with outside this routine. +
+

+ +next + +up + +previous +
+ Next: SLA_CTF2R - Hour,Min,Sec to Radians +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CS2C6 - Spherical Pos/Vel to Cartesian +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node41.html b/src/slalib/sun67.htx/node41.html new file mode 100644 index 0000000..bf3cf62 --- /dev/null +++ b/src/slalib/sun67.htx/node41.html @@ -0,0 +1,125 @@ + + + + +SLA_CTF2R - Hour,Min,Sec to Radians + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DAF2R - Deg,Arcmin,Arcsec to Radians +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CTF2D - Hour,Min,Sec to Days +

+

+

SLA_CTF2R - Hour,Min,Sec to Radians +   +

+
+
ACTION: +
Convert hours, minutes, seconds to radians (single precision). +
CALL: +
CALL sla_CTF2R (IHOUR, IMIN, SEC, RAD, J) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
IHOURIhours
IMINIminutes
SECRseconds
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
RADRangle in radians
JIstatus:
0 = OK
1 = IHOUR outside range 0-23
2 = IMIN outside range 0-59
3 = SEC outside range 0-59.999$\cdots$
+

+
NOTES: +
+
1. +
The result is computed even if any of the range checks fail. +
2. +
The sign must be dealt with outside this routine. +
+

+ +next + +up + +previous +
+ Next: SLA_DAF2R - Deg,Arcmin,Arcsec to Radians +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CTF2D - Hour,Min,Sec to Days +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node42.html b/src/slalib/sun67.htx/node42.html new file mode 100644 index 0000000..faed2a4 --- /dev/null +++ b/src/slalib/sun67.htx/node42.html @@ -0,0 +1,122 @@ + + + + +SLA_DAF2R - Deg,Arcmin,Arcsec to Radians + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DAFIN - Sexagesimal character string to angle +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CTF2R - Hour,Min,Sec to Radians +

+

+

SLA_DAF2R - Deg,Arcmin,Arcsec to Radians +   +

+
+
ACTION: +
Convert degrees, arcminutes, arcseconds to radians +(double precision). +

CALL: +
CALL sla_DAF2R (IDEG, IAMIN, ASEC, RAD, J) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
IDEGIdegrees
IAMINIarcminutes
ASECDarcseconds
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + +
RADDangle in radians
JIstatus:
1 = IDEG outside range 0-359
2 = IAMIN outside range 0-59
3 = ASEC outside range 0-59.999$\cdots$
+

+
NOTES: +
+
1. +
The result is computed even if any of the range checks fail. +
2. +
The sign must be dealt with outside this routine. +
+

+ +next + +up + +previous +
+ Next: SLA_DAFIN - Sexagesimal character string to angle +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_CTF2R - Hour,Min,Sec to Radians +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node43.html b/src/slalib/sun67.htx/node43.html new file mode 100644 index 0000000..8559153 --- /dev/null +++ b/src/slalib/sun67.htx/node43.html @@ -0,0 +1,229 @@ + + + + +SLA_DAFIN - Sexagesimal character string to angle + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DAT - TAI-UTC +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DAF2R - Deg,Arcmin,Arcsec to Radians +

+

+

SLA_DAFIN - Sexagesimal character string to angle +   +

+
+
ACTION: +
Decode a free-format sexagesimal string (degrees, arcminutes, +arcseconds) into a double precision floating point + number (radians). +

CALL: +
CALL sla_DAFIN (STRING, NSTRT, DRESLT, JF) +

+

+
GIVEN: +
+
+ + + + + + + + + +
STRINGC*(*)string containing deg, arcmin, arcsec fields
NSTRTIpointer to start of decode (beginning of STRING = 1)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NSTRTIadvanced past the decoded angle
DRESLTDangle in radians
JFIstatus:
0 = OK
+1 = default, DRESLT unchanged (note 2)
-1 = bad degrees (note 3)
-2 = bad arcminutes (note 3)
-3 = bad arcseconds (note 3)
+

+
EXAMPLE +
:
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
argumentbeforeafter
   
STRING'-57 17 44.806 12 34 56.7'unchanged
NSTRT116 (i.e. pointing to 12...)
RESLT--1.00000D0
JF- 
+
A further call to sla_DAFIN, without adjustment of NSTRT, will + decode the second angle, $12^{\circ}\,34^{'}\,56^{''}.7$.
+

+
NOTES: +
+
1. +
The first three ``fields'' in STRING are degrees, arcminutes, +arcseconds, separated by spaces or commas. The degrees field +may be signed, but not the others. The decoding is carried + out by the sla_DFLTIN routine and is free-format. +
2. +
Successive fields may be absent, defaulting to zero. For + zero status, the only combinations allowed are degrees alone, + degrees and arcminutes, and all three fields present. If all + three fields are omitted, a status of +1 is returned and DRESLT is + unchanged. In all other cases DRESLT is changed. +
3. +
Range checking: +
    +
  • The degrees field is not range checked. However, it is + expected to be integral unless the other two fields are absent. +
  • The arcminutes field is expected to be 0-59, and integral if + the arcseconds field is present. If the arcseconds field + is absent, the arcminutes is expected to be 0-59.9999... +
  • The arcseconds field is expected to be 0-59.9999... +
  • Decoding continues even when a check has failed. Under these + circumstances the field takes the supplied value, defaulting to + zero, and the result DRESLT is computed and returned. +
+
4. +
Further fields after the three expected ones are not treated as + an error. The pointer NSTRT is left in the correct state for + further decoding with the present routine or with sla_DFLTIN + etc. See the example, above. +
5. +
If STRING contains hours, minutes, seconds instead of + degrees etc, + or if the required units are turns (or days) instead of radians, + the result DRESLT should be multiplied as follows:
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
for STRINGto obtainmultiply DRESLT by
   
${\circ}$  '  ''radians1.0D0
${\circ}$  '  ''turns$1/{2 \pi} = 0.1591549430918953358$D0
h m sradians15.0D0
h m sdays$15/{2\pi} = 2.3873241463784300365$D0
+

+ +next + +up + +previous +
+ Next: SLA_DAT - TAI-UTC +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DAF2R - Deg,Arcmin,Arcsec to Radians +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node44.html b/src/slalib/sun67.htx/node44.html new file mode 100644 index 0000000..791aba6 --- /dev/null +++ b/src/slalib/sun67.htx/node44.html @@ -0,0 +1,109 @@ + + + + +SLA_DAT - TAI-UTC + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DAV2M - Rotation Matrix from Axial Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DAFIN - Sexagesimal character string to angle +

+

+

SLA_DAT - TAI-UTC +   +

+
+
ACTION: +
Increment to be applied to Coordinated Universal Time UTC to give +International Atomic Time TAI. +

CALL: +
D = sla_DAT (UTC) +

+

+
GIVEN: +
+
+ + + + + +
UTCDUTC date as a modified JD (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
sla_DATDTAI-UTC in seconds
+

+
NOTES: +
+
1. +
The UTC is specified to be a date rather than a time to indicate +that care needs to be taken not to specify an instant which lies +within a leap second. Though in most cases UTC can include the + fractional part, correct behaviour on the day of a leap second + can be guaranteed only up to the end of the second + $23^{\rm h}\,59^{\rm m}\,59^{\rm s}$.
2. +
UTC began at 1960 January 1. To specify a UTC prior to this + date would be meaningless; in such cases the parameters + for the year 1960 are used by default. +
3. +
This routine has to be updated on each occasion that a + leap second is announced, and programs using it relinked. + Refer to the program source code for information on when the + most recent leap second was added. +
+

+ +next + +up + +previous +
+ Next: SLA_DAV2M - Rotation Matrix from Axial Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DAFIN - Sexagesimal character string to angle +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node45.html b/src/slalib/sun67.htx/node45.html new file mode 100644 index 0000000..4e11c46 --- /dev/null +++ b/src/slalib/sun67.htx/node45.html @@ -0,0 +1,103 @@ + + + + +SLA_DAV2M - Rotation Matrix from Axial Vector + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DBEAR - Direction Between Points on a Sphere +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DAT - TAI-UTC +

+

+

SLA_DAV2M - Rotation Matrix from Axial Vector +   +

+
+
ACTION: +
Form the rotation matrix corresponding to a given axial vector +(double precision). +

CALL: +
CALL sla_DAV2M (AXVEC, RMAT) +

+

+
GIVEN: +
+
+ + + + + +
AXVECD(3)axial vector (radians)
+

+
RETURNED: +
+
+ + + + + +
RMATD(3,3)rotation matrix
+

+
NOTES: +
+
1. +
A rotation matrix describes a rotation about some arbitrary axis. +The axis is called the Euler axis, and the angle through which the +reference frame rotates is called the Euler angle. The axial + vector supplied to this routine has the same direction as the + Euler axis, and its magnitude is the Euler angle in radians. +
2. +
If AXVEC is null, the unit matrix is returned. +
3. +
The reference frame rotates clockwise as seen looking along + the axial vector from the origin. +
+

+ +next + +up + +previous +
+ Next: SLA_DBEAR - Direction Between Points on a Sphere +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DAT - TAI-UTC +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node46.html b/src/slalib/sun67.htx/node46.html new file mode 100644 index 0000000..39a1ffd --- /dev/null +++ b/src/slalib/sun67.htx/node46.html @@ -0,0 +1,123 @@ + + + + +SLA_DBEAR - Direction Between Points on a Sphere + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DBJIN - Decode String to B/J Epoch (DP) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DAV2M - Rotation Matrix from Axial Vector +

+

+

SLA_DBEAR - Direction Between Points on a Sphere +   +

+
+
ACTION: +
Returns the bearing (position angle) of one point on a +sphere relative to another (double precision). +

CALL: +
D = sla_DBEAR (A1, B1, A2, B2) +

+

+
GIVEN: +
+
+ + + + + + + + + +
A1,B1Dspherical coordinates of one point
A2,B2Dspherical coordinates of the other point
+

+
RETURNED: +
+
+ + + + + +
sla_DBEARDbearing from first point to second
+

+
NOTES: +
+
1. +
The spherical coordinates are $[\,\alpha,\delta\,]$,$[\lambda,\phi]$ etc., in radians. +
2. +
The result is the bearing (position angle), in radians, + of point [A2,B2] as seen + from point [A1,B1]. It is in the range $\pm \pi$. The sense + is such that if [A2,B2] + is a small distance due east of [A1,B1] the result + is about $+\pi/2$. Zero is returned + if the two points are coincident. +
3. +
If either B-coordinate is outside the range $\pm\pi/2$, the + result may correspond to ``the long way round''. +
4. +
The routine sla_DPAV performs an equivalent function except + that the points are specified in the form of Cartesian unit + vectors. +
+

+ +next + +up + +previous +
+ Next: SLA_DBJIN - Decode String to B/J Epoch (DP) +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DAV2M - Rotation Matrix from Axial Vector +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node47.html b/src/slalib/sun67.htx/node47.html new file mode 100644 index 0000000..5d8e877 --- /dev/null +++ b/src/slalib/sun67.htx/node47.html @@ -0,0 +1,157 @@ + + + + +SLA_DBJIN - Decode String to B/J Epoch (DP) + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DC62S - Cartesian 6-Vector to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DBEAR - Direction Between Points on a Sphere +

+

+

SLA_DBJIN - Decode String to B/J Epoch (DP) +   +

+
+
ACTION: +
Decode a character string into a DOUBLE PRECISION number, +with special provision for Besselian and Julian epochs. + The string syntax is as for sla_DFLTIN, prefixed by + an optional `B' or `J'. +

CALL: +
CALL sla_DBJIN (STRING, NSTRT, DRESLT, J1, J2) +

+

+
GIVEN: +
+
+ + + + + + + + + +
STRINGCstring containing field to be decoded
NSTRTIpointer to first character of field in string
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NSTRTIincremented past the decoded field
DRESLTDresult
J1IDFLTIN status:
-1 = -OK
0 = +OK
1 = null field
2 = error
J2Isyntax flag:
0 = normal DFLTIN syntax
1 = `B' or `b'
2 = `J' or `j'
+

+
NOTES: +
+
1. +
The purpose of the syntax extensions is to help cope with mixed +FK4 and FK5 data, allowing fields such as `B1950' or `J2000' +to be decoded. +
2. +
In addition to the syntax accepted by sla_DFLTIN, + the following two extensions are recognized by sla_DBJIN: +
+
(a) +
A valid non-null field preceded by the character `B' +(or `b') is accepted. +
(b) +
A valid non-null field preceded by the character `J' + (or `j') is accepted. +
+
3. +
The calling program is told of the `B' or `J' through an + supplementary status argument. The rest of + the arguments are as for sla_DFLTIN. +
+

+ +next + +up + +previous +
+ Next: SLA_DC62S - Cartesian 6-Vector to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DBEAR - Direction Between Points on a Sphere +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node48.html b/src/slalib/sun67.htx/node48.html new file mode 100644 index 0000000..95057e4 --- /dev/null +++ b/src/slalib/sun67.htx/node48.html @@ -0,0 +1,110 @@ + + + + +SLA_DC62S - Cartesian 6-Vector to Spherical + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DCC2S - Cartesian to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DBJIN - Decode String to B/J Epoch (DP) +

+

+

SLA_DC62S - Cartesian 6-Vector to Spherical +   +

+
+
ACTION: +
Conversion of position & velocity in Cartesian coordinates +to spherical coordinates (double precision). +

CALL: +
CALL sla_DC62S (V, A, B, R, AD, BD, RD) +

+

+
GIVEN: +
+
+ + + + + +
VD(6)$[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
ADlongitude (radians)
BDlatitude (radians)
RDradial coordinate
ADDlongitude derivative (radians per unit time)
BDDlatitude derivative (radians per unit time)
RDDradial derivative
+

+ +next + +up + +previous +
+ Next: SLA_DCC2S - Cartesian to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DBJIN - Decode String to B/J Epoch (DP) +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node49.html b/src/slalib/sun67.htx/node49.html new file mode 100644 index 0000000..86f582e --- /dev/null +++ b/src/slalib/sun67.htx/node49.html @@ -0,0 +1,103 @@ + + + + +SLA_DCC2S - Cartesian to Spherical + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DCMPF - Interpret Linear Fit +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DC62S - Cartesian 6-Vector to Spherical +

+

+

SLA_DCC2S - Cartesian to Spherical +   +

+
+
ACTION: +
Cartesian coordinates to spherical coordinates (double precision). +
CALL: +
CALL sla_DCC2S (V, A, B) +

+

+
GIVEN: +
+
+ + + + + +
VD(3)$[\,x,y,z\,]$ vector
+

+
RETURNED: +
+
+ + + + + +
A,BDspherical coordinates in radians
+

+
NOTES: +
+
1. +
The spherical coordinates are longitude (+ve anticlockwise +looking from the +ve latitude pole) and latitude. The +Cartesian coordinates are right handed, with the x-axis + at zero longitude and latitude, and the z-axis at the + +ve latitude pole. +
2. +
If V is null, zero A and B are returned. +
3. +
At either pole, zero A is returned. +
+

+ +next + +up + +previous +
+ Next: SLA_DCMPF - Interpret Linear Fit +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DC62S - Cartesian 6-Vector to Spherical +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node5.html b/src/slalib/sun67.htx/node5.html new file mode 100644 index 0000000..3920866 --- /dev/null +++ b/src/slalib/sun67.htx/node5.html @@ -0,0 +1,83 @@ + + + + +Scope + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Objectives +
+Up: INTRODUCTION +
+ Previous: Example Application +

+

+

+Scope +

+SLALIB contains 183 routines covering the following topics: + +

+ +next + +up + +previous +
+ Next: Objectives +
+Up: INTRODUCTION +
+ Previous: Example Application +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node50.html b/src/slalib/sun67.htx/node50.html new file mode 100644 index 0000000..555de30 --- /dev/null +++ b/src/slalib/sun67.htx/node50.html @@ -0,0 +1,166 @@ + + + + +SLA_DCMPF - Interpret Linear Fit + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DCS2C - Spherical to Cartesian +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DCC2S - Cartesian to Spherical +

+

+

SLA_DCMPF - Interpret Linear Fit +   +

+
+
ACTION: +
Decompose an $[\,x,y\,]$ linear fit into its constituent parameters: +zero points, scales, nonperpendicularity and orientation. +

CALL: +
CALL sla_DCMPF (COEFFS,XZ,YZ,XS,YS,PERP,ORIENT) +

+

+
GIVEN: +
+
+ + + + + +
COEFFSD(6)transformation coefficients (see note)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
XZDx zero point
YZDy zero point
XSDx scale
YSDy scale
PERPDnonperpendicularity (radians)
ORIENTDorientation (radians)
+

+
NOTES: +
+
1. +
The model relates two sets of $[\,x,y\,]$ coordinates as follows. +Naming the six elements of COEFFS a,b,c,d,e & f, +the model transforms coordinates $[x_{1},y_{1}\,]$ into coordinates + $[x_{2},y_{2}\,]$ as follows: +
x2 = a + bx1 + cy1
+ y2 = d + ex1 + fy1
+ The sla_DCMPF routine decomposes this transformation + into four steps: +
+
(a) +
Zero points: +
$x' = x_{1} + {\rm XZ}$
+ $y' = y_{1} + {\rm YZ}$
+
(b) +
Scales: +
$x'' = x' {\rm XS}$
+ $y'' = y' {\rm YS}$
+
(c) +
Nonperpendicularity: +
$x''' = + x'' \cos {\rm PERP}/2 + y'' \sin {\rm PERP}/2$
+ $y''' = + x'' \sin {\rm PERP}/2 + y'' \cos {\rm PERP}/2$
+
(d) +
Orientation: +
$x_{2} = + x''' \cos {\rm ORIENT} +
+ y''' \sin {\rm ORIENT}$
+ $y_{2} = - x''' \sin {\rm ORIENT} +
+ y''' \cos {\rm ORIENT}$
+
2. +
See also sla_FITXY, sla_PXY, sla_INVF, sla_XY2XY. +
+

+ +next + +up + +previous +
+ Next: SLA_DCS2C - Spherical to Cartesian +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DCC2S - Cartesian to Spherical +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node51.html b/src/slalib/sun67.htx/node51.html new file mode 100644 index 0000000..1a8cb1b --- /dev/null +++ b/src/slalib/sun67.htx/node51.html @@ -0,0 +1,99 @@ + + + + +SLA_DCS2C - Spherical to Cartesian + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DD2TF - Days to Hour,Min,Sec +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DCMPF - Interpret Linear Fit +

+

+

SLA_DCS2C - Spherical to Cartesian +   +

+
+
ACTION: +
Spherical coordinates to Cartesian coordinates (double precision). +
CALL: +
CALL sla_DCS2C (A, B, V) +

+

+
GIVEN: +
+
+ + + + + +
A,BDspherical coordinates in radians: $[\,\alpha,\delta\,]$ etc.
+

+
RETURNED: +
+
+ + + + + +
VD(3)$[\,x,y,z\,]$ unit vector
+

+
NOTE: +
The spherical coordinates are longitude (+ve anticlockwise +looking from the +ve latitude pole) and latitude. The + Cartesian coordinates are right handed, with the x-axis + at zero longitude and latitude, and the z-axis at the + +ve latitude pole. +
+

+ +next + +up + +previous +
+ Next: SLA_DD2TF - Days to Hour,Min,Sec +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DCMPF - Interpret Linear Fit +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node52.html b/src/slalib/sun67.htx/node52.html new file mode 100644 index 0000000..52cca63 --- /dev/null +++ b/src/slalib/sun67.htx/node52.html @@ -0,0 +1,115 @@ + + + + +SLA_DD2TF - Days to Hour,Min,Sec + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DE2H - to Az,El +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DCS2C - Spherical to Cartesian +

+

+

SLA_DD2TF - Days to Hour,Min,Sec +   +

+
+
ACTION: +
Convert an interval in days into hours, minutes, seconds +(double precision). +

CALL: +
CALL sla_DD2TF (NDP, DAYS, SIGN, IHMSF) +

+

+
GIVEN: +
+
+ + + + + + + + + +
NDPInumber of decimal places of seconds
DAYSDinterval in days
+

+
RETURNED: +
+
+ + + + + + + + + +
SIGNC`+' or `-'
IHMSFI(4)hours, minutes, seconds, fraction
+

+
NOTES: +
+
1. +
NDP less than zero is interpreted as zero. +
2. +
The largest useful value for NDP is determined by the size +of DAYS, the format of DOUBLE PRECISION floating-point numbers + on the target machine, and the risk of overflowing IHMSF(4). + For example, on a VAX computer, for DAYS up to 1D0, the available + floating-point precision corresponds roughly to NDP=12. However, + the practical limit is NDP=9, set by the capacity of the 32-bit + integer IHMSF(4). +
3. +
The absolute value of DAYS may exceed 1D0. In cases where it + does not, it is up to the caller to test for and handle the + case where DAYS is very nearly 1D0 and rounds up to 24 hours, + by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +
+

+ +next + +up + +previous +
+ Next: SLA_DE2H - to Az,El +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DCS2C - Spherical to Cartesian +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node53.html b/src/slalib/sun67.htx/node53.html new file mode 100644 index 0000000..05a6c56 --- /dev/null +++ b/src/slalib/sun67.htx/node53.html @@ -0,0 +1,145 @@ + + + + +SLA_DE2H - to Az,El + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DEULER - Euler Angles to Rotation Matrix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DD2TF - Days to Hour,Min,Sec +

+

+

    +
+SLA_DE2H - $h,\delta$ to Az,El +

+
+
ACTION: +
Equatorial to horizon coordinates +(double precision). +

CALL: +
CALL sla_DE2H (HA, DEC, PHI, AZ, EL) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
HADhour angle (radians)
DECDdeclination (radians)
PHIDlatitude (radians)
+

+
RETURNED: +
+
+ + + + + + + + + +
AZDazimuth (radians)
ELDelevation (radians)
+

+
NOTES: +
+
1. +
Azimuth is returned in the range $0\!-\!2\pi$; north is zero, +and east is $+\pi/2$. Elevation is returned in the range +$\pm \pi$.
2. +
The latitude must be geodetic. In critical applications, + corrections for polar motion should be applied. +
3. +
In some applications it will be important to specify the + correct type of hour angle and declination in order to + produce the required type of azimuth and elevation. In + particular, it may be important to distinguish between + elevation as affected by refraction, which would + require the observed $[\,h,\delta\,]$, and the elevation + in vacuo, which would require the topocentric + $[\,h,\delta\,]$. If the effects of diurnal aberration can be neglected, the + apparent $[\,h,\delta\,]$ may be used instead of the topocentric + $[\,h,\delta\,]$.
4. +
No range checking of arguments is carried out. +
5. +
In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude, and (for tracking a star) + sine and cosine of declination. +
+

+ +next + +up + +previous +
+ Next: SLA_DEULER - Euler Angles to Rotation Matrix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DD2TF - Days to Hour,Min,Sec +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node54.html b/src/slalib/sun67.htx/node54.html new file mode 100644 index 0000000..1fc9a2a --- /dev/null +++ b/src/slalib/sun67.htx/node54.html @@ -0,0 +1,127 @@ + + + + +SLA_DEULER - Euler Angles to Rotation Matrix + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DFLTIN - Decode a Double Precision Number +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DE2H - to Az,El +

+

+

SLA_DEULER - Euler Angles to Rotation Matrix +   +

+
+
ACTION: +
Form a rotation matrix from the Euler angles - three +successive rotations about specified Cartesian axes + (double precision). +

CALL: +
CALL sla_DEULER (ORDER, PHI, THETA, PSI, RMAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
ORDERCspecifies about which axes the rotations occur
PHID1st rotation (radians)
THETAD2nd rotation (radians)
PSID3rd rotation (radians)
+

+
RETURNED: +
+
+ + + + + +
RMATD(3,3)rotation matrix
+

+
NOTES: +
+
1. +
A rotation is positive when the reference frame rotates +anticlockwise as seen looking towards the origin from the +positive region of the specified axis. +
2. +
The characters of ORDER define which axes the three successive + rotations are about. A typical value is `ZXZ', indicating that + RMAT is to become the direction cosine matrix corresponding to + rotations of the reference frame through PHI radians about the + old z-axis, followed by THETA radians about the resulting + x-axis, + then PSI radians about the resulting z-axis. +
3. +
The axis names can be any of the following, in any order or + combination: X, Y, Z, uppercase or lowercase, 1, 2, 3. Normal + axis labelling/numbering conventions apply; the xyz ($\equiv123$) triad is right-handed. Thus, the `ZXZ' example given above + could be written `zxz' or `313' (or even `ZxZ' or `3xZ'). ORDER + is terminated by length or by the first unrecognized character. + Fewer than three rotations are acceptable, in which case the later + angle arguments are ignored. Zero rotations produces a unit RMAT. +
+

+ +next + +up + +previous +
+ Next: SLA_DFLTIN - Decode a Double Precision Number +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DE2H - to Az,El +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node55.html b/src/slalib/sun67.htx/node55.html new file mode 100644 index 0000000..390f876 --- /dev/null +++ b/src/slalib/sun67.htx/node55.html @@ -0,0 +1,200 @@ + + + + +SLA_DFLTIN - Decode a Double Precision Number + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DH2E - Az,El to +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DEULER - Euler Angles to Rotation Matrix +

+

+

SLA_DFLTIN - Decode a Double Precision Number +   +

+
+
ACTION: +
Convert free-format input into double precision floating point. +
CALL: +
CALL sla_DFLTIN (STRING, NSTRT, DRESLT, JFLAG) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
STRINGCstring containing number to be decoded
NSTRTIpointer to where decoding is to commence
DRESLTDcurrent value of result
+

+
RETURNED: +
+
+ + + + + + + + + + + + + +
NSTRTIadvanced to next number
DRESLTDresult
JFLAGIstatus: -1 = -OK, 0 = +OK, 1 = null result, 2 = error
+

+
NOTES: +
+
1. +
The reason sla_DFLTIN has separate `OK' status values +for + and - is to enable minus zero to be detected. +This is of crucial importance + when decoding mixed-radix numbers. For example, an angle + expressed as degrees, arcminutes and arcseconds may have a + leading minus sign but a zero degrees field. +
2. +
A TAB is interpreted as a space, and lowercase characters are + interpreted as uppercase. n.b. The test for TAB is + ASCII-specific. +
3. +
The basic format is the sequence of fields $\pm n.n x \pm n$, where $\pm$ is a sign + character `+' or `-', n means a string of decimal digits, + `.' is a decimal point, and x, which indicates an exponent, + means `D' or `E'. Various combinations of these fields can be + omitted, and embedded blanks are permissible in certain places. +
4. +
Spaces: +
    +
  • Leading spaces are ignored. +
  • Embedded spaces are allowed only after +, -, D or E, + and after the decimal point if the first sequence of + digits is absent. +
  • Trailing spaces are ignored; the first signifies + end of decoding and subsequent ones are skipped. +
+
5. +
Delimiters: +
    +
  • Any character other than +,-,0-9,.,D,E or space may be + used to signal the end of the number and terminate decoding. +
  • Comma is recognized by sla_DFLTIN as a special case; it + is skipped, leaving the pointer on the next character. See + 13, below. +
  • Decoding will in all cases terminate if end of string + is reached. +
+
6. +
Both signs are optional. The default is +. +
7. +
The mantissa n.n defaults to unity. +
8. +
The exponent $x\!\pm\!n$ defaults to `D0'. +
9. +
The strings of decimal digits may be of any length. +
10. +
The decimal point is optional for whole numbers. +
11. +
A null result occurs when the string of characters + being decoded does not begin with +,-,0-9,.,D or E, or + consists entirely of spaces. When this condition is + detected, JFLAG is set to 1 and DRESLT is left untouched. +
12. +
NSTRT = 1 for the first character in the string. +
13. +
On return from sla_DFLTIN, NSTRT is set ready for the next + decode - following trailing blanks and any comma. If a + delimiter other than comma is being used, NSTRT must be + incremented before the next call to sla_DFLTIN, otherwise + all subsequent calls will return a null result. +
14. +
Errors (JFLAG=2) occur when: +
    +
  • a +, -, D or E is left unsatisfied; or +
  • the decimal point is present without at least + one decimal digit before or after it; or +
  • an exponent more than 100 has been presented. +
+
15. +
When an error has been detected, NSTRT is left + pointing to the character following the last + one used before the error came to light. This + may be after the point at which a more sophisticated + program could have detected the error. For example, + sla_DFLTIN does not detect that `1D999' is unacceptable + (on a computer where this is so) until the entire number + has been decoded. +
16. +
Certain highly unlikely combinations of mantissa and + exponent can cause arithmetic faults during the + decode, in some cases despite the fact that they + together could be construed as a valid number. +
17. +
Decoding is left to right, one pass. +
18. +
See also sla_FLOTIN and sla_INTIN. +
+

+ +next + +up + +previous +
+ Next: SLA_DH2E - Az,El to +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DEULER - Euler Angles to Rotation Matrix +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node56.html b/src/slalib/sun67.htx/node56.html new file mode 100644 index 0000000..e71b073 --- /dev/null +++ b/src/slalib/sun67.htx/node56.html @@ -0,0 +1,146 @@ + + + + +SLA_DH2E - Az,El to + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DIMXV - Apply 3D Reverse Rotation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DFLTIN - Decode a Double Precision Number +

+

+

    +
+SLA_DH2E - Az,El to $h,\delta$

+
+
ACTION: +
Horizon to equatorial coordinates +(double precision). +

CALL: +
CALL sla_DH2E (AZ, EL, PHI, HA, DEC) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
AZDazimuth (radians)
ELDelevation (radians)
PHIDlatitude (radians)
+

+
RETURNED: +
+
+ + + + + + + + + +
HADhour angle (radians)
DECDdeclination (radians)
+

+
NOTES: +
+
1. +
The sign convention for azimuth is north zero, east $+\pi/2$.
2. +
HA is returned in the range $\pm \pi$. Declination is returned +in the range $\pm \pi$.
3. +
The latitude is (in principle) geodetic. In critical + applications, corrections for polar motion should be applied + (see sla_POLMO). +
4. +
In some applications it will be important to specify the + correct type of elevation in order to produce the required + type of $[\,h,\delta\,]$. In particular, it may be important to + distinguish between the elevation as affected by refraction, + which will yield the observed $[\,h,\delta\,]$, and the elevation + in vacuo, which will yield the topocentric + $[\,h,\delta\,]$. If the + effects of diurnal aberration can be neglected, the + topocentric $[\,h,\delta\,]$ may be used as an approximation to the + apparent $[\,h,\delta\,]$.
5. +
No range checking of arguments is carried out. +
6. +
In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude. +
+

+ +next + +up + +previous +
+ Next: SLA_DIMXV - Apply 3D Reverse Rotation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DFLTIN - Decode a Double Precision Number +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node57.html b/src/slalib/sun67.htx/node57.html new file mode 100644 index 0000000..df5870d --- /dev/null +++ b/src/slalib/sun67.htx/node57.html @@ -0,0 +1,118 @@ + + + + +SLA_DIMXV - Apply 3D Reverse Rotation + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DJCAL - MJD to Gregorian for Output +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DH2E - Az,El to +

+

+

SLA_DIMXV - Apply 3D Reverse Rotation +   +

+
+
ACTION: +
Multiply a 3-vector by the inverse of a rotation +matrix (double precision). +

CALL: +
CALL sla_DIMXV (DM, VA, VB) +

+

+
GIVEN: +
+
+ + + + + + + + + +
DMD(3,3)rotation matrix
VAD(3)vector to be rotated
+

+
RETURNED: +
+
+ + + + + +
VBD(3)result vector
+

+
NOTES: +
+
1. +
This routine performs the operation: +
b = M$^{T}\cdot$a +
+ where a and b are the 3-vectors VA and VB + respectively, and M is the $3\times3$ matrix DM. +
2. +
The main function of this routine is apply an inverse + rotation; under these circumstances, ${\bf \rm M}$ is + orthogonal, with its inverse the same as its transpose. +
3. +
To comply with the ANSI Fortran 77 standard, VA and VB must + not be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is not, however, + recommended. +
+

+ +next + +up + +previous +
+ Next: SLA_DJCAL - MJD to Gregorian for Output +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DH2E - Az,El to +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node58.html b/src/slalib/sun67.htx/node58.html new file mode 100644 index 0000000..78f70fa --- /dev/null +++ b/src/slalib/sun67.htx/node58.html @@ -0,0 +1,112 @@ + + + + +SLA_DJCAL - MJD to Gregorian for Output + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DJCL - MJD to Year,Month,Day,Frac +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DIMXV - Apply 3D Reverse Rotation +

+

+

SLA_DJCAL - MJD to Gregorian for Output +   +

+
+
ACTION: +
Modified Julian Date to Gregorian Calendar Date, expressed +in a form convenient for formatting messages (namely + rounded to a specified precision, and with the fields + stored in a single array). +

CALL: +
CALL sla_DJCAL (NDP, DJM, IYMDF, J) +

+

+
GIVEN: +
+
+ + + + + + + + + +
NDPInumber of decimal places of days in fraction
DJMDmodified Julian Date (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + + + + + +
IYMDFI(4)year, month, day, fraction in Gregorian calendar
JIstatus: nonzero = out of range
+

+
NOTES: +
+
1. +
Any date after 4701BC March 1 is accepted. +
2. +
NDP should be 4 or less to avoid overflow on machines which +use 32-bit integers. +
+

+
REFERENCE: +
The algorithm is derived from that of Hatcher, +Q.Jl.R.astr.Soc. (1984) 25, 53-55. +
+

+ +next + +up + +previous +
+ Next: SLA_DJCL - MJD to Year,Month,Day,Frac +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DIMXV - Apply 3D Reverse Rotation +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node59.html b/src/slalib/sun67.htx/node59.html new file mode 100644 index 0000000..1d0b789 --- /dev/null +++ b/src/slalib/sun67.htx/node59.html @@ -0,0 +1,117 @@ + + + + +SLA_DJCL - MJD to Year,Month,Day,Frac + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DM2AV - Rotation Matrix to Axial Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DJCAL - MJD to Gregorian for Output +

+

+

SLA_DJCL - MJD to Year,Month,Day,Frac +   +

+
+
ACTION: +
Modified Julian Date to Gregorian year, month, day, +and fraction of a day. +

CALL: +
CALL sla_DJCL (DJM, IY, IM, ID, FD, J) +

+

+
GIVEN: +
+
+ + + + + +
DJMDmodified Julian Date (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
IYIyear
IMImonth
IDIday
FDDfraction of day
JIstatus:
0 = OK
-1 = unacceptable date (before 4701BC March 1)
+

+
REFERENCE: +
The algorithm is derived from that of Hatcher, +Q.Jl.R.astr.Soc. (1984) 25, 53-55. +
+

+ +next + +up + +previous +
+ Next: SLA_DM2AV - Rotation Matrix to Axial Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DJCAL - MJD to Gregorian for Output +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node6.html b/src/slalib/sun67.htx/node6.html new file mode 100644 index 0000000..c90fd51 --- /dev/null +++ b/src/slalib/sun67.htx/node6.html @@ -0,0 +1,116 @@ + + + + +Objectives + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Fortran Version +
+Up: INTRODUCTION +
+ Previous: Scope +

+

+

+Objectives +

+SLALIB was designed to give application programmers +a basic set of positional-astronomy tools which were +accurate and easy to use. To this end, the library is: + +A few caveats: + +

+ +next + +up + +previous +
+ Next: Fortran Version +
+Up: INTRODUCTION +
+ Previous: Scope +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node60.html b/src/slalib/sun67.htx/node60.html new file mode 100644 index 0000000..db12402 --- /dev/null +++ b/src/slalib/sun67.htx/node60.html @@ -0,0 +1,107 @@ + + + + +SLA_DM2AV - Rotation Matrix to Axial Vector + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DMAT - Solve Simultaneous Equations +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DJCL - MJD to Year,Month,Day,Frac +

+

+

SLA_DM2AV - Rotation Matrix to Axial Vector +   +

+
+
ACTION: +
From a rotation matrix, determine the corresponding axial vector +(double precision). +

CALL: +
CALL sla_DM2AV (RMAT, AXVEC) +

+

+
GIVEN: +
+
+ + + + + +
RMATD(3,3)rotation matrix
+

+
RETURNED: +
+
+ + + + + +
AXVECD(3)axial vector (radians)
+

+
NOTES: +
+
1. +
A rotation matrix describes a rotation about some arbitrary axis. +The axis is called the Euler axis, and the angle through +which the reference frame rotates is called the Euler angle. + The axial vector returned by this routine has the same + direction as the Euler axis, and its magnitude is the Euler angle + in radians. +
2. +
The magnitude and direction of the axial vector can be separated + by means of the routine sla_DVN. +
3. +
The reference frame rotates clockwise as seen looking along + the axial vector from the origin. +
4. +
If RMAT is null, so is the result. +
+

+ +next + +up + +previous +
+ Next: SLA_DMAT - Solve Simultaneous Equations +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DJCL - MJD to Year,Month,Day,Frac +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node61.html b/src/slalib/sun67.htx/node61.html new file mode 100644 index 0000000..b72e3ac --- /dev/null +++ b/src/slalib/sun67.htx/node61.html @@ -0,0 +1,152 @@ + + + + +SLA_DMAT - Solve Simultaneous Equations + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DMOON - Approx Moon Pos/Vel +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DM2AV - Rotation Matrix to Axial Vector +

+

+

SLA_DMAT - Solve Simultaneous Equations +   +

+
+
ACTION: +
Matrix inversion and solution of simultaneous equations +(double precision). +

CALL: +
CALL sla_DMAT (N, A, Y, D, JF, IW) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
NInumber of unknowns
AD(N,N)matrix
YD(N)vector
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + +
AD(N,N)matrix inverse
YD(N)solution
DDdeterminant
JFIsingularity flag: 0=OK
IWI(N)workspace
+

+
NOTES: +
+
1. +
For the set of n simultaneous linear equations in n unknowns: +
A$\cdot$y = x +
+ where: +
    +
  • A is a non-singular $n \times n$ matrix, +
  • y is the vector of n unknowns, and +
  • x is the known vector, +
+ sla_DMAT computes: +
    +
  • the inverse of matrix A, +
  • the determinant of matrix A, and +
  • the vector of n unknowns y. +
+ Argument N is the order n, A (given) is the matrix A, + Y (given) is the vector x and Y (returned) + is the vector y. + The argument A (returned) is the inverse matrix A-1, + and D is det(A). +
2. +
JF is the singularity flag. If the matrix is non-singular, + JF=0 is returned. If the matrix is singular, JF=-1 + and D=0D0 are returned. In the latter case, the contents + of array A on return are undefined. +
3. +
The algorithm is Gaussian elimination with partial pivoting. + This method is very fast; some much slower algorithms can give + better accuracy, but only by a small factor. +
4. +
This routine replaces the obsolete sla_DMATRX. +
+

+ +next + +up + +previous +
+ Next: SLA_DMOON - Approx Moon Pos/Vel +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DM2AV - Rotation Matrix to Axial Vector +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node62.html b/src/slalib/sun67.htx/node62.html new file mode 100644 index 0000000..dedceda --- /dev/null +++ b/src/slalib/sun67.htx/node62.html @@ -0,0 +1,154 @@ + + + + +SLA_DMOON - Approx Moon Pos/Vel + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DMXM - Multiply Matrices +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DMAT - Solve Simultaneous Equations +

+

+

SLA_DMOON - Approx Moon Pos/Vel +   +

+
+
ACTION: +
Approximate geocentric position and velocity of the Moon +(double precision). +

CALL: +
CALL sla_DMOON (DATE, PV) +

+

+
GIVEN: +
+
+ + + + + +
DATEDTDB (loosely ET) as a Modified Julian Date (JD-2400000.5) +
+

+
RETURNED: +
+
+ + + + + +
PVD(6)Moon $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$, mean equator and equinox +of date (AU, AU s-1)
+

+
NOTES: +
+
1. +
This routine is a full implementation of the algorithm +published by Meeus (see reference). +
2. +
Meeus quotes accuracies of $10\hspace{-0.05em}^{'\hspace{-0.1em}'}$ in longitude, + $3\hspace{-0.05em}^{'\hspace{-0.1em}'}$ in latitude and + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.2$ arcsec in HP + (equivalent to about 20 km in distance). Comparison with + JPL DE200 over the interval 1960-2025 gives RMS errors of +

$3\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.7$ and 83 mas/hour in longitude, +

$2\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.3$ arcsec and 48 mas/hour in latitude, + 11 km and 81 mm/s in distance. + The maximum errors over the same interval are + $18\hspace{-0.05em}^{'\hspace{-0.1em}'}$ and + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.50$ /hour in longitude, + $11\hspace{-0.05em}^{'\hspace{-0.1em}'}$ and + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.24$ /hour in latitude, + 40 km and 0.29 m/s in distance. +

3. +
The original algorithm is expressed in terms of the obsolete + timescale Ephemeris Time. Either TDB or TT can be used, + but not UT without incurring significant errors ($30\hspace{-0.05em}^{'\hspace{-0.1em}'}$ at + the present time) due to the Moon's + $0\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.5$ /s movement. +
4. +
The algorithm is based on pre IAU 1976 standards. However, + the result has been moved onto the new (FK5) equinox, an + adjustment which is in any case much smaller than the + intrinsic accuracy of the procedure. +
5. +
Velocity is obtained by a complete analytical differentiation + of the Meeus model. +
+

+
REFERENCE: +
Meeus, l'Astronomie, June 1984, p348. +
+

+ +next + +up + +previous +
+ Next: SLA_DMXM - Multiply Matrices +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DMAT - Solve Simultaneous Equations +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node63.html b/src/slalib/sun67.htx/node63.html new file mode 100644 index 0000000..9d19b4d --- /dev/null +++ b/src/slalib/sun67.htx/node63.html @@ -0,0 +1,106 @@ + + + + +SLA_DMXM - Multiply Matrices + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DMXV - Apply 3D Rotation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DMOON - Approx Moon Pos/Vel +

+

+

    +
+SLA_DMXM - Multiply $3\times3$ Matrices +

+
+
ACTION: +
Product of two $3\times3$ matrices (double precision). +
CALL: +
CALL sla_DMXM (A, B, C) +

+

+
GIVEN: +
+
+ + + + + + + + + +
AD(3,3)matrix A
BD(3,3)matrix B
+

+
RETURNED: +
+
+ + + + + +
CD(3,3)matrix result: A$\times$B
+

+
NOTE: +
To comply with the ANSI Fortran 77 standard, A, B and C must +be different arrays. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is not, however, + recommended. +
+

+ +next + +up + +previous +
+ Next: SLA_DMXV - Apply 3D Rotation +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DMOON - Approx Moon Pos/Vel +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node64.html b/src/slalib/sun67.htx/node64.html new file mode 100644 index 0000000..b6a0e15 --- /dev/null +++ b/src/slalib/sun67.htx/node64.html @@ -0,0 +1,115 @@ + + + + +SLA_DMXV - Apply 3D Rotation + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DPAV - Position-Angle Between Two Directions +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DMXM - Multiply Matrices +

+

+

SLA_DMXV - Apply 3D Rotation +   +

+
+
ACTION: +
Multiply a 3-vector by a rotation matrix (double precision). +
CALL: +
CALL sla_DMXV (DM, VA, VB) +

+

+
GIVEN: +
+
+ + + + + + + + + +
DMD(3,3)rotation matrix
VAD(3)vector to be rotated
+

+
RETURNED: +
+
+ + + + + +
VBD(3)result vector
+

+
NOTES: +
+
1. +
This routine performs the operation: +
b = M$\cdot$a +
+ where a and b are the 3-vectors VA and VB + respectively, and M is the $3\times3$ matrix DM. +
2. +
The main function of this routine is apply a + rotation; under these circumstances, M is a + proper real orthogonal matrix. +
3. +
To comply with the ANSI Fortran 77 standard, VA and VB must + not be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is not, however, + recommended. +
+

+ +next + +up + +previous +
+ Next: SLA_DPAV - Position-Angle Between Two Directions +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DMXM - Multiply Matrices +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node65.html b/src/slalib/sun67.htx/node65.html new file mode 100644 index 0000000..de89921 --- /dev/null +++ b/src/slalib/sun67.htx/node65.html @@ -0,0 +1,117 @@ + + + + +SLA_DPAV - Position-Angle Between Two Directions + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DR2AF - Radians to Deg,Min,Sec,Frac +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DMXV - Apply 3D Rotation +

+

+

SLA_DPAV - Position-Angle Between Two Directions +   +

+
+
ACTION: +
Returns the bearing (position angle) of one celestial +direction with respect to another (double precision). +

CALL: +
D = sla_DPAV (V1, V2) +

+

+
GIVEN: +
+
+ + + + + + + + + +
V1D(3)direction cosines of one point
V2D(3)directions cosines of the other point
+

+
RETURNED: +
+
+ + + + + +
sla_DPAVDposition-angle of 2nd point with respect to 1st
+

+
NOTES: +
+
1. +
The coordinate frames correspond to $[\,\alpha,\delta\,]$,$[\lambda,\phi]$ etc.. +
2. +
The result is the bearing (position angle), in radians, + of point V2 as seen + from point V1. It is in the range $\pm \pi$. The sense + is such that if V2 + is a small distance due east of V1 the result + is about $+\pi/2$. Zero is returned + if the two points are coincident. +
3. +
The routine sla_DBEAR performs an equivalent function except + that the points are specified in the form of spherical coordinates. +
+

+ +next + +up + +previous +
+ Next: SLA_DR2AF - Radians to Deg,Min,Sec,Frac +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DMXV - Apply 3D Rotation +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node66.html b/src/slalib/sun67.htx/node66.html new file mode 100644 index 0000000..c4b2639 --- /dev/null +++ b/src/slalib/sun67.htx/node66.html @@ -0,0 +1,122 @@ + + + + +SLA_DR2AF - Radians to Deg,Min,Sec,Frac + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DR2TF - Radians to Hour,Min,Sec,Frac +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DPAV - Position-Angle Between Two Directions +

+

+

SLA_DR2AF - Radians to Deg,Min,Sec,Frac +   +

+
+
ACTION: +
Convert an angle in radians to degrees, arcminutes, arcseconds, +fraction (double precision). +

CALL: +
CALL sla_DR2AF (NDP, ANGLE, SIGN, IDMSF) +

+

+
GIVEN: +
+
+ + + + + + + + + +
NDPInumber of decimal places of arcseconds
ANGLEDangle in radians
+

+
RETURNED: +
+
+ + + + + + + + + +
SIGNC`+' or `-'
IDMSFI(4)degrees, arcminutes, arcseconds, fraction
+

+
NOTES: +
+
1. +
NDP less than zero is interpreted as zero. +
2. +
The largest useful value for NDP is determined by the size +of ANGLE, the format of DOUBLE PRECISION floating-point numbers + on the target machine, and the risk of overflowing IDMSF(4). + For example, on a VAX computer, for ANGLE up to $2\pi$, the available + floating-point precision corresponds roughly to NDP=12. However, + the practical limit is NDP=9, set by the capacity of the 32-bit + integer IDMSF(4). +
3. +
The absolute value of ANGLE may exceed $2\pi$. In cases where it + does not, it is up to the caller to test for and handle the + case where ANGLE is very nearly $2\pi$ and rounds up to $360^{\circ}$, by testing for IDMSF(1)=360 and setting IDMSF(1-4) to zero. +
+

+ +next + +up + +previous +
+ Next: SLA_DR2TF - Radians to Hour,Min,Sec,Frac +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DPAV - Position-Angle Between Two Directions +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node67.html b/src/slalib/sun67.htx/node67.html new file mode 100644 index 0000000..f5e0648 --- /dev/null +++ b/src/slalib/sun67.htx/node67.html @@ -0,0 +1,121 @@ + + + + +SLA_DR2TF - Radians to Hour,Min,Sec,Frac + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DRANGE - Put Angle into Range +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DR2AF - Radians to Deg,Min,Sec,Frac +

+

+

SLA_DR2TF - Radians to Hour,Min,Sec,Frac +   +

+
+
ACTION: +
Convert an angle in radians to hours, minutes, seconds, +fraction (double precision). +

CALL: +
CALL sla_DR2TF (NDP, ANGLE, SIGN, IHMSF) +

+

+
GIVEN: +
+
+ + + + + + + + + +
NDPInumber of decimal places of seconds
ANGLEDangle in radians
+

+
RETURNED: +
+
+ + + + + + + + + +
SIGNC`+' or `-'
IHMSFI(4)hours, minutes, seconds, fraction
+

+
NOTES: +
+
1. +
NDP less than zero is interpreted as zero. +
2. +
The largest useful value for NDP is determined by the size +of ANGLE, the format of DOUBLE PRECISION floating-point numbers + on the target machine, and the risk of overflowing IHMSF(4). + For example, on a VAX computer, for ANGLE up to $2\pi$, the available + floating-point precision corresponds roughly to NDP=12. However, + the practical limit is NDP=9, set by the capacity of the 32-bit + integer IHMSF(4). +
3. +
The absolute value of ANGLE may exceed $2\pi$. In cases where it + does not, it is up to the caller to test for and handle the + case where ANGLE is very nearly $2\pi$ and rounds up to 24 hours, + by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +
+

+ +next + +up + +previous +
+ Next: SLA_DRANGE - Put Angle into Range +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DR2AF - Radians to Deg,Min,Sec,Frac +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node68.html b/src/slalib/sun67.htx/node68.html new file mode 100644 index 0000000..477164f --- /dev/null +++ b/src/slalib/sun67.htx/node68.html @@ -0,0 +1,93 @@ + + + + +SLA_DRANGE - Put Angle into Range + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DRANRM - Put Angle into Range +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DR2TF - Radians to Hour,Min,Sec,Frac +

+

+

    +
+SLA_DRANGE - Put Angle into Range $\pm \pi$

+
+
ACTION: +
Normalize an angle into the range $\pm \pi$ (double precision). +
CALL: +
D = sla_DRANGE (ANGLE) +

+

+
GIVEN: +
+
+ + + + + +
ANGLEDangle in radians
+

+
RETURNED: +
+
+ + + + + +
sla_DRANGEDANGLE expressed in the range $\pm \pi$.
+

+ +next + +up + +previous +
+ Next: SLA_DRANRM - Put Angle into Range +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DR2TF - Radians to Hour,Min,Sec,Frac +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node69.html b/src/slalib/sun67.htx/node69.html new file mode 100644 index 0000000..02f5415 --- /dev/null +++ b/src/slalib/sun67.htx/node69.html @@ -0,0 +1,93 @@ + + + + +SLA_DRANRM - Put Angle into Range + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DS2C6 - Spherical Pos/Vel to Cartesian +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DRANGE - Put Angle into Range +

+

+

    +
+SLA_DRANRM - Put Angle into Range $0\!-\!2\pi$

+
+
ACTION: +
Normalize an angle into the range $0\!-\!2\pi$(double precision). +

CALL: +
D = sla_DRANRM (ANGLE) +

+

+
GIVEN: +
+
+ + + + + +
ANGLEDangle in radians
+

+
RETURNED: +
+
+ + + + + +
sla_DRANRMDANGLE expressed in the range $0\!-\!2\pi$
+

+ +next + +up + +previous +
+ Next: SLA_DS2C6 - Spherical Pos/Vel to Cartesian +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DRANGE - Put Angle into Range +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node7.html b/src/slalib/sun67.htx/node7.html new file mode 100644 index 0000000..e75fbed --- /dev/null +++ b/src/slalib/sun67.htx/node7.html @@ -0,0 +1,76 @@ + + + + +Fortran Version + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: C Version +
+Up: INTRODUCTION +
+ Previous: Objectives +

+

+

+Fortran Version +

+The Fortran versions of SLALIB use ANSI Fortran 77 with a few +commonplace extensions. Just three out of the 183 routines require +platform-specific techniques and accordingly are supplied +in different forms. +SLALIB has been implemented on the following platforms: +VAX/VMS, +PC (Microsoft Fortran, Linux), +DECstation (Ultrix), +DEC Alpha (DEC Unix), +Sun (SunOS, Solaris), +Hewlett Packard (HP-UX), +CONVEX, +Perkin-Elmer and +Fujitsu. +

+


+ +next + +up + +previous +
+ Next: C Version +
+Up: INTRODUCTION +
+ Previous: Objectives +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node70.html b/src/slalib/sun67.htx/node70.html new file mode 100644 index 0000000..b1ebf8a --- /dev/null +++ b/src/slalib/sun67.htx/node70.html @@ -0,0 +1,114 @@ + + + + +SLA_DS2C6 - Spherical Pos/Vel to Cartesian + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DS2TP - Spherical to Tangent Plane +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DRANRM - Put Angle into Range +

+

+

SLA_DS2C6 - Spherical Pos/Vel to Cartesian +   +

+
+
ACTION: +
Conversion of position & velocity in spherical coordinates +to Cartesian coordinates (double precision). +

CALL: +
CALL sla_DS2C6 (A, B, R, AD, BD, RD, V) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
ADlongitude (radians) - for example $\alpha$
BDlatitude (radians) - for example $\delta$
RDradial coordinate
ADDlongitude derivative (radians per unit time)
BDDlatitude derivative (radians per unit time)
RDDradial derivative
+

+
RETURNED: +
+
+ + + + + +
VD(6)$[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$
+

+ +next + +up + +previous +
+ Next: SLA_DS2TP - Spherical to Tangent Plane +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DRANRM - Put Angle into Range +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node71.html b/src/slalib/sun67.htx/node71.html new file mode 100644 index 0000000..8703383 --- /dev/null +++ b/src/slalib/sun67.htx/node71.html @@ -0,0 +1,129 @@ + + + + +SLA_DS2TP - Spherical to Tangent Plane + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DSEP - Angle Between 2 Points on Sphere +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DS2C6 - Spherical Pos/Vel to Cartesian +

+

+

SLA_DS2TP - Spherical to Tangent Plane +   +

+
+
ACTION: +
Projection of spherical coordinates onto the tangent plane +(double precision). +

CALL: +
CALL sla_DS2TP (RA, DEC, RAZ, DECZ, XI, ETA, J) +

+

+
GIVEN: +
+
+ + + + + + + + + +
RA,DECDspherical coordinates of star (radians)
RAZ,DECZDspherical coordinates of tangent point (radians)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
XI,ETADtangent plane coordinates (radians)
JIstatus:
0 = OK, star on tangent plane
1 = error, star too far from axis
2 = error, antistar on tangent plane
3 = error, antistar too far from axis
+

+
NOTES: +
+
1. +
The projection is called the gnomonic projection; the +Cartesian coordinates $[\,\xi,\eta\,]$ are called +standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
2. +
When working in $[\,x,y,z\,]$ rather than spherical coordinates, the + equivalent Cartesian routine sla_DV2TP is available. +
+

+ +next + +up + +previous +
+ Next: SLA_DSEP - Angle Between 2 Points on Sphere +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DS2C6 - Spherical Pos/Vel to Cartesian +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node72.html b/src/slalib/sun67.htx/node72.html new file mode 100644 index 0000000..b127b82 --- /dev/null +++ b/src/slalib/sun67.htx/node72.html @@ -0,0 +1,100 @@ + + + + +SLA_DSEP - Angle Between 2 Points on Sphere + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DT - Approximate ET minus UT +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DS2TP - Spherical to Tangent Plane +

+

+

SLA_DSEP - Angle Between 2 Points on Sphere +   +

+
+
ACTION: +
Angle between two points on a sphere (double precision). +
CALL: +
D = sla_DSEP (A1, B1, A2, B2) +

+

+
GIVEN: +
+
+ + + + + + + + + +
A1,B1Dspherical coordinates of one point (radians)
A2,B2Dspherical coordinates of the other point (radians)
+

+
RETURNED: +
+
+ + + + + +
sla_DSEPDangle between [A1,B1] and [A2,B2] in radians
+

+
NOTES: +
+
1. +
The spherical coordinates are right ascension and declination, +longitude and latitude, etc., in radians. +
2. +
The result is always positive. +
+

+ +next + +up + +previous +
+ Next: SLA_DT - Approximate ET minus UT +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DS2TP - Spherical to Tangent Plane +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node73.html b/src/slalib/sun67.htx/node73.html new file mode 100644 index 0000000..fca730c --- /dev/null +++ b/src/slalib/sun67.htx/node73.html @@ -0,0 +1,131 @@ + + + + +SLA_DT - Approximate ET minus UT + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DTF2D - Hour,Min,Sec to Days +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DSEP - Angle Between 2 Points on Sphere +

+

+

SLA_DT - Approximate ET minus UT +   +

+
+
ACTION: +
Estimate $\Delta$T, the offset between dynamical time +and Universal Time, for a given historical epoch. +

CALL: +
D = sla_DT (EPOCH) +

+

+
GIVEN: +
+
+ + + + + +
EPOCHD(Julian) epoch (e.g. 1850D0)
+

+
RETURNED: +
+
+ + + + + +
sla_DTDapproximate ET-UT (after 1984, TT-UT1) in seconds
+

+
NOTES: +
+
1. +
Depending on the epoch, one of three parabolic approximations +is used: +

+before AD 979 		 Stephenson & Morrison's 390 BC to AD 948 model
+		 AD 979 to AD 1708 		 Stephenson & Morrison's AD 948 to AD 1600 model
+		 after AD 1708 		 McCarthy & Babcock's post-1650 model
+
+ The breakpoints are chosen to ensure continuity: they occur + at places where the adjacent models give the same answer as + each other. +
2. +
The accuracy is modest, with errors of up to $20^{\rm s}$ during + the interval since 1650, rising to perhaps $30^{\rm m}$ by 1000 BC. Comparatively accurate values from AD 1600 + are tabulated in + the Astronomical Almanac (see section K8 of the 1995 + edition). +
3. +
The use of DOUBLE PRECISION for both argument and result is + simply for compatibility with other SLALIB time routines. +
4. +
The models used are based on a lunar tidal acceleration value + of + $-26\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.00$ per century. +
+

+
REFERENCE: +
Seidelmann, P.K. (ed), 1992. Explanatory +Supplement to the Astronomical Almanac, ISBN 0-935702-68-7. + This contains references to the papers by Stephenson & Morrison + and by McCarthy & Babcock which describe the models used here. +
+

+ +next + +up + +previous +
+ Next: SLA_DTF2D - Hour,Min,Sec to Days +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DSEP - Angle Between 2 Points on Sphere +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node74.html b/src/slalib/sun67.htx/node74.html new file mode 100644 index 0000000..88700cd --- /dev/null +++ b/src/slalib/sun67.htx/node74.html @@ -0,0 +1,125 @@ + + + + +SLA_DTF2D - Hour,Min,Sec to Days + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DTF2R - Hour,Min,Sec to Radians +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DT - Approximate ET minus UT +

+

+

SLA_DTF2D - Hour,Min,Sec to Days +   +

+
+
ACTION: +
Convert hours, minutes, seconds to days (double precision). +
CALL: +
CALL sla_DTF2D (IHOUR, IMIN, SEC, DAYS, J) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
IHOURIhours
IMINIminutes
SECDseconds
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
DAYSDinterval in days
JIstatus:
0 = OK
1 = IHOUR outside range 0-23
2 = IMIN outside range 0-59
3 = SEC outside range 0-59.999$\cdots$
+

+
NOTES: +
+
1. +
The result is computed even if any of the range checks fail. +
2. +
The sign must be dealt with outside this routine. +
+

+ +next + +up + +previous +
+ Next: SLA_DTF2R - Hour,Min,Sec to Radians +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DT - Approximate ET minus UT +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node75.html b/src/slalib/sun67.htx/node75.html new file mode 100644 index 0000000..535d444 --- /dev/null +++ b/src/slalib/sun67.htx/node75.html @@ -0,0 +1,125 @@ + + + + +SLA_DTF2R - Hour,Min,Sec to Radians + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DTP2S - Tangent Plane to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTF2D - Hour,Min,Sec to Days +

+

+

SLA_DTF2R - Hour,Min,Sec to Radians +   +

+
+
ACTION: +
Convert hours, minutes, seconds to radians (double precision). +
CALL: +
CALL sla_DTF2R (IHOUR, IMIN, SEC, RAD, J) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
IHOURIhours
IMINIminutes
SECDseconds
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
RADDangle in radians
JIstatus:
0 = OK
1 = IHOUR outside range 0-23
2 = IMIN outside range 0-59
3 = SEC outside range 0-59.999$\cdots$
+

+
NOTES: +
+
1. +
The result is computed even if any of the range checks fail. +
2. +
The sign must be dealt with outside this routine. +
+

+ +next + +up + +previous +
+ Next: SLA_DTP2S - Tangent Plane to Spherical +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTF2D - Hour,Min,Sec to Days +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node76.html b/src/slalib/sun67.htx/node76.html new file mode 100644 index 0000000..46c4f7a --- /dev/null +++ b/src/slalib/sun67.htx/node76.html @@ -0,0 +1,109 @@ + + + + +SLA_DTP2S - Tangent Plane to Spherical + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DTP2V - Tangent Plane to Direction Cosines +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTF2R - Hour,Min,Sec to Radians +

+

+

SLA_DTP2S - Tangent Plane to Spherical +   +

+
+
ACTION: +
Transform tangent plane coordinates into spherical +coordinates (double precision) +

CALL: +
CALL sla_DTP2S (XI, ETA, RAZ, DECZ, RA, DEC) +

+

+
GIVEN: +
+
+ + + + + + + + + +
XI,ETADtangent plane rectangular coordinates (radians)
RAZ,DECZDspherical coordinates of tangent point (radians)
+

+
RETURNED: +
+
+ + + + + +
RA,DECDspherical coordinates (radians)
+

+
NOTES: +
+
1. +
The projection is called the gnomonic projection; the +Cartesian coordinates $[\,\xi,\eta\,]$ are called +standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
2. +
When working in $[\,x,y,z\,]$ rather than spherical coordinates, the + equivalent Cartesian routine sla_DTP2V is available. +
+

+ +next + +up + +previous +
+ Next: SLA_DTP2V - Tangent Plane to Direction Cosines +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTF2R - Hour,Min,Sec to Radians +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node77.html b/src/slalib/sun67.htx/node77.html new file mode 100644 index 0000000..522e009 --- /dev/null +++ b/src/slalib/sun67.htx/node77.html @@ -0,0 +1,117 @@ + + + + +SLA_DTP2V - Tangent Plane to Direction Cosines + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DTPS2C - Plate centre from and +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTP2S - Tangent Plane to Spherical +

+

+

SLA_DTP2V - Tangent Plane to Direction Cosines +   +

+
+
ACTION: +
Given the tangent-plane coordinates of a star and the direction +cosines of the tangent point, determine the direction cosines + of the star + (double precision). +

CALL: +
CALL sla_DTP2V (XI, ETA, V0, V) +

+

+
GIVEN: +
+
+ + + + + + + + + +
XI,ETADtangent plane coordinates of star (radians)
V0D(3)direction cosines of tangent point
+

+
RETURNED: +
+
+ + + + + +
VD(3)direction cosines of star
+

+
NOTES: +
+
1. +
If vector V0 is not of unit length, the returned vector V will +be wrong. +
2. +
If vector V0 points at a pole, the returned vector V will be + based on the arbitrary assumption that $\alpha=0$ at + the tangent point. +
3. +
The projection is called the gnomonic projection; the + Cartesian coordinates $[\,\xi,\eta\,]$ are called + standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
4. +
This routine is the Cartesian equivalent of the routine sla_DTP2S. +
+

+ +next + +up + +previous +
+ Next: SLA_DTPS2C - Plate centre from and +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTP2S - Tangent Plane to Spherical +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node78.html b/src/slalib/sun67.htx/node78.html new file mode 100644 index 0000000..61458ac --- /dev/null +++ b/src/slalib/sun67.htx/node78.html @@ -0,0 +1,168 @@ + + + + +SLA_DTPS2C - Plate centre from and + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DTPV2C - Plate centre from and x,y,z +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTP2V - Tangent Plane to Direction Cosines +

+

+

    +
+SLA_DTPS2C - Plate centre from $\xi,\eta$ and $\alpha,\delta$

+
+
ACTION: +
From the tangent plane coordinates of a star of known $[\,\alpha,\delta\,]$,determine the $[\,\alpha,\delta\,]$ of the tangent point (double precision) +

CALL: +
CALL sla_DTPS2C (XI, ETA, RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2, N) +

+

+
GIVEN: +
+
+ + + + + + + + + +
XI,ETADtangent plane rectangular coordinates (radians)
RA,DECDspherical coordinates (radians)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
RAZ1,DECZ1Dspherical coordinates of tangent point, +solution 1
RAZ2,DECZ2Dspherical coordinates of tangent point, +solution 2
NInumber of solutions:
0 = no solutions returned (note 2)
1 = only the first solution is useful (note 3)
2 = there are two useful solutions (note 3)
+

+
NOTES: +
+
1. +
The RAZ1 and RAZ2 values returned are in the range $0\!-\!2\pi$.
2. +
Cases where there is no solution can only arise near the poles. +For example, it is clearly impossible for a star at the pole + itself to have a non-zero $\xi$ value, and hence it is + meaningless to ask where the tangent point would have to be + to bring about this combination of $\xi$ and $\delta$.
3. +
Also near the poles, cases can arise where there are two useful + solutions. The argument N indicates whether the second of the + two solutions returned is useful. N=1 + indicates only one useful solution, the usual case; under + these circumstances, the second solution corresponds to the + ``over-the-pole'' case, and this is reflected in the values + of RAZ2 and DECZ2 which are returned. +
4. +
The DECZ1 and DECZ2 values returned are in the range $\pm \pi$, but in the ordinary, non-pole-crossing, case, the range is + $\pm\pi/2$.
5. +
RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2 are all in radians. +
6. +
The projection is called the gnomonic projection; the + Cartesian coordinates $[\,\xi,\eta\,]$ are called + standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
7. +
When working in $[\,x,y,z\,]$ rather than spherical coordinates, the + equivalent Cartesian routine sla_DTPV2C is available. +
+

+ +next + +up + +previous +
+ Next: SLA_DTPV2C - Plate centre from and x,y,z +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTP2V - Tangent Plane to Direction Cosines +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node79.html b/src/slalib/sun67.htx/node79.html new file mode 100644 index 0000000..de0194d --- /dev/null +++ b/src/slalib/sun67.htx/node79.html @@ -0,0 +1,144 @@ + + + + +SLA_DTPV2C - Plate centre from and x,y,z + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DTT - TT minus UTC +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTPS2C - Plate centre from and +

+

+

    +
+SLA_DTPV2C - Plate centre from $\xi,\eta$ and x,y,z +

+
+
ACTION: +
From the tangent plane coordinates of a star of known +direction cosines, determine the direction cosines + of the tangent point (double precision) +

CALL: +
CALL sla_DTPV2C (XI, ETA, V, V01, V02, N) +

+

+
GIVEN: +
+
+ + + + + + + + + +
XI,ETADtangent plane coordinates of star (radians)
VD(3)direction cosines of star
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
V01D(3)direction cosines of tangent point, solution 1
V01D(3)direction cosines of tangent point, solution 2
NInumber of solutions:
0 = no solutions returned (note 2)
1 = only the first solution is useful (note 3)
2 = there are two useful solutions (note 3)
+

+
NOTES: +
+
1. +
The vector V must be of unit length or the result will be wrong. +
2. +
Cases where there is no solution can only arise near the poles. +For example, it is clearly impossible for a star at the pole + itself to have a non-zero XI value. +
3. +
Also near the poles, cases can arise where there are two useful + solutions. The argument N indicates whether the second of the + two solutions returned is useful. + N=1 + indicates only one useful solution, the usual case; under these + circumstances, the second solution can be regarded as valid if + the vector V02 is interpreted as the ``over-the-pole'' case. +
4. +
The projection is called the gnomonic projection; the + Cartesian coordinates $[\,\xi,\eta\,]$ are called + standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
5. +
This routine is the Cartesian equivalent of the routine sla_DTPS2C. +
+

+ +next + +up + +previous +
+ Next: SLA_DTT - TT minus UTC +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTPS2C - Plate centre from and +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node8.html b/src/slalib/sun67.htx/node8.html new file mode 100644 index 0000000..81261d2 --- /dev/null +++ b/src/slalib/sun67.htx/node8.html @@ -0,0 +1,85 @@ + + + + +C Version + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: Future Versions +
+Up: INTRODUCTION +
+ Previous: Fortran Version +

+

+

+C Version +

+An ANSI C version of SLALIB is available from the author +but is not part of the Starlink release. +The functionality of this (proprietary) C version closely matches +that of the Starlink Fortran SLALIB, partly for the convenience of +existing users of the Fortran version, some of whom have in the past +implemented C ``wrappers''. The function names +cannot be the same as the Fortran versions because of potential +linking problems when +both forms of the library are present; the C routine which +is the equivalent of (for example) SLA_REFRO is slaRefro. +The types of arguments follow the Fortran version, except +that integers are int rather than long. +Argument passing is by value +(except for arrays and strings of course) +for given arguments and by pointer for returned arguments. +All the C functions are re-entrant. +

+The Fortran routines sla_GRESID, sla_RANDOM and +sla_WAIT have no C counterparts. +

+Further details of the C version of SLALIB are available +from the author. The definitive guide to +the calling sequences is the file slalib.h. +

+


+ +next + +up + +previous +
+ Next: Future Versions +
+Up: INTRODUCTION +
+ Previous: Fortran Version +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node80.html b/src/slalib/sun67.htx/node80.html new file mode 100644 index 0000000..e7704f5 --- /dev/null +++ b/src/slalib/sun67.htx/node80.html @@ -0,0 +1,111 @@ + + + + +SLA_DTT - TT minus UTC + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DV2TP - Direction Cosines to Tangent Plane +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTPV2C - Plate centre from and x,y,z +

+

+

SLA_DTT - TT minus UTC +   +

+
+
ACTION: +
Compute $\Delta$TT, the increment to be applied to +Coordinated Universal Time UTC to give + Terrestrial Time TT. +

CALL: +
D = sla_DTT (DJU) +

+

+
GIVEN: +
+
+ + + + + +
DJUDUTC date as a modified JD (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
sla_DTTDTT-UTC in seconds
+

+
NOTES: +
+
1. +
The UTC is specified to be a date rather than a time to indicate +that care needs to be taken not to specify an instant which lies +within a leap second. Though in most cases UTC can include the + fractional part, correct behaviour on the day of a leap second + can be guaranteed only up to the end of the second + $23^{\rm h}\,59^{\rm m}\,59^{\rm s}$.
2. +
Pre 1972 January 1 a fixed value of 10 + ET-TAI is returned. +
3. +
TT is one interpretation of the defunct timescale + Ephemeris Time, ET. +
4. +
See also the routine sla_DT, which roughly estimates ET-UT for + historical epochs. +
+

+ +next + +up + +previous +
+ Next: SLA_DV2TP - Direction Cosines to Tangent Plane +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTPV2C - Plate centre from and x,y,z +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node81.html b/src/slalib/sun67.htx/node81.html new file mode 100644 index 0000000..eba8ed9 --- /dev/null +++ b/src/slalib/sun67.htx/node81.html @@ -0,0 +1,137 @@ + + + + +SLA_DV2TP - Direction Cosines to Tangent Plane + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DVDV - Scalar Product +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTT - TT minus UTC +

+

+

SLA_DV2TP - Direction Cosines to Tangent Plane +   +

+
+
ACTION: +
Given the direction cosines of a star and of the tangent point, +determine the star's tangent-plane coordinates + (double precision). +

CALL: +
CALL sla_DV2TP (V, V0, XI, ETA, J) +

+

+
GIVEN: +
+
+ + + + + + + + + +
VD(3)direction cosines of star
V0D(3)direction cosines of tangent point
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
XI,ETADtangent plane coordinates (radians)
JIstatus:
0 = OK, star on tangent plane
1 = error, star too far from axis
2 = error, antistar on tangent plane
3 = error, antistar too far from axis
+

+
NOTES: +
+
1. +
If vector V0 is not of unit length, or if vector V is of zero +length, the results will be wrong. +
2. +
If V0 points at a pole, the returned $\xi,\eta$ will be based on the + arbitrary assumption that $\alpha=0$ at the tangent point. +
3. +
The projection is called the gnomonic projection; the + Cartesian coordinates $[\,\xi,\eta\,]$ are called + standard coordinates. The latter + are in units of the distance from the tangent plane to the projection + point, i.e. radians near the origin. +
4. +
This routine is the Cartesian equivalent of the routine sla_DS2TP. +
+

+ +next + +up + +previous +
+ Next: SLA_DVDV - Scalar Product +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DTT - TT minus UTC +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node82.html b/src/slalib/sun67.htx/node82.html new file mode 100644 index 0000000..024100b --- /dev/null +++ b/src/slalib/sun67.htx/node82.html @@ -0,0 +1,91 @@ + + + + +SLA_DVDV - Scalar Product + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DVN - Normalize Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DV2TP - Direction Cosines to Tangent Plane +

+

+

SLA_DVDV - Scalar Product +   +

+
+
ACTION: +
Scalar product of two 3-vectors (double precision). +
CALL: +
D = sla_DVDV (VA, VB) +

+

+
GIVEN: +
+
+ + + + + + + + + +
VAD(3)first vector
VBD(3)second vector
+

+
RETURNED: +
+
+ + + + + +
sla_DVDVDscalar product VA.VB
+

+ +next + +up + +previous +
+ Next: SLA_DVN - Normalize Vector +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DV2TP - Direction Cosines to Tangent Plane +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node83.html b/src/slalib/sun67.htx/node83.html new file mode 100644 index 0000000..073d4ef --- /dev/null +++ b/src/slalib/sun67.htx/node83.html @@ -0,0 +1,95 @@ + + + + +SLA_DVN - Normalize Vector + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_DVXV - Vector Product +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DVDV - Scalar Product +

+

+

SLA_DVN - Normalize Vector +   +

+
+
ACTION: +
Normalize a 3-vector, also giving the modulus (double precision). +
CALL: +
CALL sla_DVN (V, UV, VM) +

+

+
GIVEN: +
+
+ + + + + +
VD(3)vector
+

+
RETURNED: +
+
+ + + + + + + + + +
UVD(3)unit vector in direction of V
VMDmodulus of V
+

+
NOTE: +
If the modulus of V is zero, UV is set to zero as well. +
+

+ +next + +up + +previous +
+ Next: SLA_DVXV - Vector Product +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DVDV - Scalar Product +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node84.html b/src/slalib/sun67.htx/node84.html new file mode 100644 index 0000000..745d1f0 --- /dev/null +++ b/src/slalib/sun67.htx/node84.html @@ -0,0 +1,93 @@ + + + + +SLA_DVXV - Vector Product + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_E2H - to Az,El +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DVN - Normalize Vector +

+

+

SLA_DVXV - Vector Product +   +

+
+
ACTION: +
Vector product of two 3-vectors (double precision). +
CALL: +
CALL sla_DVXV (VA, VB, VC) +

+

+
GIVEN: +
+
+ + + + + + + + + +
VAD(3)first vector
VBD(3)second vector
+

+
RETURNED: +
+
+ + + + + +
VCD(3)vector product VA$\times$VB
+

+ +next + +up + +previous +
+ Next: SLA_E2H - to Az,El +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DVN - Normalize Vector +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node85.html b/src/slalib/sun67.htx/node85.html new file mode 100644 index 0000000..3c589df --- /dev/null +++ b/src/slalib/sun67.htx/node85.html @@ -0,0 +1,145 @@ + + + + +SLA_E2H - to Az,El + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EARTH - Approx Earth Pos/Vel +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DVXV - Vector Product +

+

+

    +
+SLA_E2H - $h,\delta$ to Az,El +

+
+
ACTION: +
Equatorial to horizon coordinates +(single precision). +

CALL: +
CALL sla_DE2H (HA, DEC, PHI, AZ, EL) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
HARhour angle (radians)
DECRdeclination (radians)
PHIRlatitude (radians)
+

+
RETURNED: +
+
+ + + + + + + + + +
AZRazimuth (radians)
ELRelevation (radians)
+

+
NOTES: +
+
1. +
Azimuth is returned in the range $0\!-\!2\pi$; north is zero, +and east is $+\pi/2$. Elevation is returned in the range +$\pm \pi$.
2. +
The latitude must be geodetic. In critical applications, + corrections for polar motion should be applied. +
3. +
In some applications it will be important to specify the + correct type of hour angle and declination in order to + produce the required type of azimuth and elevation. In + particular, it may be important to distinguish between + elevation as affected by refraction, which would + require the observed $[\,h,\delta\,]$, and the elevation + in vacuo, which would require the topocentric + $[\,h,\delta\,]$. If the effects of diurnal aberration can be neglected, the + apparent $[\,h,\delta\,]$ may be used instead of the topocentric + $[\,h,\delta\,]$.
4. +
No range checking of arguments is carried out. +
5. +
In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude, and (for tracking a star) + sine and cosine of declination. +
+

+ +next + +up + +previous +
+ Next: SLA_EARTH - Approx Earth Pos/Vel +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_DVXV - Vector Product +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node86.html b/src/slalib/sun67.htx/node86.html new file mode 100644 index 0000000..6507524 --- /dev/null +++ b/src/slalib/sun67.htx/node86.html @@ -0,0 +1,124 @@ + + + + +SLA_EARTH - Approx Earth Pos/Vel + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_ECLEQ - Ecliptic to Equatorial +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_E2H - to Az,El +

+

+

SLA_EARTH - Approx Earth Pos/Vel +   +

+
+
ACTION: +
Approximate heliocentric position and velocity of the Earth +(single precision). +

CALL: +
CALL sla_EARTH (IY, ID, FD, PV) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
IYIyear
IDIday in year (1 = Jan 1st)
FDRfraction of day
+

+
RETURNED: +
+
+ + + + + +
PVR(6)Earth $[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$ (AU, AU s-1)
+

+
NOTES: +
+
1. +
The date and time is TDB (loosely ET) in a Julian calendar +which has been aligned to the ordinary Gregorian +calendar for the interval 1900 March 1 to 2100 February 28. + The year and day can be obtained by calling sla_CALYD or + sla_CLYD. +
2. +
The Earth heliocentric 6-vector is referred to the + FK4 mean equator and equinox of date. +
3. +
Maximum/RMS errors 1950-2050: +
    +
  • 13/5 $\times10^{-5}$ AU = 19200/7600 km in position +
  • 47/26 $\times10^{-10}$ AU s-1 = + 0.0070/0.0039 km s-1 in speed +
+
4. +
More accurate results are obtainable with the routine sla_EVP. +
+

+ +next + +up + +previous +
+ Next: SLA_ECLEQ - Ecliptic to Equatorial +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_E2H - to Az,El +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node87.html b/src/slalib/sun67.htx/node87.html new file mode 100644 index 0000000..5935487 --- /dev/null +++ b/src/slalib/sun67.htx/node87.html @@ -0,0 +1,97 @@ + + + + +SLA_ECLEQ - Ecliptic to Equatorial + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_ECMAT - Form Matrix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EARTH - Approx Earth Pos/Vel +

+

+

SLA_ECLEQ - Ecliptic to Equatorial +   +

+
+
ACTION: +
Transformation from ecliptic longitude and latitude to +J2000.0 $[\,\alpha,\delta\,]$.

CALL: +
CALL sla_ECLEQ (DL, DB, DATE, DR, DD) +

+

+
GIVEN: +
+
+ + + + + + + + + +
DL,DBDecliptic longitude and latitude +(mean of date, IAU 1980 theory, radians)
DATEDTDB (formerly ET) as Modified Julian Date +(JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
DR,DDDJ2000.0 mean $[\,\alpha,\delta\,]$ (radians)
+

+ +next + +up + +previous +
+ Next: SLA_ECMAT - Form Matrix +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EARTH - Approx Earth Pos/Vel +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node88.html b/src/slalib/sun67.htx/node88.html new file mode 100644 index 0000000..895c629 --- /dev/null +++ b/src/slalib/sun67.htx/node88.html @@ -0,0 +1,106 @@ + + + + +SLA_ECMAT - Form Matrix + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_ECOR - RV & Time Corrns to Sun +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ECLEQ - Ecliptic to Equatorial +

+

+

    +
+SLA_ECMAT - Form $\alpha,\delta\rightarrow\lambda,\beta$ Matrix +

+
+
ACTION: +
Form the equatorial to ecliptic rotation matrix (IAU 1980 theory). +
CALL: +
CALL sla_ECMAT (DATE, RMAT) +

+

+
GIVEN: +
+
+ + + + + +
DATEDTDB (formerly ET) as Modified Julian Date +(JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
RMATD(3,3)rotation matrix
+

+
NOTES: +
+
1. +
RMAT is matrix M in the expression +vecl = M$\cdot$vequ. +
2. +
The equator, equinox and ecliptic are mean of date. +
+

+
REFERENCE: +
Murray, C.A., Vectorial Astrometry, section 4.3. +
+

+ +next + +up + +previous +
+ Next: SLA_ECOR - RV & Time Corrns to Sun +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ECLEQ - Ecliptic to Equatorial +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node89.html b/src/slalib/sun67.htx/node89.html new file mode 100644 index 0000000..990df2a --- /dev/null +++ b/src/slalib/sun67.htx/node89.html @@ -0,0 +1,140 @@ + + + + +SLA_ECOR - RV & Time Corrns to Sun + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EG50 - B1950 to Galactic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ECMAT - Form Matrix +

+

+

SLA_ECOR - RV & Time Corrns to Sun +   +

+
+
ACTION: +
Component of Earth orbit velocity and heliocentric +light time in a given direction. +

CALL: +
CALL sla_ECOR (RM, DM, IY, ID, FD, RV, TL) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + +
RM,DMRmean $[\,\alpha,\delta\,]$ of date (radians)
IYIyear
IDIday in year (1 = Jan 1st)
FDRfraction of day
+

+
RETURNED: +
+
+ + + + + + + + + +
RVRcomponent of Earth orbital velocity (km s-1)
TLRcomponent of heliocentric light time (s)
+

+
NOTES: +
+
1. +
The date and time is TDB (loosely ET) in a Julian calendar +which has been aligned to the ordinary Gregorian +calendar for the interval 1900 March 1 to 2100 February 28. + The year and day can be obtained by calling sla_CALYD or + sla_CLYD. +
2. +
Sign convention: +
    +
  • The velocity component is +ve when the + Earth is receding from + the given point on the sky. +
  • The light time component is +ve + when the Earth lies between the Sun and + the given point on the sky. +
+
3. +
Accuracy: +
    +
  • The velocity component is usually within 0.004 km s-1 + of the correct value and is never in error by more than + 0.007 km s-1. +
  • The error in light time correction is about + $0^{\rm s}\hspace{-0.3em}.03$ at worst, + but is usually better than $0^{\rm s}\hspace{-0.3em}.01$.
+ For applications requiring higher accuracy, see the sla_EVP routine. +
+

+ +next + +up + +previous +
+ Next: SLA_EG50 - B1950 to Galactic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ECMAT - Form Matrix +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node9.html b/src/slalib/sun67.htx/node9.html new file mode 100644 index 0000000..a9d8058 --- /dev/null +++ b/src/slalib/sun67.htx/node9.html @@ -0,0 +1,75 @@ + + + + +Future Versions + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: New Functions +
+Up: INTRODUCTION +
+ Previous: C Version +

+

+

+Future Versions +

+The homogeneity and ease of use of SLALIB could perhaps be improved +in the future +by turning to C++ and object-oriented techniques. For example ``celestial +position'' could be a class and many of the transformations +could happen automatically. This requires further study and +would almost certainly result in a complete redesign. +Similarly, +the impact of Fortran 90 has yet to be assessed. Once compilers +become widely available, some internal recoding may be worthwhile +in order to simplify parts of the code. However, as with C++, +a redesign of the +application interfaces will be needed if the capabilities of the +new language are to be exploited to the full. +

+


+ +next + +up + +previous +
+ Next: New Functions +
+Up: INTRODUCTION +
+ Previous: C Version +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node90.html b/src/slalib/sun67.htx/node90.html new file mode 100644 index 0000000..1deba43 --- /dev/null +++ b/src/slalib/sun67.htx/node90.html @@ -0,0 +1,106 @@ + + + + +SLA_EG50 - B1950 to Galactic + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EL2UE - Conventional to Universal Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ECOR - RV & Time Corrns to Sun +

+

+

    +
+SLA_EG50 - B1950 $\alpha,\delta$ to Galactic +

+
+
ACTION: +
Transformation from B1950.0 FK4 equatorial coordinates to +IAU 1958 galactic coordinates. +

CALL: +
CALL sla_EG50 (DR, DD, DL, DB) +

+

+
GIVEN: +
+
+ + + + + +
DR,DDDB1950.0 $[\,\alpha,\delta\,]$ (radians)
+

+
RETURNED: +
+
+ + + + + +
DL,DBDgalactic longitude and latitude $[\,l^{I\!I},b^{I\!I}\,]$ (radians)
+

+
NOTE: +
The equatorial coordinates are B1950.0 FK4. Use the +routine sla_EQGAL if conversion from J2000.0 FK5 coordinates + is required. +
+

+
REFERENCE: +
Blaauw et al., 1960, Mon.Not.R.astr.Soc., +121, 123. +
+

+ +next + +up + +previous +
+ Next: SLA_EL2UE - Conventional to Universal Elements +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_ECOR - RV & Time Corrns to Sun +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node91.html b/src/slalib/sun67.htx/node91.html new file mode 100644 index 0000000..2beedff --- /dev/null +++ b/src/slalib/sun67.htx/node91.html @@ -0,0 +1,330 @@ + + + + +SLA_EL2UE - Conventional to Universal Elements + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EPB - MJD to Besselian Epoch +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EG50 - B1950 to Galactic +

+

+

SLA_EL2UE - Conventional to Universal Elements +   +

+
+
ACTION: +
Transform conventional osculating orbital elements +into ``universal'' form. +

CALL: +
CALL sla_EL2UE ( + DATE, JFORM, EPOCH, ORBINC, ANODE, + PERIH, AORQ, E, AORL, DM, + U, JSTAT) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
DATEDepoch (TT MJD) of osculation (Note 3)
JFORMIchoice of element set (1-3; Note 6)
EPOCHDepoch of elements (t0 or T, TT MJD)
ORBINCDinclination (i, radians)
ANODEDlongitude of the ascending node ($\Omega$, radians)
PERIHDlongitude or argument of perihelion +($\varpi$ or $\omega$,
radians)
AORQDmean distance or perihelion distance (a or q, AU)
EDeccentricity (e)
AORLDmean anomaly or longitude +(M or L, radians,
JFORM=1,2 only)
DMDdaily motion (n, radians, JFORM=1 only)
+

+
RETURNED: +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
UD(13)universal orbital elements (Note 1)
(1)combined mass (M+m)
(2)total energy of the orbit ($\alpha$)
(3)reference (osculating) epoch (t0)
(4-6)position at reference epoch (${\rm \bf r}_0$)
(7-9)velocity at reference epoch (${\rm \bf v}_0$)
(10)heliocentric distance at reference epoch
(11)${\rm \bf r}_0.{\rm \bf v}_0$
(12)date (t)
(13)universal eccentric anomaly ($\psi$) of date, +approx
   
JSTATIstatus:
0 = OK
-1 = illegal JFORM
-2 = illegal E
-3 = illegal AORQ
-4 = illegal DM
-5 = numerical error
+

+
NOTES: +
+
1. +
The ``universal'' elements are those which define the orbit for +the purposes of the method of universal variables (see reference). +They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i) $\alpha$, which is proportional to the total energy of the + orbit, (ii) the heliocentric distance at epoch, + (iii) the outwards component of the velocity at the given epoch, + (iv) an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v) that date. +
2. +
The companion routine is sla_UE2PV. This takes the set of numbers + that the present routine outputs and uses them to derive the + object's position and velocity. A single prediction requires one + call to the present routine followed by one call to sla_UE2PV; + for convenience, the two calls are packaged as the routine + sla_PLANEL. Multiple predictions may be made by again calling the + present routine once, but then calling sla_UE2PV multiple times, + which is faster than multiple calls to sla_PLANEL. +
3. +
DATE is the epoch of osculation. It is in the TT timescale + (formerly Ephemeris Time, ET) and is a Modified Julian Date + (JD-2400000.5). +
4. +
The supplied orbital elements are with respect to the J2000 + ecliptic and equinox. The position and velocity parameters + returned in the array U are with respect to the mean equator and + equinox of epoch J2000, and are for the perihelion prior to the + specified epoch. +
5. +
The universal elements returned in the array U are in canonical + units (solar masses, AU and canonical days). +
6. +
Three different element-format options are supported, as + follows.
+

+JFORM=1, suitable for the major planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 longitude of perihelion $\varpi$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e < 1 )$ 
+		 AORL 		 = 		 mean longitude L (radians)
+		 DM 		 = 		 daily motion n (radians)        
+
+

+JFORM=2, suitable for minor planets: +


+ 		 EPOCH 		 = 		 epoch of elements t0 (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 mean distance a (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e < 1 )$ 
+		 AORL 		 = 		 mean anomaly M (radians)        
+
+

+JFORM=3, suitable for comets: +


+ 		 EPOCH 		 = 		 epoch of perihelion T (TT MJD)
+		 ORBINC 		 = 		 inclination i (radians)
+		 ANODE 		 = 		 longitude of the ascending node $\Omega$ (radians)
+		 PERIH 		 = 		 argument of perihelion $\omega$ (radians)
+		 AORQ 		 = 		 perihelion distance q (AU)
+		 E 		 = 		 eccentricity e $( 0 \leq e \leq 10 )$
+
7. +
Unused elements (DM for JFORM=2, AORL and DM for JFORM=3) are + not accessed. +
8. +
The algorithm was originally adapted from the EPHSLA program of + D.H.P.Jones (private communication, 1996). The method + is based on Stumpff's Universal Variables. +
+

+
REFERENCE: +
Everhart, E. & Pitkin, E.T., Am. J. Phys. 51, 712, 1983. +
+

+ +next + +up + +previous +
+ Next: SLA_EPB - MJD to Besselian Epoch +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EG50 - B1950 to Galactic +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node92.html b/src/slalib/sun67.htx/node92.html new file mode 100644 index 0000000..854488f --- /dev/null +++ b/src/slalib/sun67.htx/node92.html @@ -0,0 +1,91 @@ + + + + +SLA_EPB - MJD to Besselian Epoch + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EPB2D - Besselian Epoch to MJD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EL2UE - Conventional to Universal Elements +

+

+

SLA_EPB - MJD to Besselian Epoch +   +

+
+
ACTION: +
Conversion of Modified Julian Date to Besselian Epoch. +
CALL: +
D = sla_EPB (DATE) +

+

+
GIVEN: +
+
+ + + + + +
DATEDModified Julian Date (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
sla_EPBDBesselian Epoch
+

+
REFERENCE: +
Lieske, J.H., 1979, Astr.Astrophys. 73, 282. +
+

+ +next + +up + +previous +
+ Next: SLA_EPB2D - Besselian Epoch to MJD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EL2UE - Conventional to Universal Elements +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node93.html b/src/slalib/sun67.htx/node93.html new file mode 100644 index 0000000..c142fe7 --- /dev/null +++ b/src/slalib/sun67.htx/node93.html @@ -0,0 +1,91 @@ + + + + +SLA_EPB2D - Besselian Epoch to MJD + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EPCO - Convert Epoch to B or J +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPB - MJD to Besselian Epoch +

+

+

SLA_EPB2D - Besselian Epoch to MJD +   +

+
+
ACTION: +
Conversion of Besselian Epoch to Modified Julian Date. +
CALL: +
D = sla_EPB2D (EPB) +

+

+
GIVEN: +
+
+ + + + + +
EPBDBesselian Epoch
+

+
RETURNED: +
+
+ + + + + +
sla_EPB2DDModified Julian Date (JD-2400000.5)
+

+
REFERENCE: +
Lieske, J.H., 1979. Astr.Astrophys. 73, 282. +
+

+ +next + +up + +previous +
+ Next: SLA_EPCO - Convert Epoch to B or J +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPB - MJD to Besselian Epoch +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node94.html b/src/slalib/sun67.htx/node94.html new file mode 100644 index 0000000..e71fda8 --- /dev/null +++ b/src/slalib/sun67.htx/node94.html @@ -0,0 +1,110 @@ + + + + +SLA_EPCO - Convert Epoch to B or J + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EPJ - MJD to Julian Epoch +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPB2D - Besselian Epoch to MJD +

+

+

SLA_EPCO - Convert Epoch to B or J +   +

+
+
ACTION: +
Convert an epoch to Besselian or Julian to match another one. +
CALL: +
D = sla_EPCO (K0, K, E) +

+

+
GIVEN: +
+
+ + + + + + + + + + + + + +
K0Cform of result: `B'=Besselian, `J'=Julian
KCform of given epoch: `B' or `J'
EDepoch
+

+
RETURNED: +
+
+ + + + + +
sla_EPCODthe given epoch converted as necessary
+

+
NOTES: +
+
1. +
The result is always either equal to or very close to +the given epoch E. The routine is required only in +applications where punctilious treatment of heterogeneous + mixtures of star positions is necessary. +
2. +
K0 and K are not validated. They are interpreted as follows: +
    +
  • If K0 and K are the same, the result is E. +
  • If K0 is `B' and K isn't, the conversion is J to B. +
  • In all other cases, the conversion is B to J. +
+

+ +next + +up + +previous +
+ Next: SLA_EPJ - MJD to Julian Epoch +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPB2D - Besselian Epoch to MJD +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node95.html b/src/slalib/sun67.htx/node95.html new file mode 100644 index 0000000..aefb9d6 --- /dev/null +++ b/src/slalib/sun67.htx/node95.html @@ -0,0 +1,91 @@ + + + + +SLA_EPJ - MJD to Julian Epoch + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EPJ2D - Julian Epoch to MJD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPCO - Convert Epoch to B or J +

+

+

SLA_EPJ - MJD to Julian Epoch +   +

+
+
ACTION: +
Convert Modified Julian Date to Julian Epoch. +
CALL: +
D = sla_EPJ (DATE) +

+

+
GIVEN: +
+
+ + + + + +
DATEDModified Julian Date (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
sla_EPJDJulian Epoch
+

+
REFERENCE: +
Lieske, J.H., 1979. Astr.Astrophys., 73, 282. +
+

+ +next + +up + +previous +
+ Next: SLA_EPJ2D - Julian Epoch to MJD +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPCO - Convert Epoch to B or J +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node96.html b/src/slalib/sun67.htx/node96.html new file mode 100644 index 0000000..c0f38a9 --- /dev/null +++ b/src/slalib/sun67.htx/node96.html @@ -0,0 +1,91 @@ + + + + +SLA_EPJ2D - Julian Epoch to MJD + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EQECL - J2000 to Ecliptic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPJ - MJD to Julian Epoch +

+

+

SLA_EPJ2D - Julian Epoch to MJD +   +

+
+
ACTION: +
Convert Julian Epoch to Modified Julian Date. +
CALL: +
D = sla_EPJ2D (EPJ) +

+

+
GIVEN: +
+
+ + + + + +
EPJDJulian Epoch
+

+
RETURNED: +
+
+ + + + + +
sla_EPJ2DDModified Julian Date (JD-2400000.5)
+

+
REFERENCE: +
Lieske, J.H., 1979. Astr.Astrophys., 73, 282. +
+

+ +next + +up + +previous +
+ Next: SLA_EQECL - J2000 to Ecliptic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPJ - MJD to Julian Epoch +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node97.html b/src/slalib/sun67.htx/node97.html new file mode 100644 index 0000000..a386ad5 --- /dev/null +++ b/src/slalib/sun67.htx/node97.html @@ -0,0 +1,98 @@ + + + + +SLA_EQECL - J2000 to Ecliptic + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EQEQX - Equation of the Equinoxes +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPJ2D - Julian Epoch to MJD +

+

+

    +
+SLA_EQECL - J2000 $\alpha,\delta$ to Ecliptic +

+
+
ACTION: +
Transformation from J2000.0 equatorial coordinates to +ecliptic longitude and latitude. +

CALL: +
CALL sla_EQECL (DR, DD, DATE, DL, DB) +

+

+
GIVEN: +
+
+ + + + + + + + + +
DR,DDDJ2000.0 mean $[\,\alpha,\delta\,]$ (radians)
DATEDTDB (formerly ET) as Modified Julian Date (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
DL,DBDecliptic longitude and latitude +(mean of date, IAU 1980 theory, radians)
+

+ +next + +up + +previous +
+ Next: SLA_EQEQX - Equation of the Equinoxes +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EPJ2D - Julian Epoch to MJD +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node98.html b/src/slalib/sun67.htx/node98.html new file mode 100644 index 0000000..e5a2cc7 --- /dev/null +++ b/src/slalib/sun67.htx/node98.html @@ -0,0 +1,111 @@ + + + + +SLA_EQEQX - Equation of the Equinoxes + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_EQGAL - J2000 to Galactic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EQECL - J2000 to Ecliptic +

+

+

SLA_EQEQX - Equation of the Equinoxes +   +

+
+
ACTION: +
Equation of the equinoxes (IAU 1994). +
CALL: +
D = sla_EQEQX (DATE) +

+

+
GIVEN: +
+
+ + + + + +
DATEDTDB (formerly ET) as Modified Julian Date (JD-2400000.5)
+

+
RETURNED: +
+
+ + + + + +
sla_EQEQXDThe equation of the equinoxes (radians)
+

+
NOTES: +
+
1. +
The equation of the equinoxes is defined here as GAST - GMST: +it is added to a mean sidereal time to give the +apparent sidereal time. +
2. +
The change from the classic ``textbook'' expression + $\Delta\psi\,cos\,\epsilon$ occurred with IAU Resolution C7, + Recommendation 3 (1994). The new formulation takes into + account cross-terms between the various precession and + nutation quantities, amounting to about 3 milliarcsec. + The transition from the old to the new model officially + takes place on 1997 February 27. +
+

+
REFERENCE: +
Capitaine, N. & Gontier, A.-M. (1993), +Astron. Astrophys., + 275, 645-650. +
+

+ +next + +up + +previous +
+ Next: SLA_EQGAL - J2000 to Galactic +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EQECL - J2000 to Ecliptic +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/node99.html b/src/slalib/sun67.htx/node99.html new file mode 100644 index 0000000..1e4582a --- /dev/null +++ b/src/slalib/sun67.htx/node99.html @@ -0,0 +1,105 @@ + + + + +SLA_EQGAL - J2000 to Galactic + + + + + + + + + + + + +

+ +next + +up + +previous +
+ Next: SLA_ETRMS - E-terms of Aberration +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EQEQX - Equation of the Equinoxes +

+

+

    +
+SLA_EQGAL - J2000 $\alpha,\delta$ to Galactic +

+
+
ACTION: +
Transformation from J2000.0 FK5 equatorial coordinates to +IAU 1958 galactic coordinates. +

CALL: +
CALL sla_EQGAL (DR, DD, DL, DB) +

+

+
GIVEN: +
+
+ + + + + +
DR,DDDJ2000.0 $[\,\alpha,\delta\,]$ (radians)
+

+
RETURNED: +
+
+ + + + + +
DL,DBDgalactic longitude and latitude $[\,l^{I\!I},b^{I\!I}\,]$ (radians)
+

+
NOTE: +
The equatorial coordinates are J2000.0 FK5. Use the routine +sla_EG50 if conversion from B1950.0 FK4 coordinates is required. +
+

+
REFERENCE: +
Blaauw et al., 1960, Mon.Not.R.astr.Soc., +121, 123. +
+

+ +next + +up + +previous +
+ Next: SLA_ETRMS - E-terms of Aberration +
+Up: SUBPROGRAM SPECIFICATIONS +
+ Previous: SLA_EQEQX - Equation of the Equinoxes +

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/orangeball.gif b/src/slalib/sun67.htx/orangeball.gif new file mode 100644 index 0000000..e757cd0 Binary files /dev/null and b/src/slalib/sun67.htx/orangeball.gif differ diff --git a/src/slalib/sun67.htx/pinkball.gif b/src/slalib/sun67.htx/pinkball.gif new file mode 100644 index 0000000..43e843b Binary files /dev/null and b/src/slalib/sun67.htx/pinkball.gif differ diff --git a/src/slalib/sun67.htx/previous_group_motif.gif b/src/slalib/sun67.htx/previous_group_motif.gif new file mode 100644 index 0000000..03ea0dc Binary files /dev/null and b/src/slalib/sun67.htx/previous_group_motif.gif differ diff --git a/src/slalib/sun67.htx/previous_group_motif_gr.gif b/src/slalib/sun67.htx/previous_group_motif_gr.gif new file mode 100644 index 0000000..c7a1e2b Binary files /dev/null and b/src/slalib/sun67.htx/previous_group_motif_gr.gif differ diff --git a/src/slalib/sun67.htx/previous_motif.gif b/src/slalib/sun67.htx/previous_motif.gif new file mode 100644 index 0000000..aef90f1 Binary files /dev/null and b/src/slalib/sun67.htx/previous_motif.gif differ diff --git a/src/slalib/sun67.htx/previous_motif_gr.gif b/src/slalib/sun67.htx/previous_motif_gr.gif new file mode 100644 index 0000000..c6acaab Binary files /dev/null and b/src/slalib/sun67.htx/previous_motif_gr.gif differ diff --git a/src/slalib/sun67.htx/purpleball.gif b/src/slalib/sun67.htx/purpleball.gif new file mode 100644 index 0000000..4836265 Binary files /dev/null and b/src/slalib/sun67.htx/purpleball.gif differ diff --git a/src/slalib/sun67.htx/redball.gif b/src/slalib/sun67.htx/redball.gif new file mode 100644 index 0000000..b1a9580 Binary files /dev/null and b/src/slalib/sun67.htx/redball.gif differ diff --git a/src/slalib/sun67.htx/source.gif b/src/slalib/sun67.htx/source.gif new file mode 100755 index 0000000..c8dea79 Binary files /dev/null and b/src/slalib/sun67.htx/source.gif differ diff --git a/src/slalib/sun67.htx/sun67.css b/src/slalib/sun67.htx/sun67.css new file mode 100644 index 0000000..3970428 --- /dev/null +++ b/src/slalib/sun67.htx/sun67.css @@ -0,0 +1,10 @@ + +SMALL.TINY { font-size : xx-small } +SMALL.SCRIPTSIZE { font-size : xx-small } +SMALL.FOOTNOTESIZE { font-size : x-small } +SMALL.SMALL { font-size : small } +BIG.LARGE { font-size : large } +BIG.XLARGE { font-size : x-large } +BIG.XXLARGE { font-size : xx-large } +BIG.HUGE { font-size : xx-large } +BIG.XHUGE { font-size : xx-large } diff --git a/src/slalib/sun67.htx/sun67.html b/src/slalib/sun67.htx/sun67.html new file mode 100644 index 0000000..1836213 --- /dev/null +++ b/src/slalib/sun67.htx/sun67.html @@ -0,0 +1,610 @@ + + + + +SLALIB -- Positional Astronomy Library + + + + + + + + + +

+ +next +up +previous +
+ Next: Abstract +
+

+

+

  +

+ SLALIB -- Positional Astronomy Library +
+2.4-0 +
+Programmer's Manual +

+

+ Starlink User Note67.45 +
+P.T.Wallace +
+12 October 1999 +

+ CCLRC +/ + Rutherford Appleton Laboratory +
+ Particle Physics & Astronomy Research Council +
+

+ Starlink Project +

+ Retrieve hardcopy +
+ 
+

Contents

+



+ +  + + +

+ +next +up +previous +
+ Next: Abstract +
+

+

+

+SLALIB --- Positional Astronomy Library
Starlink User Note 67
P. T. Wallace
12 October 1999
E-mail:ptw@star.rl.ac.uk
+
+ + diff --git a/src/slalib/sun67.htx/up_motif.gif b/src/slalib/sun67.htx/up_motif.gif new file mode 100644 index 0000000..3d1aebf Binary files /dev/null and b/src/slalib/sun67.htx/up_motif.gif differ diff --git a/src/slalib/sun67.htx/up_motif_gr.gif b/src/slalib/sun67.htx/up_motif_gr.gif new file mode 100644 index 0000000..a8b463a Binary files /dev/null and b/src/slalib/sun67.htx/up_motif_gr.gif differ diff --git a/src/slalib/sun67.htx/whiteball.gif b/src/slalib/sun67.htx/whiteball.gif new file mode 100644 index 0000000..4a90ea1 Binary files /dev/null and b/src/slalib/sun67.htx/whiteball.gif differ diff --git a/src/slalib/sun67.htx/yellowball.gif b/src/slalib/sun67.htx/yellowball.gif new file mode 100644 index 0000000..c6ba6b1 Binary files /dev/null and b/src/slalib/sun67.htx/yellowball.gif differ diff --git a/src/slalib/sun67.htx_tar b/src/slalib/sun67.htx_tar new file mode 100644 index 0000000..5dabe52 Binary files /dev/null and b/src/slalib/sun67.htx_tar differ diff --git a/src/slalib/sun67.tex b/src/slalib/sun67.tex new file mode 100644 index 0000000..3047136 --- /dev/null +++ b/src/slalib/sun67.tex @@ -0,0 +1,12430 @@ +\documentclass[11pt,twoside]{article} +\setcounter{tocdepth}{2} +\pagestyle{myheadings} + +% ----------------------------------------------------------------------------- +% ? Document identification +\newcommand{\stardoccategory} {Starlink User Note} +\newcommand{\stardocinitials} {SUN} +\newcommand{\stardocsource} {sun67.45} +\newcommand{\stardocnumber} {67.45} +\newcommand{\stardocauthors} {P.\,T.\,Wallace} +\newcommand{\stardocdate} {12 October 1999} +\newcommand{\stardoctitle} {SLALIB --- Positional Astronomy Library} +\newcommand{\stardocversion} {2.4-0} +\newcommand{\stardocmanual} {Programmer's Manual} +% ? End of document identification + +%%% Also see \nroutines definition later %%% + +% ----------------------------------------------------------------------------- + +\newcommand{\stardocname}{\stardocinitials /\stardocnumber} +\markright{\stardocname} + +%---------------------------------------------------- +% Comment out unwanted definitions to suit stationery + +\setlength{\textwidth}{160mm} % +\setlength{\textheight}{230mm} % European A4 +\setlength{\topmargin}{-5mm} % + +%\setlength{\textwidth}{167mm} % +%\setlength{\textheight}{220mm} % US Letter +%\setlength{\topmargin}{-10mm} % + +% +%---------------------------------------------------- + +\setlength{\textwidth}{160mm} +\setlength{\textheight}{230mm} +\setlength{\topmargin}{-2mm} +\setlength{\oddsidemargin}{0mm} +\setlength{\evensidemargin}{0mm} +\setlength{\parindent}{0mm} +\setlength{\parskip}{\medskipamount} +\setlength{\unitlength}{1mm} + +% ----------------------------------------------------------------------------- +% Hypertext definitions. +% ====================== +% These are used by the LaTeX2HTML translator in conjunction with star2html. + +% Comment.sty: version 2.0, 19 June 1992 +% Selectively in/exclude pieces of text. +% +% Author +% Victor Eijkhout +% Department of Computer Science +% University Tennessee at Knoxville +% 104 Ayres Hall +% Knoxville, TN 37996 +% USA + +% Do not remove the %\begin{rawtex} and %\end{rawtex} lines (used by +% star2html to signify raw TeX that latex2html cannot process). +%\begin{rawtex} +\makeatletter +\def\makeinnocent#1{\catcode`#1=12 } +\def\csarg#1#2{\expandafter#1\csname#2\endcsname} + +\def\ThrowAwayComment#1{\begingroup + \def\CurrentComment{#1}% + \let\do\makeinnocent \dospecials + \makeinnocent\^^L% and whatever other special cases + \endlinechar`\^^M \catcode`\^^M=12 \xComment} +{\catcode`\^^M=12 \endlinechar=-1 % + \gdef\xComment#1^^M{\def\test{#1} + \csarg\ifx{PlainEnd\CurrentComment Test}\test + \let\html@next\endgroup + \else \csarg\ifx{LaLaEnd\CurrentComment Test}\test + \edef\html@next{\endgroup\noexpand\end{\CurrentComment}} + \else \let\html@next\xComment + \fi \fi \html@next} +} +\makeatother + +\def\includecomment + #1{\expandafter\def\csname#1\endcsname{}% + \expandafter\def\csname end#1\endcsname{}} +\def\excludecomment + #1{\expandafter\def\csname#1\endcsname{\ThrowAwayComment{#1}}% + {\escapechar=-1\relax + \csarg\xdef{PlainEnd#1Test}{\string\\end#1}% + \csarg\xdef{LaLaEnd#1Test}{\string\\end\string\{#1\string\}}% + }} + +% Define environments that ignore their contents. +\excludecomment{comment} +\excludecomment{rawhtml} +\excludecomment{htmlonly} +%\end{rawtex} + +% Hypertext commands etc. This is a condensed version of the html.sty +% file supplied with LaTeX2HTML by: Nikos Drakos & +% Jelle van Zeijl . The LaTeX2HTML documentation +% should be consulted about all commands (and the environments defined above) +% except \xref and \xlabel which are Starlink specific. + +\newcommand{\htmladdnormallinkfoot}[2]{#1\footnote{#2}} +\newcommand{\htmladdnormallink}[2]{#1} +\newcommand{\htmladdimg}[1]{} +\newenvironment{latexonly}{}{} +\newcommand{\hyperref}[4]{#2\ref{#4}#3} +\newcommand{\htmlref}[2]{#1} +\newcommand{\htmlimage}[1]{} +\newcommand{\htmladdtonavigation}[1]{} + +% Starlink cross-references and labels. +\newcommand{\xref}[3]{#1} +\newcommand{\xlabel}[1]{} + +% LaTeX2HTML symbol. +\newcommand{\latextohtml}{{\bf LaTeX}{2}{\tt{HTML}}} + +% Define command to re-centre underscore for Latex and leave as normal +% for HTML (severe problems with \_ in tabbing environments and \_\_ +% generally otherwise). +\newcommand{\latex}[1]{#1} +\newcommand{\setunderscore}{\renewcommand{\_}{{\tt\symbol{95}}}} +\latex{\setunderscore} + +% Redefine the \tableofcontents command. This procrastination is necessary +% to stop the automatic creation of a second table of contents page +% by latex2html. +\newcommand{\latexonlytoc}[0]{\tableofcontents} + +% ----------------------------------------------------------------------------- +% Debugging. +% ========= +% Remove % on the following to debug links in the HTML version using Latex. + +% \newcommand{\hotlink}[2]{\fbox{\begin{tabular}[t]{@{}c@{}}#1\\\hline{\footnotesize #2}\end{tabular}}} +% \renewcommand{\htmladdnormallinkfoot}[2]{\hotlink{#1}{#2}} +% \renewcommand{\htmladdnormallink}[2]{\hotlink{#1}{#2}} +% \renewcommand{\hyperref}[4]{\hotlink{#1}{\S\ref{#4}}} +% \renewcommand{\htmlref}[2]{\hotlink{#1}{\S\ref{#2}}} +% \renewcommand{\xref}[3]{\hotlink{#1}{#2 -- #3}} +% ----------------------------------------------------------------------------- +% ? Document specific \newcommand or \newenvironment commands. +%------------------------------------------------------------------------------ + +\newcommand{\nroutines} {183} +\newcommand{\radec} {$[\,\alpha,\delta\,]$} +\newcommand{\hadec} {$[\,h,\delta\,]$} +\newcommand{\xieta} {$[\,\xi,\eta\,]$} +\newcommand{\azel} {$[\,Az,El~]$} +\newcommand{\ecl} {$[\,\lambda,\beta~]$} +\newcommand{\gal} {$[\,l^{I\!I},b^{I\!I}\,]$} +\newcommand{\xy} {$[\,x,y\,]$} +\newcommand{\xyz} {$[\,x,y,z\,]$} +\newcommand{\xyzd} {$[\,\dot{x},\dot{y},\dot{z}\,]$} +\newcommand{\xyzxyzd} {$[\,x,y,z,\dot{x},\dot{y},\dot{z}\,]$} +\newcommand{\degree}[2] {$#1^{\circ} + \hspace{-0.37em}.\hspace{0.02em}#2$} + +\newcommand{\arcsec}[2] {\arcseci{#1}$\hspace{-0.4em}.#2$} +\begin{htmlonly} + \newcommand{\arcsec}[2] { + {$#1\hspace{-0.05em}^{'\hspace{-0.1em}'}\hspace{-0.4em}.#2$} + } +\end{htmlonly} + +\newcommand{\arcseci}[1] {$#1\hspace{-0.05em}$\raisebox{-0.5ex} + {$^{'\hspace{-0.1em}'}$}} +\begin{htmlonly} + \renewcommand{\arcseci}[1] {$#1\hspace{-0.05em}^{'\hspace{-0.1em}'}$} +\end{htmlonly} + +\newcommand{\dms}[4] {$#1^{\circ}\,#2\raisebox{-0.5ex} + {$^{'}$}\,$\arcsec{#3}{#4}} +\begin{htmlonly} + \renewcommand{\dms}[4]{$#1^{\circ}\,#2^{'}\,#3^{''}.#4$} +\end{htmlonly} + +\newcommand{\tseci}[1] {$#1$\mbox{$^{\rm s}$}} +\newcommand{\tsec}[2] {\tseci{#1}$\hspace{-0.3em}.#2$} +\begin{htmlonly} + \renewcommand{\tsec}[2] {$#1^{\rm s}\hspace{-0.3em}.#2$} +\end{htmlonly} + +\newcommand{\hms}[4] {$#1^{\rm h}\,#2^{\rm m}\,$\tsec{#3}{#4}} +\begin{htmlonly} + \renewcommand{\hms}[4] {$#1^{h}\,#2^{m}\,#3^{s}.#4$} +\end{htmlonly} + +\newcommand{\callhead}[1]{\goodbreak\vspace{\bigskipamount}{\large\bf{#1}}} +\newenvironment{callset}{\begin{list}{}{\setlength{\leftmargin}{2cm} + \setlength{\parsep}{\smallskipamount}}}{\end{list}} +\newcommand{\subp}[1]{\item\hspace{-1cm}#1\\} +\newcommand{\subq}[2]{\item\hspace{-1cm}#1\\\hspace*{-1cm}#2\\} +\newcommand{\name}[1]{\mbox{#1}} +\newcommand{\fortvar}[1]{\mbox{\em #1}} + +\newcommand{\routine}[3] +{\hbadness=10000 + \vbox + { + \rule{\textwidth}{0.3mm}\\ + {\Large {\bf #1} \hfill #2 \hfill {\bf #1}}\\ + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + #3 + \end{description} + \setlength{\topsep}{\oldspacing} + } +} + +% Replacement for HTML version (each routine in own subsection). +\begin{htmlonly} + \renewcommand{\routine}[3] + { + \subsection{#1\xlabel{#1} - #2\label{#1}} + \begin{description} + #3 + \end{description} + } +\end{htmlonly} + +\newcommand{\action}[1] +{\item[ACTION]: #1} + +\begin{htmlonly} + \newcommand{\action}[1] + {\item[ACTION:] #1} +\end{htmlonly} + +\newcommand{\call}[1] +{\item[CALL]: \hspace{0.4em}{\tt #1}} +\newlength{\oldspacing} + +\begin{htmlonly} + \renewcommand{\call}[1] + { + \item[CALL:] {\tt #1} + } +\end{htmlonly} + +\newcommand{\args}[2] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[#1]:\\[1.5ex] + \begin{tabular}{p{7em}p{6em}p{22em}} + #2 + \end{tabular} + \end{description} + \setlength{\topsep}{\oldspacing} +} +\begin{htmlonly} + \renewcommand{\args}[2] + { + \begin{description} + \item[#1:]\\ + \begin{tabular}{p{7em}p{6em}l} + #2 + \end{tabular} + \end{description} + } +\end{htmlonly} + +\newcommand{\spec}[3] +{ + {\em {#1}} & {\bf \mbox{#2}} & {#3} +} + +\newcommand{\specel}[2] +{ + \multicolumn{1}{c}{#1} & {} & {#2} +} + +\newcommand{\anote}[1] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[NOTE]: + #1 + \end{description} + \setlength{\topsep}{\oldspacing} +} + +\begin{htmlonly} + \renewcommand{\anote}[1] + { + \begin{description} + \item[NOTE:] + #1 + \end{description} + } +\end{htmlonly} + +\newcommand{\notes}[1] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[NOTES]: + #1 + \end{description} + \setlength{\topsep}{\oldspacing} +} + +\begin{htmlonly} + \renewcommand{\notes}[1] + { + \begin{description} + \item[NOTES:] + #1 + \end{description} + } +\end{htmlonly} + +\newcommand{\aref}[1] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[REFERENCE]: + #1 + \end{description} + \setlength{\topsep}{\oldspacing} +} + +\begin{htmlonly} + \newcommand{\aref}[1] + { + \begin{description} + \item[REFERENCE:] + #1 + \end{description} + } +\end{htmlonly} + +\newcommand{\refs}[1] +{ + \goodbreak + \setlength{\oldspacing}{\topsep} + \setlength{\topsep}{0.3ex} + \begin{description} + \item[REFERENCES]: + #1 + \end{description} + \setlength{\topsep}{\oldspacing} +} +\begin{htmlonly} + \newcommand{\refs}[1] + { + \begin{description} + \item[REFERENCES:] + #1 + \end{description} + } +\end{htmlonly} + +\newcommand{\exampleitem}{\item [EXAMPLE]:} +\begin{htmlonly} + \renewcommand{\exampleitem}{\item [EXAMPLE:]} +\end{htmlonly} + +%------------------------------------------------------------------------------ +% ? End of document specific commands +% ----------------------------------------------------------------------------- +% Title Page. +% =========== +\renewcommand{\thepage}{\roman{page}} +\begin{document} +\thispagestyle{empty} + +% Latex document header. +% ====================== +\begin{latexonly} + CCLRC / {\sc Rutherford Appleton Laboratory} \hfill {\bf \stardocname}\\ + {\large Particle Physics \& Astronomy Research Council}\\ + {\large Starlink Project\\} + {\large \stardoccategory\ \stardocnumber} + \begin{flushright} + \stardocauthors\\ + \stardocdate + \end{flushright} + \vspace{-4mm} + \rule{\textwidth}{0.5mm} + \vspace{5mm} + \begin{center} + {\Huge\bf \stardoctitle \\ [2.5ex]} + {\LARGE\bf \stardocversion \\ [4ex]} + {\Huge\bf \stardocmanual} + \end{center} + \vspace{5mm} + +% ? Heading for abstract if used. + \vspace{10mm} + \begin{center} + {\Large\bf Abstract} + \end{center} +% ? End of heading for abstract. +\end{latexonly} + +% HTML documentation header. +% ========================== +\begin{htmlonly} + \xlabel{} + \begin{rawhtml}

\end{rawhtml} + \stardoctitle\\ + \stardocversion\\ + \stardocmanual + \begin{rawhtml}

\end{rawhtml} + +% ? Add picture here if required. +% ? End of picture + + \begin{rawhtml}

\end{rawhtml} + \stardoccategory \stardocnumber \\ + \stardocauthors \\ + \stardocdate + \begin{rawhtml}

\end{rawhtml} + \htmladdnormallink{CCLRC}{http://www.cclrc.ac.uk} / + \htmladdnormallink{Rutherford Appleton Laboratory} + {http://www.cclrc.ac.uk/ral} \\ + \htmladdnormallink{Particle Physics \& Astronomy Research Council} + {http://www.pparc.ac.uk} \\ + \begin{rawhtml}

\end{rawhtml} + \htmladdnormallink{Starlink Project}{http://star-www.rl.ac.uk/} + \begin{rawhtml}

\end{rawhtml} + \htmladdnormallink{\htmladdimg{source.gif} Retrieve hardcopy} + {http://star-www.rl.ac.uk/cgi-bin/hcserver?\stardocsource}\\ + +% HTML document table of contents. +% ================================ +% Add table of contents header and a navigation button to return to this +% point in the document (this should always go before the abstract \section). + \label{stardoccontents} + \begin{rawhtml} +
+

Contents

+ \end{rawhtml} + \renewcommand{\latexonlytoc}[0]{} + \htmladdtonavigation{\htmlref{\htmladdimg{contents_motif.gif}} + {stardoccontents}} + +% ? New section for abstract if used. + \section{\xlabel{abstract}Abstract} +% ? End of new section for abstract +\end{htmlonly} + +% ----------------------------------------------------------------------------- +% ? Document Abstract. (if used) +% ================== +SLALIB is a library used by writers of positional-astronomy applications. +Most of the \nroutines\ routines are concerned with astronomical position and time, +but a number have wider trigonometrical, numerical or general applications. +% ? End of document abstract +% ----------------------------------------------------------------------------- +% ? Latex document Table of Contents (if used). +% =========================================== + \newpage + \begin{latexonly} + \setlength{\parskip}{0mm} + \latexonlytoc + \setlength{\parskip}{\medskipamount} + \markright{\stardocname} + \end{latexonly} +% ? End of Latex document table of contents +% ----------------------------------------------------------------------------- +\newpage +\renewcommand{\thepage}{\arabic{page}} +\setcounter{page}{1} + +\section{INTRODUCTION} +\subsection{Purpose} +SLALIB\footnote{The name isn't an acronym; +it just stands for ``Subprogram Library~A''.} +is a library of routines +intended to make accurate and reliable positional-astronomy +applications easier to write. +Most SLALIB routines are concerned with astronomical position and time, but a +number have wider trigonometrical, numerical or general applications. +The applications ASTROM, COCO, RV and TPOINT +all make extensive use of the SLALIB +routines, as do a number of telescope control systems around the world. +The SLALIB versions currently in service are written in +Fortran~77 and run on VAX/VMS, several Unix platforms and PC. +A generic ANSI~C version is also available from the author; it is +functionally similar to the Fortran version upon which the present +document concentrates. + +\subsection{Example Application} +Here is a simple example of an application program written +using SLALIB calls: + +\begin{verbatim} + PROGRAM FK4FK5 + * + * Read a B1950 position from I/O unit 5 and reply on I/O unit 6 + * with the J2000 equivalent. Enter a period to quit. + * + IMPLICIT NONE + CHARACTER C*80,S + INTEGER I,J,IHMSF(4),IDMSF(4) + DOUBLE PRECISION R4,D4,R5,D5 + LOGICAL BAD + + * Loop until a period is entered + C = ' ' + DO WHILE (C(:1).NE.'.') + + * Read h m s d ' " + READ (5,'(A)') C + IF (C(:1).NE.'.') THEN + BAD = .TRUE. + + * Decode the RA + I = 1 + CALL sla_DAFIN(C,I,R4,J) + IF (J.EQ.0) THEN + R4 = 15D0*R4 + + * Decode the Dec + CALL sla_DAFIN(C,I,D4,J) + IF (J.EQ.0) THEN + + * FK4 to FK5 + CALL sla_FK45Z(R4,D4,1950D0,R5,D5) + + * Format and output the result + CALL sla_DR2TF(2,R5,S,IHMSF) + CALL sla_DR2AF(1,D5,S,IDMSF) + WRITE (6, + : '(1X,I2.2,2I3.2,''.'',I2.2,2X,A,I2.2,2I3.2,''.'',I1)') + : IHMSF,S,IDMSF + BAD = .FALSE. + END IF + END IF + IF (BAD) WRITE (6,'(1X,''?'')') + END IF + END DO + + END +\end{verbatim} +In this example, SLALIB not only provides the complicated FK4 to +FK5 transformation but also +simplifies the tedious and error-prone tasks +of decoding and formatting angles +expressed as hours, minutes {\it etc}. The +example incorporates range checking, and avoids the +notorious ``minus zero'' problem (an often-perpetrated bug where +declinations between $0^{\circ}$ and $-1^{\circ}$ lose their minus +sign). +With a little extra elaboration and a few more calls to SLALIB, +defaulting can be provided (enabling unused fields to +be replaced with commas to avoid retyping), proper motions +can be handled, different epochs can be specified, and +so on. See the program COCO (SUN/56) for further ideas. + +\subsection{Scope} +SLALIB contains \nroutines\ routines covering the following topics: +\begin{itemize} +\item String Decoding, + Sexagesimal Conversions +\item Angles, Vectors \& Rotation Matrices +\item Calendars, + Timescales +\item Precession \& Nutation +\item Proper Motion +\item FK4/FK5/Hipparcos, + Elliptic Aberration +\item Geocentric Coordinates +\item Apparent \& Observed Place +\item Azimuth \& Elevation +\item Refraction \& Air Mass +\item Ecliptic, + Galactic, + Supergalactic Coordinates +\item Ephemerides +\item Astrometry +\item Numerical Methods +\end{itemize} + +\subsection{Objectives} +SLALIB was designed to give application programmers +a basic set of positional-astronomy tools which were +accurate and easy to use. To this end, the library is: +\begin{itemize} +\item Readily available, including source code and documentation. +\item Supported and maintained. +\item Portable -- coded in standard languages and available for +multiple computers and operating systems. +\item Thoroughly commented, both for maintainability and to +assist those wishing to cannibalize the code. +\item Stable. +\item Trustworthy -- some care has gone into +testing SLALIB, both by comparison with published data and +by checks for internal consistency. +\item Rigorous -- corners are not cut, +even where the practical consequences would, as a rule, be +negligible. +\item Comprehensive, without including too many esoteric features +required only by specialists. +\item Practical -- almost all the routines have been written to +satisfy real needs encountered during the development of +real-life applications. +\item Environment-independent -- the package is +completely free of pauses, stops, I/O {\it etc}. +\item Self-contained -- SLALIB calls no other libraries. +\end{itemize} +A few {\it caveats}: +\begin{itemize} +\item SLALIB does not pretend to be canonical. It is in essence +an anthology, and the adopted algorithms are liable +to change as more up-to-date ones become available. +\item The functions aren't orthogonal -- there are several +cases of different +routines doing similar things, and many examples where +sequences of SLALIB calls have simply been packaged, all to +make applications less trouble to write. +\item There are omissions -- for example there are no +routines for calculating physical ephemerides of +Solar-System bodies. +\item SLALIB is not homogeneous, though important subsets +(for example the FK4/FK5 routines) are. +\item The library is not foolproof. You have to know what +you are trying to do ({\it e.g.}\ by reading textbooks on positional +astronomy), and it is the caller's responsibility to supply +sensible arguments (although enough internal validation is done to +avoid arithmetic errors). +\item Without being written in a wasteful +manner, SLALIB is nonetheless optimized for maintainability +rather than speed. In addition, there are many places +where considerable simplification would be possible if some +specified amount of accuracy could be sacrificed; such +compromises are left to the individual programmer and +are not allowed to limit SLALIB's value as a source +of comparison results. +\end{itemize} + +\subsection{Fortran Version} +The Fortran versions of SLALIB use ANSI Fortran~77 with a few +commonplace extensions. Just three out of the \nroutines\ routines require +platform-specific techniques and accordingly are supplied +in different forms. +SLALIB has been implemented on the following platforms: +VAX/VMS, +PC (Microsoft Fortran, Linux), +DECstation (Ultrix), +DEC Alpha (DEC Unix), +Sun (SunOS, Solaris), +Hewlett Packard (HP-UX), +CONVEX, +Perkin-Elmer and +Fujitsu. + +\subsection{C Version} +An ANSI C version of SLALIB is available from the author +but is not part of the Starlink release. +The functionality of this (proprietary) C version closely matches +that of the Starlink Fortran SLALIB, partly for the convenience of +existing users of the Fortran version, some of whom have in the past +implemented C ``wrappers''. The function names +cannot be the same as the Fortran versions because of potential +linking problems when +both forms of the library are present; the C routine which +is the equivalent of (for example) {\tt SLA\_REFRO} is {\tt slaRefro}. +The types of arguments follow the Fortran version, except +that integers are {\tt int} rather than {\tt long}. +Argument passing is by value +(except for arrays and strings of course) +for given arguments and by pointer for returned arguments. +All the C functions are re-entrant. + +The Fortran routines {\tt sla\_GRESID}, {\tt sla\_RANDOM} and +{\tt sla\_WAIT} have no C counterparts. + +Further details of the C version of SLALIB are available +from the author. The definitive guide to +the calling sequences is the file {\tt slalib.h}. + +\subsection{Future Versions} +The homogeneity and ease of use of SLALIB could perhaps be improved +in the future +by turning to C++ and object-oriented techniques. For example ``celestial +position'' could be a class and many of the transformations +could happen automatically. This requires further study and +would almost certainly result in a complete redesign. +Similarly, +the impact of Fortran~90 has yet to be assessed. Once compilers +become widely available, some internal recoding may be worthwhile +in order to simplify parts of the code. However, as with C++, +a redesign of the +application interfaces will be needed if the capabilities of the +new language are to be exploited to the full. + +\subsection{New Functions} +In a package like SLALIB it is difficult to know how far to go. Is it +enough to provide the primitive operations, or should more +complicated functions be packaged? Is it worth encroaching on +specialist areas, where individual experts have all written their +own software already? To what extent should CPU efficiency be +an issue? How much support of different numerical precisions is +required? And so on. + +In practice, almost all the routines in SLALIB are there because they were +needed for some specific application, and this is likely to remain the +pattern for any enhancements in the future. +Suggestions for additional SLALIB routines should be addressed to the +author. + +\subsection{Acknowledgements} +SLALIB is descended from a package of routines written +for the AAO 16-bit minicomputers +in the mid-1970s. The coming of the VAX +allowed a much more comprehensive and thorough package +to be designed for Starlink, especially important +at a time when the adoption +of the IAU 1976 resolutions meant that astronomers +would have to cope with a mixture of reference frames, +timescales and nomenclature. + +Much of the preparatory work on SLALIB was done by +Althea~Wilkinson of Manchester University. +During its development, +Andrew~Murray, +Catherine~Hohenkerk, +Andrew~Sinclair, +Bernard~Yallop +and +Brian~Emerson of Her Majesty's Nautical Almanac Office were consulted +on many occasions; their advice was indispensable. +I am especially grateful to +Catherine~Hohenkerk +for supplying preprints of papers, and test data. A number of +enhancements to SLALIB were at the suggestion of +Russell~Owen, University of Washington, +the late Phil~Hill, St~Andrews University, +Bill~Vacca, JILA, Boulder and +Ron~Maddalena, NRAO. +Mark~Calabretta, CSIRO Radiophysics, Sydney supplied changes to suit Convex. +I am indebted to Derek~Jones (RGO) for introducing me to the +``universal variables'' method of calculating orbits. + +The first C version of SLALIB was a hand-coded transcription +of the Starlink Fortran version carried out by +Steve~Eaton (University of Leeds) in the course of +MSc work. This was later +enhanced by John~Straede (AAO) and Martin~Shepherd (Caltech). +The current C SLALIB is a complete rewrite by the present author and +includes a comprehensive validation suite. +Additional comments on the C version came from Bob~Payne (NRAO) and +Jeremy~Bailey (AAO). + +\section{LINKING} + +On Unix systems (Sun, DEC Alpha {\it etc.}): +\begin{verse} +{\tt \%~~f77 progname.o -L/star/lib `sla\_link` -o progname} +\end{verse} +(The above assumes that all Starlink directories have been added to +the {\tt LD\_LIBRARY\_PATH} and {\tt PATH} environment variables +as described in SUN/202.) + +On VAX/VMS: +\begin{verse} +{\tt \$~~LINK progname,SLALIB\_DIR:SLALIB/LIB} +\end{verse} + +\pagebreak + +\section{SUBPROGRAM SPECIFICATIONS} +%----------------------------------------------------------------------- +\routine{SLA\_ADDET}{Add E-terms of Aberration} +{ + \action{Add the E-terms (elliptic component of annual aberration) to a + pre IAU 1976 mean place to conform to the old catalogue convention.} + \call{CALL sla\_ADDET (RM, DM, EQ, RC, DC)} +} +\args{GIVEN} +{ + \spec{RM,DM}{D}{\radec\ without E-terms (radians)} \\ + \spec{EQ}{D}{Besselian epoch of mean equator and equinox} +} +\args{RETURNED} +{ + \spec{RC,DC}{D}{\radec\ with E-terms included (radians)} +} +\anote{Most star positions from pre-1984 optical catalogues (or + obtained by astrometry with respect to such stars) have the + E-terms built-in. If it is necessary to convert a formal mean + place (for example a pulsar timing position) to one + consistent with such a star catalogue, then the + \radec\ should be adjusted using this routine.} +\aref{{\it Explanatory Supplement to the Astronomical Ephemeris}, + section 2D, page 48.} +%----------------------------------------------------------------------- +\routine{SLA\_AFIN}{Sexagesimal character string to angle} +{ + \action{Decode a free-format sexagesimal string (degrees, arcminutes, + arcseconds) into a single precision floating point + number (radians).} + \call{CALL sla\_AFIN (STRING, NSTRT, RESLT, JF)} +} +\args{GIVEN} +{ + \spec{STRING}{C*(*)}{string containing deg, arcmin, arcsec fields} \\ + \spec{NSTRT}{I}{pointer to start of decode (beginning of STRING = 1)} +} +\args{RETURNED} +{ + \spec{NSTRT}{I}{advanced past the decoded angle} \\ + \spec{RESLT}{R}{angle in radians} \\ + \spec{JF}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{0.7em} $+1$ = default, RESLT unchanged (note 2)} \\ + \spec{}{}{\hspace{0.7em} $-1$ = bad degrees (note 3)} \\ + \spec{}{}{\hspace{0.7em} $-2$ = bad arcminutes (note 3)} \\ + \spec{}{}{\hspace{0.7em} $-3$ = bad arcseconds (note 3)} \\ +} +\goodbreak +\setlength{\oldspacing}{\topsep} +\setlength{\topsep}{0.3ex} +\begin{description} + \exampleitem \\ [1.5ex] + \begin{tabular}{p{7em}p{15em}p{12em}} + {\it argument} & {\it before} & {\it after} \\ \\ + STRING & $'$\verb*}-57 17 44.806 12 34 56.7}$'$ & unchanged \\ + NSTRT & 1 & 16 ({\it i.e.}\ pointing to 12...) \\ + RESLT & - & $-1.00000$ \\ + JF & - & 0 + \end{tabular} + \item A further call to sla\_AFIN, without adjustment of NSTRT, will + decode the second angle, \dms{12}{34}{56}{7}. +\end{description} +\setlength{\topsep}{\oldspacing} +\notes +{ + \begin{enumerate} + \item The first three ``fields'' in STRING are degrees, arcminutes, + arcseconds, separated by spaces or commas. The degrees field + may be signed, but not the others. The decoding is carried + out by the sla\_DFLTIN routine and is free-format. + \item Successive fields may be absent, defaulting to zero. For + zero status, the only combinations allowed are degrees alone, + degrees and arcminutes, and all three fields present. If all + three fields are omitted, a status of +1 is returned and RESLT is + unchanged. In all other cases RESLT is changed. + \item Range checking: + \begin{itemize} + \item The degrees field is not range checked. However, it is + expected to be integral unless the other two fields are absent. + \item The arcminutes field is expected to be 0-59, and integral if + the arcseconds field is present. If the arcseconds field + is absent, the arcminutes is expected to be 0-59.9999... + \item The arcseconds field is expected to be 0-59.9999... + \item Decoding continues even when a check has failed. Under these + circumstances the field takes the supplied value, defaulting to + zero, and the result RESLT is computed and returned. + \end{itemize} + \item Further fields after the three expected ones are not treated as + an error. The pointer NSTRT is left in the correct state for + further decoding with the present routine or with sla\_DFLTIN + {\it etc}. See the example, above. + \item If STRING contains hours, minutes, seconds instead of + degrees {\it etc}, + or if the required units are turns (or days) instead of radians, + the result RESLT should be multiplied as follows: \\ [1.5ex] + \begin{tabular}{p{6em}p{5em}p{15em}} + {\it for STRING} & {\it to obtain} & {\it multiply RESLT by} \\ \\ + ${\circ}$~~\raisebox{-0.7ex}{$'$}~~\raisebox{-0.7ex}{$''$} + & radians & $1.0$ \\ + ${\circ}$~~\raisebox{-0.7ex}{$'$}~~\raisebox{-0.7ex}{$''$} + & turns & $1/{2 \pi} = 0.1591549430918953358$ \\ + h m s & radians & $15.0$ \\ + h m s & days & $15/{2\pi} = 2.3873241463784300365$ \\ + \end{tabular} + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_AIRMAS}{Air Mass} +{ + \action{Air mass at given zenith distance (double precision).} + \call{D~=~sla\_AIRMAS (ZD)} +} +\args{GIVEN} +{ + \spec{ZD}{D}{observed zenith distance (radians)} +} +\args{RETURNED} +{ + \spec{sla\_AIRMAS}{D}{air mass (1 at zenith)} +} +\notes +{ + \begin{enumerate} + \item The {\it observed}\/ zenith distance referred to above means + ``as affected by refraction''. + \item The routine uses Hardie's (1962) polynomial fit to Bemporad's + data for the relative air mass, $X$, in units of thickness at the + zenith as tabulated by Schoenberg (1929). This is adequate for all + normal needs as it is accurate to better than + 0.1\% up to $X = 6.8$ and better than 1\% up to $X = 10$. + Bemporad's tabulated values are unlikely to be trustworthy + to such accuracy + because of variations in density, pressure and other + conditions in the atmosphere from those assumed in his work. + \item The sign of the ZD is ignored. + \item At zenith distances greater than about $\zeta = 87^{\circ}$ the + air mass is held constant to avoid arithmetic overflows. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item Hardie, R.H., 1962, in {\it Astronomical Techniques}\, + ed. W.A.\ Hiltner, University of Chicago Press, p180. + \item Schoenberg, E., 1929, Hdb.\ d.\ Ap., + Berlin, Julius Springer, 2, 268. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_ALTAZ}{Velocities {\it etc.}\ for Altazimuth Mount} +{ + \action{Positions, velocities and accelerations for an altazimuth + telescope mount tracking a star (double precision).} + \call{CALL sla\_ALTAZ (\vtop{ + \hbox{HA, DEC, PHI,} + \hbox{AZ, AZD, AZDD, EL, ELD, ELDD, PA, PAD, PADD)}}} +} +\args{GIVEN} +{ + \spec{HA}{D}{hour angle} \\ + \spec{DEC}{D}{declination} \\ + \spec{PHI}{D}{observatory latitude} +} +\args{RETURNED} +{ + \spec{AZ}{D}{azimuth} \\ + \spec{AZD}{D}{azimuth velocity} \\ + \spec{AZDD}{D}{azimuth acceleration} \\ + \spec{EL}{D}{elevation} \\ + \spec{ELD}{D}{elevation velocity} \\ + \spec{ELDD}{D}{elevation acceleration} \\ + \spec{PA}{D}{parallactic angle} \\ + \spec{PAD}{D}{parallactic angle velocity} \\ + \spec{PADD}{D}{parallactic angle acceleration} +} +\notes +{ + \begin{enumerate} + \setlength{\parskip}{\medskipamount} + \item Natural units are used throughout. HA, DEC, PHI, AZ, EL + and ZD are in radians. The velocities and accelerations + assume constant declination and constant rate of change of + hour angle (as for tracking a star); the units of AZD, ELD + and PAD are radians per radian of HA, while the units of AZDD, + ELDD and PADD are radians per radian of HA squared. To + convert into practical degree- and second-based units: + + \begin{center} + \begin{tabular}{rlcl} + angles & $\times 360/2\pi$ & $\rightarrow$ & degrees \\ + velocities & $\times (2\pi/86400) \times (360/2\pi)$ + & $\rightarrow$ & degree/sec \\ + accelerations & $\times (2\pi/86400)^2 \times (360/2\pi)$ + & $\rightarrow$ & degree/sec/sec \\ + \end{tabular} + \end{center} + + Note that the seconds here are sidereal rather than SI. One + sidereal second is about 0.99727 SI seconds. + + The velocity and acceleration factors assume the sidereal + tracking case. Their respective numerical values are (exactly) + 1/240 and (approximately) 1/3300236.9. + \item Azimuth is returned in the range $[\,0,2\pi\,]$; north is zero, + and east is $+\pi/2$. Elevation and parallactic angle are + returned in the range $\pm\pi/2$. Position angle is +ve + for a star west of the meridian and is the angle NP--star--zenith. + \item The latitude is geodetic as opposed to geocentric. The + hour angle and declination are topocentric. Refraction and + deficiencies in the telescope mounting are ignored. The + purpose of the routine is to give the general form of the + quantities. The details of a real telescope could profoundly + change the results, especially close to the zenith. + \item No range checking of arguments is carried out. + \item In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude, and (for tracking a star) + sine and cosine of declination. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_AMP}{Apparent to Mean} +{ + \action{Convert star \radec\ from geocentric apparent to + mean place (post IAU 1976).} + \call{CALL sla\_AMP (RA, DA, DATE, EQ, RM, DM)} +} +\args{GIVEN} +{ + \spec{RA,DA}{D}{apparent \radec\ (radians)} \\ + \spec{DATE}{D}{TDB for apparent place (JD$-$2400000.5)} \\ + \spec{EQ}{D}{equinox: Julian epoch of mean place} +} +\args{RETURNED} +{ + \spec{RM,DM}{D}{mean \radec\ (radians)} +} +\notes +{ + \begin{enumerate} + \item The distinction between the required TDB and TT is + always negligible. Moreover, for all but the most + critical applications UTC is adequate. + \item The accuracy is limited by the routine sla\_EVP, called + by sla\_MAPPA, which computes the Earth position and + velocity using the methods of Stumpff. The maximum + error is about 0.3~milliarcsecond. + \item Iterative techniques are used for the aberration and + light deflection corrections so that the routines + sla\_AMP (or sla\_AMPQK) and sla\_MAP (or sla\_MAPQK) are + accurate inverses; even at the edge of the Sun's disc + the discrepancy is only about 1~nanoarcsecond. + \item Where multiple apparent places are to be converted to + mean places, for a fixed date and equinox, it is more + efficient to use the sla\_MAPPA routine to compute the + required parameters once, followed by one call to + sla\_AMPQK per star. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item 1984 {\it Astronomical Almanac}, pp B39-B41. + \item Lederle \& Schwan, 1984.\ {\it Astr.Astrophys.}\ {\bf 134}, 1-6. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_AMPQK}{Quick Apparent to Mean} +{ + \action{Convert star \radec\ from geocentric apparent to mean place + (post IAU 1976). Use of this routine is appropriate when + efficiency is important and where many star positions are + all to be transformed for one epoch and equinox. The + star-independent parameters can be obtained by calling + the sla\_MAPPA routine.} + \call{CALL sla\_AMPQK (RA, DA, AMPRMS, RM, DM)} +} +\args{GIVEN} +{ + \spec{RA,DA}{D}{apparent \radec\ (radians)} \\ + \spec{AMPRMS}{D(21)}{star-independent mean-to-apparent parameters:} \\ + \specel {(1)} {time interval for proper motion (Julian years)} \\ + \specel {(2-4)} {barycentric position of the Earth (AU)} \\ + \specel {(5-7)} {heliocentric direction of the Earth (unit vector)} \\ + \specel {(8)} {(gravitational radius of + Sun)$\times 2 / $(Sun-Earth distance)} \\ + \specel {(9-11)} {{\bf v}: barycentric Earth velocity in units of c} \\ + \specel {(12)} {$\sqrt{1-\left|\mbox{\bf v}\right|^2}$} \\ + \specel {(13-21)} {precession/nutation $3\times3$ matrix} +} +\args{RETURNED} +{ + \spec{RM,DM}{D}{mean \radec\ (radians)} +} +\notes +{ + \begin{enumerate} + \item The accuracy is limited by the routine sla\_EVP, called + by sla\_MAPPA, which computes the Earth position and + velocity using the methods of Stumpff. The maximum + error is about 0.3~milliarcsecond. + \item Iterative techniques are used for the aberration and + light deflection corrections so that the routines + sla\_AMP (or sla\_AMPQK) and sla\_MAP (or sla\_MAPQK) are + accurate inverses; even at the edge of the Sun's disc + the discrepancy is only about 1~nanoarcsecond. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item 1984 {\it Astronomical Almanac}, pp B39-B41. + \item Lederle \& Schwan, 1984.\ {\it Astr.Astrophys.}\ {\bf 134}, 1-6. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_AOP}{Apparent to Observed} +{ + \action{Apparent to observed place, for optical sources distant from + the solar system.} + \call{CALL sla\_AOP (\vtop{ + \hbox{RAP, DAP, DATE, DUT, ELONGM, PHIM, HM, XP, YP,} + \hbox{TDK, PMB, RH, WL, TLR, AOB, ZOB, HOB, DOB, ROB)}}} +} +\args{GIVEN} +{ + \spec{RAP,DAP}{D}{geocentric apparent \radec\ (radians)} \\ + \spec{DATE}{D}{UTC date/time (Modified Julian Date, JD$-$2400000.5)} \\ + \spec{DUT}{D}{$\Delta$UT: UT1$-$UTC (UTC seconds)} \\ + \spec{ELONGM}{D}{observer's mean longitude (radians, east +ve)} \\ + \spec{PHIM}{D}{observer's mean geodetic latitude (radians)} \\ + \spec{HM}{D}{observer's height above sea level (metres)} \\ + \spec{XP,YP}{D}{polar motion \xy\ coordinates (radians)} \\ + \spec{TDK}{D}{local ambient temperature (degrees K; std=273.155D0)} \\ + \spec{PMB}{D}{local atmospheric pressure (mB; std=1013.25D0)} \\ + \spec{RH}{D}{local relative humidity (in the range 0D0\,--\,1D0)} \\ + \spec{WL}{D}{effective wavelength ($\mu{\rm m}$, {\it e.g.}\ 0.55D0)} \\ + \spec{TLR}{D}{tropospheric lapse rate (degrees K per metre, + {\it e.g.}\ 0.0065D0)} +} +\args{RETURNED} +{ + \spec{AOB}{D}{observed azimuth (radians: N=0, E=$90^{\circ}$)} \\ + \spec{ZOB}{D}{observed zenith distance (radians)} \\ + \spec{HOB}{D}{observed Hour Angle (radians)} \\ + \spec{DOB}{D}{observed $\delta$ (radians)} \\ + \spec{ROB}{D}{observed $\alpha$ (radians)} +} +\notes +{ + \begin{enumerate} + \item This routine returns zenith distance rather than elevation + in order to reflect the fact that no allowance is made for + depression of the horizon. + \item The accuracy of the result is limited by the corrections for + refraction. Providing the meteorological parameters are + known accurately and there are no gross local effects, the + predicted azimuth and elevation should be within about + \arcsec{0}{1} for $\zeta<70^{\circ}$. Even + at a topocentric zenith distance of + $90^{\circ}$, the accuracy in elevation should be better than + 1~arcminute; useful results are available for a further + $3^{\circ}$, beyond which the sla\_REFRO routine returns a + fixed value of the refraction. The complementary + routines sla\_AOP (or sla\_AOPQK) and sla\_OAP (or sla\_OAPQK) + are self-consistent to better than 1~microarcsecond all over + the celestial sphere. + \item It is advisable to take great care with units, as even + unlikely values of the input parameters are accepted and + processed in accordance with the models used. + \item {\it Apparent}\/ \radec\ means the geocentric apparent right ascension + and declination, which is obtained from a catalogue mean place + by allowing for space motion, parallax, precession, nutation, + annual aberration, and the Sun's gravitational lens effect. For + star positions in the FK5 system ({\it i.e.}\ J2000), these effects can + be applied by means of the sla\_MAP {\it etc.}\ routines. Starting from + other mean place systems, additional transformations will be + needed; for example, FK4 ({\it i.e.}\ B1950) mean places would first + have to be converted to FK5, which can be done with the + sla\_FK425 {\it etc.}\ routines. + \item {\it Observed}\/ \azel\ means the position that would be seen by a + perfect theodolite located at the observer. This is obtained + from the geocentric apparent \radec\ by allowing for Earth + orientation and diurnal aberration, rotating from equator + to horizon coordinates, and then adjusting for refraction. + The \hadec\ is obtained by rotating back into equatorial + coordinates, using the geodetic latitude corrected for polar + motion, and is the position that would be seen by a perfect + equatorial located at the observer and with its polar axis + aligned to the Earth's axis of rotation ({\it n.b.}\ not to the + refracted pole). Finally, the $\alpha$ is obtained by subtracting + the {\it h}\/ from the local apparent ST. + \item To predict the required setting of a real telescope, the + observed place produced by this routine would have to be + adjusted for the tilt of the azimuth or polar axis of the + mounting (with appropriate corrections for mount flexures), + for non-perpendicularity between the mounting axes, for the + position of the rotator axis and the pointing axis relative + to it, for tube flexure, for gear and encoder errors, and + finally for encoder zero points. Some telescopes would, of + course, exhibit other properties which would need to be + accounted for at the appropriate point in the sequence. + \item This routine takes time to execute, due mainly to the + rigorous integration used to evaluate the refraction. + For processing multiple stars for one location and time, + call sla\_AOPPA once followed by one call per star to sla\_AOPQK. + Where a range of times within a limited period of a few hours + is involved, and the highest precision is not required, call + sla\_AOPPA once, followed by a call to sla\_AOPPAT each time the + time changes, followed by one call per star to sla\_AOPQK. + \item The DATE argument is UTC expressed as an MJD. This is, + strictly speaking, wrong, because of leap seconds. However, + as long as the $\Delta$UT and the UTC are consistent there + are no difficulties, except during a leap second. In this + case, the start of the 61st second of the final minute should + begin a new MJD day and the old pre-leap $\Delta$UT should + continue to be used. As the 61st second completes, the MJD + should revert to the start of the day as, simultaneously, + the $\Delta$UT changes by one second to its post-leap new value. + \item The $\Delta$UT (UT1$-$UTC) is tabulated in IERS circulars and + elsewhere. It increases by exactly one second at the end of + each UTC leap second, introduced in order to keep $\Delta$UT + within $\pm$\tsec{0}{9}. + \item IMPORTANT -- TAKE CARE WITH THE LONGITUDE SIGN CONVENTION. The + longitude required by the present routine is {\bf east-positive}, + in accordance with geographical convention (and right-handed). + In particular, note that the longitudes returned by the + sla\_OBS routine are west-positive (as in the {\it Astronomical + Almanac}\/ before 1984) and must be reversed in sign before use + in the present routine. + \item The polar coordinates XP,YP can be obtained from IERS + circulars and equivalent publications. The + maximum amplitude is about \arcsec{0}{3}. If XP,YP values + are unavailable, use XP=YP=0D0. See page B60 of the 1988 + {\it Astronomical Almanac}\/ for a definition of the two angles. + \item The height above sea level of the observing station, HM, + can be obtained from the {\it Astronomical Almanac}\/ (Section J + in the 1988 edition), or via the routine sla\_OBS. If P, + the pressure in mB, is available, an adequate + estimate of HM can be obtained from the following expression: + \begin{quote} + {\tt HM=-29.3D0*TSL*LOG(P/1013.25D0)} + \end{quote} + where TSL is the approximate sea-level air temperature in degrees K + (see {\it Astrophysical Quantities}, C.W.Allen, 3rd~edition, + \S 52). Similarly, if the pressure P is not known, + it can be estimated from the height of the observing + station, HM as follows: + \begin{quote} + {\tt P=1013.25D0*EXP(-HM/(29.3D0*TSL))} + \end{quote} + Note, however, that the refraction is proportional to the + pressure and that an accurate P value is important for + precise work. + \item The azimuths {\it etc.}\ used by the present routine are with + respect to the celestial pole. Corrections to the terrestrial pole + can be computed using sla\_POLMO. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_AOPPA}{Appt-to-Obs Parameters} +{ + \action{Pre-compute the set of apparent to observed place parameters + required by the ``quick'' routines sla\_AOPQK and sla\_OAPQK.} + \call{CALL sla\_AOPPA (\vtop{ + \hbox{DATE, DUT, ELONGM, PHIM, HM, XP, YP,} + \hbox{TDK, PMB, RH, WL, TLR, AOPRMS)}}} +} +\args{GIVEN} +{ + \spec{DATE}{D}{UTC date/time (Modified Julian Date, JD$-$2400000.5)} \\ + \spec{DUT}{D}{$\Delta$UT: UT1$-$UTC (UTC seconds)} \\ + \spec{ELONGM}{D}{observer's mean longitude (radians, east +ve)} \\ + \spec{PHIM}{D}{observer's mean geodetic latitude (radians)} \\ + \spec{HM}{D}{observer's height above sea level (metres)} \\ + \spec{XP,YP}{D}{polar motion \xy\ coordinates (radians)} \\ + \spec{TDK}{D}{local ambient temperature (degrees K; std=273.155D0)} \\ + \spec{PMB}{D}{local atmospheric pressure (mB; std=1013.25D0)} \\ + \spec{RH}{D}{local relative humidity (in the range 0D0\,--\,1D0)} \\ + \spec{WL}{D}{effective wavelength ($\mu{\rm m}$, {\it e.g.}\ 0.55D0)} \\ + \spec{TLR}{D}{tropospheric lapse rate (degrees K per metre, + {\it e.g.}\ 0.0065D0)} +} +\args{RETURNED} +{ + \spec{AOPRMS}{D(14)}{star-independent apparent-to-observed parameters:} \\ + \specel {(1)} {geodetic latitude (radians)} \\ + \specel {(2,3)} {sine and cosine of geodetic latitude} \\ + \specel {(4)} {magnitude of diurnal aberration vector} \\ + \specel {(5)} {height (HM)} \\ + \specel {(6)} {ambient temperature (TDK)} \\ + \specel {(7)} {pressure (PMB)} \\ + \specel {(8)} {relative humidity (RH)} \\ + \specel {(9)} {wavelength (WL)} \\ + \specel {(10)} {lapse rate (TLR)} \\ + \specel {(11,12)} {refraction constants A and B (radians)} \\ + \specel {(13)} {longitude + eqn of equinoxes + + ``sidereal $\Delta$UT'' (radians)} \\ + \specel {(14)} {local apparent sidereal time (radians)} +} +\notes +{ + \begin{enumerate} + \item It is advisable to take great care with units, as even + unlikely values of the input parameters are accepted and + processed in accordance with the models used. + \item The DATE argument is UTC expressed as an MJD. This is, + strictly speaking, wrong, because of leap seconds. However, + as long as the $\Delta$UT and the UTC are consistent there + are no difficulties, except during a leap second. In this + case, the start of the 61st second of the final minute should + begin a new MJD day and the old pre-leap $\Delta$UT should + continue to be used. As the 61st second completes, the MJD + should revert to the start of the day as, simultaneously, + the $\Delta$UT changes by one second to its post-leap new value. + \item The $\Delta$UT (UT1$-$UTC) is tabulated in IERS circulars and + elsewhere. It increases by exactly one second at the end of + each UTC leap second, introduced in order to keep $\Delta$UT + within $\pm$\tsec{0}{9}. The ``sidereal $\Delta$UT'' which forms + part of AOPRMS(13) is the same quantity, but converted from solar + to sidereal seconds and expressed in radians. + \item IMPORTANT -- TAKE CARE WITH THE LONGITUDE SIGN CONVENTION. The + longitude required by the present routine is {\bf east-positive}, + in accordance with geographical convention (and right-handed). + In particular, note that the longitudes returned by the + sla\_OBS routine are west-positive (as in the {\it Astronomical + Almanac}\/ before 1984) and must be reversed in sign before use in + the present routine. + \item The polar coordinates XP,YP can be obtained from IERS + circulars and equivalent publications. The + maximum amplitude is about \arcsec{0}{3}. If XP,YP values + are unavailable, use XP=YP=0D0. See page B60 of the 1988 + {\it Astronomical Almanac}\/ for a definition of the two angles. + \item The height above sea level of the observing station, HM, + can be obtained from the {\it Astronomical Almanac}\/ (Section J + in the 1988 edition), or via the routine sla\_OBS. If P, + the pressure in mB, is available, an adequate + estimate of HM can be obtained from the following expression: + \begin{quote} + {\tt HM=-29.3D0*TSL*LOG(P/1013.25D0)} + \end{quote} + where TSL is the approximate sea-level air temperature in degrees K + (see {\it Astrophysical Quantities}, C.W.Allen, 3rd~edition, + \S 52). Similarly, if the pressure P is not known, + it can be estimated from the height of the observing + station, HM as follows: + \begin{quote} + {\tt P=1013.25D0*EXP(-HM/(29.3D0*TSL))} + \end{quote} + Note, however, that the refraction is proportional to the + pressure and that an accurate P value is important for + precise work. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_AOPPAT}{Update Appt-to-Obs Parameters} +{ + \action{Recompute the sidereal time in the apparent to observed place + star-independent parameter block.} + \call{CALL sla\_AOPPAT (DATE, AOPRMS)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{UTC date/time (Modified Julian Date, JD$-$2400000.5)} \\ + \spec{AOPRMS}{D(14)}{star-independent apparent-to-observed parameters:} \\ + \specel{(1-12)}{not required} \\ + \specel{(13)}{longitude + eqn of equinoxes + + ``sidereal $\Delta$UT'' (radians)} \\ + \specel{(14)}{not required} +} +\args{RETURNED} +{ + \spec{AOPRMS}{D(14)}{star-independent apparent-to-observed parameters:} \\ + \specel{(1-13)}{not changed} \\ + \specel{(14)}{local apparent sidereal time (radians)} +} +\anote{For more information, see sla\_AOPPA.} +%----------------------------------------------------------------------- +\routine{SLA\_AOPQK}{Quick Appt-to-Observed} +{ + \action{Quick apparent to observed place (but see Note~8, below).} + \call{CALL sla\_AOPQK (RAP, DAP, AOPRMS, AOB, ZOB, HOB, DOB, ROB)} +} +\args{GIVEN} +{ + \spec{RAP,DAP}{D}{geocentric apparent \radec\ (radians)} \\ + \spec{AOPRMS}{D(14)}{star-independent apparent-to-observed parameters:} \\ + \specel{(1)}{geodetic latitude (radians)} \\ + \specel{(2,3)}{sine and cosine of geodetic latitude} \\ + \specel{(4)}{magnitude of diurnal aberration vector} \\ + \specel{(5)}{height (metres)} \\ + \specel{(6)}{ambient temperature (degrees K)} \\ + \specel{(7)}{pressure (mB)} \\ + \specel{(8)}{relative humidity (0\,--\,1)} \\ + \specel{(9)}{wavelength ($\mu{\rm m}$)} \\ + \specel{(10)}{lapse rate (degrees K per metre)} \\ + \specel{(11,12)}{refraction constants A and B (radians)} \\ + \specel{(13)}{longitude + eqn of equinoxes + + ``sidereal $\Delta$UT'' (radians)} \\ + \specel{(14)}{local apparent sidereal time (radians)} +} +\args{RETURNED} +{ + \spec{AOB}{D}{observed azimuth (radians: N=0, E=$90^{\circ}$)} \\ + \spec{ZOB}{D}{observed zenith distance (radians)} \\ + \spec{HOB}{D}{observed Hour Angle (radians)} \\ + \spec{DOB}{D}{observed Declination (radians)} \\ + \spec{ROB}{D}{observed Right Ascension (radians)} +} +\notes +{ + \begin{enumerate} + \item This routine returns zenith distance rather than elevation + in order to reflect the fact that no allowance is made for + depression of the horizon. + \item The accuracy of the result is limited by the corrections for + refraction. Providing the meteorological parameters are + known accurately and there are no gross local effects, the + predicted azimuth and elevation should be within about + \arcsec{0}{1} for $\zeta<70^{\circ}$. Even + at a topocentric zenith distance of + $90^{\circ}$, the accuracy in elevation should be better than + 1~arcminute; useful results are available for a further + $3^{\circ}$, beyond which the sla\_REFRO routine returns a + fixed value of the refraction. The complementary + routines sla\_AOP (or sla\_AOPQK) and sla\_OAP (or sla\_OAPQK) + are self-consistent to better than 1~microarcsecond all over + the celestial sphere. + \item It is advisable to take great care with units, as even + unlikely values of the input parameters are accepted and + processed in accordance with the models used. + \item {\it Apparent}\/ \radec\ means the geocentric apparent right ascension + and declination, which is obtained from a catalogue mean place + by allowing for space motion, parallax, precession, nutation, + annual aberration, and the Sun's gravitational lens effect. For + star positions in the FK5 system ({\it i.e.}\ J2000), these effects can + be applied by means of the sla\_MAP {\it etc.}\ routines. Starting from + other mean place systems, additional transformations will be + needed; for example, FK4 ({\it i.e.}\ B1950) mean places would first + have to be converted to FK5, which can be done with the + sla\_FK425 {\it etc.}\ routines. + \item {\it Observed}\/ \azel\ means the position that would be seen by a + perfect theodolite located at the observer. This is obtained + from the geocentric apparent \radec\ by allowing for Earth + orientation and diurnal aberration, rotating from equator + to horizon coordinates, and then adjusting for refraction. + The \hadec\ is obtained by rotating back into equatorial + coordinates, using the geodetic latitude corrected for polar + motion, and is the position that would be seen by a perfect + equatorial located at the observer and with its polar axis + aligned to the Earth's axis of rotation ({\it n.b.}\ not to the + refracted pole). Finally, the $\alpha$ is obtained by subtracting + the {\it h}\/ from the local apparent ST. + \item To predict the required setting of a real telescope, the + observed place produced by this routine would have to be + adjusted for the tilt of the azimuth or polar axis of the + mounting (with appropriate corrections for mount flexures), + for non-perpendicularity between the mounting axes, for the + position of the rotator axis and the pointing axis relative + to it, for tube flexure, for gear and encoder errors, and + finally for encoder zero points. Some telescopes would, of + course, exhibit other properties which would need to be + accounted for at the appropriate point in the sequence. + \item The star-independent apparent-to-observed-place parameters + in AOPRMS may be computed by means of the sla\_AOPPA routine. + If nothing has changed significantly except the time, the + sla\_AOPPAT routine may be used to perform the requisite + partial recomputation of AOPRMS. + \item The ``sidereal $\Delta$UT'' which forms part of AOPRMS(13) + is UT1$-$UTC converted from solar to + sidereal seconds and expressed in radians. + \item At zenith distances beyond about $76^\circ$, the need for + special care with the corrections for refraction causes a + marked increase in execution time. Moreover, the effect + gets worse with increasing zenith distance. Adroit + programming in the calling application may allow the + problem to be reduced. Prepare an alternative AOPRMS array, + computed for zero air-pressure; this will disable the + refraction corrections and cause rapid execution. Using + this AOPRMS array, a preliminary call to the present routine + will, depending on the application, produce a rough position + which may be enough to establish whether the full, slow + calculation (using the real AOPRMS array) is worthwhile. + For example, there would be no need for the full calculation + if the preliminary call had already established that the + source was well below the elevation limits for a particular + telescope. + \item The azimuths {\it etc.}\ used by the present routine are with + respect to the celestial pole. Corrections to the terrestrial pole + can be computed using sla\_POLMO. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_ATMDSP}{Atmospheric Dispersion} +{ + \action{Apply atmospheric-dispersion adjustments to refraction coefficients.} + \call{CALL sla\_ATMDSP (TDK, PMB, RH, WL1, A1, B1, WL2, A2, B2)} +} +\args{GIVEN} +{ + \spec{TDK}{D}{ambient temperature at the observer (degrees K)} \\ + \spec{PMB}{D}{pressure at the observer (mB)} \\ + \spec{RH}{D}{relative humidity at the observer (range 0\,--\,1)} \\ + \spec{WL1}{D}{base wavelength ($\mu{\rm m}$)} \\ + \spec{A1}{D}{refraction coefficient A for wavelength WL1 (radians)} \\ + \spec{B1}{D}{refraction coefficient B for wavelength WL1 (radians)} \\ + \spec{WL2}{D}{wavelength for which adjusted A,B required ($\mu{\rm m}$)} +} +\args{RETURNED} +{ + \spec{A2}{D}{refraction coefficient A for wavelength WL2 (radians)} \\ + \spec{B2}{D}{refraction coefficient B for wavelength WL2 (radians)} +} +\notes +{ + \begin{enumerate} + \item To use this routine, first call sla\_REFCO specifying WL1 as the + wavelength. This yields refraction coefficients A1, B1, correct + for that wavelength. Subsequently, calls to sla\_ATMDSP specifying + different wavelengths will produce new, slightly adjusted + refraction coefficients A2, B2, which apply to the specified wavelength. + \item Most of the atmospheric dispersion happens between $0.7\,\mu{\rm m}$ + and the UV atmospheric cutoff, and the effect increases strongly + towards the UV end. For this reason a blue reference wavelength + is recommended, for example $0.4\,\mu{\rm m}$. + \item The accuracy, for this set of conditions: \\[1pc] + \hspace*{5ex} \begin{tabular}{rcl} + height above sea level & ~ & 2000\,m \\ + latitude & ~ & $29^\circ$ \\ + pressure & ~ & 793\,mB \\ + temperature & ~ & $290^\circ$\,K \\ + humidity & ~ & 0.5 (50\%) \\ + lapse rate & ~ & $0.0065^\circ m^{-1}$ \\ + reference wavelength & ~ & $0.4\,\mu{\rm m}$ \\ + star elevation & ~ & $15^\circ$ \\ + \end{tabular}\\[1pc] + is about 2.5\,mas RMS between 0.3 and $1.0\,\mu{\rm m}$, and stays + within 4\,mas for the whole range longward of $0.3\,\mu{\rm m}$ + (compared with a total dispersion from 0.3 to $20\,\mu{\rm m}$ + of about \arcseci{11}). These errors are typical for ordinary + conditions; in extreme conditions values a few times this size + may occur. + \item If either wavelength exceeds $100\,\mu{\rm m}$, the radio case + is assumed and the returned refraction coefficients are the + same as the given ones. + \item The algorithm consists of calculation of the refractivity of the + air at the observer for the two wavelengths, using the methods + of the sla\_REFRO routine, and then scaling of the two refraction + coefficients according to classical refraction theory. This + amounts to scaling the A coefficient in proportion to $(\mu-1)$ and + the B coefficient almost in the same ratio (see R.M.Green, + {\it Spherical Astronomy,}\/ Cambridge University Press, 1985). + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_AV2M}{Rotation Matrix from Axial Vector} +{ + \action{Form the rotation matrix corresponding to a given axial vector + (single precision).} + \call{CALL sla\_AV2M (AXVEC, RMAT)} +} +\args{GIVEN} +{ + \spec{AXVEC}{R(3)}{axial vector (radians)} +} +\args{RETURNED} +{ + \spec{RMAT}{R(3,3)}{rotation matrix} +} +\notes +{ + \begin{enumerate} + \item A rotation matrix describes a rotation about some arbitrary axis. + The axis is called the {\it Euler axis}, and the angle through which the + reference frame rotates is called the Euler angle. The axial + vector supplied to this routine has the same direction as the + Euler axis, and its magnitude is the Euler angle in radians. + \item If AXVEC is null, the unit matrix is returned. + \item The reference frame rotates clockwise as seen looking along + the axial vector from the origin. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_BEAR}{Direction Between Points on a Sphere} +{ + \action{Returns the bearing (position angle) of one point on a + sphere seen from another (single precision).} + \call{R~=~sla\_BEAR (A1, B1, A2, B2)} +} +\args{GIVEN} +{ + \spec{A1,B1}{R}{spherical coordinates of one point} \\ + \spec{A2,B2}{R}{spherical coordinates of the other point} +} +\args{RETURNED} +{ + \spec{sla\_BEAR}{R}{bearing from first point to second} +} +\notes +{ + \begin{enumerate} + \item The spherical coordinates are \radec, + $[\lambda,\phi]$ {\it etc.}, in radians. + \item The result is the bearing (position angle), in radians, + of point [A2,B2] as seen + from point [A1,B1]. It is in the range $\pm \pi$. The sense + is such that if [A2,B2] + is a small distance due east of [A1,B1] the result + is about $+\pi/2$. Zero is returned + if the two points are coincident. + \item If either B-coordinate is outside the range $\pm\pi/2$, the + result may correspond to ``the long way round''. + \item The routine sla\_PAV performs an equivalent function except + that the points are specified in the form of Cartesian unit + vectors. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CAF2R}{Deg,Arcmin,Arcsec to Radians} +{ + \action{Convert degrees, arcminutes, arcseconds to radians + (single precision).} + \call{CALL sla\_CAF2R (IDEG, IAMIN, ASEC, RAD, J)} +} +\args{GIVEN} +{ + \spec{IDEG}{I}{degrees} \\ + \spec{IAMIN}{I}{arcminutes} \\ + \spec{ASEC}{R}{arcseconds} +} +\args{RETURNED} +{ + \spec{RAD}{R}{angle in radians} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 1 = IDEG outside range 0$-$359} \\ + \spec{}{}{\hspace{1.5em} 2 = IAMIN outside range 0$-$59} \\ + \spec{}{}{\hspace{1.5em} 3 = ASEC outside range 0$-$59.999$\cdots$} +} +\notes +{ + \begin{enumerate} + \item The result is computed even if any of the range checks fail. + \item The sign must be dealt with outside this routine. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CALDJ}{Calendar Date to MJD} +{ + \action{Gregorian Calendar to Modified Julian Date, with century default.} + \call{CALL sla\_CALDJ (IY, IM, ID, DJM, J)} +} +\args{GIVEN} +{ + \spec{IY,IM,ID}{I}{year, month, day in Gregorian calendar} +} +\args{RETURNED} +{ + \spec{DJM}{D}{modified Julian Date (JD$-$2400000.5) for $0^{\rm h}$} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} 1 = bad year (MJD not computed)} \\ + \spec{}{}{\hspace{1.5em} 2 = bad month (MJD not computed)} \\ + \spec{}{}{\hspace{1.5em} 3 = bad day (MJD computed)} \\ +} +\notes +{ + \begin{enumerate} + \item This routine supports the {\it century default}\/ feature. + Acceptable years are: + \begin{itemize} + \item 00-49, interpreted as 2000\,--\,2049, + \item 50-99, interpreted as 1950\,--\,1999, and + \item 100 upwards, interpreted literally. + \end{itemize} + For 1-100AD use the routine sla\_CLDJ instead. + \item For year $n$BC use IY = $-(n-1)$. + \item When an invalid year or month is supplied (status J~=~1~or~2) + the MJD is {\bf not} computed. When an invalid day is supplied + (status J~=~3) the MJD {\bf is} computed. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CALYD}{Calendar to Year, Day} +{ + \action{Gregorian calendar date to year and day in year, in a Julian + calendar aligned to the 20th/21st century Gregorian calendar, + with century default.} + \call{CALL sla\_CALYD (IY, IM, ID, NY, ND, J)} +} +\args{GIVEN} +{ + \spec{IY,IM,ID}{I}{year, month, day in Gregorian calendar: + year may optionally omit the century} +} +\args{RETURNED} +{ + \spec{NY}{I}{year (re-aligned Julian calendar)} \\ + \spec{ND}{I}{day in year (1 = January 1st)} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} 1 = bad year (before $-4711$)} \\ + \spec{}{}{\hspace{1.5em} 2 = bad month} \\ + \spec{}{}{\hspace{1.5em} 3 = bad day} +} +\notes +{ + \begin{enumerate} + \item This routine supports the {\it century default}\/ feature. + Acceptable years are: + \begin{itemize} + \item 00-49, interpreted as 2000\,--\,2049, + \item 50-99, interpreted as 1950\,--\,1999, and + \item other years after -4712 , interpreted literally. + \end{itemize} + Use sla\_CLYD for years before 100AD. + \item The purpose of sla\_CALDJ is to support + sla\_EARTH, sla\_MOON and sla\_ECOR. + \item Between 1900~March~1 and 2100~February~28 it returns answers + which are consistent with the ordinary Gregorian calendar. + Outside this range there will be a discrepancy which increases + by one day for every non-leap century year. + \item When an invalid year or month is supplied (status J~=~1 or J~=~2) + the results are {\bf not} computed. When a day is + supplied which is outside the conventional range (status J~=~3) + the results {\bf are} computed. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CC2S}{Cartesian to Spherical} +{ + \action{Cartesian coordinates to spherical coordinates (single precision).} + \call{CALL sla\_CC2S (V, A, B)} +} +\args{GIVEN} +{ + \spec{V}{R(3)}{\xyz\ vector} +} +\args{RETURNED} +{ + \spec{A,B}{R}{spherical coordinates in radians} +} +\notes +{ + \begin{enumerate} + \item The spherical coordinates are longitude (+ve anticlockwise + looking from the +ve latitude pole) and latitude. The + Cartesian coordinates are right handed, with the {\it x}-axis + at zero longitude and latitude, and the {\it z}-axis at the + +ve latitude pole. + \item If V is null, zero A and B are returned. + \item At either pole, zero A is returned. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CC62S}{Cartesian 6-Vector to Spherical} +{ + \action{Conversion of position \& velocity in Cartesian coordinates + to spherical coordinates (single precision).} + \call{CALL sla\_CC62S (V, A, B, R, AD, BD, RD)} +} +\args{GIVEN} +{ + \spec{V}{R(6)}{\xyzxyzd} +} +\args{RETURNED} +{ + \spec{A}{R}{longitude (radians) -- for example $\alpha$} \\ + \spec{B}{R}{latitude (radians) -- for example $\delta$} \\ + \spec{R}{R}{radial coordinate} \\ + \spec{AD}{R}{longitude derivative (radians per unit time)} \\ + \spec{BD}{R}{latitude derivative (radians per unit time)} \\ + \spec{RD}{R}{radial derivative} +} +%----------------------------------------------------------------------- +\routine{SLA\_CD2TF}{Days to Hour,Min,Sec} +{ + \action{Convert an interval in days to hours, minutes, seconds + (single precision).} + \call{CALL sla\_CD2TF (NDP, DAYS, SIGN, IHMSF)} +} +\args{GIVEN} +{ + \spec{NDP}{I}{number of decimal places of seconds} \\ + \spec{DAYS}{R}{interval in days} +} +\args{RETURNED} +{ + \spec{SIGN}{C}{`+' or `$-$'} \\ + \spec{IHMSF}{I(4)}{hours, minutes, seconds, fraction} +} +\notes +{ + \begin{enumerate} + \item NDP less than zero is interpreted as zero. + \item The largest useful value for NDP is determined by the size of + DAYS, the format of REAL floating-point numbers on the target + machine, and the risk of overflowing IHMSF(4). For example, + on a VAX computer, for DAYS up to 1.0, the available floating-point + precision corresponds roughly to NDP=3. This is well below + the ultimate limit of NDP=9 set by the capacity of the 32-bit + integer IHMSF(4). + \item The absolute value of DAYS may exceed 1.0. In cases where it + does not, it is up to the caller to test for and handle the + case where DAYS is very nearly 1.0 and rounds up to 24~hours, + by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +\end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CLDJ}{Calendar to MJD} +{ + \action{Gregorian Calendar to Modified Julian Date.} + \call{CALL sla\_CLDJ (IY, IM, ID, DJM, J)} +} +\args{GIVEN} +{ + \spec{IY,IM,ID}{I}{year, month, day in Gregorian calendar} +} +\args{RETURNED} +{ + \spec{DJM}{D}{modified Julian Date (JD$-$2400000.5) for $0^{\rm h}$} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} 1 = bad year} \\ + \spec{}{}{\hspace{1.5em} 2 = bad month} \\ + \spec{}{}{\hspace{1.5em} 3 = bad day} +} +\notes +{ + \begin{enumerate} + \item When an invalid year or month is supplied (status J~=~1~or~2) + the MJD is {\bf not} computed. When an invalid day is supplied + (status J~=~3) the MJD {\bf is} computed. + \item The year must be $-$4699 ({\it i.e.}\ 4700BC) or later. + For year $n$BC use IY = $-(n-1)$. + \item An alternative to the present routine is sla\_CALDJ, which + accepts a year with the century missing. + \end{enumerate} +} +\aref{The algorithm is derived from that of Hatcher, + {\it Q.\,Jl.\,R.\,astr.\,Soc.}\ (1984) {\bf 25}, 53-55.} +%----------------------------------------------------------------------- +\routine{SLA\_CLYD}{Calendar to Year, Day} +{ + \action{Gregorian calendar date to year and day in year, in a Julian + calendar aligned to the 20th/21st century Gregorian calendar.} + \call{CALL sla\_CLYD (IY, IM, ID, NY, ND, J)} +} +\args{GIVEN} +{ + \spec{IY,IM,ID}{I}{year, month, day in Gregorian calendar} +} +\args{RETURNED} +{ + \spec{NY}{I}{year (re-aligned Julian calendar)} \\ + \spec{ND}{I}{day in year (1 = January 1st)} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} 1 = bad year (before $-4711$)} \\ + \spec{}{}{\hspace{1.5em} 2 = bad month} \\ + \spec{}{}{\hspace{1.5em} 3 = bad day} +} +\notes +{ + \begin{enumerate} + \item The purpose of sla\_CLYD is to support sla\_EARTH, + sla\_MOON and sla\_ECOR. + \item Between 1900~March~1 and 2100~February~28 it returns answers + which are consistent with the ordinary Gregorian calendar. + Outside this range there will be a discrepancy which increases + by one day for every non-leap century year. + \item When an invalid year or month is supplied (status J~=~1 or J~=~2) + the results are {\bf not} computed. When a day is + supplied which is outside the conventional range (status J~=~3) + the results {\bf are} computed. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_COMBN}{Next Combination} +{ + \action{Generate the next combination, a subset of a specified size chosen + from a specified number of items.} + \call{CALL sla\_COMBN (NSEL, NCAND, LIST, J)} +} +\args{GIVEN} +{ + \spec{NSEL}{I}{number of items (subset size)} \\ + \spec{NCAND}{I}{number of candidates (set size)} +} +\args{GIVEN and RETURNED} +{ + \spec{LIST}{I(NSEL)}{latest combination, LIST(1)=0 to initialize} +} +\args{RETURNED} +{ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} $-$1 = illegal NSEL or NCAND} \\ + \spec{}{}{\hspace{2.3em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} $+$1 = no more combinations available} +} +\notes +{ + \begin{enumerate} + \item NSEL and NCAND must both be at least 1, and NSEL must be less + than or equal to NCAND. + \item This routine returns, in the LIST array, a subset of NSEL integers + chosen from the range 1 to NCAND inclusive, in ascending order. + Before calling the routine for the first time, the caller must set + the first element of the LIST array to zero (any value less than 1 + will do) to cause initialization. + \item The first combination to be generated is: + \begin{verse} + LIST(1)=1, LIST(2)=2, \ldots, LIST(NSEL)=NSEL + \end{verse} + This is also the combination returned for the ``finished'' (J=1) case. + The final permutation to be generated is: + \begin{verse} + LIST(1)=NCAND, LIST(2)=NCAND$-$1, \ldots, \\ + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~LIST(NSEL)=NCAND$-$NSEL+1 + \end{verse} + \item If the ``finished'' (J=1) status is ignored, the routine + continues to deliver combinations, the pattern repeating + every NCAND!/(NSEL!(NCAND$-$NSEL)!) calls. + \item The algorithm is by R.\,F.\,Warren-Smith (private communication). + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CR2AF}{Radians to Deg,Arcmin,Arcsec} +{ + \action{Convert an angle in radians to degrees, arcminutes, + arcseconds (single precision).} + \call{CALL sla\_CR2AF (NDP, ANGLE, SIGN, IDMSF)} +} +\args{GIVEN} +{ + \spec{NDP}{I}{number of decimal places of arcseconds} \\ + \spec{ANGLE}{R}{angle in radians} +} +\args{RETURNED} +{ + \spec{SIGN}{C}{`+' or `$-$'} \\ + \spec{IDMSF}{I(4)}{degrees, arcminutes, arcseconds, fraction} +} +\notes +{ + \begin{enumerate} + \item NDP less than zero is interpreted as zero. + \item The largest useful value for NDP is determined by the size of + ANGLE, the format of REAL floating-point numbers on the target + machine, and the risk of overflowing IDMSF(4). For example, + on a VAX computer, for ANGLE up to $2\pi$, the available floating-point + precision corresponds roughly to NDP=3. This is well below + the ultimate limit of NDP=9 set by the capacity of the 32-bit + integer IHMSF(4). + \item The absolute value of ANGLE may exceed $2\pi$. In cases where it + does not, it is up to the caller to test for and handle the + case where ANGLE is very nearly $2\pi$ and rounds up to $360^{\circ}$, + by testing for IDMSF(1)=360 and setting IDMSF(1-4) to zero. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CR2TF}{Radians to Hour,Min,Sec} +{ + \action{Convert an angle in radians to hours, minutes, seconds + (single precision).} + \call{CALL sla\_CR2TF (NDP, ANGLE, SIGN, IHMSF)} +} +\args{GIVEN} +{ + \spec{NDP}{I}{number of decimal places of seconds} \\ + \spec{ANGLE}{R}{angle in radians} +} +\args{RETURNED} +{ + \spec{SIGN}{C}{`+' or `$-$'} \\ + \spec{IHMSF}{I(4)}{hours, minutes, seconds, fraction} +} +\notes +{ + \begin{enumerate} + \item NDP less than zero is interpreted as zero. + \item The largest useful value for NDP is determined by the size of + ANGLE, the format of REAL floating-point numbers on the target + machine, and the risk of overflowing IHMSF(4). For example, + on a VAX computer, for ANGLE up to $2\pi$, the available floating-point + precision corresponds roughly to NDP=3. This is well below + the ultimate limit of NDP=9 set by the capacity of the 32-bit + integer IHMSF(4). + \item The absolute value of ANGLE may exceed $2\pi$. In cases where it + does not, it is up to the caller to test for and handle the + case where ANGLE is very nearly $2\pi$ and rounds up to 24~hours, + by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +\end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CS2C}{Spherical to Cartesian} +{ + \action{Spherical coordinates to Cartesian coordinates (single precision).} + \call{CALL sla\_CS2C (A, B, V)} +} +\args{GIVEN} +{ + \spec{A,B}{R}{spherical coordinates in radians: \radec\ {\it etc.}} +} +\args{RETURNED} +{ + \spec{V}{R(3)}{\xyz\ unit vector} +} +\anote{The spherical coordinates are longitude (+ve anticlockwise + looking from the +ve latitude pole) and latitude. The + Cartesian coordinates are right handed, with the {\it x}-axis + at zero longitude and latitude, and the {\it z}-axis at the + +ve latitude pole.} +%----------------------------------------------------------------------- +\routine{SLA\_CS2C6}{Spherical Pos/Vel to Cartesian} +{ + \action{Conversion of position \& velocity in spherical coordinates + to Cartesian coordinates (single precision).} + \call{CALL sla\_CS2C6 (A, B, R, AD, BD, RD, V)} +} +\args{GIVEN} +{ + \spec{A}{R}{longitude (radians) -- for example $\alpha$} \\ + \spec{B}{R}{latitude (radians) -- for example $\delta$} \\ + \spec{R}{R}{radial coordinate} \\ + \spec{AD}{R}{longitude derivative (radians per unit time)} \\ + \spec{BD}{R}{latitude derivative (radians per unit time)} \\ + \spec{RD}{R}{radial derivative} +} +\args{RETURNED} +{ + \spec{V}{R(6)}{\xyzxyzd} +} +%----------------------------------------------------------------------- +\routine{SLA\_CTF2D}{Hour,Min,Sec to Days} +{ + \action{Convert hours, minutes, seconds to days (single precision).} + \call{CALL sla\_CTF2D (IHOUR, IMIN, SEC, DAYS, J)} +} +\args{GIVEN} +{ + \spec{IHOUR}{I}{hours} \\ + \spec{IMIN}{I}{minutes} \\ + \spec{SEC}{R}{seconds} +} +\args{RETURNED} +{ + \spec{DAYS}{R}{interval in days} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} 1 = IHOUR outside range 0-23} \\ + \spec{}{}{\hspace{1.5em} 2 = IMIN outside range 0-59} \\ + \spec{}{}{\hspace{1.5em} 3 = SEC outside range 0-59.999$\cdots$} +} +\notes +{ + \begin{enumerate} + \item The result is computed even if any of the range checks fail. + \item The sign must be dealt with outside this routine. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_CTF2R}{Hour,Min,Sec to Radians} +{ + \action{Convert hours, minutes, seconds to radians (single precision).} + \call{CALL sla\_CTF2R (IHOUR, IMIN, SEC, RAD, J)} +} +\args{GIVEN} +{ + \spec{IHOUR}{I}{hours} \\ + \spec{IMIN}{I}{minutes} \\ + \spec{SEC}{R}{seconds} +} +\args{RETURNED} +{ + \spec{RAD}{R}{angle in radians} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} 1 = IHOUR outside range 0-23} \\ + \spec{}{}{\hspace{1.5em} 2 = IMIN outside range 0-59} \\ + \spec{}{}{\hspace{1.5em} 3 = SEC outside range 0-59.999$\cdots$} +} +\notes +{ + \begin{enumerate} + \item The result is computed even if any of the range checks fail. + \item The sign must be dealt with outside this routine. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DAF2R}{Deg,Arcmin,Arcsec to Radians} +{ + \action{Convert degrees, arcminutes, arcseconds to radians + (double precision).} + \call{CALL sla\_DAF2R (IDEG, IAMIN, ASEC, RAD, J)} +} +\args{GIVEN} +{ + \spec{IDEG}{I}{degrees} \\ + \spec{IAMIN}{I}{arcminutes} \\ + \spec{ASEC}{D}{arcseconds} +} +\args{RETURNED} +{ + \spec{RAD}{D}{angle in radians} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 1 = IDEG outside range 0$-$359} \\ + \spec{}{}{\hspace{1.5em} 2 = IAMIN outside range 0$-$59} \\ + \spec{}{}{\hspace{1.5em} 3 = ASEC outside range 0$-$59.999$\cdots$} +} +\notes +{ + \begin{enumerate} + \item The result is computed even if any of the range checks fail. + \item The sign must be dealt with outside this routine. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DAFIN}{Sexagesimal character string to angle} +{ + \action{Decode a free-format sexagesimal string (degrees, arcminutes, + arcseconds) into a double precision floating point + number (radians).} + \call{CALL sla\_DAFIN (STRING, NSTRT, DRESLT, JF)} +} +\args{GIVEN} +{ + \spec{STRING}{C*(*)}{string containing deg, arcmin, arcsec fields} \\ + \spec{NSTRT}{I}{pointer to start of decode (beginning of STRING = 1)} +} +\args{RETURNED} +{ + \spec{NSTRT}{I}{advanced past the decoded angle} \\ + \spec{DRESLT}{D}{angle in radians} \\ + \spec{JF}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{0.7em} $+1$ = default, DRESLT unchanged (note 2)} \\ + \spec{}{}{\hspace{0.7em} $-1$ = bad degrees (note 3)} \\ + \spec{}{}{\hspace{0.7em} $-2$ = bad arcminutes (note 3)} \\ + \spec{}{}{\hspace{0.7em} $-3$ = bad arcseconds (note 3)} \\ +} +\goodbreak +\setlength{\oldspacing}{\topsep} +\setlength{\topsep}{0.3ex} +\begin{description} + \item [EXAMPLE]: \\ [1.5ex] + \begin{tabular}{p{7em}p{15em}p{12em}} + {\it argument} & {\it before} & {\it after} \\ \\ + STRING & $'$\verb*}-57 17 44.806 12 34 56.7}$'$ & unchanged \\ + NSTRT & 1 & 16 ({\it i.e.}\ pointing to 12...) \\ + RESLT & - & $-1.00000${\tt D0} \\ + JF & - & 0 + \end{tabular} + \item A further call to sla\_DAFIN, without adjustment of NSTRT, will + decode the second angle, \dms{12}{34}{56}{7}. +\end{description} +\setlength{\topsep}{\oldspacing} +\notes +{ + \begin{enumerate} + \item The first three ``fields'' in STRING are degrees, arcminutes, + arcseconds, separated by spaces or commas. The degrees field + may be signed, but not the others. The decoding is carried + out by the sla\_DFLTIN routine and is free-format. + \item Successive fields may be absent, defaulting to zero. For + zero status, the only combinations allowed are degrees alone, + degrees and arcminutes, and all three fields present. If all + three fields are omitted, a status of +1 is returned and DRESLT is + unchanged. In all other cases DRESLT is changed. + \item Range checking: + \begin{itemize} + \item The degrees field is not range checked. However, it is + expected to be integral unless the other two fields are absent. + \item The arcminutes field is expected to be 0-59, and integral if + the arcseconds field is present. If the arcseconds field + is absent, the arcminutes is expected to be 0-59.9999... + \item The arcseconds field is expected to be 0-59.9999... + \item Decoding continues even when a check has failed. Under these + circumstances the field takes the supplied value, defaulting to + zero, and the result DRESLT is computed and returned. + \end{itemize} + \item Further fields after the three expected ones are not treated as + an error. The pointer NSTRT is left in the correct state for + further decoding with the present routine or with sla\_DFLTIN + {\it etc}. See the example, above. + \item If STRING contains hours, minutes, seconds instead of + degrees {\it etc}, + or if the required units are turns (or days) instead of radians, + the result DRESLT should be multiplied as follows: \\ [1.5ex] + \begin{tabular}{p{6em}p{5em}p{18em}} + {\it for STRING} & {\it to obtain} & {\it multiply DRESLT by} \\ \\ + ${\circ}$~~\raisebox{-0.7ex}{$'$}~~\raisebox{-0.7ex}{$''$} + & radians & $1.0${\tt D0} \\ + ${\circ}$~~\raisebox{-0.7ex}{$'$}~~\raisebox{-0.7ex}{$''$} + & turns & $1/{2 \pi} = 0.1591549430918953358${\tt D0} \\ + h m s & radians & $15.0${\tt D0} \\ + h m s & days & $15/{2\pi} = 2.3873241463784300365${\tt D0} + \end{tabular} + \end{enumerate} +} +%------------------------------------------------------------------------------ +\routine{SLA\_DAT}{TAI$-$UTC} +{ + \action{Increment to be applied to Coordinated Universal Time UTC to give + International Atomic Time TAI.} + \call{D~=~sla\_DAT (UTC)} +} +\args{GIVEN} +{ + \spec{UTC}{D}{UTC date as a modified JD (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{sla\_DAT}{D}{TAI$-$UTC in seconds} +} +\notes +{ + \begin{enumerate} + \item The UTC is specified to be a date rather than a time to indicate + that care needs to be taken not to specify an instant which lies + within a leap second. Though in most cases UTC can include the + fractional part, correct behaviour on the day of a leap second + can be guaranteed only up to the end of the second + $23^{\rm h}\,59^{\rm m}\,59^{\rm s}$. + \item UTC began at 1960 January 1. To specify a UTC prior to this + date would be meaningless; in such cases the parameters + for the year 1960 are used by default. + \item This routine has to be updated on each occasion that a + leap second is announced, and programs using it relinked. + Refer to the program source code for information on when the + most recent leap second was added. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DAV2M}{Rotation Matrix from Axial Vector} +{ + \action{Form the rotation matrix corresponding to a given axial vector + (double precision).} + \call{CALL sla\_DAV2M (AXVEC, RMAT)} +} +\args{GIVEN} +{ + \spec{AXVEC}{D(3)}{axial vector (radians)} +} +\args{RETURNED} +{ + \spec{RMAT}{D(3,3)}{rotation matrix} +} +\notes +{ + \begin{enumerate} + \item A rotation matrix describes a rotation about some arbitrary axis. + The axis is called the {\it Euler axis}, and the angle through which the + reference frame rotates is called the {\it Euler angle}. The axial + vector supplied to this routine has the same direction as the + Euler axis, and its magnitude is the Euler angle in radians. + \item If AXVEC is null, the unit matrix is returned. + \item The reference frame rotates clockwise as seen looking along + the axial vector from the origin. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DBEAR}{Direction Between Points on a Sphere} +{ + \action{Returns the bearing (position angle) of one point on a + sphere relative to another (double precision).} + \call{D~=~sla\_DBEAR (A1, B1, A2, B2)} +} +\args{GIVEN} +{ + \spec{A1,B1}{D}{spherical coordinates of one point} \\ + \spec{A2,B2}{D}{spherical coordinates of the other point} +} +\args{RETURNED} +{ + \spec{sla\_DBEAR}{D}{bearing from first point to second} +} +\notes +{ + \begin{enumerate} + \item The spherical coordinates are \radec, + $[\lambda,\phi]$ {\it etc.}, in radians. + \item The result is the bearing (position angle), in radians, + of point [A2,B2] as seen + from point [A1,B1]. It is in the range $\pm \pi$. The sense + is such that if [A2,B2] + is a small distance due east of [A1,B1] the result + is about $+\pi/2$. Zero is returned + if the two points are coincident. + \item If either B-coordinate is outside the range $\pm\pi/2$, the + result may correspond to ``the long way round''. + \item The routine sla\_DPAV performs an equivalent function except + that the points are specified in the form of Cartesian unit + vectors. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DBJIN}{Decode String to B/J Epoch (DP)} +{ + \action{Decode a character string into a DOUBLE PRECISION number, + with special provision for Besselian and Julian epochs. + The string syntax is as for sla\_DFLTIN, prefixed by + an optional `B' or `J'.} + \call{CALL sla\_DBJIN (STRING, NSTRT, DRESLT, J1, J2)} +} +\args{GIVEN} +{ + \spec{STRING}{C}{string containing field to be decoded} \\ + \spec{NSTRT}{I}{pointer to first character of field in string} +} +\args{RETURNED} +{ + \spec{NSTRT}{I}{incremented past the decoded field} \\ + \spec{DRESLT}{D}{result} \\ + \spec{J1}{I}{DFLTIN status:} \\ + \spec{}{}{\hspace{0.7em} $-$1 = $-$OK} \\ + \spec{}{}{\hspace{1.5em} 0 = +OK} \\ + \spec{}{}{\hspace{1.5em} 1 = null field} \\ + \spec{}{}{\hspace{1.5em} 2 = error} \\ + \spec{J2}{I}{syntax flag:} \\ + \spec{}{}{\hspace{1.5em} 0 = normal DFLTIN syntax} \\ + \spec{}{}{\hspace{1.5em} 1 = `B' or `b'} \\ + \spec{}{}{\hspace{1.5em} 2 = `J' or `j'} +} +\notes +{ + \begin{enumerate} + \item The purpose of the syntax extensions is to help cope with mixed + FK4 and FK5 data, allowing fields such as `B1950' or `J2000' + to be decoded. + \item In addition to the syntax accepted by sla\_DFLTIN, + the following two extensions are recognized by sla\_DBJIN: + \begin{enumerate} + \item A valid non-null field preceded by the character `B' + (or `b') is accepted. + \item A valid non-null field preceded by the character `J' + (or `j') is accepted. + \end{enumerate} + \item The calling program is told of the `B' or `J' through an + supplementary status argument. The rest of + the arguments are as for sla\_DFLTIN. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DC62S}{Cartesian 6-Vector to Spherical} +{ + \action{Conversion of position \& velocity in Cartesian coordinates + to spherical coordinates (double precision).} + \call{CALL sla\_DC62S (V, A, B, R, AD, BD, RD)} +} +\args{GIVEN} +{ + \spec{V}{D(6)}{\xyzxyzd} +} +\args{RETURNED} +{ + \spec{A}{D}{longitude (radians)} \\ + \spec{B}{D}{latitude (radians)} \\ + \spec{R}{D}{radial coordinate} \\ + \spec{AD}{D}{longitude derivative (radians per unit time)} \\ + \spec{BD}{D}{latitude derivative (radians per unit time)} \\ + \spec{RD}{D}{radial derivative} +} +%----------------------------------------------------------------------- +\routine{SLA\_DCC2S}{Cartesian to Spherical} +{ + \action{Cartesian coordinates to spherical coordinates (double precision).} + \call{CALL sla\_DCC2S (V, A, B)} +} +\args{GIVEN} +{ + \spec{V}{D(3)}{\xyz\ vector} +} +\args{RETURNED} +{ + \spec{A,B}{D}{spherical coordinates in radians} +} +\notes +{ + \begin{enumerate} + \item The spherical coordinates are longitude (+ve anticlockwise + looking from the +ve latitude pole) and latitude. The + Cartesian coordinates are right handed, with the {\it x}-axis + at zero longitude and latitude, and the {\it z}-axis at the + +ve latitude pole. + \item If V is null, zero A and B are returned. + \item At either pole, zero A is returned. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DCMPF}{Interpret Linear Fit} +{ + \action{Decompose an \xy\ linear fit into its constituent parameters: + zero points, scales, nonperpendicularity and orientation.} + \call{CALL sla\_DCMPF (COEFFS,XZ,YZ,XS,YS,PERP,ORIENT)} +} +\args{GIVEN} +{ + \spec{COEFFS}{D(6)}{transformation coefficients (see note)} +} +\args{RETURNED} +{ + \spec{XZ}{D}{{\it x} zero point} \\ + \spec{YZ}{D}{{\it y} zero point} \\ + \spec{XS}{D}{{\it x} scale} \\ + \spec{YS}{D}{{\it y} scale} \\ + \spec{PERP}{D}{nonperpendicularity (radians)} \\ + \spec{ORIENT}{D}{orientation (radians)} +} +\notes +{ + \begin{enumerate} + \item The model relates two sets of \xy\ coordinates as follows. + Naming the six elements of COEFFS $a,b,c,d,e$ \& $f$, + the model transforms coordinates $[x_{1},y_{1}\,]$ into coordinates + $[x_{2},y_{2}\,]$ as follows: + \begin{verse} + $x_{2} = a + bx_{1} + cy_{1}$ \\ + $y_{2} = d + ex_{1} + fy_{1}$ + \end{verse} + The sla\_DCMPF routine decomposes this transformation + into four steps: + \begin{enumerate} + \item Zero points: + \begin{verse} + $x' = x_{1} + {\rm XZ}$ \\ + $y' = y_{1} + {\rm YZ}$ + \end{verse} + \item Scales: + \begin{verse} + $x'' = x' {\rm XS}$ \\ + $y'' = y' {\rm YS}$ + \end{verse} + \item Nonperpendicularity: + \begin{verse} + $x''' = + x'' \cos {\rm PERP}/2 + y'' \sin {\rm PERP}/2$ \\ + $y''' = + x'' \sin {\rm PERP}/2 + y'' \cos {\rm PERP}/2$ + \end{verse} + \item Orientation: + \begin{verse} + $x_{2} = + x''' \cos {\rm ORIENT} + + y''' \sin {\rm ORIENT}$ \\ + $y_{2} = - x''' \sin {\rm ORIENT} + + y''' \cos {\rm ORIENT}$ + \end{verse} + \end{enumerate} + \item See also sla\_FITXY, sla\_PXY, sla\_INVF, sla\_XY2XY. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DCS2C}{Spherical to Cartesian} +{ + \action{Spherical coordinates to Cartesian coordinates (double precision).} + \call{CALL sla\_DCS2C (A, B, V)} +} +\args{GIVEN} +{ + \spec{A,B}{D}{spherical coordinates in radians: \radec\ {\it etc.}} +} +\args{RETURNED} +{ + \spec{V}{D(3)}{\xyz\ unit vector} +} +\anote{The spherical coordinates are longitude (+ve anticlockwise + looking from the +ve latitude pole) and latitude. The + Cartesian coordinates are right handed, with the {\it x}-axis + at zero longitude and latitude, and the {\it z}-axis at the + +ve latitude pole.} +%----------------------------------------------------------------------- +\routine{SLA\_DD2TF}{Days to Hour,Min,Sec} +{ + \action{Convert an interval in days into hours, minutes, seconds + (double precision).} + \call{CALL sla\_DD2TF (NDP, DAYS, SIGN, IHMSF)} +} +\args{GIVEN} +{ + \spec{NDP}{I}{number of decimal places of seconds} \\ + \spec{DAYS}{D}{interval in days} +} +\args{RETURNED} +{ + \spec{SIGN}{C}{`+' or `$-$'} \\ + \spec{IHMSF}{I(4)}{hours, minutes, seconds, fraction} +} +\notes +{ + \begin{enumerate} + \item NDP less than zero is interpreted as zero. + \item The largest useful value for NDP is determined by the size + of DAYS, the format of DOUBLE PRECISION floating-point numbers + on the target machine, and the risk of overflowing IHMSF(4). + For example, on a VAX computer, for DAYS up to 1D0, the available + floating-point precision corresponds roughly to NDP=12. However, + the practical limit is NDP=9, set by the capacity of the 32-bit + integer IHMSF(4). + \item The absolute value of DAYS may exceed 1D0. In cases where it + does not, it is up to the caller to test for and handle the + case where DAYS is very nearly 1D0 and rounds up to 24~hours, + by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. +\end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DE2H}{$h,\delta$ to Az,El} +{ + \action{Equatorial to horizon coordinates + (double precision).} + \call{CALL sla\_DE2H (HA, DEC, PHI, AZ, EL)} +} +\args{GIVEN} +{ + \spec{HA}{D}{hour angle (radians)} \\ + \spec{DEC}{D}{declination (radians)} \\ + \spec{PHI}{D}{latitude (radians)} +} +\args{RETURNED} +{ + \spec{AZ}{D}{azimuth (radians)} \\ + \spec{EL}{D}{elevation (radians)} +} +\notes +{ + \begin{enumerate} + \item Azimuth is returned in the range $0\!-\!2\pi$; north is zero, + and east is $+\pi/2$. Elevation is returned in the range + $\pm\pi$. + \item The latitude must be geodetic. In critical applications, + corrections for polar motion should be applied. + \item In some applications it will be important to specify the + correct type of hour angle and declination in order to + produce the required type of azimuth and elevation. In + particular, it may be important to distinguish between + elevation as affected by refraction, which would + require the {\it observed} \hadec, and the elevation + {\it in vacuo}, which would require the {\it topocentric} + \hadec. + If the effects of diurnal aberration can be neglected, the + {\it apparent} \hadec\ may be used instead of the topocentric + \hadec. + \item No range checking of arguments is carried out. + \item In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude, and (for tracking a star) + sine and cosine of declination. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DEULER}{Euler Angles to Rotation Matrix} +{ + \action{Form a rotation matrix from the Euler angles -- three + successive rotations about specified Cartesian axes + (double precision).} + \call{CALL sla\_DEULER (ORDER, PHI, THETA, PSI, RMAT)} +} +\args{GIVEN} +{ + \spec{ORDER}{C}{specifies about which axes the rotations occur} \\ + \spec{PHI}{D}{1st rotation (radians)} \\ + \spec{THETA}{D}{2nd rotation (radians)} \\ + \spec{PSI}{D}{3rd rotation (radians)} +} +\args{RETURNED} +{ + \spec{RMAT}{D(3,3)}{rotation matrix} +} +\notes +{ + \begin{enumerate} + \item A rotation is positive when the reference frame rotates + anticlockwise as seen looking towards the origin from the + positive region of the specified axis. + \item The characters of ORDER define which axes the three successive + rotations are about. A typical value is `ZXZ', indicating that + RMAT is to become the direction cosine matrix corresponding to + rotations of the reference frame through PHI radians about the + old {\it z}-axis, followed by THETA radians about the resulting + {\it x}-axis, + then PSI radians about the resulting {\it z}-axis. + \item The axis names can be any of the following, in any order or + combination: X, Y, Z, uppercase or lowercase, 1, 2, 3. Normal + axis labelling/numbering conventions apply; the {\it xyz} ($\equiv123$) + triad is right-handed. Thus, the `ZXZ' example given above + could be written `zxz' or `313' (or even `ZxZ' or `3xZ'). ORDER + is terminated by length or by the first unrecognized character. + Fewer than three rotations are acceptable, in which case the later + angle arguments are ignored. Zero rotations produces a unit RMAT. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DFLTIN}{Decode a Double Precision Number} +{ + \action{Convert free-format input into double precision floating point.} + \call{CALL sla\_DFLTIN (STRING, NSTRT, DRESLT, JFLAG)} +} +\args{GIVEN} +{ + \spec{STRING}{C}{string containing number to be decoded} \\ + \spec{NSTRT}{I}{pointer to where decoding is to commence} \\ + \spec{DRESLT}{D}{current value of result} +} +\args{RETURNED} +{ + \spec{NSTRT}{I}{advanced to next number} \\ + \spec{DRESLT}{D}{result} \\ + \spec{JFLAG}{I}{status: $-$1~=~$-$OK, 0~=~+OK, 1~=~null result, 2~=~error} +} +\notes +{ + \begin{enumerate} + \item The reason sla\_DFLTIN has separate `OK' status values + for + and $-$ is to enable minus zero to be detected. + This is of crucial importance + when decoding mixed-radix numbers. For example, an angle + expressed as degrees, arcminutes and arcseconds may have a + leading minus sign but a zero degrees field. + \item A TAB is interpreted as a space, and lowercase characters are + interpreted as uppercase. {\it n.b.}\ The test for TAB is + ASCII-specific. + \item The basic format is the sequence of fields $\pm n.n x \pm n$, + where $\pm$ is a sign + character `+' or `$-$', $n$ means a string of decimal digits, + `.' is a decimal point, and $x$, which indicates an exponent, + means `D' or `E'. Various combinations of these fields can be + omitted, and embedded blanks are permissible in certain places. + \item Spaces: + \begin{itemize} + \item Leading spaces are ignored. + \item Embedded spaces are allowed only after +, $-$, D or E, + and after the decimal point if the first sequence of + digits is absent. + \item Trailing spaces are ignored; the first signifies + end of decoding and subsequent ones are skipped. + \end{itemize} + \item Delimiters: + \begin{itemize} + \item Any character other than +,$-$,0-9,.,D,E or space may be + used to signal the end of the number and terminate decoding. + \item Comma is recognized by sla\_DFLTIN as a special case; it + is skipped, leaving the pointer on the next character. See + 13, below. + \item Decoding will in all cases terminate if end of string + is reached. + \end{itemize} + \item Both signs are optional. The default is +. + \item The mantissa $n.n$ defaults to unity. + \item The exponent $x\!\pm\!n$ defaults to `D0'. + \item The strings of decimal digits may be of any length. + \item The decimal point is optional for whole numbers. + \item A {\it null result}\/ occurs when the string of characters + being decoded does not begin with +,$-$,0-9,.,D or E, or + consists entirely of spaces. When this condition is + detected, JFLAG is set to 1 and DRESLT is left untouched. + \item NSTRT = 1 for the first character in the string. + \item On return from sla\_DFLTIN, NSTRT is set ready for the next + decode -- following trailing blanks and any comma. If a + delimiter other than comma is being used, NSTRT must be + incremented before the next call to sla\_DFLTIN, otherwise + all subsequent calls will return a null result. + \item Errors (JFLAG=2) occur when: + \begin{itemize} + \item a +, $-$, D or E is left unsatisfied; or + \item the decimal point is present without at least + one decimal digit before or after it; or + \item an exponent more than 100 has been presented. + \end{itemize} + \item When an error has been detected, NSTRT is left + pointing to the character following the last + one used before the error came to light. This + may be after the point at which a more sophisticated + program could have detected the error. For example, + sla\_DFLTIN does not detect that `1D999' is unacceptable + (on a computer where this is so) until the entire number + has been decoded. + \item Certain highly unlikely combinations of mantissa and + exponent can cause arithmetic faults during the + decode, in some cases despite the fact that they + together could be construed as a valid number. + \item Decoding is left to right, one pass. + \item See also sla\_FLOTIN and sla\_INTIN. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DH2E}{Az,El to $h,\delta$} +{ + \action{Horizon to equatorial coordinates + (double precision).} + \call{CALL sla\_DH2E (AZ, EL, PHI, HA, DEC)} +} +\args{GIVEN} +{ + \spec{AZ}{D}{azimuth (radians)} \\ + \spec{EL}{D}{elevation (radians)} \\ + \spec{PHI}{D}{latitude (radians)} +} +\args{RETURNED} +{ + \spec{HA}{D}{hour angle (radians)} \\ + \spec{DEC}{D}{declination (radians)} +} +\notes +{ + \begin{enumerate} + \item The sign convention for azimuth is north zero, east $+\pi/2$. + \item HA is returned in the range $\pm\pi$. Declination is returned + in the range $\pm\pi$. + \item The latitude is (in principle) geodetic. In critical + applications, corrections for polar motion should be applied + (see sla\_POLMO). + \item In some applications it will be important to specify the + correct type of elevation in order to produce the required + type of \hadec. In particular, it may be important to + distinguish between the elevation as affected by refraction, + which will yield the {\it observed} \hadec, and the elevation + {\it in vacuo}, which will yield the {\it topocentric} + \hadec. If the + effects of diurnal aberration can be neglected, the + topocentric \hadec\ may be used as an approximation to the + {\it apparent} \hadec. + \item No range checking of arguments is carried out. + \item In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DIMXV}{Apply 3D Reverse Rotation} +{ + \action{Multiply a 3-vector by the inverse of a rotation + matrix (double precision).} + \call{CALL sla\_DIMXV (DM, VA, VB)} +} +\args{GIVEN} +{ + \spec{DM}{D(3,3)}{rotation matrix} \\ + \spec{VA}{D(3)}{vector to be rotated} +} +\args{RETURNED} +{ + \spec{VB}{D(3)}{result vector} +} +\notes +{ + \begin{enumerate} + \item This routine performs the operation: + \begin{verse} + {\bf b} = {\bf M}$^{T}\cdot${\bf a} + \end{verse} + where {\bf a} and {\bf b} are the 3-vectors VA and VB + respectively, and {\bf M} is the $3\times3$ matrix DM. + \item The main function of this routine is apply an inverse + rotation; under these circumstances, ${\bf \rm M}$ is + {\it orthogonal}, with its inverse the same as its transpose. + \item To comply with the ANSI Fortran 77 standard, VA and VB must + {\bf not} be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is {\bf not}, however, + recommended. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DJCAL}{MJD to Gregorian for Output} +{ + \action{Modified Julian Date to Gregorian Calendar Date, expressed + in a form convenient for formatting messages (namely + rounded to a specified precision, and with the fields + stored in a single array).} + \call{CALL sla\_DJCAL (NDP, DJM, IYMDF, J)} +} +\args{GIVEN} +{ + \spec{NDP}{I}{number of decimal places of days in fraction} \\ + \spec{DJM}{D}{modified Julian Date (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{IYMDF}{I(4)}{year, month, day, fraction in Gregorian calendar} \\ + \spec{J}{I}{status: nonzero = out of range} +} +\notes +{ + \begin{enumerate} + \item Any date after 4701BC March 1 is accepted. + \item NDP should be 4 or less to avoid overflow on machines which + use 32-bit integers. + \end{enumerate} +} +\aref{The algorithm is derived from that of Hatcher, + {\it Q.\,Jl.\,R.\,astr.\,Soc.}\ (1984) {\bf 25}, 53-55.} +%----------------------------------------------------------------------- +\routine{SLA\_DJCL}{MJD to Year,Month,Day,Frac} +{ + \action{Modified Julian Date to Gregorian year, month, day, + and fraction of a day.} + \call{CALL sla\_DJCL (DJM, IY, IM, ID, FD, J)} +} +\args{GIVEN} +{ + \spec{DJM}{D}{modified Julian Date (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{IY}{I}{year} \\ + \spec{IM}{I}{month} \\ + \spec{ID}{I}{day} \\ + \spec{FD}{D}{fraction of day} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{0.7em} $-$1 = unacceptable date (before 4701BC March 1)} +} +\aref{The algorithm is derived from that of Hatcher, + {\it Q.\,Jl.\,R.\,astr.\,Soc.}\ (1984) {\bf 25}, 53-55.} +%----------------------------------------------------------------------- +\routine{SLA\_DM2AV}{Rotation Matrix to Axial Vector} +{ + \action{From a rotation matrix, determine the corresponding axial vector + (double precision).} + \call{CALL sla\_DM2AV (RMAT, AXVEC)} +} +\args{GIVEN} +{ + \spec{RMAT}{D(3,3)}{rotation matrix} +} +\args{RETURNED} +{ + \spec{AXVEC}{D(3)}{axial vector (radians)} +} +\notes +{ + \begin{enumerate} + \item A rotation matrix describes a rotation about some arbitrary axis. + The axis is called the {\it Euler axis}, and the angle through + which the reference frame rotates is called the {\it Euler angle}. + The {\it axial vector}\/ returned by this routine has the same + direction as the Euler axis, and its magnitude is the Euler angle + in radians. + \item The magnitude and direction of the axial vector can be separated + by means of the routine sla\_DVN. + \item The reference frame rotates clockwise as seen looking along + the axial vector from the origin. + \item If RMAT is null, so is the result. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DMAT}{Solve Simultaneous Equations} +{ + \action{Matrix inversion and solution of simultaneous equations + (double precision).} + \call{CALL sla\_DMAT (N, A, Y, D, JF, IW)} +} +\args{GIVEN} +{ + \spec{N}{I}{number of unknowns} \\ + \spec{A}{D(N,N)}{matrix} \\ + \spec{Y}{D(N)}{vector} +} +\args{RETURNED} +{ + \spec{A}{D(N,N)}{matrix inverse} \\ + \spec{Y}{D(N)}{solution} \\ + \spec{D}{D}{determinant} \\ + \spec{JF}{I}{singularity flag: 0=OK} \\ + \spec{IW}{I(N)}{workspace} +} +\notes +{ + \begin{enumerate} + \item For the set of $n$ simultaneous linear equations in $n$ unknowns: + \begin{verse} + {\bf A}$\cdot${\bf y} = {\bf x} + \end{verse} + where: + \begin{itemize} + \item {\bf A} is a non-singular $n \times n$ matrix, + \item {\bf y} is the vector of $n$ unknowns, and + \item {\bf x} is the known vector, + \end{itemize} + sla\_DMAT computes: + \begin{itemize} + \item the inverse of matrix {\bf A}, + \item the determinant of matrix {\bf A}, and + \item the vector of $n$ unknowns {\bf y}. + \end{itemize} + Argument N is the order $n$, A (given) is the matrix {\bf A}, + Y (given) is the vector {\bf x} and Y (returned) + is the vector {\bf y}. + The argument A (returned) is the inverse matrix {\bf A}$^{-1}$, + and D is {\it det}\/({\bf A}). + \item JF is the singularity flag. If the matrix is non-singular, + JF=0 is returned. If the matrix is singular, JF=$-$1 + and D=0D0 are returned. In the latter case, the contents + of array A on return are undefined. + \item The algorithm is Gaussian elimination with partial pivoting. + This method is very fast; some much slower algorithms can give + better accuracy, but only by a small factor. + \item This routine replaces the obsolete sla\_DMATRX. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DMOON}{Approx Moon Pos/Vel} +{ + \action{Approximate geocentric position and velocity of the Moon + (double precision).} + \call{CALL sla\_DMOON (DATE, PV)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{TDB (loosely ET) as a Modified Julian Date (JD$-$2400000.5) +} +} +\args{RETURNED} +{ + \spec{PV}{D(6)}{Moon \xyzxyzd, mean equator and equinox + of date (AU, AU~s$^{-1}$)} +} +\notes +{ + \begin{enumerate} + \item This routine is a full implementation of the algorithm + published by Meeus (see reference). + \item Meeus quotes accuracies of \arcseci{10} in longitude, + \arcseci{3} in latitude and \arcsec{0}{2} arcsec in HP + (equivalent to about 20~km in distance). Comparison with + JPL~DE200 over the interval 1960-2025 gives RMS errors of + \arcsec{3}{7} and 83~mas/hour in longitude, + \arcsec{2}{3} arcsec and 48~mas/hour in latitude, + 11~km and 81~mm/s in distance. + The maximum errors over the same interval are + \arcseci{18} and \arcsec{0}{50}/hour in longitude, + \arcseci{11} and \arcsec{0}{24}/hour in latitude, + 40~km and 0.29~m/s in distance. + \item The original algorithm is expressed in terms of the obsolete + timescale {\it Ephemeris Time}. Either TDB or TT can be used, + but not UT without incurring significant errors (\arcseci{30} at + the present time) due to the Moon's \arcsec{0}{5}/s movement. + \item The algorithm is based on pre IAU 1976 standards. However, + the result has been moved onto the new (FK5) equinox, an + adjustment which is in any case much smaller than the + intrinsic accuracy of the procedure. + \item Velocity is obtained by a complete analytical differentiation + of the Meeus model. + \end{enumerate} +} +\aref{Meeus, {\it l'Astronomie}, June 1984, p348.} +%----------------------------------------------------------------------- +\routine{SLA\_DMXM}{Multiply $3\times3$ Matrices} +{ + \action{Product of two $3\times3$ matrices (double precision).} + \call{CALL sla\_DMXM (A, B, C)} +} +\args{GIVEN} +{ + \spec{A}{D(3,3)}{matrix {\bf A}} \\ + \spec{B}{D(3,3)}{matrix {\bf B}} +} +\args{RETURNED} +{ + \spec{C}{D(3,3)}{matrix result: {\bf A}$\times${\bf B}} +} +\anote{To comply with the ANSI Fortran 77 standard, A, B and C must + be different arrays. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is {\bf not}, however, + recommended.} +%----------------------------------------------------------------------- +\routine{SLA\_DMXV}{Apply 3D Rotation} +{ + \action{Multiply a 3-vector by a rotation matrix (double precision).} + \call{CALL sla\_DMXV (DM, VA, VB)} +} +\args{GIVEN} +{ + \spec{DM}{D(3,3)}{rotation matrix} \\ + \spec{VA}{D(3)}{vector to be rotated} +} +\args{RETURNED} +{ + \spec{VB}{D(3)}{result vector} +} +\notes +{ + \begin{enumerate} + \item This routine performs the operation: + \begin{verse} + {\bf b} = {\bf M}$\cdot${\bf a} + \end{verse} + where {\bf a} and {\bf b} are the 3-vectors VA and VB + respectively, and {\bf M} is the $3\times3$ matrix DM. + \item The main function of this routine is apply a + rotation; under these circumstances, {\bf M} is a + {\it proper real orthogonal}\/ matrix. + \item To comply with the ANSI Fortran 77 standard, VA and VB must + {\bf not} be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is {\bf not}, however, + recommended. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DPAV}{Position-Angle Between Two Directions} +{ + \action{Returns the bearing (position angle) of one celestial + direction with respect to another (double precision).} + \call{D~=~sla\_DPAV (V1, V2)} +} +\args{GIVEN} +{ + \spec{V1}{D(3)}{direction cosines of one point} \\ + \spec{V2}{D(3)}{directions cosines of the other point} +} +\args{RETURNED} +{ + \spec{sla\_DPAV}{D}{position-angle of 2nd point with respect to 1st} +} +\notes +{ + \begin{enumerate} + \item The coordinate frames correspond to \radec, + $[\lambda,\phi]$ {\it etc.}. + \item The result is the bearing (position angle), in radians, + of point V2 as seen + from point V1. It is in the range $\pm \pi$. The sense + is such that if V2 + is a small distance due east of V1 the result + is about $+\pi/2$. Zero is returned + if the two points are coincident. + \item The routine sla\_DBEAR performs an equivalent function except + that the points are specified in the form of spherical coordinates. + \end{enumerate} +} +%------------------------------------------------------------------------------ +\routine{SLA\_DR2AF}{Radians to Deg,Min,Sec,Frac} +{ + \action{Convert an angle in radians to degrees, arcminutes, arcseconds, + fraction (double precision).} + \call{CALL sla\_DR2AF (NDP, ANGLE, SIGN, IDMSF)} +} +\args{GIVEN} +{ + \spec{NDP}{I}{number of decimal places of arcseconds} \\ + \spec{ANGLE}{D}{angle in radians} +} +\args{RETURNED} +{ + \spec{SIGN}{C}{`+' or `$-$'} \\ + \spec{IDMSF}{I(4)}{degrees, arcminutes, arcseconds, fraction} +} +\notes +{ + \begin{enumerate} + \item NDP less than zero is interpreted as zero. + \item The largest useful value for NDP is determined by the size + of ANGLE, the format of DOUBLE~PRECISION floating-point numbers + on the target machine, and the risk of overflowing IDMSF(4). + For example, on a VAX computer, for ANGLE up to $2\pi$, the available + floating-point precision corresponds roughly to NDP=12. However, + the practical limit is NDP=9, set by the capacity of the 32-bit + integer IDMSF(4). + \item The absolute value of ANGLE may exceed $2\pi$. In cases where it + does not, it is up to the caller to test for and handle the + case where ANGLE is very nearly $2\pi$ and rounds up to $360^{\circ}$, + by testing for IDMSF(1)=360 and setting IDMSF(1-4) to zero. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DR2TF}{Radians to Hour,Min,Sec,Frac} +{ + \action{Convert an angle in radians to hours, minutes, seconds, + fraction (double precision).} + \call{CALL sla\_DR2TF (NDP, ANGLE, SIGN, IHMSF)} +} +\args{GIVEN} +{ + \spec{NDP}{I}{number of decimal places of seconds} \\ + \spec{ANGLE}{D}{angle in radians} +} +\args{RETURNED} +{ + \spec{SIGN}{C}{`+' or `$-$'} \\ + \spec{IHMSF}{I(4)}{hours, minutes, seconds, fraction} +} +\notes +{ + \begin{enumerate} + \item NDP less than zero is interpreted as zero. + \item The largest useful value for NDP is determined by the size + of ANGLE, the format of DOUBLE PRECISION floating-point numbers + on the target machine, and the risk of overflowing IHMSF(4). + For example, on a VAX computer, for ANGLE up to $2\pi$, the available + floating-point precision corresponds roughly to NDP=12. However, + the practical limit is NDP=9, set by the capacity of the 32-bit + integer IHMSF(4). + \item The absolute value of ANGLE may exceed $2\pi$. In cases where it + does not, it is up to the caller to test for and handle the + case where ANGLE is very nearly $2\pi$ and rounds up to 24~hours, + by testing for IHMSF(1)=24 and setting IHMSF(1-4) to zero. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DRANGE}{Put Angle into Range $\pm\pi$} +{ + \action{Normalize an angle into the range $\pm\pi$ (double precision).} + \call{D~=~sla\_DRANGE (ANGLE)} +} +\args{GIVEN} +{ + \spec{ANGLE}{D}{angle in radians} +} +\args{RETURNED} +{ + \spec{sla\_DRANGE}{D}{ANGLE expressed in the range $\pm\pi$.} +} +%----------------------------------------------------------------------- +\routine{SLA\_DRANRM}{Put Angle into Range $0\!-\!2\pi$} +{ + \action{Normalize an angle into the range $0\!-\!2\pi$ + (double precision).} + \call{D~=~sla\_DRANRM (ANGLE)} +} +\args{GIVEN} +{ + \spec{ANGLE}{D}{angle in radians} +} +\args{RETURNED} +{ + \spec{sla\_DRANRM}{D}{ANGLE expressed in the range $0\!-\!2\pi$} +} +%----------------------------------------------------------------------- +\routine{SLA\_DS2C6}{Spherical Pos/Vel to Cartesian} +{ + \action{Conversion of position \& velocity in spherical coordinates + to Cartesian coordinates (double precision).} + \call{CALL sla\_DS2C6 (A, B, R, AD, BD, RD, V)} +} +\args{GIVEN} +{ + \spec{A}{D}{longitude (radians) -- for example $\alpha$} \\ + \spec{B}{D}{latitude (radians) -- for example $\delta$} \\ + \spec{R}{D}{radial coordinate} \\ + \spec{AD}{D}{longitude derivative (radians per unit time)} \\ + \spec{BD}{D}{latitude derivative (radians per unit time)} \\ + \spec{RD}{D}{radial derivative} +} +\args{RETURNED} +{ + \spec{V}{D(6)}{\xyzxyzd} +} +%----------------------------------------------------------------------- +\routine{SLA\_DS2TP}{Spherical to Tangent Plane} +{ + \action{Projection of spherical coordinates onto the tangent plane + (double precision).} + \call{CALL sla\_DS2TP (RA, DEC, RAZ, DECZ, XI, ETA, J)} +} +\args{GIVEN} +{ + \spec{RA,DEC}{D}{spherical coordinates of star (radians)} \\ + \spec{RAZ,DECZ}{D}{spherical coordinates of tangent point (radians)} +} +\args{RETURNED} +{ + \spec{XI,ETA}{D}{tangent plane coordinates (radians)} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK, star on tangent plane} \\ + \spec{}{}{\hspace{1.5em} 1 = error, star too far from axis} \\ + \spec{}{}{\hspace{1.5em} 2 = error, antistar on tangent plane} \\ + \spec{}{}{\hspace{1.5em} 3 = error, antistar too far from axis} +} +\notes +{ + \begin{enumerate} + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item When working in \xyz\ rather than spherical coordinates, the + equivalent Cartesian routine sla\_DV2TP is available. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DSEP}{Angle Between 2 Points on Sphere} +{ + \action{Angle between two points on a sphere (double precision).} + \call{D~=~sla\_DSEP (A1, B1, A2, B2)} +} +\args{GIVEN} +{ + \spec{A1,B1}{D}{spherical coordinates of one point (radians)} \\ + \spec{A2,B2}{D}{spherical coordinates of the other point (radians)} +} +\args{RETURNED} +{ + \spec{sla\_DSEP}{D}{angle between [A1,B1] and [A2,B2] in radians} +} +\notes +{ + \begin{enumerate} + \item The spherical coordinates are right ascension and declination, + longitude and latitude, {\it etc.}, in radians. + \item The result is always positive. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DT}{Approximate ET minus UT} +{ + \action{Estimate $\Delta$T, the offset between dynamical time + and Universal Time, for a given historical epoch.} + \call{D~=~sla\_DT (EPOCH)} +} +\args{GIVEN} +{ + \spec{EPOCH}{D}{(Julian) epoch ({\it e.g.}\ 1850D0)} +} +\args{RETURNED} +{ + \spec{sla\_DT}{D}{approximate ET$-$UT (after 1984, TT$-$UT1) in seconds} +} +\notes +{ + \begin{enumerate} + \item Depending on the epoch, one of three parabolic approximations + is used: +\begin{tabbing} +xx \= xxxxxxxxxxxxxxxxxx \= \kill +\> before AD 979 \> Stephenson \& Morrison's 390 BC to AD 948 model \\ +\> AD 979 to AD 1708 \> Stephenson \& Morrison's AD 948 to AD 1600 model \\ +\> after AD 1708 \> McCarthy \& Babcock's post-1650 model +\end{tabbing} + The breakpoints are chosen to ensure continuity: they occur + at places where the adjacent models give the same answer as + each other. + \item The accuracy is modest, with errors of up to $20^{\rm s}$ during + the interval since 1650, rising to perhaps $30^{\rm m}$ + by 1000~BC. Comparatively accurate values from AD~1600 + are tabulated in + the {\it Astronomical Almanac}\/ (see section K8 of the 1995 + edition). + \item The use of {\tt DOUBLE PRECISION} for both argument and result is + simply for compatibility with other SLALIB time routines. + \item The models used are based on a lunar tidal acceleration value + of \arcsec{-26}{00} per century. + \end{enumerate} +} +\aref{Seidelmann, P.K.\ (ed), 1992. {\it Explanatory + Supplement to the Astronomical Almanac,}\/ ISBN~0-935702-68-7. + This contains references to the papers by Stephenson \& Morrison + and by McCarthy \& Babcock which describe the models used here.} +%----------------------------------------------------------------------- +\routine{SLA\_DTF2D}{Hour,Min,Sec to Days} +{ + \action{Convert hours, minutes, seconds to days (double precision).} + \call{CALL sla\_DTF2D (IHOUR, IMIN, SEC, DAYS, J)} +} +\args{GIVEN} +{ + \spec{IHOUR}{I}{hours} \\ + \spec{IMIN}{I}{minutes} \\ + \spec{SEC}{D}{seconds} +} +\args{RETURNED} +{ + \spec{DAYS}{D}{interval in days} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} 1 = IHOUR outside range 0-23} \\ + \spec{}{}{\hspace{1.5em} 2 = IMIN outside range 0-59} \\ + \spec{}{}{\hspace{1.5em} 3 = SEC outside range 0-59.999$\cdots$} +} +\notes +{ + \begin{enumerate} + \item The result is computed even if any of the range checks fail. + \item The sign must be dealt with outside this routine. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DTF2R}{Hour,Min,Sec to Radians} +{ + \action{Convert hours, minutes, seconds to radians (double precision).} + \call{CALL sla\_DTF2R (IHOUR, IMIN, SEC, RAD, J)} +} +\args{GIVEN} +{ + \spec{IHOUR}{I}{hours} \\ + \spec{IMIN}{I}{minutes} \\ + \spec{SEC}{D}{seconds} +} +\args{RETURNED} +{ + \spec{RAD}{D}{angle in radians} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} 1 = IHOUR outside range 0-23} \\ + \spec{}{}{\hspace{1.5em} 2 = IMIN outside range 0-59} \\ + \spec{}{}{\hspace{1.5em} 3 = SEC outside range 0-59.999$\cdots$} +} +\notes +{ + \begin{enumerate} + \item The result is computed even if any of the range checks fail. + \item The sign must be dealt with outside this routine. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DTP2S}{Tangent Plane to Spherical} +{ + \action{Transform tangent plane coordinates into spherical + coordinates (double precision)} + \call{CALL sla\_DTP2S (XI, ETA, RAZ, DECZ, RA, DEC)} +} +\args{GIVEN} +{ + \spec{XI,ETA}{D}{tangent plane rectangular coordinates (radians)} \\ + \spec{RAZ,DECZ}{D}{spherical coordinates of tangent point (radians)} +} +\args{RETURNED} +{ + \spec{RA,DEC}{D}{spherical coordinates (radians)} +} +\notes +{ + \begin{enumerate} + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item When working in \xyz\ rather than spherical coordinates, the + equivalent Cartesian routine sla\_DTP2V is available. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DTP2V}{Tangent Plane to Direction Cosines} +{ + \action{Given the tangent-plane coordinates of a star and the direction + cosines of the tangent point, determine the direction cosines + of the star + (double precision).} + \call{CALL sla\_DTP2V (XI, ETA, V0, V)} +} +\args{GIVEN} +{ + \spec{XI,ETA}{D}{tangent plane coordinates of star (radians)} \\ + \spec{V0}{D(3)}{direction cosines of tangent point} +} +\args{RETURNED} +{ + \spec{V}{D(3)}{direction cosines of star} +} +\notes +{ + \begin{enumerate} + \item If vector V0 is not of unit length, the returned vector V will + be wrong. + \item If vector V0 points at a pole, the returned vector V will be + based on the arbitrary assumption that $\alpha=0$ at + the tangent point. + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item This routine is the Cartesian equivalent of the routine sla\_DTP2S. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DTPS2C}{Plate centre from $\xi,\eta$ and $\alpha,\delta$} +{ + \action{From the tangent plane coordinates of a star of known \radec, + determine the \radec\ of the tangent point (double precision)} + \call{CALL sla\_DTPS2C (XI, ETA, RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2, N)} +} +\args{GIVEN} +{ + \spec{XI,ETA}{D}{tangent plane rectangular coordinates (radians)} \\ + \spec{RA,DEC}{D}{spherical coordinates (radians)} +} +\args{RETURNED} +{ + \spec{RAZ1,DECZ1}{D}{spherical coordinates of tangent point, + solution 1} \\ + \spec{RAZ2,DECZ2}{D}{spherical coordinates of tangent point, + solution 2} \\ + \spec{N}{I}{number of solutions:} \\ + \spec{}{}{\hspace{1em} 0 = no solutions returned (note 2)} \\ + \spec{}{}{\hspace{1em} 1 = only the first solution is useful (note 3)} \\ + \spec{}{}{\hspace{1em} 2 = there are two useful solutions (note 3)} +} +\notes +{ + \begin{enumerate} + \item The RAZ1 and RAZ2 values returned are in the range $0\!-\!2\pi$. + \item Cases where there is no solution can only arise near the poles. + For example, it is clearly impossible for a star at the pole + itself to have a non-zero $\xi$ value, and hence it is + meaningless to ask where the tangent point would have to be + to bring about this combination of $\xi$ and $\delta$. + \item Also near the poles, cases can arise where there are two useful + solutions. The argument N indicates whether the second of the + two solutions returned is useful. N\,=\,1 + indicates only one useful solution, the usual case; under + these circumstances, the second solution corresponds to the + ``over-the-pole'' case, and this is reflected in the values + of RAZ2 and DECZ2 which are returned. + \item The DECZ1 and DECZ2 values returned are in the range $\pm\pi$, + but in the ordinary, non-pole-crossing, case, the range is + $\pm\pi/2$. + \item RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2 are all in radians. + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item When working in \xyz\ rather than spherical coordinates, the + equivalent Cartesian routine sla\_DTPV2C is available. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DTPV2C}{Plate centre from $\xi,\eta$ and $x,y,z$} +{ + \action{From the tangent plane coordinates of a star of known + direction cosines, determine the direction cosines + of the tangent point (double precision)} + \call{CALL sla\_DTPV2C (XI, ETA, V, V01, V02, N)} +} +\args{GIVEN} +{ + \spec{XI,ETA}{D}{tangent plane coordinates of star (radians)} \\ + \spec{V}{D(3)}{direction cosines of star} +} +\args{RETURNED} +{ + \spec{V01}{D(3)}{direction cosines of tangent point, solution 1} \\ + \spec{V01}{D(3)}{direction cosines of tangent point, solution 2} \\ + \spec{N}{I}{number of solutions:} \\ + \spec{}{}{\hspace{1em} 0 = no solutions returned (note 2)} \\ + \spec{}{}{\hspace{1em} 1 = only the first solution is useful (note 3)} \\ + \spec{}{}{\hspace{1em} 2 = there are two useful solutions (note 3)} +} +\notes +{ + \begin{enumerate} + \item The vector V must be of unit length or the result will be wrong. + \item Cases where there is no solution can only arise near the poles. + For example, it is clearly impossible for a star at the pole + itself to have a non-zero XI value. + \item Also near the poles, cases can arise where there are two useful + solutions. The argument N indicates whether the second of the + two solutions returned is useful. + N\,=\,1 + indicates only one useful solution, the usual case; under these + circumstances, the second solution can be regarded as valid if + the vector V02 is interpreted as the ``over-the-pole'' case. + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item This routine is the Cartesian equivalent of the routine sla\_DTPS2C. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DTT}{TT minus UTC} +{ + \action{Compute $\Delta$TT, the increment to be applied to + Coordinated Universal Time UTC to give + Terrestrial Time TT.} + \call{D~=~sla\_DTT (DJU)} +} +\args{GIVEN} +{ + \spec{DJU}{D}{UTC date as a modified JD (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{sla\_DTT}{D}{TT$-$UTC in seconds} +} +\notes +{ + \begin{enumerate} + \item The UTC is specified to be a date rather than a time to indicate + that care needs to be taken not to specify an instant which lies + within a leap second. Though in most cases UTC can include the + fractional part, correct behaviour on the day of a leap second + can be guaranteed only up to the end of the second + $23^{\rm h}\,59^{\rm m}\,59^{\rm s}$. + \item Pre 1972 January 1 a fixed value of 10 + ET$-$TAI is returned. + \item TT is one interpretation of the defunct timescale + {\it Ephemeris Time}, ET. + \item See also the routine sla\_DT, which roughly estimates ET$-$UT for + historical epochs. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DV2TP}{Direction Cosines to Tangent Plane} +{ + \action{Given the direction cosines of a star and of the tangent point, + determine the star's tangent-plane coordinates + (double precision).} + \call{CALL sla\_DV2TP (V, V0, XI, ETA, J)} +} +\args{GIVEN} +{ + \spec{V}{D(3)}{direction cosines of star} \\ + \spec{V0}{D(3)}{direction cosines of tangent point} +} +\args{RETURNED} +{ + \spec{XI,ETA}{D}{tangent plane coordinates (radians)} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK, star on tangent plane} \\ + \spec{}{}{\hspace{1.5em} 1 = error, star too far from axis} \\ + \spec{}{}{\hspace{1.5em} 2 = error, antistar on tangent plane} \\ + \spec{}{}{\hspace{1.5em} 3 = error, antistar too far from axis} +} +\notes +{ + \begin{enumerate} + \item If vector V0 is not of unit length, or if vector V is of zero + length, the results will be wrong. + \item If V0 points at a pole, the returned $\xi,\eta$ + will be based on the + arbitrary assumption that $\alpha=0$ at the tangent point. + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item This routine is the Cartesian equivalent of the routine sla\_DS2TP. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_DVDV}{Scalar Product} +{ + \action{Scalar product of two 3-vectors (double precision).} + \call{D~=~sla\_DVDV (VA, VB)} +} +\args{GIVEN} +{ + \spec{VA}{D(3)}{first vector} \\ + \spec{VB}{D(3)}{second vector} +} +\args{RETURNED} +{ + \spec{sla\_DVDV}{D}{scalar product VA.VB} +} +%----------------------------------------------------------------------- +\routine{SLA\_DVN}{Normalize Vector} +{ + \action{Normalize a 3-vector, also giving the modulus (double precision).} + \call{CALL sla\_DVN (V, UV, VM)} +} +\args{GIVEN} +{ + \spec{V}{D(3)}{vector} +} +\args{RETURNED} +{ + \spec{UV}{D(3)}{unit vector in direction of V} \\ + \spec{VM}{D}{modulus of V} +} +\anote{If the modulus of V is zero, UV is set to zero as well.} +%----------------------------------------------------------------------- +\routine{SLA\_DVXV}{Vector Product} +{ + \action{Vector product of two 3-vectors (double precision).} + \call{CALL sla\_DVXV (VA, VB, VC)} +} +\args{GIVEN} +{ + \spec{VA}{D(3)}{first vector} \\ + \spec{VB}{D(3)}{second vector} +} +\args{RETURNED} +{ + \spec{VC}{D(3)}{vector product VA$\times$VB} +} +%----------------------------------------------------------------------- +\routine{SLA\_E2H}{$h,\delta$ to Az,El} +{ + \action{Equatorial to horizon coordinates + (single precision).} + \call{CALL sla\_DE2H (HA, DEC, PHI, AZ, EL)} +} +\args{GIVEN} +{ + \spec{HA}{R}{hour angle (radians)} \\ + \spec{DEC}{R}{declination (radians)} \\ + \spec{PHI}{R}{latitude (radians)} +} +\args{RETURNED} +{ + \spec{AZ}{R}{azimuth (radians)} \\ + \spec{EL}{R}{elevation (radians)} +} +\notes +{ + \begin{enumerate} + \item Azimuth is returned in the range $0\!-\!2\pi$; north is zero, + and east is $+\pi/2$. Elevation is returned in the range + $\pm\pi$. + \item The latitude must be geodetic. In critical applications, + corrections for polar motion should be applied. + \item In some applications it will be important to specify the + correct type of hour angle and declination in order to + produce the required type of azimuth and elevation. In + particular, it may be important to distinguish between + elevation as affected by refraction, which would + require the {\it observed} \hadec, and the elevation + {\it in vacuo}, which would require the {\it topocentric} + \hadec. + If the effects of diurnal aberration can be neglected, the + {\it apparent} \hadec\ may be used instead of the topocentric + \hadec. + \item No range checking of arguments is carried out. + \item In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude, and (for tracking a star) + sine and cosine of declination. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_EARTH}{Approx Earth Pos/Vel} +{ + \action{Approximate heliocentric position and velocity of the Earth + (single precision).} + \call{CALL sla\_EARTH (IY, ID, FD, PV)} +} +\args{GIVEN} +{ + \spec{IY}{I}{year} \\ + \spec{ID}{I}{day in year (1 = Jan 1st)} \\ + \spec{FD}{R}{fraction of day} +} +\args{RETURNED} +{ + \spec{PV}{R(6)}{Earth \xyzxyzd\ (AU, AU~s$^{-1}$)} +} +\notes +{ + \begin{enumerate} + \item The date and time is TDB (loosely ET) in a Julian calendar + which has been aligned to the ordinary Gregorian + calendar for the interval 1900~March~1 to 2100~February~28. + The year and day can be obtained by calling sla\_CALYD or + sla\_CLYD. + \item The Earth heliocentric 6-vector is referred to the + FK4 mean equator and equinox of date. + \item Maximum/RMS errors 1950-2050: + \begin{itemize} + \item 13/5~$\times10^{-5}$~AU = 19200/7600~km in position + \item 47/26~$\times10^{-10}$~AU~s$^{-1}$ = + 0.0070/0.0039~km~s$^{-1}$ in speed + \end{itemize} + \item More accurate results are obtainable with the routine sla\_EVP. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_ECLEQ}{Ecliptic to Equatorial} +{ + \action{Transformation from ecliptic longitude and latitude to + J2000.0 \radec.} + \call{CALL sla\_ECLEQ (DL, DB, DATE, DR, DD)} +} +\args{GIVEN} +{ + \spec{DL,DB}{D}{ecliptic longitude and latitude + (mean of date, IAU 1980 theory, radians)} \\ + \spec{DATE}{D}{TDB (formerly ET) as Modified Julian Date + (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{DR,DD}{D}{J2000.0 mean \radec\ (radians)} +} +%----------------------------------------------------------------------- +\routine{SLA\_ECMAT}{Form $\alpha,\delta\rightarrow\lambda,\beta$ Matrix} +{ + \action{Form the equatorial to ecliptic rotation matrix (IAU 1980 theory).} + \call{CALL sla\_ECMAT (DATE, RMAT)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{TDB (formerly ET) as Modified Julian Date + (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{RMAT}{D(3,3)}{rotation matrix} +} +\notes +{ + \begin{enumerate} + \item RMAT is matrix {\bf M} in the expression + {\bf v}$_{ecl}$~=~{\bf M}$\cdot${\bf v}$_{equ}$. + \item The equator, equinox and ecliptic are mean of date. + \end{enumerate} +} +\aref{Murray, C.A., {\it Vectorial Astrometry}, section 4.3.} +%----------------------------------------------------------------------- +\routine{SLA\_ECOR}{RV \& Time Corrns to Sun} +{ + \action{Component of Earth orbit velocity and heliocentric + light time in a given direction.} + \call{CALL sla\_ECOR (RM, DM, IY, ID, FD, RV, TL)} +} +\args{GIVEN} +{ + \spec{RM,DM}{R}{mean \radec\ of date (radians)} \\ + \spec{IY}{I}{year} \\ + \spec{ID}{I}{day in year (1 = Jan 1st)} \\ + \spec{FD}{R}{fraction of day} +} +\args{RETURNED} +{ + \spec{RV}{R}{component of Earth orbital velocity (km~s$^{-1}$)} \\ + \spec{TL}{R}{component of heliocentric light time (s)} +} +\notes +{ + \begin{enumerate} + \item The date and time is TDB (loosely ET) in a Julian calendar + which has been aligned to the ordinary Gregorian + calendar for the interval 1900 March 1 to 2100 February 28. + The year and day can be obtained by calling sla\_CALYD or + sla\_CLYD. + \item Sign convention: + \begin{itemize} + \item The velocity component is +ve when the + Earth is receding from + the given point on the sky. + \item The light time component is +ve + when the Earth lies between the Sun and + the given point on the sky. + \end{itemize} + \item Accuracy: + \begin{itemize} + \item The velocity component is usually within 0.004~km~s$^{-1}$ + of the correct value and is never in error by more than + 0.007~km~s$^{-1}$. + \item The error in light time correction is about + \tsec{0}{03} at worst, + but is usually better than \tsec{0}{01}. + \end{itemize} + For applications requiring higher accuracy, see the sla\_EVP routine. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_EG50}{B1950 $\alpha,\delta$ to Galactic} +{ + \action{Transformation from B1950.0 FK4 equatorial coordinates to + IAU 1958 galactic coordinates.} + \call{CALL sla\_EG50 (DR, DD, DL, DB)} +} +\args{GIVEN} +{ + \spec{DR,DD}{D}{B1950.0 \radec\ (radians)} +} +\args{RETURNED} +{ + \spec{DL,DB}{D}{galactic longitude and latitude \gal\ (radians)} +} +\anote{The equatorial coordinates are B1950.0 FK4. Use the + routine sla\_EQGAL if conversion from J2000.0 FK5 coordinates + is required.} +\aref{Blaauw {\it et al.}, 1960, {\it Mon.Not.R.astr.Soc.}, + {\bf 121}, 123.} +%----------------------------------------------------------------------- +\routine{SLA\_EL2UE}{Conventional to Universal Elements} +{ + \action{Transform conventional osculating orbital elements + into ``universal'' form.} + \call{CALL sla\_EL2UE (\vtop{ + \hbox{DATE, JFORM, EPOCH, ORBINC, ANODE,} + \hbox{PERIH, AORQ, E, AORL, DM,} + \hbox{U, JSTAT)}}} +} +\args{GIVEN} +{ + \spec{DATE}{D}{epoch (TT MJD) of osculation (Note~3)} \\ + \spec{JFORM}{I}{choice of element set (1-3; Note~6)} \\ + \spec{EPOCH}{D}{epoch of elements ($t_0$ or $T$, TT MJD)} \\ + \spec{ORBINC}{D}{inclination ($i$, radians)} \\ + \spec{ANODE}{D}{longitude of the ascending node ($\Omega$, radians)} \\ + \spec{PERIH}{D}{longitude or argument of perihelion + ($\varpi$ or $\omega$,} \\ + \spec{}{}{\hspace{1.5em} radians)} \\ + \spec{AORQ}{D}{mean distance or perihelion distance ($a$ or $q$, AU)} \\ + \spec{E}{D}{eccentricity ($e$)} \\ + \spec{AORL}{D}{mean anomaly or longitude + ($M$ or $L$, radians,} \\ + \spec{}{}{\hspace{1.5em} JFORM=1,2 only)} \\ + \spec{DM}{D}{daily motion ($n$, radians, JFORM=1 only)} +} +\args{RETURNED} +{ + \spec{U}{D(13)}{universal orbital elements (Note~1)} \\ + \specel {(1)} {combined mass ($M+m$)} \\ + \specel {(2)} {total energy of the orbit ($\alpha$)} \\ + \specel {(3)} {reference (osculating) epoch ($t_0$)} \\ + \specel {(4-6)} {position at reference epoch (${\rm \bf r}_0$)} \\ + \specel {(7-9)} {velocity at reference epoch (${\rm \bf v}_0$)} \\ + \specel {(10)} {heliocentric distance at reference epoch} \\ + \specel {(11)} {${\rm \bf r}_0.{\rm \bf v}_0$} \\ + \specel {(12)} {date ($t$)} \\ + \specel {(13)} {universal eccentric anomaly ($\psi$) of date, + approx} \\ \\ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{1.95em} 0 = OK} \\ + \spec{}{}{\hspace{1.2em} $-$1 = illegal JFORM} \\ + \spec{}{}{\hspace{1.2em} $-$2 = illegal E} \\ + \spec{}{}{\hspace{1.2em} $-$3 = illegal AORQ} \\ + \spec{}{}{\hspace{1.2em} $-$4 = illegal DM} \\ + \spec{}{}{\hspace{1.2em} $-$5 = numerical error} +} +\notes +{ + \begin{enumerate} + \item The ``universal'' elements are those which define the orbit for + the purposes of the method of universal variables (see reference). + They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i)~$\alpha$, which is proportional to the total energy of the + orbit, (ii)~the heliocentric distance at epoch, + (iii)~the outwards component of the velocity at the given epoch, + (iv)~an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v)~that date. + \item The companion routine is sla\_UE2PV. This takes the set of numbers + that the present routine outputs and uses them to derive the + object's position and velocity. A single prediction requires one + call to the present routine followed by one call to sla\_UE2PV; + for convenience, the two calls are packaged as the routine + sla\_PLANEL. Multiple predictions may be made by again calling the + present routine once, but then calling sla\_UE2PV multiple times, + which is faster than multiple calls to sla\_PLANEL. + \item DATE is the epoch of osculation. It is in the TT timescale + (formerly Ephemeris Time, ET) and is a Modified Julian Date + (JD$-$2400000.5). + \item The supplied orbital elements are with respect to the J2000 + ecliptic and equinox. The position and velocity parameters + returned in the array U are with respect to the mean equator and + equinox of epoch J2000, and are for the perihelion prior to the + specified epoch. + \item The universal elements returned in the array U are in canonical + units (solar masses, AU and canonical days). + \item Three different element-format options are supported, as + follows. \\ + + JFORM=1, suitable for the major planets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> longitude of perihelion $\varpi$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e < 1 )$ \\ + \> AORL \> = \> mean longitude $L$ (radians) \\ + \> DM \> = \> daily motion $n$ (radians) + \end{tabbing} + + JFORM=2, suitable for minor planets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e < 1 )$ \\ + \> AORL \> = \> mean anomaly $M$ (radians) + \end{tabbing} + + JFORM=3, suitable for comets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of perihelion $T$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> perihelion distance $q$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e \leq 10 )$ + \end{tabbing} + \item Unused elements (DM for JFORM=2, AORL and DM for JFORM=3) are + not accessed. + \item The algorithm was originally adapted from the EPHSLA program of + D.\,H.\,P.\,Jones (private communication, 1996). The method + is based on Stumpff's Universal Variables. + \end{enumerate} +} +\aref{Everhart, E. \& Pitkin, E.T., Am.~J.~Phys.~51, 712, 1983.} +%------------------------------------------------------------------------------ +\routine{SLA\_EPB}{MJD to Besselian Epoch} +{ + \action{Conversion of Modified Julian Date to Besselian Epoch.} + \call{D~=~sla\_EPB (DATE)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{Modified Julian Date (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{sla\_EPB}{D}{Besselian Epoch} +} +\aref{Lieske, J.H., 1979, {\it Astr.Astrophys.}\ {\bf 73}, 282.} +%----------------------------------------------------------------------- +\routine{SLA\_EPB2D}{Besselian Epoch to MJD} +{ + \action{Conversion of Besselian Epoch to Modified Julian Date.} + \call{D~=~sla\_EPB2D (EPB)} +} +\args{GIVEN} +{ + \spec{EPB}{D}{Besselian Epoch} +} +\args{RETURNED} +{ + \spec{sla\_EPB2D}{D}{Modified Julian Date (JD$-$2400000.5)} +} +\aref{Lieske, J.H., 1979. {\it Astr.Astrophys.}\ {\bf 73}, 282.} +%----------------------------------------------------------------------- +\routine{SLA\_EPCO}{Convert Epoch to B or J} +{ + \action{Convert an epoch to Besselian or Julian to match another one.} + \call{D~=~sla\_EPCO (K0, K, E)} + +} +\args{GIVEN} +{ + \spec{K0}{C}{form of result: `B'=Besselian, `J'=Julian} \\ + \spec{K}{C}{form of given epoch: `B' or `J'} \\ + \spec{E}{D}{epoch} +} +\args{RETURNED} +{ + \spec{sla\_EPCO}{D}{the given epoch converted as necessary} +} +\notes +{ + \begin{enumerate} + \item The result is always either equal to or very close to + the given epoch E. The routine is required only in + applications where punctilious treatment of heterogeneous + mixtures of star positions is necessary. + \item K0 and K are not validated. They are interpreted as follows: + \begin{itemize} + \item If K0 and K are the same, the result is E. + \item If K0 is `B' and K isn't, the conversion is J to B. + \item In all other cases, the conversion is B to J. + \end{itemize} + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_EPJ}{MJD to Julian Epoch} +{ + \action{Convert Modified Julian Date to Julian Epoch.} + \call{D~=~sla\_EPJ (DATE)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{Modified Julian Date (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{sla\_EPJ}{D}{Julian Epoch} +} +\aref{Lieske, J.H., 1979.\ {\it Astr.Astrophys.}, {\bf 73}, 282.} +%----------------------------------------------------------------------- +\routine{SLA\_EPJ2D}{Julian Epoch to MJD} +{ + \action{Convert Julian Epoch to Modified Julian Date.} + \call{D~=~sla\_EPJ2D (EPJ)} +} +\args{GIVEN} +{ + \spec{EPJ}{D}{Julian Epoch} +} +\args{RETURNED} +{ + \spec{sla\_EPJ2D}{D}{Modified Julian Date (JD$-$2400000.5)} +} +\aref{Lieske, J.H., 1979.\ {\it Astr.Astrophys.}, {\bf 73}, 282.} +%----------------------------------------------------------------------- +\routine{SLA\_EQECL}{J2000 $\alpha,\delta$ to Ecliptic} +{ + \action{Transformation from J2000.0 equatorial coordinates to + ecliptic longitude and latitude.} + \call{CALL sla\_EQECL (DR, DD, DATE, DL, DB)} +} +\args{GIVEN} +{ + \spec{DR,DD}{D}{J2000.0 mean \radec\ (radians)} \\ + \spec{DATE}{D}{TDB (formerly ET) as Modified Julian Date (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{DL,DB}{D}{ecliptic longitude and latitude + (mean of date, IAU 1980 theory, radians)} +} +%----------------------------------------------------------------------- +\routine{SLA\_EQEQX}{Equation of the Equinoxes} +{ + \action{Equation of the equinoxes (IAU 1994).} + \call{D~=~sla\_EQEQX (DATE)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{TDB (formerly ET) as Modified Julian Date (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{sla\_EQEQX}{D}{The equation of the equinoxes (radians)} +} +\notes{ + \begin{enumerate} + \item The equation of the equinoxes is defined here as GAST~$-$~GMST: + it is added to a {\it mean}\/ sidereal time to give the + {\it apparent}\/ sidereal time. + \item The change from the classic ``textbook'' expression + $\Delta\psi\,cos\,\epsilon$ occurred with IAU Resolution C7, + Recommendation~3 (1994). The new formulation takes into + account cross-terms between the various precession and + nutation quantities, amounting to about 3~milliarcsec. + The transition from the old to the new model officially + takes place on 1997 February~27. + \end{enumerate} +} +\aref{Capitaine, N.\ \& Gontier, A.-M.\ (1993), + {\it Astron. Astrophys.}, + {\bf 275}, 645-650.} +%----------------------------------------------------------------------- +\routine{SLA\_EQGAL}{J2000 $\alpha,\delta$ to Galactic} +{ + \action{Transformation from J2000.0 FK5 equatorial coordinates to + IAU 1958 galactic coordinates.} + \call{CALL sla\_EQGAL (DR, DD, DL, DB)} +} +\args{GIVEN} +{ + \spec{DR,DD}{D}{J2000.0 \radec\ (radians)} +} +\args{RETURNED} +{ + \spec{DL,DB}{D}{galactic longitude and latitude \gal\ (radians)} +} +\anote{The equatorial coordinates are J2000.0 FK5. Use the routine + sla\_EG50 if conversion from B1950.0 FK4 coordinates is required.} +\aref{Blaauw {\it et al.}, 1960, {\it Mon.Not.R.astr.Soc.}, + {\bf 121}, 123.} +%----------------------------------------------------------------------- +\routine{SLA\_ETRMS}{E-terms of Aberration} +{ + \action{Compute the E-terms vector -- the part of the annual + aberration which arises from the eccentricity of the + Earth's orbit.} + \call{CALL sla\_ETRMS (EP, EV)} +} +\args{GIVEN} +{ + \spec{EP}{D}{Besselian epoch} +} +\args{RETURNED} +{ + \spec{EV}{D(3)}{E-terms as $[\Delta x, \Delta y, \Delta z\,]$} +} +\anote{Note the use of the J2000 aberration constant (\arcsec{20}{49552}). + This is a reflection of the fact that the E-terms embodied in + existing star catalogues were computed from a variety of + aberration constants. Rather than adopting one of the old + constants the latest value is used here.} +\refs +{ + \begin{enumerate} + \item Smith, C.A.\ {\it et al.}, 1989. {\it Astr.J.}\ {\bf 97}, 265. + \item Yallop, B.D.\ {\it et al.}, 1989. {\it Astr.J.}\ {\bf 97}, 274. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_EULER}{Rotation Matrix from Euler Angles} +{ + \action{Form a rotation matrix from the Euler angles -- three + successive rotations about specified Cartesian axes + (single precision).} + \call{CALL sla\_EULER (ORDER, PHI, THETA, PSI, RMAT)} +} +\args{GIVEN} +{ + \spec{ORDER}{C*(*)}{specifies about which axes the rotations occur} \\ + \spec{PHI}{R}{1st rotation (radians)} \\ + \spec{THETA}{R}{2nd rotation (radians)} \\ + \spec{PSI}{R}{3rd rotation (radians)} +} +\args{RETURNED} +{ + \spec{RMAT}{R(3,3)}{rotation matrix} +} +\notes +{ + \begin{enumerate} + \item A rotation is positive when the reference frame rotates + anticlockwise as seen looking towards the origin from the + positive region of the specified axis. + \item The characters of ORDER define which axes the three successive + rotations are about. A typical value is `ZXZ', indicating that + RMAT is to become the direction cosine matrix corresponding to + rotations of the reference frame through PHI radians about the + old {\it z}-axis, followed by THETA radians about the resulting + {\it x}-axis, + then PSI radians about the resulting {\it z}-axis. In detail: + \begin{itemize} + \item The axis names can be any of the following, in any order or + combination: X, Y, Z, uppercase or lowercase, 1, 2, 3. Normal + axis labelling/numbering conventions apply; + the {\it xyz} ($\equiv123$) + triad is right-handed. Thus, the `ZXZ' example given above + could be written `zxz' or `313' (or even `ZxZ' or `3xZ'). + \item ORDER is terminated by length or by the first unrecognized + character. + \item Fewer than three rotations are acceptable, in which case + the later angle arguments are ignored. + \end{itemize} + \item Zero rotations produces a unit RMAT. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_EVP}{Earth Position \& Velocity} +{ + \action{Barycentric and heliocentric velocity and position of the Earth.} + \call{CALL sla\_EVP (DATE, DEQX, DVB, DPB, DVH, DPH)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{TDB (formerly ET) as a Modified Julian Date + (JD$-$2400000.5)} \\ + \spec{DEQX}{D}{Julian Epoch ({\it e.g.}\ 2000D0) of mean equator and + equinox of the vectors returned. If DEQX~$<0$, + all vectors are referred to the mean equator and + equinox (FK5) of date DATE.} +} +\args{RETURNED} +{ + \spec{DVB}{D(3)}{barycentric \xyzd, AU~s$^{-1}$} \\ + \spec{DPB}{D(3)}{barycentric \xyz, AU} \\ + \spec{DVH}{D(3)}{heliocentric \xyzd, AU~s$^{-1}$} \\ + \spec{DPH}{D(3)}{heliocentric \xyz, AU} +} +\notes +{ + \begin{enumerate} + \item This routine is used when accuracy is more important + than CPU time, yet the extra complication of reading a + pre-computed ephemeris is not justified. The maximum + deviations from the JPL~DE96 ephemeris are as follows: + \begin{itemize} + \item velocity (barycentric or heliocentric): 420~mm~s$^{-1}$ + \item position (barycentric): 6900~km + \item position (heliocentric): 1600~km + \end{itemize} + \item The routine is an adaption of the BARVEL and BARCOR + subroutines of P.Stumpff, which are described in + {\it Astr.Astrophys.Suppl.Ser.}\ {\bf 41}, 1-8 (1980). + Most of the changes are merely cosmetic and do not affect + the results at all. However, some adjustments have been + made so as to give results that refer to the new (IAU 1976 + `FK5') equinox and precession, although the differences these + changes make relative to the results from Stumpff's original + `FK4' version are smaller than the inherent accuracy of the + algorithm. One minor shortcoming in the original routines + that has {\bf not} been corrected is that slightly better + numerical accuracy could be achieved if the various polynomial + evaluations were to be so arranged that the smallest terms were + computed first. Note also that one of Stumpff's precession + constants differs by \arcsec{0}{001} from the value given in the + {\it Explanatory Supplement}. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_FITXY}{Fit Linear Model to Two \xy\ Sets} +{ + \action{Fit a linear model to relate two sets of \xy\ coordinates.} + \call{CALL sla\_FITXY (ITYPE,NP,XYE,XYM,COEFFS,J)} +} +\args{GIVEN} +{ + \spec{ITYPE}{I}{type of model: 4 or 6 (note 1)} \\ + \spec{NP}{I}{number of samples (note 2)} \\ + \spec{XYE}{D(2,NP)}{expected \xy\ for each sample} \\ + \spec{XYM}{D(2,NP)}{measured \xy\ for each sample} +} +\args{RETURNED} +{ + \spec{COEFFS}{D(6)}{coefficients of model (note 3)} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK} \\ + \spec{}{}{\hspace{0.7em} $-$1 = illegal ITYPE} \\ + \spec{}{}{\hspace{0.7em} $-$2 = insufficient data} \\ + \spec{}{}{\hspace{0.7em} $-$3 = singular solution} +} +\notes +{ + \begin{enumerate} + \item ITYPE, which must be either 4 or 6, selects the type of model + fitted. Both allowed ITYPE values produce a model COEFFS which + consists of six coefficients, namely the zero points and, for + each of XE and YE, the coefficient of XM and YM. For ITYPE=6, + all six coefficients are independent, modelling squash and shear + as well as origin, scale, and orientation. However, ITYPE=4 + selects the {\it solid body rotation}\/ option; the model COEFFS + still consists of the same six coefficients, but now two of + them are used twice (appropriately signed). Origin, scale + and orientation are still modelled, but not squash or shear -- + the units of X and Y have to be the same. + \item For NC=4, NP must be at least 2. For NC=6, NP must be at + least 3. + \item The model is returned in the array COEFFS. Naming the + six elements of COEFFS $a,b,c,d,e$ \& $f$, + the model transforms {\it measured}\/ coordinates + $[x_{m},y_{m}\,]$ into {\it expected}\/ coordinates + $[x_{e},y_{e}\,]$ as follows: + \begin{verse} + $x_{e} = a + bx_{m} + cy_{m}$ \\ + $y_{e} = d + ex_{m} + fy_{m}$ + \end{verse} + For the {\it solid body rotation}\/ option (ITYPE=4), the + magnitudes of $b$ and $f$, and of $c$ and $e$, are equal. The + signs of these coefficients depend on whether there is a + sign reversal between $[x_{e},y_{e}]$ and $[x_{m},y_{m}]$; + fits are performed + with and without a sign reversal and the best one chosen. + \item Error status values J=$-$1 and $-$2 leave COEFFS unchanged; + if J=$-$3 COEFFS may have been changed. + \item See also sla\_PXY, sla\_INVF, sla\_XY2XY, sla\_DCMPF. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_FK425}{FK4 to FK5} +{ + \action{Convert B1950.0 FK4 star data to J2000.0 FK5. + This routine converts stars from the old, Bessel-Newcomb, FK4 + system to the new, IAU~1976, FK5, Fricke system. The precepts + of Smith~{\it et~al.}\ (see reference~1) are followed, + using the implementation + by Yallop~{\it et~al.}\ (reference~2) of a matrix method + due to Standish. + Kinoshita's development of Andoyer's post-Newcomb precession is + used. The numerical constants from + Seidelmann~{\it et~al.}\ (reference~3) are used canonically.} + \call{CALL sla\_FK425 (\vtop{ + \hbox{R1950,D1950,DR1950,DD1950,P1950,V1950,} + \hbox{R2000,D2000,DR2000,DD2000,P2000,V2000)}}} +} +\args{GIVEN} +{ + \spec{R1950}{D}{B1950.0 $\alpha$ (radians)} \\ + \spec{D1950}{D}{B1950.0 $\delta$ (radians)} \\ + \spec{DR1950}{D}{B1950.0 proper motion in $\alpha$ + (radians per tropical year)} \\ + \spec{DD1950}{D}{B1950.0 proper motion in $\delta$ + (radians per tropical year)} \\ + \spec{P1950}{D}{B1950.0 parallax (arcsec)} \\ + \spec{V1950}{D}{B1950.0 radial velocity (km~s$^{-1}$, +ve = moving away)} +} +\args{RETURNED} +{ + \spec{R2000}{D}{J2000.0 $\alpha$ (radians)} \\ + \spec{D2000}{D}{J2000.0 $\delta$ (radians)} \\ + \spec{DR2000}{D}{J2000.0 proper motion in $\alpha$ + (radians per Julian year)} \\ + \spec{DD2000}{D}{J2000.0 proper motion in $\delta$ + (radians per Julian year)} \\ + \spec{P2000}{D}{J2000.0 parallax (arcsec)} \\ + \spec{V2000}{D}{J2000.0 radial velocity (km~s$^{-1}$, +ve = moving away)} +} +\notes +{ + \begin{enumerate} + \item The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are per year rather than per century. + \item Conversion from Besselian epoch 1950.0 to Julian epoch + 2000.0 only is provided for. Conversions involving other + epochs will require use of the appropriate precession, + proper motion, and E-terms routines before and/or after FK425 + is called. + \item In the FK4 catalogue the proper motions of stars within + $10^{\circ}$ of the poles do not include the {\it differential + E-terms}\/ effect and should, strictly speaking, be handled + in a different manner from stars outside these regions. + However, given the general lack of homogeneity of the star + data available for routine astrometry, the difficulties of + handling positions that may have been determined from + astrometric fields spanning the polar and non-polar regions, + the likelihood that the differential E-terms effect was not + taken into account when allowing for proper motion in past + astrometry, and the undesirability of a discontinuity in + the algorithm, the decision has been made in this routine to + include the effect of differential E-terms on the proper + motions for all stars, whether polar or not. At epoch J2000, + and measuring on the sky rather than in terms of $\Delta\alpha$, + the errors resulting from this simplification are less than + 1~milliarcsecond in position and 1~milliarcsecond per + century in proper motion. + \item See also sla\_FK45Z, sla\_FK524, sla\_FK54Z. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item Smith, C.A.\ {\it et al.}, 1989.\ {\it Astr.J.}\ {\bf 97}, 265. + \item Yallop, B.D.\ {\it et al.}, 1989.\ {\it Astr.J.}\ {\bf 97}, 274. + \item Seidelmann, P.K.\ (ed), 1992. {\it Explanatory + Supplement to the Astronomical Almanac,}\/ ISBN~0-935702-68-7. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_FK45Z}{FK4 to FK5, no P.M. or Parallax} +{ + \action{Convert B1950.0 FK4 star data to J2000.0 FK5 assuming zero + proper motion in the FK5 frame. + This routine converts stars from the old, Bessel-Newcomb, FK4 + system to the new, IAU~1976, FK5, Fricke system, in such a + way that the FK5 proper motion is zero. Because such a star + has, in general, a non-zero proper motion in the FK4 system, + the routine requires the epoch at which the position in the + FK4 system was determined. The method is from appendix~2 of + reference~1, but using the constants of reference~4.} + \call{CALL sla\_FK45Z (R1950,D1950,BEPOCH,R2000,D2000)} +} +\args{GIVEN} +{ + \spec{R1950}{D}{B1950.0 FK4 $\alpha$ at epoch BEPOCH (radians)} \\ + \spec{D1950}{D}{B1950.0 FK4 $\delta$ at epoch BEPOCH (radians)} \\ + \spec{BEPOCH}{D}{Besselian epoch ({\it e.g.}\ 1979.3D0)} +} +\args{RETURNED} +{ + \spec{R2000}{D}{J2000.0 FK5 $\alpha$ (radians)} \\ + \spec{D2000}{D}{J2000.0 FK5 $\delta$ (radians)} +} +\notes +{ + \begin{enumerate} + \item The epoch BEPOCH is strictly speaking Besselian, but + if a Julian epoch is supplied the result will be + affected only to a negligible extent. + \item Conversion from Besselian epoch 1950.0 to Julian epoch + 2000.0 only is provided for. Conversions involving other + epochs will require use of the appropriate precession, + proper motion, and E-terms routines before and/or + after FK45Z is called. + \item In the FK4 catalogue the proper motions of stars within + $10^{\circ}$ of the poles do not include the {\it differential + E-terms}\/ effect and should, strictly speaking, be handled + in a different manner from stars outside these regions. + However, given the general lack of homogeneity of the star + data available for routine astrometry, the difficulties of + handling positions that may have been determined from + astrometric fields spanning the polar and non-polar regions, + the likelihood that the differential E-terms effect was not + taken into account when allowing for proper motion in past + astrometry, and the undesirability of a discontinuity in + the algorithm, the decision has been made in this routine to + include the effect of differential E-terms on the proper + motions for all stars, whether polar or not. At epoch 2000, + and measuring on the sky rather than in terms of $\Delta\alpha$, + the errors resulting from this simplification are less than + 1~milliarcsecond in position and 1~milliarcsecond per + century in proper motion. + \item See also sla\_FK425, sla\_FK524, sla\_FK54Z. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item Aoki, S., {\it et al.}, 1983.\ {\it Astr.Astrophys.}, {\bf 128}, 263. + \item Smith, C.A.\ {\it et al.}, 1989.\ {\it Astr.J.}\ {\bf 97}, 265. + \item Yallop, B.D.\ {\it et al.}, 1989.\ {\it Astr.J.}\ {\bf 97}, 274. + \item Seidelmann, P.K.\ (ed), 1992. {\it Explanatory + Supplement to the Astronomical Almanac,}\/ ISBN~0-935702-68-7. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_FK524}{FK5 to FK4} +{ + \action{Convert J2000.0 FK5 star data to B1950.0 FK4. + This routine converts stars from the new, IAU~1976, FK5, Fricke + system, to the old, Bessel-Newcomb, FK4 system. + The precepts of Smith~{\it et~al.}\ (reference~1) are followed, + using the implementation by Yallop~{\it et~al.}\ (reference~2) + of a matrix method due to Standish. Kinoshita's development of + Andoyer's post-Newcomb precession is used. The numerical + constants from Seidelmann~{\it et~al.}\ (reference~3) are + used canonically.} + \call{CALL sla\_FK524 (\vtop{ + \hbox{R2000,D2000,DR2000,DD2000,P2000,V2000,} + \hbox{R1950,D1950,DR1950,DD1950,P1950,V1950)}}} +} +\args{GIVEN} +{ + \spec{R2000}{D}{J2000.0 $\alpha$ (radians)} \\ + \spec{D2000}{D}{J2000.0 $\delta$ (radians)} \\ + \spec{DR2000}{D}{J2000.0 proper motion in $\alpha$ + (radians per Julian year)} \\ + \spec{DD2000}{D}{J2000.0 proper motion in $\delta$ + (radians per Julian year)} \\ + \spec{P2000}{D}{J2000.0 parallax (arcsec)} \\ + \spec{V2000}{D}{J2000 radial velocity (km~s$^{-1}$, +ve = moving away)} +} +\args{RETURNED} +{ + \spec{R1950}{D}{B1950.0 $\alpha$ (radians)} \\ + \spec{D1950}{D}{B1950.0 $\delta$ (radians)} \\ + \spec{DR1950}{D}{B1950.0 proper motion in $\alpha$ + (radians per tropical year)} \\ + \spec{DD1950}{D}{B1950.0 proper motion in $\delta$ + (radians per tropical year)} \\ + \spec{P1950}{D}{B1950.0 parallax (arcsec)} \\ + \spec{V1950}{D}{radial velocity (km~s$^{-1}$, +ve = moving away)} +} +\notes +{ + \begin{enumerate} + \item The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are per year rather than per century. + \item Note that conversion from Julian epoch 2000.0 to Besselian + epoch 1950.0 only is provided for. Conversions involving + other epochs will require use of the appropriate precession, + proper motion, and E-terms routines before and/or after + FK524 is called. + \item In the FK4 catalogue the proper motions of stars within + $10^{\circ}$ of the poles do not include the {\it differential + E-terms}\/ effect and should, strictly speaking, be handled + in a different manner from stars outside these regions. + However, given the general lack of homogeneity of the star + data available for routine astrometry, the difficulties of + handling positions that may have been determined from + astrometric fields spanning the polar and non-polar regions, + the likelihood that the differential E-terms effect was not + taken into account when allowing for proper motion in past + astrometry, and the undesirability of a discontinuity in + the algorithm, the decision has been made in this routine to + include the effect of differential E-terms on the proper + motions for all stars, whether polar or not. At epoch 2000, + and measuring on the sky rather than in terms of $\Delta\alpha$, + the errors resulting from this simplification are less than + 1~milliarcsecond in position and 1~milliarcsecond per + century in proper motion. + \item See also sla\_FK425, sla\_FK45Z, sla\_FK54Z. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item Smith, C.A.\ {\it et al.}, 1989.\ {\it Astr.J.}\ {\bf 97}, 265. + \item Yallop, B.D.\ {\it et al.}, 1989.\ {\it Astr.J.}\ {\bf 97}, 274. + \item Seidelmann, P.K.\ (ed), 1992. {\it Explanatory + Supplement to the Astronomical Almanac,}\/ ISBN~0-935702-68-7. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_FK52H}{FK5 to Hipparcos} +{ + \action{Transform an FK5 (J2000) position and proper motion + into the frame of the Hipparcos catalogue.} + \call{CALL sla\_FK52H (R5,D5,DR5,DD5,RH,DH,DRH,DDH)} +} +\args{GIVEN} +{ + \spec{R5}{D}{J2000.0 FK5 $\alpha$ (radians)} \\ + \spec{D5}{D}{J2000.0 FK5 $\delta$ (radians)} \\ + \spec{DR5}{D}{J2000.0 FK5 proper motion in $\alpha$ + (radians per Julian year)} \\ + \spec{DD5}{D}{J2000.0 FK5 proper motion in $\delta$ + (radians per Julian year)} +} +\args{RETURNED} +{ + \spec{RH}{D}{Hipparcos $\alpha$ (radians)} \\ + \spec{DH}{D}{Hipparcos $\delta$ (radians)} \\ + \spec{DRH}{D}{Hipparcos proper motion in $\alpha$ + (radians per Julian year)} \\ + \spec{DDH}{D}{Hipparcos proper motion in $\delta$ + (radians per Julian year)} +} +\notes +{ + \begin{enumerate} + \item The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are per year rather than per century. + \item The FK5 to Hipparcos + transformation consists of a pure rotation and spin; + zonal errors in the FK5 catalogue are not taken into account. + \item The adopted epoch J2000.0 FK5 to Hipparcos orientation and spin + values are as follows (see reference): + + \vspace{2ex} + + ~~~~~~~~~~~~ + \begin{tabular}{|r|r|r|} \hline + & + \multicolumn{1}{|c}{\it orientation} & + \multicolumn{1}{|c|}{\it ~~~spin~~~} \\ \hline + $x$ & $-19.9$~~~~ & ~$-0.30$~~ \\ + $y$ & $-9.1$~~~~ & ~$+0.60$~~ \\ + $z$ & $+22.9$~~~~ & ~$+0.70$~~ \\ \hline + & {\it mas}~~~~~ & ~{\it mas/y}~ \\ \hline + \end{tabular} + + \vspace{3ex} + + These orientation and spin components are interpreted as + {\it axial vectors.} An axial vector points at the pole of + the rotation and its length is the amount of rotation in radians. + \item See also sla\_FK5HZ, sla\_H2FK5, sla\_HFK5Z. + \end{enumerate} +} +\aref {Feissel, M.\ \& Mignard, F., 1998., {\it Astron.Astrophys.}\ + {\bf 331}, L33-L36.} +%----------------------------------------------------------------------- +\routine{SLA\_FK54Z}{FK5 to FK4, no P.M. or Parallax} +{ + \action{Convert a J2000.0 FK5 star position to B1950.0 FK4 assuming + FK5 zero proper motion and parallax. + This routine converts star positions from the new, IAU~1976, + FK5, Fricke system to the old, Bessel-Newcomb, FK4 system.} + \call{CALL sla\_FK54Z (R2000,D2000,BEPOCH,R1950,D1950,DR1950,DD1950)} +} +\args{GIVEN} +{ + \spec{R2000}{D}{J2000.0 FK5 $\alpha$ (radians)} \\ + \spec{D2000}{D}{J2000.0 FK5 $\delta$ (radians)} \\ + \spec{BEPOCH}{D}{Besselian epoch ({\it e.g.}\ 1950D0)} +} +\args{RETURNED} +{ + \spec{R1950}{D}{B1950.0 FK4 $\alpha$ at epoch BEPOCH (radians)} \\ + \spec{D1950}{D}{B1950.0 FK4 $\delta$ at epoch BEPOCH (radians)} \\ + \spec{DR1950}{D}{B1950.0 FK4 proper motion in $\alpha$ + (radians per tropical year)} \\ + \spec{DD1950}{D}{B1950.0 FK4 proper motion in $\delta$ + (radians per tropical year)} +} +\notes +{ + \begin{enumerate} + \item The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are per year rather than per century. + \item Conversion from Julian epoch 2000.0 to Besselian epoch 1950.0 + only is provided for. Conversions involving other epochs will + require use of the appropriate precession routines before and + after this routine is called. + \item Unlike in the sla\_FK524 routine, the FK5 proper motions, the + parallax and the radial velocity are presumed zero. + \item It was the intention that FK5 should be a close approximation + to an inertial frame, so that distant objects have zero proper + motion; such objects have (in general) non-zero proper motion + in FK4, and this routine returns those {\it fictitious proper + motions}. + \item The position returned by this routine is in the B1950 + reference frame but at Besselian epoch BEPOCH. For + comparison with catalogues the BEPOCH argument will + frequently be 1950D0. + \item See also sla\_FK425, sla\_FK45Z, sla\_FK524. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_FK5HZ}{FK5 to Hipparcos, no P.M.} +{ + \action{Transform an FK5 (J2000) star position into the frame of the + Hipparcos catalogue, assuming zero Hipparcos proper motion.} + \call{CALL sla\_FK52H (R5,D5,EPOCH,RH,DH)} +} +\args{GIVEN} +{ + \spec{R5}{D}{J2000.0 FK5 $\alpha$ (radians)} \\ + \spec{D5}{D}{J2000.0 FK5 $\delta$ (radians)} \\ + \spec{EPOCH}{D}{Julian epoch (TDB)} +} +\args{RETURNED} +{ + \spec{RH}{D}{Hipparcos $\alpha$ (radians)} \\ + \spec{DH}{D}{Hipparcos $\delta$ (radians)} +} +\notes +{ + \begin{enumerate} + \item The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are per year rather than per century. + \item The FK5 to Hipparcos + transformation consists of a pure rotation and spin; + zonal errors in the FK5 catalogue are not taken into account. + \item The adopted epoch J2000.0 FK5 to Hipparcos orientation and spin + values are as follows (see reference): + + \vspace{2ex} + + ~~~~~~~~~~~~ + \begin{tabular}{|r|r|r|} \hline + & + \multicolumn{1}{|c}{\it orientation} & + \multicolumn{1}{|c|}{\it ~~~spin~~~} \\ \hline + $x$ & $-19.9$~~~~ & ~$-0.30$~~ \\ + $y$ & $-9.1$~~~~ & ~$+0.60$~~ \\ + $z$ & $+22.9$~~~~ & ~$+0.70$~~ \\ \hline + & {\it mas}~~~~~ & ~{\it mas/y}~ \\ \hline + \end{tabular} + + \vspace{3ex} + + These orientation and spin components are interpreted as + {\it axial vectors.} An axial vector points at the pole of + the rotation and its length is the amount of rotation in radians. + \item See also sla\_FK52H, sla\_H2FK5, sla\_HFK5Z. + \end{enumerate} +} +\aref {Feissel, M.\ \& Mignard, F., 1998., {\it Astron.Astrophys.}\ + {\bf 331}, L33-L36.} +%----------------------------------------------------------------------- +\routine{SLA\_FLOTIN}{Decode a Real Number} +{ + \action{Convert free-format input into single precision floating point.} + \call{CALL sla\_FLOTIN (STRING, NSTRT, RESLT, JFLAG)} +} +\args{GIVEN} +{ + \spec{STRING}{C}{string containing number to be decoded} \\ + \spec{NSTRT}{I}{pointer to where decoding is to commence} \\ + \spec{RESLT}{R}{current value of result} +} +\args{RETURNED} +{ + \spec{NSTRT}{I}{advanced to next number} \\ + \spec{RESLT}{R}{result} \\ + \spec{JFLAG}{I}{status: $-$1~=~$-$OK, 0~=~+OK, 1~=~null result, 2~=~error} +} +\notes +{ + \begin{enumerate} + \item The reason sla\_FLOTIN has separate `OK' status values + for + and $-$ is to enable minus zero to be detected. + This is of crucial importance + when decoding mixed-radix numbers. For example, an angle + expressed as degrees, arcminutes and arcseconds may have a + leading minus sign but a zero degrees field. + \item A TAB is interpreted as a space, and lowercase characters are + interpreted as uppercase. {\it n.b.}\ The test for TAB is + ASCII-specific. + \item The basic format is the sequence of fields $\pm n.n x \pm n$, + where $\pm$ is a sign + character `+' or `$-$', $n$ means a string of decimal digits, + `.' is a decimal point, and $x$, which indicates an exponent, + means `D' or `E'. Various combinations of these fields can be + omitted, and embedded blanks are permissible in certain places. + \item Spaces: + \begin{itemize} + \item Leading spaces are ignored. + \item Embedded spaces are allowed only after +, $-$, D or E, + and after the decimal point if the first sequence of + digits is absent. + \item Trailing spaces are ignored; the first signifies + end of decoding and subsequent ones are skipped. + \end{itemize} + \item Delimiters: + \begin{itemize} + \item Any character other than +,$-$,0-9,.,D,E or space may be + used to signal the end of the number and terminate decoding. + \item Comma is recognized by sla\_FLOTIN as a special case; it + is skipped, leaving the pointer on the next character. See + 13, below. + \item Decoding will in all cases terminate if end of string + is reached. + \end{itemize} + \item Both signs are optional. The default is +. + \item The mantissa $n.n$ defaults to unity. + \item The exponent $x\!\pm\!n$ defaults to `E0'. + \item The strings of decimal digits may be of any length. + \item The decimal point is optional for whole numbers. + \item A {\it null result}\/ occurs when the string of characters + being decoded does not begin with +,$-$,0-9,.,D or E, or + consists entirely of spaces. When this condition is + detected, JFLAG is set to 1 and RESLT is left untouched. + \item NSTRT = 1 for the first character in the string. + \item On return from sla\_FLOTIN, NSTRT is set ready for the next + decode -- following trailing blanks and any comma. If a + delimiter other than comma is being used, NSTRT must be + incremented before the next call to sla\_FLOTIN, otherwise + all subsequent calls will return a null result. + \item Errors (JFLAG=2) occur when: + \begin{itemize} + \item a +, $-$, D or E is left unsatisfied; or + \item the decimal point is present without at least + one decimal digit before or after it; or + \item an exponent more than 100 has been presented. + \end{itemize} + \item When an error has been detected, NSTRT is left + pointing to the character following the last + one used before the error came to light. This + may be after the point at which a more sophisticated + program could have detected the error. For example, + sla\_FLOTIN does not detect that `1E999' is unacceptable + (on a computer where this is so) + until the entire number has been decoded. + \item Certain highly unlikely combinations of mantissa and + exponent can cause arithmetic faults during the + decode, in some cases despite the fact that they + together could be construed as a valid number. + \item Decoding is left to right, one pass. + \item See also sla\_DFLTIN and sla\_INTIN. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_GALEQ}{Galactic to J2000 $\alpha,\delta$} +{ + \action{Transformation from IAU 1958 galactic coordinates + to J2000.0 FK5 equatorial coordinates.} + \call{CALL sla\_GALEQ (DL, DB, DR, DD)} +} +\args{GIVEN} +{ + \spec{DL,DB}{D}{galactic longitude and latitude \gal} +} +\args{RETURNED} +{ + \spec{DR,DD}{D}{J2000.0 \radec} +} +\notes +{ + \begin{enumerate} + \item All arguments are in radians. + \item The equatorial coordinates are J2000.0 FK5. Use the routine + sla\_GE50 if conversion to B1950.0 FK4 coordinates is + required. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_GALSUP}{Galactic to Supergalactic} +{ + \action{Transformation from IAU 1958 galactic coordinates to + de Vaucouleurs supergalactic coordinates.} + \call{CALL sla\_GALSUP (DL, DB, DSL, DSB)} +} +\args{GIVEN} +{ + \spec{DL,DB}{D}{galactic longitude and latitude \gal\ (radians)} +} +\args{RETURNED} +{ + \spec{DSL,DSB}{D}{supergalactic longitude and latitude (radians)} +} +\refs +{ + \begin{enumerate} + \item de Vaucouleurs, de Vaucouleurs, \& Corwin, {\it Second Reference + Catalogue of Bright Galaxies}, U.Texas, p8. + \item Systems \& Applied Sciences Corp., documentation for the + machine-readable version of the above catalogue, + Contract NAS 5-26490. + \end{enumerate} + (These two references give different values for the galactic + longitude of the supergalactic origin. Both are wrong; the + correct value is $l^{I\!I}=137.37$.) +} +%----------------------------------------------------------------------- +\routine{SLA\_GE50}{Galactic to B1950 $\alpha,\delta$} +{ + \action{Transformation from IAU 1958 galactic coordinates to + B1950.0 FK4 equatorial coordinates.} + \call{CALL sla\_GE50 (DL, DB, DR, DD)} +} +\args{GIVEN} +{ + \spec{DL,DB}{D}{galactic longitude and latitude \gal} +} +\args{RETURNED} +{ + \spec{DR,DD}{D}{B1950.0 \radec} +} +\notes +{ + \begin{enumerate} + \item All arguments are in radians. + \item The equatorial coordinates are B1950.0 FK4. Use the + routine sla\_GALEQ if conversion to J2000.0 FK5 coordinates + is required. + \end{enumerate} +} +\aref{Blaauw {\it et al.}, 1960, {\it Mon.Not.R.astr.Soc.}, + {\bf 121}, 123.} +%----------------------------------------------------------------------- +\routine{SLA\_GEOC}{Geodetic to Geocentric} +{ + \action{Convert geodetic position to geocentric.} + \call{CALL sla\_GEOC (P, H, R, Z)} +} +\args{GIVEN} +{ + \spec{P}{D}{latitude (geodetic, radians)} \\ + \spec{H}{D}{height above reference spheroid (geodetic, metres)} +} +\args{RETURNED} +{ + \spec{R}{D}{distance from Earth axis (AU)} \\ + \spec{Z}{D}{distance from plane of Earth equator (AU)} +} +\notes +{ + \begin{enumerate} + \item Geocentric latitude can be obtained by evaluating {\tt ATAN2(Z,R)}. + \item IAU 1976 constants are used. + \end{enumerate} +} +\aref{Green, R.M., 1985.\ {\it Spherical Astronomy}, Cambridge U.P., p98.} +%----------------------------------------------------------------------- +\routine{SLA\_GMST}{UT to GMST} +{ + \action{Conversion from universal time UT1 to Greenwich mean + sidereal time.} + \call{D~=~sla\_GMST (UT1)} +} +\args{GIVEN} +{ + \spec{UT1}{D}{universal time (strictly UT1) expressed as + modified Julian Date (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{sla\_GMST}{D}{Greenwich mean sidereal time (radians)} +} +\notes +{ + \begin{enumerate} + \item The IAU~1982 expression + (see page~S15 of the 1984 {\it Astronomical + Almanac})\/ is used, but rearranged to reduce rounding errors. This + expression is always described as giving the GMST at $0^{\rm h}$UT; + in fact, it gives the difference between the + GMST and the UT, which happens to equal the GMST (modulo + 24~hours) at $0^{\rm h}$UT each day. In sla\_GMST, the + entire UT is used directly as the argument for the + canonical formula, and the fractional part of the UT is + added separately; note that the factor $1.0027379\cdots$ does + not appear. + \item See also the routine sla\_GMSTA, which + delivers better numerical + precision by accepting the UT date and time as separate arguments. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_GMSTA}{UT to GMST (extra precision)} +{ + \action{Conversion from universal time UT1 to Greenwich Mean + sidereal time, with rounding errors minimized.} + \call{D~=~sla\_GMSTA (DATE, UT1)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{UT1 date as Modified Julian Date (integer part + of JD$-$2400000.5)} \\ + \spec{UT1}{D}{UT1 time (fraction of a day)} +} +\args{RETURNED} +{ + \spec{sla\_GMST}{D}{Greenwich mean sidereal time (radians)} +} +\notes +{ + \begin{enumerate} + \item The algorithm is derived from the IAU 1982 expression + (see page~S15 of the 1984 Astronomical Almanac). + \item There is no restriction on how the UT is apportioned between the + DATE and UT1 arguments. Either of the two arguments could, for + example, be zero and the entire date\,+\,time supplied in the other. + However, the routine is designed to deliver maximum accuracy when + the DATE argument is a whole number and the UT1 argument + lies in the range $[\,0,\,1\,]$, or {\it vice versa}. + \item See also the routine sla\_GMST, which accepts the UT1 as a single + argument. Compared with sla\_GMST, the extra numerical precision + delivered by the present routine is unlikely to be important in + an absolute sense, but may be useful when critically comparing + algorithms and in applications where two sidereal times close + together are differenced. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_GRESID}{Gaussian Residual} +{ + \action{Generate pseudo-random normal deviate or {\it Gaussian residual}.} + \call{R~=~sla\_GRESID (S)} +} +\args{GIVEN} +{ + \spec{S}{R}{standard deviation} +} +\notes +{ + \begin{enumerate} + \item The results of many calls to this routine will be + normally distributed with mean zero and standard deviation S. + \item The Box-Muller algorithm is used. + \item The implementation is machine-dependent. + \end{enumerate} +} +\aref{Ahrens \& Dieter, 1972.\ {\it Comm.A.C.M.}\ {\bf 15}, 873.} +%----------------------------------------------------------------------- +\routine{SLA\_H2E}{Az,El to $h,\delta$} +{ + \action{Horizon to equatorial coordinates + (single precision).} + \call{CALL sla\_H2E (AZ, EL, PHI, HA, DEC)} +} +\args{GIVEN} +{ + \spec{AZ}{R}{azimuth (radians)} \\ + \spec{EL}{R}{elevation (radians)} \\ + \spec{PHI}{R}{latitude (radians)} +} +\args{RETURNED} +{ + \spec{HA}{R}{hour angle (radians)} \\ + \spec{DEC}{R}{declination (radians)} +} +\notes +{ + \begin{enumerate} + \item The sign convention for azimuth is north zero, east $+\pi/2$. + \item HA is returned in the range $\pm\pi$. Declination is returned + in the range $\pm\pi$. + \item The latitude is (in principle) geodetic. In critical + applications, corrections for polar motion should be applied + (see sla\_POLMO). + \item In some applications it will be important to specify the + correct type of elevation in order to produce the required + type of \hadec. In particular, it may be important to + distinguish between the elevation as affected by refraction, + which will yield the {\it observed} \hadec, and the elevation + {\it in vacuo}, which will yield the {\it topocentric} + \hadec. If the + effects of diurnal aberration can be neglected, the + topocentric \hadec\ may be used as an approximation to the + {\it apparent} \hadec. + \item No range checking of arguments is carried out. + \item In applications which involve many such calculations, rather + than calling the present routine it will be more efficient to + use inline code, having previously computed fixed terms such + as sine and cosine of latitude. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_H2FK5}{Hipparcos to FK5} +{ + \action{Transform a Hipparcos star position and proper motion + into the FK5 (J2000) frame.} + \call{CALL sla\_H2FK5 (RH,DH,DRH,DDH,R5,D5,DR5,DD5)} +} +\args{GIVEN} +{ + \spec{RH}{D}{Hipparcos $\alpha$ (radians)} \\ + \spec{DH}{D}{Hipparcos $\delta$ (radians)} \\ + \spec{DRH}{D}{Hipparcos proper motion in $\alpha$ + (radians per Julian year)} \\ + \spec{DDH}{D}{Hipparcos proper motion in $\delta$ + (radians per Julian year)} +} +\args{RETURNED} +{ + \spec{R5}{D}{J2000.0 FK5 $\alpha$ (radians)} \\ + \spec{D5}{D}{J2000.0 FK5 $\delta$ (radians)} \\ + \spec{DR5}{D}{J2000.0 FK5 proper motion in $\alpha$ + (radians per Julian year)} \\ + \spec{DD5}{D}{FK5 J2000.0 proper motion in $\delta$ + (radians per Julian year)} +} +\notes +{ + \begin{enumerate} + \item The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are per year rather than per century. + \item The FK5 to Hipparcos + transformation consists of a pure rotation and spin; + zonal errors in the FK5 catalogue are not taken into account. + \item The adopted epoch J2000.0 FK5 to Hipparcos orientation and spin + values are as follows (see reference): + + \vspace{2ex} + + ~~~~~~~~~~~~ + \begin{tabular}{|r|r|r|} \hline + & + \multicolumn{1}{|c}{\it orientation} & + \multicolumn{1}{|c|}{\it ~~~spin~~~} \\ \hline + $x$ & $-19.9$~~~~ & ~$-0.30$~~ \\ + $y$ & $-9.1$~~~~ & ~$+0.60$~~ \\ + $z$ & $+22.9$~~~~ & ~$+0.70$~~ \\ \hline + & {\it mas}~~~~~ & ~{\it mas/y}~ \\ \hline + \end{tabular} + + \vspace{3ex} + + These orientation and spin components are interpreted as + {\it axial vectors.} An axial vector points at the pole of + the rotation and its length is the amount of rotation in radians. + \item See also sla\_FK52H, sla\_FK5HZ, sla\_HFK5Z. + \end{enumerate} +} +\aref {Feissel, M.\ \& Mignard, F., 1998., {\it Astron.Astrophys.}\ + {\bf 331}, L33-L36.} +%----------------------------------------------------------------------- +\routine{SLA\_HFK5Z}{Hipparcos to FK5, no P.M.} +{ + \action{Transform a Hipparcos star position + into the FK5 (J2000) frame assuming zero Hipparcos proper motion.} + \call{CALL sla\_HFK5Z (RH,DH,EPOCH,R5,D5,DR5,DD5)} +} +\args{GIVEN} +{ + \spec{RH}{D}{Hipparcos $\alpha$ (radians)} \\ + \spec{DH}{D}{Hipparcos $\delta$ (radians)} \\ + \spec{EPOCH}{D}{Julian epoch (TDB)} +} +\args{RETURNED} +{ + \spec{R5}{D}{J2000.0 FK5 $\alpha$ (radians)} \\ + \spec{D5}{D}{J2000.0 FK5 $\delta$ (radians)} \\ + \spec{DR5}{D}{J2000.0 FK5 proper motion in $\alpha$ + (radians per Julian year)} \\ + \spec{DD5}{D}{FK5 J2000.0 proper motion in $\delta$ + (radians per Julian year)} +} +\notes +{ + \begin{enumerate} + \item The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are per year rather than per century. + \item The FK5 to Hipparcos + transformation consists of a pure rotation and spin; + zonal errors in the FK5 catalogue are not taken into account. + \item The adopted epoch J2000.0 FK5 to Hipparcos orientation and spin + values are as follows (see reference): + + \vspace{2ex} + + ~~~~~~~~~~~~ + \begin{tabular}{|r|r|r|} \hline + & + \multicolumn{1}{|c}{\it orientation} & + \multicolumn{1}{|c|}{\it ~~~spin~~~} \\ \hline + $x$ & $-19.9$~~~~ & ~$-0.30$~~ \\ + $y$ & $-9.1$~~~~ & ~$+0.60$~~ \\ + $z$ & $+22.9$~~~~ & ~$+0.70$~~ \\ \hline + & {\it mas}~~~~~ & ~{\it mas/y}~ \\ \hline + \end{tabular} + + \vspace{3ex} + + These orientation and spin components are interpreted as + {\it axial vectors.} An axial vector points at the pole of + the rotation and its length is the amount of rotation in radians. + The order of the rotations, which are very small, + \item It was the intention that Hipparcos should be a close + approximation to an inertial frame, so that distant objects + have zero proper motion; such objects have (in general) + non-zero proper motion in FK5, and this routine returns those + {\it fictitious proper motions.} + \item The position returned by this routine is in the FK5 J2000 + reference frame but at Julian epoch EPOCH. + \item See also sla\_FK52H, sla\_FK5HZ, sla\_H2FK5. + \end{enumerate} +} +\aref {Feissel, M.\ \& Mignard, F., 1998., {\it Astron.Astrophys.}\ + {\bf 331}, L33-L36.} +%----------------------------------------------------------------------- +\routine{SLA\_IMXV}{Apply 3D Reverse Rotation} +{ + \action{Multiply a 3-vector by the inverse of a rotation + matrix (single precision).} + \call{CALL sla\_IMXV (RM, VA, VB)} +} +\args{GIVEN} +{ + \spec{RM}{R(3,3)}{rotation matrix} \\ + \spec{VA}{R(3)}{vector to be rotated} +} +\args{RETURNED} +{ + \spec{VB}{R(3)}{result vector} +} +\notes +{ + \begin{enumerate} + \item This routine performs the operation: + \begin{verse} + {\bf b} = {\bf M}$^{T}\cdot${\bf a} + \end{verse} + where {\bf a} and {\bf b} are the 3-vectors VA and VB + respectively, and {\bf M} is the $3\times3$ matrix RM. + \item The main function of this routine is apply an inverse + rotation; under these circumstances, ${\bf M}$ is + {\it orthogonal}, with its inverse the same as its transpose. + \item To comply with the ANSI Fortran 77 standard, VA and VB must + {\bf not} be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is {\bf not}, however, + recommended. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_INTIN}{Decode an Integer Number} +{ + \action{Convert free-format input into an integer.} + \call{CALL sla\_INTIN (STRING, NSTRT, IRESLT, JFLAG)} +} +\args{GIVEN} +{ + \spec{STRING}{C}{string containing number to be decoded} \\ + \spec{NSTRT}{I}{pointer to where decoding is to commence} \\ + \spec{IRESLT}{I}{current value of result} +} +\args{RETURNED} +{ + \spec{NSTRT}{I}{advanced to next number} \\ + \spec{IRESLT}{I}{result} \\ + \spec{JFLAG}{I}{status: $-$1 = $-$OK, 0~=~+OK, 1~=~null result, 2~=~error} +} +\notes +{ + \begin{enumerate} + \item The reason sla\_INTIN has separate `OK' status values + for + and $-$ is to enable minus zero to be detected. + This is of crucial importance + when decoding mixed-radix numbers. For example, an angle + expressed as degrees, arcminutes and arcseconds may have a + leading minus sign but a zero degrees field. + \item A TAB is interpreted as a space. {\it n.b.}\ The test for TAB is + ASCII-specific. + \item The basic format is the sequence of fields $\pm n$, + where $\pm$ is a sign + character `+' or `$-$', and $n$ means a string of decimal digits. + \item Spaces: + \begin{itemize} + \item Leading spaces are ignored. + \item Spaces between the sign and the number are allowed. + \item Trailing spaces are ignored; the first signifies + end of decoding and subsequent ones are skipped. + \end{itemize} + \item Delimiters: + \begin{itemize} + \item Any character other than +,$-$,0-9 or space may be + used to signal the end of the number and terminate decoding. + \item Comma is recognized by sla\_INTIN as a special case; it + is skipped, leaving the pointer on the next character. See + 9, below. + \item Decoding will in all cases terminate if end of string + is reached. + \end{itemize} + \item The sign is optional. The default is +. + \item A {\it null result}\/ occurs when the string of characters + being decoded does not begin with +,$-$ or 0-9, or + consists entirely of spaces. When this condition is + detected, JFLAG is set to 1 and IRESLT is left untouched. + \item NSTRT = 1 for the first character in the string. + \item On return from sla\_INTIN, NSTRT is set ready for the next + decode -- following trailing blanks and any comma. If a + delimiter other than comma is being used, NSTRT must be + incremented before the next call to sla\_INTIN, otherwise + all subsequent calls will return a null result. + \item Errors (JFLAG=2) occur when: + \begin{itemize} + \item there is a + or $-$ but no number; or + \item the number is greater than $2^{31}-1$. + \end{itemize} + \item When an error has been detected, NSTRT is left + pointing to the character following the last + one used before the error came to light. + \item See also sla\_FLOTIN and sla\_DFLTIN. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_INVF}{Invert Linear Model} +{ + \action{Invert a linear model of the type produced by the + sla\_FITXY routine.} + \call{CALL sla\_INVF (FWDS,BKWDS,J)} +} +\args{GIVEN} +{ + \spec{FWDS}{D(6)}{model coefficients} +} +\args{RETURNED} +{ + \spec{BKWDS}{D(6)}{inverse model} \\ + \spec{J}{I}{status: 0 = OK, $-$1 = no inverse} +} +\notes +{ + \begin{enumerate} + \item The models relate two sets of \xy\ coordinates as follows. + Naming the six elements of FWDS $a,b,c,d,e$ \& $f$, + where two sets of coordinates $[x_{1},y_{1}]$ and + $[x_{2},y_{2}\,]$ are related thus: + \begin{verse} + $x_{2} = a + bx_{1} + cy_{1}$ \\ + $y_{2} = d + ex_{1} + fy_{1}$ + \end{verse} + The present routine generates a new set of coefficients + $p,q,r,s,t$ \& $u$ (the array BKWDS) such that: + \begin{verse} + $x_{1} = p + qx_{2} + ry_{2}$ \\ + $y_{1} = s + tx_{2} + uy_{2}$ + \end{verse} + \item Two successive calls to this routine will deliver a set + of coefficients equal to the starting values. + \item To comply with the ANSI Fortran 77 standard, FWDS and BKWDS must + {\bf not} be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is {\bf not}, however, + recommended. + \item See also sla\_FITXY, sla\_PXY, sla\_XY2XY, sla\_DCMPF. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_KBJ}{Select Epoch Prefix} +{ + \action{Select epoch prefix `B' or `J'.} + \call{CALL sla\_KBJ (JB, E, K, J)} +} +\args{GIVEN} +{ + \spec{JB}{I}{sla\_DBJIN prefix status: 0=none, 1=`B', 2=`J'} \\ + \spec{E}{D}{epoch -- Besselian or Julian} +} +\args{RETURNED} +{ + \spec{K}{C}{`B' or `J'} \\ + \spec{J}{I}{status: 0=OK} +} +\anote{The routine is mainly intended for use in conjunction with the + sla\_DBJIN routine. If the value of JB indicates that an explicit + B or J prefix was detected by sla\_DBJIN, a `B' or `J' + is returned to match. If JB indicates that no explicit B or J + was supplied, the choice is made on the basis of the epoch + itself; B is assumed for E $<1984$, otherwise J.} +%----------------------------------------------------------------------- +\routine{SLA\_M2AV}{Rotation Matrix to Axial Vector} +{ + \action{From a rotation matrix, determine the corresponding axial vector + (single precision).} + \call{CALL sla\_M2AV (RMAT, AXVEC)} +} +\args{GIVEN} +{ + \spec{RMAT}{R(3,3)}{rotation matrix} +} +\args{RETURNED} +{ + \spec{AXVEC}{R(3)}{axial vector (radians)} +} +\notes +{ + \begin{enumerate} + \item A rotation matrix describes a rotation about some arbitrary axis. + The axis is called the {\it Euler axis}, and the angle through + which the reference frame rotates is called the {\it Euler angle}. + The {\it axial vector}\/ returned by this routine has the same + direction as the Euler axis, and its magnitude is the Euler angle + in radians. + \item The magnitude and direction of the axial vector can be separated + by means of the routine sla\_VN. + \item The reference frame rotates clockwise as seen looking along + the axial vector from the origin. + \item If RMAT is null, so is the result. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_MAP}{Mean to Apparent} +{ + \action{Transform star \radec\ from mean place to geocentric apparent. + The reference frames and timescales used are post IAU~1976.} + \call{CALL sla\_MAP (RM, DM, PR, PD, PX, RV, EQ, DATE, RA, DA)} +} +\args{GIVEN} +{ + \spec{RM,DM}{D}{mean \radec\ (radians)} \\ + \spec{PR,PD}{D}{proper motions: \radec\ changes per Julian year} \\ + \spec{PX}{D}{parallax (arcsec)} \\ + \spec{RV}{D}{radial velocity (km~s$^{-1}$, +ve if receding)} \\ + \spec{EQ}{D}{epoch and equinox of star data (Julian)} \\ + \spec{DATE}{D}{TDB for apparent place (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{RA,DA}{D}{apparent \radec\ (radians)} +} +\notes +{ + \begin{enumerate} + \item EQ is the Julian epoch specifying both the reference + frame and the epoch of the position -- usually 2000. + For positions where the epoch and equinox are + different, use the routine sla\_PM to apply proper + motion corrections before using this routine. + \item The distinction between the required TDB and TT is + always negligible. Moreover, for all but the most + critical applications UTC is adequate. + \item The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are per year rather than per century. + \item This routine may be wasteful for some applications + because it recomputes the Earth position/velocity and + the precession/nutation matrix each time, and because + it allows for parallax and proper motion. Where + multiple transformations are to be carried out for one + epoch, a faster method is to call the sla\_MAPPA routine + once and then either the sla\_MAPQK routine (which includes + parallax and proper motion) or sla\_MAPQKZ (which assumes + zero parallax and FK5 proper motion). + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item 1984 {\it Astronomical Almanac}, pp B39-B41. + \item Lederle \& Schwan, 1984.\ {\it Astr.Astrophys.}\ {\bf 134}, 1-6. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_MAPPA}{Mean to Apparent Parameters} +{ + \action{Compute star-independent parameters in preparation for + conversions between mean place and geocentric apparent place. + The parameters produced by this routine are required in the + parallax, light deflection, aberration, and precession/nutation + parts of the mean/apparent transformations. + The reference frames and timescales used are post IAU~1976.} + \call{CALL sla\_MAPPA (EQ, DATE, AMPRMS)} +} +\args{GIVEN} +{ + \spec{EQ}{D}{epoch of mean equinox to be used (Julian)} \\ + \spec{DATE}{D}{TDB (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{AMPRMS}{D(21)}{star-independent mean-to-apparent parameters:} \\ + \specel {(1)} {time interval for proper motion (Julian years)} \\ + \specel {(2-4)} {barycentric position of the Earth (AU)} \\ + \specel {(5-7)} {heliocentric direction of the Earth (unit vector)} \\ + \specel {(8)} {(gravitational radius of + Sun)$\times 2 / $(Sun-Earth distance)} \\ + \specel {(9-11)} {{\bf v}: barycentric Earth velocity in units of c} \\ + \specel {(12)} {$\sqrt{1-\left|\mbox{\bf v}\right|^2}$} \\ + \specel {(13-21)} {precession/nutation $3\times3$ matrix} +} +\notes +{ + \begin{enumerate} + \item For DATE, the distinction between the required TDB and TT + is always negligible. Moreover, for all but the most + critical applications UTC is adequate. + \item The accuracy of the routines using the parameters AMPRMS is + limited by the routine sla\_EVP, used here to compute the + Earth position and velocity by the methods of Stumpff. + The maximum error in the resulting aberration corrections is + about 0.3 milliarcsecond. + \item The vectors AMPRMS(2-4) and AMPRMS(5-7) are referred to + the mean equinox and equator of epoch EQ. + \item The parameters produced by this routine are used by + sla\_MAPQK and sla\_MAPQKZ. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item 1984 {\it Astronomical Almanac}, pp B39-B41. + \item Lederle \& Schwan, 1984.\ {\it Astr.Astrophys.}\ {\bf 134}, 1-6. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_MAPQK}{Quick Mean to Apparent} +{ + \action{Quick mean to apparent place: transform a star \radec\ from + mean place to geocentric apparent place, given the + star-independent parameters. The reference frames and + timescales used are post IAU 1976.} + \call{CALL sla\_MAPQK (RM, DM, PR, PD, PX, RV, AMPRMS, RA, DA)} +} +\args{GIVEN} +{ + \spec{RM,DM}{D}{mean \radec\ (radians)} \\ + \spec{PR,PD}{D}{proper motions: \radec\ changes per Julian year} \\ + \spec{PX}{D}{parallax (arcsec)} \\ + \spec{RV}{D}{radial velocity (km~s$^{-1}$, +ve if receding)} \\ + \spec{AMPRMS}{D(21)}{star-independent mean-to-apparent parameters:} \\ + \specel {(1)} {time interval for proper motion (Julian years)} \\ + \specel {(2-4)} {barycentric position of the Earth (AU)} \\ + \specel {(5-7)} {heliocentric direction of the Earth (unit vector)} \\ + \specel {(8)} {(gravitational radius of + Sun)$\times 2 / $(Sun-Earth distance)} \\ + \specel {(9-11)} {{\bf v}: barycentric Earth velocity in units of c} \\ + \specel {(12)} {$\sqrt{1-\left|\mbox{\bf v}\right|^2}$} \\ + \specel {(13-21)} {precession/nutation $3\times3$ matrix} +} +\args{RETURNED} +{ + \spec{RA,DA}{D }{apparent \radec\ (radians)} +} +\notes +{ + \begin{enumerate} + \item Use of this routine is appropriate when efficiency is important + and where many star positions, all referred to the same equator + and equinox, are to be transformed for one epoch. The + star-independent parameters can be obtained by calling the + sla\_MAPPA routine. + \item If the parallax and proper motions are zero the sla\_MAPQKZ + routine can be used instead. + \item The vectors AMPRMS(2-4) and AMPRMS(5-7) are referred to + the mean equinox and equator of epoch EQ. + \item Strictly speaking, the routine is not valid for solar-system + sources, though the error will usually be extremely small. + However, to prevent gross errors in the case where the + position of the Sun is specified, the gravitational + deflection term is restrained within about \arcseci{920} of the + centre of the Sun's disc. The term has a maximum value of + about \arcsec{1}{85} at this radius, and decreases to zero as + the centre of the disc is approached. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item 1984 {\it Astronomical Almanac}, pp B39-B41. + \item Lederle \& Schwan, 1984.\ {\it Astr.Astrophys.}\ {\bf 134}, 1-6. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_MAPQKZ}{Quick Mean-Appt, no PM {\it etc.}} +{ + \action{Quick mean to apparent place: transform a star \radec\ from + mean place to geocentric apparent place, given the + star-independent parameters, and assuming zero parallax + and FK5 proper motion. + The reference frames and timescales used are post IAU~1976.} + \call{CALL sla\_MAPQKZ (RM, DM, AMPRMS, RA, DA)} +} +\args{GIVEN} +{ + \spec{RM,DM}{D}{mean \radec\ (radians)} \\ + \spec{AMPRMS}{D(21)}{star-independent mean-to-apparent parameters:} \\ + \specel {(1)} {time interval for proper motion (Julian years)} \\ + \specel {(2-4)} {barycentric position of the Earth (AU)} \\ + \specel {(5-7)} {heliocentric direction of the Earth (unit vector)} \\ + \specel {(8)} {(gravitational radius of + Sun)$\times 2 / $(Sun-Earth distance)} \\ + \specel {(9-11)} {{\bf v}: barycentric Earth velocity in units of c} \\ + \specel {(12)} {$\sqrt{1-\left|\mbox{\bf v}\right|^2}$} \\ + \specel {(13-21)} {precession/nutation $3\times3$ matrix} +} +\args{RETURNED} +{ + \spec{RA,DA}{D}{apparent \radec\ (radians)} +} +\notes +{ + \begin{enumerate} + \item Use of this routine is appropriate when efficiency is important + and where many star positions, all with parallax and proper + motion either zero or already allowed for, and all referred to + the same equator and equinox, are to be transformed for one + epoch. The star-independent parameters can be obtained by + calling the sla\_MAPPA routine. + \item The corresponding routine for the case of non-zero parallax + and FK5 proper motion is sla\_MAPQK. + \item The vectors AMPRMS(2-4) and AMPRMS(5-7) are referred to the + mean equinox and equator of epoch EQ. + \item Strictly speaking, the routine is not valid for solar-system + sources, though the error will usually be extremely small. + However, to prevent gross errors in the case where the + position of the Sun is specified, the gravitational + deflection term is restrained within about \arcseci{920} of the + centre of the Sun's disc. The term has a maximum value of + about \arcsec{1}{85} at this radius, and decreases to zero as + the centre of the disc is approached. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item 1984 {\it Astronomical Almanac}, pp B39-B41. + \item Lederle \& Schwan, 1984.\ {\it Astr.Astrophys.}\ {\bf 134}, 1-6. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_MOON}{Approx Moon Pos/Vel} +{ + \action{Approximate geocentric position and velocity of the Moon + (single precision).} + \call{CALL sla\_MOON (IY, ID, FD, PV)} +} +\args{GIVEN} +{ + \spec{IY}{I}{year} \\ + \spec{ID}{I}{day in year (1 = Jan 1st)} \\ + \spec{FD}{R }{fraction of day} +} +\args{RETURNED} +{ + \spec{PV}{R(6)}{Moon \xyzxyzd, mean equator and equinox of + date (AU, AU~s$^{-1}$)} +} +\notes +{ + \begin{enumerate} + \item The date and time is TDB (loosely ET) in a Julian calendar + which has been aligned to the ordinary Gregorian + calendar for the interval 1900 March 1 to 2100 February 28. + The year and day can be obtained by calling sla\_CALYD or + sla\_CLYD. + \item The position is accurate to better than 0.5~arcminute + in direction and 1000~km in distance. The velocity + is accurate to better than \arcsec{0}{5} per hour in direction + and 4~metres per socond in distance. (RMS figures with respect + to JPL DE200 for the interval 1960-2025 are \arcseci{14} and + \arcsec{0}{2} per hour in longitude, \arcseci{9} and \arcsec{0}{2} + per hour in latitude, 350~km and 2~metres per second in distance.) + Note that the distance accuracy is comparatively poor because this + routine is principally intended for computing topocentric direction. + \item This routine is only a partial implementation of the original + Meeus algorithm (reference below), which offers 4 times the + accuracy in direction and 20 times the accuracy in distance + when fully implemented (as it is in sla\_DMOON). + \end{enumerate} +} +\aref{Meeus, {\it l'Astronomie}, June 1984, p348.} +%----------------------------------------------------------------------- +\routine{SLA\_MXM}{Multiply $3\times3$ Matrices} +{ + \action{Product of two $3\times3$ matrices (single precision).} + \call{CALL sla\_MXM (A, B, C)} +} +\args{GIVEN} +{ + \spec{A}{R(3,3)}{matrix {\bf A}} \\ + \spec{B}{R(3,3)}{matrix {\bf B}} +} +\args{RETURNED} +{ + \spec{C}{R(3,3)}{matrix result: {\bf A}$\times${\bf B}} +} +\anote{To comply with the ANSI Fortran 77 standard, A, B and C must + be different arrays. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is {\bf not}, however, + recommended.} +%----------------------------------------------------------------------- +\routine{SLA\_MXV}{Apply 3D Rotation} +{ + \action{Multiply a 3-vector by a rotation matrix (single precision).} + \call{CALL sla\_MXV (RM, VA, VB)} +} +\args{GIVEN} +{ + \spec{RM}{R(3,3)}{rotation matrix} \\ + \spec{VA}{R(3)}{vector to be rotated} +} +\args{RETURNED} +{ + \spec{VB}{R(3)}{result vector} +} +\notes +{ + \begin{enumerate} + \item This routine performs the operation: + \begin{verse} + {\bf b} = {\bf M}$\cdot${\bf a} + \end{verse} + where {\bf a} and {\bf b} are the 3-vectors VA and VB + respectively, and {\bf M} is the $3\times3$ matrix RM. + \item The main function of this routine is apply a + rotation; under these circumstances, ${\bf M}$ is a + {\it proper real orthogonal}\/ matrix. + \item To comply with the ANSI Fortran 77 standard, VA and VB must + {\bf not} be the same array. The routine is, in fact, coded + so as to work properly on the VAX and many other systems even + if this rule is violated, something that is {\bf not}, however, + recommended. + \end{enumerate} +} +%------------------------------------------------------------------------------ +\routine{SLA\_NUT}{Nutation Matrix} +{ + \action{Form the matrix of nutation (IAU 1980 theory) for a given date.} + \call{CALL sla\_NUT (DATE, RMATN)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{TDB (formerly ET) as Modified Julian Date + (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{RMATN}{D(3,3)}{nutation matrix} +} +\anote{The matrix is in the sense: + \begin{verse} + {\bf v}$_{true}$ = {\bf M}$\cdot${\bf v}$_{mean}$ + \end{verse} + where {\bf v}$_{true}$ is the star vector relative to the + true equator and equinox of date, {\bf M} is the + $3\times3$ matrix RMATN and + {\bf v}$_{mean}$ is the star vector relative to the + mean equator and equinox of date.} +\refs +{ + \begin{enumerate} + \item Final report of the IAU Working Group on Nutation, + chairman P.K.Seidelmann, 1980. + \item Kaplan, G.H., 1981.\ {\it USNO circular No.\ 163}, pA3-6. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_NUTC}{Nutation Components} +{ + \action{Nutation (IAU 1980 theory): longitude \& obliquity + components, and mean obliquity.} + \call{CALL sla\_NUTC (DATE, DPSI, DEPS, EPS0)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{TDB (formerly ET) as Modified Julian Date + (JD$-$2400000.5)} +} +\args{RETURNED} +{ + \spec{DPSI,DEPS}{D}{nutation in longitude and obliquity (radians)} \\ + \spec{EPS0}{D}{mean obliquity (radians)} +} +\refs +{ + \begin{enumerate} + \item Final report of the IAU Working Group on Nutation, + chairman P.K.Seidelmann, 1980. + \item Kaplan, G.H., 1981.\ {\it USNO circular no.\ 163}, pA3-6. + \end{enumerate} +} +%------------------------------------------------------------------------------ +\routine{SLA\_OAP}{Observed to Apparent} +{ + \action{Observed to apparent place.} + \call{CALL sla\_OAP (\vtop{ + \hbox{TYPE, OB1, OB2, DATE, DUT, ELONGM, PHIM,} + \hbox{HM, XP, YP, TDK, PMB, RH, WL, TLR, RAP, DAP)}}} +} +\args{GIVEN} +{ + \spec{TYPE}{C*(*)}{type of coordinates -- `R', `H' or `A' (see below)} \\ + \spec{OB1}{D}{observed Az, HA or RA (radians; Az is N=0, E=$90^{\circ}$)} \\ + \spec{OB2}{D}{observed zenith distance or $\delta$ (radians)} \\ + \spec{DATE}{D }{UTC date/time (Modified Julian Date, JD$-$2400000.5)} \\ + \spec{DUT}{D}{$\Delta$UT: UT1$-$UTC (UTC seconds)} \\ + \spec{ELONGM}{D}{observer's mean longitude (radians, east +ve)} \\ + \spec{PHIM}{D}{observer's mean geodetic latitude (radians)} \\ + \spec{HM}{D}{observer's height above sea level (metres)} \\ + \spec{XP,YP}{D}{polar motion \xy\ coordinates (radians)} \\ + \spec{TDK}{D}{local ambient temperature (degrees K; std=273.155D0)} \\ + \spec{PMB}{D}{local atmospheric pressure (mB; std=1013.25D0)} \\ + \spec{RH}{D}{local relative humidity (in the range 0D0\,--\,1D0)} \\ + \spec{WL}{D}{effective wavelength ($\mu{\rm m}$, {\it e.g.}\ 0.55D0)} \\ + \spec{TLR}{D}{tropospheric lapse rate (degrees K per metre, + {\it e.g.}\ 0.0065D0)} +} +\args{RETURNED} +{ + \spec{RAP,DAP}{D}{geocentric apparent \radec} +} +\notes +{ + \begin{enumerate} + \item Only the first character of the TYPE argument is significant. + `R' or `r' indicates that OBS1 and OBS2 are the observed Right + Ascension and Declination; `H' or `h' indicates that they are + Hour Angle (west +ve) and Declination; anything else (`A' or + `a' is recommended) indicates that OBS1 and OBS2 are Azimuth + (north zero, east is $90^{\circ}$) and Zenith Distance. (Zenith + distance is used rather than elevation in order to reflect the + fact that no allowance is made for depression of the horizon.) + \item The accuracy of the result is limited by the corrections for + refraction. Providing the meteorological parameters are + known accurately and there are no gross local effects, the + predicted azimuth and elevation should be within about + \arcsec{0}{1} for $\zeta<70^{\circ}$. Even + at a topocentric zenith distance of + $90^{\circ}$, the accuracy in elevation should be better than + 1~arcminute; useful results are available for a further + $3^{\circ}$, beyond which the sla\_REFRO routine returns a + fixed value of the refraction. The complementary + routines sla\_AOP (or sla\_AOPQK) and sla\_OAP (or sla\_OAPQK) + are self-consistent to better than 1~microarcsecond all over + the celestial sphere. + \item It is advisable to take great care with units, as even + unlikely values of the input parameters are accepted and + processed in accordance with the models used. + \item {\it Observed}\/ \azel\ means the position that would be seen by a + perfect theodolite located at the observer. This is + related to the observed \hadec\ via the standard rotation, using + the geodetic latitude (corrected for polar motion), while the + observed HA and RA are related simply through the local + apparent ST. {\it Observed}\/ \radec\ or \hadec\ thus means the + position that would be seen by a perfect equatorial located + at the observer and with its polar axis aligned to the + Earth's axis of rotation ({\it n.b.}\ not to the refracted pole). + By removing from the observed place the effects of + atmospheric refraction and diurnal aberration, the + geocentric apparent \radec\ is obtained. + \item Frequently, {\it mean}\/ rather than {\it apparent}\, + \radec\ will be required, + in which case further transformations will be necessary. The + sla\_AMP {\it etc.}\ routines will convert + the apparent \radec\ produced + by the present routine into an FK5 J2000 mean place, by + allowing for the Sun's gravitational lens effect, annual + aberration, nutation and precession. Should FK4 B1950 + coordinates be needed, the routines sla\_FK524 {\it etc.}\ will also + need to be applied. + \item To convert to apparent \radec\ the coordinates read from a + real telescope, corrections would have to be applied for + encoder zero points, gear and encoder errors, tube flexure, + the position of the rotator axis and the pointing axis + relative to it, non-perpendicularity between the mounting + axes, and finally for the tilt of the azimuth or polar axis + of the mounting (with appropriate corrections for mount + flexures). Some telescopes would, of course, exhibit other + properties which would need to be accounted for at the + appropriate point in the sequence. + \item The star-independent apparent-to-observed-place parameters + in AOPRMS may be computed by means of the sla\_AOPPA routine. + If nothing has changed significantly except the time, the + sla\_AOPPAT routine may be used to perform the requisite + partial recomputation of AOPRMS. + \item The DATE argument is UTC expressed as an MJD. This is, + strictly speaking, wrong, because of leap seconds. However, + as long as the $\Delta$UT and the UTC are consistent there + are no difficulties, except during a leap second. In this + case, the start of the 61st second of the final minute should + begin a new MJD day and the old pre-leap $\Delta$UT should + continue to be used. As the 61st second completes, the MJD + should revert to the start of the day as, simultaneously, + the $\Delta$UT changes by one second to its post-leap new value. + \item The $\Delta$UT (UT1$-$UTC) is tabulated in IERS circulars and + elsewhere. It increases by exactly one second at the end of + each UTC leap second, introduced in order to keep $\Delta$UT + within $\pm$\tsec{0}{9}. + \item IMPORTANT -- TAKE CARE WITH THE LONGITUDE SIGN CONVENTION. The + longitude required by the present routine is {\bf east-positive}, + in accordance with geographical convention (and right-handed). + In particular, note that the longitudes returned by the + sla\_OBS routine are west-positive (as in the {\it Astronomical + Almanac}\/ before 1984) and must be reversed in sign before use + in the present routine. + \item The polar coordinates XP,YP can be obtained from IERS + circulars and equivalent publications. The + maximum amplitude is about \arcsec{0}{3}. If XP,YP values + are unavailable, use XP=YP=0D0. See page B60 of the 1988 + {\it Astronomical Almanac}\/ for a definition of the two angles. + \item The height above sea level of the observing station, HM, + can be obtained from the {\it Astronomical Almanac}\/ (Section J + in the 1988 edition), or via the routine sla\_OBS. If P, + the pressure in mB, is available, an adequate + estimate of HM can be obtained from the following expression: + \begin{quote} + {\tt HM=-29.3D0*TSL*LOG(P/1013.25D0)} + \end{quote} + where TSL is the approximate sea-level air temperature in degrees K + (see {\it Astrophysical Quantities}, C.W.Allen, 3rd~edition, + \S 52). Similarly, if the pressure P is not known, + it can be estimated from the height of the observing + station, HM as follows: + \begin{quote} + {\tt P=1013.25D0*EXP(-HM/(29.3D0*TSL))} + \end{quote} + Note, however, that the refraction is proportional to the + pressure and that an accurate P value is important for + precise work. + \item The azimuths {\it etc.}\ used by the present routine are with + respect to the celestial pole. Corrections from the terrestrial pole + can be computed using sla\_POLMO. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_OAPQK}{Quick Observed to Apparent} +{ + \action{Quick observed to apparent place.} + \call{CALL sla\_OAPQK (TYPE, OB1, OB2, AOPRMS, RAP, DAP)} +} +\args{GIVEN} +{ + \spec{TYPE}{C*(*)}{type of coordinates -- `R', `H' or `A' (see below)} \\ + \spec{OB1}{D}{observed Az, HA or RA (radians; Az is N=0, E=$90^{\circ}$)} \\ + \spec{OB2}{D}{observed zenith distance or $\delta$ (radians)} \\ + \spec{AOPRMS}{D(14)}{star-independent apparent-to-observed parameters:} \\ + \specel {(1)} {geodetic latitude (radians)} \\ + \specel {(2,3)} {sine and cosine of geodetic latitude} \\ + \specel {(4)} {magnitude of diurnal aberration vector} \\ + \specel {(5)} {height (HM)} \\ + \specel {(6)} {ambient temperature (TDK)} \\ + \specel {(7)} {pressure (PMB)} \\ + \specel {(8)} {relative humidity (RH)} \\ + \specel {(9)} {wavelength (WL)} \\ + \specel {(10)} {lapse rate (TLR)} \\ + \specel {(11,12)} {refraction constants A and B (radians)} \\ + \specel {(13)} {longitude + eqn of equinoxes + + ``sidereal $\Delta$UT'' (radians)} \\ + \specel {(14)} {local apparent sidereal time (radians)} +} +\args{RETURNED} +{ + \spec{RAP,DAP}{D}{geocentric apparent \radec} +} +\notes +{ + \begin{enumerate} + \item Only the first character of the TYPE argument is significant. + `R' or `r' indicates that OBS1 and OBS2 are the observed Right + Ascension and Declination; `H' or `h' indicates that they are + Hour Angle (west +ve) and Declination; anything else (`A' or + `a' is recommended) indicates that OBS1 and OBS2 are Azimuth + (north zero, east is $90^{\circ}$) and Zenith Distance. (Zenith + distance is used rather than elevation in order to reflect the + fact that no allowance is made for depression of the horizon.) + \item The accuracy of the result is limited by the corrections for + refraction. Providing the meteorological parameters are + known accurately and there are no gross local effects, the + predicted azimuth and elevation should be within about + \arcsec{0}{1} for $\zeta<70^{\circ}$. Even + at a topocentric zenith distance of + $90^{\circ}$, the accuracy in elevation should be better than + 1~arcminute; useful results are available for a further + $3^{\circ}$, beyond which the sla\_REFRO routine returns a + fixed value of the refraction. The complementary + routines sla\_AOP (or sla\_AOPQK) and sla\_OAP (or sla\_OAPQK) + are self-consistent to better than 1~microarcsecond all over + the celestial sphere. + \item It is advisable to take great care with units, as even + unlikely values of the input parameters are accepted and + processed in accordance with the models used. + \item {\it Observed}\/ \azel\ means the position that would be seen by a + perfect theodolite located at the observer. This is + related to the observed \hadec\ via the standard rotation, using + the geodetic latitude (corrected for polar motion), while the + observed HA and RA are related simply through the local + apparent ST. {\it Observed}\/ \radec\ or \hadec\ thus means the + position that would be seen by a perfect equatorial located + at the observer and with its polar axis aligned to the + Earth's axis of rotation ({\it n.b.}\ not to the refracted pole). + By removing from the observed place the effects of + atmospheric refraction and diurnal aberration, the + geocentric apparent \radec\ is obtained. + \item Frequently, {\it mean}\/ rather than {\it apparent}\, + \radec\ will be required, + in which case further transformations will be necessary. The + sla\_AMP {\it etc.}\ routines will convert + the apparent \radec\ produced + by the present routine into an FK5 J2000 mean place, by + allowing for the Sun's gravitational lens effect, annual + aberration, nutation and precession. Should FK4 B1950 + coordinates be needed, the routines sla\_FK524 {\it etc.}\ will also + need to be applied. + \item To convert to apparent \radec\ the coordinates read from a + real telescope, corrections would have to be applied for + encoder zero points, gear and encoder errors, tube flexure, + the position of the rotator axis and the pointing axis + relative to it, non-perpendicularity between the mounting + axes, and finally for the tilt of the azimuth or polar axis + of the mounting (with appropriate corrections for mount + flexures). Some telescopes would, of course, exhibit other + properties which would need to be accounted for at the + appropriate point in the sequence. + \item The star-independent apparent-to-observed-place parameters + in AOPRMS may be computed by means of the sla\_AOPPA routine. + If nothing has changed significantly except the time, the + sla\_AOPPAT routine may be used to perform the requisite + partial recomputation of AOPRMS. + \item The azimuths {\it etc.}\ used by the present routine are with + respect to the celestial pole. Corrections from the terrestrial pole + can be computed using sla\_POLMO. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_OBS}{Observatory Parameters} +{ + \action{Look up an entry in a standard list of + groundbased observing stations parameters.} + \call{CALL sla\_OBS (N, C, NAME, W, P, H)} +} +\args{GIVEN} +{ + \spec{N}{I}{number specifying observing station} +} +\args{GIVEN or RETURNED} +{ + \spec{C}{C*(*)}{identifier specifying observing station} +} +\args{RETURNED} +{ + \spec{NAME}{C*(*)}{name of specified observing station} \\ + \spec{W}{D}{longitude (radians, west +ve)} \\ + \spec{P}{D}{geodetic latitude (radians, north +ve)} \\ + \spec{H}{D}{height above sea level (metres)} +} +\notes +{ + \begin{enumerate} + \item Station identifiers C may be up to 10 characters long, + and station names NAME may be up to 40 characters long. + \item C and N are {\it alternative}\/ ways of specifying the observing + station. The C option, which is the most generally useful, + may be selected by specifying an N value of zero or less. + If N is 1 or more, the parameters of the Nth station + in the currently supported list are interrogated, and + the station identifier C is returned as well as NAME, W, + P and H. + \item If the station parameters are not available, either because + the station identifier C is not recognized, or because an + N value greater than the number of stations supported is + given, a name of `?' is returned and W, P and H are left in + their current states. + \item Programs can obtain a list of all currently supported + stations by calling the routine repeatedly, with N=1,2,3... + When NAME=`?' is seen, the list of stations has been + exhausted. The stations at the time of writing are listed + below. + \item Station numbers, identifiers, names and other details are + subject to change and should not be hardwired into + application programs. + \item All station identifiers C are uppercase only; lower case + characters must be converted to uppercase by the calling + program. The station names returned may contain both upper- + and lowercase. All characters up to the first space are + checked; thus an abbreviated ID will return the parameters + for the first station in the list which matches the + abbreviation supplied, and no station in the list will ever + contain embedded spaces. C must not have leading spaces. + \item IMPORTANT -- BEWARE OF THE LONGITUDE SIGN CONVENTION. The + longitude returned by sla\_OBS is + {\bf west-positive}, following the pre-1984 {\it Astronomical + Almanac}. However, this sign convention is left-handed and is + the opposite of the one now used; elsewhere in + SLALIB the preferable east-positive convention is used. In + particular, note that for use in sla\_AOP, sla\_AOPPA and + sla\_OAP the sign of the longitude must be reversed. + \item Users are urged to inform the author of any improvements + they would like to see made. For example: + \begin{itemize} + \item typographical corrections + \item more accurate parameters + \item better station identifiers or names + \item additional stations + \end{itemize} + \end{enumerate} +Stations supported by sla\_OBS at the time of writing: +\begin{tabbing} +xxxxxxxxxxxxxxxxx \= \kill +{\it ID} \> {\it NAME} \\ \\ +AAT \> Anglo-Australian 3.9m Telescope \\ +ANU2.3 \> Siding Spring 2.3 metre \\ +APO3.5 \> Apache Point 3.5m \\ +ARECIBO \> Arecibo 1000 foot \\ +ATCA \> Australia Telescope Compact Array \\ +BLOEMF \> Bloemfontein 1.52 metre \\ +BOSQALEGRE \> Bosque Alegre 1.54 metre \\ +CAMB1MILE \> Cambridge 1 mile \\ +CAMB5KM \> Cambridge 5km \\ +CATALINA61 \> Catalina 61 inch \\ +CFHT \> Canada-France-Hawaii 3.6m Telescope \\ +CSO \> Caltech Sub-mm Observatory, Mauna Kea \\ +DAO72 \> DAO Victoria BC 1.85 metre \\ +DUNLAP74 \> David Dunlap 74 inch \\ +DUPONT \> Du Pont 2.5m Telescope, Las Campanas \\ +EFFELSBERG \> Effelsberg 100 metre \\ +ESO3.6 \> ESO 3.6 metre \\ +ESONTT \> ESO 3.5 metre NTT \\ +ESOSCHM \> ESO 1 metre Schmidt, La Silla \\ +FCRAO \> Five College Radio Astronomy Obs \\ +FLAGSTF61 \> USNO 61 inch astrograph, Flagstaff \\ +GBVA140 \> Greenbank 140 foot \\ +GBVA300 \> Greenbank 300 foot \\ +GEMININ \> Gemini North 8-m telescope \\ +HARVARD \> Harvard College Observatory 1.55m \\ +HPROV1.52 \> Haute Provence 1.52 metre \\ +HPROV1.93 \> Haute Provence 1.93 metre \\ +IRTF \> NASA IR Telescope Facility, Mauna Kea \\ +JCMT \> JCMT 15 metre \\ +JODRELL1 \> Jodrell Bank 250 foot \\ +KECK1 \> Keck 10m Telescope 1 \\ +KECK2 \> Keck 10m Telescope 2 \\ +KISO \> Kiso 1.05 metre Schmidt, Japan \\ +KOTTAMIA \> Kottamia 74 inch \\ +KPNO158 \> Kitt Peak 158 inch \\ +KPNO36FT \> Kitt Peak 36 foot \\ +KPNO84 \> Kitt Peak 84 inch \\ +KPNO90 \> Kitt Peak 90 inch \\ +LICK120 \> Lick 120 inch \\ +LOWELL72 \> Perkins 72 inch, Lowell \\ +LPO1 \> Jacobus Kapteyn 1m Telescope \\ +LPO2.5 \> Isaac Newton 2.5m Telescope \\ +LPO4.2 \> William Herschel 4.2m Telescope \\ +MAUNAK88 \> Mauna Kea 88 inch \\ +MCDONLD2.1 \> McDonald 2.1 metre \\ +MCDONLD2.7 \> McDonald 2.7 metre \\ +MMT \> MMT, Mt Hopkins \\ +MOPRA \> ATNF Mopra Observatory \\ +MTEKAR \> Mt Ekar 1.82 metre \\ +MTHOP1.5 \> Mt Hopkins 1.5 metre \\ +MTLEMMON60 \> Mt Lemmon 60 inch \\ +NOBEYAMA \> Nobeyama 45 metre \\ +OKAYAMA \> Okayama 1.88 metre \\ +PALOMAR200 \> Palomar 200 inch \\ +PALOMAR48 \> Palomar 48-inch Schmidt \\ +PALOMAR60 \> Palomar 60 inch \\ +PARKES \> Parkes 64 metre \\ +QUEBEC1.6 \> Quebec 1.6 metre \\ +SAAO74 \> Sutherland 74 inch \\ +SANPM83 \> San Pedro Martir 83 inch \\ +ST.ANDREWS \> St Andrews University Observatory \\ +STEWARD90 \> Steward 90 inch \\ +STROMLO74 \> Mount Stromlo 74 inch \\ +SUBARU \> Subaru 8 metre \\ +SUGARGROVE \> Sugar Grove 150 foot \\ +TAUTNBG \> Tautenburg 2 metre \\ +TAUTSCHM \> Tautenberg 1.34 metre Schmidt \\ +TIDBINBLA \> Tidbinbilla 64 metre \\ +TOLOLO1.5M \> Cerro Tololo 1.5 metre \\ +TOLOLO4M \> Cerro Tololo 4 metre \\ +UKIRT \> UK Infra Red Telescope \\ +UKST \> UK 1.2 metre Schmidt, Siding Spring \\ +USSR6 \> USSR 6 metre \\ +USSR600 \> USSR 600 foot \\ +VLA \> Very Large Array +\end{tabbing} +} +%----------------------------------------------------------------------- +\routine{SLA\_PA}{$h,\delta$ to Parallactic Angle} +{ + \action{Hour angle and declination to parallactic angle + (double precision).} + \call{D~=~sla\_PA (HA, DEC, PHI)} +} +\args{GIVEN} +{ + \spec{HA}{D}{hour angle in radians (geocentric apparent)} \\ + \spec{DEC}{D}{declination in radians (geocentric apparent)} \\ + \spec{PHI}{D}{latitude in radians (geodetic)} +} +\args{RETURNED} +{ + \spec{sla\_PA}{D}{parallactic angle (radians, in the range $\pm \pi$)} +} +\notes +{ + \begin{enumerate} + \item The parallactic angle at a point in the sky is the position + angle of the vertical, {\it i.e.}\ the angle between the direction to + the pole and to the zenith. In precise applications care must + be taken only to use geocentric apparent \hadec\ and to consider + separately the effects of atmospheric refraction and telescope + mount errors. + \item At the pole a zero result is returned. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_PAV}{Position-Angle Between Two Directions} +{ + \action{Returns the bearing (position angle) of one celestial + direction with respect to another (single precision).} + \call{R~=~sla\_PAV (V1, V2)} +} +\args{GIVEN} +{ + \spec{V1}{R(3)}{direction cosines of one point} \\ + \spec{V2}{R(3)}{directions cosines of the other point} +} +\args{RETURNED} +{ + \spec{sla\_PAV}{R}{position-angle of 2nd point with respect to 1st} +} +\notes +{ + \begin{enumerate} + \item The coordinate frames correspond to \radec, + $[\lambda,\phi]$ {\it etc.}. + \item The result is the bearing (position angle), in radians, + of point V2 as seen + from point V1. It is in the range $\pm \pi$. The sense + is such that if V2 + is a small distance due east of V1 the result + is about $+\pi/2$. Zero is returned + if the two points are coincident. + \item The routine sla\_BEAR performs an equivalent function except + that the points are specified in the form of spherical coordinates. + \end{enumerate} +} +%------------------------------------------------------------------------------ +\routine{SLA\_PCD}{Apply Radial Distortion} +{ + \action{Apply pincushion/barrel distortion to a tangent-plane \xy.} + \call{CALL sla\_PCD (DISCO,X,Y)} +} +\args{GIVEN} +{ + \spec{DISCO}{D}{pincushion/barrel distortion coefficient} \\ + \spec{X,Y}{D}{tangent-plane \xy} +} +\args{RETURNED} +{ + \spec{X,Y}{D}{distorted \xy} +} +\notes +{ + \begin{enumerate} + \item The distortion is of the form $\rho = r (1 + c r^{2})$, where $r$ is + the radial distance from the tangent point, $c$ is the DISCO + argument, and $\rho$ is the radial distance in the presence of + the distortion. + \item For {\it pincushion}\/ distortion, C is +ve; for + {\it barrel}\/ distortion, C is $-$ve. + \item For X,Y in units of one projection radius (in the case of + a photographic plate, the focal length), the following + DISCO values apply: + + \vspace{2ex} + + \hspace{5em} + \begin{tabular}{|l|c|} \hline + Geometry & DISCO \\ \hline \hline + astrograph & 0.0 \\ \hline + Schmidt & $-$0.3333 \\ \hline + AAT PF doublet & +147.069 \\ \hline + AAT PF triplet & +178.585 \\ \hline + AAT f/8 & +21.20 \\ \hline + JKT f/8 & +14.6 \\ \hline + \end{tabular} + + \vspace{2ex} + + \item There is a companion routine, sla\_UNPCD, which performs + an approximately inverse operation. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_PDA2H}{H.A.\ for a Given Azimuth} +{ + \action{Hour Angle corresponding to a given azimuth (double precision).} + \call{CALL sla\_PDA2H (P, D, A, H1, J1, H2, J2)} +} +\args{GIVEN} +{ + \spec{P}{D}{latitude} \\ + \spec{D}{D}{declination} \\ + \spec{A}{D}{azimuth} +} +\args{RETURNED} +{ + \spec{H1}{D}{hour angle: first solution if any} \\ + \spec{J1}{I}{flag: 0 = solution 1 is valid} \\ + \spec{H2}{D}{hour angle: second solution if any} \\ + \spec{J2}{I}{flag: 0 = solution 2 is valid} +} +%----------------------------------------------------------------------- +\routine{SLA\_PDQ2H}{H.A.\ for a Given P.A.} +{ + \action{Hour Angle corresponding to a given parallactic angle + (double precision).} + \call{CALL sla\_PDQ2H (P, D, Q, H1, J1, H2, J2)} +} +\args{GIVEN} +{ + \spec{P}{D}{latitude} \\ + \spec{D}{D}{declination} \\ + \spec{Q}{D}{azimuth} +} +\args{RETURNED} +{ + \spec{H1}{D}{hour angle: first solution if any} \\ + \spec{J1}{I}{flag: 0 = solution 1 is valid} \\ + \spec{H2}{D}{hour angle: second solution if any} \\ + \spec{J2}{I}{flag: 0 = solution 2 is valid} +} +%----------------------------------------------------------------------- +\routine{SLA\_PERMUT}{Next Permutation} +{ + \action{Generate the next permutation of a specified number of items.} + \call{CALL sla\_PERMUT (N, ISTATE, IORDER, J)} +} +\args{GIVEN} +{ + \spec{N}{I}{number of items: there will be N! permutations} \\ + \spec{ISTATE}{I(N)}{state, ISTATE(1)$=-1$ to initialize} +} +\args{RETURNED} +{ + \spec{ISTATE}{I(N)}{state, updated ready for next time} \\ + \spec{IORDER}{I(N)}{next permutation of numbers 1,2,\ldots,N} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} $-$1 = illegal N (zero or less is illegal)} \\ + \spec{}{}{\hspace{2.3em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} $+$1 = no more permutations available} +} +\notes +{ + \begin{enumerate} + \item This routine returns, in the IORDER array, the integers 1 to N + inclusive, in an order that depends on the current contents of + the ISTATE array. Before calling the routine for the first + time, the caller must set the first element of the ISTATE array + to $-1$ (any negative number will do) to cause the ISTATE array + to be fully initialized. + \item The first permutation to be generated is: + \begin{verse} + IORDER(1)=N, IORDER(2)=N-1, ..., IORDER(N)=1 + \end{verse} + This is also the permutation returned for the ``finished'' (J=1) case. + The final permutation to be generated is: + \begin{verse} + IORDER(1)=1, IORDER(2)=2, ..., IORDER(N)=N + \end{verse} + \item If the ``finished'' (J=1) status is ignored, the routine continues + to deliver permutations, the pattern repeating every~N!\,~calls. + \end{enumerate} +} +%------------------------------------------------------------------------------ +\routine{SLA\_PERTEL}{Perturbed Orbital Elements} +{ + \action{Update the osculating elements of an asteroid or comet by + applying planetary perturbations.} + \call{CALL sla\_PERTEL (\vtop{ + \hbox{JFORM, DATE0, DATE1,} + \hbox{EPOCH0, ORBI0, ANODE0, PERIH0, AORQ0, E0, AM0,} + \hbox{EPOCH1, ORBI1, ANODE1, PERIH1, AORQ1, E1, AM1,} + \hbox{JSTAT)}}} +} +\args{GIVEN (format and dates)} +{ + \spec{JFORM}{I}{choice of element set (2 or 3; Note~1)} \\ + \spec{DATE0}{D}{date of osculation (TT MJD) for the given} \\ + \spec{}{}{\hspace{1.5em} elements} \\ + \spec{DATE1}{D}{date of osculation (TT MJD) for the updated} \\ + \spec{}{}{\hspace{1.5em} elements} +} +\args{GIVEN (the unperturbed elements)} +{ + \spec{EPOCH0}{D}{epoch of the given element set + ($t_0$ or $T$, TT MJD;} \\ + \spec{}{}{\hspace{1.5em} Note~2)} \\ + \spec{ORBI0}{D}{inclination ($i$, radians)} \\ + \spec{ANODE0}{D}{longitude of the ascending node ($\Omega$, radians)} \\ + \spec{PERIH0}{D}{argument of perihelion + ($\omega$, radians)} \\ + \spec{AORQ0}{D}{mean distance or perihelion distance ($a$ or $q$, AU)} \\ + \spec{E0}{D}{eccentricity ($e$)} \\ + \spec{AM0}{D}{mean anomaly ($M$, radians, JFORM=2 only)} +} +\args{RETURNED (the updated elements)} +{ + \spec{EPOCH1}{D}{epoch of the updated element set + ($t_0$ or $T$,} \\ + \spec{}{}{\hspace{1.5em} TT MJD; Note~2)} \\ + \spec{ORBI1}{D}{inclination ($i$, radians)} \\ + \spec{ANODE1}{D}{longitude of the ascending node ($\Omega$, radians)} \\ + \spec{PERIH1}{D}{argument of perihelion + ($\omega$, radians)} \\ + \spec{AORQ1}{D}{mean distance or perihelion distance ($a$ or $q$, AU)} \\ + \spec{E1}{D}{eccentricity ($e$)} \\ + \spec{AM1}{D}{mean anomaly ($M$, radians, JFORM=2 only)} +} +\args{RETURNED (status flag)} +{ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{0.5em}+102 = warning, distant epoch} \\ + \spec{}{}{\hspace{0.5em}+101 = warning, large timespan + ($>100$ years)} \\ + \spec{}{}{\hspace{-1.3em}+1 to +8 = coincident with major planet + (Note~6)} \\ + \spec{}{}{\hspace{1.95em} 0 = OK} \\ + \spec{}{}{\hspace{1.2em} $-$1 = illegal JFORM} \\ + \spec{}{}{\hspace{1.2em} $-$2 = illegal E0} \\ + \spec{}{}{\hspace{1.2em} $-$3 = illegal AORQ0} \\ + \spec{}{}{\hspace{1.2em} $-$4 = internal error} \\ + \spec{}{}{\hspace{1.2em} $-$5 = numerical error} +} +\notes +{ + \begin{enumerate} + \item Two different element-format options are supported, as follows. \\ + + JFORM=2, suitable for minor planets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e < 1 )$ \\ + \> AORL \> = \> mean anomaly $M$ (radians) + \end{tabbing} + + JFORM=3, suitable for comets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of perihelion $T$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> perihelion distance $q$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e \leq 10 )$ + \end{tabbing} + \item DATE0, DATE1, EPOCH0 and EPOCH1 are all instants of time in + the TT timescale (formerly Ephemeris Time, ET), expressed + as Modified Julian Dates (JD$-$2400000.5). + \begin{itemize} + \item DATE0 is the instant at which the given + ({\it i.e.}\ unperturbed) osculating elements are correct. + \item DATE1 is the specified instant at which the updated osculating + elements are correct. + \item EPOCH0 and EPOCH1 will be the same as DATE0 and DATE1 + (respectively) for the JFORM=2 case, normally used for minor + planets. For the JFORM=3 case, the two epochs will refer to + perihelion passage and so will not, in general, be the same as + DATE0 and/or DATE1 though they may be similar to one another. + \end{itemize} + \item The elements are with respect to the J2000 ecliptic and mean equinox. + \item Unused elements (AM0 and AM1 for JFORM=3) are not accessed. + \item See the sla\_PERTUE routine for details of the algorithm used. + \item This routine is not intended to be used for major planets, which + is why JFORM=1 is not available and why there is no opportunity + to specify either the longitude of perihelion or the daily + motion. However, if JFORM=2 elements are somehow obtained for a + major planet and supplied to the routine, sensible results will, + in fact, be produced. This happens because the sla\_PERTUE routine + that is called to perform the calculations checks the separation + between the body and each of the planets and interprets a + suspiciously small value (0.001~AU) as an attempt to apply it to + the planet concerned. If this condition is detected, the + contribution from that planet is ignored, and the status is set to + the planet number (Mercury=1,\ldots,Neptune=8) as a warning. + \end{enumerate} +} +\aref{Sterne, Theodore E., {\it An Introduction to Celestial Mechanics,}\/ + Interscience Publishers, 1960. Section 6.7, p199.} +%------------------------------------------------------------------------------ +\routine{SLA\_PERTUE}{Perturbed Universal Elements} +{ + \action{Update the universal elements of an asteroid or comet by + applying planetary perturbations.} + \call{CALL sla\_PERTUE (DATE, U, JSTAT)} +} +\args{GIVEN} +{ + \spec{DATE1}{D}{final epoch (TT MJD) for the updated elements} +} +\args{GIVEN and RETURNED} +{ + \spec{U}{D(13)}{universal elements (updated in place)} \\ + \specel {(1)} {combined mass ($M+m$)} \\ + \specel {(2)} {total energy of the orbit ($\alpha$)} \\ + \specel {(3)} {reference (osculating) epoch ($t_0$)} \\ + \specel {(4-6)} {position at reference epoch (${\rm \bf r}_0$)} \\ + \specel {(7-9)} {velocity at reference epoch (${\rm \bf v}_0$)} \\ + \specel {(10)} {heliocentric distance at reference epoch} \\ + \specel {(11)} {${\rm \bf r}_0.{\rm \bf v_0}$} \\ + \specel {(12)} {date ($t$)} \\ + \specel {(13)} {universal eccentric anomaly ($\psi$) of date, approx} +} +\args{RETURNED} +{ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{0.5em}+102 = warning, distant epoch} \\ + \spec{}{}{\hspace{0.5em}+101 = warning, large timespan + ($>100$ years)} \\ + \spec{}{}{\hspace{-1.3em}+1 to +8 = coincident with major planet + (Note~5)} \\ + \spec{}{}{\hspace{1.95em} 0 = OK} \\ + \spec{}{}{\hspace{1.2em} $-$1 = numerical error} +} +\notes +{ + \begin{enumerate} + \setlength{\parskip}{\medskipamount} + \item The ``universal'' elements are those which define the orbit for the + purposes of the method of universal variables (see reference 2). + They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i)~$\alpha$, which is proportional to the total energy of the + orbit, (ii)~the heliocentric distance at epoch, + (iii)~the outwards component of the velocity at the given epoch, + (iv)~an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v)~that date. + \item The universal elements are with respect to the J2000 equator and + equinox. + \item The epochs DATE, U(3) and U(12) are all Modified Julian Dates + (JD$-$2400000.5). + \item The algorithm is a simplified form of Encke's method. It takes as + a basis the unperturbed motion of the body, and numerically + integrates the perturbing accelerations from the major planets. + The expression used is essentially Sterne's 6.7-2 (reference 1). + Everhart and Pitkin (reference 2) suggest rectifying the orbit at + each integration step by propagating the new perturbed position + and velocity as the new universal variables. In the present + routine the orbit is rectified less frequently than this, in order + to gain a slight speed advantage. However, the rectification is + done directly in terms of position and velocity, as suggested by + Everhart and Pitkin, bypassing the use of conventional orbital + elements. + + The $f(q)$ part of the full Encke method is not used. The purpose + of this part is to avoid subtracting two nearly equal quantities + when calculating the ``indirect member'', which takes account of the + small change in the Sun's attraction due to the slightly displaced + position of the perturbed body. A simpler, direct calculation in + double precision proves to be faster and not significantly less + accurate. + + Apart from employing a variable timestep, and occasionally + ``rectifying the orbit'' to keep the indirect member small, the + integration is done in a fairly straightforward way. The + acceleration estimated for the middle of the timestep is assumed + to apply throughout that timestep; it is also used in the + extrapolation of the perturbations to the middle of the next + timestep, to predict the new disturbed position. There is no + iteration within a timestep. + + Measures are taken to reach a compromise between execution time + and accuracy. The starting-point is the goal of achieving + arcsecond accuracy for ordinary minor planets over a ten-year + timespan. This goal dictates how large the timesteps can be, + which in turn dictates how frequently the unperturbed motion has + to be recalculated from the osculating elements. + + Within predetermined limits, the timestep for the numerical + integration is varied in length in inverse proportion to the + magnitude of the net acceleration on the body from the major + planets. + + The numerical integration requires estimates of the major-planet + motions. Approximate positions for the major planets (Pluto + alone is omitted) are obtained from the routine sla\_PLANET. Two + levels of interpolation are used, to enhance speed without + significantly degrading accuracy. At a low frequency, the routine + sla\_PLANET is called to generate updated position+velocity ``state + vectors''. The only task remaining to be carried out at the full + frequency ({\it i.e.}\ at each integration step) is to use the state + vectors to extrapolate the planetary positions. In place of a + strictly linear extrapolation, some allowance is made for the + curvature of the orbit by scaling back the radius vector as the + linear extrapolation goes off at a tangent. + + Various other approximations are made. For example, perturbations + by Pluto and the minor planets are neglected, relativistic effects + are not taken into account and the Earth-Moon system is treated as + a single body. + + In the interests of simplicity, the background calculations for + the major planets are carried out {\it en masse.} + The mean elements and + state vectors for all the planets are refreshed at the same time, + without regard for orbit curvature, mass or proximity. + + \item This routine is not intended to be used for major planets. + However, if major-planet elements are supplied, sensible results + will, in fact, be produced. This happens because the routine + checks the separation between the body and each of the planets and + interprets a suspiciously small value (0.001~AU) as an attempt to + apply the routine to the planet concerned. If this condition + is detected, the + contribution from that planet is ignored, and the status is set to + the planet number (Mercury=1,\ldots,Neptune=8) as a warning. + \end{enumerate} +} +\refs{ + \begin{enumerate} + \item Sterne, Theodore E., {\it An Introduction to Celestial Mechanics,}\/ + Interscience Publishers, 1960. Section 6.7, p199. + \item Everhart, E. \& Pitkin, E.T., Am.~J.~Phys.~51, 712, 1983. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_PLANEL}{Planet Position from Elements} +{ + \action{Heliocentric position and velocity of a planet, + asteroid or comet, starting from orbital elements.} + \call{CALL sla\_PLANEL (\vtop{ + \hbox{DATE, JFORM, EPOCH, ORBINC, ANODE, PERIH,} + \hbox{AORQ, E, AORL, DM, PV, JSTAT)}}} +} +\args{GIVEN} +{ + \spec{DATE}{D}{Modified Julian Date (JD$-$2400000.5)} \\ + \spec{JFORM}{I}{choice of element set (1-3, see Note~3, below)} \\ + \spec{EPOCH}{D}{epoch of elements ($t_0$ or $T$, TT MJD)} \\ + \spec{ORBINC}{D}{inclination ($i$, radians)} \\ + \spec{ANODE}{D}{longitude of the ascending node ($\Omega$, radians)} \\ + \spec{PERIH}{D}{longitude or argument of perihelion + ($\varpi$ or $\omega$,} \\ + \spec{}{}{\hspace{1.5em} radians)} \\ + \spec{AORQ}{D}{mean distance or perihelion distance ($a$ or $q$, AU)} \\ + \spec{E}{D}{eccentricity ($e$)} \\ + \spec{AORL}{D}{mean anomaly or longitude + ($M$ or $L$, radians,} \\ + \spec{}{}{\hspace{1.5em} JFORM=1,2 only)} \\ + \spec{DM}{D}{daily motion ($n$, radians, JFORM=1 only)} +} +\args{RETURNED} +{ + \spec{PV}{D(6)}{heliocentric \xyzxyzd, equatorial, J2000} \\ + \spec{}{}{\hspace{1.5em} (AU, AU/s)} \\ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{2.3em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} $-$1 = illegal JFORM} \\ + \spec{}{}{\hspace{1.5em} $-$2 = illegal E} \\ + \spec{}{}{\hspace{1.5em} $-$3 = illegal AORQ} \\ + \spec{}{}{\hspace{1.5em} $-$4 = illegal DM} \\ + \spec{}{}{\hspace{1.5em} $-$5 = numerical error} +} +\notes +{ + \begin{enumerate} + \item DATE is the instant for which the prediction is + required. It is in the TT timescale (formerly + Ephemeris Time, ET) and is a + Modified Julian Date (JD$-$2400000.5). + \item The elements are with respect to + the J2000 ecliptic and equinox. + \item Three different element-format options are available, as + follows. \\ + + JFORM=1, suitable for the major planets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> longitude of perihelion $\varpi$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e < 1 )$ \\ + \> AORL \> = \> mean longitude $L$ (radians) \\ + \> DM \> = \> daily motion $n$ (radians) + \end{tabbing} + + JFORM=2, suitable for minor planets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e < 1 )$ \\ + \> AORL \> = \> mean anomaly $M$ (radians) + \end{tabbing} + + JFORM=3, suitable for comets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of perihelion $T$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> perihelion distance $q$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e \leq 10 )$ + \end{tabbing} + \item Unused elements (DM for JFORM=2, AORL and DM for JFORM=3) are + not accessed. + \item The reference frame for the result is equatorial and is with + respect to the mean equinox and ecliptic of epoch J2000. + \item The algorithm was originally adapted from the EPHSLA program of + D.\,H.\,P.\,Jones (private communication, 1996). The method + is based on Stumpff's Universal Variables. + \end{enumerate} +} +\aref{Everhart, E. \& Pitkin, E.T., Am.~J.~Phys.~51, 712, 1983.} +%------------------------------------------------------------------------------ +\routine{SLA\_PLANET}{Planetary Ephemerides} +{ + \action{Approximate heliocentric position and velocity of a planet.} + \call{CALL sla\_PLANET (DATE, NP, PV, JSTAT)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{Modified Julian Date (JD$-$2400000.5)} \\ + \spec{NP}{I}{planet:} \\ + \spec{}{}{\hspace{1.5em} 1\,=\,Mercury} \\ + \spec{}{}{\hspace{1.5em} 2\,=\,Venus} \\ + \spec{}{}{\hspace{1.5em} 3\,=\,Earth-Moon Barycentre} \\ + \spec{}{}{\hspace{1.5em} 4\,=\,Mars} \\ + \spec{}{}{\hspace{1.5em} 5\,=\,Jupiter} \\ + \spec{}{}{\hspace{1.5em} 6\,=\,Saturn} \\ + \spec{}{}{\hspace{1.5em} 7\,=\,Uranus} \\ + \spec{}{}{\hspace{1.5em} 8\,=\,Neptune} \\ + \spec{}{}{\hspace{1.5em} 9\,=\,Pluto} +} +\args{RETURNED} +{ + \spec{PV}{D(6)}{heliocentric \xyzxyzd, equatorial, J2000} \\ + \spec{}{}{\hspace{1.5em} (AU, AU/s)} \\ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} $+$1 = warning: date outside of range} \\ + \spec{}{}{\hspace{2.3em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} $-$1 = illegal NP (outside 1-9)} \\ + \spec{}{}{\hspace{1.5em} $-$2 = solution didn't converge} +} +\notes +{ + \begin{enumerate} + \item The epoch, DATE, is in the TDB timescale and is in the form + of a Modified Julian Date (JD$-$2400000.5). + \item The reference frame is equatorial and is with respect to + the mean equinox and ecliptic of epoch J2000. + \item If a planet number, NP, outside the range 1-9 is supplied, an error + status is returned (JSTAT~=~$-1$) and the PV vector + is set to zeroes. + \item The algorithm for obtaining the mean elements of the + planets from Mercury to Neptune is due to + J.\,L.\,Simon, P.\,Bretagnon, J.\,Chapront, + M.\,Chapront-Touze, G.\,Francou and J.\,Laskar (Bureau des + Longitudes, Paris, France). The (completely different) + algorithm for calculating the ecliptic coordinates of + Pluto is by Meeus. + \item Comparisons of the present routine with the JPL DE200 ephemeris + give the following RMS errors over the interval 1960-2025: + \begin{tabbing} + xxxxx \= xxxxxxxxxxxxxxxxx \= xxxxxxxxxxxxxx \= \kill + \> \> {\it position (km)} \> {\it speed (metre/sec)} \\ \\ + \> Mercury \> \hspace{2em}334 \> \hspace{2.5em}0.437 \\ + \> Venus \> \hspace{1.5em}1060 \> \hspace{2.5em}0.855 \\ + \> EMB \> \hspace{1.5em}2010 \> \hspace{2.5em}0.815 \\ + \> Mars \> \hspace{1.5em}7690 \> \hspace{2.5em}1.98 \\ + \> Jupiter \> \hspace{1em}71700 \> \hspace{2.5em}7.70 \\ + \> Saturn \> \hspace{0.5em}199000 \> \hspace{2em}19.4 \\ + \> Uranus \> \hspace{0.5em}564000 \> \hspace{2em}16.4 \\ + \> Neptune \> \hspace{0.5em}158000 \> \hspace{2em}14.4 \\ + \> Pluto \> \hspace{1em}36400 \> \hspace{2.5em}0.137 + \end{tabbing} + From comparisons with DE102, Simon {\it et al.}\/ quote the following + longitude accuracies over the interval 1800-2200: + \begin{tabbing} + xxxxx \= xxxxxxxxxxxxxxxxxxxx \= \kill + \> Mercury \> \hspace{0.5em}\arcseci{4} \\ + \> Venus \> \hspace{0.5em}\arcseci{5} \\ + \> EMB \> \hspace{0.5em}\arcseci{6} \\ + \> Mars \> \arcseci{17} \\ + \> Jupiter \> \arcseci{71} \\ + \> Saturn \> \arcseci{81} \\ + \> Uranus \> \arcseci{86} \\ + \> Neptune \> \arcseci{11} + \end{tabbing} + In the case of Pluto, Meeus quotes an accuracy of \arcsec{0}{6} + in longitude and \arcsec{0}{2} in latitude for the period + 1885-2099. + + For all except Pluto, over the period 1000-3000, + the accuracy is better than 1.5 + times that over 1800-2200. Outside the interval 1000-3000 the + accuracy declines. For Pluto the accuracy declines rapidly + outside the period 1885-2099. Outside these ranges + (1885-2099 for Pluto, 1000-3000 for the rest) a ``date out + of range'' warning status ({\tt JSTAT=+1}) is returned. + \item The algorithms for (i)~Mercury through Neptune and + (ii)~Pluto are completely independent. In the Mercury + through Neptune case, the present SLALIB + implementation differs from the original + Simon {\it et al.}\/ Fortran code in the following respects: + \begin{itemize} + \item The date is supplied as a Modified Julian Date rather + a Julian Date (${\rm MJD} = ({\rm JD} - 2400000.5$). + \item The result is returned only in equatorial + Cartesian form; the ecliptic + longitude, latitude and radius vector are not returned. + \item The velocity is in AU per second, not AU per day. + \item Different error/warning status values are used. + \item Kepler's Equation is not solved inline. + \item Polynomials in T are nested to minimize rounding errors. + \item Explicit double-precision constants are used to avoid + mixed-mode expressions. + \item There are other, cosmetic, changes to comply with + Starlink/SLALIB style guidelines. + \end{itemize} + None of the above changes affects the result significantly. + \item NP\,=\,3 the result is for the Earth-Moon Barycentre. To + obtain the heliocentric position and velocity of the Earth, + either use the SLALIB routine sla\_EVP or call sla\_DMOON and + subtract 0.012150581 times the geocentric Moon vector from + the EMB vector produced by the present routine. (The Moon + vector should be precessed to J2000 first, but this can + be omitted for modern epochs without introducing significant + inaccuracy.) + \end{enumerate} +\refs +{ + \begin{enumerate} + \item Simon {\it et al.,}\/ + Astron.\ Astrophys.\ {\bf 282}, 663 (1994). + \item Meeus, J., + {\it Astronomical Algorithms,}\/ Willmann-Bell (1991). + \end{enumerate} +} +} +%------------------------------------------------------------------------------ +\routine{SLA\_PLANTE}{\radec\ of Planet from Elements} +{ + \action{Topocentric apparent \radec\ of a Solar-System object whose + heliocentric orbital elements are known.} + \call{CALL sla\_PLANTE (\vtop{ + \hbox{DATE, ELONG, PHI, JFORM, EPOCH, ORBINC, ANODE, PERIH,} + \hbox{AORQ, E, AORL, DM, RA, DEC, R, JSTAT)}}} +} +\args{GIVEN} +{ + \spec{DATE}{D}{MJD of observation (JD$-$2400000.5)} \\ + \spec{ELONG,PHI}{D}{observer's longitude (east +ve) and latitude} \\ + \spec{}{}{\hspace{1.5em} radians)} \\ + \spec{JFORM}{I}{choice of element set (1-3, see Note~4, below)} \\ + \spec{EPOCH}{D}{epoch of elements ($t_0$ or $T$, TT MJD)} \\ + \spec{ORBINC}{D}{inclination ($i$, radians)} \\ + \spec{ANODE}{D}{longitude of the ascending node ($\Omega$, radians)} \\ + \spec{PERIH}{D}{longitude or argument of perihelion + ($\varpi$ or $\omega$,} \\ + \spec{}{}{\hspace{1.5em} radians)} \\ + \spec{AORQ}{D}{mean distance or perihelion distance ($a$ or $q$, AU)} \\ + \spec{E}{D}{eccentricity ($e$)} \\ + \spec{AORL}{D}{mean anomaly or longitude ($M$ or $L$,} \\ + \spec{}{}{\hspace{1.5em} radians, JFORM=1,2 only)} \\ + \spec{DM}{D}{daily motion ($n$, radians, JFORM=1 only)} +} +\args{RETURNED} +{ + \spec{RA,DEC}{D}{topocentric apparent \radec\ (radians)} \\ + \spec{R}{D}{distance from observer (AU)} \\ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{2.3em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} $-$1 = illegal JFORM} \\ + \spec{}{}{\hspace{1.5em} $-$2 = illegal E} \\ + \spec{}{}{\hspace{1.5em} $-$3 = illegal AORQ} \\ + \spec{}{}{\hspace{1.5em} $-$4 = illegal DM} \\ + \spec{}{}{\hspace{1.5em} $-$5 = numerical error} +} +\notes +{ + \begin{enumerate} + \item DATE is the instant for which the prediction is + required. It is in the TT timescale (formerly + Ephemeris Time, ET) and is a + Modified Julian Date (JD$-$2400000.5). + \item The longitude and latitude allow correction for geocentric + parallax. This is usually a small effect, but can become + important for Earth-crossing asteroids. Geocentric positions + can be generated by appropriate use of the routines + sla\_EVP and sla\_PLANEL. + \item The elements are with respect to the J2000 ecliptic and equinox. + \item Three different element-format options are available, as + follows. \\ + + JFORM=1, suitable for the major planets: + + \begin{tabbing} + xxx \= xxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> longitude of perihelion $\varpi$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ \\ + \> AORL \> = \> mean longitude $L$ (radians) \\ + \> DM \> = \> daily motion $n$ (radians) + \end{tabbing} + + JFORM=2, suitable for minor planets: + + \begin{tabbing} + xxx \= xxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ \\ + \> AORL \> = \> mean anomaly $M$ (radians) + \end{tabbing} + + JFORM=3, suitable for comets: + + \begin{tabbing} + xxx \= xxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of perihelion $T$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> perihelion distance $q$ (AU) \\ + \> E \> = \> eccentricity $e$ + \end{tabbing} + \item Unused elements (DM for JFORM=2, AORL and DM for JFORM=3) are + not accessed. + \end{enumerate} +} +%------------------------------------------------------------------------------ +\routine{SLA\_PM}{Proper Motion} +{ + \action{Apply corrections for proper motion to a star \radec.} + \call{CALL sla\_PM (R0, D0, PR, PD, PX, RV, EP0, EP1, R1, D1)} +} +\args{GIVEN} +{ + \spec{R0,D0}{D}{\radec\ at epoch EP0 (radians)} \\ + \spec{PR,PD}{D}{proper motions: rate of change of + \radec\ (radians per year)} \\ + \spec{PX}{D}{parallax (arcsec)} \\ + \spec{RV}{D}{radial velocity (km~s$^{-1}$, +ve if receding)} \\ + \spec{EP0}{D}{start epoch in years ({\it e.g.}\ Julian epoch)} \\ + \spec{EP1}{D}{end epoch in years (same system as EP0)} +} +\args{RETURNED} +{ + \spec{R1,D1}{D}{\radec\ at epoch EP1 (radians)} +} +\anote{The $\alpha$ proper motions are $\dot{\alpha}$ rather than + $\dot{\alpha}\cos\delta$, and are in the same coordinate + system as R0,D0.} +\refs +{ + \begin{enumerate} + \item 1984 {\it Astronomical Almanac}, pp B39-B41. + \item Lederle \& Schwan, 1984.\ {\it Astr. Astrophys.}\ {\bf 134}, 1-6. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_POLMO}{Polar Motion} +{ + \action{Polar motion: correct site longitude and latitude for polar + motion and calculate azimuth difference between celestial and + terrestrial poles.} + \call{CALL sla\_POLMO (ELONGM, PHIM, XP, YP, ELONG, PHI, DAZ)} +} +\args{GIVEN} +{ + \spec{ELONGM}{D}{mean longitude of the site (radians, east +ve)} \\ + \spec{PHIM}{D}{mean geodetic latitude of the site (radians)} \\ + \spec{XP}{D}{polar motion $x$-coordinate (radians)} \\ + \spec{YP}{D}{polar motion $y$-coordinate (radians)} +} +\args{RETURNED} +{ + \spec{ELONG}{D}{true longitude of the site (radians, east +ve)} \\ + \spec{PHI}{D}{true geodetic latitude of the site (radians)} \\ + \spec{DAZ}{D}{azimuth correction (terrestrial$-$celestial, radians)} +} +\notes +{ +\begin{enumerate} +\item ``Mean'' longitude and latitude are the (fixed) values for the + site's location with respect to the IERS terrestrial reference + frame; the latitude is geodetic. TAKE CARE WITH THE LONGITUDE + SIGN CONVENTION. The longitudes used by the present routine + are east-positive, in accordance with geographical convention + (and right-handed). In particular, note that the longitudes + returned by the sla\_OBS routine are west-positive, following + astronomical usage, and must be reversed in sign before use in + the present routine. +\item XP and YP are the (changing) coordinates of the Celestial + Ephemeris Pole with respect to the IERS Reference Pole. + XP is positive along the meridian at longitude $0^\circ$, + and YP is positive along the meridian at longitude + $270^\circ$ ({\it i.e.}\ $90^\circ$ west). Values for XP,YP can + be obtained from IERS circulars and equivalent publications; + the maximum amplitude observed so far is about \arcsec{0}{3}. +\item ``True'' longitude and latitude are the (moving) values for + the site's location with respect to the celestial ephemeris + pole and the meridian which corresponds to the Greenwich + apparent sidereal time. The true longitude and latitude + link the terrestrial coordinates with the standard celestial + models (for precession, nutation, sidereal time {\it etc}). +\item The azimuths produced by sla\_AOP and sla\_AOPQK are with + respect to due north as defined by the Celestial Ephemeris + Pole, and can therefore be called ``celestial azimuths''. + However, a telescope fixed to the Earth measures azimuth + essentially with respect to due north as defined by the + IERS Reference Pole, and can therefore be called ``terrestrial + azimuth''. Uncorrected, this would manifest itself as a + changing ``azimuth zero-point error''. The value DAZ is the + correction to be added to a celestial azimuth to produce + a terrestrial azimuth. +\item The present routine is rigorous. For most practical + purposes, the following simplified formulae provide an + adequate approximation: \\[2ex] + \hspace*{1em}\begin{tabular}{lll} + {\tt ELONG} & {\tt =} & + {\tt ELONGM+XP*COS(ELONGM)-YP*SIN(ELONGM)} \\ + {\tt PHI } & {\tt =} & + {\tt PHIM+(XP*SIN(ELONGM)+YP*COS(ELONGM))*TAN(PHIM)} \\ + {\tt DAZ } & {\tt =} & + {\tt -SQRT(XP*XP+YP*YP)*COS(ELONGM-ATAN2(XP,YP))/COS(PHIM)} \\ + \end{tabular} \\[2ex] + An alternative formulation for DAZ is:\\[2ex] + \hspace*{1em}\begin{tabular}{lll} + {\tt X } & {\tt =} & {\tt COS(ELONGM)*COS(PHIM)} \\ + {\tt Y } & {\tt =} & {\tt SIN(ELONGM)*COS(PHIM)} \\ + {\tt DAZ} & {\tt =} & {\tt ATAN2(-X*YP-Y*XP,X*X+Y*Y)} \\ + \end{tabular} +\end{enumerate} +} +\aref{Seidelmann, P.K.\ (ed), 1992. {\it Explanatory + Supplement to the Astronomical Almanac,}\/ ISBN~0-935702-68-7, + sections 3.27, 4.25, 4.52.} +%----------------------------------------------------------------------- +\routine{SLA\_PREBN}{Precession Matrix (FK4)} +{ + \action{Generate the matrix of precession between two epochs, + using the old, pre IAU~1976, Bessel-Newcomb model, in + Andoyer's formulation.} + \call{CALL sla\_PREBN (BEP0, BEP1, RMATP)} +} +\args{GIVEN} +{ + \spec{BEP0}{D}{beginning Besselian epoch} \\ + \spec{BEP1}{D}{ending Besselian epoch} +} +\args{RETURNED} +{ + \spec{RMATP}{D(3,3)}{precession matrix} +} +\anote{The matrix is in the sense: + \begin{verse} + {\bf v}$_{1}$ = {\bf M}$\cdot${\bf v}$_{0}$ + \end{verse} + where {\bf v}$_{1}$ is the star vector relative to the + mean equator and equinox of epoch BEP1, {\bf M} is the + $3\times3$ matrix RMATP and + {\bf v}$_{0}$ is the star vector relative to the + mean equator and equinox of epoch BEP0.} +\aref{Smith {\it et al.}, 1989.\ {\it Astr.J.}\ {\bf 97}, 269.} +%----------------------------------------------------------------------- +\routine{SLA\_PREC}{Precession Matrix (FK5)} +{ + \action{Form the matrix of precession between two epochs (IAU 1976, FK5).} + \call{CALL sla\_PREC (EP0, EP1, RMATP)} +} +\args{GIVEN} +{ + \spec{EP0}{D}{beginning epoch} \\ + \spec{EP1}{D}{ending epoch} +} +\args{RETURNED} +{ + \spec{RMATP}{D(3,3)}{precession matrix} +} +\notes +{ + \begin{enumerate} + \item The epochs are TDB Julian epochs. + \item The matrix is in the sense: + \begin{verse} + {\bf v}$_{1}$ = {\bf M}$\cdot${\bf v}$_{0}$ + \end{verse} + where {\bf v}$_{1}$ is the star vector relative to the + mean equator and equinox of epoch EP1, {\bf M} is the + $3\times3$ matrix RMATP and + {\bf v}$_{0}$ is the star vector relative to the + mean equator and equinox of epoch EP0. + \item Though the matrix method itself is rigorous, the precession + angles are expressed through canonical polynomials which are + valid only for a limited time span. There are also known + errors in the IAU precession rate. The absolute accuracy + of the present formulation is better than \arcsec{0}{1} from + 1960\,AD to 2040\,AD, better than \arcseci{1} from 1640\,AD to 2360\,AD, + and remains below \arcseci{3} for the whole of the period + 500\,BC to 3000\,AD. The errors exceed \arcseci{10} outside the + range 1200\,BC to 3900\,AD, exceed \arcseci{100} outside 4200\,BC to + 5600\,AD and exceed \arcseci{1000} outside 6800\,BC to 8200\,AD. + The SLALIB routine sla\_PRECL implements a more elaborate + model which is suitable for problems spanning several + thousand years. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item Lieske, J.H., 1979.\ {\it Astr.Astrophys.}\ {\bf 73}, 282; + equations 6 \& 7, p283. + \item Kaplan, G.H., 1981.\ {\it USNO circular no.\ 163}, pA2. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_PRECES}{Precession} +{ + \action{Precession -- either the old ``FK4'' (Bessel-Newcomb, pre~IAU~1976) + or new ``FK5'' (Fricke, post~IAU~1976) as required.} + \call{CALL sla\_PRECES (SYSTEM, EP0, EP1, RA, DC)} +} +\args{GIVEN} +{ + \spec{SYSTEM}{C}{precession to be applied: `FK4' or `FK5'} \\ + \spec{EP0,EP1}{D}{starting and ending epoch} \\ + \spec{RA,DC}{D}{\radec, mean equator \& equinox of epoch EP0} +} +\args{RETURNED} +{ + \spec{RA,DC}{D}{\radec, mean equator \& equinox of epoch EP1} +} +\notes +{ + \begin{enumerate} + \item Lowercase characters in SYSTEM are acceptable. + \item The epochs are Besselian if SYSTEM=`FK4' and Julian if `FK5'. + For example, to precess coordinates in the old system from + equinox 1900.0 to 1950.0 the call would be: + \begin{quote} + {\tt CALL sla\_PRECES ('FK4', 1900D0, 1950D0, RA, DC)} + \end{quote} + \item This routine will {\bf NOT} correctly convert between the old and + the new systems -- for example conversion from B1950 to J2000. + For these purposes see sla\_FK425, sla\_FK524, sla\_FK45Z and + sla\_FK54Z. + \item If an invalid SYSTEM is supplied, values of $-$99D0,$-$99D0 are + returned for both RA and DC. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_PRECL}{Precession Matrix (latest)} +{ + \action{Form the matrix of precession between two epochs, using the + model of Simon {\it et al}.\ (1994), which is suitable for long + periods of time.} + \call{CALL sla\_PRECL (EP0, EP1, RMATP)} +} +\args{GIVEN} +{ + \spec{EP0}{D}{beginning epoch} \\ + \spec{EP1}{D}{ending epoch} +} +\args{RETURNED} +{ + \spec{RMATP}{D(3,3)}{precession matrix} +} +\notes +{ + \begin{enumerate} + \item The epochs are TDB Julian epochs. + \item The matrix is in the sense: + \begin{verse} + {\bf v}$_{1}$ = {\bf M}$\cdot${\bf v}$_{0}$ + \end{verse} + where {\bf v}$_{1}$ is the star vector relative to the + mean equator and equinox of epoch EP1, {\bf M} is the + $3\times3$ matrix RMATP and + {\bf v}$_{0}$ is the star vector relative to the + mean equator and equinox of epoch EP0. + \item The absolute accuracy of the model is limited by the + uncertainty in the general precession, about \arcsec{0}{3} per + 1000~years. The remainder of the formulation provides a + precision of 1~milliarcsecond over the interval from 1000\,AD + to 3000\,AD, \arcsec{0}{1} from 1000\,BC to 5000\,AD and + \arcseci{1} from 4000\,BC to 8000\,AD. + \end{enumerate} +} +\aref{Simon, J.L.\ {\it et al}., 1994.\ {\it Astr.Astrophys.}\ {\bf 282}, + 663.} +%----------------------------------------------------------------------- +\routine{SLA\_PRENUT}{Precession/Nutation Matrix} +{ + \action{Form the matrix of precession and nutation (IAU~1976, FK5).} + \call{CALL sla\_PRENUT (EPOCH, DATE, RMATPN)} +} +\args{GIVEN} +{ + \spec{EPOCH}{D}{Julian Epoch for mean coordinates} \\ + \spec{DATE}{D}{Modified Julian Date (JD$-$2400000.5) + for true coordinates} +} +\args{RETURNED} +{ + \spec{RMATPN}{D(3,3)}{combined precession/nutation matrix} +} +\notes +{ + \begin{enumerate} + \item The epoch and date are TDB. + \item The matrix is in the sense: + \begin{verse} + {\bf v}$_{true}$ = {\bf M}$\cdot${\bf v}$_{mean}$ + \end{verse} + where {\bf v}$_{true}$ is the star vector relative to the + true equator and equinox of epoch DATE, {\bf M} is the + $3\times3$ matrix RMATPN and + {\bf v}$_{mean}$ is the star vector relative to the + mean equator and equinox of epoch EPOCH. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_PV2EL}{Orbital Elements from Position/Velocity} +{ + \action{Heliocentric osculating elements obtained from instantaneous + position and velocity.} + \call{CALL sla\_PV2EL (\vtop{ + \hbox{PV, DATE, PMASS, JFORMR, JFORM, EPOCH, ORBINC,} + \hbox{ANODE, PERIH, AORQ, E, AORL, DM, JSTAT)}}} +} +\args{GIVEN} +{ + \spec{PV}{D(6)}{heliocentric \xyzxyzd, equatorial, J2000} \\ + \spec{}{}{\hspace{1.5em} (AU, AU/s; Note~1)} \\ + \spec{DATE}{D}{date (TT Modified Julian Date = JD$-$2400000.5)} \\ + \spec{PMASS}{D}{mass of the planet (Sun = 1; Note~2)} \\ + \spec{JFORMR}{I}{requested element set (1-3; Note~3)} +} +\args{RETURNED} +{ + \spec{JFORM}{I}{element set actually returned (1-3; Note~4)} \\ + \spec{EPOCH}{D}{epoch of elements ($t_0$ or $T$, TT MJD)} \\ + \spec{ORBINC}{D}{inclination ($i$, radians)} \\ + \spec{ANODE}{D}{longitude of the ascending node ($\Omega$, radians)} \\ + \spec{PERIH}{D}{longitude or argument of perihelion + ($\varpi$ or $\omega$,} \\ + \spec{}{}{\hspace{1.5em} radians)} \\ + \spec{AORQ}{D}{mean distance or perihelion distance ($a$ or $q$, AU)} \\ + \spec{E}{D}{eccentricity ($e$)} \\ + \spec{AORL}{D}{mean anomaly or longitude + ($M$ or $L$, radians,} \\ + \spec{}{}{\hspace{1.5em} JFORM=1,2 only)} \\ + \spec{DM}{D}{daily motion ($n$, radians, JFORM=1 only)} \\ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{2.3em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} $-$1 = illegal PMASS} \\ + \spec{}{}{\hspace{1.5em} $-$2 = illegal JFORMR} \\ + \spec{}{}{\hspace{1.5em} $-$3 = position/velocity out of allowed range} +} +\notes +{ + \begin{enumerate} + \item The PV 6-vector is with respect to the mean equator and equinox of + epoch J2000. The orbital elements produced are with respect to + the J2000 ecliptic and mean equinox. + \item The mass, PMASS, is important only for the larger planets. For + most purposes ({\it e.g.}~asteroids) use 0D0. Values less than zero + are illegal. + \item Three different element-format options are supported, as + follows. \\ + + JFORM=1, suitable for the major planets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> longitude of perihelion $\varpi$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e < 1 )$ \\ + \> AORL \> = \> mean longitude $L$ (radians) \\ + \> DM \> = \> daily motion $n$ (radians) + \end{tabbing} + + JFORM=2, suitable for minor planets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e < 1 )$ \\ + \> AORL \> = \> mean anomaly $M$ (radians) + \end{tabbing} + + JFORM=3, suitable for comets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of perihelion $T$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> perihelion distance $q$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e \leq 10 )$ + \end{tabbing} + \item It may not be possible to generate elements in the form + requested through JFORMR. The caller is notified of the form + of elements actually returned by means of the JFORM argument: + + \begin{tabbing} + xx \= xxxxxxxxxx \= xxxxxxxxxxx \= \kill + \> JFORMR \> JFORM \> meaning \\ \\ + \> ~~~~~1 \> ~~~~~1 \> OK: elements are in the requested format \\ + \> ~~~~~1 \> ~~~~~2 \> never happens \\ + \> ~~~~~1 \> ~~~~~3 \> orbit not elliptical \\ + \> ~~~~~2 \> ~~~~~1 \> never happens \\ + \> ~~~~~2 \> ~~~~~2 \> OK: elements are in the requested format \\ + \> ~~~~~2 \> ~~~~~3 \> orbit not elliptical \\ + \> ~~~~~3 \> ~~~~~1 \> never happens \\ + \> ~~~~~3 \> ~~~~~2 \> never happens \\ + \> ~~~~~3 \> ~~~~~3 \> OK: elements are in the requested format + \end{tabbing} + \item The arguments returned for each value of JFORM ({\it cf}\/ Note~5: + JFORM may not be the same as JFORMR) are as follows: + + \begin{tabbing} + xxx \= xxxxxxxxxxxx \= xxxxxx \= xxxxxx \= \kill + \> JFORM \> 1 \> 2 \> 3 \\ \\ + \> EPOCH \> $t_0$ \> $t_0$ \> $T$ \\ + \> ORBINC \> $i$ \> $i$ \> $i$ \\ + \> ANODE \> $\Omega$ \> $\Omega$ \> $\Omega$ \\ + \> PERIH \> $\varpi$ \> $\omega$ \> $\omega$ \\ + \> AORQ \> $a$ \> $a$ \> $q$ \\ + \> E \> $e$ \> $e$ \> $e$ \\ + \> AORL \> $L$ \> $M$ \> - \\ + \> DM \> $n$ \> - \> - + \end{tabbing} + + where: + \begin{tabbing} + xxx \= xxxxxxxx \= xxx \= \kill + \> $t_0$ \> is the epoch of the elements (MJD, TT) \\ + \> $T$ \> is the epoch of perihelion (MJD, TT) \\ + \> $i$ \> is the inclination (radians) \\ + \> $\Omega$ \> is the longitude of the ascending node (radians) \\ + \> $\varpi$ \> is the longitude of perihelion (radians) \\ + \> $\omega$ \> is the argument of perihelion (radians) \\ + \> $a$ \> is the mean distance (AU) \\ + \> $q$ \> is the perihelion distance (AU) \\ + \> $e$ \> is the eccentricity \\ + \> $L$ \> is the longitude (radians, $0-2\pi$) \\ + \> $M$ \> is the mean anomaly (radians, $0-2\pi$) \\ + \> $n$ \> is the daily motion (radians) \\ + \> - \> means no value is set + \end{tabbing} + \item At very small inclinations, the longitude of the ascending node + ANODE becomes indeterminate and under some circumstances may be + set arbitrarily to zero. Similarly, if the orbit is close to + circular, the true anomaly becomes indeterminate and under some + circumstances may be set arbitrarily to zero. In such cases, + the other elements are automatically adjusted to compensate, + and so the elements remain a valid description of the orbit. + \end{enumerate} +} +\aref{Sterne, Theodore E., {\it An Introduction to Celestial Mechanics,}\/ + Interscience Publishers, 1960.} +%----------------------------------------------------------------------- +\routine{SLA\_PV2UE}{Position/Velocity to Universal Elements} +{ + \action{Construct a universal element set based on an instantaneous + position and velocity.} + \call{CALL sla\_PV2UE (PV, DATE, PMASS, U, JSTAT)} +} +\args{GIVEN} +{ + \spec{PV}{D(6)}{heliocentric \xyzxyzd, equatorial, J2000} \\ + \spec{}{}{\hspace{1.5em} (AU, AU/s; Note~1)} \\ + \spec{DATE}{D}{date (TT Modified Julian Date = JD$-$2400000.5)} \\ + \spec{PMASS}{D}{mass of the planet (Sun = 1; Note~2)} +} +\args{RETURNED} +{ + \spec{U}{D(13)}{universal orbital elements (Note~3)} \\ + \specel {(1)} {combined mass ($M+m$)} \\ + \specel {(2)} {total energy of the orbit ($\alpha$)} \\ + \specel {(3)} {reference (osculating) epoch ($t_0$)} \\ + \specel {(4-6)} {position at reference epoch (${\rm \bf r}_0$)} \\ + \specel {(7-9)} {velocity at reference epoch (${\rm \bf v}_0$)} \\ + \specel {(10)} {heliocentric distance at reference epoch} \\ + \specel {(11)} {${\rm \bf r}_0.{\rm \bf v}_0$} \\ + \specel {(12)} {date ($t$)} \\ + \specel {(13)} {universal eccentric anomaly ($\psi$) of date, approx} \\ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{1.95em} 0 = OK} \\ + \spec{}{}{\hspace{1.2em} $-$1 = illegal PMASS} \\ + \spec{}{}{\hspace{1.2em} $-$2 = too close to Sun} \\ + \spec{}{}{\hspace{1.2em} $-$3 = too slow} +} +\notes +{ + \begin{enumerate} + \item The PV 6-vector can be with respect to any chosen inertial frame, + and the resulting universal-element set will be with respect to + the same frame. A common choice will be mean equator and ecliptic + of epoch J2000. + \item The mass, PMASS, is important only for the larger planets. For + most purposes ({\it e.g.}~asteroids) use 0D0. Values less than zero + are illegal. + \item The ``universal'' elements are those which define the orbit for the + purposes of the method of universal variables (see reference). + They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i)~$\alpha$, which is proportional to the total energy of the + orbit, (ii)~the heliocentric distance at epoch, + (iii)~the outwards component of the velocity at the given epoch, + (iv)~an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v)~that date. + \end{enumerate} +} +\aref{Everhart, E. \& Pitkin, E.T., Am.~J.~Phys.~51, 712, 1983.} +%----------------------------------------------------------------------- +\routine{SLA\_PVOBS}{Observatory Position \& Velocity} +{ + \action{Position and velocity of an observing station.} + \call{CALL sla\_PVOBS (P, H, STL, PV)} +} +\args{GIVEN} +{ + \spec{P}{D}{latitude (geodetic, radians)} \\ + \spec{H}{D}{height above reference spheroid (geodetic, metres)} \\ + \spec{STL}{D}{local apparent sidereal time (radians)} +} +\args{RETURNED} +{ + \spec{PV}{D(6)}{\xyzxyzd\ (AU, AU~s$^{-1}$, true equator and equinox + of date)} +} +\anote{IAU 1976 constants are used.} +%----------------------------------------------------------------------- +\routine{SLA\_PXY}{Apply Linear Model} +{ + \action{Given arrays of {\it expected}\/ and {\it measured}\, + \xy\ coordinates, and a + linear model relating them (as produced by sla\_FITXY), compute + the array of {\it predicted}\/ coordinates and the RMS residuals.} + \call{CALL sla\_PXY (NP,XYE,XYM,COEFFS,XYP,XRMS,YRMS,RRMS)} +} +\args{GIVEN} +{ + \spec{NP}{I}{number of samples} \\ + \spec{XYE}{D(2,NP)}{expected \xy\ for each sample} \\ + \spec{XYM}{D(2,NP)}{measured \xy\ for each sample} \\ + \spec{COEFFS}{D(6)}{coefficients of model (see below)} +} +\args{RETURNED} +{ + \spec{XYP}{D(2,NP)}{predicted \xy\ for each sample} \\ + \spec{XRMS}{D}{RMS in X} \\ + \spec{YRMS}{D}{RMS in Y} \\ + \spec{RRMS}{D }{total RMS (vector sum of XRMS and YRMS)} +} +\notes +{ + \begin{enumerate} + \item The model is supplied in the array COEFFS. Naming the + six elements of COEFFS $a,b,c,d,e$ \& $f$, + the model transforms {\it measured}\/ coordinates + $[x_{m},y_{m}\,]$ into {\it predicted}\/ coordinates + $[x_{p},y_{p}\,]$ as follows: + \begin{verse} + $x_{p} = a + bx_{m} + cy_{m}$ \\ + $y_{p} = d + ex_{m} + fy_{m}$ + \end{verse} + \item The residuals are $(x_{p}-x_{e})$ and $(y_{p}-y_{e})$. + \item If NP is less than or equal to zero, no coordinates are + transformed, and the RMS residuals are all zero. + \item See also sla\_FITXY, sla\_INVF, sla\_XY2XY, sla\_DCMPF + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_RANDOM}{Random Number} +{ + \action{Generate pseudo-random real number in the range $0 \leq x < 1$.} + \call{R~=~sla\_RANDOM (SEED)} +} +\args{GIVEN} +{ + \spec{SEED}{R}{an arbitrary real number} +} +\args{RETURNED} +{ + \spec{SEED}{R}{a new arbitrary value} \\ + \spec{sla\_RANDOM}{R}{Pseudo-random real number $0 \leq x < 1$.} +} +\anote{The implementation is machine-dependent.} +%----------------------------------------------------------------------- +\routine{SLA\_RANGE}{Put Angle into Range $\pm\pi$} +{ + \action{Normalize an angle into the range $\pm\pi$ (single precision).} + \call{R~=~sla\_RANGE (ANGLE)} +} +\args{GIVEN} +{ + \spec{ANGLE}{R}{angle in radians} +} +\args{RETURNED} +{ + \spec{sla\_RANGE}{R}{ANGLE expressed in the range $\pm\pi$.} +} +%----------------------------------------------------------------------- +\routine{SLA\_RANORM}{Put Angle into Range $0\!-\!2\pi$} +{ + \action{Normalize an angle into the range $0\!-\!2\pi$ (single precision).} + \call{R~=~sla\_RANORM (ANGLE)} +} +\args{GIVEN} +{ + \spec{ANGLE}{R}{angle in radians} +} +\args{RETURNED} +{ + \spec{sla\_RANORM}{R}{ANGLE expressed in the range $0\!-\!2\pi$} +} +%----------------------------------------------------------------------- +\routine{SLA\_RCC}{Barycentric Coordinate Time} +{ + \call{D~=~sla\_RCC (TDB, UT1, WL, U, V)} + \action{The relativistic clock correction TDB$-$TT, the + difference between {\it proper time}\, + on Earth and {\it coordinate time}\/ in the solar system barycentric + space-time frame of reference. The proper time is TT; the + coordinate time is {\it an implementation}\/ of TDB.} +} +\args{GIVEN} +{ + \spec{TDB}{D}{coordinate time (MJD: JD$-$2400000.5)} \\ + \spec{UT1}{D}{universal time (fraction of one day)} \\ + \spec{WL}{D}{clock longitude (radians west)} \\ + \spec{U}{D}{clock distance from Earth spin axis (km)} \\ + \spec{V}{D}{clock distance north of Earth equatorial plane (km)} +} +\args{RETURNED} +{ + \spec{sla\_RCC}{D}{TDB$-$TT (sec)} +} +\notes +{ + \begin{enumerate} + \item TDB may be considered to + be the coordinate time in the solar system barycentre frame of + reference, and TT is the proper time given by clocks at mean sea + level on the Earth. + \item The result has a main (annual) sinusoidal term of amplitude + approximately 1.66ms, plus planetary terms up to about + 20$\mu$s, and lunar and diurnal terms up to 2$\mu$s. The + variation arises from the transverse Doppler effect and the + gravitational red-shift as the observer varies in speed and + moves through different gravitational potentials. + \item The argument TDB is, strictly, the barycentric coordinate time; + however, the terrestrial proper time (TT) can in practice be used. + \item The geocentric model is that of Fairhead \& Bretagnon (1990), + in its full + form. It was supplied by Fairhead (private communication) + as a Fortran subroutine. A number of coding changes were made to + this subroutine in order + match the calling sequence of previous versions of the present + routine, to comply with Starlink programming standards and to + avoid compilation problems on certain machines. On the supported + computer types, + the numerical results are essentially unaffected by the + changes. The topocentric model is from Moyer (1981) and Murray (1983). + During the interval 1950-2050, the absolute accuracy of the + geocentric model is better than $\pm3$~nanoseconds + relative to direct numerical integrations using the JPL DE200/LE200 + solar system ephemeris. + \item The IAU definition of TDB is that it must differ from TT only by + periodic terms. Though practical, this is an imprecise definition + which ignores the existence of very long-period and secular effects + in the dynamics of the solar system. As a consequence, different + implementations of TDB will, in general, differ in zero-point and + will drift linearly relative to one other. + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item Fairhead, L.\ \& + Bretagnon, P., 1990.\ {\it Astr.Astrophys.}\ {\bf 229}, 240-247. + \item Moyer, T.D., 1981.\ {\it Cel.Mech.}\ {\bf 23}, 33. + \item Murray, C.A., 1983,\ {\it Vectorial Astrometry}, Adam Hilger. + \end{enumerate} +} +%------------------------------------------------------------------------------ +\routine{SLA\_RDPLAN}{Apparent \radec\ of Planet} +{ + \action{Approximate topocentric apparent \radec\ and angular + size of a planet.} + \call{CALL sla\_RDPLAN (DATE, NP, ELONG, PHI, RA, DEC, DIAM)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{MJD of observation (JD$-$2400000.5)} \\ + \spec{NP}{I}{planet:} \\ + \spec{}{}{\hspace{1.5em} 1\,=\,Mercury} \\ + \spec{}{}{\hspace{1.5em} 2\,=\,Venus} \\ + \spec{}{}{\hspace{1.5em} 3\,=\,Moon} \\ + \spec{}{}{\hspace{1.5em} 4\,=\,Mars} \\ + \spec{}{}{\hspace{1.5em} 5\,=\,Jupiter} \\ + \spec{}{}{\hspace{1.5em} 6\,=\,Saturn} \\ + \spec{}{}{\hspace{1.5em} 7\,=\,Uranus} \\ + \spec{}{}{\hspace{1.5em} 8\,=\,Neptune} \\ + \spec{}{}{\hspace{1.5em} 9\,=\,Pluto} \\ + \spec{}{}{\hspace{0.44em} else\,=\,Sun} \\ + \spec{ELONG,PHI}{D}{observer's longitude (east +ve) and latitude + (radians)} +} +\args{RETURNED} +{ + \spec{RA,DEC}{D}{topocentric apparent \radec\ (radians)} \\ + \spec{DIAM}{D}{angular diameter (equatorial, radians)} +} +\notes +{ + \begin{enumerate} + \item The date is in a dynamical timescale (TDB, formerly ET) + and is in the form of a Modified + Julian Date (JD$-$2400000.5). For all practical purposes, TT can + be used instead of TDB, and for many applications UT will do + (except for the Moon). + \item The longitude and latitude allow correction for geocentric + parallax. This is a major effect for the Moon, but in the + context of the limited accuracy of the present routine its + effect on planetary positions is small (negligible for the + outer planets). Geocentric positions can be generated by + appropriate use of the routines sla\_DMOON and sla\_PLANET. + \item The direction accuracy (arcsec, 1000-3000\,AD) is of order: + \begin{tabbing} + xxxxxxx \= xxxxxxxxxxxxxxxxxx \= \kill + \> Sun \> \hspace{0.5em}5 \\ + \> Mercury \> \hspace{0.5em}2 \\ + \> Venus \> 10 \\ + \> Moon \> 30 \\ + \> Mars \> 50 \\ + \> Jupiter \> 90 \\ + \> Saturn \> 90 \\ + \> Uranus \> 90 \\ + \> Neptune \> 10 \\ + \> Pluto \> \hspace{0.5em}1~~~(1885-2099\,AD only) + \end{tabbing} + The angular diameter accuracy is about 0.4\% for the Moon, + and 0.01\% or better for the Sun and planets. + For more information on accuracy, + refer to the routines sla\_PLANET and sla\_DMOON, + which the present routine uses. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_REFCO}{Refraction Constants} +{ + \action{Determine the constants $a$ and $b$ in the + atmospheric refraction model + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$, + where $\zeta$ is the {\it observed}\/ zenith distance + ({\it i.e.}\ affected by refraction) and $\Delta \zeta$ is + what to add to $\zeta$ to give the {\it topocentric}\, + ({\it i.e.\ in vacuo}) zenith distance.} + \call{CALL sla\_REFCO (HM, TDK, PMB, RH, WL, PHI, TLR, EPS, REFA, REFB)} +} +\args{GIVEN} +{ + \spec{HM}{D}{height of the observer above sea level (metre)} \\ + \spec{TDK}{D}{ambient temperature at the observer (degrees K)} \\ + \spec{PMB}{D}{pressure at the observer (mB)} \\ + \spec{RH}{D}{relative humidity at the observer (range 0\,--\,1)} \\ + \spec{WL}{D}{effective wavelength of the source ($\mu{\rm m}$)} \\ + \spec{PHI}{D}{latitude of the observer (radian, astronomical)} \\ + \spec{TLR}{D}{temperature lapse rate in the troposphere + (degrees K per metre)} \\ + \spec{EPS}{D}{precision required to terminate iteration (radian)} +} +\args{RETURNED} +{ + \spec{REFA}{D}{$\tan \zeta$ coefficient (radians)} \\ + \spec{REFB}{D}{$\tan^{3} \zeta$ coefficient (radians)} +} +\notes +{ + \begin{enumerate} + \item Suggested values for the TLR and EPS arguments are 0.0065D0 and + 1D$-$8 respectively. + \item The radio refraction is chosen by specifying WL $>100$~$\mu{\rm m}$. + \item The routine is a slower but more accurate alternative to the + sla\_REFCOQ routine. The constants it produces give perfect + agreement with sla\_REFRO at zenith distances + $\tan^{-1} 1$ ($45^\circ$) and $\tan^{-1} 4$ ($\sim 76^\circ$). + At other zenith distances, the model achieves: + \arcsec{0}{5} accuracy for $\zeta<80^{\circ}$, + \arcsec{0}{01} accuracy for $\zeta<60^{\circ}$, and + \arcsec{0}{001} accuracy for $\zeta<45^{\circ}$. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_REFCOQ}{Refraction Constants (fast)} +{ + \action{Determine the constants $a$ and $b$ in the + atmospheric refraction model + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$, + where $\zeta$ is the {\it observed}\/ zenith distance + ({\it i.e.}\ affected by refraction) and $\Delta \zeta$ is + what to add to $\zeta$ to give the {\it topocentric}\, + ({\it i.e.\ in vacuo}) zenith distance. (This is a fast + alternative to the sla\_REFCO routine -- see notes.)} + \call{CALL sla\_REFCOQ (TDK, PMB, RH, WL, REFA, REFB)} +} +\args{GIVEN} +{ + \spec{TDK}{D}{ambient temperature at the observer (degrees K)} \\ + \spec{PMB}{D}{pressure at the observer (mB)} \\ + \spec{RH}{D}{relative humidity at the observer (range 0\,--\,1)} \\ + \spec{WL}{D}{effective wavelength of the source ($\mu{\rm m}$)} +} +\args{RETURNED} +{ + \spec{REFA}{D}{$\tan \zeta$ coefficient (radians)} \\ + \spec{REFB}{D}{$\tan^{3} \zeta$ coefficient (radians)} +} +\notes +{ + \begin{enumerate} + \item The radio refraction is chosen by specifying WL $>100$~$\mu{\rm m}$. + \item The model is an approximation, for moderate zenith distances, + to the predictions of the sla\_REFRO routine. The approximation + is maintained across a range of conditions, and applies to + both optical/IR and radio. + \item The algorithm is a fast alternative to the sla\_REFCO routine. + The latter calls the sla\_REFRO routine itself: this involves + integrations through a model atmosphere, and is costly in + processor time. However, the model which is produced is precisely + correct for two zenith distances ($45^\circ$ and $\sim\!76^\circ$) + and at other zenith distances is limited in accuracy only by the + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ formulation + itself. The present routine is not as accurate, though it + satisfies most practical requirements. + \item The model omits the effects of (i)~height above sea level (apart + from the reduced pressure itself), (ii)~latitude ({\it i.e.}\ the + flattening of the Earth) and (iii)~variations in tropospheric + lapse rate. + \item The model has been tested using the following range of conditions: + \begin{itemize} + \item [$\cdot$] lapse rates 0.0055, 0.0065, 0.0075~degrees K per metre + \item [$\cdot$] latitudes $0^\circ$, $25^\circ$, $50^\circ$, $75^\circ$ + \item [$\cdot$] heights 0, 2500, 5000 metres above sea level + \item [$\cdot$] pressures mean for height $-10$\% to $+5$\% in steps of $5$\% + \item [$\cdot$] temperatures $-10^\circ$ to $+20^\circ$ with respect to + $280^\circ$K at sea level + \item [$\cdot$] relative humidity 0, 0.5, 1 + \item [$\cdot$] wavelength 0.4, 0.6, \ldots\ $2\mu{\rm m}$, + radio + \item [$\cdot$] zenith distances $15^\circ$, $45^\circ$, $75^\circ$ + \end{itemize} + For the above conditions, the comparison with sla\_REFRO + was as follows: + + \vspace{2ex} + + ~~~~~~~~~~ + \begin{tabular}{|r|r|r|} \hline + & {\it worst} & {\it RMS} \\ \hline + optical/IR & 62 & 8 \\ + radio & 319 & 49 \\ \hline + & mas & mas \\ \hline + \end{tabular} + + \vspace{3ex} + + For this particular set of conditions: + \begin{itemize} + \item [$\cdot$] lapse rate $6.5^\circ K km^{-1}$ + \item [$\cdot$] latitude $50^\circ$ + \item [$\cdot$] sea level + \item [$\cdot$] pressure 1005\,mB + \item [$\cdot$] temperature $7^\circ$C + \item [$\cdot$] humidity 80\% + \item [$\cdot$] wavelength 5740\,\.{A} + \end{itemize} + the results were as follows: + + \vspace{2ex} + + ~~~~~~~~~~ + \begin{tabular}{|r|r|r|r|} \hline + \multicolumn{1}{|c}{$\zeta$} & + \multicolumn{1}{|c}{sla\_REFRO} & + \multicolumn{1}{|c}{sla\_REFCOQ} & + \multicolumn{1}{|c|}{Saastamoinen} \\ \hline + 10 & 10.27 & 10.27 & 10.27 \\ + 20 & 21.19 & 21.20 & 21.19 \\ + 30 & 33.61 & 33.61 & 33.60 \\ + 40 & 48.82 & 48.83 & 48.81 \\ + 45 & 58.16 & 58.18 & 58.16 \\ + 50 & 69.28 & 69.30 & 69.27 \\ + 55 & 82.97 & 82.99 & 82.95 \\ + 60 & 100.51 & 100.54 & 100.50 \\ + 65 & 124.23 & 124.26 & 124.20 \\ + 70 & 158.63 & 158.68 & 158.61 \\ + 72 & 177.32 & 177.37 & 177.31 \\ + 74 & 200.35 & 200.38 & 200.32 \\ + 76 & 229.45 & 229.43 & 229.42 \\ + 78 & 267.44 & 267.29 & 267.41 \\ + 80 & 319.13 & 318.55 & 319.10 \\ \hline + deg & arcsec & arcsec & arcsec \\ \hline + \end{tabular} + + \vspace{3ex} + + The values for Saastamoinen's formula (which includes terms + up to $\tan^5$) are taken from Hohenkerk and Sinclair (1985). + + The results from the much slower but more accurate sla\_REFCO + routine have not been included in the tabulation as they are + identical to those in the sla\_REFRO column to the \arcsec{0}{01} + resolution used. + \item Outlandish input parameters are silently limited + to mathematically safe values. Zero pressure is permissible, + and causes zeroes to be returned. + \item The algorithm draws on several sources, as follows: + \begin{itemize} + \item The formula for the saturation vapour pressure of water as + a function of temperature and temperature is taken from + expressions A4.5-A4.7 of Gill (1982). + \item The formula for the water vapour pressure, given the + saturation pressure and the relative humidity is from + Crane (1976), expression 2.5.5. + \item The refractivity of air is a function of temperature, + total pressure, water-vapour pressure and, in the case + of optical/IR but not radio, wavelength. The formulae + for the two cases are developed from the Essen and Froome + expressions adopted in Resolution 1 of the 12th International + Geodesy Association General Assembly (1963). + \end{itemize} + The above three items are as used in the sla\_REFRO routine. + \begin{itemize} + \item The formula for $\beta~(=H_0/r_0)$ is + an adaption of expression 9 from Stone (1996). The + adaptations, arrived at empirically, consist of (i)~a + small adjustment to the coefficient and (ii)~a humidity + term for the radio case only. + \item The formulae for the refraction constants as a function of + $n-1$ and $\beta$ are from Green (1987), expression 4.31. + \end{itemize} + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item Crane, R.K., Meeks, M.L.\ (ed), ``Refraction Effects in + the Neutral Atmosphere'', + {\it Methods of Experimental Physics: Astrophysics 12B,}\/ + Academic Press, 1976. + \item Gill, Adrian E., {\it Atmosphere-Ocean Dynamics,}\/ + Academic Press, 1982. + \item Hohenkerk, C.Y., \& Sinclair, A.T., NAO Technical Note + No.~63, 1985. + \item International Geodesy Association General Assembly, Bulletin + G\'{e}od\'{e}sique {\bf 70} p390, 1963. + \item Stone, Ronald C., P.A.S.P.~{\bf 108} 1051-1058, 1996. + \item Green, R.M., {\it Spherical Astronomy,}\/ Cambridge + University Press, 1987. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_REFRO}{Refraction} +{ + \action{Atmospheric refraction, for radio or optical/IR wavelengths.} + \call{CALL sla\_REFRO (ZOBS, HM, TDK, PMB, RH, WL, PHI, TLR, EPS, REF)} +} +\args{GIVEN} +{ + \spec{ZOBS}{D}{observed zenith distance of the source (radians)} \\ + \spec{HM}{D}{height of the observer above sea level (metre)} \\ + \spec{TDK}{D}{ambient temperature at the observer (degrees K)} \\ + \spec{PMB}{D}{pressure at the observer (mB)} \\ + \spec{RH}{D}{relative humidity at the observer (range 0\,--\,1)} \\ + \spec{WL}{D}{effective wavelength of the source ($\mu{\rm m}$)} \\ + \spec{PHI}{D}{latitude of the observer (radian, astronomical)} \\ + \spec{TLR}{D}{temperature lapse rate in the troposphere + (degrees K per metre)} \\ + \spec{EPS}{D}{precision required to terminate iteration (radian)} +} +\args{RETURNED} +{ + \spec{REF}{D}{refraction: {\it in vacuo}\/ ZD minus observed ZD (radians)} +} +\notes +{ + \begin{enumerate} + \item A suggested value for the TLR argument is 0.0065D0. The + refraction is significantly affected by TLR, and if studies + of the local atmosphere have been carried out a better TLR + value may be available. + \item A suggested value for the EPS argument is 1D$-$8. The result is + usually at least two orders of magnitude more computationally + precise than the supplied EPS value. + \item The routine computes the refraction for zenith distances up + to and a little beyond $90^\circ$ using the method of Hohenkerk + \& Sinclair (NAO Technical Notes 59 and 63, subsequently adopted + in the {\it Explanatory Supplement to the Astronomical Almanac,}\/ + 1992 -- see section 3.281). + \item The code is based on the AREF optical/IR refraction subroutine + of C.\,Hohenkerk (HMNAO, September 1984), with extensions to + support the radio case. The modifications to the original HMNAO + optical/IR refraction code which affect the results are: + \begin{itemize} + \item Murray's values for the gas constants have been used + ({\it Vectorial Astrometry,}\/ Adam Hilger, 1983). + \item A better model for $P_s(T)$ has been adopted (taken from + Gill, {\it Atmosphere-Ocean Dynamics,}\/ Academic Press, 1982). + \item More accurate expressions for $Pw_o$ have been adopted + (again from Gill 1982). + \item Provision for radio wavelengths has been added using + expressions devised by A.\,T.\,Sinclair, RGO (private + communication 1989), based on the Essen \& Froome + refractivity formula adopted in Resolution~1 of the + 12th International Geodesy Association General Assembly + (Bulletin G\'{e}od\'{e}sique {\bf 70} p390, 1963). + \end{itemize} + None of the changes significantly affects the optical/IR results + with respect to the algorithm given in the 1992 {\it Explanatory + Supplement.}\/ For example, at $70^\circ$ zenith distance the present + routine agrees with the ES algorithm to better than \arcsec{0}{05} + for any reasonable combination of parameters. However, the + improved water-vapour expressions do make a significant difference + in the radio band, at $70^\circ$ zenith distance reaching almost + \arcseci{4} for a hot, humid, low-altitude site during a period of + low pressure. + \item The radio refraction is chosen by specifying WL $>100$~$\mu{\rm m}$. + Because the algorithm takes no account of the ionosphere, the + accuracy deteriorates at low frequencies, below about 30\,MHz. + \item Before use, the value of ZOBS is expressed in the range $\pm\pi$. + If this ranged ZOBS is negative, the result REF is computed from its + absolute value before being made negative to match. In addition, if + it has an absolute value greater than $93^\circ$, a fixed REF value + equal to the result for ZOBS~$=93^\circ$ is returned, appropriately + signed. + \item As in the original Hohenkerk and Sinclair algorithm, fixed values + of the water vapour polytrope exponent, the height of the + tropopause, and the height at which refraction is negligible are + used. + \item The radio refraction has been tested against work done by + Iain~Coulson, JACH, (private communication 1995) for the + James Clerk Maxwell Telescope, Mauna Kea. For typical conditions, + agreement at the \arcsec{0}{1} level is achieved for moderate ZD, + worsening to perhaps \arcsec{0}{5}\,--\,\arcsec{1}{0} at ZD $80^\circ$. + At hot and humid sea-level sites the accuracy will not be as good. + \item It should be noted that the relative humidity RH is formally + defined in terms of ``mixing ratio'' rather than pressures or + densities as is often stated. It is the mass of water per unit + mass of dry air divided by that for saturated air at the same + temperature and pressure (see Gill 1982). The familiar + $\nu=p_w/p_s$ or $\nu=\rho_w/\rho_s$ expressions can differ from + the formal definition by several percent, significant in the + radio case. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_REFV}{Apply Refraction to Vector} +{ + \action{Adjust an unrefracted Cartesian vector to include the effect of + atmospheric refraction, using the simple + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ model.} + \call{CALL sla\_REFV (VU, REFA, REFB, VR)} +} +\args{GIVEN} +{ + \spec{VU}{D}{unrefracted position of the source (\azel\ 3-vector)} \\ + \spec{REFA}{D}{$\tan \zeta$ coefficient (radians)} \\ + \spec{REFB}{D}{$\tan^{3} \zeta$ coefficient (radians)} +} +\args{RETURNED} +{ + \spec{VR}{D}{refracted position of the source (\azel\ 3-vector)} +} +\notes +{ + \begin{enumerate} + \item This routine applies the adjustment for refraction in the + opposite sense to the usual one -- it takes an unrefracted + ({\it in vacuo}\/) position and produces an observed (refracted) + position, whereas the + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ + model strictly + applies to the case where an observed position is to have the + refraction removed. The unrefracted to refracted case is + harder, and requires an inverted form of the text-book + refraction models; the algorithm used here is equivalent to + one iteration of the Newton-Raphson method applied to the + above formula. + \item Though optimized for speed rather than precision, the present + routine achieves consistency with the refracted-to-unrefracted + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ + model at better than 1~microarcsecond within + $30^\circ$ of the zenith and remains within 1~milliarcsecond to + $\zeta=70^\circ$. The inherent accuracy of the model is, of + course, far worse than this -- see the documentation for sla\_REFCO + for more information. + \item At low elevations (below about $3^\circ$) the refraction + correction is held back to prevent arithmetic problems and + wildly wrong results. Over a wide range of observer heights + and corresponding temperatures and pressures, the following + levels of accuracy are achieved, relative to numerical + integration through a model atmosphere: + + \begin{center} + \begin{tabular}{ccl} + $\zeta_{obs}$ & {\it error} \\ \\ + $80^\circ$ & \arcsec{0}{4} \\ + $81^\circ$ & \arcsec{0}{8} \\ + $82^\circ$ & \arcsec{1}{6} \\ + $83^\circ$ & \arcseci{3} \\ + $84^\circ$ & \arcseci{7} \\ + $85^\circ$ & \arcseci{17} \\ + $86^\circ$ & \arcseci{45} \\ + $87^\circ$ & \arcseci{150} \\ + $88^\circ$ & \arcseci{340} \\ + $89^\circ$ & \arcseci{620} \\ + $90^\circ$ & \arcseci{1100} \\ + $91^\circ$ & \arcseci{1900} & $<$ high-altitude \\ + $92^\circ$ & \arcseci{3200} & $<$ sites only \\ + \end{tabular} + \end{center} + \item See also the routine sla\_REFZ, which performs the adjustment to + the zenith distance rather than in \xyz . + The present routine is faster than sla\_REFZ and, + except very low down, + is equally accurate for all practical purposes. However, beyond + about $\zeta=84^\circ$ sla\_REFZ should be used, and for the utmost + accuracy iterative use of sla\_REFRO should be considered. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_REFZ}{Apply Refraction to ZD} +{ + \action{Adjust an unrefracted zenith distance to include the effect of + atmospheric refraction, using the simple + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ model.} + \call{CALL sla\_REFZ (ZU, REFA, REFB, ZR)} +} +\args{GIVEN} +{ + \spec{ZU}{D}{unrefracted zenith distance of the source (radians)} \\ + \spec{REFA}{D}{$\tan \zeta$ coefficient (radians)} \\ + \spec{REFB}{D}{$\tan^{3} \zeta$ coefficient (radians)} +} +\args{RETURNED} +{ + \spec{ZR}{D}{refracted zenith distance (radians)} +} +\notes +{ + \begin{enumerate} + \item This routine applies the adjustment for refraction in the + opposite sense to the usual one -- it takes an unrefracted + ({\it in vacuo}\/) position and produces an observed (refracted) + position, whereas the + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ + model strictly + applies to the case where an observed position is to have the + refraction removed. The unrefracted to refracted case is + harder, and requires an inverted form of the text-book + refraction models; the formula used here is based on the + Newton-Raphson method. For the utmost numerical consistency + with the refracted to unrefracted model, two iterations are + carried out, achieving agreement at the $10^{-11}$~arcsecond level + for $\zeta=80^\circ$. The inherent accuracy of the model + is, of course, far worse than this -- see the documentation for + sla\_REFCO for more information. + \item At $\zeta=83^\circ$, the rapidly-worsening + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ + model is abandoned and an empirical formula takes over: + + \[\Delta \zeta = F \left( + \frac{0^\circ\hspace{-0.37em}.\hspace{0.02em}55445 + - 0^\circ\hspace{-0.37em}.\hspace{0.02em}01133 E + + 0^\circ\hspace{-0.37em}.\hspace{0.02em}00202 E^2} + {1 + 0.28385 E +0.02390 E^2} \right) \] + where $E=90^\circ-\zeta_{true}$ + and $F$ is a factor chosen to meet the + $\Delta \zeta = a \tan \zeta + b \tan^{3} \zeta$ + formula at $\zeta=83^\circ$. Over a + wide range of observer heights and corresponding temperatures and + pressures, the following levels of accuracy are achieved, + relative to numerical integration through a model atmosphere: + + \begin{center} + \begin{tabular}{ccl} + $\zeta_{obs}$ & {\it error} \\ \\ + $80^\circ$ & \arcsec{0}{4} \\ + $81^\circ$ & \arcsec{0}{8} \\ + $82^\circ$ & \arcsec{1}{5} \\ + $83^\circ$ & \arcsec{3}{2} \\ + $84^\circ$ & \arcsec{4}{9} \\ + $85^\circ$ & \arcsec{5}{8} \\ + $86^\circ$ & \arcsec{6}{1} \\ + $87^\circ$ & \arcsec{7}{1} \\ + $88^\circ$ & \arcseci{11} \\ + $89^\circ$ & \arcseci{21} \\ + $90^\circ$ & \arcseci{43} \\ + $91^\circ$ & \arcseci{92} & $<$ high-altitude \\ + $92^\circ$ & \arcseci{220} & $<$ sites only \\ + \end{tabular} + \end{center} + \item See also the routine sla\_REFV, which performs the adjustment in + \xyz , and with the emphasis on speed rather than numerical accuracy. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_RVEROT}{RV Corrn to Earth Centre} +{ + \action{Velocity component in a given direction due to Earth rotation.} + \call{R~=~sla\_RVEROT (PHI, RA, DA, ST)} +} +\args{GIVEN} +{ + \spec{PHI}{R}{geodetic latitude of observing station (radians)} \\ + \spec{RA,DA}{R}{apparent \radec\ (radians)} \\ + \spec{ST}{R}{local apparent sidereal time (radians)} +} +\args{RETURNED} +{ + \spec{sla\_RVEROT}{R}{Component of Earth rotation in + direction RA,DA (km~s$^{-1}$)} +} +\notes +{ + \begin{enumerate} + \item Sign convention: the result is positive when the observatory + is receding from the given point on the sky. + \item Accuracy: the simple algorithm used assumes a spherical Earth and + an observing station at sea level; for actual observing + sites, the error is unlikely to be greater than 0.0005~km~s$^{-1}$. + For applications requiring greater precision, use the routine + sla\_PVOBS. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_RVGALC}{RV Corrn to Galactic Centre} +{ + \action{Velocity component in a given direction due to the rotation + of the Galaxy.} + \call{R~=~sla\_RVGALC (R2000, D2000)} +} +\args{GIVEN} +{ + \spec{R2000,D2000}{R}{J2000.0 mean \radec\ (radians)} +} +\args{RETURNED} +{ + \spec{sla\_RVGALC}{R}{Component of dynamical LSR motion in direction + R2000,D2000 (km~s$^{-1}$)} +} +\notes +{ + \begin{enumerate} + \item Sign convention: the result is positive when the LSR + is receding from the given point on the sky. + \item The Local Standard of Rest used here is a point in the + vicinity of the Sun which is in a circular orbit around + the Galactic centre. Sometimes called the {\it dynamical}\/ LSR, + it is not to be confused with a {\it kinematical}\/ LSR, which + is the mean standard of rest of star catalogues or stellar + populations. + \item The dynamical LSR velocity due to Galactic rotation is assumed to + be 220~km~s$^{-1}$ towards $l^{I\!I}=90^{\circ}$, + $b^{I\!I}=0$. + \end{enumerate} +} +\aref{Kerr \& Lynden-Bell (1986), MNRAS, 221, p1023.} +%----------------------------------------------------------------------- +\routine{SLA\_RVLG}{RV Corrn to Local Group} +{ + \action{Velocity component in a given direction due to the combination + of the rotation of the Galaxy and the motion of the Galaxy + relative to the mean motion of the local group.} + \call{R~=~sla\_RVLG (R2000, D2000)} +} +\args{GIVEN} +{ + \spec{R2000,D2000}{R}{J2000.0 mean \radec\ (radians)} +} +\args{RETURNED} +{ + \spec{sla\_RVLG}{R}{Component of {\bf solar} ({\it n.b.}) + motion in direction R2000,D2000 (km~s$^{-1}$)} +} +\anote{Sign convention: the result is positive when + the Sun is receding from the given point on the sky.} +\aref{{\it IAU Trans.}\ 1976.\ {\bf 16B}, p201.} +%----------------------------------------------------------------------- +\routine{SLA\_RVLSRD}{RV Corrn to Dynamical LSR} +{ + \action{Velocity component in a given direction due to the Sun's + motion with respect to the ``dynamical'' Local Standard of Rest.} + \call{R~=~sla\_RVLSRD (R2000, D2000)} +} +\args{GIVEN} +{ + \spec{R2000,D2000}{R}{J2000.0 mean \radec\ (radians)} +} +\args{RETURNED} +{ + \spec{sla\_RVLSRD}{R}{Component of {\it peculiar}\/ solar motion + in direction R2000,D2000 (km~s$^{-1}$)} +} +\notes +{ + \begin{enumerate} + \item Sign convention: the result is positive when + the Sun is receding from the given point on the sky. + \item The Local Standard of Rest used here is the {\it dynamical}\/ LSR, + a point in the vicinity of the Sun which is in a circular + orbit around the Galactic centre. The Sun's motion with + respect to the dynamical LSR is called the {\it peculiar}\/ solar + motion. + \item There is another type of LSR, called a {\it kinematical}\/ LSR. A + kinematical LSR is the mean standard of rest of specified star + catalogues or stellar populations, and several slightly + different kinematical LSRs are in use. The Sun's motion with + respect to an agreed kinematical LSR is known as the + {\it standard}\/ solar motion. + The dynamical LSR is seldom used by observational astronomers, + who conventionally use a kinematical LSR such as the one implemented + in the routine sla\_RVLSRK. + \item The peculiar solar motion is from Delhaye (1965), in {\it Stars + and Stellar Systems}, vol~5, p73: in Galactic Cartesian + coordinates (+9,+12,+7)~km~s$^{-1}$. + This corresponds to about 16.6~km~s$^{-1}$ + towards Galactic coordinates $l^{I\!I}=53^{\circ},b^{I\!I}=+25^{\circ}$. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_RVLSRK}{RV Corrn to Kinematical LSR} +{ + \action{Velocity component in a given direction due to the Sun's + motion with respect to a kinematical Local Standard of Rest.} + \call{R~=~sla\_RVLSRK (R2000, D2000)} +} +\args{GIVEN} +{ + \spec{R2000,D2000}{R}{J2000.0 mean \radec\ (radians)} +} +\args{RETURNED} +{ + \spec{sla\_RVLSRK}{R}{Component of {\it standard}\/ solar motion + in direction R2000,D2000 (km~s$^{-1}$)} +} +\notes +{ + \begin{enumerate} + \item Sign convention: the result is positive when + the Sun is receding from the given point on the sky. + \item The Local Standard of Rest used here is one of several + {\it kinematical}\/ LSRs in common use. A kinematical LSR is the + mean standard of rest of specified star catalogues or stellar + populations. The Sun's motion with respect to a kinematical + LSR is known as the {\it standard}\/ solar motion. + \item There is another sort of LSR, seldom used by observational + astronomers, called the {\it dynamical}\/ LSR. This is a + point in the vicinity of the Sun which is in a circular orbit + around the Galactic centre. The Sun's motion with respect to + the dynamical LSR is called the {\it peculiar}\/ solar motion. To + obtain a radial velocity correction with respect to the + dynamical LSR use the routine sla\_RVLSRD. + \item The adopted standard solar motion is 20~km~s$^{-1}$ + towards $\alpha=18^{\rm h},\delta=+30^{\circ}$ (1900). + \end{enumerate} +} +\refs +{ + \begin{enumerate} + \item Delhaye (1965), in {\it Stars and Stellar Systems}, vol~5, p73. + \item {\it Methods of Experimental Physics}\/ (ed Meeks), vol~12, + part~C, sec~6.1.5.2, p281. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_S2TP}{Spherical to Tangent Plane} +{ + \action{Projection of spherical coordinates onto the tangent plane + (single precision).} + \call{CALL sla\_S2TP (RA, DEC, RAZ, DECZ, XI, ETA, J)} +} +\args{GIVEN} +{ + \spec{RA,DEC}{R}{spherical coordinates of star (radians)} \\ + \spec{RAZ,DECZ}{R}{spherical coordinates of tangent point (radians)} +} +\args{RETURNED} +{ + \spec{XI,ETA}{R}{tangent plane coordinates (radians)} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK, star on tangent plane} \\ + \spec{}{}{\hspace{1.5em} 1 = error, star too far from axis} \\ + \spec{}{}{\hspace{1.5em} 2 = error, antistar on tangent plane} \\ + \spec{}{}{\hspace{1.5em} 3 = error, antistar too far from axis} +} +\notes +{ + \begin{enumerate} + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item When working in \xyz\ rather than spherical coordinates, the + equivalent Cartesian routine sla\_V2TP is available. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_SEP}{Angle Between 2 Points on Sphere} +{ + \action{Angle between two points on a sphere (single precision).} + \call{R~=~sla\_SEP (A1, B1, A2, B2)} +} +\args{GIVEN} +{ + \spec{A1,B1}{R}{spherical coordinates of one point (radians)} \\ + \spec{A2,B2}{R}{spherical coordinates of the other point (radians)} +} +\args{RETURNED} +{ + \spec{sla\_SEP}{R}{angle between [A1,B1] and [A2,B2] in radians} +} +\notes +{ + \begin{enumerate} + \item The spherical coordinates are right ascension and declination, + longitude and latitude, {\it etc.}\ in radians. + \item The result is always positive. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_SMAT}{Solve Simultaneous Equations} +{ + \action{Matrix inversion and solution of simultaneous equations + (single precision).} + \call{CALL sla\_SMAT (N, A, Y, D, JF, IW)} +} +\args{GIVEN} +{ + \spec{N}{I}{number of unknowns} \\ + \spec{A}{R(N,N)}{matrix} \\ + \spec{Y}{R(N)}{vector} +} +\args{RETURNED} +{ + \spec{A}{R(N,N)}{matrix inverse} \\ + \spec{Y}{R(N)}{solution} \\ + \spec{D}{R}{determinant} \\ + \spec{JF}{I}{singularity flag: 0=OK} \\ + \spec{IW}{I(N)}{workspace} +} +\notes +{ + \begin{enumerate} + \item For the set of $n$ simultaneous linear equations in $n$ unknowns: + \begin{verse} + {\bf A}$\cdot${\bf y} = {\bf x} + \end{verse} + where: + \begin{itemize} + \item {\bf A} is a non-singular $n \times n$ matrix, + \item {\bf y} is the vector of $n$ unknowns, and + \item {\bf x} is the known vector, + \end{itemize} + sla\_SMAT computes: + \begin{itemize} + \item the inverse of matrix {\bf A}, + \item the determinant of matrix {\bf A}, and + \item the vector of $n$ unknowns {\bf y}. + \end{itemize} + Argument N is the order $n$, A (given) is the matrix {\bf A}, + Y (given) is the vector {\bf x} and Y (returned) + is the vector {\bf y}. + The argument A (returned) is the inverse matrix {\bf A}$^{-1}$, + and D is {\it det}\/({\bf A}). + \item JF is the singularity flag. If the matrix is non-singular, + JF=0 is returned. If the matrix is singular, JF=$-$1 + and D=0.0 are returned. In the latter case, the contents + of array A on return are undefined. + \item The algorithm is Gaussian elimination with partial pivoting. + This method is very fast; some much slower algorithms can give + better accuracy, but only by a small factor. + \item This routine replaces the obsolete sla\_SMATRX. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_SUBET}{Remove E-terms} +{ + \action{Remove the E-terms (elliptic component of annual aberration) + from a pre IAU~1976 catalogue \radec\ to give a mean place.} + \call{CALL sla\_SUBET (RC, DC, EQ, RM, DM)} +} +\args{GIVEN} +{ + \spec{RC,DC}{D}{\radec\ with E-terms included (radians)} \\ + \spec{EQ}{D}{Besselian epoch of mean equator and equinox} +} +\args{RETURNED} +{ + \spec{RM,DM}{D}{\radec\ without E-terms (radians)} +} +\anote{Most star positions from pre-1984 optical catalogues (or + obtained by astrometry with respect to such stars) have the + E-terms built-in. This routine converts such a position to a + formal mean place (allowing, for example, comparison with a + pulsar timing position).} +\aref{{\it Explanatory Supplement to the Astronomical Ephemeris}, + section 2D, page 48.} +%----------------------------------------------------------------------- +\routine{SLA\_SUPGAL}{Supergalactic to Galactic} +{ + \action{Transformation from de Vaucouleurs supergalactic coordinates + to IAU 1958 galactic coordinates.} + \call{CALL sla\_GALSUP (DL, DB, DSL, DSB)} +} +\args{GIVEN} +{ + \spec{DSL,DSB}{D}{supergalactic longitude and latitude (radians)} +} +\args{RETURNED} +{ + \spec{DL,DB}{D}{galactic longitude and latitude \gal\ (radians)} +} +\refs +{ + \begin{enumerate} + \item de Vaucouleurs, de Vaucouleurs, \& Corwin, {\it Second Reference + Catalogue of Bright Galaxies}, U.Texas, p8. + \item Systems \& Applied Sciences Corp., documentation for the + machine-readable version of the above catalogue, + Contract NAS 5-26490. + \end{enumerate} + (These two references give different values for the galactic + longitude of the supergalactic origin. Both are wrong; the + correct value is $l^{I\!I}=137.37$.) +} +%------------------------------------------------------------------------------ +\routine{SLA\_SVD}{Singular Value Decomposition} +{ + \action{Singular value decomposition. + This routine expresses a given matrix {\bf A} as the product of + three matrices {\bf U}, {\bf W}, {\bf V}$^{T}$: + \begin{tabbing} + XXXXXX \= \kill + \> {\bf A} = {\bf U} $\cdot$ {\bf W} $\cdot$ {\bf V}$^{T}$ + \end{tabbing} + where: + \begin{tabbing} + XXXXXX \= XXXX \= \kill + \> {\bf A} \> is any $m$ (rows) $\times n$ (columns) matrix, + where $m \geq n$ \\ + \> {\bf U} \> is an $m \times n$ column-orthogonal matrix \\ + \> {\bf W} \> is an $n \times n$ diagonal matrix with + $w_{ii} \geq 0$ \\ + \> {\bf V}$^{T}$ \> is the transpose of an $n \times n$ + orthogonal matrix +\end{tabbing} +} + \call{CALL sla\_SVD (M, N, MP, NP, A, W, V, WORK, JSTAT)} +} +\args{GIVEN} +{ + \spec{M,N}{I}{$m$, $n$, the numbers of rows and columns in matrix {\bf A}} \\ + \spec{MP,NP}{I}{physical dimensions of array containing matrix {\bf A}} \\ + \spec{A}{D(MP,NP)}{array containing $m \times n$ matrix {\bf A}} +} +\args{RETURNED} +{ + \spec{A}{D(MP,NP)}{array containing $m \times n$ column-orthogonal + matrix {\bf U}} \\ + \spec{W}{D(N)}{$n \times n$ diagonal matrix {\bf W} + (diagonal elements only)} \\ + \spec{V}{D(NP,NP)}{array containing $n \times n$ orthogonal + matrix {\bf V} ({\it n.b.}\ not {\bf V}$^{T}$)} \\ + \spec{WORK}{D(N)}{workspace} \\ + \spec{JSTAT}{I}{0~=~OK, $-$1~=~array A wrong shape, $>$0~=~index of W + for which convergence failed (see note~3, below)} +} +\notes +{ + \begin{enumerate} + \item M and N are the {\it logical}\/ dimensions of the + matrices and vectors concerned, which can be located in + arrays of larger {\it physical}\/ dimensions, given by MP and NP. + \item V contains matrix V, not the transpose of matrix V. + \item If the status JSTAT is greater than zero, this need not + necessarily be treated as a failure. It means that, due to + chance properties of the matrix A, the QR transformation + phase of the routine did not fully converge in a predefined + number of iterations, something that very seldom occurs. + When this condition does arise, it is possible that the + elements of the diagonal matrix W have not been correctly + found. However, in practice the results are likely to + be trustworthy. Applications should report the condition + as a warning, but then proceed normally. + \end{enumerate} +} +\refs{The algorithm is an adaptation of the routine SVD in the {\it EISPACK}\, + library (Garbow~{\it et~al.}\ 1977, {\it EISPACK Guide Extension}, + Springer Verlag), which is a FORTRAN~66 implementation of the Algol + routine SVD of Wilkinson \& Reinsch 1971 ({\it Handbook for Automatic + Computation}, vol~2, ed Bauer~{\it et~al.}, Springer Verlag). These + references give full details of the algorithm used here. + A good account of the use of SVD in least squares problems is given + in {\it Numerical Recipes}\/ (Press~{\it et~al.}\ 1987, Cambridge + University Press), which includes another variant of the EISPACK code.} +%----------------------------------------------------------------------- +\routine{SLA\_SVDCOV}{Covariance Matrix from SVD} +{ + \action{From the {\bf W} and {\bf V} matrices from the SVD + factorization of a matrix + (as obtained from the sla\_SVD routine), obtain + the covariance matrix.} + \call{CALL sla\_SVDCOV (N, NP, NC, W, V, WORK, CVM)} +} +\args{GIVEN} +{ + \spec{N}{I}{$n$, the number of rows and columns in + matrices {\bf W} and {\bf V}} \\ + \spec{NP}{I}{first dimension of array containing $n \times n$ + matrix {\bf V}} \\ + \spec{NC}{I}{first dimension of array CVM} \\ + \spec{W}{D(N)}{$n \times n$ diagonal matrix {\bf W} + (diagonal elements only)} \\ + \spec{V}{D(NP,NP)}{array containing $n \times n$ orthogonal matrix {\bf V}} +} +\args{RETURNED} +{ + \spec{WORK}{D(N)}{workspace} \\ + \spec{CVM}{D(NC,NC)}{array to receive covariance matrix} +} +\aref{{\it Numerical Recipes}, section 14.3.} +%----------------------------------------------------------------------- +\routine{SLA\_SVDSOL}{Solution Vector from SVD} +{ + \action{From a given vector and the SVD of a matrix (as obtained from + the sla\_SVD routine), obtain the solution vector. + This routine solves the equation: + \begin{tabbing} + XXXXXX \= \kill + \> {\bf A} $\cdot$ {\bf x} = {\bf b} + \end{tabbing} + where: + \begin{tabbing} + XXXXXX \= XXXX \= \kill + \> {\bf A} \> is a given $m$ (rows) $\times n$ (columns) + matrix, where $m \geq n$ \\ + \> {\bf x} \> is the $n$-vector we wish to find, and \\ + \> {\bf b} \> is a given $m$-vector + \end{tabbing} + by means of the {\it Singular Value Decomposition}\/ method (SVD).} + \call{CALL sla\_SVDSOL (M, N, MP, NP, B, U, W, V, WORK, X)} +} +\args{GIVEN} +{ + \spec{M,N}{I}{$m$, $n$, the numbers of rows and columns in matrix {\bf A}} \\ + \spec{MP,NP}{I}{physical dimensions of array containing matrix {\bf A}} \\ + \spec{B}{D(M)}{known vector {\bf b}} \\ + \spec{U}{D(MP,NP)}{array containing $m \times n$ matrix {\bf U}} \\ + \spec{W}{D(N)}{$n \times n$ diagonal matrix {\bf W} + (diagonal elements only)} \\ + \spec{V}{D(NP,NP)}{array containing $n \times n$ orthogonal matrix {\bf V}} +} +\args{RETURNED} +{ + \spec{WORK}{D(N)}{workspace} \\ + \spec{X}{D(N)}{unknown vector {\bf x}} +} +\notes +{ + \begin{enumerate} + \item In the Singular Value Decomposition method (SVD), + the matrix {\bf A} is first factorized (for example by + the routine sla\_SVD) into the following components: + \begin{tabbing} + XXXXXX \= \kill + \> {\bf A} = {\bf U} $\cdot$ {\bf W} $\cdot$ {\bf V}$^{T}$ + \end{tabbing} + where: + \begin{tabbing} + XXXXXX \= XXXX \= \kill + \> {\bf A} \> is any $m$ (rows) $\times n$ (columns) matrix, + where $m > n$ \\ + \> {\bf U} \> is an $m \times n$ column-orthogonal matrix \\ + \> {\bf W} \> is an $n \times n$ diagonal matrix with + $w_{ii} \geq 0$ \\ + \> {\bf V}$^{T}$ \> is the transpose of an $n \times n$ + orthogonal matrix + \end{tabbing} + Note that $m$ and $n$ are the {\it logical}\/ dimensions of the + matrices and vectors concerned, which can be located in + arrays of larger {\it physical}\/ dimensions MP and NP. + The solution is then found from the expression: + \begin{tabbing} + XXXXXX \= \kill + \> {\bf x} = {\bf V} $\cdot~[diag(1/${\bf W}$_{j})] + \cdot (${\bf U}$^{T} \cdot${\bf b}) + \end{tabbing} + \item If matrix {\bf A} is square, and if the diagonal matrix {\bf W} is not + altered, the method is equivalent to conventional solution + of simultaneous equations. + \item If $m > n$, the result is a least-squares fit. + \item If the solution is poorly determined, this shows up in the + SVD factorization as very small or zero {\bf W}$_{j}$ values. Where + a {\bf W}$_{j}$ value is small but non-zero it can be set to zero to + avoid ill effects. The present routine detects such zero + {\bf W}$_{j}$ values and produces a sensible solution, with highly + correlated terms kept under control rather than being allowed + to elope to infinity, and with meaningful values for the + other terms. + \end{enumerate} +} +\aref{{\it Numerical Recipes}, section 2.9.} +%----------------------------------------------------------------------- +\routine{SLA\_TP2S}{Tangent Plane to Spherical} +{ + \action{Transform tangent plane coordinates into spherical + coordinates (single precision)} + \call{CALL sla\_TP2S (XI, ETA, RAZ, DECZ, RA, DEC)} +} +\args{GIVEN} +{ + \spec{XI,ETA}{R}{tangent plane rectangular coordinates (radians)} \\ + \spec{RAZ,DECZ}{R}{spherical coordinates of tangent point (radians)} +} +\args{RETURNED} +{ + \spec{RA,DEC}{R}{spherical coordinates (radians)} +} +\notes +{ + \begin{enumerate} + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item When working in \xyz\ rather than spherical coordinates, the + equivalent Cartesian routine sla\_TP2V is available. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_TP2V}{Tangent Plane to Direction Cosines} +{ + \action{Given the tangent-plane coordinates of a star and the direction + cosines of the tangent point, determine the direction cosines + of the star + (single precision).} + \call{CALL sla\_TP2V (XI, ETA, V0, V)} +} +\args{GIVEN} +{ + \spec{XI,ETA}{R}{tangent plane coordinates of star (radians)} \\ + \spec{V0}{R(3)}{direction cosines of tangent point} +} +\args{RETURNED} +{ + \spec{V}{R(3)}{direction cosines of star} +} +\notes +{ + \begin{enumerate} + \item If vector V0 is not of unit length, the returned vector V will + be wrong. + \item If vector V0 points at a pole, the returned vector V will be + based on the arbitrary assumption that $\alpha=0$ at + the tangent point. + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item This routine is the Cartesian equivalent of the routine sla\_TP2S. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_TPS2C}{Plate centre from $\xi,\eta$ and $\alpha,\delta$} +{ + \action{From the tangent plane coordinates of a star of known \radec, + determine the \radec\ of the tangent point (single precision)} + \call{CALL sla\_TPS2C (XI, ETA, RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2, N)} +} +\args{GIVEN} +{ + \spec{XI,ETA}{R}{tangent plane rectangular coordinates (radians)} \\ + \spec{RA,DEC}{R}{spherical coordinates (radians)} +} +\args{RETURNED} +{ + \spec{RAZ1,DECZ1}{R}{spherical coordinates of tangent point, + solution 1} \\ + \spec{RAZ2,DECZ2}{R}{spherical coordinates of tangent point, + solution 2} \\ + \spec{N}{I}{number of solutions:} \\ + \spec{}{}{\hspace{1em} 0 = no solutions returned (note 2)} \\ + \spec{}{}{\hspace{1em} 1 = only the first solution is useful (note 3)} \\ + \spec{}{}{\hspace{1em} 2 = there are two useful solutions (note 3)} +} +\notes +{ + \begin{enumerate} + \item The RAZ1 and RAZ2 values returned are in the range $0\!-\!2\pi$. + \item Cases where there is no solution can only arise near the poles. + For example, it is clearly impossible for a star at the pole + itself to have a non-zero $\xi$ value, and hence it is + meaningless to ask where the tangent point would have to be + to bring about this combination of $\xi$ and $\delta$. + \item Also near the poles, cases can arise where there are two useful + solutions. The argument N indicates whether the second of the + two solutions returned is useful. N\,=\,1 + indicates only one useful solution, the usual case; under + these circumstances, the second solution corresponds to the + ``over-the-pole'' case, and this is reflected in the values + of RAZ2 and DECZ2 which are returned. + \item The DECZ1 and DECZ2 values returned are in the range $\pm\pi$, + but in the ordinary, non-pole-crossing, case, the range is + $\pm\pi/2$. + \item RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2 are all in radians. + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item When working in \xyz\ rather than spherical coordinates, the + equivalent Cartesian routine sla\_TPV2C is available. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_TPV2C}{Plate centre from $\xi,\eta$ and $x,y,z$} +{ + \action{From the tangent plane coordinates of a star of known + direction cosines, determine the direction cosines + of the tangent point (single precision)} + \call{CALL sla\_TPV2C (XI, ETA, V, V01, V02, N)} +} +\args{GIVEN} +{ + \spec{XI,ETA}{R}{tangent plane coordinates of star (radians)} \\ + \spec{V}{R(3)}{direction cosines of star} +} +\args{RETURNED} +{ + \spec{V01}{R(3)}{direction cosines of tangent point, solution 1} \\ + \spec{V01}{R(3)}{direction cosines of tangent point, solution 2} \\ + \spec{N}{I}{number of solutions:} \\ + \spec{}{}{\hspace{1em} 0 = no solutions returned (note 2)} \\ + \spec{}{}{\hspace{1em} 1 = only the first solution is useful (note 3)} \\ + \spec{}{}{\hspace{1em} 2 = there are two useful solutions (note 3)} +} +\notes +{ + \begin{enumerate} + \item The vector V must be of unit length or the result will be wrong. + \item Cases where there is no solution can only arise near the poles. + For example, it is clearly impossible for a star at the pole + itself to have a non-zero XI value. + \item Also near the poles, cases can arise where there are two useful + solutions. The argument N indicates whether the second of the + two solutions returned is useful. + N\,=\,1 + indicates only one useful solution, the usual case; under these + circumstances, the second solution can be regarded as valid if + the vector V02 is interpreted as the ``over-the-pole'' case. + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item This routine is the Cartesian equivalent of the routine sla\_TPS2C. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_UE2EL}{Universal to Conventional Elements} +{ + \action{Transform universal elements into conventional heliocentric + osculating elements.} + \call{CALL sla\_UE2EL (\vtop{ + \hbox{U, JFORMR,} + \hbox{JFORM, EPOCH, ORBINC, ANODE, PERIH,} + \hbox{AORQ, E, AORL, DM, JSTAT)}}} +} +\args{GIVEN} +{ + \spec{U}{D(13)}{universal orbital elements (updated; Note~1)} \\ + \specel {(1)} {combined mass ($M+m$)} \\ + \specel {(2)} {total energy of the orbit ($\alpha$)} \\ + \specel {(3)} {reference (osculating) epoch ($t_0$)} \\ + \specel {(4-6)} {position at reference epoch (${\rm \bf r}_0$)} \\ + \specel {(7-9)} {velocity at reference epoch (${\rm \bf v}_0$)} \\ + \specel {(10)} {heliocentric distance at reference epoch} \\ + \specel {(11)} {${\rm \bf r}_0.{\rm \bf v}_0$} \\ + \specel {(12)} {date ($t$)} \\ + \specel {(13)} {universal eccentric anomaly ($\psi$) of date, approx} \\ \\ + \spec{JFORMR}{I}{requested element set (1-3; Note~3)} +} +\args{RETURNED} +{ + \spec{JFORM}{I}{element set actually returned (1-3; Note~4)} \\ + \spec{EPOCH}{D}{epoch of elements ($t_0$ or $T$, TT MJD)} \\ + \spec{ORBINC}{D}{inclination ($i$, radians)} \\ + \spec{ANODE}{D}{longitude of the ascending node ($\Omega$, radians)} \\ + \spec{PERIH}{D}{longitude or argument of perihelion + ($\varpi$ or $\omega$,} \\ + \spec{}{}{\hspace{1.5em} radians)} \\ + \spec{AORQ}{D}{mean distance or perihelion distance ($a$ or $q$, AU)} \\ + \spec{E}{D}{eccentricity ($e$)} \\ + \spec{AORL}{D}{mean anomaly or longitude + ($M$ or $L$, radians,} \\ + \spec{}{}{\hspace{1.5em} JFORM=1,2 only)} \\ + \spec{DM}{D}{daily motion ($n$, radians, JFORM=1 only)} \\ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{2.3em} 0 = OK} \\ + \spec{}{}{\hspace{1.5em} $-$1 = illegal PMASS} \\ + \spec{}{}{\hspace{1.5em} $-$2 = illegal JFORMR} \\ + \spec{}{}{\hspace{1.5em} $-$3 = position/velocity out of allowed range} +} +\notes +{ + \begin{enumerate} + \setlength{\parskip}{\medskipamount} + \item The ``universal'' elements are those which define the orbit for the + purposes of the method of universal variables (see reference 2). + They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i)~$\alpha$, which is proportional to the total energy of the + orbit, (ii)~the heliocentric distance at epoch, + (iii)~the outwards component of the velocity at the given epoch, + (iv)~an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v)~that date. + \item The universal elements are with respect to the mean equator and + equinox of epoch J2000. The orbital elements produced are with + respect to the J2000 ecliptic and mean equinox. + \item Three different element-format options are supported, as + follows. \\ + + JFORM=1, suitable for the major planets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> longitude of perihelion $\varpi$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e < 1 )$ \\ + \> AORL \> = \> mean longitude $L$ (radians) \\ + \> DM \> = \> daily motion $n$ (radians) + \end{tabbing} + + JFORM=2, suitable for minor planets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of elements $t_0$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> mean distance $a$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e < 1 )$ \\ + \> AORL \> = \> mean anomaly $M$ (radians) + \end{tabbing} + + JFORM=3, suitable for comets: + + \begin{tabbing} + xxx \= xxxxxxxx \= xx \= \kill + \> EPOCH \> = \> epoch of perihelion $T$ (TT MJD) \\ + \> ORBINC \> = \> inclination $i$ (radians) \\ + \> ANODE \> = \> longitude of the ascending node $\Omega$ (radians) \\ + \> PERIH \> = \> argument of perihelion $\omega$ (radians) \\ + \> AORQ \> = \> perihelion distance $q$ (AU) \\ + \> E \> = \> eccentricity $e$ $( 0 \leq e \leq 10 )$ + \end{tabbing} + \item It may not be possible to generate elements in the form + requested through JFORMR. The caller is notified of the form + of elements actually returned by means of the JFORM argument: + + \begin{tabbing} + xx \= xxxxxxxxxx \= xxxxxxxxxxx \= \kill + \> JFORMR \> JFORM \> meaning \\ \\ + \> ~~~~~1 \> ~~~~~1 \> OK: elements are in the requested format \\ + \> ~~~~~1 \> ~~~~~2 \> never happens \\ + \> ~~~~~1 \> ~~~~~3 \> orbit not elliptical \\ + \> ~~~~~2 \> ~~~~~1 \> never happens \\ + \> ~~~~~2 \> ~~~~~2 \> OK: elements are in the requested format \\ + \> ~~~~~2 \> ~~~~~3 \> orbit not elliptical \\ + \> ~~~~~3 \> ~~~~~1 \> never happens \\ + \> ~~~~~3 \> ~~~~~2 \> never happens \\ + \> ~~~~~3 \> ~~~~~3 \> OK: elements are in the requested format + \end{tabbing} + \item The arguments returned for each value of JFORM ({\it cf}\/ Note~5: + JFORM may not be the same as JFORMR) are as follows: + + \begin{tabbing} + xxx \= xxxxxxxxxxxx \= xxxxxx \= xxxxxx \= \kill + \> JFORM \> 1 \> 2 \> 3 \\ \\ + \> EPOCH \> $t_0$ \> $t_0$ \> $T$ \\ + \> ORBINC \> $i$ \> $i$ \> $i$ \\ + \> ANODE \> $\Omega$ \> $\Omega$ \> $\Omega$ \\ + \> PERIH \> $\varpi$ \> $\omega$ \> $\omega$ \\ + \> AORQ \> $a$ \> $a$ \> $q$ \\ + \> E \> $e$ \> $e$ \> $e$ \\ + \> AORL \> $L$ \> $M$ \> - \\ + \> DM \> $n$ \> - \> - + \end{tabbing} + + where: + \begin{tabbing} + xxx \= xxxxxxxx \= xxx \= \kill + \> $t_0$ \> is the epoch of the elements (MJD, TT) \\ + \> $T$ \> is the epoch of perihelion (MJD, TT) \\ + \> $i$ \> is the inclination (radians) \\ + \> $\Omega$ \> is the longitude of the ascending node (radians) \\ + \> $\varpi$ \> is the longitude of perihelion (radians) \\ + \> $\omega$ \> is the argument of perihelion (radians) \\ + \> $a$ \> is the mean distance (AU) \\ + \> $q$ \> is the perihelion distance (AU) \\ + \> $e$ \> is the eccentricity \\ + \> $L$ \> is the longitude (radians, $0-2\pi$) \\ + \> $M$ \> is the mean anomaly (radians, $0-2\pi$) \\ + \> $n$ \> is the daily motion (radians) \\ + \> - \> means no value is set + \end{tabbing} + \item At very small inclinations, the longitude of the ascending node + ANODE becomes indeterminate and under some circumstances may be + set arbitrarily to zero. Similarly, if the orbit is close to + circular, the true anomaly becomes indeterminate and under some + circumstances may be set arbitrarily to zero. In such cases, + the other elements are automatically adjusted to compensate, + and so the elements remain a valid description of the orbit. + \end{enumerate} +} +\refs{ + \begin{enumerate} + \item Sterne, Theodore E., {\it An Introduction to Celestial Mechanics,}\/ + Interscience Publishers, 1960. Section 6.7, p199. + \item Everhart, E. \& Pitkin, E.T., Am.~J.~Phys.~51, 712, 1983. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_UE2PV}{Pos/Vel from Universal Elements} +{ + \action{Heliocentric position and velocity of a planet, asteroid or comet, + starting from orbital elements in the ``universal variables'' form.} + \call{CALL sla\_UE2PV (DATE, U, PV, JSTAT)} +} +\args{GIVEN} +{ + \spec{DATE}{D}{date (TT Modified Julian Date = JD$-$2400000.5)} +} +\args{GIVEN and RETURNED} +{ + \spec{U}{D(13)}{universal orbital elements (updated; Note~1)} \\ + \specel {(1)} {combined mass ($M+m$)} \\ + \specel {(2)} {total energy of the orbit ($\alpha$)} \\ + \specel {(3)} {reference (osculating) epoch ($t_0$)} \\ + \specel {(4-6)} {position at reference epoch (${\rm \bf r}_0$)} \\ + \specel {(7-9)} {velocity at reference epoch (${\rm \bf v}_0$)} \\ + \specel {(10)} {heliocentric distance at reference epoch} \\ + \specel {(11)} {${\rm \bf r}_0.{\rm \bf v}_0$} \\ + \specel {(12)} {date ($t$)} \\ + \specel {(13)} {universal eccentric anomaly ($\psi$) of date, approx} +} +\args{RETURNED} +{ + \spec{PV}{D(6)}{heliocentric \xyzxyzd, equatorial, J2000} \\ + \spec{}{}{\hspace{1.5em} (AU, AU/s; Note~1)} \\ + \spec{JSTAT}{I}{status:} \\ + \spec{}{}{\hspace{1.95em} 0 = OK} \\ + \spec{}{}{\hspace{1.2em} $-$1 = radius vector zero} \\ + \spec{}{}{\hspace{1.2em} $-2$ = failed to converge} +} +\notes +{ + \begin{enumerate} + \setlength{\parskip}{\medskipamount} + \item The ``universal'' elements are those which define the orbit for the + purposes of the method of universal variables (see reference). + They consist of the combined mass of the two bodies, an epoch, + and the position and velocity vectors (arbitrary reference frame) + at that epoch. The parameter set used here includes also various + quantities that can, in fact, be derived from the other + information. This approach is taken to avoiding unnecessary + computation and loss of accuracy. The supplementary quantities + are (i)~$\alpha$, which is proportional to the total energy of the + orbit, (ii)~the heliocentric distance at epoch, + (iii)~the outwards component of the velocity at the given epoch, + (iv)~an estimate of $\psi$, the ``universal eccentric anomaly'' at a + given date and (v)~that date. + \item The companion routine is sla\_EL2UE. This takes the conventional + orbital elements and transforms them into the set of numbers + needed by the present routine. A single prediction requires one + one call to sla\_EL2UE followed by one call to the present routine; + for convenience, the two calls are packaged as the routine + sla\_PLANEL. Multiple predictions may be made by again + calling sla\_EL2UE once, but then calling the present routine + multiple times, which is faster than multiple calls to sla\_PLANEL. + + It is not obligatory to use sla\_EL2UE to obtain the parameters. + However, it should be noted that because sla\_EL2UE performs its + own validation, no checks on the contents of the array U are made + by the present routine. + \item DATE is the instant for which the prediction is required. It is + in the TT timescale (formerly Ephemeris Time, ET) and is a + Modified Julian Date (JD$-$2400000.5). + \item The universal elements supplied in the array U are in canonical + units (solar masses, AU and canonical days). The position and + velocity are not sensitive to the choice of reference frame. The + sla\_EL2UE routine in fact produces coordinates with respect to the + J2000 equator and equinox. + \item The algorithm was originally adapted from the EPHSLA program of + D.\,H.\,P.\,Jones (private communication, 1996). The method + is based on Stumpff's Universal Variables. + \end{enumerate} +} +\aref{Everhart, E. \& Pitkin, E.T., Am.~J.~Phys.~51, 712, 1983.} +%----------------------------------------------------------------------- +\routine{SLA\_UNPCD}{Remove Radial Distortion} +{ + \action{Remove pincushion/barrel distortion from a distorted + \xy\ to give tangent-plane \xy.} + \call{CALL sla\_UNPCD (DISCO,X,Y)} +} +\args{GIVEN} +{ + \spec{DISCO}{D}{pincushion/barrel distortion coefficient} \\ + \spec{X,Y}{D}{distorted \xy} +} +\args{RETURNED} +{ + \spec{X,Y}{D}{tangent-plane \xy} +} +\notes +{ + \begin{enumerate} + \item The distortion is of the form $\rho = r (1 + c r^{2})$, where $r$ is + the radial distance from the tangent point, $c$ is the DISCO + argument, and $\rho$ is the radial distance in the presence of + the distortion. + \item For {\it pincushion}\/ distortion, C is +ve; for + {\it barrel}\/ distortion, C is $-$ve. + \item For X,Y in units of one projection radius (in the case of + a photographic plate, the focal length), the following + DISCO values apply: + + \vspace{2ex} + + \hspace{5em} + \begin{tabular}{|l|c|} \hline + Geometry & DISCO \\ \hline \hline + astrograph & 0.0 \\ \hline + Schmidt & $-$0.3333 \\ \hline + AAT PF doublet & +147.069 \\ \hline + AAT PF triplet & +178.585 \\ \hline + AAT f/8 & +21.20 \\ \hline + JKT f/8 & +14.6 \\ \hline + \end{tabular} + + \vspace{2ex} + + \item The present routine is an approximate inverse to the + companion routine sla\_PCD, obtained from two iterations + of Newton's method. The mismatch between the sla\_PCD + and sla\_UNPCD is negligible for astrometric applications; + to reach 1~milliarcsec at the edge of the AAT triplet or + Schmidt field would require field diameters of \degree{2}{4} + and $42^{\circ}$ respectively. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_V2TP}{Direction Cosines to Tangent Plane} +{ + \action{Given the direction cosines of a star and of the tangent point, + determine the star's tangent-plane coordinates + (single precision).} + \call{CALL sla\_V2TP (V, V0, XI, ETA, J)} +} +\args{GIVEN} +{ + \spec{V}{R(3)}{direction cosines of star} \\ + \spec{V0}{R(3)}{direction cosines of tangent point} +} +\args{RETURNED} +{ + \spec{XI,ETA}{R}{tangent plane coordinates (radians)} \\ + \spec{J}{I}{status:} \\ + \spec{}{}{\hspace{1.5em} 0 = OK, star on tangent plane} \\ + \spec{}{}{\hspace{1.5em} 1 = error, star too far from axis} \\ + \spec{}{}{\hspace{1.5em} 2 = error, antistar on tangent plane} \\ + \spec{}{}{\hspace{1.5em} 3 = error, antistar too far from axis} +} +\notes +{ + \begin{enumerate} + \item If vector V0 is not of unit length, or if vector V is of zero + length, the results will be wrong. + \item If V0 points at a pole, the returned $\xi,\eta$ + will be based on the + arbitrary assumption that $\alpha=0$ at the tangent point. + \item The projection is called the {\it gnomonic}\/ projection; the + Cartesian coordinates \xieta\ are called + {\it standard coordinates.}\/ The latter + are in units of the distance from the tangent plane to the projection + point, {\it i.e.}\ radians near the origin. + \item This routine is the Cartesian equivalent of the routine sla\_S2TP. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_VDV}{Scalar Product} +{ + \action{Scalar product of two 3-vectors (single precision).} + \call{R~=~sla\_VDV (VA, VB)} +} +\args{GIVEN} +{ + \spec{VA}{R(3)}{first vector} \\ + \spec{VB}{R(3)}{second vector} +} +\args{RETURNED} +{ + \spec{sla\_VDV}{R}{scalar product VA.VB} +} +%----------------------------------------------------------------------- +\routine{SLA\_VN}{Normalize Vector} +{ + \action{Normalize a 3-vector, also giving the modulus (single precision).} + \call{CALL sla\_VN (V, UV, VM)} +} +\args{GIVEN} +{ + \spec{V}{R(3)}{vector} +} +\args{RETURNED} +{ + \spec{UV}{R(3)}{unit vector in direction of V} \\ + \spec{VM}{R}{modulus of V} +} +\anote{If the modulus of V is zero, UV is set to zero as well.} +%----------------------------------------------------------------------- +\routine{SLA\_VXV}{Vector Product} +{ + \action{Vector product of two 3-vectors (single precision).} + \call{CALL sla\_VXV (VA, VB, VC)} +} +\args{GIVEN} +{ + \spec{VA}{R(3)}{first vector} \\ + \spec{VB}{R(3)}{second vector} +} +\args{RETURNED} +{ + \spec{VC}{R(3)}{vector product VA$\times$VB} +} +%----------------------------------------------------------------------- +\routine{SLA\_WAIT}{Time Delay} +{ + \action{Wait for a specified interval.} + \call{CALL sla\_WAIT (DELAY)} +} +\args{GIVEN} +{ + \spec{DELAY}{R}{delay in seconds} +} +\notes +{ + \begin{enumerate} + \item The implementation is machine-specific. + \item The delay actually requested is restricted to the range + 100ns-200s in the present implementation. + \item There is no guarantee of accuracy, though on almost all + types of computer the program will certainly not + resume execution {\it before}\/ the stated interval has + elapsed. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_XY2XY}{Apply Linear Model to an \xy} +{ + \action{Transform one \xy\ into another using a linear model of the type + produced by the sla\_FITXY routine.} + \call{CALL sla\_XY2XY (X1,Y1,COEFFS,X2,Y2)} +} +\args{GIVEN} +{ + \spec{X1,Y1}{D}{\xy\ before transformation} \\ + \spec{COEFFS}{D(6)}{transformation coefficients (see note)} +} +\args{RETURNED} +{ + \spec{X2,Y2}{D}{\xy\ after transformation} +} +\notes +{ + \begin{enumerate} + \item The model relates two sets of \xy\ coordinates as follows. + Naming the six elements of COEFFS $a,b,c,d,e$ \& $f$, + the present routine performs the transformation: + \begin{verse} + $x_{2} = a + bx_{1} + cy_{1}$ \\ + $y_{2} = d + ex_{1} + fy_{1}$ + \end{verse} + \item See also sla\_FITXY, sla\_PXY, sla\_INVF, sla\_DCMPF. + \end{enumerate} +} +%----------------------------------------------------------------------- +\routine{SLA\_ZD}{$h,\delta$ to Zenith Distance} +{ + \action{Hour angle and declination to zenith distance + (double precision).} + \call{D~=~sla\_ZD (HA, DEC, PHI)} +} +\args{GIVEN} +{ + \spec{HA}{D}{hour angle in radians} \\ + \spec{DEC}{D}{declination in radians} \\ + \spec{PHI}{D}{latitude in radians} +} +\args{RETURNED} +{ + \spec{sla\_ZD}{D}{zenith distance (radians, $0\!-\!\pi$)} +} +\notes +{ + \begin{enumerate} + \item The latitude must be geodetic. In critical applications, + corrections for polar motion should be applied (see sla\_POLMO). + \item In some applications it will be important to specify the + correct type of hour angle and declination in order to + produce the required type + of zenith distance. In particular, it may be + important to distinguish between the zenith distance + as affected by refraction, which would require the + {\it observed}\/ \hadec, and the zenith distance {\it in vacuo}, + which would require the {\it topocentric}\/ \hadec. If + the effects of diurnal aberration can be neglected, the + {\it apparent}\/ \hadec\ may be used instead of the + {\it topocentric}\/ \hadec. + \item No range checking of arguments is done. + \item In applications which involve many zenith distance calculations, + rather than calling the present routine it will be more + efficient to use inline code, having previously computed fixed + terms such as sine and cosine of latitude, and perhaps sine and + cosine of declination. + \end{enumerate} +} + +\pagebreak + +\section{EXPLANATION AND EXAMPLES} +To guide the writer of positional-astronomy applications software, +this final chapter puts the SLALIB routines into the context of +astronomical phenomena and techniques, and presents a few +``cookbook'' examples +of the SLALIB calls in action. The astronomical content of the chapter +is not, of course, intended to be a substitute for specialist text-books on +positional astronomy, but may help bridge the gap between +such books and the SLALIB routines. For further reading, the following +cover a wide range of material and styles: +\begin{itemize} +\item {\it Explanatory Supplement to the Astronomical Almanac}, + ed.\ P.\,Kenneth~Seidelmann (1992), University Science Books. +\item {\it Vectorial Astrometry}, C.\,A.\,Murray (1983), Adam Hilger. +\item {\it Spherical Astronomy}, Robin~M.\,Green (1985), Cambridge + University Press. +\item {\it Spacecraft Attitude Determination and Control}, + ed.\ James~R.\,Wertz (1986), Reidel. +\item {\it Practical Astronomy with your Calculator}, + Peter~Duffett-Smith (1981), Cambridge University Press. +\end{itemize} +Also of considerable value, though out of date in places, are: +\begin{itemize} +\item {\it Explanatory Supplement to the Astronomical Ephemeris + and the American Ephemeris and Nautical Almanac}, RGO/USNO (1974), + HMSO. +\item {\it Textbook on Spherical Astronomy}, W.\,M.\,Smart (1977), + Cambridge University Press. +\end{itemize} +Only brief details of individual SLALIB routines are given here, and +readers will find it useful to refer to the subprogram specifications +elsewhere in this document. The source code for the SLALIB routines +(available in both Fortran and C) is also intended to be used as +documentation. + +\subsection {Spherical Trigonometry} +Celestial phenomena occur at such vast distances from the +observer that for most practical purposes there is no need to +work in 3D; only the direction +of a source matters, not how far away it is. Things can +therefore be viewed as if they were happening +on the inside of sphere with the observer at the centre -- +the {\it celestial sphere}. Problems involving +positions and orientations in the sky can then be solved by +using the formulae of {\it spherical trigonometry}, which +apply to {\it spherical triangles}, the sides of which are +{\it great circles}. + +Positions on the celestial sphere may be specified by using +a spherical polar coordinate system, defined in terms of +some fundamental plane and a line in that plane chosen to +represent zero longitude. Mathematicians usually work with the +co-latitude, with zero at the principal pole, whereas most +astronomical coordinate systems use latitude, reckoned plus and +minus from the equator. +Astronomical coordinate systems may be either right-handed +({\it e.g.}\ right ascension and declination \radec, +Galactic longitude and latitude \gal) +or left-handed ({\it e.g.}\ hour angle and +declination \hadec). In some cases +different conventions have been used in the past, a fruitful source of +mistakes. Azimuth and geographical longitude are examples; azimuth +is now generally reckoned north through east +(making a left-handed system); geographical longitude is now usually +taken to increase eastwards (a right-handed system) but astronomers +used to employ a west-positive convention. In reports +and program comments it is wise to spell out what convention +is being used, if there is any possibility of confusion. + +When applying spherical trigonometry formulae, attention must be +paid to +rounding errors (for example it is a bad idea to find a +small angle through its cosine) and to the possibility of +problems close to poles. +Also, if a formulation relies on inspection to establish +the quadrant of the result, it is an indication that a vector-related +method might be preferable. + +As well as providing many routines which work in terms of specific +spherical coordinates such as \radec, SLALIB provides +two routines which operate directly on generic spherical +coordinates: +sla\_SEP +computes the separation between +two points (the distance along a great circle) and +sla\_BEAR +computes the bearing (or {\it position angle}) +of one point seen from the other. The routines +sla\_DSEP +and +sla\_DBEAR +are double precision equivalents. As a simple demonstration +of SLALIB, we will use these facilities to estimate the distance from +London to Sydney and the initial compass heading: +\goodbreak +\begin{verbatim} + IMPLICIT NONE + + * Degrees to radians + REAL D2R + PARAMETER (D2R=0.01745329252) + + * Longitudes and latitudes (radians) for London and Sydney + REAL AL,BL,AS,BS + PARAMETER (AL=-0.2*D2R,BL=51.5*D2R,AS=151.2*D2R,BS=-33.9*D2R) + + * Earth radius in km (spherical approximation) + REAL RKM + PARAMETER (RKM=6375.0) + + REAL sla_SEP,sla_BEAR + + + * Distance and initial heading (N=0, E=90) + WRITE (*,'(1X,I5,'' km,'',I4,'' deg'')') + : NINT(sla_SEP(AL,BL,AS,BS)*RKM),NINT(sla_BEAR(AL,BL,AS,BS)/D2R) + + END +\end{verbatim} +\goodbreak +(The result is 17011~km, $61^\circ$.) + +The routines +sla\_PAV and +sla\_DPAV +are equivalents of sla\_BEAR and sla\_DBEAR but starting from +direction-cosines instead of spherical coordinates. + +\subsubsection{Formatting angles} +SLALIB has routines for decoding decimal numbers +from character form and for converting angles to and from +sexagesimal form (hours, minutes, seconds or degrees, +arcminutes, arcseconds). These apparently straightforward +operations contain hidden traps which the SLALIB routines +avoid. + +There are five routines for decoding numbers from a character +string, such as might be entered using a keyboard. +They all work in the same style, and successive calls +can work their way along a single string decoding +a sequence of numbers of assorted types. Number +fields can be separated by spaces or commas, and can be defaulted +to previous values or to preset defaults. + +Three of the routines decode single numbers: +sla\_INTIN +(integer), +sla\_FLOTIN +(single precision floating point) and +sla\_DFLTIN +(double precision). A minus sign can be +detected even when the number is zero; this avoids +the frequently-encountered ``minus zero'' bug, where +declinations {\it etc.}\ in +the range $0^{\circ}$ to $-1^{\circ}$ mysteriously migrate to +the range $0^{\circ}$ to $+1^{\circ}$. +Here is an example (in Fortran) where we wish to +read two numbers, and integer {\tt IX} and a real, {\tt Y}, +with {\tt X} defaulting to zero and {\tt Y} defaulting to +{\tt X}: +\goodbreak +\begin{verbatim} + DOUBLE PRECISION Y + CHARACTER*80 A + INTEGER IX,I,J + + * Input the string to be decoded + READ (*,'(A)') A + + * Preset IX to its default value + IX = 0 + + * Point to the start of the string + I = 1 + + * Decode an integer + CALL sla_INTIN(A,I,IX,J) + IF (J.GT.1) GO TO ... (bad IX) + + * Preset Y to its default value + Y = DBLE(IX) + + * Decode a double precision number + CALL sla_DFLTIN(A,I,Y,J) + IF (J.GT.1) GO TO ... (bad Y) +\end{verbatim} +\goodbreak +Two additional routines decode a 3-field sexagesimal number: +sla\_AFIN +(degrees, arcminutes, arcseconds to single +precision radians) and +sla\_DAFIN +(the same but double precision). They also +work using other units such as hours {\it etc}.\ if +you multiply the result by the appropriate factor. An example +Fortran program which uses +sla\_DAFIN +was given earlier, in section 1.2. + +SLALIB provides four routines for expressing an angle in radians +in a preferred range. The function +sla\_RANGE +expresses an angle +in the range $\pm\pi$; +sla\_RANORM +expresses an angle in the range +$0-2\pi$. The functions +sla\_DRANGE +and +sla\_DRANRM +are double precision versions. + +Several routines +(sla\_CTF2D, +sla\_CR2AF +{\it etc.}) are provided to convert +angles to and from +sexagesimal form (hours, minute, seconds or degrees, +arcminutes and arcseconds). +They avoid the common +``converting from integer to real at the wrong time'' +bug, which produces angles like \hms{24}{59}{59}{999}. +Here is a program which displays an hour angle +stored in radians: +\goodbreak +\begin{verbatim} + DOUBLE PRECISION HA + CHARACTER SIGN + INTEGER IHMSF(4) + : + CALL sla_DR2TF(3,HA,SIGN,IHMSF) + WRITE (*,'(1X,A,3I3.2,''.'',I3.3)') SIGN,IHMSF +\end{verbatim} +\goodbreak + +\subsection {Vectors and Matrices} +As an alternative to employing a spherical polar coordinate system, +the direction of an object can be defined in terms of the sum of any +three vectors as long as they are different and +not coplanar. In practice, three vectors at right angles are +usually chosen, forming a system +of {\it Cartesian coordinates}. The {\it x}- and {\it y}-axes +lie in the fundamental plane ({\it e.g.}\ the equator in the +case of \radec), with the {\it x}-axis pointing to zero longitude. +The {\it z}-axis is normal to the fundamental plane and points +towards positive latitudes. The {\it y}-axis can lie in either +of the two possible directions, depending on whether the +coordinate system is right-handed or left-handed. +The three axes are sometimes called +a {\it triad}. For most applications involving arbitrarily +distant objects such as stars, the vector which defines +the direction concerned is constrained to have unit length. +The {\it x}-, {\it y-} and {\it z-}components +can be regarded as the scalar (dot) product of this vector +onto the three axes of the triad in turn. Because the vector +is a unit vector, +each of the three dot-products is simply the cosine of the angle +between the unit vector and the axis concerned, and the +{\it x}-, {\it y-} and {\it z-}components are sometimes +called {\it direction cosines}. + +For some applications involving objects +with the Solar System, unit vectors are inappropriate, and +it is necessary to use vectors scaled in length-units such as +AU, km {\it etc.} +In these cases the origin of the coordinate system may not be +the observer, but instead might be the Sun, the Solar-System +barycentre, the centre of the Earth {\it etc.} But whatever the application, +the final direction in which the observer sees the object can be +expressed as direction cosines. + +But where has this got us? Instead of two numbers -- a longitude and +a latitude -- we now have three numbers to look after +-- the {\it x}-, {\it y-} and +{\it z-}components -- whose quadratic sum we have somehow to contrive to +be unity. And, in addition to this apparent redundancy, +most people find it harder to visualize +problems in terms of \xyz\ than in $[\,\theta,\phi~]$. +Despite these objections, the vector approach turns out to have +significant advantages over the spherical trigonometry approach: +\begin{itemize} +\item Vector formulae tend to be much more succinct; one vector + operation is the equivalent of strings of sines and cosines. +\item The formulae are as a rule rigorous, even at the poles. +\item Accuracy is maintained all over the celestial sphere. + When one Cartesian component is nearly unity and + therefore insensitive to direction, the others become small + and therefore more precise. +\item Formulations usually deliver the quadrant of the result + without the need for any inspection (except within the + library function ATAN2). +\end{itemize} +A number of important transformations in positional +astronomy turn out to be nothing more than changes of coordinate +system, something which is especially convenient if +the vector approach is used. A direction with respect +to one triad can be expressed relative to another triad simply +by multiplying the \xyz\ column vector by the appropriate +$3\times3$ orthogonal matrix +(a tensor of Rank~2, or {\it dyadic}). The three rows of this +{\it rotation matrix}\/ +are the vectors in the old coordinate system of the three +new axes, and the transformation amounts to obtaining the +dot-product of the direction-vector with each of the three +new axes. Precession, nutation, \hadec\ to \azel, +\radec\ to \gal\ and so on are typical examples of the +technique. A useful property of the rotation matrices +is that they can be inverted simply by taking the transpose. + +The elements of these vectors and matrices are assorted combinations of +the sines and cosines of the various angles involved (hour angle, +declination and so on, depending on which transformation is +being applied). If you write out the matrix multiplications +in full you get expressions which are essentially the same as the +equivalent spherical trigonometry formulae. Indeed, many of the +standard formulae of spherical trigonometry are most easily +derived by expressing the problem initially in +terms of vectors. + +\subsubsection{Using vectors} +SLALIB provides conversions between spherical and vector +form +(sla\_CS2C, +sla\_CC2S +{\it etc.}), plus an assortment +of standard vector and matrix operations +(sla\_VDV, +sla\_MXV +{\it etc.}). +There are also routines +(sla\_EULER +{\it etc.}) for creating a rotation matrix +from three {\it Euler angles}\/ (successive rotations about +specified Cartesian axes). Instead of Euler angles, a rotation +matrix can be expressed as an {\it axial vector}\/ (the pole of the rotation, +and the amount of rotation), and routines are provided for this +(sla\_AV2M, +sla\_M2AV +{\it etc.}). + +Here is an example where spherical coordinates {\tt P1} and {\tt Q1} +undergo a coordinate transformation and become {\tt P2} and {\tt Q2}; +the transformation consists of a rotation of the coordinate system +through angles {\tt A}, {\tt B} and {\tt C} about the +{\it z}, new {\it y}\/ and new {\it z}\/ axes respectively: +\goodbreak +\begin{verbatim} + REAL A,B,C,R(3,3),P1,Q1,V1(3),V2(3),P2,Q2 + : + * Create rotation matrix + CALL sla_EULER('ZYZ',A,B,C,R) + + * Transform position (P,Q) from spherical to Cartesian + CALL sla_CS2C(P1,Q1,V1) + + * Multiply by rotation matrix + CALL sla_MXV(R,V1,V2) + + * Back to spherical + CALL sla_CC2S(V2,P2,Q2) +\end{verbatim} +\goodbreak +Small adjustments to the direction of a position +vector are often most conveniently described in terms of +$[\,\Delta x,\Delta y, \Delta z\,]$. Adding the correction +vector needs careful handling if the position +vector is to remain of length unity, an advisable precaution which +ensures that +the \xyz\ components are always available to mean the cosines of +the angles between the vector and the axis concerned. Two types +of shifts are commonly used, +the first where a small vector of arbitrary direction is +added to the unit vector, and the second where there is a displacement +in the latitude coordinate (declination, elevation {\it etc.}) alone. + +For a shift produced by adding a small \xyz\ vector ${\bf D}$ to a +unit vector ${\bf V1}$, the resulting vector ${\bf V2}$ has direction +$<{\bf V1}+{\bf D}>$ but is no longer of unit length. A better approximation +is available if the result is multiplied by a scaling factor of +$(1-{\bf D}\cdot{\bf V1})$, where the dot +means scalar product. In Fortran: +\goodbreak +\begin{verbatim} + F = (1D0-(DX*V1X+DY*V1Y+DZ*V1Z)) + V2X = F*(V1X+DX) + V2Y = F*(V1Y+DY) + V2Z = F*(V1Z+DZ) +\end{verbatim} +\goodbreak +\noindent +The correction for diurnal aberration (discussed later) is +an example of this form of shift. + +As an example of the second kind of displacement +we will apply a small change in elevation $\delta E$ to an +\azel\ direction vector. The direction of the +result can be obtained by making the allowable approximation +${\tan \delta E\approx\delta E}$ and adding a adjustment +vector of length $\delta E$ normal +to the direction vector in the vertical plane containing the direction +vector. The $z$-component of the adjustment vector is +$\delta E \cos E$, +and the horizontal component is +$\delta E \sin E$ which has then to be +resolved into $x$ and $y$ in proportion to their current sizes. To +approximate a unit vector more closely, a correction factor of +$\cos \delta E$ can then be applied, which is nearly +$(1-\delta E^2 /2)$ for +small $\delta E$. Expressed in Fortran, for initial vector +{\tt V1X,V1Y,V1Z}, change in elevation {\tt DEL} +(+ve $\equiv$ upwards), and result +vector {\tt V2X,V2Y,V2Z}: +\goodbreak +\begin{verbatim} + COSDEL = 1D0-DEL*DEL/2D0 + R1 = SQRT(V1X*V1X+V1Y*V1Y) + F = COSDEL*(R1-DEL*V1Z)/R1 + V2X = F*V1X + V2Y = F*V1Y + V2Z = COSDEL*(V1Z+DEL*R1) +\end{verbatim} +\goodbreak +An example of this type of shift is the correction for atmospheric +refraction (see later). +Depending on the relationship between $\delta E$ and $E$, special +handling at the pole (the zenith for our example) may be required. + +SLALIB includes routines for the case where both a position +and a velocity are involved. The routines +sla\_CS2C6 +and +sla\_CC62S +convert from $[\theta,\phi,\dot{\theta},\dot{\phi}]$ +to \xyzxyzd\ and back; +sla\_DCS26 +and +sla\_DC62S +are double precision equivalents. + +\subsection {Celestial Coordinate Systems} +SLALIB has routines to perform transformations +of celestial positions between different spherical +coordinate systems, including those shown in the following table: + +\begin{center} +\begin{tabular}{|l|c|c|c|c|c|c|} \hline +{\it system} & {\it symbols} & {\it longitude} & {\it latitude} & + {\it x-y plane} & {\it long.\ zero} & {\it RH/LH} +\\ \hline \hline +horizon & -- & azimuth & elevation & horizontal & north & L +\\ \hline +equatorial & $\alpha,\delta$ & R.A.\ & Dec.\ & equator & equinox & R +\\ \hline +local equ.\ & $h,\delta$ & H.A.\ & Dec.\ & equator & meridian & L +\\ \hline +ecliptic & $\lambda,\beta$ & ecl.\ long.\ & ecl.\ lat.\ & + ecliptic & equinox & R +\\ \hline +galactic & $l^{I\!I},b^{I\!I}$ & gal.\ long.\ & gal.\ lat.\ & + gal.\ equator & gal.\ centre & R +\\ \hline +supergalactic & SGL,SGB & SG long.\ & SG lat.\ & + SG equator & node w.\ gal.\ equ.\ & R +\\ \hline +\end{tabular} +\end{center} +Transformations between \hadec\ and \azel\ can be performed by +calling +sla\_E2H +and +sla\_H2E, +or, in double precision, +sla\_DE2H +and +sla\_DH2E. +There is also a routine for obtaining +zenith distance alone for a given \hadec, +sla\_ZD, +and one for determining the parallactic angle, +sla\_PA. +Three routines are included which relate to altazimuth telescope +mountings. For a given \hadec\ and latitude, +sla\_ALTAZ +returns the azimuth, elevation and parallactic angle, plus +velocities and accelerations for sidereal tracking. +The routines +sla\_PDA2H +and +sla\_PDQ2H +predict at what hour angle a given azimuth or +parallactic angle will be reached. + +The routines +sla\_EQECL +and +sla\_ECLEQ +transform between ecliptic +coordinates and \radec\/; there is also a routine for generating the +equatorial to ecliptic rotation matrix for a given date: +sla\_ECMAT. + +For conversion between Galactic coordinates and \radec\ there are +two sets of routines, depending on whether the \radec\ is +old-style, B1950, or new-style, J2000; +sla\_EG50 +and +sla\_GE50 +are \radec\ to \gal\ and {\it vice versa}\/ for the B1950 case, while +sla\_EQGAL +and +sla\_GALEQ +are the J2000 equivalents. + +Finally, the routines +sla\_GALSUP +and +sla\_SUPGAL +transform \gal\ to de~Vaucouleurs supergalactic longitude and latitude +and {\it vice versa.} + +It should be appreciated that the table, above, constitutes +a gross oversimplification. Apparently +simple concepts such as equator, equinox {\it etc.}\ are apt to be very hard to +pin down precisely (polar motion, orbital perturbations \ldots) and +some have several interpretations, all subtly different. The various +frames move in complicated ways with respect to one another or to +the stars (themselves in motion). And in some instances the +coordinate system is slightly distorted, so that the +ordinary rules of spherical trigonometry no longer strictly apply. + +These {\it caveats}\/ +apply particularly to the bewildering variety of different +\radec\ systems that are in use. Figure~1 shows how +some of these systems are related, to one another and +to the direction in which a celestial source actually +appears in the sky. At the top of the diagram are +the various sorts of {\it mean place}\/ +found in star catalogues and papers;\footnote{One frame not included in +Figure~1 is that of the Hipparcos catalogue. This is currently the +best available implementation in the optical of the {\it International +Celestial Reference System}\/ (ICRS), which is based on extragalactic +radio sources observed by VLBI. The distinction between FK5 J2000 +and Hipparcos coordinates only becomes important when accuracies of +50~mas or better are required. More details are given in +Section~4.14.} at the bottom is the +{\it observed}\/ \azel, where a perfect theodolite would +be pointed to see the source; and in the body of +the diagram are +the intermediate processing steps and coordinate +systems. To help +understand this diagram, and the SLALIB routines that can +be used to carry out the various calculations, we will look at the coordinate +systems involved, and the astronomical phenomena that +affect them. + +\begin{figure} +\begin{center} +\begin{tabular}{|cccccc|} \hline +& & & & & \\ +\hspace{5em} & \hspace{5em} & \hspace{5em} & + \hspace{5em} & \hspace{5em} & \hspace{5em} \\ +\multicolumn{2}{|c}{\hspace{0em}\fbox{\parbox{8.5em}{\center \vspace{-2ex} + mean \radec, FK4, \\ + any equinox + \vspace{0.5ex}}}} & + \multicolumn{2}{c}{\hspace{0em}\fbox{\parbox{8.5em}{\center \vspace{-2ex} + mean \radec, FK4, + no $\mu$, any equinox + \vspace{0.5ex}}}} & +\multicolumn{2}{c|}{\hspace{0em}\fbox{\parbox{8.5em}{\center \vspace{-2ex} + mean \radec, FK5, \\ + any equinox + \vspace{0.5ex}}}} \\ +& \multicolumn{2}{|c|}{} & \multicolumn{2}{c|}{} & \\ +\multicolumn{2}{|c}{space motion} & \multicolumn{1}{c|}{} & & + \multicolumn{2}{c|}{space motion} \\ +\multicolumn{2}{|c}{-- E-terms} & + \multicolumn{2}{c}{-- E-terms} & \multicolumn{1}{c|}{} & \\ +\multicolumn{2}{|c}{precess to B1950} & \multicolumn{2}{c}{precess to B1950} & + \multicolumn{2}{c|}{precess to J2000} \\ +\multicolumn{2}{|c}{+ E-terms} & + \multicolumn{2}{c}{+ E-terms} & \multicolumn{1}{c|}{} & \\ +\multicolumn{2}{|c}{FK4 to FK5, no $\mu$} & + \multicolumn{2}{c}{FK4 to FK5, no $\mu$} & \multicolumn{1}{c|}{} & \\ +\multicolumn{2}{|c}{parallax} & \multicolumn{1}{c|}{} & & + \multicolumn{2}{c|}{parallax} \\ +& \multicolumn{2}{|c|}{} & \multicolumn{2}{c|}{} & \\ \cline{2-5} +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{\fbox{\parbox{18em}{\center \vspace{-2ex} + FK5, J2000, current epoch, geocentric + \vspace{0.5ex}}}} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{light deflection} & \\ +& \multicolumn{4}{c}{annual aberration} & \\ +& \multicolumn{4}{c}{precession/nutation} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{\fbox{Apparent \radec}} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{Earth rotation} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{\fbox{Apparent \hadec}} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{diurnal aberration} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{\fbox{Topocentric \hadec}} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{\hadec\ to \azel} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{\fbox{Topocentric \azel}} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{refraction} & \\ +\multicolumn{3}{|c|}{} & & & \\ +& \multicolumn{4}{c}{\fbox{Observed \azel}} & \\ +& & & & & \\ +& & & & & \\ \hline +\end{tabular} +\end{center} +\vspace{-0.5ex} +\caption{Relationship Between Celestial Coordinates} + +Star positions are published or catalogued using +one of the mean \radec\ systems shown at +the top. The ``FK4'' systems +were used before about 1980 and are usually +equinox B1950. The ``FK5'' system, equinox J2000, is now preferred, +or rather its modern equivalent, the International Celestial Reference +Frame (in the optical, the Hipparcos catalogue). +The figure relates a star's mean \radec\ to the actual +line-of-sight to the star. +Note that for the conventional choices of equinox, namely +B1950 or J2000, all of the precession and E-terms corrections +are superfluous. +\end{figure} + +\subsection{Precession and Nutation} +{\it Right ascension and declination}, (\radec), are the names +of the longitude and latitude in a spherical +polar coordinate system based on the Earth's axis of rotation. +The zero point of $\alpha$ is the point of intersection of +the {\it celestial +equator}\/ and the {\it ecliptic}\/ (the apparent path of the Sun +through the year) where the Sun moves into the northern +hemisphere. This point is called the +{\it first point of Aries}, +the {\it vernal equinox}\/ (with apologies to +southern-hemisphere readers) or simply the {\it equinox}.\footnote{With +the introduction of the International Celestial Reference System (ICRS), the +connection between (i)~star coordinates and (ii)~the Earth's orientation +and orbit has been broken. However, the orientation of the +International Celestial Reference Frame (ICRF) axes was, for convenience, +chosen to match J2000 FK5, and for most practical purposes ICRF coordinates +(for example entries in the Hipparcos catalogue) can be regarded as +synonymous with J2000 FK5. See Section 4.14 for further details.} + +This simple picture is unfortunately +complicated by the difficulty of defining +a suitable equator and equinox. One problem is that the +Sun's apparent motion is not completely regular, due to the +ellipticity of the Earth's orbit and its continuous disturbance +by the Moon and planets. This is dealt with by +separating the motion into (i)~a smooth and steady {\it mean Sun}\/ +and (ii)~a set of periodic corrections and perturbations; only the former +is involved in establishing reference frames and timescales. +A second, far larger problem, is that +the celestial equator and the ecliptic +are both moving with respect to the stars. +These motions arise because of the gravitational +interactions between the Earth and the other solar-system bodies. + +By far the largest effect is the +so-called ``precession of the equinoxes'', where the Earth's +rotation axis sweeps out a cone centred on the ecliptic +pole, completing one revolution in about 26,000 years. The +cause of the motion is the torque exerted on the distorted and +spinning Earth by the Sun and the Moon. Consider the effect of the +Sun alone, at or near the northern summer solstice. The Sun +`sees' the top (north pole) of the Earth tilted towards it +(by about \degree{23}{5}, the {\it obliquity of the +ecliptic}\/), +and sees the nearer part of the Earth's equatorial bulge +below centre and the further part above centre. +Although the Earth is in free fall, +the gravitational force on the nearer part of the +equatorial bulge is greater than that on the further part, and +so there is a net torque acting +as if to eliminate the tilt. Six months later the same thing +is happening in reverse, except that the torque is still +trying to eliminate the tilt. In between (at the equinoxes) the +torque shrinks to zero. A torque acting on a spinning body +is gyroscopically translated +into a precessional motion of the spin axis at right-angles to the torque, +and this happens to the Earth. +The motion varies during the +year, going through two maxima, but always acts in the +same direction. The Moon produces the same effect, +adding a contribution to the precession which peaks twice +per month. The Moon's proximity to the Earth more than compensates +for its smaller mass and gravitational attraction, so that it +in fact contributes most of the precessional effect. + +The complex interactions between the three bodies produce a +precessional motion that is wobbly rather than completely smooth. +However, the main 26,000-year component is on such a grand scale that +it dwarfs the remaining terms, the biggest of +which has an amplitude of only \arcseci{17} and a period of +about 18.6~years. This difference of scale makes it convenient to treat +these two components of the motion separately. The main 26,000-year +effect is called {\it luni-solar precession}; the smaller, +faster, periodic terms are called the {\it nutation}. + +Note that precession and nutation are simply +different frequency components of the same physical effect. It is +a common misconception that precession is caused +by the Sun and nutation is caused by the Moon. In fact +the Moon is responsible for two-thirds of the precession, and, +while it is true that much of the complex detail of the nutation is +a reflection of the intricacies of the lunar orbit, there are +nonetheless important solar terms in the nutation. + +In addition to and quite separate +from the precession/nutation effect, the orbit of the Earth-Moon system +is not fixed in orientation, a result of the attractions of the +planets. This slow (about \arcsec{0}{5}~per~year) +secular rotation of the ecliptic about a slowly-moving diameter is called, +confusingly, {\it planetary +precession}\/ and, along with the luni-solar precession is +included in the {\it general precession}. The equator and +ecliptic as affected by general precession +are what define the various ``mean'' \radec\ reference frames. + +The models for precession and nutation come from a combination +of observation and theory, and are subject to continuous +refinement. Nutation models in particular have reached a high +degree of sophistication, taking into account such things as +the non-rigidity of the Earth and the effects of +the planets; SLALIB's nutation +model (IAU~1980) involves 106 terms in each of $\psi$ (longitude) +and $\epsilon$ (obliquity), some as small as \arcsec{0}{0001}. + +\subsubsection{SLALIB support for precession and nutation} +SLALIB offers a choice of three precession models: +\begin{itemize} +\item The old Bessel-Newcomb, pre IAU~1976, ``FK4'' model, used for B1950 + star positions and other pre-1984.0 purposes +(sla\_PREBN). +\item The new Fricke, IAU~1976, ``FK5'' model, used for J2000 star + positions and other post-1984.0 purposes +(sla\_PREC). +\item A model published by Simon {\it et al.}\ which is more accurate than + the IAU~1976 model and which is suitable for long + periods of time +(sla\_PRECL). +\end{itemize} +In each case, the named SLALIB routine generates the $(3\times3)$ +{\it precession +matrix}\/ for a given start and finish time. For example, +here is the Fortran code for generating the rotation +matrix which describes the precession between the epochs +J2000 and J1985.372 (IAU 1976 model): +\goodbreak +\begin{verbatim} + DOUBLE PRECISION PMAT(3,3) + : + CALL sla_PREC(2000D0,1985.372D0,PMAT) +\end{verbatim} +\goodbreak +It is instructive to examine the resulting matrix: +\goodbreak +\begin{verbatim} + +0.9999936402 +0.0032709208 +0.0014214694 + -0.0032709208 +0.9999946505 -0.0000023247 + -0.0014214694 -0.0000023248 +0.9999989897 +\end{verbatim} +\goodbreak +Note that the diagonal elements are close to unity, and the +other elements are small. This shows that over an interval as +short as 15~years the precession isn't going to move a +position vector very far (in this case about \degree{0}{2}). + +For convenience, a direct \radec\ to \radec\ precession routine is +also provided +(sla\_PRECES), +suitable for either the old or the new system (but not a +mixture of the two). + +SLALIB provides only one nutation model, the new, IAU~1980 model, +implemented in the routine +sla\_NUTC. +This returns the components of nutation +in longitude and latitude (and also provides the obliquity) from +which a nutation matrix can be generated by calling +sla\_DEULER +(and from which the {\it equation of the equinoxes}, described +later, can be found). Alternatively, +the nutation matrix can be generated in a single call by using +sla\_NUT. + +A rotation matrix for applying the entire precession/nutation +transformation in one go can be generated by calling +sla\_PRENUT. + +\subsection{Mean Places} +The main effect of the precession/nutation is a steady increase of about +\arcseci{50}/year in the ecliptic longitudes of the stars. It is therefore +essential, when reporting the position of an astronomical target, to +qualify the coordinates with a date, or {\it epoch}. +Specifying the epoch ties down the equator and +equinox which define the \radec\ coordinate system that is +being used. +\footnote{An equinox is, however, not required for coordinates +in the International Celestial Reference System. Such coordinates must +be labelled simply ``ICRS'', or the specific catalogue can be mentioned, +such as ``Hipparcos''; constructions such as ``Hipparcos, J2000'' are +redundant and misleading.} For simplicity, only +the smooth and steady ``general +precession'' part of the complete precession/nutation effect is +included, thereby defining what is called the {\it mean}\/ +equator and equinox for the epoch concerned. We say a star +has a mean place of (for example) +\hms{12}{07}{58}{09}~\dms{-19}{44}{37}{1} ``with respect to the mean equator +and equinox of epoch J2000''. The short way of saying +this is ``\radec\ equinox J2000'' ({\bf not} ``\radec\ epoch J2000'', +which means something different to do with +proper motion). + +\subsection{Epoch} +The word ``epoch'' just means a moment in time, and can be supplied +in a variety of forms, using different calendar systems and timescales. + +For the purpose of specifying the epochs associated with the +mean place of a star, two conventions exist. Both sorts of epoch +superficially resemble years AD but are not tied to the civil +(Gregorian) calendar; to distinguish them from ordinary calendar-years +there is often +a ``.0'' suffix (as in ``1950.0''), although any other fractional +part is perfectly legal ({\it e.g.}\ 1987.5). + +The older system, +{\it Besselian epoch}, is defined in such a way that its units are +tropical years of about 365.2422~days and its timescale is the +obsolete {\it Ephemeris Time}. +The start of the Besselian year is the moment +when the ecliptic longitude of the mean Sun is +$280^{\circ}$; this happens near the start of the +calendar year (which is why $280^{\circ}$ was chosen). + +The new system, {\it Julian epoch}, was adopted as +part of the IAU~1976 revisions (about which more will be said +in due course) and came formally into use at the +beginning of 1984. It uses the Julian year of exactly +365.25~days; Julian epoch 2000 is defined to be 2000~January~1.5 in the +TT timescale. + +For specifying mean places, various standard epochs are in use, the +most common ones being Besselian epoch 1950.0 and Julian epoch 2000.0. +To distinguish the two systems, Besselian epochs +are now prefixed ``B'' and Julian epochs are prefixed ``J''. +Epochs without an initial letter can be assumed to be Besselian +if before 1984.0, otherwise Julian. These details are supported by +the SLALIB routines +sla\_DBJIN +(decodes numbers from a +character string, accepting an optional leading B or J), +sla\_KBJ +(decides whether B or J depending on prefix or range) and +sla\_EPCO +(converts one epoch to match another). + +SLALIB has four routines for converting +Besselian and Julian epochs into other forms. +The functions +sla\_EPB2D +and +sla\_EPJ2D +convert Besselian and Julian epochs into MJD; the functions +sla\_EPB +and +sla\_EPJ +do the reverse. For example, to express B1950 as a Julian epoch: +\goodbreak +\begin{verbatim} + DOUBLE PRECISION sla_EPJ,sla_EPB2D + : + WRITE (*,'(1X,''J'',F10.5)') sla_EPJ(sla_EPB2D(1950D0)) +\end{verbatim} +\goodbreak +(The answer is J1949.99979.) + +\subsection{Proper Motion} +Stars in catalogues usually have, in addition to the +\radec\ coordinates, a {\it proper motion} $[\mu_\alpha,\mu_\delta]$. +This is an intrinsic motion +of the star across the background. Very few stars have a +proper motion which exceeds \arcseci{1}/year, and most are +far below this level. A star observed as part of normal +astronomy research will, as a rule, have a proper motion +which is unknown. + +Mean \radec\ and rate of change are not sufficient to pin +down a star; the epoch at which the \radec\ was or will +be correct is also needed. Note the distinction +between the epoch which specifies the +coordinate system and the epoch at which the star passed +through the given \radec. The full specification for a star +is \radec, proper motions, equinox and epoch (plus something to +identify which set of models for the precession {\it etc.}\ is +being used -- see the next section). +For convenience, coordinates given in star catalogues are almost +always adjusted to make the equinox and epoch the same -- for +example B1950 in the case of the SAO~catalogue. + +SLALIB provides one routine to handle proper motion on its own, +sla\_PM. +Proper motion is also allowed for in various other +routines as appropriate, for example +sla\_MAP +and +sla\_FK425. +Note that in all SLALIB routines which involve proper motion +the units are radians per year and the +$\alpha$ component is in the form $\dot{\alpha}$ ({\it i.e.}\ big +numbers near the poles). +Some star catalogues have proper motion per century, and +in some catalogues the $\alpha$ component is in the form +$\dot{\alpha}\cos\delta$ ({\it i.e.}\ angle on the sky). + +\subsection{Parallax and Radial Velocity} +For the utmost accuracy and the nearest stars, allowance can +be made for {\it annual parallax}\/ and for the effects of perspective +on the proper motion. + +Parallax is appreciable only for nearby stars; even +the nearest, Proxima Centauri, is displaced from its average +position by less than +an arcsecond as the Earth revolves in its orbit. + +For stars with a known parallax, knowledge of the radial velocity +allows the proper motion to be expressed as an actual space +motion in 3~dimensions. The proper motion is, +in fact, a snapshot of the transverse component of the +space motion, and in the case of nearby stars will +change with time due to perspective. + +SLALIB does not provide facilities for handling parallax +and radial-velocity on their own, but their contribution is +allowed for in such routines as +sla\_PM, +sla\_MAP +and +sla\_FK425. +Catalogue mean +places do not include the effects of parallax and are therefore +{\it barycentric}; when pointing telescopes {\it etc.}\ it is +usually most efficient to apply the slowly-changing +parallax correction to the mean place of the target early on +and to work with the {\it geocentric}\/ mean place. This latter +approach is implied in Figure~1. + +\subsection{Aberration} +The finite speed of light combined with the motion of the observer +around the Sun during the year causes apparent displacements of +the positions of the stars. The effect is called +the {\it annual aberration} (or ``stellar'' +aberration). Its maximum size, about \arcsec{20}{5}, +occurs for stars $90^{\circ}$ from the point towards which +the Earth is headed as it orbits the Sun; a star exactly in line with +the Earth's motion is not displaced. To receive the light of +a star, the telescope has to be offset slightly in the direction of +the Earth's motion. A familiar analogy is the need to tilt your +umbrella forward when on the move, to avoid getting wet. This +Newtonian model is, +in fact, highly misleading in the context of light as opposed +to rain, but happens to give the same answer as a relativistic +treatment to first order (better than 1~milliarcsecond). + +Before the IAU 1976 resolutions, different +values for the approximately +\arcsec{20}{5} {\it aberration constant}\/ were employed +at different times, and this can complicate comparisons +between different catalogues. Another complication comes from +the so-called {\it E-terms of aberration}, +that small part of the annual aberration correction that is a +function of the eccentricity of the Earth's orbit. The E-terms, +maximum amplitude about \arcsec{0}{3}, +happen to be approximately constant for a given star, and so they +used to be incorporated in the catalogue \radec\/ +to reduce the labour of converting to and from apparent place. +The E-terms can be removed from a catalogue \radec\/ by +calling +sla\_SUBET +or applied (for example to allow a pulsar +timing-position to be plotted on a B1950 finding chart) +by calling +sla\_ADDET; +the E-terms vector itself can be obtained by calling +sla\_ETRMS. +Star positions post IAU 1976 are free of these distortions, and to +apply corrections for annual aberration involves the actual +barycentric velocity of the Earth rather than the use of +canonical circular-orbit models. + +The annual aberration is the aberration correction for +an imaginary observer at the Earth's centre. +The motion of a real observer around the Earth's rotation axis in +the course of the day makes a small extra contribution to the total +aberration effect called the {\it diurnal aberration}. Its +maximum amplitude is about \arcsec{0}{2}. + +No SLALIB routine is provided for calculating the aberration on +its own, though the required velocity vectors can be +generated using +sla\_EVP +and +sla\_GEOC. +Annual and diurnal aberration are allowed for where required, for example in +sla\_MAP +{\it etc}.\ and +sla\_AOP +{\it etc}. Note that this sort +of aberration is different from the {\it planetary +aberration}, which is the apparent displacement of a solar-system +body, with respect to the ephemeris position, as a consequence +of the motion of {\it both}\/ the Earth and the source. The +planetary aberration can be computed either by correcting the +position of the solar-system body for light-time, followed by +the ordinary stellar aberration correction, or more +directly by expressing the position and velocity of the source +in the observer's frame and correcting for light-time alone. + +\subsection{Different Sorts of Mean Place} +A particularly confusing aspect of published mean places is that they +are sensitive to the precise way they were determined. A mean +place is not directly observable, even with fundamental +instruments such as transit circles, and to produce a mean +place will involve relying on some existing star catalogue, +for example the fundamental catalogues FK4 and FK5, +and applying given mathematical models of precession, nutation, +aberration and so on. +Note in particular that no star catalogue, +even a fundamental catalogue such as FK4 or +FK5, defines a coordinate system, strictly speaking; +it is merely a list of star positions and proper motions. +However, once the stars from a given catalogue +are used as position calibrators, {\it e.g.}\ for +transit-circle observations or for plate reductions, then a +broader sense of there being a coordinate grid naturally +arises, and such phrases as ``in the system of +the FK4'' can legitimately be employed. However, +there is no formal link between the +two concepts -- no ``standard least squares fit'' between +reality and the inevitably flawed catalogues.\footnote{This was +true until the inception of the International Celestial Reference +System, which is based on the idea of axes locked into the +distant background. The coordinates +of the extragalactic sources which realize these +axes have no individual significance; there is a ``no net rotation'' +condition which has to be satisfied each time any revisions take +place.} All such +catalogues suffer at some level from systematic, zonal distortions +of both the star positions and of the proper motions, +and include measurement errors peculiar to individual +stars. + +Many of these complications are of little significance except to +specialists. However, observational astronomers cannot +escape exposure to at least the two main varieties of +mean place, loosely called +FK4 and FK5, and should be aware of +certain pitfalls. For most practical purposes the more recent +system, FK5, is free of surprises and tolerates naive +use well. FK4, in contrast, contains two important traps: +\begin{itemize} +\item The FK4 system rotates at about + \arcsec{0}{5} per century relative to distant galaxies. + This is manifested as a systematic distortion in the + proper motions of all FK4-derived catalogues, which will + in turn pollute any astrometry done using those catalogues. + For example, FK4-based astrometry of a QSO using plates + taken decades apart will reveal a non-zero {\it fictitious proper + motion}, and any FK4 star which happens to have zero proper + motion is, in fact, slowly moving against the distant + background. The FK4 frame rotates because it was + established before the nature of the Milky Way, and hence the + existence of systematic motions of nearby stars, had been + recognized. +\item Star positions in the FK4 system are part-corrected for + annual aberration (see above) and embody the so-called + E-terms of aberration. +\end{itemize} +The change from the old FK4-based system to FK5 +occurred at the beginning +of 1984 as part of a package of resolutions made by the IAU in 1976, +along with the adoption of J2000 as the reference epoch. Star +positions in the newer, FK5, system are free from the E-terms, and +the system is a much better approximation to an +inertial frame (about five times better). + +It may occasionally be convenient to specify the FK4 fictitious proper +motion directly. In FK4, the centennial proper motion of (for example) +a QSO is: + +$\mu_\alpha=-$\tsec{0}{015869}$ + +(($\tsec{0}{029032}$~\sin \alpha + +$\tsec{0}{000340}$~\cos \alpha ) \sin \delta + -$\tsec{0}{000105}$~\cos \alpha + -$\tsec{0}{000083}$~\sin \alpha ) \sec \delta $ \\ +$\mu_\delta\,=+$\arcsec{0}{43549}$~\cos \alpha + -$\arcsec{0}{00510}$~\sin \alpha + + ($\arcsec{0}{00158}$~\sin \alpha + -$\arcsec{0}{00125}$~\cos \alpha ) \sin \delta + -$\arcsec{0}{00066}$~\cos \delta $ + +\subsection{Mean Place Transformations} +Figure~1 is based upon three varieties of mean \radec\ all of which are +of practical significance to observing astronomers in the present era: +\begin{itemize} + \item Old style (FK4) with known proper motion in the FK4 + system, and with parallax and radial velocity either + known or assumed zero. + \item Old style (FK4) with zero proper motion in FK5, + and with parallax and radial velocity assumed zero. + \item New style (FK5) with proper motion, parallax and + radial velocity either known or assumed zero. +\end{itemize} +The figure outlines the steps required to convert positions in +any of these systems to a J2000 \radec\ for the current +epoch, as might be required in a telescope-control +program for example. +Most of the steps can be carried out by calling a single +SLALIB routines; there are other SLALIB routines which +offer set-piece end-to-end transformation routines for common cases. +Note, however, that SLALIB does not set out to provide the capability +for arbitrary transformations of star-catalogue data +between all possible systems of mean \radec. +Only in the (common) cases of FK4, equinox and epoch B1950, +to FK5, equinox and epoch J2000, and {\it vice versa}\/ are +proper motion, parallax and radial velocity transformed +along with the star position itself, the +focus of SLALIB support. + +As an example of using SLALIB to transform mean places, here is +a program which implements the top-left path of Figure~1. +An FK4 \radec\ of arbitrary equinox and epoch and with +known proper motion and +parallax is transformed into an FK5 J2000 \radec\ for the current +epoch. As a test star we will use $\alpha=$\hms{16}{09}{55}{13}, +$\delta=$\dms{-75}{59}{27}{2}, equinox 1900, epoch 1963.087, +$\mu_\alpha=$\tsec{-0}{0312}$/y$, $\mu_\delta=$\arcsec{+0}{103}$/y$, +parallax = \arcsec{0}{062}, radial velocity = $-34.22$~km/s. The +epoch of observation is 1994.35. +\goodbreak +\begin{verbatim} + IMPLICIT NONE + DOUBLE PRECISION AS2R,S2R + PARAMETER (AS2R=4.8481368110953599D-6,S2R=7.2722052166430399D-5) + INTEGER J,I + DOUBLE PRECISION R0,D0,EQ0,EP0,PR,PD,PX,RV,EP1,R1,D1,R2,D2,R3,D3, + : R4,D4,R5,D5,R6,D6,EP1D,EP1B,W(3),EB(3),PXR,V(3) + DOUBLE PRECISION sla_EPB,sla_EPJ2D + + * RA, Dec etc of example star + CALL sla_DTF2R(16,09,55.13D0,R0,J) + CALL sla_DAF2R(75,59,27.2D0,D0,J) + D0=-D0 + EQ0=1900D0 + EP0=1963.087D0 + PR=-0.0312D0*S2R + PD=+0.103D0*AS2R + PX=0.062D0 + RV=-34.22D0 + EP1=1994.35D0 + + * Epoch of observation as MJD and Besselian epoch + EP1D=sla_EPJ2D(EP1) + EP1B=sla_EPB(EP1D) + + * Space motion to the current epoch + CALL sla_PM(R0,D0,PR,PD,PX,RV,EP0,EP1B,R1,D1) + + * Remove E-terms of aberration for the original equinox + CALL sla_SUBET(R1,D1,EQ0,R2,D2) + + * Precess to B1950 + R3=R2 + D3=D2 + CALL sla_PRECES('FK4',EQ0,1950D0,R3,D3) + + * Add E-terms for the standard equinox B1950 + CALL sla_ADDET(R3,D3,1950D0,R4,D4) + + * Transform to J2000, no proper motion + CALL sla_FK45Z(R4,D4,EP1B,R5,D5) + + * Parallax + CALL sla_EVP(sla_EPJ2D(EP1),2000D0,W,EB,W,W) + PXR=PX*AS2R + CALL sla_DCS2C(R5,D5,V) + DO I=1,3 + V(I)=V(I)-PXR*EB(I) + END DO + CALL sla_DCC2S(V,R6,D6) + : +\end{verbatim} +\goodbreak +It is interesting to look at how the \radec\ changes during the +course of the calculation: +\begin{tabbing} +xxxxxxxxxxxxxx \= xxxxxxxxxxxxxxxxxxxxxxxxx \= x \= \kill +\> {\tt 16 09 55.130 -75 59 27.20} \> \> {\it original equinox and epoch} \\ +\> {\tt 16 09 54.155 -75 59 23.98} \> \> {\it with space motion} \\ +\> {\tt 16 09 54.229 -75 59 24.18} \> \> {\it with old E-terms removed} \\ +\> {\tt 16 16 28.213 -76 06 54.57} \> \> {\it precessed to 1950.0} \\ +\> {\tt 16 16 28.138 -76 06 54.37} \> \> {\it with new E-terms} \\ +\> {\tt 16 23 07.901 -76 13 58.87} \> \> {\it J2000, current epoch} \\ +\> {\tt 16 23 07.907 -76 13 58.92} \> \> {\it including parallax} +\end{tabbing} + +Other remarks about the above (unusually complicated) example: +\begin{itemize} +\item If the original equinox and epoch were B1950, as is quite + likely, then it would be unnecessary to treat space motions + and E-terms explicitly. Transformation to FK5 J2000 could + be accomplished simply by calling +sla\_FK425, after which + a call to +sla\_PM and the parallax code would complete the + work. +\item The rigorous treatment of the E-terms + has only a small effect on the result. Such refinements + are, nevertheless, worthwhile in order to facilitate comparisons and + to increase the chances that star positions from different + suppliers are compatible. +\item The FK4 to FK5 transformations, +sla\_FK425 + and +sla\_FK45Z, + are not as is sometimes assumed simply 50 years of precession, + though this indeed accounts for most of the change. The + transformations also include adjustments + to the equinox, a revised precession model, elimination of the + E-terms, a change to the proper-motion time unit and so on. + The reason there are two routines rather than just one + is that the FK4 frame rotates relative to the background, whereas + the FK5 frame is a much better approximation to an + inertial frame, and zero proper + motion in FK4 does not, therefore, mean zero proper motion in FK5. + SLALIB also provides two routines, +sla\_FK524 + and +sla\_FK54Z, + to perform the inverse transformations. +\item Some star catalogues (FK4 itself is one) were constructed using slightly + different procedures for the polar regions compared with + elsewhere. SLALIB ignores this inhomogeneity and always + applies the standard + transformations irrespective of location on the celestial sphere. +\end{itemize} + +\subsection {Mean Place to Apparent Place} +The {\it geocentric apparent place}\/ of a source, or {\it apparent place}\/ +for short, +is the \radec\ if viewed from the centre of the Earth, +with respect to the true equator and equinox of date. +Transformation of an FK5 mean \radec, equinox J2000, +current epoch, to apparent place involves the following effects: +\goodbreak +\begin{itemize} + \item Light deflection -- the gravitational lens effect of + the sun. + \item Annual aberration. + \item Precession/nutation. +\end{itemize} +The {\it light deflection}\/ is seldom significant. Its value +at the limb of the Sun is about +\arcsec{1}{74}; it falls off rapidly with distance from the +Sun and has shrunk to about +\arcsec{0}{02} at an elongation of $20^\circ$. + +As already described, the {\it annual aberration}\/ +is a function of the Earth's velocity +relative to the solar system barycentre (available through the +SLALIB routine +sla\_EVP) +and produces shifts of up to about \arcsec{20}{5}. + +The {\it precession/nutation}, from J2000 to the current epoch, is +expressed by a rotation matrix which is available through the +SLALIB routine +sla\_PRENUT. + +The whole mean-to-apparent transformation can be done using the SLALIB +routine +sla\_MAP. As a demonstration, here is a program which lists the +{\it North Polar Distance}\/ ($90^\circ-\delta$) of Polaris for +the decade of closest approach to the Pole: +\goodbreak +\begin{verbatim} + IMPLICIT NONE + DOUBLE PRECISION PI,PIBY2,D2R,S2R,AS2R + PARAMETER (PI=3.141592653589793238462643D0) + PARAMETER (D2R=PI/180D0, + : PIBY2=PI/2D0, + : S2R=PI/(12D0*3600D0), + : AS2R=PI/(180D0*3600D0)) + DOUBLE PRECISION RM,DM,PR,PD,DATE,RA,DA + INTEGER J,IDS,IDE,ID,IYMDF(4),I + DOUBLE PRECISION sla_EPJ2D + + CALL sla_DTF2R(02,31,49.8131D0,RM,J) + CALL sla_DAF2R(89,15,50.661D0,DM,J) + PR=+21.7272D0*S2R/100D0 + PD=-1.571D0*AS2R/100D0 + WRITE (*,'(1X,'// + : '''Polaris north polar distance (deg) 2096-2105''/)') + WRITE (*,'(4X,''Date'',7X''NPD''/)') + CALL sla_CLDJ(2096,1,1,DATE,J) + IDS=NINT(DATE) + CALL sla_CLDJ(2105,12,31,DATE,J) + IDE=NINT(DATE) + DO ID=IDS,IDE,10 + DATE=DBLE(ID) + CALL sla_DJCAL(0,DATE,IYMDF,J) + CALL sla_MAP(RM,DM,PR,PD,0D0,0D0,2000D0,DATE,RA,DA) + WRITE (*,'(1X,I4,2I3.2,F9.5)') (IYMDF(I),I=1,3),(PIBY2-DA)/D2R + END DO + + END +\end{verbatim} +\goodbreak +For cases where the transformation has to be repeated for different +times or for more than one star, the straightforward +sla\_MAP +approach is apt to be +wasteful as both the Earth velocity and the +precession/nutation matrix can be re-calculated relatively +infrequently without ill effect. A more efficient method is to +perform the target-independent calculations only when necessary, +by calling +sla\_MAPPA, +and then to use either +sla\_MAPQKZ, +when only the \radec\/ is known, or +sla\_MAPQK, +when full catalogue positions, including proper motion, parallax and +radial velocity, are available. How frequently to call +sla\_MAPPA +depends on the accuracy objectives; once per +night will deliver sub-arcsecond accuracy for example. + +The routines +sla\_AMP +and +sla\_AMPQK +allow the reverse transformation, from apparent to mean place. + +\subsection{Apparent Place to Observed Place} +The {\it observed place}\/ of a source is its position as +seen by a perfect theodolite at the location of the +observer. Transformation of an apparent \radec\ to observed +place involves the following effects: +\goodbreak +\begin{itemize} + \item \radec\ to \hadec. + \item Diurnal aberration. + \item \hadec\ to \azel. + \item Refraction. +\end{itemize} +The transformation from apparent \radec\ to +apparent \hadec\ is made by allowing for +{\it Earth rotation}\/ through the {\it sidereal time}, $\theta$: +\[ h = \theta - \alpha \] +For this equation to work, $\alpha$ must be the apparent right +ascension for the time of observation, and $\theta$ must be +the {\it local apparent sidereal time}. The latter is obtained +as follows: +\begin{enumerate} +\item from civil time obtain the coordinated universal time, UTC + (more later on this); +\item add the UT1$-$UTC (typically a few tenths of a second) to + give the UT; +\item from the UT compute the Greenwich mean sidereal time (using +sla\_GMST); +\item add the observer's (east) longitude, giving the local mean + sidereal time; +\item add the equation of the equinoxes (using +sla\_EQEQX). +\end{enumerate} +The {\it equation of the equinoxes}\/~($=\Delta\psi\cos\epsilon$ plus +small terms) +is the effect of nutation on the sidereal time. +Its value is typically a second or less. It is +interesting to note that if the object of the exercise is to +transform a mean place all the way into an observed place (very +often the case), +then the equation of the +equinoxes and the longitude component of nutation can both be +omitted, removing a great deal of computation. However, SLALIB +follows the normal convention and works {\it via}\/ the apparent place. + +Note that for very precise work the observer's longitude should +be corrected for {\it polar motion}. This can be done with +sla\_POLMO. +The corrections are always less than about \arcsec{0}{3}, and +are futile unless the position of the observer's telescope is known +to better than a few metres. + +Tables of observed and +predicted UT1$-$UTC corrections and polar motion data +are published every few weeks by the International Earth Rotation Service. + +The transformation from apparent \hadec\ to {\it topocentric}\/ +\hadec\ consists of allowing for +{\it diurnal aberration}. This effect, maximum amplitude \arcsec{0}{2}, +was described earlier. There is no specific SLALIB routine +for computing the diurnal aberration, +though the routines +sla\_AOP {\it etc.}\ +include it, and the required velocity vector can be +determined by calling +sla\_GEOC. + +The next stage is the major coordinate rotation from local equatorial +coordinates \hadec\ into horizon coordinates. The SLALIB routines +sla\_E2H +{\it etc.}\ can be used for this. For high-precision +applications the mean geodetic latitude should be corrected for polar +motion. + +\subsubsection{Refraction} +The final correction is for atmospheric refraction. +This effect, which depends on local meteorological conditions and +the effective colour of the source/detector combination, +increases the observed elevation of the source by a +significant effect even at moderate zenith distances, and near the +horizon by over \degree{0}{5}. The amount of refraction can by +computed by calling the SLALIB routine +sla\_REFRO; +however, +this requires as input the observed zenith distance, which is what +we are trying to predict. For high precision it is +therefore necessary to iterate, using the topocentric +zenith distance as the initial estimate of the +observed zenith distance. + +The full +sla\_REFRO refraction calculation is onerous, and for +zenith distances of less than, say, $75^{\circ}$ the following +model can be used instead: + +\[ \zeta _{vac} \approx \zeta _{obs} + + A \tan \zeta _{obs} + + B \tan ^{3}\zeta _{obs} \] +where $\zeta _{vac}$ is the topocentric +zenith distance (i.e.\ {\it in vacuo}), +$\zeta _{obs}$ is the observed +zenith distance (i.e.\ affected by refraction), and $A$ and $B$ are +constants, about \arcseci{60} +and \arcsec{-0}{06} respectively for a sea-level site. +The two constants can be calculated for a given set of conditions +by calling either +sla\_REFCO or +sla\_REFCOQ. + +sla\_REFCO works by calling +sla\_REFRO for two zenith distances and fitting $A$ and $B$ +to match. The calculation is onerous, but delivers accurate +results whatever the conditions. +sla\_REFCOQ uses a direct formulation of $A$ and $B$ and +is much faster; it is slightly less accurate than +sla\_REFCO but more than adequate for most practical purposes. + +Like the full refraction model, the two-term formulation works in the wrong +direction for our purposes, predicting +the {\it in vacuo}\/ (topocentric) zenith distance +given the refracted (observed) zenith distance, +rather than {\it vice versa}. The obvious approach of +interchanging $\zeta _{vac}$ and $\zeta _{obs}$ and +reversing the signs, though approximately +correct, gives avoidable errors which are just significant in +some applications; for +example about \arcsec{0}{2} at $70^\circ$ zenith distance. A +much better result can easily be obtained, by using one Newton-Raphson +iteration as follows: + +\[ \zeta _{obs} \approx \zeta _{vac} + - \frac{A \tan \zeta _{vac} + B \tan ^{3}\zeta _{vac}} + {1 + ( A + 3 B \tan ^{2}\zeta _{vac} ) \sec ^{2}\zeta _{vac}}\] + +The effect of refraction can be applied to an unrefracted +zenith distance by calling +sla\_REFZ or to an unrefracted +\xyz\ by calling +sla\_REFV. +Over most of the sky these two routines deliver almost identical +results, but beyond $\zeta=83^\circ$ +sla\_REFV +becomes unacceptably inaccurate while +sla\_REFZ +remains usable. (However +sla\_REFV +is significantly faster, which may be important in some applications.) +SLALIB also provides a routine for computing the airmass, the function +sla\_AIRMAS. + +The refraction ``constants'' returned by +sla\_REFCO and +sla\_REFCOQ +are slightly affected by colour, especially at the blue end +of the spectrum. Where values for more than one +wavelength are needed, rather than calling +sla\_REFCO +several times it is more efficient to call +sla\_REFCO +just once, for a selected ``base'' wavelength, and then to call +sla\_ATMDSP +once for each wavelength of interest. + +All the SLALIB refraction routines work for radio wavelengths as well +as the optical/IR band. The radio refraction is very dependent on +humidity, and an accurate value must be supplied. There is no +wavelength dependence, however. The choice of optical/IR or +radio is made by specifying a wavelength greater than $100\mu m$ +for the radio case. + +\subsubsection{Efficiency considerations} +The complete apparent place to observed place transformation +can be carried out by calling +sla\_AOP. +For improved efficiency +in cases of more than one star or a sequence of times, the +target-independent calculations can be done once by +calling +sla\_AOPPA, +the time can be updated by calling +sla\_AOPPAT, +and +sla\_AOPQK +can then be used to perform the +apparent-to-observed transformation. The reverse transformation +is available through +sla\_OAP +and +sla\_OAPQK. +({\it n.b.}\ These routines use accurate but computationally-expensive +refraction algorithms for zenith distances beyond about $76^\circ$. +For many purposes, in-line code tailored to the accuracy requirements +of the application will be preferable, for example ignoring UT1$-$UTC, +omitting diurnal aberration and using +sla\_REFZ +to apply the refraction.) + +\subsection{The Hipparcos Catalogue and the ICRS} +With effect from the beginning of 1998, the IAU adopted a new +reference system to replace FK5 J2000. The new system, called the +International Celestial Reference System (ICRS), differs profoundly +from all predecessors in that the link with solar-system dynamics +was broken; the ICRS axes are defined in terms of the directions +of a set of extragalactic sources, not in terms of the mean equator and +equinox at a given reference epoch. Although the ICRS and FK5 coordinates +of any given object are almost the same, the orientation of the new frame +was essentially arbitrary, and the close match to FK5 J2000 was contrived +purely for reasons of continuity and convenience. + +A distinction is made between the reference {\it system}\/ (the ICRS) +and {\it frame}\/ (ICRF). The ICRS is the set of prescriptions and +conventions together with the modelling required to define, at any +time, a triad of axes. The ICRF is a practical realization, and +currently consists of a catalogue of equatorial coordinates for 608 +extragalactic radio sources observed by VLBI. + +The best optical realization of the ICRF currently available is the +Hipparcos catalogue. The extragalactic sources were not directly +observable by the Hipparcos satellite and so the link from Hipparcos +to ICRF was established through a variety of indirect techniques: VLBI and +conventional interferometry of radio stars, photographic astrometry +and so on. The Hipparcos frame is aligned to the ICRF to within about +0.5~mas and 0.5~mas/year (at epoch 1991.25). + +The Hipparcos catalogue includes all of the FK5 stars, which has enabled +the orientation and spin of the latter to be studied. At epoch J2000, +the misalignment of the FK5 frame with respect to Hipparcos +(and hence ICRS) are about 32~mas and 1~mas/year respectively. +Consequently, for many practical purposes, including pointing +telescopes, the IAU 1976-1982 conventions on reference frames and +Earth orientation remain adequate and there is no need to change to +Hipparcos coordinates, new precession/nutation models and so on. +However, for the most exacting astrometric applications, SLALIB +provides some support for Hipparcos coordinates in the form of +four new routines: +sla\_FK52H and +sla\_H2FK5, +which transform FK5 positions and proper motions to the Hipparcos frame +and {\it vice versa,}\/ and +sla\_FK5HZ and +sla\_HFK5Z, +where the transformations are for stars whose Hipparcos proper motion is +zero. + +Further information on the ICRS can be found in the paper by M.\,Feissel +and F.\,Mignard, Astron.\,Astrophys. 331, L33-L36 (1988). + +\subsection{Timescales} +SLALIB provides for conversion between several timescales, and involves +use of one or two others. The full list is as follows: +\begin{itemize} +\item TAI: International Atomic Time +\item UTC: Coordinated Universal Time +\item UT: Universal Time +\item GMST: Greenwich Mean Sidereal Time +\item LAST: Local Apparent Sidereal Time +\item TT: Terrestrial Time +\item TDB: Barycentric Dynamical Time. +\end{itemize} +Three obsolete timescales should be mentioned here to avoid confusion. +\begin{itemize} +\item GMT: Greenwich Mean Time -- can mean either UTC or UT. +\item ET: Ephemeris Time -- more or less the same as either TT or TDB. +\item TDT: Terrestrial Dynamical Time -- former name of TT. +\end{itemize} + +\subsubsection{Atomic Time: TAI} +{\it International Atomic Time}\/ TAI is a laboratory timescale. Its +unit is the SI second, which is defined in terms of a +defined number +of wavelengths of the radiation produced by a certain electronic +transition in the caesium 133 atom. It +is realized through a changing +population of high-precision atomic clocks held +at standards institutes in various countries. There is an +elaborate process of continuous intercomparison, leading to +a weighted average of all the clocks involved. + +Though TAI shares the same second as the more familiar UTC, the +two timescales are noticeably separated in epoch because of the +build-up of leap seconds. At the time of writing, UTC +lags about half a minute behind TAI. + +For any given date, the difference TAI$-$UTC +can be obtained by calling the SLALIB routine +sla\_DAT. +Note, however, that an up-to-date copy of the routine must be used if +the most recent leap seconds are required. For applications +where this is critical, mechanisms independent of SLALIB +and under local control must +be set up; in such cases +sla\_DAT +can be useful as an +independent check, for test dates within the range of the +available version. Up-to-date information on TAI$-$UTC is available +from {\tt ftp://maia.usno.navy.mil/ser7/tai-utc.dat}. + +\subsubsection{Universal Time: UTC, UT1} +{\it Coordinated Universal Time}\/ UTC is the basis of civil timekeeping. +Most time zones differ from UTC by an integer number +of hours, though a few ({\it e.g.}\ parts of Canada and Australia) differ +by $n+0.5$~hours. The UTC second is the same as the SI second, +as for TAI. In the long term, UTC keeps in step with the +Sun. It does so even though the Earth's rotation is slightly +variable (due to large scale movements of water and atmosphere +among other things) by occasionally introducing a {\it leap +second}. + +{\it Universal Time}\/ UT, or more specifically UT1, +is in effect the mean solar time. It is continuous +({\it i.e.}\ there are no leap seconds) but has a variable +rate because of the Earth's non-uniform rotation period. It is +needed for computing the sidereal time, an essential part of +pointing a telescope at a celestial source. To obtain UT1, you +have to look up the value of UT1$-$UTC for the date concerned +in tables published by the International Earth Rotation +Service; this quantity, kept in the range +$\pm$\tsec{0}{9} by means of UTC leap +seconds, is then added to the UTC. The quantity UT1$-$UTC, +which typically changes by 1 or 2~ms per day, +can only be obtained by observation, though seasonal trends +are known and the IERS listings are able to predict some way into +the future with adequate accuracy for pointing telescopes. + +UTC leap seconds are introduced as necessary, +usually at the end of December or June. +On the average the solar day is slightly longer +than the nominal 86,400~SI~seconds and so leap seconds are always positive; +however, provision exists for negative leap seconds if needed. +The form of a leap second can be seen from the +following description of the end of June~1994: + +\hspace{3em} +\begin{tabular}{clrccc} \\ + & & & UTC & UT1$-$UTC & UT1 \\ \\ +1994 & June & 30 & 23 59 58 & $-0.218$ & 23 59 57.782 \\ + & & & 23 59 59 & $-0.218$ & 23 59 58.782 \\ + & & & 23 59 60 & $-0.218$ & 23 59 59.782 \\ + & July & 1 & 00 00 00 & $+0.782$ & 00 00 00.782 \\ + & & & 00 00 01 & $+0.782$ & 00 00 01.782 \\ +\end{tabular} + +Note that UTC has to be expressed as hours, minutes and +seconds (or at least in seconds for a given date) if leap seconds +are to be taken into account. It is improper to express a UTC as a +Julian Date, for example, because there will be an ambiguity +during a leap second (in the above example, +1994~June~30 \hms{23}{59}{60}{0} and +1994~July~1 \hms{00}{00}{00}{0} would {\it both}\/ come out as +MJD~49534.00000). Although in the vast majority of +cases this won't matter, there are potential problems in +on-line data acquisition systems and in applications involving +taking the difference between two times. Note that although the routines +sla\_DAT +and +sla\_DTT +expect UTC in the form of an MJD, the meaning here is really a +whole-number {\it date}\/ rather than a time. Though the routines will accept +a fractional part and will almost always function correctly, on a day +which ends with a leap +second incorrect results would be obtained during the leap second +itself because by then the MJD would have moved into the next day. + +\subsubsection{Sidereal Time: GMST, LAST} +Sidereal Time is the ``time of day'' relative to the +stars rather than to the Sun. After +one sidereal day the stars come back to the same place in the +sky, apart from sub-arcsecond precession effects. Because the Earth +rotates faster relative to the stars than to the Sun by one day +per year, the sidereal second is shorter than the solar +second; the ratio is about 0.9973. + +The {\it Greenwich Mean Sidereal Time}\/ GMST is +linked to UT1 by a numerical formula which +is implemented in the SLALIB routines +sla\_GMST +and +sla\_GMSTA. +There are, of course, no leap seconds in GMST, but the second +changes in length along with the UT1 second, and also varies +over long periods of time because of slow changes in the Earth's +orbit. This makes the timescale unsuitable for everything except +predicting the apparent directions of celestial sources. + +The {\it Local Apparent Sidereal Time}\/ LAST is the apparent right +ascension of the local meridian, from which the hour angle of any +star can be determined knowing its $\alpha$. It can be obtained from the +GMST by adding the east longitude (corrected for polar motion +in precise work) and the {\it equation of the equinoxes}. The +latter, already described, is an aspect of the nutation effect +and can be predicted by calling the SLALIB routine +sla\_EQEQX +or, neglecting certain very small terms, by calling +sla\_NUTC +and using the expression $\Delta\psi\cos\epsilon$. + +\subsubsection{Dynamical Time: TT, TDB} +Dynamical time is the independent variable in the theories +which describe the motions of bodies in the solar system. When +you use published formulae which model the position of the +Earth in its orbit, for example, or look up +the Moon's position in a precomputed ephemeris, the date and time +you use must be in terms of one of the dynamical timescales. It +is a common but understandable mistake to use UT directly, in which +case the results will be about 1~minute out (in the present +era). + +It is not hard to see why such timescales are necessary. +UTC would clearly be unsuitable as the argument of an +ephemeris because of leap seconds. +A solar-system ephemeris based on UT1 or sidereal time would somehow +have to include the unpredictable variations of the Earth's rotation. +TAI would work, but eventually +the ephemeris and the ensemble of atomic clocks would drift apart. +In effect, the ephemeris {\it is}\/ a clock, with the bodies of +the solar system the hands. + +Only two of the dynamical timescales are of any great importance to +observational astronomers, TT and TDB. (The obsolete +timescale ET, ephemeris time, was more or less the same as TT.) + +{\it Terrestrial Time}\/ TT is +the theoretical timescale of apparent geocentric ephemerides of solar +system bodies. It applies, in principle, +to an Earthbound clock, at sea-level, and for practical purposes +it is tied to +Atomic Time TAI through the formula TT~$=$~TAI~$+$~\tsec{32}{184}. +In practice, therefore, the units of TT are ordinary SI seconds, and +the offset of \tsec{32}{184} with respect to TAI is fixed. +The SLALIB routine +sla\_DTT +returns TT$-$UTC for a given UTC +({\it n.b.}\ sla\_DTT +calls +sla\_DAT, +and the latter must be an up-to-date version if recent leap seconds are +to be taken into account). + +{\it Barycentric Dynamical Time}\/ TDB differs from TT by an amount which +cycles back and forth by a millisecond or two due to +relativistic effects. The variation is +negligible for most purposes, but unless taken into +account would swamp +long-term analysis of pulse arrival times from the +millisecond pulsars. It is a consequence of +the TT clock being on the Earth rather than in empty +space: the ellipticity of +the Earth's orbit means that the TT clock's speed and +gravitational potential vary slightly +during the course of the year, and as a consequence +its rate as seen from an outside observer +varies due to transverse Doppler effect and gravitational +redshift. By definition, TDB and TT differ only +by periodic terms, and the main effect +is a sinusoidal variation of amplitude \tsec{0}{0016}; the +largest planetary terms are nearly two orders of magnitude +smaller. The SLALIB routine +sla\_RCC +provides a model of +TDB-TT accurate to a few nanoseconds. +There are other dynamical timescales, not supported by +SLALIB routines, which include allowance also for the secular terms. +These timescales gain on TT and TDB by about \tsec{0}{0013}/day. + +For most purposes the more accessible TT is the timescale to use, +for example when calling +sla\_PRENUT +to generate a precession/nutation matrix or when calling +sla\_EVP +to predict the +Earth's position and velocity. For some purposes TDB is the +correct timescale, for example when interrogating the JPL planetary +ephemeris (see {\it Starlink User Note~87}\/), though in most cases +TT will be near enough and will involve less computation. + +Investigations of topocentric solar-system phenomena such as +occultations and eclipses require solar time as well as dynamical +time. TT/TDB/ET is all that is required in order to compute the geocentric +circumstances, but if horizon coordinates or geocentric parallax +are to be tackled UT is also needed. A rough estimate +of $\Delta {\rm T} = {\rm ET} - {\rm UT}$ is +available via the routine +sla\_DT. +For a given epoch ({\it e.g.}\ 1650) this returns an approximation +to $\Delta {\rm T}$ in seconds. + +\subsection{Calendars} +The ordinary {\it Gregorian Calendar Date}, +together with a time of day, can be +used to express an epoch in any desired timescale. For many purposes, +however, a continuous count of days is more convenient, and for +this purpose the system of {\it Julian Day Number}\/ can be used. +JD zero is located about 7000~years ago, well before the +historical era, and is formally defined in terms of Greenwich noon; +Julian Day Number 2449444 began at noon on 1994 April~1. {\it Julian Date}\/ +is the same system but with a fractional part appended; +Julian Date 2449443.5 was the midnight on which 1994 April~1 +commenced. Because of the unwieldy size of Julian Dates +and the awkwardness of the half-day offset, it is +accepted practice to remove the leading `24' and the trailing `.5', +producing what is called the {\it Modified Julian Date}: +MJD~=~JD$-2400000.5$. SLALIB routines use MJD, as opposed to +JD, throughout, largely to avoid loss of precision. +1994 April~1 commenced at MJD~49443.0. + +Despite JD (and hence MJD) being defined in terms of (in effect) +UT, the system can be used in conjunction with other timescales +such as TAI, TT and TDB (and even sidereal time through the +concept of {\it Greenwich Sidereal Date}). However, it is improper +to express a UTC as a JD or MJD because of leap seconds. + +SLALIB has six routines for converting to and from dates in +the Gregorian calendar. The routines +sla\_CLDJ +and +sla\_CALDJ +both convert a calendar date into an MJD, the former interpreting +years between 0 and 99 as 1st century and the latter as late 20th or +early 21st century. The routines sla\_DJCL +and +sla\_DJCAL +both convert an MJD into calendar year, month, day and fraction of a day; +the latter performs rounding to a specified precision, important +to avoid dates like `{\tt 94 04 01.***}' appearing in messages. +Some of SLALIB's low-precision ephemeris routines +(sla\_EARTH, +sla\_MOON +and +sla\_ECOR) +work in terms of year plus day-in-year (where +day~1~=~January~1st, at least for the modern era). +This form of date can be generated by +calling +sla\_CALYD +(which defaults years 0-99 into 1950-2049) +or +sla\_CLYD +(which covers the full range from prehistoric times). + +\subsection{Geocentric Coordinates} +The location of the observer on the Earth is significant in a +number of ways. The most obvious, of course, is the effect of latitude +on the observed \azel\ of a star. Less obvious is the need to +allow for geocentric parallax when finding the Moon with a +telescope (and when doing high-precision work involving the +Sun or planets), and the need to correct observed radial +velocities and apparent pulsar periods for the effects +of the Earth's rotation. + +The SLALIB routine +sla\_OBS +supplies details of groundbased observatories from an internal +list. This is useful when writing applications that apply to +more than one observatory; the user can enter a brief name, +or browse through a list, and be spared the trouble of typing +in the full latitude, longitude {\it etc}. The following +Fortran code returns the full name, longitude and latitude +of a specified observatory: +\goodbreak +\begin{verbatim} + CHARACTER IDENT*10,NAME*40 + DOUBLE PRECISION W,P,H + : + CALL sla_OBS(0,IDENT,NAME,W,P,H) + IF (NAME.EQ.'?') ... (not recognized) +\end{verbatim} +\goodbreak +(Beware of the longitude sign convention, which is west +ve +for historical reasons.) The following lists all +the supported observatories: +\goodbreak +\begin{verbatim} + : + INTEGER N + : + N=1 + NAME=' ' + DO WHILE (NAME.NE.'?') + CALL sla_OBS(N,IDENT,NAME,W,P,H) + IF (NAME.NE.'?') THEN + WRITE (*,'(1X,I3,4X,A,4X,A)') N,IDENT,NAME + N=N+1 + END IF + END DO +\end{verbatim} +\goodbreak +The routine +sla\_GEOC +converts a {\it geodetic latitude}\/ +(one referred to the local horizon) to a geocentric position, +taking into account the Earth's oblateness and also the height +above sea level of the observer. The results are expressed in +vector form, namely as the distance of the observer from +the spin axis and equator respectively. The {\it geocentric +latitude}\/ can be found be evaluating ATAN2 of the +two numbers. A full 3-D vector description of the position +and velocity of the observer is available through the routine +sla\_PVOBS. +For a specified geodetic latitude, height above +sea level, and local sidereal time, +sla\_PVOBS +generates a 6-element vector containing the position and +velocity with respect to the true equator and equinox of +date ({\it i.e.}\ compatible with apparent \radec). For +some applications it will be necessary to convert to a +mean \radec\ frame (notably FK5, J2000) by multiplying +elements 1-3 and 4-6 respectively with the appropriate +precession matrix. (In theory an additional correction to the +velocity vector is needed to allow for differential precession, +but this correction is always negligible.) + +See also the discussion of the routine +sla\_RVEROT, +later. + +\subsection{Ephemerides} +SLALIB includes routines for generating positions and +velocities of Solar-System bodies. The accuracy objectives are +modest, and the SLALIB facilities do not attempt +to compete with precomputed ephemerides such as +those provided by JPL, or with models containing +thousands of terms. It is also worth noting +that SLALIB's very accurate star coordinate conversion +routines are not strictly applicable to solar-system cases, +though they are adequate for most practical purposes. + +Earth/Sun ephemerides can be generated using the routine +sla\_EVP, +which predicts Earth position and velocity with respect to both the +solar-system barycentre and the +Sun. Maximum velocity error is 0.42~metres per second; maximum +heliocentric position error is 1600~km (about \arcseci{2}), with +barycentric position errors about 4 times worse. +(The Sun's position as +seen from the Earth can, of course, be obtained simply by +reversing the signs of the Cartesian components of the +Earth\,:\,Sun vector.) + +Geocentric Moon ephemerides are available from +sla\_DMOON, +which predicts the Moon's position and velocity with respect to +the Earth's centre. Direction accuracy is usually better than +10~km (\arcseci{5}) and distance accuracy a little worse. + +Lower-precision but faster predictions for the Sun and Moon +can be made by calling +sla\_EARTH +and +sla\_MOON. +Both are single precision and accept dates in the form of +year, day-in-year and fraction of day +(starting from a calendar date you need to call +sla\_CLYD +or +sla\_CALYD +to get the required year and day). +The +sla\_EARTH +routine returns the heliocentric position and velocity +of the Earth's centre for the mean equator and +equinox of date. The accuracy is better than 20,000~km in position +and 10~metres per second in speed. +The +position and velocity of the Moon with respect to the +Earth's centre for the mean equator and ecliptic of date +can be obtained by calling +sla\_MOON. +The positional accuracy is better than \arcseci{30} in direction +and 1000~km in distance. + +Approximate ephemerides for all the major planets +can be generated by calling +sla\_PLANET +or +sla\_RDPLAN. These routines offer arcminute accuracy (much +better for the inner planets and for Pluto) over a span of several +millennia (but only $\pm100$ years for Pluto). +The routine +sla\_PLANET produces heliocentric position and +velocity in the form of equatorial \xyzxyzd\ for the +mean equator and equinox of J2000. The vectors +produced by +sla\_PLANET +can be used in a variety of ways according to the +requirements of the application concerned. The routine +sla\_RDPLAN +uses +sla\_PLANET +and +sla\_DMOON +to deal with the common case of predicting +a planet's apparent \radec\ and angular size as seen by a +terrestrial observer. + +Note that in predicting the position in the sky of a solar-system body +it is necessary to allow for geocentric parallax. This correction +is {\it essential}\/ in the case of the Moon, where the observer's +position on the Earth can affect the Moon's \radec\ by up to +$1^\circ$. The calculation can most conveniently be done by calling +sla\_PVOBS and subtracting the resulting 6-vector from the +one produced by +sla\_DMOON, as is demonstrated by the following example: +\goodbreak +\begin{verbatim} + * Demonstrate the size of the geocentric parallax correction + * in the case of the Moon. The test example is for the AAT, + * before midnight, in summer, near first quarter. + + IMPLICIT NONE + CHARACTER NAME*40,SH,SD + INTEGER J,I,IHMSF(4),IDMSF(4) + DOUBLE PRECISION SLONGW,SLAT,H,DJUTC,FDUTC,DJUT1,DJTT,STL, + : RMATN(3,3),PMM(6),PMT(6),RM,DM,PVO(6),TL + DOUBLE PRECISION sla_DTT,sla_GMST,sla_EQEQX,sla_DRANRM + + * Get AAT longitude and latitude in radians and height in metres + CALL sla_OBS(0,'AAT',NAME,SLONGW,SLAT,H) + + * UTC (1992 January 13, 11 13 59) to MJD + CALL sla_CLDJ(1992,1,13,DJUTC,J) + CALL sla_DTF2D(11,13,59.0D0,FDUTC,J) + DJUTC=DJUTC+FDUTC + + * UT1 (UT1-UTC value of -0.152 sec is from IERS Bulletin B) + DJUT1=DJUTC+(-0.152D0)/86400D0 + + * TT + DJTT=DJUTC+sla_DTT(DJUTC)/86400D0 + + * Local apparent sidereal time + STL=sla_GMST(DJUT1)-SLONGW+sla_EQEQX(DJTT) + + * Geocentric position/velocity of Moon (mean of date) + CALL sla_DMOON(DJTT,PMM) + + * Nutation to true equinox of date + CALL sla_NUT(DJTT,RMATN) + CALL sla_DMXV(RMATN,PMM,PMT) + CALL sla_DMXV(RMATN,PMM(4),PMT(4)) + + * Report geocentric HA,Dec + CALL sla_DCC2S(PMT,RM,DM) + CALL sla_DR2TF(2,sla_DRANRM(STL-RM),SH,IHMSF) + CALL sla_DR2AF(1,DM,SD,IDMSF) + WRITE (*,'(1X,'' geocentric:'',2X,A,I2.2,2I3.2,''.'',I2.2,'// + : '1X,A,I2.2,2I3.2,''.'',I1)') + : SH,IHMSF,SD,IDMSF + + * Geocentric position of observer (true equator and equinox of date) + CALL sla_PVOBS(SLAT,H,STL,PVO) + + * Place origin at observer + DO I=1,6 + PMT(I)=PMT(I)-PVO(I) + END DO + + * Allow for planetary aberration + TL=499.004782D0*SQRT(PMT(1)**2+PMT(2)**2+PMT(3)**2) + DO I=1,3 + PMT(I)=PMT(I)-TL*PMT(I+3) + END DO + + * Report topocentric HA,Dec + CALL sla_DCC2S(PMT,RM,DM) + CALL sla_DR2TF(2,sla_DRANRM(STL-RM),SH,IHMSF) + CALL sla_DR2AF(1,DM,SD,IDMSF) + WRITE (*,'(1X,''topocentric:'',2X,A,I2.2,2I3.2,''.'',I2.2,'// + : '1X,A,I2.2,2I3.2,''.'',I1)') + : SH,IHMSF,SD,IDMSF + END +\end{verbatim} +\goodbreak +The output produced is as follows: +\goodbreak +\begin{verbatim} + geocentric: +03 06 55.59 +15 03 39.0 + topocentric: +03 09 23.79 +15 40 51.5 +\end{verbatim} +\goodbreak +(An easier but +less instructive method of estimating the topocentric apparent place of the +Moon is to call the routine +sla\_RDPLAN.) + +As an example of using +sla\_PLANET, +the following program estimates the geocentric separation +between Venus and Jupiter during a close conjunction +in 2\,BC, which is a star-of-Bethlehem candidate: +\goodbreak +\begin{verbatim} + * Compute time and minimum geocentric apparent separation + * between Venus and Jupiter during the close conjunction of 2 BC. + + IMPLICIT NONE + + DOUBLE PRECISION SEPMIN,DJD0,FD,DJD,DJDM,DF,PV(6),RMATP(3,3), + : PVM(6),PVE(6),TL,RV,DV,RJ,DJ,SEP + INTEGER IHOUR,IMIN,J,I,IHMIN,IMMIN + DOUBLE PRECISION sla_EPJ,sla_DSEP + + + * Search for closest approach on the given day + DJD0=1720859.5D0 + SEPMIN=1D10 + DO IHOUR=20,22 + DO IMIN=0,59 + CALL sla_DTF2D(IHOUR,IMIN,0D0,FD,J) + + * Julian date and MJD + DJD=DJD0+FD + DJDM=DJD-2400000.5D0 + + * Earth to Moon (mean of date) + CALL sla_DMOON(DJDM,PV) + + * Precess Moon position to J2000 + CALL sla_PRECL(sla_EPJ(DJDM),2000D0,RMATP) + CALL sla_DMXV(RMATP,PV,PVM) + + * Sun to Earth-Moon Barycentre (mean J2000) + CALL sla_PLANET(DJDM,3,PVE,J) + + * Correct from EMB to Earth + DO I=1,3 + PV(I)=PVE(I)-0.012150581D0*PVM(I) + END DO + + * Sun to Venus + CALL sla_PLANET(DJDM,2,PV,J) + + * Earth to Venus + DO I=1,6 + PV(I)=PV(I)-PVE(I) + END DO + + * Light time to Venus (sec) + TL=499.004782D0*SQRT((PV(1)-PVE(1))**2+ + : (PV(2)-PVE(2))**2+ + : (PV(3)-PVE(3))**2) + + * Extrapolate backwards in time by that much + DO I=1,3 + PV(I)=PV(I)-TL*PV(I+3) + END DO + + * To RA,Dec + CALL sla_DCC2S(PV,RV,DV) + + * Same for Jupiter + CALL sla_PLANET(DJDM,5,PV,J) + DO I=1,6 + PV(I)=PV(I)-PVE(I) + END DO + TL=499.004782D0*SQRT((PV(1)-PVE(1))**2+ + : (PV(2)-PVE(2))**2+ + : (PV(3)-PVE(3))**2) + DO I=1,3 + PV(I)=PV(I)-TL*PV(I+3) + END DO + CALL sla_DCC2S(PV,RJ,DJ) + + * Separation (arcsec) + SEP=sla_DSEP(RV,DV,RJ,DJ) + + * Keep if smallest so far + IF (SEP.LT.SEPMIN) THEN + IHMIN=IHOUR + IMMIN=IMIN + SEPMIN=SEP + END IF + END DO + END DO + + * Report + WRITE (*,'(1X,I2.2,'':'',I2.2,F6.1)') IHMIN,IMMIN, + : 206264.8062D0*SEPMIN + + END +\end{verbatim} +\goodbreak +The output produced (the Ephemeris Time on the day in question, and +the closest approach in arcseconds) is as follows: +\goodbreak +\begin{verbatim} + 21:19 33.7 +\end{verbatim} +\goodbreak +For comparison, accurate predictions based on the JPL DE\,102 ephemeris +give a separation about \arcseci{8} less than +the above estimate, occurring about half an hour earlier +(see {\it Sky and Telescope,}\/ April~1987, p\,357). + +The following program demonstrates +sla\_RDPLAN. +\begin{verbatim} + * For a given date, time and geographical location, output + * a table of planetary positions and diameters. + + IMPLICIT NONE + CHARACTER PNAMES(0:9)*7,B*80,S + INTEGER I,NP,IY,J,IM,ID,IHMSF(4),IDMSF(4) + DOUBLE PRECISION R2AS,FD,DJM,ELONG,PHI,RA,DEC,DIAM + PARAMETER (R2AS=206264.80625D0) + DATA PNAMES / 'Sun','Mercury','Venus','Moon','Mars','Jupiter', + : 'Saturn','Uranus','Neptune', 'Pluto' / + + + * Loop until 'end' typed + B=' ' + DO WHILE (B.NE.'END'.AND.B.NE.'end') + + * Get date, time and observer's location + PRINT *,'Date? (Y,M,D, Gregorian)' + READ (*,'(A)') B + IF (B.NE.'END'.AND.B.NE.'end') THEN + I=1 + CALL sla_INTIN(B,I,IY,J) + CALL sla_INTIN(B,I,IM,J) + CALL sla_INTIN(B,I,ID,J) + PRINT *,'Time? (H,M,S, dynamical)' + READ (*,'(A)') B + I=1 + CALL sla_DAFIN(B,I,FD,J) + FD=FD*2.3873241463784300365D0 + CALL sla_CLDJ(IY,IM,ID,DJM,J) + DJM=DJM+FD + PRINT *,'Longitude? (D,M,S, east +ve)' + READ (*,'(A)') B + I=1 + CALL sla_DAFIN(B,I,ELONG,J) + PRINT *,'Latitude? (D,M,S, (geodetic)' + READ (*,'(A)') B + I=1 + CALL sla_DAFIN(B,I,PHI,J) + + * Loop planet by planet + DO NP=0,8 + + * Get RA,Dec and diameter + CALL sla_RDPLAN(DJM,NP,ELONG,PHI,RA,DEC,DIAM) + + * One line of report + CALL sla_DR2TF(2,RA,S,IHMSF) + CALL sla_DR2AF(1,DEC,S,IDMSF) + WRITE (*, + : '(1X,A,2X,3I3.2,''.'',I2.2,2X,A,I2.2,2I3.2,''.'',I1,F8.1)') + : PNAMES(NP),IHMSF,S,IDMSF,R2AS*DIAM + + * Next planet + END DO + PRINT *,' ' + END IF + + * Next case + END DO + + END +\end{verbatim} +Entering the following data (for 1927~June~29 at $5^{\rm h}\,25^{\rm m}$~ET +and the position of Preston, UK.): +\begin{verbatim} + 1927 6 29 + 5 25 + -2 42 + 53 46 +\end{verbatim} +produces the following report: +\begin{verbatim} + Sun 06 28 14.03 +23 17 17.5 1887.8 + Mercury 08 08 58.62 +19 20 57.3 9.3 + Venus 09 38 53.64 +15 35 32.9 22.8 + Moon 06 28 18.30 +23 18 37.3 1903.9 + Mars 09 06 49.34 +17 52 26.7 4.0 + Jupiter 00 11 12.06 -00 10 57.5 41.1 + Saturn 16 01 43.34 -18 36 55.9 18.2 + Uranus 00 13 33.53 +00 39 36.0 3.5 + Neptune 09 49 35.75 +13 38 40.8 2.2 + Pluto 07 05 29.50 +21 25 04.2 .1 +\end{verbatim} +Inspection of the Sun and Moon data reveals that +a total solar eclipse is in progress. + +SLALIB also provides for the case where orbital elements (with respect +to the J2000 equinox and ecliptic) +are available. This allows predictions to be made for minor-planets and +(if you ignore non-gravitational effects) +comets. Furthermore, if major-planet elements for an epoch close to the date +in question are available, more accurate predictions can be made than +are offered by +sla\_RDPLAN and +sla\_PLANET. + +The SLALIB planetary-prediction +routines that work with orbital elements are +sla\_PLANTE (the orbital-elements equivalent of +sla\_RDPLAN), which predicts the topocentric \radec, and +sla\_PLANEL (the orbital-elements equivalent of +sla\_PLANET), which predicts the heliocentric \xyzxyzd\ with respect to the +J2000 equinox and equator. In addition, the routine +sla\_PV2EL does the inverse of +sla\_PLANEL, transforming \xyzxyzd\ into {\it osculating elements.} + +Osculating elements describe the unperturbed 2-body orbit. This is +a good approximation to the actual orbit for a few weeks either +side of the specified epoch, outside which perturbations due to +the other bodies of the Solar System lead to +increasing errors. Given a minor planet's osculating elements for +a particular date, predictions for a date even just +100 days earlier or later +are likely to be in error by several arcseconds. +These errors can +be reduced if new elements are generated which take account of +the perturbations of the major planets, and this is what the routine +sla\_PERTEL does. Once +sla\_PERTEL has been called, to provide osculating elements +close to the required date, the elements can be passed to +sla\_PLANEL or +sla\_PLANTE in the normal way. Predictions of arcsecond accuracy +over a span of a decade or more are available using this +technique. + +Three different combinations of orbital elements are +provided for, matching the usual conventions +for major planets, minor planets and +comets respectively. The choice is made through the +argument {\tt JFORM}:\\ + +\hspace{4em} +\begin{tabular}{|c|c|c|} \hline +{\tt JFORM=1} & {\tt JFORM=2} & {\tt JFORM=3} \\ +\hline \hline +$t_0$ & $t_0$ & $T$ \\ +\hline +$i$ & $i$ & $i$ \\ +\hline +$\Omega$ & $\Omega$ & $\Omega$ \\ +\hline +$\varpi$ & $\omega$ & $\omega$ \\ +\hline +$a$ & $a$ & $q$ \\ +\hline +$e$ & $e$ & $e$ \\ +\hline +$L$ & $M$ & \\ +\hline +$n$ & & \\ +\hline +\end{tabular}\\[5ex] +The symbols have the following meanings: +\begin{tabbing} +xxxxxxx \= xxxx \= \kill +\> $t_0$ \> epoch at which the elements were correct \\ +\> $T$ \> epoch of perihelion passage \\ +\> $i$ \> inclination of the orbit \\ +\> $\Omega$ \> longitude of the ascending node \\ +\> $\varpi$ \> longitude of perihelion ($\varpi = \Omega + \omega$) \\ +\> $\omega$ \> argument of perihelion \\ +\> $a$ \> semi-major axis of the orbital ellipse \\ +\> $q$ \> perihelion distance \\ +\> $e$ \> orbital eccentricity \\ +\> $L$ \> mean longitude ($L = \varpi + M$) \\ +\> $M$ \> mean anomaly \\ +\> $n$ \> mean motion \\ +\end{tabbing} + +The mean motion, $n$, tells sla\_PLANEL the mass of the planet. +If it is not available, it should be claculated +from $n^2 a^3 = k^2 (1+m)$, where $k = 0.01720209895$ and +m is the mass of the planet ($M_\odot = 1$); $a$ is in AU. + +Conventional elements are not the only way of specifying an orbit. +The \xyzxyzd\ state vector is an equally valid specification, +and the so-called {\it method of universal variables}\/ allows +orbital calculations to be made directly, bypassing angular +quantities and avoiding Kepler's Equation. The universal-variables +approach has various advantages, including better handling of +near-parabolic cases and greater efficiency. +SLALIB uses universal variables for its internal +calculations and also offers a number of routines which +applications can call. + +The universal elements are the \xyzxyzd\ and its epoch, plus the mass +of the body. The SLALIB routines supplement these elements with +certain redundant values in order to +avoid unnecessary recomputation when the elements are next used. + +The routines +sla\_EL2UE and +sla\_UE2EL transform conventional elements into the +universal form and {\it vice versa.} +The routine +sla\_PV2UE takes an \xyzxyzd\ and forms the set of universal +elements; +sla\_UE2PV takes a set of universal elements and predicts the \xyzxyzd\ +for a specified epoch. +The routine +sla\_PERTUE provides updated universal elements, +taking into account perturbations from the major planets. + +\subsection{Radial Velocity and Light-Time Corrections} +When publishing high-resolution spectral observations +it is necessary to refer them to a specified standard of rest. +This involves knowing the component in the direction of the +source of the velocity of the observer. SLALIB provides a number +of routines for this purpose, allowing observations to be +referred to the Earth's centre, the Sun, a Local Standard of Rest +(either dynamical or kinematical), the centre of the Galaxy, and +the mean motion of the Local Group. + +The routine +sla\_RVEROT +corrects for the diurnal rotation of +the observer around the Earth's axis. This is always less than 0.5~km/s. + +No specific routine is provided to correct a radial velocity +from geocentric to heliocentric, but this can easily be done by calling +sla\_EVP +as follows (array declarations {\it etc}.\ omitted): +\goodbreak +\begin{verbatim} + : + * Star vector, J2000 + CALL sla_DCS2C(RM,DM,V) + + * Earth/Sun velocity and position, J2000 + CALL sla_EVP(TDB,2000D0,DVB,DPB,DVH,DPH) + + * Radial velocity correction due to Earth orbit (km/s) + VCORB = -sla_DVDV(V,DVH)*149.597870D6 + : +\end{verbatim} +\goodbreak +The maximum value of this correction is the Earth's orbital speed +of about 30~km/s. A related routine, +sla\_ECOR, +computes the light-time correction with respect to the Sun. It +would be used when reducing observations of a rapid variable-star +for instance. +Note, however, that the accuracy objectives for pulsar work are +beyond the scope of these SLALIB routines, and even the superior +sla\_EVP +routine is unsuitable for arrival-time calculations of better +than 25~millisecond accuracy. + +To remove the intrinsic $\sim20$~km/s motion of the Sun relative +to other stars in the solar neighbourhood, +a velocity correction to a +{\it local standard of rest}\/ (LSR) is required. There are +opportunities for mistakes here. There are two sorts of LSR, +{\it dynamical}\/ and {\it kinematical}, and +multiple definitions exist for the latter. The +dynamical LSR is a point near the Sun which is in a circular +orbit around the Galactic centre; the Sun has a ``peculiar'' +motion relative to the dynamical LSR. A kinematical LSR is +the mean standard of rest of specified star catalogues or stellar +populations, and its precise definition depends on which +catalogues or populations were used and how the analysis was +carried out. The Sun's motion with respect to a kinematical +LSR is called the ``standard'' solar motion. Radial +velocity corrections to the dynamical LSR are produced by the routine +sla\_RVLSRD +and to the adopted kinematical LSR by +sla\_RVLSRK. +See the individual specifications for these routines for the +precise definition of the LSR in each case. + +For extragalactic sources, the centre of the Galaxy can be used as +a standard of rest. The radial velocity correction from the +dynamical LSR to the Galactic centre can be obtained by calling +sla\_RVGALC. +Its maximum value is 220~km/s. + +For very distant sources it is appropriate to work relative +to the mean motion of the Local Group. The routine for +computing the radial velocity correction in this case is +sla\_RVLG. +Note that in this case the correction is with respect to the +dynamical LSR, not the Galactic centre as might be expected. +This conforms to the IAU definition, and confers immunity from +revisions of the Galactic rotation speed. + +\subsection{Focal-Plane Astrometry} +The relationship between the position of a star image in +the focal plane of a telescope and the star's celestial +coordinates is usually described in terms of the {\it tangent plane}\/ +or {\it gnomonic}\/ projection. This is the projection produced +by a pin-hole camera and is a good approximation to the projection +geometry of a traditional large {\it f}\/-ratio astrographic refractor. +SLALIB includes a group of routines which transform +star positions between their observed places on the celestial +sphere and their \xy\ coordinates in the tangent plane. The +spherical coordinate system does not have to be \radec\ but +usually is. The so-called {\it standard coordinates}\/ of a star +are the tangent plane \xy, in radians, with respect to an origin +at the tangent point, with the $y$-axis pointing north and +the $x$-axis pointing east (in the direction of increasing $\alpha$). +The factor relating the standard coordinates to +the actual \xy\ coordinates in, say, millimetres is simply +the focal length of the telescope. + +Given the \radec\ of the {\it plate centre}\/ (the tangent point) +and the \radec\ of a star within the field, the standard +coordinates can be determined by calling +sla\_S2TP +(single precision) or +sla\_DS2TP +(double precision). The reverse transformation, where the +\xy\ is known and we wish to find the \radec, is carried out by calling +sla\_TP2S +or +sla\_DTP2S. +Occasionally we know the both the \xy\ and the \radec\ of a +star and need to deduce the \radec\ of the tangent point; +this can be done by calling +sla\_TPS2C +or +sla\_DTPS2C. +(All of these transformations apply not just to \radec\ but to +other spherical coordinate systems, of course.) +Equivalent (and faster) +routines are provided which work directly in \xyz\ instead of +spherical coordinates: +sla\_V2TP and +sla\_DV2TP, +sla\_TP2V and +sla\_DTP2V, +sla\_TPV2C and +sla\_DTPV2C. + +Even at the best of times, the tangent plane projection is merely an +approximation. Some telescopes and cameras exhibit considerable pincushion +or barrel distortion and some have a curved focal surface. +For example, neither Schmidt cameras nor (especially) +large reflecting telescopes with wide-field corrector lenses +are adequately modelled by tangent-plane geometry. In such +cases, however, it is still possible to do most of the work +using the (mathematically convenient) tangent-plane +projection by inserting an extra step which applies or +removes the distortion peculiar to the system concerned. +A simple $r_1=r_0(1+Kr_0^2)$ law works well in the +majority of cases; $r_0$ is the radial distance in the +tangent plane, $r_1$ is the radial distance after adding +the distortion, and $K$ is a constant which depends on the +telescope ($\theta$ is unaffected). The routine +sla\_PCD +applies the distortion to an \xy\ and +sla\_UNPCD +removes it. For \xy\ in radians, $K$ values range from $-1/3$ for the +tiny amount of barrel distortion in Schmidt geometry to several +hundred for the serious pincushion distortion +produced by wide-field correctors in big reflecting telescopes +(the AAT prime focus triplet corrector is about $K=+178.6$). + +SLALIB includes a group of routines which can be put together +to build a simple plate-reduction program. The heart of the group is +sla\_FITXY, +which fits a linear model to relate two sets of \xy\ coordinates, +in the case of a plate reduction the measured positions of the +images of a set of +reference stars and the standard +coordinates derived from their catalogue positions. The +model is of the form: +\[x_{p} = a + bx_{m} + cy_{m}\] +\[y_{p} = d + ex_{m} + fy_{m}\] + +where the {\it p}\/ subscript indicates ``predicted'' coordinates +(the model's approximation to the ideal ``expected'' coordinates) and the +{\it m}\/ subscript indicates ``measured coordinates''. The +six coefficients {\it a--f}\/ can optionally be +constrained to represent a ``solid body rotation'' free of +any squash or shear distortions. Without this constraint +the model can, to some extent, accommodate effects like refraction, +allowing mean places to be used directly and +avoiding the extra complications of a +full mean-apparent-observed transformation for each star. +Having obtained the linear model, +sla\_PXY +can be used to process the set of measured and expected +coordinates, giving the predicted coordinates and determining +the RMS residuals in {\it x}\/ and {\it y}. +The routine +sla\_XY2XY +transforms one \xy\ into another using the linear model. A model +can be inverted by calling +sla\_INVF, +and decomposed into zero points, scales, $x/y$ nonperpendicularity +and orientation by calling +sla\_DCMPF. + +\subsection{Numerical Methods} +SLALIB contains a small number of simple, general-purpose +numerical-methods routines. They have no specific +connection with positional astronomy but have proved useful in +applications to do with simulation and fitting. + +At the heart of many simulation programs is the generation of +pseudo-random numbers, evenly distributed in a given range: +sla\_RANDOM +does this. Pseudo-random normal deviates, or ``Gaussian +residuals'', are often required to simulate noise and +can be generated by means of the function +sla\_GRESID. +Neither routine will pass super-sophisticated +statistical tests, but they work adequately for most +practical purposes and avoid the need to call non-standard +library routines peculiar to one sort of computer. + +Applications which perform a least-squares fit using a traditional +normal-equations methods can accomplish the required matrix-inversion +by calling either +sla\_SMAT +(single precision) or +sla\_DMAT +(double). A generally better way to perform such fits is +to use singular value decomposition. SLALIB provides a routine +to do the decomposition itself, +sla\_SVD, +and two routines to use the results: +sla\_SVDSOL +generates the solution, and +sla\_SVDCOV +produces the covariance matrix. +A simple demonstration of the use of the SLALIB SVD +routines is given below. It generates 500 simulated data +points and fits them to a model which has 4 unknown coefficients. +(The arrays in the example are sized to accept up to 1000 +points and 20 unknowns.) The model is: +\[ y = C_{1} +C_{2}x +C_{3}sin{x} +C_{4}cos{x} \] +The test values for the four coefficients are +$C_1\!=\!+50.0$, +$C_2\!=\!-2.0$, +$C_3\!=\!-10.0$ and +$C_4\!=\!+25.0$. +Gaussian noise, $\sigma=5.0$, is added to each ``observation''. +\goodbreak +\begin{verbatim} + IMPLICIT NONE + + * Sizes of arrays, physical and logical + INTEGER MP,NP,NC,M,N + PARAMETER (MP=1000,NP=10,NC=20,M=500,N=4) + + * The unknowns we are going to solve for + DOUBLE PRECISION C1,C2,C3,C4 + PARAMETER (C1=50D0,C2=-2D0,C3=-10D0,C4=25D0) + + * Arrays + DOUBLE PRECISION A(MP,NP),W(NP),V(NP,NP), + : WORK(NP),B(MP),X(NP),CVM(NC,NC) + + DOUBLE PRECISION VAL,BF1,BF2,BF3,BF4,SD2,D,VAR + REAL sla_GRESID + INTEGER I,J + + * Fill the design matrix + DO I=1,M + + * Dummy independent variable + VAL=DBLE(I)/10D0 + + * The basis functions + BF1=1D0 + BF2=VAL + BF3=SIN(VAL) + BF4=COS(VAL) + + * The observed value, including deliberate Gaussian noise + B(I)=C1*BF1+C2*BF2+C3*BF3+C4*BF4+DBLE(sla_GRESID(5.0)) + + * Fill one row of the design matrix + A(I,1)=BF1 + A(I,2)=BF2 + A(I,3)=BF3 + A(I,4)=BF4 + END DO + + * Factorize the design matrix, solve and generate covariance matrix + CALL sla_SVD(M,N,MP,NP,A,W,V,WORK,J) + CALL sla_SVDSOL(M,N,MP,NP,B,A,W,V,WORK,X) + CALL sla_SVDCOV(N,NP,NC,W,V,WORK,CVM) + + * Compute the variance + SD2=0D0 + DO I=1,M + VAL=DBLE(I)/10D0 + BF1=1D0 + BF2=VAL + BF3=SIN(VAL) + BF4=COS(VAL) + D=B(I)-(X(1)*BF1+X(2)*BF2+X(3)*BF3+X(4)*BF4) + SD2=SD2+D*D + END DO + VAR=SD2/DBLE(M) + + * Report the RMS and the solution + WRITE (*,'(1X,''RMS ='',F5.2/)') SQRT(VAR) + DO I=1,N + WRITE (*,'(1X,''C'',I1,'' ='',F7.3,'' +/-'',F6.3)') + : I,X(I),SQRT(VAR*CVM(I,I)) + END DO + END +\end{verbatim} +\goodbreak +The program produces the following output: +\goodbreak +\begin{verbatim} + RMS = 4.88 + + C1 = 50.192 +/- 0.439 + C2 = -2.002 +/- 0.015 + C3 = -9.771 +/- 0.310 + C4 = 25.275 +/- 0.310 +\end{verbatim} +\goodbreak +In this above example, essentially +identical results would be obtained if the more +commonplace normal-equations method had been used, and the large +$1000\times20$ array would have been avoided. However, the SVD method +comes into its own when the opportunity is taken to edit the W-matrix +(the so-called ``singular values'') in order to control +possible ill-conditioning. The procedure involves replacing with +zeroes any W-elements smaller than a nominated value, for example +0.001 times the largest W-element. Small W-elements indicate +ill-conditioning, which in the case of the normal-equations +method would produce spurious large coefficient values and +possible arithmetic overflows. Using SVD, the effect on the solution +of setting suspiciously small W-elements to zero is to restrain +the offending coefficients from moving very far. The +fact that action was taken can be reported to show the program user that +something is amiss. Furthermore, if element W(J) was set to zero, +the row numbers of the two biggest elements in the Jth column of the +V-matrix identify the pair of solution coefficients that are +dependent. + +A more detailed description of SVD and its use in least-squares +problems would be out of place here, and the reader is urged +to refer to the relevant sections of the book {\it Numerical Recipes} +(Press {\it et al.}, Cambridge University Press, 1987). + +The routines +sla\_COMBN +and +sla\_PERMUT +are useful for problems which involve combinations (different subsets) +and permutations (different orders). +Both return the next in a sequence of results, cycling through all the +possible results as the routine is called repeatedly. + +\pagebreak + +\section{SUMMARY OF CALLS} +The basic trigonometrical and numerical facilities are supplied in both single +and double precision versions. +Most of the more esoteric position and time routines use double precision +arguments only, even in cases where single precision would normally be adequate +in practice. +Certain routines with modest accuracy objectives are supplied in +single precision versions only. +In the calling sequences which follow, no attempt has been made +to distinguish between single and double precision argument names, +and frequently the same name is used on different occasions to +mean different things. +However, none of the routines uses a mixture of single and +double precision arguments; each routine is either wholly +single precision or wholly double precision. + +In the classified list, below, +{\it subroutine}\/ subprograms are those whose names and argument lists +are preceded by `CALL', whereas {\it function}\/ subprograms are +those beginning `R=' (when the result is REAL) or `D=' (when +the result is DOUBLE~PRECISION). + +The list is, of course, merely for quick reference; inexperienced +users {\bf must} refer to the detailed specifications given later. +In particular, {\bf don't guess} whether arguments are single or +double precision; the result could be a program that happens to +works on one sort of machine but not on another. + +\callhead{String Decoding} +\begin{callset} +\subp{CALL sla\_INTIN (STRING, NSTRT, IRESLT, JFLAG)} + Convert free-format string into integer +\subq{CALL sla\_FLOTIN (STRING, NSTRT, RESLT, JFLAG)} + {CALL sla\_DFLTIN (STRING, NSTRT, DRESLT, JFLAG)} + Convert free-format string into floating-point number +\subq{CALL sla\_AFIN (STRING, NSTRT, RESLT, JFLAG)} + {CALL sla\_DAFIN (STRING, NSTRT, DRESLT, JFLAG)} + Convert free-format string from deg,arcmin,arcsec to radians +\end{callset} + +\callhead{Sexagesimal Conversions} +\begin{callset} +\subq{CALL sla\_CTF2D (IHOUR, IMIN, SEC, DAYS, J)} + {CALL sla\_DTF2D (IHOUR, IMIN, SEC, DAYS, J)} + Hours, minutes, seconds to days +\subq{CALL sla\_CD2TF (NDP, DAYS, SIGN, IHMSF)} + {CALL sla\_DD2TF (NDP, DAYS, SIGN, IHMSF)} + Days to hours, minutes, seconds +\subq{CALL sla\_CTF2R (IHOUR, IMIN, SEC, RAD, J)} + {CALL sla\_DTF2R (IHOUR, IMIN, SEC, RAD, J)} + Hours, minutes, seconds to radians +\subq{CALL sla\_CR2TF (NDP, ANGLE, SIGN, IHMSF)} + {CALL sla\_DR2TF (NDP, ANGLE, SIGN, IHMSF)} + Radians to hours, minutes, seconds +\subq{CALL sla\_CAF2R (IDEG, IAMIN, ASEC, RAD, J)} + {CALL sla\_DAF2R (IDEG, IAMIN, ASEC, RAD, J)} + Degrees, arcminutes, arcseconds to radians +\subq{CALL sla\_CR2AF (NDP, ANGLE, SIGN, IDMSF)} + {CALL sla\_DR2AF (NDP, ANGLE, SIGN, IDMSF)} + Radians to degrees, arcminutes, arcseconds +\end{callset} + +\callhead{Angles, Vectors and Rotation Matrices} +\begin{callset} +\subq{R~=~sla\_RANGE (ANGLE)} + {D~=~sla\_DRANGE (ANGLE)} + Normalize angle into range $\pm\pi$ +\subq{R~=~sla\_RANORM (ANGLE)} + {D~=~sla\_DRANRM (ANGLE)} + Normalize angle into range $0\!-\!2\pi$ +\subq{CALL sla\_CS2C (A, B, V)} + {CALL sla\_DCS2C (A, B, V)} + Spherical coordinates to \xyz +\subq{CALL sla\_CC2S (V, A, B)} + {CALL sla\_DCC2S (V, A, B)} + \xyz\ to spherical coordinates +\subq{R~=~sla\_VDV (VA, VB)} + {D~=~sla\_DVDV (VA, VB)} + Scalar product of two 3-vectors +\subq{CALL sla\_VXV (VA, VB, VC)} + {CALL sla\_DVXV (VA, VB, VC)} + Vector product of two 3-vectors +\subq{CALL sla\_VN (V, UV, VM)} + {CALL sla\_DVN (V, UV, VM)} + Normalize a 3-vector also giving the modulus +\subq{R~=~sla\_SEP (A1, B1, A2, B2)} + {D~=~sla\_DSEP (A1, B1, A2, B2)} + Angle between two points on a sphere +\subq{R~=~sla\_BEAR (A1, B1, A2, B2)} + {D~=~sla\_DBEAR (A1, B1, A2, B2)} + Direction of one point on a sphere seen from another +\subq{R~=~sla\_PAV (V1, V2)} + {D~=~sla\_DPAV (V1, V2)} + Position-angle of one \xyz\ with respect to another +\subq{CALL sla\_EULER (ORDER, PHI, THETA, PSI, RMAT)} + {CALL sla\_DEULER (ORDER, PHI, THETA, PSI, RMAT)} + Form rotation matrix from three Euler angles +\subq{CALL sla\_AV2M (AXVEC, RMAT)} + {CALL sla\_DAV2M (AXVEC, RMAT)} + Form rotation matrix from axial vector +\subq{CALL sla\_M2AV (RMAT, AXVEC)} + {CALL sla\_DM2AV (RMAT, AXVEC)} + Determine axial vector from rotation matrix +\subq{CALL sla\_MXV (RM, VA, VB)} + {CALL sla\_DMXV (DM, VA, VB)} + Rotate vector forwards +\subq{CALL sla\_IMXV (RM, VA, VB)} + {CALL sla\_DIMXV (DM, VA, VB)} + Rotate vector backwards +\subq{CALL sla\_MXM (A, B, C)} + {CALL sla\_DMXM (A, B, C)} + Product of two 3x3 matrices +\subq{CALL sla\_CS2C6 (A, B, R, AD, BD, RD, V)} + {CALL sla\_DS2C6 (A, B, R, AD, BD, RD, V)} + Conversion of position and velocity in spherical + coordinates to Cartesian coordinates +\subq{CALL sla\_CC62S (V, A, B, R, AD, BD, RD)} + {CALL sla\_DC62S (V, A, B, R, AD, BD, RD)} + Conversion of position and velocity in Cartesian + coordinates to spherical coordinates +\end{callset} + +\callhead{Calendars} +\begin{callset} +\subp{CALL sla\_CLDJ (IY, IM, ID, DJM, J)} + Gregorian Calendar to Modified Julian Date +\subp{CALL sla\_CALDJ (IY, IM, ID, DJM, J)} + Gregorian Calendar to Modified Julian Date, + permitting century default +\subp{CALL sla\_DJCAL (NDP, DJM, IYMDF, J)} + Modified Julian Date to Gregorian Calendar, + in a form convenient for formatted output +\subp{CALL sla\_DJCL (DJM, IY, IM, ID, FD, J)} + Modified Julian Date to Gregorian Year, Month, Day, Fraction +\subp{CALL sla\_CALYD (IY, IM, ID, NY, ND, J)} + Calendar to year and day in year, permitting century default +\subp{CALL sla\_CLYD (IY, IM, ID, NY, ND, J)} + Calendar to year and day in year +\subp{D~=~sla\_EPB (DATE)} + Modified Julian Date to Besselian Epoch +\subp{D~=~sla\_EPB2D (EPB)} + Besselian Epoch to Modified Julian Date +\subp{D~=~sla\_EPJ (DATE)} + Modified Julian Date to Julian Epoch +\subp{D~=~sla\_EPJ2D (EPJ)} + Julian Epoch to Modified Julian Date +\end{callset} + +\callhead{Timescales} +\begin{callset} +\subp{D~=~sla\_GMST (UT1)} + Conversion from Universal Time to sidereal time +\subp{D~=~sla\_GMSTA (DATE, UT1)} + Conversion from Universal Time to sidereal time, rounding errors minimized +\subp{D~=~sla\_EQEQX (DATE)} + Equation of the equinoxes +\subp{D~=~sla\_DAT (DJU)} + Offset of Atomic Time from Coordinated Universal Time: TAI$-$UTC +\subp{D~=~sla\_DT (EPOCH)} + Approximate offset between dynamical time and universal time +\subp{D~=~sla\_DTT (DJU)} + Offset of Terrestrial Time from Coordinated Universal Time: TT$-$UTC +\subp{D~=~sla\_RCC (TDB, UT1, WL, U, V)} + Relativistic clock correction: TDB$-$TT +\end{callset} + +\callhead{Precession and Nutation} +\begin{callset} +\subp{CALL sla\_NUT (DATE, RMATN)} + Nutation matrix +\subp{CALL sla\_NUTC (DATE, DPSI, DEPS, EPS0)} + Longitude and obliquity components of nutation, and + mean obliquity +\subp{CALL sla\_PREC (EP0, EP1, RMATP)} + Precession matrix (IAU) +\subp{CALL sla\_PRECL (EP0, EP1, RMATP)} + Precession matrix (suitable for long periods) +\subp{CALL sla\_PRENUT (EPOCH, DATE, RMATPN)} + Combined precession/nutation matrix +\subp{CALL sla\_PREBN (BEP0, BEP1, RMATP)} + Precession matrix, old system +\subp{CALL sla\_PRECES (SYSTEM, EP0, EP1, RA, DC)} + Precession, in either the old or the new system +\end{callset} + +\callhead{Proper Motion} +\begin{callset} +\subp{CALL sla\_PM (R0, D0, PR, PD, PX, RV, EP0, EP1, R1, D1)} + Adjust for proper motion +\end{callset} + +\callhead{FK4/FK5/Hipparcos Conversions} +\begin{callset} +\subp{CALL sla\_FK425 (\vtop + {\hbox{R1950, D1950, DR1950, DD1950, P1950, V1950,} + \hbox{R2000, D2000, DR2000, DD2000, P2000, V2000)}}} + Convert B1950.0 FK4 star data to J2000.0 FK5 +\subp{CALL sla\_FK45Z (R1950, D1950, EPOCH, R2000, D2000)} + Convert B1950.0 FK4 position to J2000.0 FK5 assuming zero + FK5 proper motion and no parallax +\subp{CALL sla\_FK524 (\vtop + {\hbox{R2000, D2000, DR2000, DD2000, P2000, V2000,} + \hbox{R1950, D1950, DR1950, DD1950, P1950, V1950)}}} + Convert J2000.0 FK5 star data to B1950.0 FK4 +\subp{CALL sla\_FK54Z (R2000, D2000, BEPOCH, + R1950, D1950, DR1950, DD1950)} + Convert J2000.0 FK5 position to B1950.0 FK4 assuming zero + FK5 proper motion and no parallax +\subp{CALL sla\_FK52H (R5, D5, DR5, DD5, RH, DH, DRH, DDH)} + Convert J2000.0 FK5 star data to Hipparcos +\subp{CALL sla\_FK5HZ (R5, D5, EPOCH, RH, DH )} + Convert J2000.0 FK5 position to Hipparcos assuming zero Hipparcos + proper motion +\subp{CALL sla\_H2FK5 (RH, DH, DRH, DDH, R5, D5, DR5, DD5)} + Convert Hipparcos star data to J2000.0 FK5 +\subp{CALL sla\_HFK5Z (RH, DH, EPOCH, R5, D5, DR5, DD5)} + Convert Hipparcos position to J2000.0 FK5 assuming zero Hipparcos + proper motion +\subp{CALL sla\_DBJIN (STRING, NSTRT, DRESLT, J1, J2)} + Like sla\_DFLTIN but with extensions to accept leading `B' and `J' +\subp{CALL sla\_KBJ (JB, E, K, J)} + Select epoch prefix `B' or `J' +\subp{D~=~sla\_EPCO (K0, K, E)} + Convert an epoch into the appropriate form -- `B' or `J' +\end{callset} + +\callhead{Elliptic Aberration} +\begin{callset} +\subp{CALL sla\_ETRMS (EP, EV)} + E-terms +\subp{CALL sla\_SUBET (RC, DC, EQ, RM, DM)} + Remove the E-terms +\subp{CALL sla\_ADDET (RM, DM, EQ, RC, DC)} + Add the E-terms +\end{callset} + +\callhead{Geographical and Geocentric Coordinates} +\begin{callset} +\subp{CALL sla\_OBS (NUMBER, ID, NAME, WLONG, PHI, HEIGHT)} + Interrogate list of observatory parameters +\subp{CALL sla\_GEOC (P, H, R, Z)} + Convert geodetic position to geocentric +\subp{CALL sla\_POLMO (ELONGM, PHIM, XP, YP, ELONG, PHI, DAZ)} + Polar motion +\subp{CALL sla\_PVOBS (P, H, STL, PV)} + Position and velocity of observatory +\end{callset} + +\callhead{Apparent and Observed Place} +\begin{callset} +\subp{CALL sla\_MAP (RM, DM, PR, PD, PX, RV, EQ, DATE, RA, DA)} + Mean place to geocentric apparent place +\subp{CALL sla\_MAPPA (EQ, DATE, AMPRMS)} + Precompute mean to apparent parameters +\subp{CALL sla\_MAPQK (RM, DM, PR, PD, PX, RV, AMPRMS, RA, DA)} + Mean to apparent using precomputed parameters +\subp{CALL sla\_MAPQKZ (RM, DM, AMPRMS, RA, DA)} + Mean to apparent using precomputed parameters, for zero proper + motion, parallax and radial velocity +\subp{CALL sla\_AMP (RA, DA, DATE, EQ, RM, DM)} + Geocentric apparent place to mean place +\subp{CALL sla\_AMPQK (RA, DA, AOPRMS, RM, DM)} + Apparent to mean using precomputed parameters +\subp{CALL sla\_AOP (\vtop + {\hbox{RAP, DAP, UTC, DUT, ELONGM, PHIM, HM, XP, YP,} + \hbox{TDK, PMB, RH, WL, TLR, AOB, ZOB, HOB, DOB, ROB)}}} + Apparent place to observed place +\subp{CALL sla\_AOPPA (\vtop + {\hbox{UTC, DUT, ELONGM, PHIM, HM, XP, YP,} + \hbox{TDK, PMB, RH, WL, TLR, AOPRMS)}}} + Precompute apparent to observed parameters +\subp{CALL sla\_AOPPAT (UTC, AOPRMS)} + Update sidereal time in apparent to observed parameters +\subp{CALL sla\_AOPQK (RAP, DAP, AOPRMS, AOB, ZOB, HOB, DOB, ROB)} + Apparent to observed using precomputed parameters +\subp{CALL sla\_OAP (\vtop + {\hbox{TYPE, OB1, OB2, UTC, DUT, ELONGM, PHIM, HM, XP, YP,} + \hbox{TDK, PMB, RH, WL, TLR, RAP, DAP)}}} + Observed to apparent +\subp{CALL sla\_OAPQK (TYPE, OB1, OB2, AOPRMS, RA, DA)} + Observed to apparent using precomputed parameters +\end{callset} + +\callhead{Azimuth and Elevation} +\begin{callset} +\subp{CALL sla\_ALTAZ (\vtop + {\hbox{HA, DEC, PHI,} + \hbox{AZ, AZD, AZDD, EL, ELD, ELDD, PA, PAD, PADD)}}} + Positions, velocities {\it etc.}\ for an altazimuth mount +\subq{CALL sla\_E2H (HA, DEC, PHI, AZ, EL)} + {CALL sla\_DE2H (HA, DEC, PHI, AZ, EL)} + \hadec\ to \azel +\subq{CALL sla\_H2E (AZ, EL, PHI, HA, DEC)} + {CALL sla\_DH2E (AZ, EL, PHI, HA, DEC)} + \azel\ to \hadec +\subp{CALL sla\_PDA2H (P, D, A, H1, J1, H2, J2)} + Hour Angle corresponding to a given azimuth +\subp{CALL sla\_PDQ2H (P, D, Q, H1, J1, H2, J2)} + Hour Angle corresponding to a given parallactic angle +\subp{D~=~sla\_PA (HA, DEC, PHI)} + \hadec\ to parallactic angle +\subp{D~=~sla\_ZD (HA, DEC, PHI)} + \hadec\ to zenith distance +\end{callset} + +\callhead{Refraction and Air Mass} +\begin{callset} +\subp{CALL sla\_REFRO (ZOBS, HM, TDK, PMB, RH, WL, PHI, TLR, EPS, REF)} + Change in zenith distance due to refraction +\subp{CALL sla\_REFCO (HM, TDK, PMB, RH, WL, PHI, TLR, EPS, REFA, REFB)} + Constants for simple refraction model (accurate) +\subp{CALL sla\_REFCOQ (TDK, PMB, RH, WL, REFA, REFB)} + Constants for simple refraction model (fast) +\subp{CALL sla\_ATMDSP ( TDK, PMB, RH, WL1, REFA1, REFB1, WL2, REFA2, REFB2 )} + Adjust refraction constants for colour +\subp{CALL sla\_REFZ (ZU, REFA, REFB, ZR)} + Unrefracted to refracted ZD, simple model +\subp{CALL sla\_REFV (VU, REFA, REFB, VR)} + Unrefracted to refracted \azel\ vector, simple model +\subp{D~=~sla\_AIRMAS (ZD)} + Air mass +\end{callset} + +\callhead{Ecliptic Coordinates} +\begin{callset} +\subp{CALL sla\_ECMAT (DATE, RMAT)} + Equatorial to ecliptic rotation matrix +\subp{CALL sla\_EQECL (DR, DD, DATE, DL, DB)} + J2000.0 `FK5' to ecliptic coordinates +\subp{CALL sla\_ECLEQ (DL, DB, DATE, DR, DD)} + Ecliptic coordinates to J2000.0 `FK5' +\end{callset} + +\callhead{Galactic Coordinates} +\begin{callset} +\subp{CALL sla\_EG50 (DR, DD, DL, DB)} + B1950.0 `FK4' to galactic +\subp{CALL sla\_GE50 (DL, DB, DR, DD)} + Galactic to B1950.0 `FK4' +\subp{CALL sla\_EQGAL (DR, DD, DL, DB)} + J2000.0 `FK5' to galactic +\subp{CALL sla\_GALEQ (DL, DB, DR, DD)} + Galactic to J2000.0 `FK5' +\end{callset} + +\callhead{Supergalactic Coordinates} +\begin{callset} +\subp{CALL sla\_GALSUP (DL, DB, DSL, DSB)} + Galactic to supergalactic +\subp{CALL sla\_SUPGAL (DSL, DSB, DL, DB)} + Supergalactic to galactic +\end{callset} + +\callhead{Ephemerides} +\begin{callset} +\subp{CALL sla\_DMOON (DATE, PV)} + Approximate geocentric position and velocity of the Moon +\subp{CALL sla\_EARTH (IY, ID, FD, PV)} + Approximate heliocentric position and velocity of the Earth +\subp{CALL sla\_EVP (DATE, DEQX, DVB, DPB, DVH, DPH)} + Barycentric and heliocentric velocity and position of the Earth +\subp{CALL sla\_MOON (IY, ID, FD, PV)} + Approximate geocentric position and velocity of the Moon +\subp{CALL sla\_PLANET (DATE, NP, PV, JSTAT)} + Approximate heliocentric position and velocity of a planet +\subp{CALL sla\_RDPLAN (DATE, NP, ELONG, PHI, RA, DEC, DIAM)} + Approximate topocentric apparent place of a planet +\subp{CALL sla\_PLANEL (\vtop + {\hbox{DATE, JFORM, EPOCH, ORBINC, ANODE, PERIH,} + \hbox{AORQ, E, AORL, DM, PV, JSTAT)}}} + Heliocentric position and velocity of a planet, asteroid or + comet, starting from orbital elements +\subp{CALL sla\_PLANTE (\vtop + {\hbox{DATE, ELONG, PHI, JFORM, EPOCH, ORBINC, ANODE,} + \hbox{PERIH, AORQ, E, AORL, DM, RA, DEC, R, JSTAT)}}} + Topocentric apparent place of a Solar-System object whose + heliocentric orbital elements are known +\subp{CALL sla\_PV2EL (\vtop + {\hbox{PV, DATE, PMASS, JFORMR, JFORM, EPOCH, ORBINC,} + \hbox{ANODE, PERIH, AORQ, E, AORL, DM, JSTAT)}}} + Orbital elements of a planet from instantaneous position and velocity +\subp{CALL sla\_PERTEL (\vtop + {\hbox{JFORM, DATE0, DATE1,} + \hbox{EPOCH0, ORBI0, ANODE0, PERIH0, AORQ0, E0, AM0,} + \hbox{EPOCH1, ORBI1, ANODE1, PERIH1, AORQ1, E1, AM1,} + \hbox{JSTAT)}}} + Update elements by applying perturbations +\subp{CALL sla\_EL2UE (\vtop + {\hbox{DATE, JFORM, EPOCH, ORBINC, ANODE,} + \hbox{PERIH, AORQ, E, AORL, DM,} + \hbox{U, JSTAT)}}} + Transform conventional elements to universal elements +\subp{CALL sla\_UE2EL (\vtop + {\hbox{U, JFORMR,} + \hbox{JFORM, EPOCH, ORBINC, ANODE, PERIH,} + \hbox{AORQ, E, AORL, DM, JSTAT)}}} + Transform universal elements to conventional elements +\subp{CALL sla\_PV2UE (PV, DATE, PMASS, U, JSTAT)} + Package a position and velocity for use as universal elements +\subp{CALL sla\_UE2PV (DATE, U, PV, JSTAT)} + Extract the position and velocity from universal elements +\subp{CALL sla\_PERTUE (DATE, U, JSTAT)} + Update universal elements by applying perturbations +\subp{R~=~sla\_RVEROT (PHI, RA, DA, ST)} + Velocity component due to rotation of the Earth +\subp{CALL sla\_ECOR (RM, DM, IY, ID, FD, RV, TL)} + Components of velocity and light time due to Earth orbital motion +\subp{R~=~sla\_RVLSRD (R2000, D2000)} + Velocity component due to solar motion wrt dynamical LSR +\subp{R~=~sla\_RVLSRK (R2000, D2000)} + Velocity component due to solar motion wrt kinematical LSR +\subp{R~=~sla\_RVGALC (R2000, D2000)} + Velocity component due to rotation of the Galaxy +\subp{R~=~sla\_RVLG (R2000, D2000)} + Velocity component due to rotation and translation of the + Galaxy, relative to the mean motion of the local group +\end{callset} + +\callhead{Astrometry} +\begin{callset} +\subq{CALL sla\_S2TP (RA, DEC, RAZ, DECZ, XI, ETA, J)} + {CALL sla\_DS2TP (RA, DEC, RAZ, DECZ, XI, ETA, J)} + Transform spherical coordinates into tangent plane +\subq{CALL sla\_V2TP (V, V0, XI, ETA, J)} + {CALL sla\_DV2TP (V, V0, XI, ETA, J)} + Transform \xyz\ into tangent plane coordinates +\subq{CALL sla\_DTP2S (XI, ETA, RAZ, DECZ, RA, DEC)} + {CALL sla\_TP2S (XI, ETA, RAZ, DECZ, RA, DEC)} + Transform tangent plane coordinates into spherical coordinates +\subq{CALL sla\_DTP2V (XI, ETA, V0, V)} + {CALL sla\_TP2V (XI, ETA, V0, V)} + Transform tangent plane coordinates into \xyz +\subq{CALL sla\_DTPS2C (XI, ETA, RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2, N)} + {CALL sla\_TPS2C (XI, ETA, RA, DEC, RAZ1, DECZ1, RAZ2, DECZ2, N)} + Get plate centre from star \radec\ and tangent plane coordinates +\subq{CALL sla\_DTPV2C (XI, ETA, V, V01, V02, N)} + {CALL sla\_TPV2C (XI, ETA, V, V01, V02, N)} + Get plate centre from star \xyz\ and tangent plane coordinates +\subp{CALL sla\_PCD (DISCO, X, Y)} + Apply pincushion/barrel distortion +\subp{CALL sla\_UNPCD (DISCO, X, Y)} + Remove pincushion/barrel distortion +\subp{CALL sla\_FITXY (ITYPE, NP, XYE, XYM, COEFFS, J)} + Fit a linear model to relate two sets of \xy\ coordinates +\subp{CALL sla\_PXY (NP, XYE, XYM, COEFFS, XYP, XRMS, YRMS, RRMS)} + Compute predicted coordinates and residuals +\subp{CALL sla\_INVF (FWDS, BKWDS, J)} + Invert a linear model +\subp{CALL sla\_XY2XY (X1, Y1, COEFFS, X2, Y2)} + Transform one \xy +\subp{CALL sla\_DCMPF (COEFFS, XZ, YZ, XS, YS, PERP, ORIENT)} + Decompose a linear fit into scales {\it etc.} +\end{callset} + +\callhead{Numerical Methods} +\begin{callset} +\subp{CALL sla\_COMBN (NSEL, NCAND, LIST, J)} + Next combination (subset from a specified number of items) +\subp{CALL sla\_PERMUT (N, ISTATE, IORDER, J)} + Next permutation of a specified number of items +\subq{CALL sla\_SMAT (N, A, Y, D, JF, IW)} + {CALL sla\_DMAT (N, A, Y, D, JF, IW)} + Matrix inversion and solution of simultaneous equations +\subp{CALL sla\_SVD (M, N, MP, NP, A, W, V, WORK, JSTAT)} + Singular value decomposition of a matrix +\subp{CALL sla\_SVDSOL (M, N, MP, NP, B, U, W, V, WORK, X)} + Solution from given vector plus SVD +\subp{CALL sla\_SVDCOV (N, NP, NC, W, V, WORK, CVM)} + Covariance matrix from SVD +\subp{R~=~sla\_RANDOM (SEED)} + Generate pseudo-random real number in the range {$0 \leq x < 1$} +\subp{R~=~sla\_GRESID (S)} + Generate pseudo-random normal deviate ($\equiv$ `Gaussian residual') +\end{callset} + +\callhead{Real-time} +\begin{callset} +\subp{CALL sla\_WAIT (DELAY)} + Interval wait +\end{callset} + +\end{document} diff --git a/src/slalib/supgal.f b/src/slalib/supgal.f new file mode 100644 index 0000000..4658c8a --- /dev/null +++ b/src/slalib/supgal.f @@ -0,0 +1,79 @@ + SUBROUTINE sla_SUPGAL (DSL, DSB, DL, DB) +*+ +* - - - - - - - +* S U P G A L +* - - - - - - - +* +* Transformation from de Vaucouleurs supergalactic coordinates +* to IAU 1958 galactic coordinates (double precision) +* +* Given: +* DSL,DSB dp supergalactic longitude and latitude +* +* Returned: +* DL,DB dp galactic longitude and latitude L2,B2 +* +* (all arguments are radians) +* +* Called: +* sla_DCS2C, sla_DIMXV, sla_DCC2S, sla_DRANRM, sla_DRANGE +* +* References: +* +* de Vaucouleurs, de Vaucouleurs, & Corwin, Second Reference +* Catalogue of Bright Galaxies, U. Texas, page 8. +* +* Systems & Applied Sciences Corp., Documentation for the +* machine-readable version of the above catalogue, +* Contract NAS 5-26490. +* +* (These two references give different values for the galactic +* longitude of the supergalactic origin. Both are wrong; the +* correct value is L2=137.37.) +* +* P.T.Wallace Starlink March 1986 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DSL,DSB,DL,DB + + DOUBLE PRECISION sla_DRANRM,sla_DRANGE + + DOUBLE PRECISION V1(3),V2(3) + +* +* System of supergalactic coordinates: +* +* SGL SGB L2 B2 (deg) +* - +90 47.37 +6.32 +* 0 0 - 0 +* +* Galactic to supergalactic rotation matrix: +* + DOUBLE PRECISION RMAT(3,3) + DATA RMAT(1,1),RMAT(1,2),RMAT(1,3), + : RMAT(2,1),RMAT(2,2),RMAT(2,3), + : RMAT(3,1),RMAT(3,2),RMAT(3,3)/ + : -0.735742574804D0,+0.677261296414D0,+0.000000000000D0, + : -0.074553778365D0,-0.080991471307D0,+0.993922590400D0, + : +0.673145302109D0,+0.731271165817D0,+0.110081262225D0/ + + + +* Spherical to Cartesian + CALL sla_DCS2C(DSL,DSB,V1) + +* Supergalactic to galactic + CALL sla_DIMXV(RMAT,V1,V2) + +* Cartesian to spherical + CALL sla_DCC2S(V2,DL,DB) + +* Express in conventional ranges + DL=sla_DRANRM(DL) + DB=sla_DRANGE(DB) + + END diff --git a/src/slalib/svd.f b/src/slalib/svd.f new file mode 100644 index 0000000..8498333 --- /dev/null +++ b/src/slalib/svd.f @@ -0,0 +1,379 @@ + SUBROUTINE sla_SVD (M, N, MP, NP, A, W, V, WORK, JSTAT) +*+ +* - - - - +* S V D +* - - - - +* +* Singular value decomposition (double precision) +* +* This routine expresses a given matrix A as the product of +* three matrices U, W, V: +* +* A = U x W x VT +* +* Where: +* +* A is any M (rows) x N (columns) matrix, where M.GE.N +* U is an M x N column-orthogonal matrix +* W is an N x N diagonal matrix with W(I,I).GE.0 +* VT is the transpose of an N x N orthogonal matrix +* +* Note that M and N, above, are the LOGICAL dimensions of the +* matrices and vectors concerned, which can be located in +* arrays of larger PHYSICAL dimensions, given by MP and NP. +* +* Given: +* M,N i numbers of rows and columns in matrix A +* MP,NP i physical dimensions of array containing matrix A +* A d(MP,NP) array containing MxN matrix A +* +* Returned: +* A d(MP,NP) array containing MxN column-orthogonal matrix U +* W d(N) NxN diagonal matrix W (diagonal elements only) +* V d(NP,NP) array containing NxN orthogonal matrix V +* WORK d(N) workspace +* JSTAT i 0 = OK, -1 = A wrong shape, >0 = index of W +* for which convergence failed. See note 2, below. +* +* Notes: +* +* 1) V contains matrix V, not the transpose of matrix V. +* +* 2) If the status JSTAT is greater than zero, this need not +* necessarily be treated as a failure. It means that, due to +* chance properties of the matrix A, the QR transformation +* phase of the routine did not fully converge in a predefined +* number of iterations, something that very seldom occurs. +* When this condition does arise, it is possible that the +* elements of the diagonal matrix W have not been correctly +* found. However, in practice the results are likely to +* be trustworthy. Applications should report the condition +* as a warning, but then proceed normally. +* +* References: +* The algorithm is an adaptation of the routine SVD in the EISPACK +* library (Garbow et al 1977, EISPACK Guide Extension, Springer +* Verlag), which is a FORTRAN 66 implementation of the Algol +* routine SVD of Wilkinson & Reinsch 1971 (Handbook for Automatic +* Computation, vol 2, ed Bauer et al, Springer Verlag). These +* references give full details of the algorithm used here. A good +* account of the use of SVD in least squares problems is given in +* Numerical Recipes (Press et al 1986, Cambridge University Press), +* which includes another variant of the EISPACK code. +* +* P.T.Wallace Starlink 22 December 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER M,N,MP,NP + DOUBLE PRECISION A(MP,NP),W(N),V(NP,NP),WORK(N) + INTEGER JSTAT + +* Maximum number of iterations in QR phase + INTEGER ITMAX + PARAMETER (ITMAX=30) + + INTEGER I,K,L,J,K1,ITS,L1,I1 + LOGICAL CANCEL + DOUBLE PRECISION G,SCALE,AN,S,X,F,H,C,Y,Z + + + +* Check that the matrix is the right shape + IF (M.LT.N) THEN + +* No: error status + JSTAT = -1 + + ELSE + +* Yes: preset the status to OK + JSTAT = 0 + +* +* Householder reduction to bidiagonal form +* ---------------------------------------- + + G = 0D0 + SCALE = 0D0 + AN = 0D0 + DO I=1,N + L = I+1 + WORK(I) = SCALE*G + G = 0D0 + S = 0D0 + SCALE = 0D0 + IF (I.LE.M) THEN + DO K=I,M + SCALE = SCALE+ABS(A(K,I)) + END DO + IF (SCALE.NE.0D0) THEN + DO K=I,M + X = A(K,I)/SCALE + A(K,I) = X + S = S+X*X + END DO + F = A(I,I) + G = -SIGN(SQRT(S),F) + H = F*G-S + A(I,I) = F-G + IF (I.NE.N) THEN + DO J=L,N + S = 0D0 + DO K=I,M + S = S+A(K,I)*A(K,J) + END DO + F = S/H + DO K=I,M + A(K,J) = A(K,J)+F*A(K,I) + END DO + END DO + END IF + DO K=I,M + A(K,I) = SCALE*A(K,I) + END DO + END IF + END IF + W(I) = SCALE*G + G = 0D0 + S = 0D0 + SCALE = 0D0 + IF (I.LE.M .AND. I.NE.N) THEN + DO K=L,N + SCALE = SCALE+ABS(A(I,K)) + END DO + IF (SCALE.NE.0D0) THEN + DO K=L,N + X = A(I,K)/SCALE + A(I,K) = X + S = S+X*X + END DO + F = A(I,L) + G = -SIGN(SQRT(S),F) + H = F*G-S + A(I,L) = F-G + DO K=L,N + WORK(K) = A(I,K)/H + END DO + IF (I.NE.M) THEN + DO J=L,M + S = 0D0 + DO K=L,N + S = S+A(J,K)*A(I,K) + END DO + DO K=L,N + A(J,K) = A(J,K)+S*WORK(K) + END DO + END DO + END IF + DO K=L,N + A(I,K) = SCALE*A(I,K) + END DO + END IF + END IF + +* Overestimate of largest column norm for convergence test + AN = MAX(AN,ABS(W(I))+ABS(WORK(I))) + + END DO + +* +* Accumulation of right-hand transformations +* ------------------------------------------ + + DO I=N,1,-1 + IF (I.NE.N) THEN + IF (G.NE.0D0) THEN + DO J=L,N + V(J,I) = (A(I,J)/A(I,L))/G + END DO + DO J=L,N + S = 0D0 + DO K=L,N + S = S+A(I,K)*V(K,J) + END DO + DO K=L,N + V(K,J) = V(K,J)+S*V(K,I) + END DO + END DO + END IF + DO J=L,N + V(I,J) = 0D0 + V(J,I) = 0D0 + END DO + END IF + V(I,I) = 1D0 + G = WORK(I) + L = I + END DO + +* +* Accumulation of left-hand transformations +* ----------------------------------------- + + DO I=N,1,-1 + L = I+1 + G = W(I) + IF (I.NE.N) THEN + DO J=L,N + A(I,J) = 0D0 + END DO + END IF + IF (G.NE.0D0) THEN + IF (I.NE.N) THEN + DO J=L,N + S = 0D0 + DO K=L,M + S = S+A(K,I)*A(K,J) + END DO + F = (S/A(I,I))/G + DO K=I,M + A(K,J) = A(K,J)+F*A(K,I) + END DO + END DO + END IF + DO J=I,M + A(J,I) = A(J,I)/G + END DO + ELSE + DO J=I,M + A(J,I) = 0D0 + END DO + END IF + A(I,I) = A(I,I)+1D0 + END DO + +* +* Diagonalisation of the bidiagonal form +* -------------------------------------- + + DO K=N,1,-1 + K1 = K-1 + +* Iterate until converged + ITS = 0 + DO WHILE (ITS.LT.ITMAX) + ITS = ITS+1 + +* Test for splitting into submatrices + CANCEL = .TRUE. + DO L=K,1,-1 + L1 = L-1 + IF (AN+ABS(WORK(L)).EQ.AN) THEN + CANCEL = .FALSE. + GO TO 10 + END IF +* (Following never attempted for L=1 because WORK(1) is zero) + IF (AN+ABS(W(L1)).EQ.AN) GO TO 10 + END DO + 10 CONTINUE + +* Cancellation of WORK(L) if L>1 + IF (CANCEL) THEN + C = 0D0 + S = 1D0 + DO I=L,K + F = S*WORK(I) + IF (AN+ABS(F).EQ.AN) GO TO 20 + G = W(I) + H = SQRT(F*F+G*G) + W(I) = H + C = G/H + S = -F/H + DO J=1,M + Y = A(J,L1) + Z = A(J,I) + A(J,L1) = Y*C+Z*S + A(J,I) = -Y*S+Z*C + END DO + END DO + 20 CONTINUE + END IF + +* Converged? + Z = W(K) + IF (L.EQ.K) THEN + +* Yes: stop iterating + ITS = ITMAX + +* Ensure singular values non-negative + IF (Z.LT.0D0) THEN + W(K) = -Z + DO J=1,N + V(J,K) = -V(J,K) + END DO + END IF + ELSE + +* Not converged yet: set status if iteration limit reached + IF (ITS.EQ.ITMAX) JSTAT = K + +* Shift from bottom 2x2 minor + X = W(L) + Y = W(K1) + G = WORK(K1) + H = WORK(K) + F = ((Y-Z)*(Y+Z)+(G-H)*(G+H))/(2D0*H*Y) + IF (ABS(F).LE.1D15) THEN + G = SQRT(F*F+1D0) + ELSE + G = ABS(F) + END IF + F = ((X-Z)*(X+Z)+H*(Y/(F+SIGN(G,F))-H))/X + +* Next QR transformation + C = 1D0 + S = 1D0 + DO I1=L,K1 + I = I1+1 + G = WORK(I) + Y = W(I) + H = S*G + G = C*G + Z = SQRT(F*F+H*H) + WORK(I1) = Z + IF (Z.NE.0D0) THEN + C = F/Z + S = H/Z + ELSE + C = 1D0 + S = 0D0 + END IF + F = X*C+G*S + G = -X*S+G*C + H = Y*S + Y = Y*C + DO J=1,N + X = V(J,I1) + Z = V(J,I) + V(J,I1) = X*C+Z*S + V(J,I) = -X*S+Z*C + END DO + Z = SQRT(F*F+H*H) + W(I1) = Z + IF (Z.NE.0D0) THEN + C = F/Z + S = H/Z + END IF + F = C*G+S*Y + X = -S*G+C*Y + DO J=1,M + Y = A(J,I1) + Z = A(J,I) + A(J,I1) = Y*C+Z*S + A(J,I) = -Y*S+Z*C + END DO + END DO + WORK(L) = 0D0 + WORK(K) = F + W(K) = X + END IF + END DO + END DO + END IF + + END diff --git a/src/slalib/svdcov.f b/src/slalib/svdcov.f new file mode 100644 index 0000000..86d882c --- /dev/null +++ b/src/slalib/svdcov.f @@ -0,0 +1,60 @@ + SUBROUTINE sla_SVDCOV (N, NP, NC, W, V, WORK, CVM) +*+ +* - - - - - - - +* S V D C O V +* - - - - - - - +* +* From the W and V matrices from the SVD factorisation of a matrix +* (as obtained from the sla_SVD routine), obtain the covariance matrix. +* +* (double precision) +* +* Given: +* N i number of rows and columns in matrices W and V +* NP i first dimension of array containing matrix V +* NC i first dimension of array to receive CVM +* W d(N) NxN diagonal matrix W (diagonal elements only) +* V d(NP,NP) array containing NxN orthogonal matrix V +* +* Returned: +* WORK d(N) workspace +* CVM d(NC,NC) array to receive covariance matrix +* +* Reference: +* Numerical Recipes, section 14.3. +* +* P.T.Wallace Starlink December 1988 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER N,NP,NC + DOUBLE PRECISION W(N),V(NP,NP),WORK(N),CVM(NC,NC) + + INTEGER I,J,K + DOUBLE PRECISION S + + + + DO I=1,N + S=W(I) + IF (S.NE.0D0) THEN + WORK(I)=1D0/(S*S) + ELSE + WORK(I)=0D0 + END IF + END DO + DO I=1,N + DO J=1,I + S=0D0 + DO K=1,N + S=S+V(I,K)*V(J,K)*WORK(K) + END DO + CVM(I,J)=S + CVM(J,I)=S + END DO + END DO + + END diff --git a/src/slalib/svdsol.f b/src/slalib/svdsol.f new file mode 100644 index 0000000..46ef6bb --- /dev/null +++ b/src/slalib/svdsol.f @@ -0,0 +1,109 @@ + SUBROUTINE sla_SVDSOL (M, N, MP, NP, B, U, W, V, WORK, X) +*+ +* - - - - - - - +* S V D S O L +* - - - - - - - +* +* From a given vector and the SVD of a matrix (as obtained from +* the SVD routine), obtain the solution vector (double precision) +* +* This routine solves the equation: +* +* A . x = b +* +* where: +* +* A is a given M (rows) x N (columns) matrix, where M.GE.N +* x is the N-vector we wish to find +* b is a given M-vector +* +* by means of the Singular Value Decomposition method (SVD). In +* this method, the matrix A is first factorised (for example by +* the routine sla_SVD) into the following components: +* +* A = U x W x VT +* +* where: +* +* A is the M (rows) x N (columns) matrix +* U is an M x N column-orthogonal matrix +* W is an N x N diagonal matrix with W(I,I).GE.0 +* VT is the transpose of an NxN orthogonal matrix +* +* Note that M and N, above, are the LOGICAL dimensions of the +* matrices and vectors concerned, which can be located in +* arrays of larger PHYSICAL dimensions MP and NP. +* +* The solution is found from the expression: +* +* x = V . [diag(1/Wj)] . (transpose(U) . b) +* +* Notes: +* +* 1) If matrix A is square, and if the diagonal matrix W is not +* adjusted, the method is equivalent to conventional solution +* of simultaneous equations. +* +* 2) If M>N, the result is a least-squares fit. +* +* 3) If the solution is poorly determined, this shows up in the +* SVD factorisation as very small or zero Wj values. Where +* a Wj value is small but non-zero it can be set to zero to +* avoid ill effects. The present routine detects such zero +* Wj values and produces a sensible solution, with highly +* correlated terms kept under control rather than being allowed +* to elope to infinity, and with meaningful values for the +* other terms. +* +* Given: +* M,N i numbers of rows and columns in matrix A +* MP,NP i physical dimensions of array containing matrix A +* B d(M) known vector b +* U d(MP,NP) array containing MxN matrix U +* W d(N) NxN diagonal matrix W (diagonal elements only) +* V d(NP,NP) array containing NxN orthogonal matrix V +* +* Returned: +* WORK d(N) workspace +* X d(N) unknown vector x +* +* Reference: +* Numerical Recipes, section 2.9. +* +* P.T.Wallace Starlink 29 October 1993 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + INTEGER M,N,MP,NP + DOUBLE PRECISION B(M),U(MP,NP),W(N),V(NP,NP),WORK(N),X(N) + + INTEGER J,I,JJ + DOUBLE PRECISION S + + + +* Calculate [diag(1/Wj)] . transpose(U) . b (or zero for zero Wj) + DO J=1,N + S=0D0 + IF (W(J).NE.0D0) THEN + DO I=1,M + S=S+U(I,J)*B(I) + END DO + S=S/W(J) + END IF + WORK(J)=S + END DO + +* Multiply by matrix V to get result + DO J=1,N + S=0D0 + DO JJ=1,N + S=S+V(J,JJ)*WORK(JJ) + END DO + X(J)=S + END DO + + END diff --git a/src/slalib/tp2s.f b/src/slalib/tp2s.f new file mode 100644 index 0000000..11be54a --- /dev/null +++ b/src/slalib/tp2s.f @@ -0,0 +1,42 @@ + SUBROUTINE sla_TP2S (XI, ETA, RAZ, DECZ, RA, DEC) +*+ +* - - - - - +* T P 2 S +* - - - - - +* +* Transform tangent plane coordinates into spherical +* (single precision) +* +* Given: +* XI,ETA real tangent plane rectangular coordinates +* RAZ,DECZ real spherical coordinates of tangent point +* +* Returned: +* RA,DEC real spherical coordinates (0-2pi,+/-pi/2) +* +* Called: sla_RANORM +* +* P.T.Wallace Starlink 24 July 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL XI,ETA,RAZ,DECZ,RA,DEC + + REAL sla_RANORM + + REAL SDECZ,CDECZ,DENOM + + + + SDECZ=SIN(DECZ) + CDECZ=COS(DECZ) + + DENOM=CDECZ-ETA*SDECZ + + RA=sla_RANORM(ATAN2(XI,DENOM)+RAZ) + DEC=ATAN2(SDECZ+ETA*CDECZ,SQRT(XI*XI+DENOM*DENOM)) + + END diff --git a/src/slalib/tp2v.f b/src/slalib/tp2v.f new file mode 100644 index 0000000..cd8db96 --- /dev/null +++ b/src/slalib/tp2v.f @@ -0,0 +1,56 @@ + SUBROUTINE sla_TP2V (XI, ETA, V0, V) +*+ +* - - - - - +* T P 2 V +* - - - - - +* +* Given the tangent-plane coordinates of a star and the direction +* cosines of the tangent point, determine the direction cosines +* of the star. +* +* (single precision) +* +* Given: +* XI,ETA r tangent plane coordinates of star +* V0 r(3) direction cosines of tangent point +* +* Returned: +* V r(3) direction cosines of star +* +* Notes: +* +* 1 If vector V0 is not of unit length, the returned vector V will +* be wrong. +* +* 2 If vector V0 points at a pole, the returned vector V will be +* based on the arbitrary assumption that the RA of the tangent +* point is zero. +* +* 3 This routine is the Cartesian equivalent of the routine sla_TP2S. +* +* P.T.Wallace Starlink 11 February 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL XI,ETA,V0(3),V(3) + + REAL X,Y,Z,F,R + + + X=V0(1) + Y=V0(2) + Z=V0(3) + F=SQRT(1.0+XI*XI+ETA*ETA) + R=SQRT(X*X+Y*Y) + IF (R.EQ.0.0) THEN + R=1E-20 + X=R + END IF + V(1)=(X-(XI*Y+ETA*X*Z)/R)/F + V(2)=(Y+(XI*X-ETA*Y*Z)/R)/F + V(3)=(Z+ETA*R)/F + + END diff --git a/src/slalib/tps2c.f b/src/slalib/tps2c.f new file mode 100644 index 0000000..d7a7a52 --- /dev/null +++ b/src/slalib/tps2c.f @@ -0,0 +1,91 @@ + SUBROUTINE sla_TPS2C (XI, ETA, RA, DEC, RAZ1, DECZ1, + : RAZ2, DECZ2, N) +*+ +* - - - - - - +* T P S 2 C +* - - - - - - +* +* From the tangent plane coordinates of a star of known RA,Dec, +* determine the RA,Dec of the tangent point. +* +* (single precision) +* +* Given: +* XI,ETA r tangent plane rectangular coordinates +* RA,DEC r spherical coordinates +* +* Returned: +* RAZ1,DECZ1 r spherical coordinates of tangent point, solution 1 +* RAZ2,DECZ2 r spherical coordinates of tangent point, solution 2 +* N i number of solutions: +* 0 = no solutions returned (note 2) +* 1 = only the first solution is useful (note 3) +* 2 = both solutions are useful (note 3) +* +* Notes: +* +* 1 The RAZ1 and RAZ2 values are returned in the range 0-2pi. +* +* 2 Cases where there is no solution can only arise near the poles. +* For example, it is clearly impossible for a star at the pole +* itself to have a non-zero XI value, and hence it is +* meaningless to ask where the tangent point would have to be +* to bring about this combination of XI and DEC. +* +* 3 Also near the poles, cases can arise where there are two useful +* solutions. The argument N indicates whether the second of the +* two solutions returned is useful. N=1 indicates only one useful +* solution, the usual case; under these circumstances, the second +* solution corresponds to the "over-the-pole" case, and this is +* reflected in the values of RAZ2 and DECZ2 which are returned. +* +* 4 The DECZ1 and DECZ2 values are returned in the range +/-pi, but +* in the usual, non-pole-crossing, case, the range is +/-pi/2. +* +* 5 This routine is the spherical equivalent of the routine sla_DTPV2C. +* +* Called: sla_RANORM +* +* P.T.Wallace Starlink 5 June 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL XI,ETA,RA,DEC,RAZ1,DECZ1,RAZ2,DECZ2 + INTEGER N + + REAL X2,Y2,SD,CD,SDF,R2,R,S,C + + REAL sla_RANORM + + + X2=XI*XI + Y2=ETA*ETA + SD=SIN(DEC) + CD=COS(DEC) + SDF=SD*SQRT(1.0+X2+Y2) + R2=CD*CD*(1.0+Y2)-SD*SD*X2 + IF (R2.GE.0.0) THEN + R=SQRT(R2) + S=SDF-ETA*R + C=SDF*ETA+R + IF (XI.EQ.0.0.AND.R.EQ.0.0) R=1.0 + RAZ1=sla_RANORM(RA-ATAN2(XI,R)) + DECZ1=ATAN2(S,C) + R=-R + S=SDF-ETA*R + C=SDF*ETA+R + RAZ2=sla_RANORM(RA-ATAN2(XI,R)) + DECZ2=ATAN2(S,C) + IF (ABS(SDF).LT.1.0) THEN + N=1 + ELSE + N=2 + END IF + ELSE + N=0 + END IF + + END diff --git a/src/slalib/tpv2c.f b/src/slalib/tpv2c.f new file mode 100644 index 0000000..7afe25d --- /dev/null +++ b/src/slalib/tpv2c.f @@ -0,0 +1,83 @@ + SUBROUTINE sla_TPV2C (XI, ETA, V, V01, V02, N) +*+ +* - - - - - - +* T P V 2 C +* - - - - - - +* +* Given the tangent-plane coordinates of a star and its direction +* cosines, determine the direction cosines of the tangent-point. +* +* (single precision) +* +* Given: +* XI,ETA r tangent plane coordinates of star +* V r(3) direction cosines of star +* +* Returned: +* V01 r(3) direction cosines of tangent point, solution 1 +* V02 r(3) direction cosines of tangent point, solution 2 +* N i number of solutions: +* 0 = no solutions returned (note 2) +* 1 = only the first solution is useful (note 3) +* 2 = both solutions are useful (note 3) +* +* Notes: +* +* 1 The vector V must be of unit length or the result will be wrong. +* +* 2 Cases where there is no solution can only arise near the poles. +* For example, it is clearly impossible for a star at the pole +* itself to have a non-zero XI value, and hence it is meaningless +* to ask where the tangent point would have to be. +* +* 3 Also near the poles, cases can arise where there are two useful +* solutions. The argument N indicates whether the second of the +* two solutions returned is useful. N=1 indicates only one useful +* solution, the usual case; under these circumstances, the second +* solution can be regarded as valid if the vector V02 is interpreted +* as the "over-the-pole" case. +* +* 4 This routine is the Cartesian equivalent of the routine sla_TPS2C. +* +* P.T.Wallace Starlink 5 June 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL XI,ETA,V(3),V01(3),V02(3) + INTEGER N + + REAL X,Y,Z,RXY2,XI2,ETA2P1,SDF,R2,R,C + + + X=V(1) + Y=V(2) + Z=V(3) + RXY2=X*X+Y*Y + XI2=XI*XI + ETA2P1=ETA*ETA+1.0 + SDF=Z*SQRT(XI2+ETA2P1) + R2=RXY2*ETA2P1-Z*Z*XI2 + IF (R2.GT.0.0) THEN + R=SQRT(R2) + C=(SDF*ETA+R)/(ETA2P1*SQRT(RXY2*(R2+XI2))) + V01(1)=C*(X*R+Y*XI) + V01(2)=C*(Y*R-X*XI) + V01(3)=(SDF-ETA*R)/ETA2P1 + R=-R + C=(SDF*ETA+R)/(ETA2P1*SQRT(RXY2*(R2+XI2))) + V02(1)=C*(X*R+Y*XI) + V02(2)=C*(Y*R-X*XI) + V02(3)=(SDF-ETA*R)/ETA2P1 + IF (ABS(SDF).LT.1.0) THEN + N=1 + ELSE + N=2 + END IF + ELSE + N=0 + END IF + + END diff --git a/src/slalib/ue2el.f b/src/slalib/ue2el.f new file mode 100644 index 0000000..d7187d9 --- /dev/null +++ b/src/slalib/ue2el.f @@ -0,0 +1,194 @@ + SUBROUTINE sla_UE2EL (U, JFORMR, + : JFORM, EPOCH, ORBINC, ANODE, PERIH, + : AORQ, E, AORL, DM, JSTAT) +*+ +* - - - - - - +* U E 2 E L +* - - - - - - +* +* Transform universal elements into conventional heliocentric +* osculating elements. +* +* Given: +* U d(13) universal orbital elements (Note 1) +* +* (1) combined mass (M+m) +* (2) total energy of the orbit (alpha) +* (3) reference (osculating) epoch (t0) +* (4-6) position at reference epoch (r0) +* (7-9) velocity at reference epoch (v0) +* (10) heliocentric distance at reference epoch +* (11) r0.v0 +* (12) date (t) +* (13) universal eccentric anomaly (psi) of date, approx +* +* JFORMR i requested element set (1-3; Note 3) +* +* Returned: +* JFORM d element set actually returned (1-3; Note 4) +* EPOCH d epoch of elements (TT MJD) +* ORBINC d inclination (radians) +* ANODE d longitude of the ascending node (radians) +* PERIH d longitude or argument of perihelion (radians) +* AORQ d mean distance or perihelion distance (AU) +* E d eccentricity +* AORL d mean anomaly or longitude (radians, JFORM=1,2 only) +* DM d daily motion (radians, JFORM=1 only) +* JSTAT i status: 0 = OK +* -1 = illegal combined mass +* -2 = illegal JFORMR +* -3 = position/velocity out of range +* +* Notes +* +* 1 The "universal" elements are those which define the orbit for the +* purposes of the method of universal variables (see reference 2). +* They consist of the combined mass of the two bodies, an epoch, +* and the position and velocity vectors (arbitrary reference frame) +* at that epoch. The parameter set used here includes also various +* quantities that can, in fact, be derived from the other +* information. This approach is taken to avoiding unnecessary +* computation and loss of accuracy. The supplementary quantities +* are (i) alpha, which is proportional to the total energy of the +* orbit, (ii) the heliocentric distance at epoch, (iii) the +* outwards component of the velocity at the given epoch, (iv) an +* estimate of psi, the "universal eccentric anomaly" at a given +* date and (v) that date. +* +* 2 The universal elements are with respect to the mean equator and +* equinox of epoch J2000. The orbital elements produced are with +* respect to the J2000 ecliptic and mean equinox. +* +* 3 Three different element-format options are supported: +* +* Option JFORM=1, suitable for the major planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = longitude of perihelion, curly pi (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e +* AORL = mean longitude L (radians) +* DM = daily motion (radians) +* +* Option JFORM=2, suitable for minor planets: +* +* EPOCH = epoch of elements (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = mean distance, a (AU) +* E = eccentricity, e +* AORL = mean anomaly M (radians) +* +* Option JFORM=3, suitable for comets: +* +* EPOCH = epoch of perihelion (TT MJD) +* ORBINC = inclination i (radians) +* ANODE = longitude of the ascending node, big omega (radians) +* PERIH = argument of perihelion, little omega (radians) +* AORQ = perihelion distance, q (AU) +* E = eccentricity, e +* +* 4 It may not be possible to generate elements in the form +* requested through JFORMR. The caller is notified of the form +* of elements actually returned by means of the JFORM argument: +* +* JFORMR JFORM meaning +* +* 1 1 OK - elements are in the requested format +* 1 2 never happens +* 1 3 orbit not elliptical +* +* 2 1 never happens +* 2 2 OK - elements are in the requested format +* 2 3 orbit not elliptical +* +* 3 1 never happens +* 3 2 never happens +* 3 3 OK - elements are in the requested format +* +* 5 The arguments returned for each value of JFORM (cf Note 6: JFORM +* may not be the same as JFORMR) are as follows: +* +* JFORM 1 2 3 +* EPOCH t0 t0 T +* ORBINC i i i +* ANODE Omega Omega Omega +* PERIH curly pi omega omega +* AORQ a a q +* E e e e +* AORL L M - +* DM n - - +* +* where: +* +* t0 is the epoch of the elements (MJD, TT) +* T " epoch of perihelion (MJD, TT) +* i " inclination (radians) +* Omega " longitude of the ascending node (radians) +* curly pi " longitude of perihelion (radians) +* omega " argument of perihelion (radians) +* a " mean distance (AU) +* q " perihelion distance (AU) +* e " eccentricity +* L " longitude (radians, 0-2pi) +* M " mean anomaly (radians, 0-2pi) +* n " daily motion (radians) +* - means no value is set +* +* 6 At very small inclinations, the longitude of the ascending node +* ANODE becomes indeterminate and under some circumstances may be +* set arbitrarily to zero. Similarly, if the orbit is close to +* circular, the true anomaly becomes indeterminate and under some +* circumstances may be set arbitrarily to zero. In such cases, +* the other elements are automatically adjusted to compensate, +* and so the elements remain a valid description of the orbit. +* +* References: +* +* 1 Sterne, Theodore E., "An Introduction to Celestial Mechanics", +* Interscience Publishers Inc., 1960. Section 6.7, p199. +* +* 2 Everhart, E. & Pitkin, E.T., Am.J.Phys. 51, 712, 1983. +* +* Called: sla_PV2EL +* +* P.T.Wallace Starlink 18 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION U(13) + INTEGER JFORMR,JFORM + DOUBLE PRECISION EPOCH,ORBINC,ANODE,PERIH,AORQ,E,AORL,DM + INTEGER JSTAT + +* Gaussian gravitational constant (exact) + DOUBLE PRECISION GCON + PARAMETER (GCON=0.01720209895D0) + +* Canonical days to seconds + DOUBLE PRECISION CD2S + PARAMETER (CD2S=GCON/86400D0) + + INTEGER I + DOUBLE PRECISION PMASS,DATE,PV(6) + + +* Unpack the universal elements. + PMASS = U(1)-1D0 + DATE = U(3) + DO I=1,3 + PV(I) = U(I+3) + PV(I+3) = U(I+6)*CD2S + END DO + +* Convert the position and velocity etc into conventional elements. + CALL sla_PV2EL(PV,DATE,PMASS,JFORMR,JFORM,EPOCH,ORBINC,ANODE, + : PERIH,AORQ,E,AORL,DM,JSTAT) + + END diff --git a/src/slalib/ue2pv.f b/src/slalib/ue2pv.f new file mode 100644 index 0000000..be7b59f --- /dev/null +++ b/src/slalib/ue2pv.f @@ -0,0 +1,215 @@ + SUBROUTINE sla_UE2PV (DATE, U, PV, JSTAT) +*+ +* - - - - - - +* U E 2 P V +* - - - - - - +* +* Heliocentric position and velocity of a planet, asteroid or comet, +* starting from orbital elements in the "universal variables" form. +* +* Given: +* DATE d date, Modified Julian Date (JD-2400000.5) +* +* Given and returned: +* U d(13) universal orbital elements (updated; Note 1) +* +* given (1) combined mass (M+m) +* " (2) total energy of the orbit (alpha) +* " (3) reference (osculating) epoch (t0) +* " (4-6) position at reference epoch (r0) +* " (7-9) velocity at reference epoch (v0) +* " (10) heliocentric distance at reference epoch +* " (11) r0.v0 +* returned (12) date (t) +* " (13) universal eccentric anomaly (psi) of date +* +* Returned: +* PV d(6) position (AU) and velocity (AU/s) +* JSTAT i status: 0 = OK +* -1 = radius vector zero +* -2 = failed to converge +* +* Notes +* +* 1 The "universal" elements are those which define the orbit for the +* purposes of the method of universal variables (see reference). +* They consist of the combined mass of the two bodies, an epoch, +* and the position and velocity vectors (arbitrary reference frame) +* at that epoch. The parameter set used here includes also various +* quantities that can, in fact, be derived from the other +* information. This approach is taken to avoiding unnecessary +* computation and loss of accuracy. The supplementary quantities +* are (i) alpha, which is proportional to the total energy of the +* orbit, (ii) the heliocentric distance at epoch, (iii) the +* outwards component of the velocity at the given epoch, (iv) an +* estimate of psi, the "universal eccentric anomaly" at a given +* date and (v) that date. +* +* 2 The companion routine is sla_EL2UE. This takes the conventional +* orbital elements and transforms them into the set of numbers +* needed by the present routine. A single prediction requires one +* one call to sla_EL2UE followed by one call to the present routine; +* for convenience, the two calls are packaged as the routine +* sla_PLANEL. Multiple predictions may be made by again +* calling sla_EL2UE once, but then calling the present routine +* multiple times, which is faster than multiple calls to sla_PLANEL. +* +* It is not obligatory to use sla_EL2UE to obtain the parameters. +* However, it should be noted that because sla_EL2UE performs its +* own validation, no checks on the contents of the array U are made +* by the present routine. +* +* 3 DATE is the instant for which the prediction is required. It is +* in the TT timescale (formerly Ephemeris Time, ET) and is a +* Modified Julian Date (JD-2400000.5). +* +* 4 The universal elements supplied in the array U are in canonical +* units (solar masses, AU and canonical days). The position and +* velocity are not sensitive to the choice of reference frame. The +* sla_EL2UE routine in fact produces coordinates with respect to the +* J2000 equator and equinox. +* +* 5 The algorithm was originally adapted from the EPHSLA program of +* D.H.P.Jones (private communication, 1996). The method is based +* on Stumpff's Universal Variables. +* +* Reference: Everhart, E. & Pitkin, E.T., Am.J.Phys. 51, 712, 1983. +* +* P.T.Wallace Starlink 19 March 1999 +* +* Copyright (C) 1999 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DATE,U(13),PV(6) + INTEGER JSTAT + +* Gaussian gravitational constant (exact) + DOUBLE PRECISION GCON + PARAMETER (GCON=0.01720209895D0) + +* Canonical days to seconds + DOUBLE PRECISION CD2S + PARAMETER (CD2S=GCON/86400D0) + +* Test value for solution and maximum number of iterations + DOUBLE PRECISION TEST + INTEGER NITMAX + PARAMETER (TEST=1D-13,NITMAX=20) + + INTEGER I,NIT,N + + DOUBLE PRECISION CM,ALPHA,T0,P0(3),V0(3),R0,SIGMA0,T,PSI,DT,W, + : TOL,PSJ,PSJ2,BETA,S0,S1,S2,S3,FF,R,F,G,FD,GD + + + +* Unpack the parameters. + CM = U(1) + ALPHA = U(2) + T0 = U(3) + DO I=1,3 + P0(I) = U(I+3) + V0(I) = U(I+6) + END DO + R0 = U(10) + SIGMA0 = U(11) + T = U(12) + PSI = U(13) + +* Approximately update the universal eccentric anomaly. + PSI = PSI+(DATE-T)*GCON/R0 + +* Time from reference epoch to date (in Canonical Days: a canonical +* day is 58.1324409... days, defined as 1/GCON). + DT = (DATE-T0)*GCON + +* Refine the universal eccentric anomaly. + NIT = 1 + W = 1D0 + TOL = 0D0 + DO WHILE (ABS(W).GE.TOL) + +* Form half angles until BETA small enough. + N = 0 + PSJ = PSI + PSJ2 = PSJ*PSJ + BETA = ALPHA*PSJ2 + DO WHILE (ABS(BETA).GT.0.7D0) + N = N+1 + BETA = BETA/4D0 + PSJ = PSJ/2D0 + PSJ2 = PSJ2/4D0 + END DO + +* Calculate Universal Variables S0,S1,S2,S3 by nested series. + S3 = PSJ*PSJ2*((((((BETA/210D0+1D0) + : *BETA/156D0+1D0) + : *BETA/110D0+1D0) + : *BETA/72D0+1D0) + : *BETA/42D0+1D0) + : *BETA/20D0+1D0)/6D0 + S2 = PSJ2*((((((BETA/182D0+1D0) + : *BETA/132D0+1D0) + : *BETA/90D0+1D0) + : *BETA/56D0+1D0) + : *BETA/30D0+1D0) + : *BETA/12D0+1D0)/2D0 + S1 = PSJ+ALPHA*S3 + S0 = 1D0+ALPHA*S2 + +* Undo the angle-halving. + TOL = TEST + DO WHILE (N.GT.0) + S3 = 2D0*(S0*S3+PSJ*S2) + S2 = 2D0*S1*S1 + S1 = 2D0*S0*S1 + S0 = 2D0*S0*S0-1D0 + PSJ = PSJ+PSJ + TOL = TOL+TOL + N = N-1 + END DO + +* Improve the approximation to PSI. + FF = R0*S1+SIGMA0*S2+CM*S3-DT + R = R0*S0+SIGMA0*S1+CM*S2 + IF (R.EQ.0D0) GO TO 9010 + W = FF/R + PSI = PSI-W + +* Next iteration, unless too many already. + IF (NIT.GE.NITMAX) GO TO 9020 + NIT = NIT+1 + END DO + +* Project the position and velocity vectors (scaling velocity to AU/s). + W = CM*S2 + F = 1D0-W/R0 + G = DT-CM*S3 + FD = -CM*S1/(R0*R) + GD = 1D0-W/R + DO I=1,3 + PV(I) = P0(I)*F+V0(I)*G + PV(I+3) = CD2S*(P0(I)*FD+V0(I)*GD) + END DO + +* Update the parameters to allow speedy prediction of PSI next time. + U(12) = DATE + U(13) = PSI + +* OK exit. + JSTAT = 0 + GO TO 9999 + +* Null radius vector. + 9010 CONTINUE + JSTAT = -1 + GO TO 9999 + +* Failed to converge. + 9020 CONTINUE + JSTAT = -2 + + 9999 CONTINUE + END diff --git a/src/slalib/unpcd.f b/src/slalib/unpcd.f new file mode 100644 index 0000000..9502671 --- /dev/null +++ b/src/slalib/unpcd.f @@ -0,0 +1,68 @@ + SUBROUTINE sla_UNPCD (DISCO,X,Y) +*+ +* - - - - - - +* U N P C D +* - - - - - - +* +* Remove pincushion/barrel distortion from a distorted [x,y] +* to give tangent-plane [x,y]. +* +* Given: +* DISCO d pincushion/barrel distortion coefficient +* X,Y d distorted coordinates +* +* Returned: +* X,Y d tangent-plane coordinates +* +* Notes: +* +* 1) The distortion is of the form RP = R*(1 + C*R**2), where R is +* the radial distance from the tangent point, C is the DISCO +* argument, and RP is the radial distance in the presence of +* the distortion. +* +* 2) For pincushion distortion, C is +ve; for barrel distortion, +* C is -ve. +* +* 3) For X,Y in "radians" - units of one projection radius, +* which in the case of a photograph is the focal length of +* the camera - the following DISCO values apply: +* +* Geometry DISCO +* +* astrograph 0.0 +* Schmidt -0.3333 +* AAT PF doublet +147.069 +* AAT PF triplet +178.585 +* AAT f/8 +21.20 +* JKT f/8 +13.32 +* +* 4) The present routine is an approximate inverse to the +* companion routine sla_PCD, obtained from two iterations +* of Newton's method. The mismatch between the sla_PCD and +* sla_UNPCD routines is negligible for astrometric applications; +* to reach 1 milliarcsec at the edge of the AAT triplet or +* Schmidt field would require field diameters of 2.4 degrees +* and 42 degrees respectively. +* +* P.T.Wallace Starlink 1 August 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION DISCO,X,Y + + DOUBLE PRECISION CR2,A,CR2A2,F + + + + CR2=DISCO*(X*X+Y*Y) + A=(2D0*CR2+1D0)/(3D0*CR2+1D0) + CR2A2=CR2*A*A + F=(2D0*CR2A2*A+1D0)/(3D0*CR2A2+1D0) + X=X*F + Y=Y*F + + END diff --git a/src/slalib/v2tp.f b/src/slalib/v2tp.f new file mode 100644 index 0000000..c072bc8 --- /dev/null +++ b/src/slalib/v2tp.f @@ -0,0 +1,78 @@ + SUBROUTINE sla_V2TP (V, V0, XI, ETA, J) +*+ +* - - - - - +* V 2 T P +* - - - - - +* +* Given the direction cosines of a star and of the tangent point, +* determine the star's tangent-plane coordinates. +* +* (single precision) +* +* Given: +* V r(3) direction cosines of star +* V0 r(3) direction cosines of tangent point +* +* Returned: +* XI,ETA r tangent plane coordinates of star +* J i status: 0 = OK +* 1 = error, star too far from axis +* 2 = error, antistar on tangent plane +* 3 = error, antistar too far from axis +* +* Notes: +* +* 1 If vector V0 is not of unit length, or if vector V is of zero +* length, the results will be wrong. +* +* 2 If V0 points at a pole, the returned XI,ETA will be based on the +* arbitrary assumption that the RA of the tangent point is zero. +* +* 3 This routine is the Cartesian equivalent of the routine sla_S2TP. +* +* P.T.Wallace Starlink 27 November 1996 +* +* Copyright (C) 1996 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL V(3),V0(3),XI,ETA + INTEGER J + + REAL X,Y,Z,X0,Y0,Z0,R2,R,W,D + + REAL TINY + PARAMETER (TINY=1E-6) + + + X=V(1) + Y=V(2) + Z=V(3) + X0=V0(1) + Y0=V0(2) + Z0=V0(3) + R2=X0*X0+Y0*Y0 + R=SQRT(R2) + IF (R.EQ.0.0) THEN + R=1E-20 + X0=R + END IF + W=X*X0+Y*Y0 + D=W+Z*Z0 + IF (D.GT.TINY) THEN + J=0 + ELSE IF (D.GE.0.0) THEN + J=1 + D=TINY + ELSE IF (D.GT.-TINY) THEN + J=2 + D=-TINY + ELSE + J=3 + END IF + D=D*R + XI=(Y*X0-X*Y0)/D + ETA=(Z*R2-Z0*W)/D + + END diff --git a/src/slalib/vdv.f b/src/slalib/vdv.f new file mode 100644 index 0000000..eddeac2 --- /dev/null +++ b/src/slalib/vdv.f @@ -0,0 +1,27 @@ + REAL FUNCTION sla_VDV (VA, VB) +*+ +* - - - - +* V D V +* - - - - +* +* Scalar product of two 3-vectors (single precision) +* +* Given: +* VA real(3) first vector +* VB real(3) second vector +* +* The result is the scalar product VA.VB (single precision) +* +* P.T.Wallace Starlink November 1984 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL VA(3),VB(3) + + + sla_VDV=VA(1)*VB(1)+VA(2)*VB(2)+VA(3)*VB(3) + + END diff --git a/src/slalib/vn.f b/src/slalib/vn.f new file mode 100644 index 0000000..e252867 --- /dev/null +++ b/src/slalib/vn.f @@ -0,0 +1,46 @@ + SUBROUTINE sla_VN (V, UV, VM) +*+ +* - - - +* V N +* - - - +* +* Normalizes a 3-vector also giving the modulus (single precision) +* +* Given: +* V real(3) vector +* +* Returned: +* UV real(3) unit vector in direction of V +* VM real modulus of V +* +* If the modulus of V is zero, UV is set to zero as well +* +* P.T.Wallace Starlink 23 November 1995 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL V(3),UV(3),VM + + INTEGER I + REAL W1,W2 + + +* Modulus + W1=0.0 + DO I=1,3 + W2=V(I) + W1=W1+W2*W2 + END DO + W1=SQRT(W1) + VM=W1 + +* Normalize the vector + IF (W1.LE.0.0) W1=1.0 + DO I=1,3 + UV(I)=V(I)/W1 + END DO + + END diff --git a/src/slalib/vxv.f b/src/slalib/vxv.f new file mode 100644 index 0000000..e0b9d93 --- /dev/null +++ b/src/slalib/vxv.f @@ -0,0 +1,39 @@ + SUBROUTINE sla_VXV (VA, VB, VC) +*+ +* - - - - +* V X V +* - - - - +* +* Vector product of two 3-vectors (single precision) +* +* Given: +* VA real(3) first vector +* VB real(3) second vector +* +* Returned: +* VC real(3) vector result +* +* P.T.Wallace Starlink March 1986 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL VA(3),VB(3),VC(3) + + REAL VW(3) + INTEGER I + + +* Form the vector product VA cross VB + VW(1)=VA(2)*VB(3)-VA(3)*VB(2) + VW(2)=VA(3)*VB(1)-VA(1)*VB(3) + VW(3)=VA(1)*VB(2)-VA(2)*VB(1) + +* Return the result + DO I=1,3 + VC(I)=VW(I) + END DO + + END diff --git a/src/slalib/wait.f_alpha_OSF1 b/src/slalib/wait.f_alpha_OSF1 new file mode 100644 index 0000000..8eb80e1 --- /dev/null +++ b/src/slalib/wait.f_alpha_OSF1 @@ -0,0 +1,32 @@ + SUBROUTINE sla_WAIT (DELAY) +*+ +* - - - - - +* W A I T +* - - - - - +* +* Interval wait +* +* !!! Version for: SPARC/SunOS4, +* SPARC/Solaris2, +* DEC Mips/Ultrix +* DEC AXP/Digital Unix +* Intel/Linux +* Convex +* +* Given: +* DELAY real delay in seconds +* +* Called: SLEEP (a Fortran Intrinsic on all obove platforms) +* +* P.T.Wallace Starlink 22 January 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL DELAY + + CALL SLEEP(NINT(DELAY)) + + END diff --git a/src/slalib/wait.f_convex b/src/slalib/wait.f_convex new file mode 100644 index 0000000..8eb80e1 --- /dev/null +++ b/src/slalib/wait.f_convex @@ -0,0 +1,32 @@ + SUBROUTINE sla_WAIT (DELAY) +*+ +* - - - - - +* W A I T +* - - - - - +* +* Interval wait +* +* !!! Version for: SPARC/SunOS4, +* SPARC/Solaris2, +* DEC Mips/Ultrix +* DEC AXP/Digital Unix +* Intel/Linux +* Convex +* +* Given: +* DELAY real delay in seconds +* +* Called: SLEEP (a Fortran Intrinsic on all obove platforms) +* +* P.T.Wallace Starlink 22 January 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL DELAY + + CALL SLEEP(NINT(DELAY)) + + END diff --git a/src/slalib/wait.f_ix86_Linux b/src/slalib/wait.f_ix86_Linux new file mode 100644 index 0000000..8eb80e1 --- /dev/null +++ b/src/slalib/wait.f_ix86_Linux @@ -0,0 +1,32 @@ + SUBROUTINE sla_WAIT (DELAY) +*+ +* - - - - - +* W A I T +* - - - - - +* +* Interval wait +* +* !!! Version for: SPARC/SunOS4, +* SPARC/Solaris2, +* DEC Mips/Ultrix +* DEC AXP/Digital Unix +* Intel/Linux +* Convex +* +* Given: +* DELAY real delay in seconds +* +* Called: SLEEP (a Fortran Intrinsic on all obove platforms) +* +* P.T.Wallace Starlink 22 January 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL DELAY + + CALL SLEEP(NINT(DELAY)) + + END diff --git a/src/slalib/wait.f_mips b/src/slalib/wait.f_mips new file mode 100644 index 0000000..8eb80e1 --- /dev/null +++ b/src/slalib/wait.f_mips @@ -0,0 +1,32 @@ + SUBROUTINE sla_WAIT (DELAY) +*+ +* - - - - - +* W A I T +* - - - - - +* +* Interval wait +* +* !!! Version for: SPARC/SunOS4, +* SPARC/Solaris2, +* DEC Mips/Ultrix +* DEC AXP/Digital Unix +* Intel/Linux +* Convex +* +* Given: +* DELAY real delay in seconds +* +* Called: SLEEP (a Fortran Intrinsic on all obove platforms) +* +* P.T.Wallace Starlink 22 January 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL DELAY + + CALL SLEEP(NINT(DELAY)) + + END diff --git a/src/slalib/wait.f_pcm b/src/slalib/wait.f_pcm new file mode 100644 index 0000000..d79e78a --- /dev/null +++ b/src/slalib/wait.f_pcm @@ -0,0 +1,66 @@ + SUBROUTINE sla_WAIT (DELAY) +*+ +* - - - - - +* W A I T +* - - - - - +* +* Interval wait +* +* !!! PC only - Microsoft Fortran specific !!! +* +* Given: +* DELAY real delay in seconds +* +* A delay of up to 10000 seconds occurs. +* +* Called: GETTIM (Microsoft Fortran run-time library) +* +* P.T.Wallace Starlink 14 October 1991 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL DELAY + + INTEGER IDELAY,IH,IM,IS,I,IT,IT0,IDT + LOGICAL FIRST,LOOP + + + + +* Convert requested delay to 0.01 second ticks + IDELAY=NINT(MAX(MIN(DELAY,1E4),0.0)*1E2) + +* Set "note start time" flag + FIRST=.TRUE. + +* Set "wait in progress" flag + LOOP=.TRUE. + +* Main loop + DO WHILE (LOOP) + +* Get the current time and convert to 0.01 second ticks + CALL GETTIM(IH,IM,IS,I) + IT=((IH*60+IM)*60+IS)*100+I + +* First time through the loop? + IF (FIRST) THEN + +* Yes: note the time and reset the flag + IT0=IT + FIRST=.FALSE. + ELSE + +* No: subtract the start time, handling 0 hours wrap + IDT=IT-IT0 + IF (IDT.LT.0) IDT=IDT+8640000 + +* If the requested delay has elapsed, stop looping + LOOP=IDT.LT.IDELAY + END IF + END DO + + END diff --git a/src/slalib/wait.f_sun4 b/src/slalib/wait.f_sun4 new file mode 100644 index 0000000..8eb80e1 --- /dev/null +++ b/src/slalib/wait.f_sun4 @@ -0,0 +1,32 @@ + SUBROUTINE sla_WAIT (DELAY) +*+ +* - - - - - +* W A I T +* - - - - - +* +* Interval wait +* +* !!! Version for: SPARC/SunOS4, +* SPARC/Solaris2, +* DEC Mips/Ultrix +* DEC AXP/Digital Unix +* Intel/Linux +* Convex +* +* Given: +* DELAY real delay in seconds +* +* Called: SLEEP (a Fortran Intrinsic on all obove platforms) +* +* P.T.Wallace Starlink 22 January 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL DELAY + + CALL SLEEP(NINT(DELAY)) + + END diff --git a/src/slalib/wait.f_sun4_Solaris b/src/slalib/wait.f_sun4_Solaris new file mode 100644 index 0000000..8eb80e1 --- /dev/null +++ b/src/slalib/wait.f_sun4_Solaris @@ -0,0 +1,32 @@ + SUBROUTINE sla_WAIT (DELAY) +*+ +* - - - - - +* W A I T +* - - - - - +* +* Interval wait +* +* !!! Version for: SPARC/SunOS4, +* SPARC/Solaris2, +* DEC Mips/Ultrix +* DEC AXP/Digital Unix +* Intel/Linux +* Convex +* +* Given: +* DELAY real delay in seconds +* +* Called: SLEEP (a Fortran Intrinsic on all obove platforms) +* +* P.T.Wallace Starlink 22 January 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL DELAY + + CALL SLEEP(NINT(DELAY)) + + END diff --git a/src/slalib/wait.f_vax b/src/slalib/wait.f_vax new file mode 100644 index 0000000..1fd2e94 --- /dev/null +++ b/src/slalib/wait.f_vax @@ -0,0 +1,43 @@ + SUBROUTINE sla_WAIT (DELAY) +*+ +* - - - - - +* W A I T +* - - - - - +* +* Interval wait +* +* !!! VAX/VMS specific !!! +* +* Given: +* DELAY real delay in seconds +* +* A delay 100ns < DELAY < 200s is requested. +* +* P.T.Wallace Starlink 14 October 1991 +*- + + IMPLICIT NONE + + REAL DELAY + + INTEGER JSTAT + INTEGER SYS$SCHDWK,SYS$HIBER + + INTEGER IDT(2) + DATA IDT(2)/-1/ + + + +* Encode delta time + IDT(1)=-NINT(MAX(1.0,1E7*MIN(200.0,DELAY))) + + +* Schedule a wakeup + JSTAT=SYS$SCHDWK(,,IDT,) + IF (.NOT.JSTAT) CALL LIB$STOP(%VAL(JSTAT)) + +* Hibernate + JSTAT=SYS$HIBER() + IF (.NOT.JSTAT) CALL LIB$STOP(%VAL(JSTAT)) + + END diff --git a/src/slalib/wait.f_x86_64 b/src/slalib/wait.f_x86_64 new file mode 100644 index 0000000..8eb80e1 --- /dev/null +++ b/src/slalib/wait.f_x86_64 @@ -0,0 +1,32 @@ + SUBROUTINE sla_WAIT (DELAY) +*+ +* - - - - - +* W A I T +* - - - - - +* +* Interval wait +* +* !!! Version for: SPARC/SunOS4, +* SPARC/Solaris2, +* DEC Mips/Ultrix +* DEC AXP/Digital Unix +* Intel/Linux +* Convex +* +* Given: +* DELAY real delay in seconds +* +* Called: SLEEP (a Fortran Intrinsic on all obove platforms) +* +* P.T.Wallace Starlink 22 January 1998 +* +* Copyright (C) 1998 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + REAL DELAY + + CALL SLEEP(NINT(DELAY)) + + END diff --git a/src/slalib/xy2xy.f b/src/slalib/xy2xy.f new file mode 100644 index 0000000..d830f44 --- /dev/null +++ b/src/slalib/xy2xy.f @@ -0,0 +1,49 @@ + SUBROUTINE sla_XY2XY (X1,Y1,COEFFS,X2,Y2) +*+ +* - - - - - - +* X Y 2 X Y +* - - - - - - +* +* Transform one [X,Y] into another using a linear model of the type +* produced by the sla_FITXY routine. +* +* Given: +* X1 d x-coordinate +* Y1 d y-coordinate +* COEFFS d(6) transformation coefficients (see note) +* +* Returned: +* X2 d x-coordinate +* Y2 d y-coordinate +* +* The model relates two sets of [X,Y] coordinates as follows. +* Naming the elements of COEFFS: +* +* COEFFS(1) = A +* COEFFS(2) = B +* COEFFS(3) = C +* COEFFS(4) = D +* COEFFS(5) = E +* COEFFS(6) = F +* +* the present routine performs the transformation: +* +* X2 = A + B*X1 + C*Y1 +* Y2 = D + E*X1 + F*Y1 +* +* See also sla_FITXY, sla_PXY, sla_INVF, sla_DCMPF +* +* P.T.Wallace Starlink 5 December 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION X1,Y1,COEFFS(6),X2,Y2 + + + X2=COEFFS(1)+COEFFS(2)*X1+COEFFS(3)*Y1 + Y2=COEFFS(4)+COEFFS(5)*X1+COEFFS(6)*Y1 + + END diff --git a/src/slalib/zd.f b/src/slalib/zd.f new file mode 100644 index 0000000..f3dd34f --- /dev/null +++ b/src/slalib/zd.f @@ -0,0 +1,62 @@ + DOUBLE PRECISION FUNCTION sla_ZD (HA, DEC, PHI) +*+ +* - - - +* Z D +* - - - +* +* HA, Dec to Zenith Distance (double precision) +* +* Given: +* HA d Hour Angle in radians +* DEC d declination in radians +* PHI d observatory latitude in radians +* +* The result is in the range 0 to pi. +* +* Notes: +* +* 1) The latitude must be geodetic. In critical applications, +* corrections for polar motion should be applied. +* +* 2) In some applications it will be important to specify the +* correct type of hour angle and declination in order to +* produce the required type of zenith distance. In particular, +* it may be important to distinguish between the zenith distance +* as affected by refraction, which would require the "observed" +* HA,Dec, and the zenith distance in vacuo, which would require +* the "topocentric" HA,Dec. If the effects of diurnal aberration +* can be neglected, the "apparent" HA,Dec may be used instead of +* the topocentric HA,Dec. +* +* 3) No range checking of arguments is done. +* +* 4) In applications which involve many zenith distance calculations, +* rather than calling the present routine it will be more efficient +* to use inline code, having previously computed fixed terms such +* as sine and cosine of latitude, and perhaps sine and cosine of +* declination. +* +* P.T.Wallace Starlink 3 April 1994 +* +* Copyright (C) 1995 Rutherford Appleton Laboratory +*- + + IMPLICIT NONE + + DOUBLE PRECISION HA,DEC,PHI + + DOUBLE PRECISION SH,CH,SD,CD,SP,CP,X,Y,Z + + + SH=SIN(HA) + CH=COS(HA) + SD=SIN(DEC) + CD=COS(DEC) + SP=SIN(PHI) + CP=COS(PHI) + X=CH*CD*SP-SD*CP + Y=SH*CD + Z=CH*CD*CP+SD*SP + sla_ZD=ATAN2(SQRT(X*X+Y*Y),Z) + + END -- cgit