Source Code

These source-code files are part of a reconstructed copy of Luminary 98, a development version of the Apollo 11 Lunar Module (LM) Apollo Guidance Computer (AGC) software.

The reconstruction began with source code of Luminary 99 revision 1 previously transcribed from a digitized copy of that program. The code was then updated by undoing changes described in original Luminary memo 85, using asterisks indicating changed lines in the listing as a guide. While no listing of this version is known to exist, nor are the memory-bank checksums available, the reconstruction is believed to be correct because it was an an intermediate step in reconstructing Luminary 97 whose reconstruction was verified by matching memory-bank checksums to those listed in drawing 2021152G. Note that page numbers in the reconstructed code match those on the Luminary 099 revision 001 printout, although the added code would likely have changed page numbers for a real Luminary 98 listing.

Comments from the original source code are prefixed with a single '#' symbol, whereas comments added later are prefixed by "##" or "###". Report any errors noted by creating an issue report at the Virtual AGC project's GitHub repository.

047472,000002:                                                                                                  ## Copyright:   Public domain.
047473,000003:                                                                                                  ## Filename:    PLANETARY_INERTIAL_ORIENTATION.agc
047474,000004:                                                                                                  ## Purpose:     A section of Luminary revision 98.
047475,000005:                                                                                                  ##              It is part of the reconstructed source code for the a
047476,000006:                                                                                                  ##              development version of the flight software for the Lunar 
047477,000007:                                                                                                  ##              Module's (LM) Apollo Guidance Computer (AGC) for Apollo 11.
047478,000008:                                                                                                  ##              The code has been recreated from a copy of Luminary 99
047479,000009:                                                                                                  ##              revision 001, using asterisks indicating changed lines in
047480,000010:                                                                                                  ##              the listing and Luminary Memo #85, which lists changes between
047481,000011:                                                                                                  ##              Luminary 98 and 99.
047482,000012:                                                                                                  ## Reference:   pp. 1140-1148
047483,000013:                                                                                                  ## Assembler:   yaYUL
047484,000014:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
047485,000015:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
047486,000016:                                                                                                  ## Mod history: 2019-07-28 MAS  Created from Luminary 99.
047487,000017: 

Page 1140

