Source Code

These source-code files are part of a reconstructed copy of Artemis 071, the first release of the Apollo 15 through 17 Command Module (CM) Apollo Guidance Computer (AGC) software.

The reconstruction began with source code of Artemis 072 previously transcribed from a digitized copy of that program. The code was then updated by undoing changes between the two versions. The reconstruction was verified by matching memory-bank checksums to those listed in drawing 2021154-. Note that page numbers in the reconstructed code match those on the Artemis 072 printout, although the changed code would likely have changed page numbers for a real Artemis 071 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.

028467,000002:                                                                                                  ## Copyright:   Public domain.
028468,000003:                                                                                                  ## Filename:    P30-P31.agc
028469,000004:                                                                                                  ## Purpose:     A section of Artemis revision 071.
028470,000005:                                                                                                  ##              It is part of the reconstructed source code for the first
028471,000006:                                                                                                  ##              release of the flight software for the Command Module's
028472,000007:                                                                                                  ##              (CM) Apollo Guidance Computer (AGC) for Apollo 15 through
028473,000008:                                                                                                  ##              17. The code has been recreated from a copy of Artemis 072.
028474,000009:                                                                                                  ##              It has been adapted such that the resulting bugger words
028475,000010:                                                                                                  ##              exactly match those specified for Artemis 071 in NASA
028476,000011:                                                                                                  ##              drawing 2021154-, which gives relatively high confidence
028477,000012:                                                                                                  ##              that the reconstruction is correct.
028478,000013:                                                                                                  ## Reference:   643
028479,000014:                                                                                                  ## Assembler:   yaYUL
028480,000015:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
028481,000016:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
028482,000017:                                                                                                  ## Mod history: 2019-08-14 MAS  Created from Artemis 072.
028483,000018: 

Page 643

028485,000020: 
028486,000021:                                                                                                  #  PROGRAM DESCRIPTION   P30     DATE 5-1-69
028487,000022: 
028488,000023:                                                                                                  #  MOD.I BY S. ZELDIN-  TO ADD P31 AND ADAPT P30 FOR P31 USE.    22DEC67
028489,000024:                                                                                                  #  MOD.II BY P.WOLFF TO REDUCE CODING AND DELETE RESTART PROTECTION      4-30-69
028490,000025:                                                                                                  #  MOD.III BY C.BEALS TO DELETE P31      1NOV69
028491,000026: 
028492,000027:                                                                                                  #  FUNCTIONAL DESCRIPTION
028493,000028:                                                                                                  #        P30 (EXTERNAL DELTA-V TARGETTING PROGRAM)
028494,000029:                                                                                                  #                ACCEPTS ASTRONAUT INPUTS OF TIG,DELV(LV) AND COMPUTES, FOR DISPLAY,
028495,000030:                                                                                                  #                APOGEE, PERIGEE, DELV(MAG), MGA ASSOCIATED WITH DESIRED MANEUVER
028496,000031: 
028497,000032:                                                                                                  #  THE FOLLOWING SUBROUTINES ARE USED IN P30
028498,000033:                                                                                                  #        S30/31.1  COMPUTES APOGEE AND PERIGEE ALTITUDE
028499,000034:                                                                                                  #        P30/P31 - DISPLAYS TIG
028500,000035:                                                                                                  #        CNTUP30 - DISPLAYS DELV(LV)
028501,000036:                                                                                                  #        COMPTGO   CLOCKTASK COMPUTE TTOGO
028502,000037:                                                                                                  #        LOMAT     COMPUTE X,Y,Z IN LV COORDS
028503,000038:                                                                                                  #        PARAM30 - DISPLAYS APOGEE, PERIGEE, DELV(MAG), MGA, TIME FROM TIG,
028504,000039:                                                                                                  #                  MARKS SINCE LAST THRUSTING MANEUVER
028505,000040: 
028506,000041:                                                                                                  #  CALLING SEQUENCE VIA JOB FROM V37
028507,000042: 
028508,000043:                                                                                                  #  EXIT VIA V37 CALL OR GOTOPOOH
028509,000044: 
028510,000045:                                                                                                  #  OUTPUT FOR POWERED FLIGHT
028511,000046:                                                                                                  #        VTIG    X
028512,000047:                                                                                                  #        RTIG
028513,000048:                                                                                                  #        DELVSIN X
028514,000049: 
028515,000050:                                                                                                  #  P30 CALCULATIONS
028516,000051: 
028517,000052:                                                                                                  #  P30 CALC BASED ON STORED TARGET PARAMETERS (R OF IGNITION (RTIG), V OF
028518,000053:                                                                                                  #  IGNITION (VTIG), TIME OF IGNITION (TIG), DELV(LV), COMPUTE PERIGEE ALTITUDE
028519,000054:                                                                                                  #  APOGEE ALTITUDE AND DELTA-V REQUIRED IN REF. COORDS. (DELVSIN)
028520,000055:                                                                                                  #  
028521,000056:                                                                                                  #  ERASABLE INITIALIZATION REQUIRED
028522,000057:                                                                                                  #        TIG             TIME OF IGNITION                        DP      B28CS
028523,000058:                                                                                                  #        DELVSLV         SPECIFIED DELTA-V IN LOCAL VERT.
028524,000059:                                                                                                  #                        COORDS. OF ACTIVE VEHICLE AT
028525,000060:                                                                                                  #                        TIME OF IGNITION                        VCT.    B+7M/CS
028526,000061: 
028527,000062:                                                                                                  #  SUBROUTINES CALLED
028528,000063:                                                                                                  #        THISPREC
028529,000064: 
028530,000065:                                                                                                  #  OUTPUT
028531,000066:                                                                                                  #        RTIG            POSITION AT TIG                         VCT.    B+29M
028532,000067:                                                                                                  #        VTIG            VELOCITY AT TIG                         VCT.    B+7M
028533,000068:                                                                                                  #        DELVSIN         DELVSLV IN REF COORDS                   VCT.    B+7M/CS
028534,000069: 
028535,000070:                                                                                                  #  DEBRIS QTEMP    TEMP. ERASABLE
028536,000071:                                                                                                  #         QPRET, MPAC
028537,000072:                                                                                                  #         PUSHLIST
028538,000073: 
028539,000074: 35,2000                                           SETLOC   P30S1                                 
028540,000075: 35,2000                                           BANK                                           
028541,000076: 

