Source Code

These source-code files are part of a reconstructed copy of Luminary 173, the second (unflown) release of the Apollo 14 Lunar Module (LM) Apollo Guidance Computer (AGC) software.

The reconstruction began with reconstructed source code for Luminary 178. Changes between revision 173 and 178 were backed out, as described by Luminary memo 167 (revision 1). The reconstruction was verified by matching memory-bank checksums to those listed in drawing 2021152N. Note that page numbers in the reconstructed code match those for the baseline log section mentioned in each file's changelog; the page numbers for a real Luminary 173 listing would be different.

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.

047948,000002:                                                                                                  ## Copyright:   Public domain.
047949,000003:                                                                                                  ## Filename:    PLANETARY_INERTIAL_ORIENTATION.agc
047950,000004:                                                                                                  ## Purpose:     A section of Luminary revision 173.
047951,000005:                                                                                                  ##              It is part of the reconstructed source code for the second
047952,000006:                                                                                                  ##              (unflown) release of the flight software for the Lunar
047953,000007:                                                                                                  ##              Module's (LM) Apollo Guidance Computer (AGC) for Apollo 14.
047954,000008:                                                                                                  ##              The code has been recreated from a reconstructed copy of
047955,000009:                                                                                                  ##              Luminary 178, as well as Luminary memo 167 (revision 1).
047956,000010:                                                                                                  ##              It has been adapted such that the resulting bugger words
047957,000011:                                                                                                  ##              exactly match those specified for Luminary 173 in NASA
047958,000012:                                                                                                  ##              drawing 2021152N, which gives relatively high confidence
047959,000013:                                                                                                  ##              that the reconstruction is correct.
047960,000014:                                                                                                  ## Reference:   pp. 1131-1139
047961,000015:                                                                                                  ## Assembler:   yaYUL
047962,000016:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
047963,000017:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
047964,000018:                                                                                                  ## Mod history: 2019-09-18 MAS  Created from Luminary 178.
047965,000019: 

Page 1131

047967,000021:                                                                                                  #  ..... RP-TO-R SUBROUTINE .....
047968,000022:                                                                                                  #  SUBROUTINE TO CONVERT RP (VECTOR IN PLANETARY COORDINATE SYSTEM,EITHER
047969,000023:                                                                                                  #   EARTH-FIXED OR MOON-FIXED) TO R (SAME VECTOR IN THE BASIC REF. SYSTEM)
047970,000024: 
047971,000025:                                                                                                  #   R=MT(T)*(RP+LPXRP)    MT = M MATRIX TRANSPOSE
047972,000026: 
047973,000027:                                                                                                  #  CALLING SEQUENCE
047974,000028:                                                                                                  #   L       CALL
047975,000029:                                                                                                  #   L+1            RP-TO-R
047976,000030: 
047977,000031:                                                                                                  #  SUBROUTINES USED
047978,000032:                                                                                                  #   EARTHMX,MOONMX,EARTHL
047979,000033: 
047980,000034:                                                                                                  #     ITEMS AVAILABLE FROM LAUNCH DATA
047981,000035:                                                                                                  #      504LM= THE LIBRATION VECTOR L OF THE MOON AT TIME TIMSUBL,EXPRESSED
047982,000036:                                                                                                  #      IN THE MOON-FIXED COORD. SYSTEM   RADIANS  B0
047983,000037:                                                                                                  #        ITEMS NECESSARY FOR SUBR. USED (SEE DESCRIPTION OF SUBR.)
047984,000038: 
047985,000039:                                                                                                  #  INPUT
047986,000040:                                                                                                  #   MPAC= 0 FOR EARTH,NON-ZERO FOR MOON
047987,000041:                                                                                                  #   0-5D= RP VECTOR
047988,000042:                                                                                                  #   6-7D= TIME
047989,000043: 
047990,000044:                                                                                                  #  OUTPUT
047991,000045:                                                                                                  #   MPAC= R VECTOR METERS B-29 FOR EARTH, B-27 FOR MOON
047992,000046: 
047993,000047: 26,2000                                           SETLOC   PLANTIN1                              
047994,000048: 26,2000                                           BANK                                           
047995,000049: 
047996,000050: 26,3720                                           COUNT*   $$/LUROT                              
047997,000051: 
047998,000052: 26,3720           46020        RP-TO-R            STQ      BHIZ                                  
047999,000053: 26,3721           00050                                    RPREXIT                               
048000,000054: 26,3722           55735                                    RPTORA                                
048001,000055: 26,3723           77624                           CALL                                           #  COMPUTE M MATRIX FOR MOON
048002,000056: 26,3724           51672                                    MOONMX                                #  LP=LM FOR MOON  RADIANS B0
048003,000057: 26,3725           77775                           VLOAD                                          
048004,000058: 26,3726           02013                                    504LM                                 
048005,000059: 26,3727           53235        RPTORB             VXV      VAD                                   
048006,000060: 26,3730           00001                                    504RPR                                
048007,000061: 26,3731           00001                                    504RPR                                
048008,000062: 26,3732           52105                           VXM      GOTO                                  
048009,000063: 26,3733           00025                                    MMATRIX                               #  MPAC=R=MT(T)*(RP+LPXRP)
048010,000064: 26,3734           51660                                    RPRPXXXX                              #  RESET PUSHLOC TO 0 BEFORE EXITING
048011,000065: 26,3735           77624        RPTORA             CALL                                           #  EARTH COMPUTATIONS
048012,000066: 26,3736           55745                                    EARTHMX                               #  M MATRIX B-1
048013,000067: 26,3737           77624                           CALL                                           
048014,000068: 26,3740           15761                                    EARTHL                                #  L VECTOR RADIANS B0
048015,000069: 26,3741           76521                           MXV      VSL1                                  #  LP=M(T)*L  RAD B-0
048016,000070: 26,3742           00025                                    MMATRIX                               