047489,000019:                                                                                                  #  ..... RP-TO-R SUBROUTINE .....
047490,000020:                                                                                                  #  SUBROUTINE TO CONVERT RP (VECTOR IN PLANETARY COORDINATE SYSTEM, EITHER
047491,000021:                                                                                                  #  EARTH-FIXED OR MOON-FIXED) TO R (SAME VECTOR IN THE BASIC REF. SYSTEM)
047492,000022: 
047493,000023:                                                                                                  #        R = MT(T) * (RP + LP X RP)      MT = M MATRIX TRANSPOSE
047494,000024: 
047495,000025:                                                                                                  #  CALLING SEQUENCE
047496,000026:                                                                                                  #        L       CALL
047497,000027:                                                                                                  #        L+1             RP-TO-R
047498,000028: 
047499,000029:                                                                                                  #  SUBROUTINES USED
047500,000030:                                                                                                  #        EARTHMX, MOONMX, EARTHL
047501,000031: 
047502,000032:                                                                                                  #        ITEMS AVAILABLE FROM LAUNCH DATA
047503,000033:                                                                                                  #                504LM = THE LIBRATION VECTOR L OF THE MOON AT TIME TIMSUBL, EXPRESSED
047504,000034:                                                                                                  #                        IN THE MOON-FIXED COORD. SYSTEM         RADIANS B0
047505,000035: 
047506,000036:                                                                                                  #        ITEMS NECESSARY FOR SUBR. USED (SEE DESCRIPTION OF SUBR.)
047507,000037: 
047508,000038:                                                                                                  #  INPUT
047509,000039:                                                                                                  #        MPAC = 0 FOR EARTH, NON-ZERO FOR MOON
047510,000040:                                                                                                  #        0-5D = RP VECTOR
047511,000041:                                                                                                  #        6-7D = TIME
047512,000042: 
047513,000043:                                                                                                  #  OUTPUT
047514,000044:                                                                                                  #        MPAC = R VECTOR METERS B-29 FOR EARTH, B-27 FOR MOON
047515,000045: 
047516,000046: 26,2000                                           SETLOC   PLANTIN1                              
047517,000047: 26,2000                                           BANK                                           
047518,000048: 
047519,000049: 26,3716                                           COUNT*   $$/LUROT                              
047520,000050: 
047521,000051: 26,3716           46020        RP-TO-R            STQ      BHIZ                                  
047522,000052: 26,3717           00050                                    RPREXIT                               
047523,000053: 26,3720           55733                                    RPTORA                                
047524,000054: 26,3721           77624                           CALL                                           #  COMPUTE M MATRIX FOR MOON
047525,000055: 26,3722           51720                                    MOONMX                                #  LP=LM FOR MOON  RADIANS B0
047526,000056: 26,3723           77775                           VLOAD                                          
047527,000057: 26,3724           02013                                    504LM                                 
047528,000058: 26,3725           53235        RPTORB             VXV      VAD                                   
047529,000059: 26,3726           00001                                    504RPR                                
047530,000060: 26,3727           00001                                    504RPR                                
047531,000061: 26,3730           52105                           VXM      GOTO                                  
047532,000062: 26,3731           00025                                    MMATRIX                               #  MPAC=R=MT(T)*(RP+LPXRP)
047533,000063: 26,3732           51706                                    RPRPXXXX                              #  RESET PUSHLOC TO 0 BEFORE EXITING
047534,000064: 26,3733           77624        RPTORA             CALL                                           #  EARTH COMPUTATIONS
047535,000065: 26,3734           55743                                    EARTHMX                               #  M MATRIX B-1
047536,000066: 26,3735           77624                           CALL                                           
047537,000067: 26,3736           15753                                    EARTHL                                #  L VECTOR RADIANS B0
047538,000068: 26,3737           76521                           MXV      VSL1                                  #  LP=M(T)*L  RAD B-0
047539,000069: 26,3740           00025                                    MMATRIX                               

Page 1141

047541,000071: 26,3741           77650                           GOTO                                           
047542,000072: 26,3742           55725                                    RPTORB                                
047543,000073: 24,2000                                           SETLOC   PLANTIN                               
047544,000074: 24,2000                                           BANK                                           
047545,000075: 24,3670                                           COUNT*   $$/LUROT                              
047546,000076: 

Page 1142