Page 644

028543,000078: 35,3433  E7,1625                                  EBANK=   +MGA                                  
028544,000079: 
028545,000080: 35,3433                                           COUNT*   $$/P30                                
028546,000081: 35,3433           05547        P30                TC       UPFLAG                                
028547,000082: 35,3434           00027                           ADRES    UPDATFLG                              #  SET UPDATFLG
028548,000083: 35,3435           05547                           TC       UPFLAG                                
028549,000084: 35,3436           00031                           ADRES    TRACKFLG                              #  SET TRACKFLG
028550,000085: 35,3437           35026        DSP0633            CAF      V06N33                                #  DISPLAY TIME OF IGNITION
028551,000086: 35,3440           05535                           TC       VNFLASH                               
028552,000087: 35,3441           34535                           CAF      V06N81                                
028553,000088: 35,3442           05535                           TC       VNFLASH                               
028554,000089: 35,3443           05547                           TC       UPFLAG                                
028555,000090: 35,3444           00045                           ADRES    XDELVFLG                              #  BIT 8 FLAG 2
028556,000091: 35,3445           06006                           TC       INTPRET                               
028557,000092: 35,3446           71214                           CLEAR    DLOAD                                 
028558,000093: 35,3447           00670                                    UPDATFLG                              #  RESET UPDATFLG
028559,000094: 35,3450           03413                                    TIG                                   #  TIME IGNITION SCALED AT 2(+28)CS
028560,000095: 35,3451           34041                           STCALL   TDEC1                                 
028561,000096: 35,3452           27145                                    THISPREC                              #  ENCKE ROUTINE FOR
028562,000097: 
028563,000098: 35,3453           67175                           VLOAD    SXA,2                                 
028564,000099: 35,3454           00007                                    VATT                                  
028565,000100: 35,3455           03746                                    RTX2                                  
028566,000101: 35,3456           27640                           STOVL    VTIG                                  
028567,000102: 35,3457           00001                                    RATT                                  
028568,000103: 35,3460           03632                           STORE    RTIG                                  
028569,000104: 35,3461           03540                           STORE    RACT3                                 
028570,000105: 35,3462           53435                           VXV      UNIT                                  
028571,000106: 35,3463           03640                                    VTIG                                  
028572,000107: 35,3464           36617                           STCALL   UNRM                                  
028573,000108: 35,3465           72721                                    LOMAT                                 
028574,000109: 35,3466           61375                           VLOAD    VXM                                   
028575,000110: 35,3467           03405                                    DELVSLV                               
028576,000111: 35,3470           00001                                    0                                     
028577,000112: 35,3471           66172                           VSL1     SXA,1                                 
028578,000113: 35,3472           03745                                    RTX1                                  
028579,000114: 35,3473           03646                           STORE    DELVSIN                               
028580,000115: 35,3474           77646                           ABVAL                                          
028581,000116: 35,3475           27763                           STOVL    VGDISP                                #  MAG DELV
028582,000117: 35,3476           03632                                    RTIG                                  
028583,000118: 35,3477           53315                           PDVL     VAD                                   
028584,000119: 35,3500           03646                                    DELVSIN                               
028585,000120: 35,3501           03640                                    VTIG                                  
028586,000121: 35,3502           77624                           CALL                                           
028587,000122: 35,3503           54021                                    S30/31.1                              
028588,000123: 35,3504           77776                           EXIT                                           
028589,000124: 35,3505           33553        PARAM30            CAF      V06N42                                #  DISPLAY HAPO, HPER, DELTAV
028590,000125: 35,3506           05535                           TC       VNFLASH                               
028591,000126: 35,3507           06006        REFTEST            TC       INTPRET                               
028592,000127: 35,3510           77214                           BOFF     VLOAD                                 

Page 645

