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/sun67.htx/node43.html | 229 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 229 insertions(+) create mode 100644 src/slalib/sun67.htx/node43.html (limited to 'src/slalib/sun67.htx/node43.html') 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
+
+ + -- cgit