047548,000078:                                                                                                  #  ..... R-TO-RP SUBROUTINE .....
047549,000079:                                                                                                  #  SUBROUTINE TO CONVERT R (VECTOR IN REFERENCE COORD. SYSTEM) TO RP
047550,000080:                                                                                                  #  (VECTOR IN PLANETARY COORD SYSTEM) EITHER EARTH-FIXED OR MOON-FIXED
047551,000081: 
047552,000082:                                                                                                  #        RP = M(T) * (R - L X R)
047553,000083: 
047554,000084:                                                                                                  #  CALLING SEQUENCE
047555,000085:                                                                                                  #        L       CALL
047556,000086:                                                                                                  #        L+1             R-TO-RP
047557,000087: 
047558,000088:                                                                                                  #  SUBROUTINES USED
047559,000089:                                                                                                  #        EARTHMX, MOONMX, EARTHL
047560,000090: 
047561,000091:                                                                                                  #  INPUT
047562,000092:                                                                                                  #        MPAC = 0 FOR EARTH, NON-ZERO FOR MOON
047563,000093:                                                                                                  #        0-5D = R VECTOR
047564,000094:                                                                                                  #        6-7D = TIME
047565,000095: 
047566,000096:                                                                                                  #        ITEMS AVAILABLE FROM LAUNCH DATA
047567,000097:                                                                                                  #                504LM = THE LIBRATION VECTOR L OF THE MOON AT TIME TIMSUBL, EXPRESSED
047568,000098:                                                                                                  #                        IN THE MOON-FIXED COORD. SYSTEM   RADIANS B0
047569,000099: 
047570,000100:                                                                                                  #        ITEMS NECESSARY FOR SUBROUTINES USED (SEE DESCRIPTION OF SUBR.)
047571,000101: 
047572,000102:                                                                                                  #  OUTPUT
047573,000103:                                                                                                  #        MPAC = RP VECTOR METERS B-29 FOR EARTH, B-27 FOR MOON
047574,000104: 
047575,000105: 24,3670           46020        R-TO-RP            STQ      BHIZ                                  
047576,000106: 24,3671           00050                                    RPREXIT                               
047577,000107: 24,3672           51712                                    RTORPA                                
047578,000108: 24,3673           77624                           CALL                                           
047579,000109: 24,3674           51720                                    MOONMX                                
047580,000110: 24,3675           61375                           VLOAD    VXM                                   
047581,000111: 24,3676           02013                                    504LM                                 #  LP=LM
047582,000112: 24,3677           00025                                    MMATRIX                               
047583,000113: 24,3700           77772                           VSL1                                           #  L = MT(T)*LP          RADIANS B0
047584,000114: 24,3701           51235        RTORPB             VXV      BVSU                                  
047585,000115: 24,3702           00001                                    504RPR                                
047586,000116: 24,3703           00001                                    504RPR                                
047587,000117: 24,3704           77721                           MXV                                            #  M(T)*(R-LXR)          B-2
047588,000118: 24,3705           00025                                    MMATRIX                               
047589,000119: 24,3706           40372        RPRPXXXX           VSL1     SETPD                                 
047590,000120: 24,3707           00001                                    0D                                    
047591,000121: 24,3710           77650                           GOTO                                           
047592,000122: 24,3711           00050                                    RPREXIT                               
047593,000123: 24,3712           77624        RTORPA             CALL                                           #  EARTH COMPUTATIONS
047594,000124: 24,3713           55743                                    EARTHMX                               
047595,000125: 24,3714           77624                           CALL                                           
047596,000126: 24,3715           15753                                    EARTHL                                
047597,000127: 24,3716           77650                           GOTO                                           #  MPAC=L=(-AX,-AY,0)    RAD B-0
047598,000128: 24,3717           51701                                    RTORPB                                
047599,000129: 

Page 1143