028594,000129: 35,3511           01742                                    REFSMFLG                              #  TEST FOR REFSMFLAG ON
028595,000130: 35,3512           73544                                    NOTSET                                
028596,000131: 35,3513           03646                                    DELVSIN                               
028597,000132: 35,3514           45006                           PUSH     CALL                                  
028598,000133: 35,3515           56444                                    GET+MGA                               
028599,000134: 35,3516           77776                           EXIT                                           
028600,000135: 35,3517           03525        DISPMGA            TC       COMPTGO                               
028601,000136: 
028602,000137: 35,3520           34536        DISP45             CAF      V16N45                                #  DISPLAY MARK CNT, TFI, +MGA
028603,000138: 35,3521           05535                           TC       VNFLASH                               
028604,000139: 35,3522           05561                           TC       DOWNFLAG                              
028605,000140: 35,3523           00155                           ADRES    TIMRFLAG                              #  RESET TIMRFLAG
028606,000141: 35,3524           14103                           TCF      GOTOPOOH                              
028607,000142: 
028608,000143: 35,3525           00006        COMPTGO            EXTEND                                         
028609,000144: 35,3526           23272                           QXCH     PHSPRDT6                              
028610,000145: 
028611,000146: 35,3527           05547                           TC       UPFLAG                                #  SET TIMRFLAG
028612,000147: 35,3530           00155                           ADRES    TIMRFLAG                              
028613,000148: 35,3531           34772                           CAF      ZERO                                  
028614,000149: 35,3532           54777                           TS       NVWORD1                               
028615,000150: 
028616,000151: 35,3533           34770                           CAF      ONE                                   
028617,000152: 35,3534           05233                           TC       WAITLIST                              
028618,000153: 35,3535  E7,1412                                  EBANK=   TIG                                   
028619,000154: 35,3535           03225 50067                     2CADR    CLOKTASK                              
028620,000155: 
028621,000156: 35,3537           05362                           TC       2PHSCHNG                              
028622,000157: 35,3540           40036                           OCT      40036                                 #  6.3SPOT FOR CLOKTASK
028623,000158: 35,3541           05024                           OCT      05024                                 #  GROUP 4 CONTINUES HERE
028624,000159: 35,3542           13000                           OCT      13000                                 
028625,000160: 
028626,000161: 35,3543  01,2325               6P3SPT1            =        6.3SPOT                               
028627,000162: 35,3543           01272                           TC       PHSPRDT6                              
028628,000163: 
028629,000164: 35,3544           57545        NOTSET             DLOAD    DCOMP                                 
028630,000165: 35,3545           33552                                    MARSDP                                
028631,000166: 35,3546           03626                           STORE    +MGA                                  
028632,000167: 35,3547           77634                           RTB                                            
028633,000168: 35,3550           73517                                    DISPMGA                               
028634,000169: 35,3551           00000        MARSDP             OCT      00000                                 #  (00000) (16440) = (+00001)
028635,000170: 35,3552           35100                           OCT      35100                                 
028636,000171:                                                                                                  #  ( .01 ) DEGREES IN THE LOW ORDER REGISTE
028637,000172: 
028638,000173: 35,3553           01452        V06N42             VN       0642                                  
028639,000174: 

Page 646

028641,000176: 
028642,000177:                                                                                                  #  S30/31.1      SUBROUTINE USED BY P30/P31 CALCULATIONS
028643,000178:                                                                                                  #  MOD NO 1              LOG SECTION P30,P37
028644,000179: 
028645,000180:                                                                                                  #  FUNCTIONAL DESCRIPTION
028646,000181:                                                                                                  #        THROUGH A SERIES OF CALLS COMPUTES APOGEE AND PERIGEE ALTITUDE
028647,000182: 
028648,000183:                                                                                                  #  SUBROUTINES CALLED
028649,000184:                                                                                                  #        PERIAPO1
028650,000185:                                                                                                  #        SHIFTR1
028651,000186:                                                                                                  #        MAXCHK
028652,000187: 
028653,000188:                                                                                                  #  CALLING SEQUENCE
028654,000189:                                                                                                  #        L       CALL
028655,000190:                                                                                                  #        L+1             S30/31.1
028656,000191: 
028657,000192:                                                                                                  #  NORMAL EXIT MODE
028658,000193:                                                                                                  #        AT L+2 OR CALLING SEQUENCE
028659,000194: 
028660,000195:                                                                                                  #  OUTPUT
028661,000196:                                                                                                  #        HAPO            APOGEE ALT.             DP      B+29 M
028662,000197:                                                                                                  #        HPER            PERIGEE ALT.            DP      B+29 M
028663,000198: 
028664,000199: 26,2000                                           SETLOC   P30S1A                                
028665,000200: 26,2000                                           BANK                                           
028666,000201: 
028667,000202: 26,2021                                           COUNT*   $$/P30                                
028668,000203: 26,2021           45020        S30/31.1           STQ      CALL                                  
028669,000204: 26,2022           03657                                    QTEMP                                 
028670,000205: 26,2023           45174                                    PERIAPO1                              
028671,000206: 26,2024           77624                           CALL                                           
028672,000207: 26,2025           45330                                    SHIFTR1                               
028673,000208: 26,2026           77624                           CALL                                           
028674,000209: 26,2027           46745                                    MAXCHK                                
028675,000210: 26,2030           16357                           STODL    HPER                                  #  PERIGEE ALT B+29
028676,000211: 26,2031           00005                                    4D                                    
028677,000212: 26,2032           77624                           CALL                                           
028678,000213: 26,2033           45330                                    SHIFTR1                               
028679,000214: 26,2034           77624                           CALL                                           
028680,000215: 26,2035           46745                                    MAXCHK                                
028681,000216: 26,2036           36355                           STCALL   HAPO                                  #  APOGEE ALT B+29
028682,000217: 26,2037           03657                                    QTEMP                                 
028683,000218: 

Page 647