Page 1132

048018,000072: 26,3743           77650                           GOTO                                           
048019,000073: 26,3744           55727                                    RPTORB                                
048020,000074: 24,2000                                           SETLOC   PLANTIN                               
048021,000075: 24,2000                                           BANK                                           
048022,000076: 24,3642                                           COUNT*   $$/LUROT                              
048023,000077: 

Page 1133

048025,000079:                                                                                                  #  ..... R-TO-RP SUBROUTINE .....
048026,000080:                                                                                                  #  SUBROUTINE TO CONVERT R (VECTOR IN REFERENCE COORD. SYSTEM) TO RP
048027,000081:                                                                                                  #   (VECTOR IN PLANETARY COORD SYSTEM) EITHER EARTH-FIXED OR MOON-FIXED
048028,000082: 
048029,000083:                                                                                                  #   RP=M(T)*(R-LXR)
048030,000084: 
048031,000085:                                                                                                  #  CALLING SEQUENCE
048032,000086:                                                                                                  #   L       CALL
048033,000087:                                                                                                  #   L+1            R-TO-RP
048034,000088: 
048035,000089:                                                                                                  #  SUBROUTINES USED
048036,000090:                                                                                                  #   EARTHMX,MOONMX,EARTHL
048037,000091: 
048038,000092:                                                                                                  #  INPUT
048039,000093:                                                                                                  #   MPAC= 0 FOR EARTH,NON-ZERO FOR MOON
048040,000094:                                                                                                  #   0-5D= R VECTOR
048041,000095:                                                                                                  #   6-7D= TIME
048042,000096: 
048043,000097:                                                                                                  #     ITEMS AVAILABLE FROM LAUNCH DATA
048044,000098:                                                                                                  #      504LM= THE LIBRATION VECTOR L OF THE MOON AT TIME TIMSUBL,EXPRESSED
048045,000099:                                                                                                  #      IN THE MOON-FIXED COORD. SYSTEM   RADIANS B0
048046,000100:                                                                                                  #        ITEMS NECESSARY FOR SUBROUTINES USED (SEE DESCRIPTION OF SUBR.)
048047,000101: 
048048,000102:                                                                                                  #  OUTPUT
048049,000103:                                                                                                  #   MPAC=RP VECTOR METERS B-29 FOR EARTH, B-27 FOR MOON
048050,000104: 
048051,000105: 24,3642           46020        R-TO-RP            STQ      BHIZ                                  
048052,000106: 24,3643           00050                                    RPREXIT                               
048053,000107: 24,3644           51664                                    RTORPA                                
048054,000108: 24,3645           77624                           CALL                                           
048055,000109: 24,3646           51672                                    MOONMX                                
048056,000110: 24,3647           61375                           VLOAD    VXM                                   
048057,000111: 24,3650           02013                                    504LM                                 #  LP=LM
048058,000112: 24,3651           00025                                    MMATRIX                               
048059,000113: 24,3652           77772                           VSL1                                           #   L=MT(T)*LP  RADIANS B0
048060,000114: 24,3653           51235        RTORPB             VXV      BVSU                                  
048061,000115: 24,3654           00001                                    504RPR                                
048062,000116: 24,3655           00001                                    504RPR                                
048063,000117: 24,3656           77721                           MXV                                            #  M(T)*(R-LXR) B-2
048064,000118: 24,3657           00025                                    MMATRIX                               
048065,000119: 24,3660           40372        RPRPXXXX           VSL1     SETPD                                 
048066,000120: 24,3661           00001                                    0D                                    
048067,000121: 24,3662           77650                           GOTO                                           
048068,000122: 24,3663           00050                                    RPREXIT                               
048069,000123: 24,3664           77624        RTORPA             CALL                                           #  EARTH COMPUTATIONS
048070,000124: 24,3665           55745                                    EARTHMX                               
048071,000125: 24,3666           77624                           CALL                                           
048072,000126: 24,3667           15761                                    EARTHL                                
048073,000127: 24,3670           77650                           GOTO                                           #  MPAC=L=(-AX,-AY,0) RAD B-0
048074,000128: 24,3671           51653                                    RTORPB                                
048075,000129: 