047601,000131:                                                                                                  #  ..... MOONMX SUBROUTINE .....
047602,000132:                                                                                                  #  SUBROUTINE TO COMPUTE THE TRANSFORMATION MATRIX M FOR THE MOON
047603,000133: 
047604,000134:                                                                                                  #  CALLING SEQUENCE
047605,000135:                                                                                                  #        L       CALL
047606,000136:                                                                                                  #        L+1             MOONMX
047607,000137: 
047608,000138:                                                                                                  #  SUBROUTINES USED
047609,000139:                                                                                                  #        NEWANGLE
047610,000140: 
047611,000141:                                                                                                  #  INPUT
047612,000142:                                                                                                  #        6-7D = TIME
047613,000143: 
047614,000144:                                                                                                  #        ITEMS AVAILABLE FROM LAUNCH DATA
047615,000145:                                                                                                  #                BSUBO, BDOT
047616,000146:                                                                                                  #                TIMSUBO, NODIO, NODDOT, FSUBO, FDOT
047617,000147:                                                                                                  #                COSI = COS(I)   B-1
047618,000148:                                                                                                  #                SINI = SIN(I)   B-1
047619,000149:                                                                                                  #                  I IS THE ANGLE BETWEEN THE MEAN LUNAR EQUATORIAL PLANE AND THE
047620,000150:                                                                                                  #                  PLANE OF THE ECLIPTIC (1 DEGREE 32.1 MINUTES)
047621,000151: 
047622,000152:                                                                                                  #  OUTPUT
047623,000153:                                                                                                  #        MMATRIX = 3X3 M MATRIX B-1      (STORED IN VAC AREA)
047624,000154: 
047625,000155: 24,3720           40220        MOONMX             STQ      SETPD                                 
047626,000156: 24,3721           00051                                    EARTHMXX                              
047627,000157: 24,3722           00011                                    8D                                    
047628,000158: 24,3723           77770                           AXT,1                                          #  B REQUIRES SL 0, SL 5 IN NEWANGLE
047629,000159: 24,3724           00005                                    5                                     
047630,000160: 24,3725           65345                           DLOAD    PDDL                                  #  PD 10D        8-9D=BSUBO
047631,000161: 24,3726           14017                                    BSUBO                                 #                10-11D=BDOT
047632,000162: 24,3727           14011                                    BDOT                                  
047633,000163: 24,3730           45006                           PUSH     CALL                                  #  PD 12D
047634,000164: 24,3731           53743                                    NEWANGLE                              #  EXIT WITH PD 8D AND MPAC= B   REVS B0
047635,000165: 24,3732           71406                           PUSH     COS                                   #  PD 10D
047636,000166: 24,3733           14041                           STODL    COB                                   #  PD 8D         COS(B) B-1
047637,000167: 24,3734           77756                           SIN                                            #                SIN(B) B-1
047638,000168: 24,3735           14043                           STODL    SOB                                   #  SETUP INPUT FOR NEWANGLE
047639,000169: 24,3736           14015                                    FSUBO                                 #                        8-9D=FSUBO
047640,000170: 24,3737           41525                           PDDL     PUSH                                  #  PD 10D THEN 12D       10-11D=FDOT
047641,000171: 24,3740           14007                                    FDOT                                  
047642,000172: 24,3741           45170                           AXT,1    CALL                                  #  F REQUIRES SL 1, SL 6 IN NEWANGLE
047643,000173: 24,3742           00004                                    4                                     
047644,000174: 24,3743           53743                                    NEWANGLE                              #  EXIT WITH PD 8D AND MPAC= F REVS B0
047645,000175: 24,3744           14027                           STODL    AVECTR     +2                         #  SAVE F TEMP
047646,000176: 24,3745           14013                                    NODIO                                 #                        8-9D=NODIO
047647,000177: 24,3746           41525                           PDDL     PUSH                                  #  PD 10D THEN 12D       10-11D=NODDOT
047648,000178: 24,3747           14005                                    NODDOT                                #                        MPAC=T
047649,000179: 24,3750           45170                           AXT,1    CALL                                  #  NODE REQUIRES SL 0, SL 5 IN NEWANGLE
047650,000180: 24,3751           00005                                    5                                     
047651,000181: 24,3752           53743                                    NEWANGLE                              #  EXIT WITH PD 8D AND MPAC= NODI REVS B0

Page 1144