028685,000220: 
028686,000221:                                                                                                  #  SUBROUTINE NAME:      DELRSPL         (CONTINUATION OF V 82 IN CSM IF P11 ACTI
028687,000222:                                                                                                  #  TRANSFERRED COMPLETELY FROM SUNDISK, P30S REV 33. 9 SEPT 67.
028688,000223:                                                                                                  #  MOD NO: 0     MOD BY: ZELDIN          DATE:
028689,000224:                                                                                                  #  MOD NO: 1     MOD BY: RR BAIRNSFATHER DATE: 11 APR 67
028690,000225:                                                                                                  #  MOD NO: 2     MOD BY: RR BAIRNSFATHER DATE: 12 MAY 67         ADD UR.RT CALC WHEN BELOW 300K FT
028691,000226:                                                                                                  #  MOD NO: 2.1   MOD BY: RR BAIRNSFATHER DATE: 5 JULY 67         FIX ERROR IN MOD. 2.
028692,000227:                                                                                                  #  MOD NO: 3     MOD BY: RR BAIRNSFATHER DATE: 12 JUL 67         CHANGE SIGN OF DISPLAYED ERROR.
028693,000228:                                                                                                  #  MOD 4         MOD BY  S.ZELDIN        DATE  3 APRIL 68        CHANGE EQUATIONS FOR L/D=.18 WHICH REPLA
028694,000229: 
028695,000230:                                                                                                  #  FUNCTION:     CALCULATE (FOR DISPLAY ON CALL) AN APPROXIMATE MEASURE OF IN-PLANE SPLASH DOWN
028696,000231:                                                                                                  #                ERROR. IF THE FREE-FALL TRANSFER ANGLE TO 300K FT ABOVE PAD RADIUS IS POSITIVE:
028697,000232:                                                                                                  #                SPLASH ERROR= -RANGE TO TARGET + FREE-FALL TRANSFER ANGLE + ESTIMATED ENTRY ANGLE.
028698,000233:                                                                                                  #                THE TARGET LOCATION AT ESTIMATED TIME OF IMPACT IS USED.  IF THE FREE-FALL TRANSFER
028699,000234:                                                                                                  #                ANGLE IS NEGATIVE:  SPLASH ERROR= -RANGE TO TARGET
028700,000235:                                                                                                  #                THE PRESENT TARGET LOCATION IS USED.
028701,000236: 
028702,000237:                                                                                                  #  CALLING SEQUENCE  CALLED AFTER SR30.1 IF IN CSM AND IF P11 OPERATING (UNDER CONTROL OF V82)
028703,000238: 
028704,000239:                                                                                                  #  SUBROUTINES CALLED:  VGAMCALC, TFF/TRIG, LALOTORV.
028705,000240: 
028706,000241:                                                                                                  #  EXIT          RETURN DIRECTLY TO V 82 PROG. AT SPLRET
028707,000242: 
028708,000243:                                                                                                  #  ERASABLE INITIALIZATION   LEFT BY SR30.1 AND V82GON1
028709,000244: 
028710,000245:                                                                                                  #  OUTPUT:       RSP-RREC  RANGE IN REVOLUTIONS                  DSKY DISPLAY IN N. MI.
028711,000246: 
028712,000247:                                                                                                  #  DEBRIS:       QPRET, PDL0 ... PDL7, PDL10
028713,000248:                                                                                                  #                THETA(1)
028714,000249: 
028715,000250: 32,2000                                           SETLOC   DELRSPL1                              
028716,000251: 32,2000                                           BANK                                           
028717,000252: 32,2027                                           COUNT*   $$/P30                                #  PROGRAMS: P30 EXTERNAL DELTA V
028718,000253: 
028719,000254: 32,2027           00011        DELRSPL            STORE    8D                                    
028720,000255: 32,2030           45244                           BPL      DSU                                   
028721,000256: 32,2031           64077                                    CANTDO                                #  GONE PAST 300K FT ALT
028722,000257: 32,2032           16425                                    1BITDP                                
028723,000258: 32,2033           45000                           BOV      CALL                                  
028724,000259: 32,2034           64077                                    CANTDO                                #  POSMAX INDICATES NO 300K FT SOLUTION.
028725,000260: 32,2035           55054                                    VGAMCALC                              #  +GAMMA(REV) IN PMAC,V300 MAG(B-7)=PDL 0
028726,000261: 32,2036           45006                           PUSH     CALL                                  
028727,000262: 32,2037           57052                                    TFF/TRIG                              
028728,000263: 32,2040           77624                           CALL                                           
028729,000264: 32,2041           64105                                    AUGEKUGL                              
028730,000265: 32,2042           65525                           PDDL     ACOS                                  #  T ENTRY PDL 6
028731,000266: 32,2043           00017                                    CDELF/2                               
028732,000267: 32,2044           77615                           DAD                                            
028733,000268: 32,2045           00005                                    4                                     
028734,000269: 32,2046           26341        GETARG             STOVL    THETA(1)                              
028735,000270: 32,2047           03401                                    LAT(SPL)                              
028736,000271: 32,2050           14747                           STODL    LAT                                   
028737,000272: 32,2051           15336                                    HI6ZEROS                              
028738,000273: 32,2052           14753                           STODL    ALT                                   #  ALT=0 = LAT +4
028739,000274: 32,2053           01044                                    PIPTIME                               
028740,000275: 32,2054           71214                           BON      DLOAD                                 

Page 648

028742,000277: 32,2055           03711                                    V37FLAG                               
028743,000278: 32,2056           64060                                    +2                                    
028744,000279: 32,2057           02316                                    TSTART82                              
028745,000280: 32,2060           43225                           DSU      DAD                                   
028746,000281: 32,2061           00011                                    8D                                    
028747,000282: 32,2062           45014                           CLEAR    CALL                                  
028748,000283: 32,2063           00662                                    ERADFLAG                              
028749,000284: 32,2064           26524                                    LALOTORV                              #  R RECOV. IN ALPHAV AND MPAC
028750,000285: 
028751,000286: 32,2065           63256                           UNIT     PDVL                                  
028752,000287: 32,2066           02320                                    RONE                                  
028753,000288: 32,2067           50256                           UNIT     DOT                                   
028754,000289: 32,2070           65552                           SL1      ARCCOS                                
028755,000290: 32,2071           77621                           BDSU                                           #  ERROR = THETA EST - THETA TARG
028756,000291:                                                                                                  #  NEGATIVE NUMBER SIGNIFIES THAT WILL FALL SHORT.
028757,000292:                                                                                                  #  POSITIVE NUMBER SIGNIFIES THAT WILL OVERSHOOT.
028758,000293: 32,2072           02341                                    THETA(1)                              
028759,000294: 32,2073           36347        DELRDONE           STCALL   RSP-RREC                              #  DOWNRANGE RECOVERY RANGE ERROR        /360
028760,000295: 32,2074           27525                                    INTWAKE0                              
028761,000296: 32,2075           77624                           CALL                                           
028762,000297: 32,2076           46616                                    SPLRET                                
028763,000298: 32,2077           65345        CANTDO             DLOAD    PDDL                                  #  INITIALIZE ERASE TO DOT TARGET AND UR
028764,000299:                                                                                                  #  FOR RANGE ANGLE.
028765,000300: 32,2100           15334                                    HIDPHALF                              #  TO PDL 0 FOR DEN IN DDV.
028766,000301: 32,2101           15336                                    HI6ZEROS                              
028767,000302: 32,2102           77606                           PUSH                                           #  ZERO TO PDL 2 FOR PHI ENTRY
028768,000303: 32,2103           34011                           STCALL   8D                                    
028769,000304: 32,2104           64046                                    GETARG                                #  GO SET RSP-RREC =0
028770,000305: 
028771,000306: 32,2105           77775        AUGEKUGL           VLOAD                                          
028772,000307: 32,2106           24266                                    X1CON      -2                         
028773,000308: 32,2107           14045                           STODL    X1         -2                         
028774,000309: 32,2110           00001                                    0                                     
028775,000310: 32,2111           50025                           DSU      BMN                                   
028776,000311: 32,2112           24260                                    V(21K)                                
028777,000312: 32,2113           64140                                    LOOPSET                               
028778,000313: 32,2114           65060                           XSU,1    XCHX,2                                
028779,000314: 32,2115           00050                                    S1                                    
028780,000315: 32,2116           00046                                    X1                                    
028781,000316: 32,2117           45324                           XCHX,2   DSU                                   
028782,000317: 32,2120           00050                                    S1                                    
028783,000318: 32,2121           24246                                    V(3K)                                 
028784,000319: 32,2122           65040                           BMN      XCHX,2                                
028785,000320: 32,2123           64140                                    LOOPSET                               
028786,000321: 32,2124           00050                                    S1                                    
028787,000322: 32,2125           50025                           DSU      BMN                                   
028788,000323: 32,2126           24256                                    V(4K)                                 
028789,000324: 32,2127           64140                                    LOOPSET                               
028790,000325: 32,2130           65124                           XCHX,2   XCHX,2                                
028791,000326: 32,2131           00050                                    S1                                    

