hp41programs

Parallax

Diurnal Parallax for the HP-41


Overview
 

 1°)  Azimuthal Coordinates
 2°)  Equatorial Coordinates
 

-The difference between the topocentric coordinates and the geocentric coordinates is called "parallax"
-The vectorial relation  OP = OT + TP  gives us the required formulae to compute the parallax for the Moon , the planets ...

  where   O = the observer , T = the center of the Earth and  P = planet , Sun , Moon , .....
 

1°)  Azimuthal Coordinates
 

-Let  Az = geocentric azimuth , h = geocentric height and Az' & h' the corresponding topocentric values.
-Let  D = distance TP , D' = distance OP
-Let  b = geographic ( i-e geodetic, i-e astronomical ) latitude of the observer, b' its geocentric latitude
-Let  Alt = altitude of the observer
-And  a = Earth equatorial radius = 6378137 m , f = Earth flattening = 1/298.257
 

-We have the following rigorous formulae:

         D' cos Az' cos h' = D cos Az cos h - a r sin ( b - b' )
         D' sin Az' cos h'  = D sin Az cos h
              D' sin h'         = D sin h - a r cos ( b - b' )

          tan u = ( 1 - f ) tan b

          r sin b' = ( 1 - f ) sin u + ( Alt / 6378137 ) sin b                      (  r = OT  with Earth equatorial radius as unity )
          r cos b' =     cos u       + ( Alt / 6378137 ) cos b
 
 

Data Registers:              R00 & R04 thru R07: temp             ( Registers R01 thru R03 are to be initialized before executing "PAR" )

                                      •  R01 = D ( AU )
                                      •  R02 = b  ( ° ' " )
                                      •  R03 = Alt ( m )
Flags: /
Subroutines:   "R-S" & "S-R"  ( cf "Spherical Coordinates" or "Transformation of Coordinates" )
 
 

 01  LBL "PAR"
 02  DEG
 03  HR
 04  X<>Y
 05  HR
 06  X<>Y
 07  RCL 01      
 08  XEQ "S-R"
 09  STO 05
 10  RDN
 11  STO 06
 12  X<>Y
 13  STO 07
 14  RCL 02
 15  HR
 16  STO 04      
 17  1
 18  P-R
 19  X<>Y
 20  LASTX
 21  298.257
 22  1/X
 23  -
 24  STO 00
 25  *
 26  X<>Y
 27  R-P
 28  SIGN
 29  P-R
 30  X<>Y
 31  RCL 00      
 32  *
 33  RCL 03
 34  6378137
 35  /
 36  RCL 04
 37  X<>Y
 38  P-R
 39  ST+ T
 40  RDN
 41  +
 42  X<>Y
 43  R-P
 44  RCL 04      
 45  RCL Z
 46  -
 47  X<>Y
 48  P-R
 49  23454.79
 50  ST/ Z
 51  /
 52  ST- 07
 53  X<>Y
 54  ST- 05
 55  RCL 07      
 56  RCL 06
 57  RCL 05
 58  XEQ "R-S"
 59  X<> Z
 60  HMS
 61  X<>Y
 62  HMS
 63  END

 
     ( 104 bytes / SIZE 008 )
 
 

      STACK        INPUTS      OUTPUTS
           Y        h ( ° ' " )       h' ( ° ' " )
           X      Az ( ° ' " )      Az' ( ° ' " )

 
Example:    At the Palomar Obsevatory:

    D = 0.003 AU   STO 01
    b  = 33°21'22"   STO 02
  Alt = 1706 m       STO 03

     h  = 60°12'  ,  Az = 41°16'

     60.12    ENTER^
     41.16    XEQ "PAR"   >>>>   Az' = 41°16'11"97                             ---Execution time = 8s---
                                        RDN     h'  =  59°47'32"06

-With  Alt = 0 STO 03 , it yields

       Az' = 41°16'11"97
        h'  =  59°47'32"46

Notes:

-The distance D' is in Z-register.  Here,  D' = 0.002963056 AU
-Line 49 may be replace by 23455 without a great loss of accuracy.
 ( This value is 149597871 / 6378.137 = 1 Astronomical Unit / Earth's equatorial radius )

-In order to avoid using the subroutines "S-R" & "R-S", we can rewrite the formulae as follows:

    Tan Az' = ( sin Az cos h ) / [ cos Az cos h - ( a r / D ) sin ( b - b' ) ]
     Tan h'  = [ sin h - ( a r / D ) cos ( b - b' ) ] / [ cos2 h - 2 ( a r / D ) cos Az cos h sin ( b - b' ) + ( a r / D )2 sin2 ( b - b' ) ] 1/2

-And if Alt = 0 , we have the approximate relations:   r = 1 - f sin2 b   and   sin ( b - b' ) = f sin 2b ,  cos ( b - b' ) = 1
-"PAR0" uses these formulae:
 

Data Registers:              R00-R03-R04-R05: temp             ( Registers R01 & R02 are to be initialized before executing "PAR0" )

                                      •  R01 = D ( AU )
                                      •  R02 = b  ( ° ' " )
Flags: /
Subroutines: /
 
 

 01  LBL "PAR0"
 02  DEG
 03  HR
 04  STO 00       
 05  X<>Y
 06  HR
 07  1
 08  P-R
 09  STO 03
 10  CLX
 11  RCL 01
 12  23454.79
 13  *
 14  1/X
 15  RCL 02       
 16  HR
 17  SIN
 18  X^2
 19  298.257
 20  STO 04
 21  /
 22  1
 23  X<>Y
 24  -
 25  *
 26  ST- Y
 27  RCL 02       
 28  HR
 29  ST+ X
 30  SIN
 31  RCL 04
 32  /
 33  *
 34  STO 04
 35  RCL 00
 36  COS
 37  RCL 03       
 38  *
 39  ST+ X
 40  -
 41  RCL 04
 42  *
 43  RCL 03
 44  X^2
 45  +
 46  SQRT
 47  R-P
 48  X<>Y
 49  HMS
 50  RCL 00       
 51  RCL 03
 52  P-R
 53  RCL 04
 54  -
 55  R-P
 56  RDN
 57  HMS
 58  END

 
    ( 83 bytes / SIZE 005 )
 
 

      STACK        INPUTS      OUTPUTS
           Y        h ( ° ' " )       h' ( ° ' " )
           X      Az ( ° ' " )      Az' ( ° ' " )

 
Example:

    D = 0.003 AU   STO 01
    b  = 33°21'22"   STO 02   ( Alt = 0 )

     h  = 60°12'  ,  Az = 41°16'

     60.12    ENTER^
     41.16    XEQ "PAR0"   >>>>   Az' = 41°16'11"97                             ---Execution time = 6s---
                                          RDN     h'  =  59°47'32"46

Notes:

-So, we get almost the same results: error < 0"01
-In the case of the Palomar observatory, neglecting Alt does not produce an error greater than 1 arcsecond for the Moon, much less for the planets.

Other Formulae:

-If a great precision is not required, we can use:

         Az' = Az
and     h'  = h - ( a / D ) cos h

-These last formulas are very simple and better relations may be found.
-Here are some of them:

  1°)   Az' = Az + f ( a r / D ) sin Az sin 2b / cos h
           h'  =  h + ( a r / D ) ( - cos h + f cos Az sin 2b sin h )    and even better:

  2°)   Az' - Az = Arctan { [ ( r a / D ) sin ( b - b' ) sin Az ] / [ cos h - ( r a / D ) sin ( b - b' ) cos Az ] }
           h'  -  h   =  Arctan  { - [ ( r a / D ) cos ( h + ( b - b' ) cos Az ] / [ 1 - ( r a / D ) sin ( h + ( b - b' ) cos Az ] }

-The last ones above produce the same accuracy as "PAR0" ... but it seems there are some problems if h is close to 90° !
-Moreover, they lead to programs that are neither faster nor shorter than "PAR0".
-So I think we can keep "PAR0" if the altitude of the observer may be neglected and "PAR" otherwise...
 

2°)  Equatorial Coordinates
 

-Similar methods are available if we know the hour angle H and the declination d    ( H = Local Sidereal Time minus Right Ascension )
-Their corrected values H' and d' are related to H and d by:
 

Formulae:

         D' cos d' cos H' = D cos d cos H - a r cos b'
         D' cos d' sin H'  = D cos d sin H
              D' sin d'        = D sin d - a r sin b'

          tan u = ( 1 - f ) tan b

          r sin b' = ( 1 - f ) sin u + ( Alt / 6378137 ) sin b
          r cos b' =     cos u       + ( Alt / 6378137 ) cos b
 

Data Registers:              R00 & R04 thru R07: temp             ( Registers R01 thru R03 are to be initialized before executing "EPAR" )

                                      •  R01 = D ( AU )
                                      •  R02 = b  ( ° ' " )
                                      •  R03 = Alt ( m )
Flags: /
Subroutines:   "R-S" & "S-R"  ( cf "Spherical Coordinates" or "Transformation of Coordinates" )
 
 

 01  LBL "EPAR"
 02  DEG
 03  X<>Y
 04  HR
 05  X<>Y
 06  HR
 07  15
 08  *
 09  RCL 01       
 10  XEQ "S-R"
 11  STO 05
 12  RDN
 13  STO 06
 14  X<>Y
 15  STO 07
 16  RCL 02
 17  HR
 18  STO 04       
 19  1
 20  P-R
 21  X<>Y
 22  LASTX
 23  298.257
 24  1/X
 25  -
 26  STO 00
 27  *
 28  X<>Y
 29  R-P
 30  SIGN
 31  P-R
 32  X<>Y
 33  RCL 00       
 34  *
 35  RCL 03
 36  6378137
 37  /
 38  RCL 04
 39  X<>Y
 40  P-R
 41  ST+ T
 42  RDN
 43  +
 44  23454.79
 45  ST/ Z
 46  /
 47  ST- 07
 48  X<>Y
 49  ST- 05
 50  RCL 07       
 51  RCL 06
 52  RCL 05
 53  XEQ "R-S"
 54  X<> Z       
 55  HMS
 56  X<>Y
 57  15
 58  /
 59  24
 60  MOD
 61  HMS
 62  END

 
    ( 106 bytes / SIZE 008 )
 
 

      STACK        INPUTS      OUTPUTS
           Y        d ( ° ' " )       d' ( ° ' " )
           X    H ( hh.mnss )   H' ( hh.mnss )

 
Example:    At the Palomar Obsevatory:

    D = 0.003 AU   STO 01
    b  = 33°21'22"   STO 02
  Alt = 1706 m       STO 03

    d = -15°28'   H = 19h16m

    -15.28    ENTER^
      19.16   XEQ "EPAR"   >>>>    H' = 19h13m19s02                                       ---Execution time = 7s---
                                          RDN     d'  = -15°57'17"00

-With  Alt = 0 STO 03 , it yields

      H' = 19h13m19s06
      d'  = -15°57'16"53

Notes:

-Like with the azimuthal coordinates, we can also avoid using the subroutines "S-R" & "R-S" by rewriting the formulae as follows:

    Tan H' = ( cos d sin H ) / [ cos d cos H - ( a r / D ) cos b' ]
    Tan d' = [ sin d - ( a r / D ) sin b' ] / [ cos2 d - 2 ( a r / D ) cos d cos H cos b' + ( a r / D )2 cos2 b' ] 1/2

-And if Alt = 0 , we have the approximate relations:   r = 1 - f sin2 b   and   b' = b - f sin 2b
-The variant hereunder uses these formulae:
 

Data Registers:              R00-R03-R04-R05: temp             ( Registers R01 & R02 are to be initialized before executing "EPAR0" )

                                      •  R01 = D ( AU )
                                      •  R02 = b  ( ° ' " )
Flags: /
Subroutines: /
 
 

 01  LBL "EPAR0"
 02  DEG
 03  HR
 04  15
 05  *
 06  STO 00        
 07  X<>Y
 08  HR
 09  1
 10  P-R
 11  STO 03
 12  CLX
 13  23454.79
 14  RCL 01
 15  *
 16  1/X
 17  RCL 02
 18  HR
 19  STO 04        
 20  SIN
 21  X^2
 22  298.257
 23  STO 05
 24  /
 25  1
 26  X<>Y
 27  -
 28  *
 29  RCL 04
 30  ST+ X
 31  SIN
 32  RCL 05        
 33  /
 34  R-D
 35  RCL 04
 36  X<>Y
 37  -
 38  X<>Y
 39  P-R
 40  RDN
 41  -
 42  R^
 43  STO 04
 44  STO 05
 45  RCL 00
 46  RCL 03        
 47  P-R
 48  ST- 04
 49  X<>Y
 50  RDN
 51  ST+ X
 52  -
 53  RCL 05
 54  *
 55  RCL 03
 56  X^2
 57  +
 58  SQRT
 59  R-P
 60  X<>Y
 61  HMS
 62  R^
 63  RCL 04        
 64  CHS
 65  R-P
 66  CLX
 67  15
 68  /
 69  24
 70  MOD
 71  HMS
 72  END
 

 
    ( 101 bytes / SIZE 006 )
 
 

      STACK        INPUTS      OUTPUTS
           Y        d ( ° ' " )       d' ( ° ' " )
           X    H ( hh.mnss )   H' ( hh.mnss )

 
Example:

    D = 0.003 AU   STO 01
    b  = 33°21'22"   STO 02   ( Alt = 0 )

    d = -15°28'   H = 19h16m

    -15.28    ENTER^
      19.16   XEQ "EPAR"   >>>>    H' = 19h13m19s06                                       ---Execution time = 6s---
                                          RDN     d'  = -15°57'16"52
 
 

References:

[1]   Jean Meeus - "Astronomical Algorithms" - Willmann-Bell  -  ISBN 0-943396-61-1
[2]   F. Brunnow - "Spherical Astronomy"- New-York D. Van Nostrand - ISBN B002KW46KG ( ? )