047653,000183: 24,3753           71406                           PUSH     COS                                   #  PD 10D        8-9D= NODI REVS B0
047654,000184: 24,3754           77606                           PUSH                                           #  PD 12D        10-11D= COS(NODI) B-1
047655,000185: 24,3755           00025                           STORE    AVECTR                                
047656,000186: 24,3756           76405                           DMP      SL1R                                  
047657,000187: 24,3757           00041                                    COB                                   #                         COS(NODI) B-1
047658,000188: 24,3760           14035                           STODL    BVECTR     +2                         #  PD 10D  20-25D=AVECTR= COB*SIN(NODI)
047659,000189: 24,3761           76405                           DMP      SL1R                                  #                         SOB*SIN(NODI)
047660,000190: 24,3762           00043                                    SOB                                   
047661,000191: 24,3763           14037                           STODL    BVECTR     +4                         #  PD 8D
047662,000192: 24,3764           41556                           SIN      PUSH                                  #  PD 10D                -SIN(NODI) B-1
047663,000193: 24,3765           77676                           DCOMP                                          #          26-31D=BVECTR= COB*COS(NODI)
047664,000194: 24,3766           14033                           STODL    BVECTR                                #  PD 8D                  SOB*COS(NODI)
047665,000195: 24,3767           00027                                    AVECTR     +2                         #  MOVE F FROM TEMP LOC. TO 504F
047666,000196: 24,3770           14007                           STODL    504F                                  
047667,000197: 24,3771           76405                           DMP      SL1R                                  
047668,000198: 24,3772           00041                                    COB                                   
047669,000199: 24,3773           77650                           GOTO                                           
047670,000200: 24,3774           53671                                    MOONMXA                               
047671,000201: 
047672,000202: 25,3671                                           BANK     25                                    
047673,000203: 25,2000                                           SETLOC   PLANTIN3                              
047674,000204: 25,2000                                           BANK                                           
047675,000205: 25,3671                                           COUNT*   $$/LUROT                              
047676,000206: 
047677,000207: 25,3671           14027        MOONMXA            STODL    AVECTR     +2                         
047678,000208: 25,3672           00011                                    SINNODI                               #  8-9D=SIN(NODI) B-1
047679,000209: 25,3673           76405                           DMP      SL1R                                  
047680,000210: 25,3674           00043                                    SOB                                   
047681,000211: 25,3675           14031                           STODL    AVECTR     +4                         #                         0
047682,000212: 25,3676           06522                                    HI6ZEROS                              #        8-13D= CVECTR= -SOB  B-1
047683,000213: 25,3677           57525                           PDDL     DCOMP                                 #  PD 10D                COB
047684,000214: 25,3700           00043                                    SOB                                   
047685,000215: 25,3701           63325                           PDDL     PDVL                                  #  PD 12D THEN PD 14D
047686,000216: 25,3702           00041                                    COB                                   
047687,000217: 25,3703           00033                                    BVECTR                                
047688,000218: 25,3704           63361                           VXSC     PDVL                                  #  PD 20D        BVECTR*SINI  B-2
047689,000219: 25,3705           14003                                    SINI                                  
047690,000220: 25,3706           00011                                    CVECTR                                
047691,000221: 25,3707           53361                           VXSC     VAD                                   #  PD 14D        CVECTR*COSI  B-2
047692,000222: 25,3710           14001                                    COSI                                  
047693,000223: 25,3711           77772                           VSL1                                           
047694,000224: 25,3712           24041                           STOVL    MMATRIX    +12D                       #  PD 8D  M2=BVECTR*SINI+CVECTR*COSI  B-1
047695,000225: 25,3713           63361                           VXSC     PDVL                                  #  PD 14D
047696,000226: 25,3714           14003                                    SINI                                  #                CVECTR*SINI  B-2
047697,000227: 25,3715           00033                                    BVECTR                                
047698,000228: 25,3716           52361                           VXSC     VSU                                   #  PD 8D         BVECTR*COSI  B-2
047699,000229: 25,3717           14001                                    COSI                                  
047700,000230: 25,3720           65372                           VSL1     PDDL                                  #  PD 14D
047701,000231: 25,3721           00007                                    504F                                  #  8-13D=DVECTR=BVECTR*COSI-CVECTR*SINI  B-1
047702,000232: 25,3722           74346                           COS      VXSC                                  

Page 1145