Page 649

028793,000328: 32,2132           00046                                    X1                                    
028794,000329: 32,2133           50025                           DSU      BMN                                   
028795,000330: 32,2134           24242                                    V(400)                                
028796,000331: 32,2135           64140                                    LOOPSET                               
028797,000332: 32,2136           77730                           SXA,1                                          
028798,000333: 32,2137           00050                                    S1                                    
028799,000334: 32,2140           52110        LOOPSET            INCR,1   GOTO                                  
028800,000335: 32,2141           00001                           DEC      1          B-14                       
028801,000336: 32,2142           64145                                    K1K2LOOP                              
028802,000337: 32,2143           77730        K2CALC             SXA,1                                          
028803,000338: 32,2144           00050                                    S1                                    
028804,000339: 32,2145           44745        K1K2LOOP           DLOAD    DSU*                                  
028805,000340: 32,2146           00001                                    0                                     
028806,000341: 32,2147           24255                                    V(32K)     +1,1                       
028807,000342: 32,2150           42603                           DMP*     DAD*                                  
028808,000343: 32,2151           24241                                    YK1K2      +1,1                       
028809,000344: 32,2152           24225                                    CK1K2      +1,1                       
028810,000345: 32,2153           60125                           PDDL     TIX,1                                 
028811,000346: 32,2154           00003                                    2                                     
028812,000347: 32,2155           64143                                    K2CALC                                
028813,000348: 32,2156           55225                           DSU      BDDV                                  
028814,000349: 32,2157           40006                           PUSH     BOV                                   #  PHI ENTRY PDL 4D
028815,000350: 32,2160           64203                                    MAXPHI                                
028816,000351: 32,2161           45240                           BMN      DSU                                   
028817,000352: 32,2162           64203                                    MAXPHI                                
028818,000353: 32,2163           24210                                    MAXPHIC                               
028819,000354: 32,2164           77644                           BPL                                            
028820,000355: 32,2165           64203                                    MAXPHI                                
028821,000356: 32,2166           45345        PHICALC            DLOAD    DSU                                   
028822,000357: 32,2167           00001                                    0                                     
028823,000358: 32,2170           24266                                    V(26K)                                
028824,000359: 32,2171           71244                           BPL      DLOAD                                 
028825,000360: 32,2172           64200                                    TGR26                                 
028826,000361: 32,2173           24262                                    TLESS26                               
028827,000362: 32,2174           77671                           DDV                                            
028828,000363: 32,2175           00001                                    0                                     
028829,000364: 32,2176           43405        TENT               DMP      RVQ                                   
028830,000365: 32,2177           00005                                    4D                                    
028831,000366: 32,2200           52145        TGR26              DLOAD    GOTO                                  
028832,000367: 32,2201           24264                                    TGR26CON                              
028833,000368: 32,2202           64176                                    TENT                                  
028834,000369: 
028835,000370: 32,2203           65345        MAXPHI             DLOAD    PDDL                                  
028836,000371: 32,2204           24210                                    MAXPHIC                               
028837,000372: 32,2205           77650                           GOTO                                           
028838,000373: 32,2206           64166                                    PHICALC                               
028839,000374: 32,2207           02755 01307  MAXPHIC            2DEC     .09259298                             #  2000 NM FOR MAXIMUM PHI ENTRY
028840,000375: 
028841,000376: 32,2211                                           COUNT*   $$/P30                                

Page 650