Page 1134

048077,000131:                                                                                                  #  ..... MOONMX SUBROUTINE .....
048078,000132:                                                                                                  #  SUBROUTINE TO COMPUTE THE TRANSFORMATION MATRIX M FOR THE MOON
048079,000133: 
048080,000134:                                                                                                  #  CALLING SEQUENCE
048081,000135:                                                                                                  #   L       CALL
048082,000136:                                                                                                  #   L+1            MOONMX
048083,000137: 
048084,000138:                                                                                                  #  SUBROUTINES USED
048085,000139:                                                                                                  #   NEWANGLE
048086,000140: 
048087,000141:                                                                                                  #  INPUT
048088,000142:                                                                                                  #   6-7D= TIME
048089,000143:                                                                                                  #     ITEMS AVAILABLE FROM LAUNCH DATA
048090,000144:                                                                                                  #      BSUBO,BDOT
048091,000145:                                                                                                  #      TIMSUBO,NODIO,NODDOT,FSUBO,FDOT
048092,000146:                                                                                                  #      COSI= COS(I) B-1
048093,000147:                                                                                                  #      SINI= SIN(I) B-1
048094,000148:                                                                                                  #        I  IS THE ANGLE BETWEEN THE MEAN LUNAR EQUATORIAL PLANE AND THE
048095,000149:                                                                                                  #        PLANE OF THE ECLIPTIC  (1 DEGREE  32.1 MINUTES)
048096,000150: 
048097,000151:                                                                                                  #  OUTPUT
048098,000152:                                                                                                  #   MMATRIX= 3X3 M MATRIX B-1   (STORED IN VAC AREA)
048099,000153: 
048100,000154: 24,3672           40220        MOONMX             STQ      SETPD                                 
048101,000155: 24,3673           00051                                    EARTHMXX                              
048102,000156: 24,3674           00011                                    8D                                    
048103,000157: 24,3675           77770                           AXT,1                                          #  B REQUIRES SL 0, SL 5 IN NEWANGLE
048104,000158: 24,3676           00005                                    5                                     
048105,000159: 24,3677           65345                           DLOAD    PDDL                                  #  PD 10D            8-9D=BSUBO
048106,000160: 24,3700           14017                                    BSUBO                                 #                    10-11D= BDOT
048107,000161: 24,3701           14011                                    BDOT                                  
048108,000162: 24,3702           45006                           PUSH     CALL                                  #  PD 12D
048109,000163: 24,3703           51741                                    NEWANGLE                              #  EXIT WITH PD 8D AND MPAC= B  REVS B0
048110,000164: 24,3704           71406                           PUSH     COS                                   #  PD 10D
048111,000165: 24,3705           14041                           STODL    COB                                   #  PD 8D    COS(B) B-1
048112,000166: 24,3706           77756                           SIN                                            #           SIN(B) B-1
048113,000167: 24,3707           14043                           STODL    SOB                                   #            SETUP INPUT FOR NEWANGLE
048114,000168: 24,3710           14015                                    FSUBO                                 #                      8-9D=FSUBO
048115,000169: 24,3711           41525                           PDDL     PUSH                                  #  PD 10D THEN 12D   10-11D=FDOT
048116,000170: 24,3712           14007                                    FDOT                                  
048117,000171: 24,3713           45170                           AXT,1    CALL                                  #  F REQUIRES SL 1, SL 6 IN NEWANGLE
048118,000172: 24,3714           00004                                    4                                     
048119,000173: 24,3715           51741                                    NEWANGLE                              #  EXIT WITH PD 8D AND MPAC= F REVS B0
048120,000174: 24,3716           14027                           STODL    AVECTR     +2                         #  SAVE F TEMP
048121,000175: 24,3717           14013                                    NODIO                                 #                      8-9D=NODIO
048122,000176: 24,3720           41525                           PDDL     PUSH                                  #  PD 10D THEN 12D   10-11D=NODDOT
048123,000177: 24,3721           14005                                    NODDOT                                #                      MPAC=T
048124,000178: 24,3722           45170                           AXT,1    CALL                                  #  NODE REQUIRES SL 0, SL 5 IN NEWANGLE
048125,000179: 24,3723           00005                                    5                                     
048126,000180: 24,3724           51741                                    NEWANGLE                              #  EXIT WITH PD 8D AND MPAC= NODI REVS B0