047704,000234: 25,3723           00011                                    DVECTR                                
047705,000235: 25,3724           73525                           PDDL     SIN                                   #  PD 20D  14-19D= DVECTR*COSF  B-2
047706,000236: 25,3725           00007                                    504F                                  
047707,000237: 25,3726           52361                           VXSC     VSU                                   #  PD 14D          AVECTR*SINF  B-2
047708,000238: 25,3727           00025                                    AVECTR                                
047709,000239: 25,3730           77772                           VSL1                                           
047710,000240: 25,3731           14033                           STODL    MMATRIX    +6                         #  M1= AVECTR*SINF-DVECTR*COSF  B-1
047711,000241: 25,3732           00007                                    504F                                  
047712,000242: 25,3733           74356                           SIN      VXSC                                  #  PD 8D
047713,000243: 25,3734           71525                           PDDL     COS                                   #  PD 14D  8-13D=DVECTR*SINF B-2
047714,000244: 25,3735           00007                                    504F                                  
047715,000245: 25,3736           53361                           VXSC     VAD                                   #  PD 8D         AVECTR*COSF B-2
047716,000246: 25,3737           00025                                    AVECTR                                
047717,000247: 25,3740           57572                           VSL1     VCOMP                                 
047718,000248: 25,3741           34025                           STCALL   MMATRIX                               #  M0= -(AVECTR*COSF+DVECTR*SINF)  B-1
047719,000249: 25,3742           00051                                    EARTHMXX                              
047720,000250: 
047721,000251:                                                                                                  #  COMPUTE X=X0+(XDOT)(T+T0)
047722,000252:                                                                                                  #  8-9D= XO (REVS B-0), PUSHLOC SET AT 12D
047723,000253:                                                                                                  #  10-11D=XDOT (REVS/CSEC) SCALED B+23 FOR WEARTH,B+28 FOR NODDOT AND BDOT
047724,000254:                                                                                                  #                        AND B+27 FOR FDOT
047725,000255:                                                                                                  #   X1=DIFFERENCE IN 23 AND SCALING OF XDOT, =0 FOR WEARTH, 5 FOR NODDOT AND
047726,000256:                                                                                                  #                                        BDOT AND 4 FOR FDOT
047727,000257:                                                                                                  #  6-7D=T (CSEC B-28), TIMSUBO= (CSEC B-42 TRIPLE PREC.)
047728,000258: 
047729,000259: 25,3743           54345        NEWANGLE           DLOAD    SR                                    #  ENTER PD 12D
047730,000260: 25,3744           00007                                    6D                                    
047731,000261: 25,3745           20617                                    14D                                   
047732,000262: 25,3746           72371                           TAD      TLOAD                                 #  CHANGE MODE TO TP
047733,000263: 25,3747           01707                                    TIMSUBO                               
047734,000264: 25,3750           00155                                    MPAC                                  
047735,000265: 25,3751           14017                           STODL    TIMSUBM                               #  T+T0 CSEC B-42
047736,000266: 25,3752           00020                                    TIMSUBM    +1                         
047737,000267: 25,3753           77605                           DMP                                            #  PD 10D        MULT BY XDOT IN 10-11D
047738,000268: 25,3754           43257                           SL*      DAD                                   #  PD 8D         ADD XO IN 8-9D AFTER SHIFTING
047739,000269: 25,3755           20206                                    5,1                                   #                SUCH THAT SCALING IS B-0
047740,000270: 25,3756           67206                           PUSH     SLOAD                                 #  PD 10D  SAVE PARTIAL (X0+XDOT*T) IN 8-9D
047741,000271: 25,3757           00017                                    TIMSUBM                               
047742,000272: 25,3760           41261                           SL       DMP                                   
047743,000273: 25,3761           20212                                    9D                                    
047744,000274: 25,3762           00013                                    10D                                   #  XDOT
047745,000275: 25,3763           43257                           SL*      DAD                                   #  PD 8D         SHIFT SUCH THAT THIS PART OF X
047746,000276: 25,3764           20213                                    10D,1                                 #                IS SCALED REVS/CSEC B-0
047747,000277: 25,3765           77600                           BOV                                            #  TURN OFF OVERFLOW IF SET BY SHIFT
047748,000278: 25,3766           53767                                    +1                                    #  INSTRUCTION BEFORE EXITING
047749,000279: 25,3767           77616                           RVQ                                            #  MPAC=X= X0+(XDOT)(T+T0)  REVS B0
047750,000280: 