028843,000378: 
028844,000379: 
028845,000380:                                                                                                  #                BELOW
028846,000381:                                                                                                  #  <<<< TABLE IS INDEXED. KEEP IN ORDER >>>
028847,000382: 
028848,000383: 32,2211           00013 22652                     2DEC     7.07304526 E-4                        #  5500
028849,000384: 
028850,000385: 32,2213           00005 01642                     2DEC     3.08641975 E-4                        #  2400
028851,000386: 
028852,000387: 32,2215           00005 01642                     2DEC     3.08641975 E-4                        #  2400
028853,000388: 
028854,000389: 32,2217           77556 53522                     2DEC     -8.8888888 E-3                        #  -3.2
028855,000390: 
028856,000391: 32,2221           00055 20266                     2DEC     2.7777777  E-3                        #  1
028857,000392: 
028858,000393: 32,2223           00155 07202  CK1K2              2DEC     6.6666666  E-3                        #  2.4
028859,000394: 
028860,000395: 32,2225           00000 00000                     2DEC     0          B-28                       #  0
028861,000396: 
028862,000397: 32,2227           77730 71525                     2DEC*    -1.86909989 E-5        B7*             #  -.443
028863,000398: 
028864,000399: 32,2231           00000 00000                     2DEC     0          B-28                       
028865,000400: 
028866,000401: 32,2233           04445 10102                     2DEC*    1.11639691 E-3        B7*             #  .001225
028867,000402: 
028868,000403: 32,2235           03726 31201                     2DEC*    9.56911636 E-4        B7*             #  .00105
028869,000404: 
028870,000405: 32,2237           01040 26313  YK1K2              2DEC*    2.59733157 E-4        B7*             #  .000285
028871,000406: 
028872,000407: 32,2241           00234 01660  V(400)             2DEC     1.2192     B-7                        
028873,000408: 
028874,000409: 32,2243           25254 01014  V(28K)             2DEC     85.344     B-7                        
028875,000410: 
028876,000411: 32,2245           02222 15646  V(3K)              2DEC     9.144      B-7                        
028877,000412: 
028878,000413: 32,2247           22223 16457  V(24K)             2DEC     73.152     B-7                        
028879,000414: 
028880,000415: 32,2251           25254 01014                     2DEC     85.344     B-7                        
028881,000416: 
028882,000417: 32,2253           30304 23351  V(32K)             2DEC     97.536     B-7                        
028883,000418: 
028884,000419: 32,2255           03030 22335  V(4K)              2DEC     12.192     B-7                        
028885,000420: 
028886,000421: 32,2257           20001 00611  V(21K)             2DEC     64.008     B-7                        
028887,000422: 
028888,000423: 32,2261           00033 05763  TLESS26            2DEC*    5.70146688 E7         B-35*           #  8660PHI/V
028889,000424: 
028890,000425: 32,2263           00053 36200  TGR26CON           2DEC     7.2        E5         B-28            #  PHI/3
028891,000426: 
028892,000427: 32,2265           23637 27636  V(26K)             2DEC     79.248     B-7                        #  26000
028893,000428: 
028894,000429: 32,2267           00012        X1CON              DEC      10         B-14                       
028895,000430: 

Page 651

028897,000432: 
028898,000433: 32,2270           00010                           DEC      8          B-14                       
028899,000434: 32,2271           00006                           DEC      6          B-14                       
028900,000435:                                                                                                  #  <<<< TABLE IS INDEXED. KEEP IN ORDER >>>
028901,000436:                                                                                                  #                ABOVE

Page 652

028903,000438: 
028904,000439:                                                                                                  #  ***** AVFLAGA/P *****
028905,000440: 
028906,000441:                                                                                                  #  SUBROUTINES USED
028907,000442: 
028908,000443:                                                                                                  #        UPFLAG
028909,000444:                                                                                                  #        DOWNFLAG
028910,000445: 
028911,000446:    4000                                           SETLOC   P30SUBS                               
028912,000447:    4000                                           BANK                                           
028913,000448:    4553                                           COUNT*   $$/P30                                
028914,000449:    4553  E4,1760                                  EBANK=   SUBEXIT                               
028915,000450:    4553           00006        AVFLAGA            EXTEND                                         #  AVFLAG = CSM
028916,000451:    4554           23760                           QXCH     SUBEXIT                               
028917,000452:    4555           05561                           TC       DOWNFLAG                              
028918,000453:    4556           00050                           ADRES    AVFLAG                                #  BIT 5  FLAG 2
028919,000454:    4557           04606                           TC       E7SETTER                              
028920,000455:    4560  E7,1424                                  EBANK=   ECSTEER                               
028921,000456:    4560           34754                           CAF      BIT13                                 
028922,000457:    4561           55424                           TS       ECSTEER                               #  SET ECSTEER = 1
028923,000458:    4562           34756                           CAF      EBANK4                                
028924,000459:    4563           54003                           TS       EBANK                                 
028925,000460:    4564  E4,1760                                  EBANK=   SUBEXIT                               
028926,000461:    4564           01760                           TC       SUBEXIT                               
028927,000462:    4565           00006        AVFLAGP            EXTEND                                         #  AVFLAG = LEM
028928,000463:    4566           23760                           QXCH     SUBEXIT                               
028929,000464:    4567           05547                           TC       UPFLAG                                
028930,000465:    4570           00050                           ADRES    AVFLAG                                #  BIT 5  FLAG 2
028931,000466:    4571           01760                           TC       SUBEXIT                               
028932,000467:    4572           00006        P20FLGON           EXTEND                                         
028933,000468:    4573           23760                           QXCH     SUBEXIT                               
028934,000469:    4574           05547                           TC       UPFLAG                                
028935,000470:    4575           00031                           ADRES    TRACKFLG                              
028936,000471:    4576           05547                           TC       UPFLAG                                
028937,000472:    4577           00027                           ADRES    UPDATFLG                              
028938,000473:    4600           05561                           TC       DOWNFLAG                              
028939,000474:    4601           00244                           ADRES    PCFLAG                                
028940,000475:    4602           01760                           TC       SUBEXIT                               
028941,000476: 

Page 653