Page 1135

048128,000182: 24,3725           71406                           PUSH     COS                                   #  PD 10D   8-9D= NODI  REVS  B0
048129,000183: 24,3726           77606                           PUSH                                           #  PD 12D 10-11D= COS(NODI)  B-1
048130,000184: 24,3727           00025                           STORE    AVECTR                                
048131,000185: 24,3730           76405                           DMP      SL1R                                  
048132,000186: 24,3731           00041                                    COB                                   #                          COS(NODI)    B-1
048133,000187: 24,3732           14035                           STODL    BVECTR     +2                         #  PD 10D   20-25D=AVECTR= COB*SIN(NODI)
048134,000188: 24,3733           76405                           DMP      SL1R                                  #                          SOB*SIN(NODI)
048135,000189: 24,3734           00043                                    SOB                                   
048136,000190: 24,3735           14037                           STODL    BVECTR     +4                         #  PD 8D
048137,000191: 24,3736           41556                           SIN      PUSH                                  #  PD 10D                 -SIN(NODI)   B-1
048138,000192: 24,3737           52076                           DCOMP    GOTO                                  #           26-31D=BVECTR= COV*COS(NODI)
048139,000193: 24,3740           53703                                    MOONMXA                               
048140,000194: 25,3703                                           BANK     25                                    
048141,000195: 25,2000                                           SETLOC   PLANTIN3                              
048142,000196: 25,2000                                           BANK                                           
048143,000197: 25,3703                                           COUNT*   $$/LUROT                              
048144,000198: 
048145,000199: 25,3703           14033        MOONMXA            STODL    BVECTR                                #  PD 8D                    SOB*COS(NODI)
048146,000200: 25,3704           00027                                    AVECTR     +2                         #  MOVE F FROM TEMP LOC. TO 504F
048147,000201: 25,3705           14007                           STODL    504F                                  
048148,000202: 25,3706           76405                           DMP      SL1R                                  
048149,000203: 25,3707           00041                                    COB                                   
048150,000204: 25,3710           14027                           STODL    AVECTR     +2                         
048151,000205: 25,3711           00011                                    SINNODI                               #  8-9D=SIN(NODI)  B-1
048152,000206: 25,3712           76405                           DMP      SL1R                                  
048153,000207: 25,3713           00043                                    SOB                                   
048154,000208: 25,3714           14031                           STODL    AVECTR     +4                         #                           0
048155,000209: 25,3715           06520                                    HI6ZEROS                              #          8-13D= CVECTR= -SOB  B-1
048156,000210: 25,3716           57525                           PDDL     DCOMP                                 #  PD 10D                  COB
048157,000211: 25,3717           00043                                    SOB                                   
048158,000212: 25,3720           63325                           PDDL     PDVL                                  #  PD 12D THEN PD 14D
048159,000213: 25,3721           00041                                    COB                                   
048160,000214: 25,3722           00033                                    BVECTR                                
048161,000215: 25,3723           63361                           VXSC     PDVL                                  #  PD 20D         BVECTR*SINI  B-2
048162,000216: 25,3724           14003                                    SINI                                  
048163,000217: 25,3725           00011                                    CVECTR                                
048164,000218: 25,3726           53361                           VXSC     VAD                                   #  PD 14D         CVECTR*COSI  B-2
048165,000219: 25,3727           14001                                    COSI                                  
048166,000220: 25,3730           77772                           VSL1                                           
048167,000221: 25,3731           24041                           STOVL    MMATRIX    +12D                       #  PD 8D  M2=BVECTR*SINI+CVECTR*COSI  B-1
048168,000222: 25,3732           63361                           VXSC     PDVL                                  #  PD 14D
048169,000223: 25,3733           14003                                    SINI                                  #                 CVECTR*SINI  B-2
048170,000224: 25,3734           00033                                    BVECTR                                
048171,000225: 25,3735           52361                           VXSC     VSU                                   #  PD 8D          BVECTR*COSI  B-2
048172,000226: 25,3736           14001                                    COSI                                  
048173,000227: 25,3737           65372                           VSL1     PDDL                                  #  PD 14D
048174,000228: 25,3740           00007                                    504F                                  #  8-13D=DVECTR=BVECTR*COSI-CVECTR*SINI B-1
048175,000229: 25,3741           74346                           COS      VXSC                                  
048176,000230: 25,3742           00011                                    DVECTR                                
048177,000231: 25,3743           73525                           PDDL     SIN                                   #  PD 20D  14-19D= DVECTR*COSF  B-2