Page 1146

047752,000282:                                                                                                  #  ..... EARTHMX SUBROUTINE .....
047753,000283:                                                                                                  #  SUBROUTINE TO COMPUTE THE TRANSFORMATION MATRIX M FOR THE EARTH
047754,000284: 
047755,000285:                                                                                                  #  CALLING SEQUENCE
047756,000286:                                                                                                  #        L       CALL
047757,000287:                                                                                                  #        L+1             EARTHMX
047758,000288: 
047759,000289:                                                                                                  #  SUBROUTINES USED
047760,000290:                                                                                                  #        NEWANGLE
047761,000291: 
047762,000292:                                                                                                  #  INPUT
047763,000293:                                                                                                  #        INPUT AVAILABLE FROM LAUNCH DATA        AZO  REVS B-0
047764,000294:                                                                                                  #                                                TEPHEM  CSEC B-42
047765,000295:                                                                                                  #        6-7D= TIME CSEC B-28
047766,000296: 
047767,000297:                                                                                                  #  OUTPUT
047768,000298:                                                                                                  #        MMATRIX= 3X3 M MATRIX B-1       (STORED IN VAC AREA)
047769,000299: 
047770,000300: 26,3743                                           BANK     26                                    
047771,000301: 26,2000                                           SETLOC   PLANTIN1                              
047772,000302: 26,2000                                           BANK                                           
047773,000303: 26,3743                                           COUNT*   $$/LUROT                              
047774,000304: 
047775,000305: 26,3743           40220        EARTHMX            STQ      SETPD                                 #  SET 8-9D=AZO
047776,000306: 26,3744           00051                                    EARTHMXX                              
047777,000307: 26,3745           00011                                    8D                                    #  10-11D=WEARTH
047778,000308: 26,3746           77770                           AXT,1                                          #  FOR SL 5, AND SL 10 IN NEWANGLE
047779,000309: 26,3747           00000                                    0                                     
047780,000310: 26,3750           65345                           DLOAD    PDDL                                  #  LEAVING PD SET AT 12D FOR NEWANGLE
047781,000311: 26,3751           01712                                    AZO                                   
047782,000312: 26,3752           14021                                    WEARTH                                
047783,000313: 26,3753           45006                           PUSH     CALL                                  
047784,000314: 26,3754           53743                                    NEWANGLE                              
047785,000315: 26,3755           41401                           SETPD    PUSH                                  #  18-19D=504AZ
047786,000316: 26,3756           00023                                    18D                                   #                         COS(AZ)   SIN(AZ)     0
047787,000317: 26,3757           65346                           COS      PDDL                                  #  20-37D=  MMATRIX=     -SIN(AZ)   COS(AZ)     0    B-1
047788,000318: 26,3760           00023                                    504AZ                                 #                            0         0        1
047789,000319: 26,3761           65356                           SIN      PDDL                                  
047790,000320: 26,3762           06522                                    HI6ZEROS                              
047791,000321: 26,3763           73525                           PDDL     SIN                                   
047792,000322: 26,3764           00023                                    504AZ                                 
047793,000323: 26,3765           65276                           DCOMP    PDDL                                  
047794,000324: 26,3766           00023                                    504AZ                                 
047795,000325: 26,3767           63346                           COS      PDVL                                  
047796,000326: 26,3770           06522                                    HI6ZEROS                              
047797,000327: 26,3771           41525                           PDDL     PUSH                                  
047798,000328: 26,3772           06520                                    HIDPHALF                              
047799,000329: 26,3773           77650                           GOTO                                           
047800,000330: 26,3774           00051                                    EARTHMXX                              
047801,000331: 