028943,000478: 
028944,000479: 04,2000                                           SETLOC   P31TAG                                
028945,000480: 04,2000                                           BANK                                           
028946,000481: 
028947,000482: 04,3303                                           COUNT*   $$/P3136                              
028948,000483: 04,3303           04553        P31                TC       AVFLAGA                               
028949,000484: 04,3304           04572                           TC       P20FLGON                              #  SET TRACK,UPDATE, CLEAR FINAL FLAGS
028950,000485: 04,3305           06006                           TC       INTPRET                               
028951,000486: 04,3306           45014        P31ALMRT           CLEAR    CALL                                  
028952,000487: 04,3307           05671                                    CSISFLAG                              
028953,000488: 04,3310           11546                                    INPUTDSP                              
028954,000489: 04,3311           74014                           BOFF     AXC,1                                 
028955,000490: 04,3312           04343                                    CMOONFLG                              
028956,000491: 04,3313           11315                                    COMPMU                                
028957,000492: 04,3314           00012                                    10D                                   
028958,000493: 04,3315           51575        COMPMU             VLOAD    ABVAL                                 
028959,000494: 04,3316           01555                                    RRECTCSM                              
028960,000495: 04,3317           62606                           PUSH     PDVL*                                 #                        PL AT 04D
028961,000496: 04,3320           22301                                    MUTABLE,1                             #  RTX1=1/MU B+34,B+28, RTMU=SQRT(MU)
028962,000497: 04,3321           27746                           STOVL    RTX1                                  #  B-18,B-15, RTSR1/MU=1/SQRT(MU)        B+17,B+14
028963,000498: 04,3322           01563                                    VRECTCSM                              
028964,000499: 04,3323           57236                           VSQ      DMPR                                  
028965,000500: 04,3324           03746                                    RTX1                                  #  VSQ/MU                                B+2 ,B+18
028966,000501: 04,3325           52405                           DMP      SL3                                   #  R VSQ/MU              PL AT 02D       B-6
028967,000502: 04,3326           74421                           BDSU     SR1R                                  
028968,000503: 04,3327           33416                                    D1/32                                 #  ( 2 - R VSQ/MU )                      B-7
028969,000504: 04,3330           41471                           DDV      PUSH                                  #  ( 2 - R VSQ/MU )/R       AT 00D       B+22,B+20
028970,000505: 04,3331           55366                           SQRT     BDDV                                  #  2 PI R/(2 - R VSQ/MU)                 B-15,B-14
028971,000506: 04,3332           33430                                    2PISC                                 
028972,000507: 04,3333           65205                           DMP      PDDL                                  #  2PI R SQRT(MU)/(2MU-R VSQ)            B-2,B-0
028973,000508: 04,3334           03752                                    RTSR1/MU                              
028974,000509: 04,3335           65301                           NORM     PDDL                                  
028975,000510: 04,3336           00047                                    X1                                    
028976,000511: 04,3337           56257                           SL*      DDV                                   
028977,000512: 04,3340           20172                                    0          -7D,1                      #  HAFPA1 = PERIOD/2                     B-28
028978,000513: 04,3341           77621                           BDSU                                           #  TIG = ( TCSI - HAFPA1 )               B-28
028979,000514: 04,3342           02463                                    TCSI                                  
028980,000515: 04,3343           03413                           STORE    TIG                                   #  TIG = ( TCSI - PERIOD/2 )             B-28
028981,000516: 04,3344           77776                           EXIT                                           
028982,000517: 04,3345           35026                           CA       V06N33                                
028983,000518: 04,3346           05535                           TC       VNFLASH                               
028984,000519: 04,3347           06006                           TC       INTPRET                               
028985,000520: 04,3350           77624        P31ONWRD           CALL                                           
028986,000521: 04,3351           11217                                    SELECTMU                              
028987,000522: 04,3352           71214        P31RECYC           SET      DLOAD                                 
028988,000523: 04,3353           05470                                    HAFLAG                                
028989,000524: 04,3354           02463                                    TCSI                                  
028990,000525: 04,3355           77624                           CALL                                           
028991,000526: 04,3356           11441                                    P31ENT                                
028992,000527: 04,3357           77775        P31RT              VLOAD                                          

Page 654

028994,000529: 04,3360           11762                                    ZEROVEC                               
028995,000530: 04,3361           17405                           STODL    DELVLVC                               
028996,000531: 04,3362           02633                                    DIFFALT                               #  DELTA H AT CDH
028997,000532: 04,3363           57215                           DAD      DMPR                                  
028998,000533: 04,3364           02370                                    HAMDELH                               #  METERS        B-29
028999,000534: 04,3365           11376                                    25THOUS                               #  K = -.025                             B-0
029000,000535: 04,3366           45061                           SL       CALL                                  
029001,000536: 04,3367           20206                                    5D                                    
029002,000537: 04,3370           24005                                    N90/N81                               
029003,000538: 04,3371           77624                           CALL                                           #                 X
029004,000539: 04,3372           73027                                    VN1645                                #  S32/33.1, DISPLAYS AND COMPUTES DELVLVC
029005,000540: 04,3373           77650                           GOTO                                           #  AND DELVSIN.
029006,000541: 04,3374           11352                                    P31RECYC                              
029007,000542: 04,3375           56574 47556  25THOUS            2DEC*    -.4114470842 E-5        B+17*           #                                B+17
029008,000543: 
029009,000544: 04,3377           13434        130DEGLO           OCT      13434                                 
029010,000545: 04,3400           16163                           OCT      16163                                 
029011,000546: 04,3401           22407        208DEGLO           OCT      22407                                 
029012,000547: 04,3402           36673                           OCT      36673                                 
029013,000548: 22,2000                                           SETLOC   P36TAG                                
029014,000549: 22,2000                                           BANK                                           

Page 655