Page 1136

048179,000233: 25,3744           00007                                    504F                                  
048180,000234: 25,3745           52361                           VXSC     VSU                                   #  PD 14D          AVECTR*SINF  B-2
048181,000235: 25,3746           00025                                    AVECTR                                
048182,000236: 25,3747           77772                           VSL1                                           
048183,000237: 25,3750           14033                           STODL    MMATRIX    +6                         #  M1= AVECTR*SINF-DVECTR*COSF  B-1
048184,000238: 25,3751           00007                                    504F                                  
048185,000239: 25,3752           74356                           SIN      VXSC                                  #  PD 8D
048186,000240: 25,3753           71525                           PDDL     COS                                   #  PD 14D  8-13D=DVECTR*SINF B-2
048187,000241: 25,3754           00007                                    504F                                  
048188,000242: 25,3755           53361                           VXSC     VAD                                   #  PD 8D         AVECTR*COSF B-2
048189,000243: 25,3756           00025                                    AVECTR                                
048190,000244: 25,3757           57572                           VSL1     VCOMP                                 
048191,000245: 25,3760           34025                           STCALL   MMATRIX                               #  M0= -(AVECTR*COSF+DVECTR*SINF)  B-1
048192,000246: 25,3761           00051                                    EARTHMXX                              
048193,000247:                                                                                                  #  COMPUTE X=X0+(XDOT)(T+T0)
048194,000248:                                                                                                  #  8-9D= XO (REVS B-0),PUSHLOC SET AT 12D
048195,000249:                                                                                                  #  10-11D=XDOT (REVS/CSEC) SCALED B+23 FOR WEARTH,B+28 FOR NODDOT AND BDOT
048196,000250:                                                                                                  #                          AND B+27 FOR FDOT
048197,000251:                                                                                                  #   X1=DIFFERENCE IN 23 AND SCALING OF XDOT,=0 FOR WEARTH,5 FOR NODDOT AND
048198,000252:                                                                                                  #                                           BDOT AND 4 FOR FDOT
048199,000253:                                                                                                  #  6-7D=T (CSEC B-28), TIMSUBO= (CSEC B-42 TRIPLE PREC.)
048200,000254: 
048201,000255: 24,3741                                           BANK     24                                    
048202,000256: 24,2000                                           SETLOC   PLANTIN                               
048203,000257: 24,2000                                           BANK                                           
048204,000258: 
048205,000259: 24,3741           54345        NEWANGLE           DLOAD    SR                                    #  ENTER PD 12D
048206,000260: 24,3742           00007                                    6D                                    
048207,000261: 24,3743           20617                                    14D                                   
048208,000262: 24,3744           72371                           TAD      TLOAD                                 #  CHANGE MODE TO TP
048209,000263: 24,3745           01707                                    TIMSUBO                               
048210,000264: 24,3746           00155                                    MPAC                                  
048211,000265: 24,3747           14017                           STODL    TIMSUBM                               #  T+T0 CSEC B-42
048212,000266: 24,3750           00020                                    TIMSUBM    +1                         
048213,000267: 24,3751           77605                           DMP                                            #  PD 10D  MULT BY XDOT IN 10-11D
048214,000268: 24,3752           43257                           SL*      DAD                                   #  PD 8D   ADD XO IN 8-9D AFTER SHIFTING
048215,000269: 24,3753           20206                                    5,1                                   #          SUCH THAT SCALING IS B-0
048216,000270: 24,3754           67206                           PUSH     SLOAD                                 #  PD 10D SAVE PARTIAL (X0+XDOT*T) IN 8-9D
048217,000271: 24,3755           00017                                    TIMSUBM                               
048218,000272: 24,3756           41261                           SL       DMP                                   
048219,000273: 24,3757           20212                                    9D                                    
048220,000274: 24,3760           00013                                    10D                                   #  XDOT
048221,000275: 24,3761           43257                           SL*      DAD                                   #  PD 8D   SHIFT SUCH THAT THIS PART OF X
048222,000276: 24,3762           20213                                    10D,1                                 #          IS SCALED REVS/CSEC B-0
048223,000277: 24,3763           77600                           BOV                                            #  TURN OFF OVERFLOW IF SET BY SHIFT
048224,000278: 24,3764           51765                                    +1                                    #  INSTRUCTION BEFORE EXITING
048225,000279: 24,3765           77616                           RVQ                                            #  MPAC=X= X0+(XDOT)(T+T0)  REVS B0
048226,000280: 