Page 1147

047803,000333:                                                                                                  #  ..... EARTHL SUBROUTINE .....
047804,000334:                                                                                                  #  SUBROUTINE TO COMPUTE L VECTOR FOR EARTH
047805,000335: 
047806,000336:                                                                                                  #  CALLING SEQUENCE
047807,000337:                                                                                                  #        L       CALL
047808,000338:                                                                                                  #        L+1             EARTHL
047809,000339: 
047810,000340:                                                                                                  #  INPUT
047811,000341:                                                                                                  #        AXO,AYO SET AT LAUNCH TIME WITH AYO IMMEDIATELY FOLLOWING AXO IN CORE
047812,000342: 
047813,000343:                                                                                                  #  OUTPUT
047814,000344:                                                                                                  #                -AX
047815,000345:                                                                                                  #        MPAC=   -AY     RADIANS B-0
047816,000346:                                                                                                  #                  0
047817,000347: 
047818,000348: 06,3753                                           BANK     06                                    
047819,000349: 06,2000                                           SETLOC   EARTHLOC                              
047820,000350: 06,2000                                           BANK                                           
047821,000351: 06,3753                                           COUNT*   $$/LUROT                              
047822,000352: 
047823,000353: 06,3753           57545        EARTHL             DLOAD    DCOMP                                 
047824,000354: 06,3754           01716                                    AXO                                   
047825,000355: 06,3755           14017                           STODL    504LPL                                
047826,000356: 06,3756           01714                                    -AYO                                  
047827,000357: 06,3757           14021                           STODL    504LPL     +2                         
047828,000358: 06,3760           24007                                    LO6ZEROS                              
047829,000359: 06,3761           24023                           STOVL    504LPL     +4                         
047830,000360: 06,3762           00017                                    504LPL                                
047831,000361: 06,3763           77616                           RVQ                                            
047832,000362: 

Page 1148

047834,000364:                                                                                                  #  CONSTANTS AND ERASABLE ASSIGNMENTS
047835,000365: 
047836,000366: 06,3764  12,2004               1B1                =        DP1/2                                 #  1  SCALED B-1
047837,000367: 06,3764  0000050               RPREXIT            =        S1                                    #  R-TO-RP AND RP-TO-R SUBR EXIT
047838,000368: 06,3764  0000051               EARTHMXX           =        S2                                    #  EARTHMX, MOONMX SUBR. EXITS
047839,000369: 06,3764                        504RPR             =        0D                                    #  6 REGS        R OR RP VECTOR
047840,000370: 06,3764                        SINNODI            =        8D                                    #  2             SIN(NODI)
047841,000371: 06,3764                        DVECTR             =        8D                                    #  6             D VECTOR MOON
047842,000372: 06,3764                        CVECTR             =        8D                                    #  6             C VECTR MOON
047843,000373: 06,3764                        504AZ              =        18D                                   #  2             AZ
047844,000374: 06,3764                        TIMSUBM            =        14D                                   #  3             TIME SUB M (MOON) T+T0 IN GETAZ
047845,000375: 06,3764                        504LPL             =        14D                                   #  6             L OR LP VECTOR
047846,000376: 06,3764                        AVECTR             =        20D                                   #  6             A VECTOR (MOON)
047847,000377: 06,3764                        BVECTR             =        26D                                   #  6             B VECTOR (MOON)
047848,000378: 06,3764                        MMATRIX            =        20D                                   #  18            M MATRIX
047849,000379: 06,3764                        COB                =        32D                                   #  2             COS(B) B-1
047850,000380: 06,3764                        SOB                =        34D                                   #  2             SIN(B) B-1
047851,000381: 06,3764                        504F               =        6D                                    #  2             F(MOON)
047852,000382: 

End of include-file PLANETARY_INERTIAL_ORIENTATION.agc.  Parent file is MAIN.agc