029016,000551: 
029017,000552:                                                                                                  #  PLANE CHANGE TARGETING PROGRAM        P36
029018,000553:                                                                                                  #  
029019,000554:                                                                                                  #  PURPOSE
029020,000555:                                                                                                  #        TO COMPUTE PARAMETERS FOR PLANE CHANGE MANEUVER
029021,000556: 
029022,000557:                                                                                                  #  INPUT
029023,000558:                                                                                                  #        TCSI
029024,000559:                                                                                                  #  
029025,000560:                                                                                                  #  OUTPUT
029026,000561:                                                                                                  #        TIG             TIME OF PLANE CHANGE MANEUVER  COMPUTED TO BE
029027,000562:                                                                                                  #                        TCSI + 90 DEG TRANSFER TIME
029028,000563:                                                                                                  #        DELVLVC         DELTA VELOCITY AT PC - LOCAL VERTICAL
029029,000564:                                                                                                  #        DELVSIN         DELTA VELOCITY AT PC - REFERENCE
029030,000565: 
029031,000566: 22,3334                                           COUNT*   $$/P3136                              
029032,000567: 22,3334           04553        P36                TC       AVFLAGA                               
029033,000568: 22,3335           04572                           TC       P20FLGON                              #  SET TRACK,UPDATE - CLEAR PC FLAGS
029034,000569: 22,3336           05547                           TC       UPFLAG                                
029035,000570: 22,3337           00244                           ADRES    PCFLAG                                
029036,000571: 
029037,000572: 22,3340           06006                           TC       INTPRET                               
029038,000573: 22,3341           77624                           CALL                                           
029039,000574: 22,3342           11217                                    SELECTMU                              
029040,000575: 22,3343           71214        P36A               SET      DLOAD                                 
029041,000576: 22,3344           01067                                    XDELVFLG                              
029042,000577: 22,3345           02463                                    TCSI                                  
029043,000578: 22,3346           34041                           STCALL   TDEC1                                 
029044,000579: 22,3347           27170                                    CSMCONIC                              #  INTEGRATE STATES TO TCSI
029045,000580: 22,3350           43145                           DLOAD    SET                                   
029046,000581: 22,3351           15336                                    ZEROVECS                              
029047,000582: 22,3352           03466                                    RVSW                                  
029048,000583: 22,3353           16734                           STODL    CSTH                                  #  COS 90 DEGREES
029049,000584: 22,3354           05547                                    CS359+                                
029050,000585: 22,3355           26732                           STOVL    SNTH                                  #  SINE 90 DEGREES
029051,000586: 22,3356           00001                                    RATT                                  
029052,000587: 22,3357           45115                           PDVL     CALL                                  
029053,000588: 22,3360           00007                                    VATT                                  
029054,000589: 22,3361           45320                                    VECSHIFT                              
029055,000590: 22,3362           26746                           STOVL    VVEC                                  
029056,000591: 22,3363           77626                           STADR                                          
029057,000592: 22,3364           41120                           STCALL   RVEC                                  #  COMPUTE TRANSFER TIME OF 90 DEG
029058,000593: 22,3365           25002                                    TIMETHET                              
029059,000594: 22,3366           77615                           DAD                                            
029060,000595: 22,3367           02463                                    TCSI                                  
029061,000596: 22,3370           03413                           STORE    TIG                                   
029062,000597: 22,3371           77776                           EXIT                                           
029063,000598: 22,3372           35026                           CAF      V06N33                                
029064,000599: 22,3373           05535                           TC       VNFLASH                               
029065,000600: 22,3374           06006                           TC       INTPRET                               
029066,000601: 22,3375           77624                           CALL                                           

Page 656

029068,000603: 22,3376           73027                                    VN1645                                
029069,000604: 22,3377           45175        P36RECYC           VLOAD    CALL                                  
029070,000605: 22,3400           15336                                    ZEROVECS                              
029071,000606: 22,3401           24005                                    N90/N81                               #  DISPLAY N90,N81 COMPUTE YDOT
029072,000607: 22,3402           77624                           CALL                                           
029073,000608: 22,3403           73027                                    VN1645                                
029074,000609: 22,3404           77650                           GOTO                                           
029075,000610: 22,3405           45377                                    P36RECYC                              
029076,000611: 12,2000                                           SETLOC   N90TAG                                
029077,000612: 12,2000                                           BANK                                           

Page 657

029079,000614: 
029080,000615:                                                                                                  #  ...... N90/N81 ....... COMPUTES YDOT, DISPLAYS N90 AND N81 FOR P31, P36
029081,000616: 12,2005                                           COUNT*   $$/P3136                              
029082,000617: 12,2005           77620        N90/N81            STQ                                            
029083,000618: 12,2006           02551                                    N90RET                                
029084,000619: 12,2007           17405                           STODL    DELVLVC                               
029085,000620: 12,2010           03413                                    TIG                                   
029086,000621: 12,2011           34041                           STCALL   TDEC1                                 
029087,000622: 12,2012           45236                                    PRECSET                               
029088,000623: 12,2013           43014                           BON      SET                                   
029089,000624: 12,2014           01311                                    FINALFLG                              
029090,000625: 12,2015           24017                                    +2                                    
029091,000626: 12,2016           00470                                    UPDATFLG                              
029092,000627: 12,2017           77775                 +2        VLOAD                                          
029093,000628: 12,2020           03546                                    VACT3                                 
029094,000629: 12,2021           27640                           STOVL    VTIG                                  
029095,000630: 12,2022           03540                                    RACT3                                 
029096,000631: 12,2023           37632                           STCALL   RTIG                                  
029097,000632: 12,2024           15756                                    DISPN90                               
029098,000633: 12,2025           77624                           CALL                                           
029099,000634: 12,2026           72721                                    LOMAT                                 
029100,000635: 12,2027           61375                           VLOAD    VXM                                   
029101,000636: 12,2030           03405                                    DELVLVC                               #  ROTATE DV (LV TO REF)
029102,000637: 12,2031           00001                                    0D                                    
029103,000638: 12,2032           77772                           VSL1                                           
029104,000639: 12,2033           37646                           STCALL   DELVSIN                               
029105,000640: 12,2034           02551                                    N90RET                                

End of include-file P30-P31.agc.  Parent file is MAIN.agc