Page 1137

048228,000282:                                                                                                  #  ..... EARTHMX SUBROUTINE .....
048229,000283:                                                                                                  #  SUBROUTINE TO COMPUTE THE TRANSFORMATION MATRIX M FOR THE EARTH
048230,000284: 
048231,000285:                                                                                                  #  CALLING SEQUENCE
048232,000286:                                                                                                  #   L       CALL
048233,000287:                                                                                                  #   L+1            EARTHMX
048234,000288: 
048235,000289:                                                                                                  #  SUBROUTINES USED
048236,000290:                                                                                                  #   NEWANGLE
048237,000291: 
048238,000292:                                                                                                  #  INPUT
048239,000293:                                                                                                  #     INPUT AVAILABLE FROM LAUNCH DATA     AZO  REVS B-0
048240,000294:                                                                                                  #                                          TEPHEM  CSEC B-42
048241,000295:                                                                                                  #   6-7D= TIME CSEC B-28
048242,000296: 
048243,000297:                                                                                                  #  OUTPUT
048244,000298:                                                                                                  #   MMATRIX= 3X3 M MATRIX B-1   (STORED IN VAC AREA)
048245,000299: 
048246,000300: 26,3745                                           BANK     26                                    
048247,000301: 26,2000                                           SETLOC   PLANTIN1                              
048248,000302: 26,2000                                           BANK                                           
048249,000303: 26,3745                                           COUNT*   $$/LUROT                              
048250,000304: 
048251,000305: 26,3745           40220        EARTHMX            STQ      SETPD                                 #  SET   8-9D=AZO
048252,000306: 26,3746           00051                                    EARTHMXX                              
048253,000307: 26,3747           00011                                    8D                                    #  10-11D=WEARTH
048254,000308: 26,3750           77770                           AXT,1                                          #  FOR SL 5, AND SL 10  IN NEWANGLE
048255,000309: 26,3751           00000                                    0                                     
048256,000310: 26,3752           65345                           DLOAD    PDDL                                  #    LEAVING PD SET AT 12D FOR NEWANGLE
048257,000311: 26,3753           14023                                    AZO                                   
048258,000312: 26,3754           14021                                    WEARTH                                
048259,000313: 26,3755           45006                           PUSH     CALL                                  
048260,000314: 26,3756           51741                                    NEWANGLE                              
048261,000315: 26,3757           41401                           SETPD    PUSH                                  #  18-19D=504AZ
048262,000316: 26,3760           00023                                    18D                                   #                     COS(AZ) SIN(AZ) 0
048263,000317: 26,3761           65346                           COS      PDDL                                  #  20-37D=  MMATRIX= -SIN(AZ) COS(AZ) 0 B-1
048264,000318: 26,3762           00023                                    504AZ                                 #                      0       0      1
048265,000319: 26,3763           65356                           SIN      PDDL                                  
048266,000320: 26,3764           06520                                    HI6ZEROS                              
048267,000321: 26,3765           73525                           PDDL     SIN                                   
048268,000322: 26,3766           00023                                    504AZ                                 
048269,000323: 26,3767           65276                           DCOMP    PDDL                                  
048270,000324: 26,3770           00023                                    504AZ                                 
048271,000325: 26,3771           63346                           COS      PDVL                                  
048272,000326: 26,3772           06520                                    HI6ZEROS                              
048273,000327: 26,3773           41525                           PDDL     PUSH                                  
048274,000328: 26,3774           06516                                    HIDPHALF                              
048275,000329: 26,3775           77650                           GOTO                                           
048276,000330: 26,3776           00051                                    EARTHMXX                              
048277,000331: 

Page 1138

048279,000333:                                                                                                  #  ..... EARTHL SUBROUTINE .....
048280,000334:                                                                                                  #  SUBROUTINE TO COMPUTE L VECTOR FOR EARTH
048281,000335: 
048282,000336:                                                                                                  #  CALLING SEQUENCE
048283,000337:                                                                                                  #   L       CALL
048284,000338:                                                                                                  #   L+1            EARTHL
048285,000339: 
048286,000340:                                                                                                  #  INPUT
048287,000341:                                                                                                  #   AXO,AYO SET AT LAUNCH TIME WITH AYO IMMEDIATELY FOLLOWING AXO IN CORE
048288,000342: 
048289,000343:                                                                                                  #  OUTPUT
048290,000344:                                                                                                  #            -AX
048291,000345:                                                                                                  #    MPAC=   -AY    RADIANS B-0
048292,000346:                                                                                                  #              0
048293,000347: 
048294,000348: 06,3761                                           BANK     06                                    
048295,000349: 06,2000                                           SETLOC   EARTHLOC                              
048296,000350: 06,2000                                           BANK                                           
048297,000351: 06,3761                                           COUNT*   $$/LUROT                              
048298,000352: 
048299,000353: 06,3761           57545        EARTHL             DLOAD    DCOMP                                 
048300,000354: 06,3762           01714                                    AXO                                   
048301,000355: 06,3763           14017                           STODL    504LPL                                
048302,000356: 06,3764           01712                                    -AYO                                  
048303,000357: 06,3765           14021                           STODL    504LPL     +2                         
048304,000358: 06,3766           24007                                    LO6ZEROS                              
048305,000359: 06,3767           24023                           STOVL    504LPL     +4                         
048306,000360: 06,3770           00017                                    504LPL                                
048307,000361: 06,3771           77616                           RVQ                                            
048308,000362: 

Page 1139

048310,000364:                                                                                                  #  CONSTANTS AND ERASABLE ASSIGNMENTS
048311,000365: 06,3772  12,2004               1B1                =        DP1/2                                 #  1  SCALED B-1
048312,000366: 06,3772  0000050               RPREXIT            =        S1                                    #  R-TO-RP AND RP-TO-R SUBR EXIT
048313,000367: 06,3772  0000051               EARTHMXX           =        S2                                    #  EARTHMX,MOONMX SUBR. EXITS
048314,000368: 06,3772                        504RPR             =        0D                                    #  6 REGS  R OR RP VECTOR
048315,000369: 06,3772                        SINNODI            =        8D                                    #  2       SIN(NODI)
048316,000370: 06,3772                        DVECTR             =        8D                                    #  6       D VECTOR MOON
048317,000371: 06,3772                        CVECTR             =        8D                                    #  6       C VECTR MOON
048318,000372: 06,3772                        504AZ              =        18D                                   #  2      AZ
048319,000373: 06,3772                        TIMSUBM            =        14D                                   #  3       TIME SUB M (MOON) T+T0 IN GETAZ
048320,000374: 06,3772                        504LPL             =        14D                                   #  6       L OR LP VECTOR
048321,000375: 06,3772                        AVECTR             =        20D                                   #  6       A VECTOR (MOON)
048322,000376: 06,3772                        BVECTR             =        26D                                   #  6       B VECTOR (MOON)
048323,000377: 06,3772                        MMATRIX            =        20D                                   #  18      M MATRIX
048324,000378: 06,3772                        COB                =        32D                                   #  2       COS(B) B-1
048325,000379: 06,3772                        SOB                =        34D                                   #  2       SIN(B) B-1
048326,000380: 06,3772                        504F               =        6D                                    #  2       F(MOON)

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