Source Code

These source-code files derive from a printout of Luminary 116 (the Apollo 12 Lunar Module guidance computer program), from the personal library of original AGC developer Don Eyles, digitally photographed at archive.org, financially sponsored by Ron Burkey, and transcribed to source code by a team of volunteers. This colorized, syntax-highlighted form was created by assembling that transcribed source code. Note that the full page images are available on the Virtual AGC project page at archive.org, while reduced-size images are presented at the VirtualAGC project website. Report or fix any transcription errors at the Virtual AGC project code repository.

Notations on the program listing read, in part:

	GAP:  ASSEMBLE REVISION 116 OF AGC PROGRAM LUMINARY BY NASA 2021112-071
	19:09 AUG. 11,1969
Note that the date is the date of the printout, not the date of the program revision.

053325,000002:                                                                                                  ## Copyright:   Public domain.
053326,000003:                                                                                                  ## Filename:    TIME_OF_FREE_FALL.agc
053327,000004:                                                                                                  ## Purpose:     A section of Luminary revision 116.
053328,000005:                                                                                                  ##              It is part of the source code for the Lunar Module's (LM) 
053329,000006:                                                                                                  ##              Apollo Guidance Computer (AGC) for Apollo 12.
053330,000007:                                                                                                  ##              This file is intended to be a faithful transcription, except
053331,000008:                                                                                                  ##              that the code format has been changed to conform to the
053332,000009:                                                                                                  ##              requirements of the yaYUL assembler rather than the
053333,000010:                                                                                                  ##              original YUL assembler.
053334,000011:                                                                                                  ## Reference:   pp. 1258-1273
053335,000012:                                                                                                  ## Assembler:   yaYUL
053336,000013:                                                                                                  ## Contact:     Ron Burkey <info@sandroid.org>.
053337,000014:                                                                                                  ## Website:     www.ibiblio.org/apollo/index.html
053338,000015:                                                                                                  ## Mod history: 2017-01-22 MAS  Created from Luminary 99.
053339,000016:                                                                                                  ##              2017-02-09 RRB  Updated for Luminary 116.
053340,000017:                                                                                                  ##              2017-03-14 RSB  Proofed comment text via 3-way diff vs
053341,000018:                                                                                                  ##                              Luminary 99 and 131.
053342,000019:                                                                                                  ##              2017-03-16 RSB  Comment-text fixes identified in 5-way
053343,000020:                                                                                                  ##                              side-by-side diff of Luminary 69/99/116/131/210.
053344,000021: 

Page 1258

053346,000023:                                                                                                  #           THE TFF SUBROUTINES MAY BE USED IN EITHER EARTH OR MOON CENTERED COORDINATES. THE TFF ROUTINES NEVER
053347,000024:                                                                                                  #  KNOW WHICH ORIGIN APPLIES. IT IS THE USER WHO KNOWS, AND WHO SUPPLIES  RONE, VONE AND 1/SQRT(MU)  AT THE
053348,000025:                                                                                                  #  APPROPRIATE SCALE LEVEL FOR THE PROPER PRIMARY BODY.
053349,000026: 
053350,000027:                                                                                                  #        EARTH ORIGIN    POSITION        -29     METERS
053351,000028:                                                                                                  #                        VELOCITY        -7      METERS/CENTISECOND
053352,000029:                                                                                                  #                        1/SQRT(MU)      +17     SQRT(CS SQ/METERS CUBED)
053353,000030: 
053354,000031:                                                                                                  #        MOON ORIGIN     POSITION        -27     METERS
053355,000032:                                                                                                  #                        VELOCITY        -5      METERS/CENTISECONDS
053356,000033:                                                                                                  #                        1/SQRT(MU)      +14     SQRT(CS SQ/METERS CUBED)
053357,000034: 
053358,000035:                                                                                                  #  ALL DATA PROVIDED TO AND RECEIVED FROM ANY TFF SUBROUTINE WILL BE AT ONE OF THE LEVELS ABOVE. IN ALL CASES,
053359,000036:                                                                                                  #  THE FREE FALL TIME IS RETURNED IN CENTISECONDS AT (-28). PROGRAM  TFF/CONIC  WILL GENERATE VONE/RTMU AND
053360,000037:                                                                                                  #  LEAVE IT IN VONE' AT (+10) IF EARTH ORIGIN AND (+9) IF MOON ORIGIN.
053361,000038:                                                                                                  #           THE USER MUST STORE THE STATE VECTOR IN  RONE, VONE  AND MU IN  THE FORM 1/SQRT(MU) IN  TFF/RTMU
053362,000039:                                                                                                  #  AT THE PROPER SCALE BEFORE CALLING  TFF/CONIC. SINCE  RONE, VONE  ARE IN THE EXTENDED VERB STORAGE AREA,
053363,000040:                                                                                                  #  THE USER MUST ALSO LOCK OUT THE EXTENDED VERBS, AND RELEASE THEM WHEN FINISHED.
053364,000041:                                                                                                  #           PROGRAMS     CALC/TFF  AND  CALC/TPER  ASSUME THAT THE TERMINAL RADIUS IS LESS THAN THE PRESENT
053365,000042:                                                                                                  #  RADIUS. THIS RESTRICTION CAN BE REMOVED BY A  15 W CODING CHANGE, BUT AT PRESENT IT IS NOT DEEMED NECESSARY.
053366,000043: 
053367,000044:                                                                                                  #           THE FOLLOWING ERASABLE QUANTITIES ARE USED BY THE TFF ROUTINES, AND ARE LOCATED IN THE PUSH LIST.
053368,000045: 
053369,000046:                                                                                                  #                                        BELOW   E:  IS USED FOR EARTH ORIGIN SCALE
053370,000047:                                                                                                  #                                                M:  IS USED FOR MOON  ORIGIN SCALE
053371,000048: 
053372,000049:                                                                                                  # TFFSW          =       119D    BIT1    0 = CALCTFF             1 = CALCTPER
053373,000050: 10,2213                        TFFDELQ            =        10D                                   #  Q2-Q1                   E: (-16)  M: (-15)
053374,000051: 10,2213                        RMAG1              =        12D                                   #  ABVAL(RN)  M            E: (-29)  M: (-27)
053375,000052:                                                                                                  # RPER           =       14D             PERIGEE RADIUS  M       E: (-29)  M: (-27)
053376,000053: 10,2213                        TFFQ1              =        14D                                   #  R.V / SQRT(MUE)         E: (-16)  M: (-15)
053377,000054:                                                                                                  # SDELF/2                                SIN(THETA) /2
053378,000055: 10,2213                        CDELF/2            =        14D                                   #  COS(THETA) /2
053379,000056:                                                                                                  # RAPO           =       16D             APOGEE RADIUS  M        E: (-29)  M: (-27)
053380,000057: 10,2213                        NRTERM             =        16D                                   #  TERMINAL RADIUS  M      E: (-29+NR)
053381,000058:                                                                                                  #                          M: (-27+NR)
053382,000059: 10,2213                        RTERM              =        18D                                   #  TERMINAL RADIUS  M      E: (-29)  M: (-27)
053383,000060: 10,2213                        TFFVSQ             =        20D                                   #  -(V SQUARED/MU)  1/M    E: (20)   M: (18)
053384,000061: 10,2213                        TFF1/ALF           =        22D                                   #  SEMI MAJ AXIS  M        E: (-22-2 NA)
053385,000062:                                                                                                  #                          M: (-20-2 NA)
053386,000063: 10,2213                        TFFRTALF           =        24D                                   #  SQRT(ALFA)              E:(10+NA) M: (9+NA)
053387,000064: 10,2213                        TFFALFA            =        26D                                   #  ALFA  1/M               E:(26-NR) M: (24-NR)
053388,000065: 10,2213                        TFFNP              =        28D                                   #  SEMI LATUS RECTUM  M    E: (-38+2 NR)
053389,000066:                                                                                                  #                          M: (-36+2 NR)
053390,000067: 10,2213                        TFF/RTMU           =        30D                                   #  1/SQRT(MU)              E: (17)   M: (14)
053391,000068: 10,2213                        NRMAG              =        32D                                   #  PRESENT RADIUS  M       E: (-29+NR)
053392,000069:                                                                                                  #                          M: (-27+NR)
053393,000070: 10,2213                        TFFX               =        34D                                   
053394,000071: 10,2213                        TFFTEM             =        36D                                   #  TEMPORARY

Page 1259

053396,000073:                                                                                                  #                REGISTERS S1, S2 ARE UNTOUCHED BY ANY TFF SUBROUTINE
053397,000074:                                                                                                  #                INDEX REGISTERS X1, X2 ARE USED BY ALL TFF SUBROUTINES. THEY ARE ESTAB-
053398,000075:                                                                                                  #                LISHED IN TFF/CONIC AND MUST BE PRESERVED BETWEEN CALLS TO SUBSEQUENT
053399,000076:                                                                                                  #                SUBROUTINES.
053400,000077:                                                                                                  #                -NR                             C(X1) = NORM COUNT OF RMAG
053401,000078:                                                                                                  #                -NA                             C(X2)= NORM COUNT OF SQRT(ABS(ALFA))
053402,000079: 

Page 1260

053404,000081:                                                                                                  #  SUBROUTINE NAME:     TFFCONIC                                            DATE:    01.29.67
053405,000082:                                                                                                  #  MOD NO:  0                                                               LOG SECTION:    TIME OF FREE FALL
053406,000083:                                                                                                  #  MOD BY:  RR BAIRNSFATHER
053407,000084:                                                                                                  #  MOD NO:  1           MOD BY:  RR BAIRNSFATHER      DATE: 11 APR 67
053408,000085:                                                                                                  #  MOD NO:  2           MOD BY:  RR BAIRNSFATHER      DATE: 21 NOV 67       ADD MOON MU.
053409,000086:                                                                                                  #  MOD NO:  3           MOD BY:  RR BAIRNSFATHER      DATE: 21 MAR 68       ACCEPT DIFFERENT EARTH/MOON SCALES
053410,000087:                                                                                                  #  FUNCTIONAL DESCRIPTION:      THIS SUBROUTINE IS CALLED TO COMPUTE THOSE CONIC PARAMETERS REQUIRED BY THE TFF
053411,000088:                                                                                                  #           SUBROUTINES AND TO ESTABLISH THEM IN THE PUSH LIST AREA. THE PARAMETERS ARE LISTED UNDER OUTPUT.
053412,000089:                                                                                                  #           THE EQUATIONS ARE
053413,000090:                                                                                                  #                  -   -  -
053414,000091:                                                                                                  #                  H = RN*VN                                               ANGULAR MOMENTUM
053415,000092:                                                                                                  #                        - -
053416,000093:                                                                                                  #                  LCP = H.H / MU                                          SEMI LATUS RECTUM
053417,000094:                                                                                                  #                                -  -
053418,000095:                                                                                                  #                  ALFA = 2/RN - VN.VN / MU                                RECIPROCAL SEMI MAJ AXIS, SIGNED
053419,000096: 
053420,000097:                                                                                                  #           AND ALFA IS POS FOR ELLIPTIC ORBITS
053421,000098:                                                                                                  #                        0  FOR PARABOLIC ORBITS
053422,000099:                                                                                                  #                       NEG FOR HYPERBOLIC ORBITS.
053423,000100:                                                                                                  #           SUBROUTINE ALSO COMPUTES AND SAVES RMAG.
053424,000101:                                                                                                  #  CALLING SEQUENCE:
053425,000102:                                                                                                  #           TFFCONIC  EXPECTS CALLER TO ENTER WITH CORRECT GRAVITATIONAL CONSTANT IN MPAC, IN THE FORM
053426,000103:                                                                                                  #           1/SQRT(MU). PROGRAM WILL SAVE IN  TFF/RTMU  . THE SCALE IS DETERMINED BY WHETHER EARTH OR MOON
053427,000104:                                                                                                  #           ORIGIN IS USED.  THE CALLER MUST LOCK OUT THE EXTENDED VERBS BEFORE PROVIDING STATE VECTOR IN RONE,
053428,000105:                                                                                                  #           VONE  AT PROPER SCALE. THE EXTENDED VERBS MUST BE RESTORED WHEN THE CALLER IS FINISHED USING THE
053429,000106:                                                                                                  #           TFF ROUTINES.
053430,000107:                                                                                                  #           ENTRY POINT  TFFCONMU  EXPECTS THAT  TFF/RTMU  IS ALREADY LOADED.
053431,000108:                                                                                                  #           TO SPECIFY MU:      DLOAD   CALL               IF MU ALREADY STORED:    CALL
053432,000109:                                                                                                  #                                       YOURMU  1/RTMU       E:(17) M:(14)                TFFCONMU
053433,000110:                                                                                                  #                                       TFFCONIC
053434,000111:                                                                                                  #           PUSHLOC = PDL+0, ARBITRARY IF LEQ 18D
053435,000112: 
053436,000113:                                                                                                  #  SUBROUTINES CALLED:  NONE
053437,000114:                                                                                                  #  NORMAL EXIT MODES:  RVQ
053438,000115:                                                                                                  #  ALARMS:  NONE
053439,000116:                                                                                                  #  OUTPUT:  THE FOLLOWING ARE STORED IN THE PUSH LIST AREA.
053440,000117:                                                                                                  #           RMAG1  E:(-29) M:(-27) M  RN, PRESENT RADIUS LENGTH.
053441,000118:                                                                                                  #           NRMAG  E:(-29+NR)      M  RMAG, NORMALIZED
053442,000119:                                                                                                  #                  M:(-27+NR)
053443,000120:                                                                                                  #           X1                     -NR, NORM COUNT
053444,000121:                                                                                                  #           TFFNP  E:(-38+2NR)     M  LCP, SEMI LATUS RECTUM, WEIGHTED BY NR.       FOR VGAMCALC
053445,000122:                                                                                                  #                  M:(-36+2NR)
053446,000123:                                                                                                  #           TFF/RTMU E:(17)  M:(14)        1/SQRT(MU)
053447,000124:                                                                                                  #           TFFVSQ E:(20)  M:(18) 1/M    -(V SQ/MU): PRESENT VELOCITY,NORMLIZED.    FOR VGAMCALC
053448,000125:                                                                                                  #           TFFALFA  E:(26-NR)    1/M    ALFA, WEIGHTED BY NR
053449,000126:                                                                                                  #                    M:(24-NR)
053450,000127:                                                                                                  #           TFFRTALF  E:(10+NA)   SQRT(ALFA), NORMALIZED
053451,000128:                                                                                                  #                     M:(9+NA)

Page 1261

053453,000130:                                                                                                  #           X2                    -NA, NORMCOUNT
053454,000131:                                                                                                  #           TFF1/ALF  E:(-22-2NA) SIGNED SEMI MAJ AXIS, WEIGHTED BY NA
053455,000132:                                                                                                  #                     M:(-20-2NA)
053456,000133:                                                                                                  #           PUSHLOC AT PDL+0
053457,000134:                                                                                                  #           THE FOLLOWING  IS STORED IN GENERAL ERASABLE
053458,000135:                                                                                                  #           VONE'  E:(10)  M:(9)   V/RT(MU), NORMALIZED VELOCITY
053459,000136:                                                                                                  #  ERASABLE INITIALIZATION REQUIRED:
053460,000137:                                                                                                  #           RONE   E:(-29)  M:(-27)  M      STATE VECTOR                LEFT BY CALLER
053461,000138:                                                                                                  #           VONE   E:(-7)   M:(-5)   M/CS   STATE VECTOR                LEFT BY CALLER
053462,000139:                                                                                                  #           TFF/RTMU  E:(17)  M:(14)      1/RT(CS SQ/M CUBE)            IF ENTER VIA  TFFCONMU.
053463,000140:                                                                                                  #  DEBRIS:  QPRET,    PDL+0 ... PDL+3
053464,000141: 
053465,000142: 33,3762                                           BANK     33                                    
053466,000143: 27,2000                                           SETLOC   TOF-FF                                
053467,000144: 27,2000                                           BANK                                           
053468,000145: 
053469,000146: 27,3360                                           COUNT*   $$/TFF                                
053470,000147: 
053471,000148: 27,3360           00037        TFFCONIC           STORE    TFF/RTMU                              #  1/SQRT(MU)       E:(17)    M:(14)
053472,000149: 
053473,000150: 27,3361           53575        TFFCONMU           VLOAD    UNIT                                  #  COME HERE WITH TFFRTMU LOADED.
053474,000151: 27,3362           02207                                    RONE                                  #  SAVED RN.  M     E:(-29)   M:(-27)
053475,000152: 27,3363           77725                           PDDL                                           #  UR/2 TO PDL+0, +5
053476,000153: 27,3364           00045                                    36D                                   #  MAGNITUDE
053477,000154: 27,3365           00015                           STORE    RMAG1                                 #  M    E:(-29)    M:(-27)
053478,000155: 
053479,000156: 27,3366           77701                           NORM                                           
053480,000157: 27,3367           00047                                    X1                                    #  -NR
053481,000158: 27,3370           24041                           STOVL    NRMAG                                 #  RMAG  M   E: (-29+NR)  M: (-27+NR)
053482,000159: 27,3371           02215                                    VONE                                  #  SAVED VN.  M/CS   E: (-7)   M: (-5)
053483,000160: 27,3372           77761                           VXSC                                           
053484,000161: 27,3373           00037                                    TFF/RTMU                              #  E: (17)   M: (14)
053485,000162: 27,3374           02170                           STORE    VONE'                                 #  VN/SQRT(MU)   E: (10)   M: (9)
053486,000163: 
053487,000164: 27,3375           47361                           VXSC     VXV                                   
053488,000165: 27,3376           00041                                    NRMAG                                 #  E: (-29+NR)  M: (-27+NR)
053489,000166:                                                                                                  #  UR/2 FROM PDL
053490,000167: 27,3377           47572                           VSL1     VSQ                                   #  BEFORE:  E:(-19+NR)  M:(-18+NR)
053491,000168: 27,3400           14035                           STODL    TFFNP                                 #  LC P  M   E:(-38+2NR) M:(-36+2NR)
053492,000169:                                                                                                  #  SAVE ALSO FOR VGAMCALC
053493,000170: 27,3401           06514                                    TFF1/4                                
053494,000171: 27,3402           63271                           DDV      PDVL                                  #  (2/RMAG)  1/M   E:(26-NR)   M:(24-NR)
053495,000172: 27,3403           00041                                    NRMAG                                 #  RMAG  M   E:(-29+NR)  M:(-27+NR)
053496,000173: 27,3404           02170                                    VONE'                                 #  SAVED VN.   E:(10)    M:(9)
053497,000174: 27,3405           57436                           VSQ      DCOMP                                 #  KEEP MPAC+2 HONEST FOR SQRT.
053498,000175: 27,3406           00025                           STORE    TFFVSQ                                #  -(V SQ/MU)   E:(20)   M:(18)
053499,000176:                                                                                                  #  SAVE FOR VGAMCALC
053500,000177: 27,3407           43257                           SR*      DAD                                   

Page 1262

053502,000179: 27,3410           20573                                    0          -6,1                       #  GET -VSQ/MU   E:(26-NR)  M:(24-NR)
053503,000180: 27,3411           77626                           STADR                                          
053504,000181:                                                                                                  #  2/RMAG   FROM PDL+2
053505,000182: 27,3412           77744                           STORE    TFFALFA                               #  ALFA  1/M  E:(26-NR)   M:(24-NR)
053506,000183: 27,3413           41457                           SL*      PUSH                                  #  TEMP SAVE ALFA   E:(20)    M:(18)
053507,000184: 27,3414           20173                                    0          -6,1                       
053508,000185: 27,3415           75446                           ABS      SQRT                                  #  E:(10)   M:(9)
053509,000186: 27,3416           77701                           NORM                                           
053510,000187: 27,3417           00050                                    X2                                    #  X2 = -NA
053511,000188: 27,3420           00031                           STORE    TFFRTALF                              #  SQRT( ABS(ALFA) )  E:(10+NA)   M:(9+NA)
053512,000189: 27,3421           75316                           DSQ      SIGN                                  #  NOT SO ACCURATE, BUT OK
053513,000190:                                                                                                  #  ALFA FROM PDL+2   E:(20)   M:(18)
053514,000191: 27,3422           55254                           BZE      BDDV                                  #  SET 1/ALFA =0, TO SHOW SMALL ALFA
053515,000192: 27,3423           57425                                    +2                                    
053516,000193: 27,3424           06514                                    TFF1/4                                
053517,000194: 27,3425           00027                 +2        STORE    TFF1/ALF                              #  1/ALFA   E:(-22-2NA)    M:(-20-2NA)
053518,000195: 27,3426           77616        DUMPCNIC           RVQ                                            
053519,000196: 
053520,000197:                                                                                                  #                                                                                          39 W

Page 1263

053522,000199:                                                                                                  #  SUBROUTINE NAME:      TFFRP/RA                                            DATE:  01.17.67
053523,000200:                                                                                                  #  MOD NO:  0                                                                LOG SECTION:    TIME OF FREE FALL
053524,000201:                                                                                                  #  MOD BY:  RR BAIRNSFATHER
053525,000202:                                                                                                  #  MOD NO:  1           MOD BY:  RR BAIRNSFATHER       DATE: 11 APR 67
053526,000203:                                                                                                  #  MOD NO:  2           MOD BY:  RR BAIRNSFATHER       DATE: 21 MAR 68       ACCEPT DIFFERENT EARTH/MOON SCALES
053527,000204:                                                                                                  #                                                                            ALSO IMPROVE ACCURACY OF RAPO.
053528,000205: 
053529,000206:                                                                                                  #  FUNCTIONAL DESCRIPTION:          USED BY CALCTPER AND TFF DISPLAYS TO CALCULATE PERIGEE RADIUS AND ALSO
053530,000207:                                                                                                  #           APOGEE RADIUS FOR A GENERAL CONIC.
053531,000208:                                                                                                  #           PROGRAM GIVES PERIGEE RADIUS AS                APOGEE RADIUS IS GIVEN BY
053532,000209:                                                                                                  #                  RP = P/(1+E)                                   RA = (1+E) / ALFA
053533,000210:                                                                                                  #           WHERE   2
053534,000211:                                                                                                  #                  E  = 1 - P ALFA
053535,000212:                                                                                                  #           IF RA IS NEGATIVE OR SHOWS DIVIDE OVERFLOW, THEN RA = POSMAX BECAUSE
053536,000213:                                                                                                  #                  1. APOGEE RADIUS IS NOT MEANINGFUL FOR HYPERBOLA
053537,000214:                                                                                                  #                  2. APOGEE RADIUS IS NOT DEFINED FOR PARABOLA
053538,000215:                                                                                                  #                  3. APOGEE RADIUS EXCEEDS THE SCALING FOR ELLIPSE.
053539,000216:                                                                                                  #           THIS SUBROUTINE REQUIRES THE SIGNED RECIPROCAL SEMI MAJ AXIS,  ALFA,  AND SEMI LATUS RECTUM AS DATA.
053540,000217:                                                                                                  #  CALLING SEQUENCE:  CALL
053541,000218:                                                                                                  #                            TFFRP/RA
053542,000219:                                                                                                  #           PUSHLOC = PDL+0, ARBITRARY IF LEQ 10D
053543,000220:                                                                                                  #           C(MPAC) UNSPECIFIED
053544,000221: 
053545,000222:                                                                                                  #  SUBROUTINES CALLED:  NONE
053546,000223:                                                                                                  #  NORMAL EXIT MODE:    RVQ
053547,000224:                                                                                                  #           IF ELLIPSE, WITHIN NORMAL SCALING, RAPO IS CORRECT.
053548,000225:                                                                                                  #           OTHERWISE, RAPO = POSMAX.
053549,000226:                                                                                                  #  ALARMS:  NONE
053550,000227:                                                                                                  #  OUTPUT:  STORED IN PUSH LIST AREA. SCALE OF OUTPUT AGREES WITH DATA SUPPLIED TO  TFF/CONIC.
053551,000228:                                                                                                  #           RPER   E:(-29) M:(-27)   M     PERIGEE RADIUS                  DESTROYED BY CALCTFF/CALCTPER, TFFTRIG.
053552,000229:                                                                                                  #           RAPO   E:(-29) M:(-27)   M     APOGEE RADIUS                   WILL BE DESTROYED BY CALCTFF/CALCTPER
053553,000230:                                                                                                  #           PUSHLOC AT PDL+0
053554,000231:                                                                                                  #  ERASABLE INITIALIZATION REQUIRED:
053555,000232:                                                                                                  #           TFFALFA E:(26-NR)      M       1/SEMI MAJ AXIS                 LEFT BY TFFCONIC
053556,000233:                                                                                                  #                   M:(24-NR)
053557,000234:                                                                                                  #           TFFNP  E: (-38+2NR)    M      LC P, SEMI LATUS RECTUM          LEFT BY TFFCONIC
053558,000235:                                                                                                  #                  M: (-36+2NR)
053559,000236:                                                                                                  #           X1                     -NR, NORM COUNT OF RMAG                 LEFT BY TFFCONIC
053560,000237:                                                                                                  #           X2                     -NA, NORM COUNT OF ALFA                 LEFT BY TFFCONIC
053561,000238:                                                                                                  #  DEBRIS:  QPRET,   PDL+0 ... PDL+1
053562,000239: 

Page 1264

053564,000241: 27,3427                        RAPO               =        16D                                   #  APOGEE RADIUS  M  E:(-29) M:(-27)
053565,000242: 27,3427                        RPER               =        14D                                   #  PERIGEE RADIUS  M  E:(-29) M:(-27)
053566,000243: 
053567,000244: 27,3427           41345        TFFRP/RA           DLOAD    DMP                                   
053568,000245: 27,3430           00033                                    TFFALFA                               #  ALFA  1/M  E:(26-NR)   M:(24-NR)
053569,000246: 27,3431           00035                                    TFFNP                                 #  LC P  M   E:(-38+2NR)   M:(-36+2NR)
053570,000247: 27,3432           57457                           SR*      DCOMP                                 #  ALFA P (-12+NR)
053571,000248: 27,3433           20571                                    0          -8D,1                      #  ALFA P  (-4)
053572,000249: 27,3434           51415                           DAD      ABS                                   #  (DCOMP GIVES VALID TP RESULT FOR SQRT)
053573,000250:                                                                                                  #  (ABS PROTECTS SQRT IF E IS VERY NEAR 0)
053574,000251: 27,3435           17765                                    DP2(-4)                               
053575,000252: 27,3436           43366                           SQRT     DAD                                   #  E SQ = (1- P ALFA) (-4)
053576,000253: 27,3437           06514                                    TFF1/4                                
053577,000254: 27,3440           55206                           PUSH     BDDV                                  #  (1+E)  (-2)  TO PDL+0
053578,000255: 27,3441           00035                                    TFFNP                                 #  LCP  M  E:(-38+2NR)  M:(-36+2NR)
053579,000256: 27,3442           53657                           SR*      SR*                                   #  (DOES SR THEN SL TO AVOID OVFL)
053580,000257: 27,3443           20601                                    0,1                                   #  X1=-NR
053581,000258: 27,3444           20572                                    0          -7,1                       #  (EFFECTIVE SL)
053582,000259: 27,3445           14017                           STODL    RPER                                  #  PERIGEE RADIUS   M  E:(-29)   M:(-27)
053583,000260:                                                                                                  #  (1+E)  (-2)   FROM PDL+0
053584,000261: 27,3446           41005                           DMP      BOVB                                  
053585,000262: 27,3447           00027                                    TFF1/ALF                              #  E:(-22-2NA)  M:(-20-2NA)
053586,000263: 27,3450           57753                                    TCDANZIG                              #  CLEAR OVFIND, IF ON.
053587,000264: 27,3451           53654                           BZE      SL*                                   
053588,000265: 27,3452           57461                                    MAXRA                                 #  SET POSMAX, IF ALFA=0
053589,000266: 27,3453           57603                                    0          -5,2                       #  -5+NA
053590,000267: 27,3454           40057                           SL*      BOV                                   
053591,000268: 27,3455           57576                                    0,2                                   
053592,000269: 27,3456           57461                                    MAXRA                                 #  SET POSMAX IF OVFL.
053593,000270: 27,3457           77644                           BPL                                            #  CONTINUE WITH VALID RAPO.
053594,000271: 27,3460           57463                                    +3                                    
053595,000272: 27,3461           77745        MAXRA              DLOAD                                          #  RAPO CALC IS NOT VALID.  SET RAPO =
053596,000273: 27,3462           17771                                    NEARONE                               #  POSMAX AS A TAG.
053597,000274: 27,3463           00021                 +3        STORE    RAPO                                  #  APOGEE RADIUS  M   E:(-29)    M:(-27)
053598,000275: 27,3464           77616        DUMPRPRA           RVQ                                            
053599,000276: 
053600,000277:                                                                                                  #                                                                30 W

Page 1265

053602,000279:                                                                                                  #  SUBROUTINE NAME:     CALCTPER / CALCTFF                                 DATE:    01.29.67
053603,000280:                                                                                                  #  MOD NO:  0                                                              LOG SECTION:    TIME OF FREE FALL
053604,000281:                                                                                                  #  MOD BY:  RR BAIRNSFATHER
053605,000282:                                                                                                  #  MOD NO:  1           MOD BY:  RR BAIRNSFATHER      DATE: 21 MAR 67
053606,000283:                                                                                                  #  MOD NO:  2           MOD BY:  RR BAIRNSFATHER      DATE: 14 APR 67
053607,000284:                                                                                                  #  MOD NO:  3           MOD BY:  RR BAIRNSFATHER      DATE: 8 JUL 67       NEAR EARTH MUE AND NEG TFF (GONEPAST)
053608,000285:                                                                                                  #  MOD NO:  4           MOD BY:  RR BAIRNSFATHER      DATE: 21 NOV 67      ADD VARIABLE MU.
053609,000286:                                                                                                  #  MOD NO:  5           MOD BY:  RR BAIRNSFATHER      DATE: 21 MAR 68      ACCEPT DIFFERENT EARTH/MOON SCALES
053610,000287:                                                                                                  #  FUNCTIONAL DESCRIPTION:      PROGRAM CALCULATES THE FREE-FALL TIME OF FLIGHT FROM PRESENT POSITION  RN  AND
053611,000288:                                                                                                  #           VELOCITY  VN  TO A RADIUS LENGTH SPECIFIED BY  RTERM  , SUPPLIED BY THE USER. THE POSITION VECTOR
053612,000289:                                                                                                  #           RN  MAY BE ON EITHER SIDE OF THE CONIC, BUT  RTERM  IS CONSIDERED ON THE INBOUND SIDE.
053613,000290:                                                                                                  #           THE EQUATIONS ARE
053614,000291: 
053615,000292:                                                                                                  #                  Q2 = -SQRT(RTERM (2-RTERM ALFA) - LCP)    (INBOUND SIDE))        LEQ +- LCE/SQRT(ALFA)
053616,000293:                                                                                                  #                       -  -
053617,000294:                                                                                                  #                  Q1 = RN.VN / SQRT(MU)                                            LEQ +- LCE/SQRT(ALFA)
053618,000295: 
053619,000296:                                                                                                  #                  Z = NUM / DEN                                                    LEQ +- 1/SQRT(ALFA)
053620,000297: 
053621,000298:                                                                                                  #           WHERE, IF INBOUND
053622,000299:                                                                                                  #                  NUM = RTERM -RN                                                  LEQ +- 2 LCE/ALFA
053623,000300:                                                                                                  #                  DEN = Q2+Q1                                                      LEQ +- 2 LCE/SQRT(ALFA)
053624,000301: 
053625,000302:                                                                                                  #           AND, IF OUTBOUND 
053626,000303:                                                                                                  #                  NUM = Q2-Q1                                                      LEQ +- 2 LCE/SQRT(ALFA)
053627,000304:                                                                                                  #                  DEN = 2 - ALFA (RTERM + RN) .                                    LEQ +- 2 LCE
053628,000305: 
053629,000306:                                                                                                  #           IF     ALFA ZZ  <  1.0               (FOR ALL CONICS EXCEPT ELLIPSES HAVING ABS(DEL ECC ANOM) G 90 DEG)
053630,000307: 
053631,000308:                                                                                                  #           THEN   X = ALFA Z Z
053632,000309:                                                                                                  #           AND    TFF = (RTERM +RN -2 ZZ T(X) ) Z/SQRT(MU)
053633,000310: 
053634,000311:                                                                                                  #                  EXCEPT  IF ALFA PNZ, AND IF TFF NEG,
053635,000312:                                                                                                  #                  THEN    TFF = 2 PI /(ALFA SQRT(ALFA)) + TFF
053636,000313: 
053637,000314:                                                                                                  #           OR     IF ALFA ZZ GEQ 1.0             (FOR ELLIPSES HAVING ABS(DEL ECC ANOM) GEQ 90 DEG)
053638,000315: 
053639,000316:                                                                                                  #           THEN   X = 1/ALFA Z Z
053640,000317:                                                                                                  #           AND    TFF = (PI/SQRT(ALFA) -Q2 +Q1 +2(X T(X) -1) /ALFA Z) /ALFA SQRT(MU)
053641,000318: 
053642,000319:                                                                                                  #           WHERE  T(X) IS A POLYNOMIAL APPROXIMATION TO THE SERIES
053643,000320:                                                                                                  #                             2     3                        2
053644,000321:                                                                                                  #                  1/3 -X/5 +X /7 -X /9 ...                (X   <  1.0)
053645,000322: 
053646,000323:                                                                                                  #  CALLING SEQUENCE:  TIME TO RTERM                           TIME TO PERIGEE
053647,000324:                                                                                                  #                     CALL                                    CALL
053648,000325:                                                                                                  #                             CALCTFF                                CALCTPER
053649,000326:                                                                                                  #                     C(MPAC) = TERMNL RAD M                  C(MPAC) = PERIGEE RAD M
053650,000327:                                                                                                  #           FOR EITHER,   E:(-29)     M:(-27)
053651,000328:                                                                                                  #           FOR EITHER, PUSHLOC = PDL+0, ARBITRARY IF LEQ 8D.

Page 1266

053653,000330: 
053654,000331:                                                                                                  #  SUBROUTINES CALLED:  T(X), VIA RTB
053655,000332:                                                                                                  #  NORMAL EXIT MODE:  RVQ
053656,000333:                                                                                                  #           HOWEVER, PROGRAM EXITS WITH ONE OF THE FOLLOWING VALUES FOR TFF (-28) CS  IN MPAC. USER MUST STORE.
053657,000334:                                                                                                  #                  A. TFF = FLIGHT TIME. NORMAL CASE FOR POSITIVE FLIGHT TIME LESS THAN ONE ORBITAL PERIOD.
053658,000335:                                                                                                  #                  B. (THIS OPTION IS NO LONGER USED.)
053659,000336:                                                                                                  #                  C. TFF = POSMAX.  THIS INDICATES THAT THE CONIC FROM THE PRESENT POSITION WILL NOT RETURN TO
053660,000337:                                                                                                  #                     THE SPECIFIED ALTITUDE.  ALSO INDICATES OUTBOUND PARABOLA OR HYPERBOLA.
053661,000338:                                                                                                  #  OUTPUT:  C(MPAC)  (-28)  CS    TIME OF FLIGHT, OR TIME TO PERIGEE
053662,000339:                                                                                                  #           TFFX    (0)           X,                                      LEFT FOR ENTRY DISPLAY TFF ROUTINES
053663,000340:                                                                                                  #           NRTERM  E:(-29+NR)    M  RTERM, WEIGHTED BY NR                LEFT FOR ENTRY DISPLAY TFF ROUTINES
053664,000341:                                                                                                  #                   M:(-27+NR)
053665,000342:                                                                                                  #           TFFTEM  E:(-59+2NR)   LCP Z Z SGN(SDELF)                      LEFT FOR ENTRY DISPLAY TFF ROUTINES
053666,000343:                                                                                                  #                   M:(-55+2NR)   LCP /ALFA SGN(SDELF)                    LEFT FOR ENTRY DISPLAY TFF ROUTINES
053667,000344:                                                                                                  #           NOTE:  TFFTEM = PDL 36D AND WILL BE DESTROYED BY .:UNIT:.
053668,000345:                                                                                                  #           RMAG1  E:(-29) M:(-27) PDL 12 NOT TOUCHED.
053669,000346:                                                                                                  #           TFFQ1  E:(-16) M:(-15) PDL 14D
053670,000347:                                                                                                  #           TFFDELQ E:(-16) M:(-15) PDL 10D
053671,000348:                                                                                                  #           PUSHLOC AT PDL+0
053672,000349:                                                                                                  #  ERASABLE INITIALIZATION REQUIRED:
053673,000350:                                                                                                  #           RONE   E:(-29)  M:(-27)  M   STATE VECTOR                      LEFT BY USER
053674,000351:                                                                                                  #           VONE'  E:(+10)  M:(+9)   VN/SQRT(MU)                           LEFT BY TFF/CONIC
053675,000352:                                                                                                  #           RMAG1  E:(-29)  M:(-27)  PRESENT RADIUS,  M                    LEFT BY TFFCONIC
053676,000353:                                                                                                  #           C(MPAC)E:(-29)  M:(-27)  RTERM, TERMINAL RADIUS LENGTH, M      LEFT BY USER
053677,000354: 
053678,000355:                                                                                                  #           THE FOLLOWING ARE STORED IN THE PUSH LIST AREA.
053679,000356:                                                                                                  #           TFF/RTMU  E:(17)  M:(14)  1/SQRT(MU)                           LEFT BY TFFCONIC.
053680,000357:                                                                                                  #           NRMAG  E: (-29+NR)  M  RMAG, NORMALIZED                        LEFT BY TFFCONIC
053681,000358:                                                                                                  #                  M: (-27+NR)
053682,000359:                                                                                                  #           X1                     -NR, NORM COUNT                         LEFT BY TFFCONIC
053683,000360:                                                                                                  #           TFFNP  E: (-38+2NR)  M   LCP, SEMI LATUS RECTUM, WEIGHT NR     LEFT BY TFFCONIC
053684,000361:                                                                                                  #                  M: (-36+2NR)
053685,000362:                                                                                                  #           TFFALFA  E: (26-NR)    1/M  ALFA, WEIGHT NR                    LEFT BY TFFCONIC
053686,000363:                                                                                                  #                    M: (24-NR)
053687,000364:                                                                                                  #           TFFRTALF  E:(10+NA)    SQRT(ALFA), NORMALIZED                  LEFT BY TFFCONIC
053688,000365:                                                                                                  #                     M:(9+NA)
053689,000366:                                                                                                  #           X2                     -NA, NORMCOUNT                          LEFT BY TFFCONIC
053690,000367:                                                                                                  #           TFF1/ALF  E:(-22-2NA)   SIGNED SEMIMAJ AXIS, WEIGHTED BY NA    LEFT BY TFFCONIC
053691,000368:                                                                                                  #                     M:(-20-2NA)
053692,000369:                                                                                                  #  DEBRIS:  QPRET,   PDL+0 ... PDL+3
053693,000370:                                                                                                  #           RTERM  E:(-29)  M:(-27)  RTERM, TERMINAL RADIUS LENGTH
053694,000371:                                                                                                  #           RAPO   E:(-29)  M:(-27)  PDL 16D  (=NRTERM)
053695,000372:                                                                                                  #           RPER   E:(-29)  M:(-27)  PDL 14D   (=TFFQ1)
053696,000373: 

Page 1267

053698,000375: 27,3465           77614        CALCTPER           SETGO                                          #  ENTER WITH RPER IN MPAC
053699,000376: 27,3466           03436                                    TFFSW                                 
053700,000377: 27,3467           57472                                    +3                                    
053701,000378: 27,3470           77614        CALCTFF            CLEAR                                          #  ENTER WITH RTERM IN MPAC
053702,000379: 27,3471           03676                                    TFFSW                                 
053703,000380: 27,3472           00023                 +3        STORE    RTERM                                 #  E: (-29)  M: (-27)
053704,000381: 27,3473           77657                           SL*                                            
053705,000382: 27,3474           20201                                    0,1                                   #  X1=-NR
053706,000383: 27,3475           00021                           STORE    NRTERM                                #  RTERM  E: (-29+NR)  M: (-27+NR)
053707,000384: 27,3476           44205                           DMP      BDSU                                  
053708,000385: 27,3477           00033                                    TFFALFA                               #  ALFA  E: (26-NR)  M: (24-NR)
053709,000386: 27,3500           06514                                    TFF1/4                                
053710,000387: 27,3501           41206                           PUSH     DMP                                   #  (2-ALFA RTERM)  (-3)  TO PDL+0
053711,000388: 27,3502           00021                                    NRTERM                                #  E: (-29+NR)  M: (-27+NR)
053712,000389: 27,3503           53725                           PDDL     SR*                                   #  RTERM(2-ALFA RTERM) TO PDL+2
053713,000390:                                                                                                  #  E: (-32+NR)   M: (-30+NR)
053714,000391: 27,3504           00035                                    TFFNP                                 #  LC P  E:(-38+2NR)  M:(-36+2NR)
053715,000392: 27,3505           20573                                    0          -6,1                       #  X1 = -NR
053716,000393: 27,3506           43276                           DCOMP    DAD                                   #  DUE TO SHIFTS, KEEP PRECISION FOR SQRT
053717,000394:                                                                                                  #  RTERM(2-ALFA RTERM) FROM PDL +2
053718,000395:                                                                                                  #  E: (-32+NR)  M: (-30+NR)
053719,000396: 27,3507           77657                           SR*                                            #  LEAVE  E: (-32)  M: (-30)
053720,000397: 27,3510           20601                                    0,1                                   #  X1 = -NR
053721,000398: 27,3511           71214                           BOFF     DLOAD                                 #  CHECK TFF / TPER SWITCH
053722,000399: 27,3512           03756                                    TFFSW                                 
053723,000400: 27,3513           57515                                    +2                                    #  IF TFF, CONTINUE
053724,000401: 27,3514           06524                                    TFFZEROS                              #  IF TPER, SET Q2 = 0
053725,000402: 27,3515           75440                 +2        BMN      SQRT                                  #  E: (-16)  M: (-15)
053726,000403: 
053727,000404: 27,3516           57650                                    MAXTFF1                               #  NO FREE FALL CONIC TO RTERM FROM HERE
053728,000405:                                                                                                  #  RESET PDL, SET TFF=POSMAX, AND EXIT.
053729,000406: 
053730,000407: 27,3517           41076                           DCOMP    BOVB                                  #  RT IS ON INBOUND SIDE.  ASSURE OVFIND=0
053731,000408: 27,3520           57753                                    TCDANZIG                              #  ANY PORT IN A STORM.
053732,000409: 27,3521           24045                           STOVL    TFFTEM                                #  Q2   E: (-16)  M: (-15)
053733,000410: 27,3522           02170                                    VONE'                                 #  VN/SQRT(MU) E: (10)  M: (9)
053734,000411: 27,3523           52441                           DOT      SL3                                   
053735,000412: 27,3524           02207                                    RONE                                  #  SAVED RN.  E: (-29)  M:(-27)
053736,000413: 27,3525           00017                           STORE    TFFQ1                                 #  Q1, SAVE FOR GONEPAST TEST.
053737,000414:                                                                                                  #  E: (-16)  M: (-15)
053738,000415: 27,3526           44240                           BMN      BDSU                                  
053739,000416: 27,3527           57550                                    INBOUND                               #  USE ALTERNATE Z
053740,000417: 27,3530           00045                                    TFFTEM                                #  Q2  E: (-16)  M: (-15)
053741,000418: 
053742,000419:                                                                                                  #  OUTBOUND Z CALC CONTINUES HERE
053743,000420: 
053744,000421: 27,3531           14043                           STODL    TFFX                                  #  NUM=Q2-Q1  E: (-16)  M:(-15)
053745,000422: 27,3532           00033                                    TFFALFA                               #  ALFA  E: (26-NR)  M: (24-NR)
053746,000423: 27,3533           44205                           DMP      BDSU                                  

Page 1268

053748,000425: 27,3534           00041                                    NRMAG                                 #  RMAG  E: (-29+NR)  M: (-27+NR)
053749,000426:                                                                                                  #  (2-RTERM ALFA)  (-3) FROM PDL+0
053750,000427: 27,3535           51406        SAVEDEN            PUSH     ABS                                   #  DEN TO PDL+0  E: (-3) OR (-16)
053751,000428:                                                                                                  #                M: (-3) OR (-15)
053752,000429: 27,3536           40015                           DAD      BOV                                   #  INDETERMINANCY TEST
053753,000430: 27,3537           17757                                    LIM(-22)                              #  =1.0-B(-22)
053754,000431: 27,3540           57561                                    TFFXTEST                              #  GO IF DEN >/= B(-22)
053755,000432: 27,3541           65345                           DLOAD    PDDL                                  #  SET DEN=0 OTHERWISE
053756,000433: 27,3542           06524                                    TFFZEROS                              
053757,000434:                                                                                                  #  XCH ZERO WITH PDL+0
053758,000435: 27,3543           57545                           DLOAD    DCOMP                                 
053759,000436: 27,3544           00033                                    TFFALFA                               #  ALFA  E: (26-NR)  M: (24-NR)
053760,000437: 27,3545           71240                           BMN      DLOAD                                 #  FOR TPER: Z INDET AT DELE/2=0 AND 90.
053761,000438: 27,3546           57655                                    TFFEL1                                #  ASSUME 90, AND LEAVE 0 IN PDL: 1/Z=D/N
053762,000439: 
053763,000440:                                                                                                  #  Z INDET. AT PERIGEE FOR PARAB OR HYPERB.
053764,000441: 27,3547           77616        DUMPTFF1           RVQ                                            #  RETURN TFF =0
053765,000442: 
053766,000443:                                                                                                  #  INBOUND Z CALC CONTINUES HERE
053767,000444: 
053768,000445: 27,3550           77745        INBOUND            DLOAD                                          #  RESET PDL+0
053769,000446: 27,3551           45345                           DLOAD    DSU                                   #  ALTERNATE Z CALC
053770,000447: 27,3552           00023                                    RTERM                                 #  E: (-29)  M: (-27)
053771,000448: 27,3553           00015                                    RMAG1                                 #  E: (-29)  M: (-27)
053772,000449: 27,3554           14043                           STODL    TFFX                                  #  NUM=RTERM-RN  E: (-29)  M: (-27)
053773,000450: 27,3555           00045                                    TFFTEM                                #  Q2  E: (-16)  M: (-15)
053774,000451: 27,3556           52015                           DAD      GOTO                                  
053775,000452: 27,3557           00017                                    TFFQ1                                 #  Q1  E: (-16)  M: (-15)
053776,000453: 27,3560           57535                                    SAVEDEN                               #  DEN = Q2+Q1   E: (-16)  M:(-15)
053777,000454: 
053778,000455: 27,3561           65215        TFFXTEST           DAD      PDDL                                  #  (ABS(DEN) TO PDL+2))   E: (-3) OR (-16)
053779,000456:                                                                                                  #                         M: (-3) OR (-15)
053780,000457: 27,3562           17761                                    DP(-22)                               #  RESTORE ABS(DEN) TO MPAC
053781,000458: 27,3563           00043                                    TFFX                                  #  NUM E:(-16) OR (-29)  M:(-15) OR (-27)
053782,000459: 27,3564           53605                           DMP      SR*                                   
053783,000460: 27,3565           00031                                    TFFRTALF                              #  SQRT(ALFA)  E: (10+NA)  M: (9+NA)
053784,000461: 27,3566           57201                                    0          -3,2                       #  X2=-NA
053785,000462: 27,3567           77671                           DDV                                            #  C(MPAC) =NUM SQRT(ALFA)  E:(-3) OR (-16)
053786,000463:                                                                                                  #                           M:(-3) OR (-15)
053787,000464:                                                                                                  #  ABS(DEN) FROM PDL+2  E:(-3) OR (-16)
053788,000465:                                                                                                  #                       M:(-3) OR (-15)
053789,000466: 27,3570           40145                           DLOAD    BOV                                   #  (THE DLOAD IS SHARED WITH TFFELL)
053790,000467: 27,3571           00043                                    TFFX                                  #  NUM  E: (-16) OR (-29)  M: (-15) OR (-27)
053791,000468: 27,3572           57653                                    TFFELL                                #  USE EQN FOR DELE GEQ 90, LEQ -90
053792,000469: 
053793,000470:                                                                                                  #  OTHERWISE, CONTINUE FOR GENERAL CONIC FOR TFF EQN
053794,000471: 
053795,000472: 27,3573           45471                           DDV      STADR                                 
053796,000473:                                                                                                  #  DEN FROM PDL+0  E: (-3) OR (-16)
053797,000474:                                                                                                  #                  M: (-3) OR (-15)
053798,000475: 27,3574           77732                           STORE    TFFTEM                                #  Z SAVE FOR SIGN OF SDELF.

Page 1269

053800,000477:                                                                                                  #  E: (-13)  M: (-12)
053801,000478: 27,3575           63406                           PUSH     DSQ                                   #  Z TO PDL+0
053802,000479: 27,3576           41206                           PUSH     DMP                                   #  Z SQ TO PDL+2  E: (-26)  M: (-24)
053803,000480: 27,3577           00035                                    TFFNP                                 #  LC P  E: (-38+2NR)  M: (-36+2NR)
053804,000481: 27,3600           75261                           SL       SIGN                                  
053805,000482: 27,3601           20206                                    5                                     
053806,000483: 27,3602           00045                                    TFFTEM                                #  AFFIX SIGN FOR SDELF (ENTRY DISPLAY)
053807,000484: 27,3603           14045                           STODL    TFFTEM                                #  P ZSQ  E: (-59+2NR)  M: (-55+2NR)
053808,000485:                                                                                                  #  (ARG IS USED IN TFF/TRIG)
053809,000486:                                                                                                  #  ZSQ FROM PDL+2   E: (-26)  M: (-24)
053810,000487: 27,3604           41206                           PUSH     DMP                                   #  RESTORE PUSH LOC
053811,000488: 27,3605           00033                                    TFFALFA                               #  ALFA  E: (26-NR)  M: (24-NR)
053812,000489: 27,3606           77657                           SL*                                            
053813,000490: 27,3607           20201                                    0,1                                   #  X1=-NR
053814,000491: 27,3610           00043                           STORE    TFFX                                  #  X
053815,000492: 27,3611           41234                           RTB      DMP                                   
053816,000493: 27,3612           57735                                    T(X)                                  #   POLY
053817,000494:                                                                                                  #  ZSQ FROM PDL+2  E: (-26)  M: (-24)
053818,000495: 27,3613           44302                           SR2      BDSU                                  #  2 ZSQ T(X)  E: (-29)  M: (-27)
053819,000496: 27,3614           00023                                    RTERM                                 #  RTERM  E: (-29)  M: (-27)
053820,000497: 27,3615           41215                           DAD      DMP                                   
053821,000498: 27,3616           00015                                    RMAG1                                 #  E: (-29)  M: (-27)
053822,000499:                                                                                                  #  Z FROM PDL+0  E: (-13)  M: (-12)
053823,000500: 27,3617           51042                           SR3      BPL                                   #  TFF SQRT(MU)   E: (-45)  M: (-42)
053824,000501: 27,3620           57641                                    ENDTFF                                #  (NO PUSH UP)
053825,000502: 27,3621           75206                           PUSH     SIGN                                  #  TFF SQRT(MU) TO PDL+0
053826,000503: 27,3622           00017                                    TFFQ1                                 #  Q1 FOR GONEPAST TEST
053827,000504: 27,3623           71244                           BPL      DLOAD                                 #  GONE PAST ?
053828,000505: 27,3624           57645                                    NEGTFF                                #  YES. TFF < 0.
053829,000506: 27,3625           00027                                    TFF1/ALF                              #  1/ALFA  E: (-22-2NA)  M: (-20-2NA)
053830,000507: 27,3626           51076                           DCOMP    BPL                                   #  ALFA > 0 ?
053831,000508: 27,3627           57645                                    NEGTFF                                #  NO. TFF IS NEGATIVE.
053832,000509: 
053833,000510:                                                                                                  #  CORRECT FOR ORBITAL PERIOD.
053834,000511: 
053835,000512: 27,3630           77676                           DCOMP                                          #  YES. CORRECT FOR ORB PERIOD.
053836,000513: 27,3631           56205                           DMP      DDV                                   
053837,000514: 27,3632           17755                                    PI/16                                 #  2 PI (-5)
053838,000515: 27,3633           00031                                    TFFRTALF                              #  SQRT(ALFA)  E: (10+NA)  M: (9+NA)
053839,000516: 27,3634           53657                           SL*      SL*                                   
053840,000517: 27,3635           57602                                    0          -4,2                       #  X2=-NA
053841,000518: 27,3636           57602                                    0          -4,2                       
053842,000519: 27,3637           43257                           SL*      DAD                                   
053843,000520: 27,3640           57576                                    0,2                                   
053844,000521:                                                                                                  #  TFF SQRT(MU) FROM PDL+0  E:(-45) M:(-42)
053845,000522: 27,3641           40005        ENDTFF             DMP      BOV                                   #  TFF SQRT(MU) IN MPAC     E:(-45) M:(-42)
053846,000523: 27,3642           00037                                    TFF/RTMU                              #  E: (17)  M: (14)
053847,000524: 27,3643           57651                                    MAXTFF                                #  SET POSMAX IF OVFL.
053848,000525: 
053849,000526: 27,3644           77616        DUMPTFF2           RVQ                                            #  RETURN TFF   (-28) CS IN MPAC.
053850,000527: 

Page 1270

053852,000529: 27,3645           77745        NEGTFF             DLOAD                                          
053853,000530:                                                                                                  #  TFF SQRT(MU)  FROM PDL+0, NEGATIVE.
053854,000531: 27,3646           77650                           GOTO                                           
053855,000532: 27,3647           57641                                    ENDTFF                                
053856,000533: 
053857,000534: 27,3650           77745        MAXTFF1            DLOAD                                          #  RESET PDL
053858,000535: 27,3651           43545        MAXTFF             DLOAD    RVQ                                   
053859,000536: 27,3652           17771                                    NEARONE                               
053860,000537: 
053861,000538:                                                                                                  #  TIME OF FLIGHT ELLIPSE WHEN DEL (ECCENTRIC ANOM) GEQ 90 AND LEQ -90.
053862,000539: 
053863,000540:                                                                                                  #  NUM FROM TFFX.  E: (-16) OR (-29)
053864,000541:                                                                                                  #                  M: (-15) OR (-27)
053865,000542: 27,3653           77712        TFFELL             SL2                                            #  NUM  E:(-14) OR (-27)  M:(-13) OR (-25)
053866,000543: 27,3654           41465                           BDDV     PUSH                                  #  TEMP SAVE D/N IN PDL+0
053867,000544:                                                                                                  #  DEN FROM PDL+0 E:(-3)/( 16) M:(-3)/(-15)
053868,000545:                                                                                                  #  N/D TO PDL+0  E:(11) M:(10)
053869,000546: 27,3655           45345        TFFEL1             DLOAD    DSU                                   #  (ENTER WITH D/N=0 IN PDL+0)
053870,000547: 27,3656           00045                                    TFFTEM                                #  Q2  E: (-16)  M: (-15)
053871,000548: 27,3657           00017                                    TFFQ1                                 #  Q1  E: (-16)  M: (-15)
053872,000549: 27,3660           14013                           STODL    TFFDELQ                               #  Q2-Q1  E: (-16)  M: (-15)
053873,000550:                                                                                                  #  D/N FROM PDL+0
053874,000551: 27,3661           77626                           STADR                                          
053875,000552: 27,3662           77732                           STORE    TFFTEM                                #  D/N  E: (11)  M: (10)
053876,000553: 27,3663           53605                           DMP      SL*                                   
053877,000554: 27,3664           00027                                    TFF1/ALF                              #  1/ALFA E: (-22-2NA)  M: (-20-2NA)
053878,000555: 27,3665           57576                                    0,2                                   #  1/ALFA Z  E: (-11-NA)  M: (-10-NA)
053879,000556: 27,3666           41206                           PUSH     DMP                                   #  TO PDL+0
053880,000557: 27,3667           00045                                    TFFTEM                                #  1/Z  E: (11)  M: (10)
053881,000558: 27,3670           41057                           SL*      BOVB                                  
053882,000559: 27,3671           57576                                    0,2                                   #  X2= -NA
053883,000560: 27,3672           21713                                    SIGNMPAC                              #  IN CASE X= 1.0, CONTINUE
053884,000561: 27,3673           00043                           STORE    TFFX                                  #  X=1/ALFA ZSQ
053885,000562: 27,3674           41234                           RTB      DMP                                   
053886,000563: 27,3675           57735                                    T(X)                                  #  POLY
053887,000564: 27,3676           00043                                    TFFX                                  
053888,000565: 27,3677           45242                           SR3      DSU                                   
053889,000566: 27,3700           17763                                    DP2(-3)                               
053890,000567: 27,3701           41405                           DMP      PUSH                                  #  2(X T(X)-1) /Z ALFA  E: (-15-NA)
053891,000568:                                                                                                  #                       M: (-14-NA)
053892,000569:                                                                                                  #  1/ALFA Z FROM PDL+0  E: (-11-NA)
053893,000570:                                                                                                  #                       M: (-10-NA)
053894,000571: 27,3702           41345                           DLOAD    DMP                                   #  GET SIGN FOR SDELF
053895,000572: 27,3703           00045                                    TFFTEM                                #  1/Z  E: (11)  M: (10)
053896,000573: 27,3704           00015                                    RMAG1                                 #  E: (-29)  M: (-27)
053897,000574: 27,3705           43312                           SL2      DAD                                   
053898,000575: 27,3706           00017                                    TFFQ1                                 #  Q1  E: (-16)  M: (-15)
053899,000576: 27,3707           14045                           STODL    TFFTEM                                #  (Q1+R 1/Z)  =SGN OF SDELF E:(-16) M:(-15
053900,000577: 27,3710           00035                                    TFFNP                                 #  LC P E: (-38+2NR) M: (-36+2NR)
053901,000578: 27,3711           53605                           DMP      SL*                                   #  CALC FOR ARG FOR TFF/TRIG.

Page 1271

053903,000580: 27,3712           00027                                    TFF1/ALF                              #  1/ALFA   E:(-22-2NA)  M:(-20-2NA)
053904,000581: 27,3713           57575                                    1,2                                   #  X2=-NA
053905,000582: 27,3714           53765                           SIGN     SL*                                   
053906,000583: 27,3715           00045                                    TFFTEM                                #  AFFIX SIGN FOR SDELF
053907,000584: 27,3716           57576                                    0,2                                   
053908,000585: 27,3717           14045                           STODL    TFFTEM                                #  P/ALFA  E:(-59+2NR)  M:(-55+2NR)
053909,000586:                                                                                                  #  (ARG FOR USE IN TFF/TRIG)
053910,000587: 27,3720           00027                                    TFF1/ALF                              #  1/ALFA E:(-22-2NA)  M:(-20-2NA)
053911,000588: 27,3721           41366                           SQRT     DMP                                   
053912,000589: 27,3722           17755                                    PI/16                                 #  PI (-4)
053913,000590: 27,3723           77615                           DAD                                            
053914,000591:                                                                                                  #  2(XT(X)-1)/Z ALFA FROM PDL E:(-15-NA)
053915,000592:                                                                                                  #                             M:(-14-NA)
053916,000593: 27,3724           45257                           SL*      DSU                                   
053917,000594: 27,3725           57577                                    0          -1,2                       
053918,000595: 27,3726           00013                                    TFFDELQ                               #  Q2-Q1  E: (-16)  M: (-15)
053919,000596: 27,3727           53605                           DMP      SL*                                   
053920,000597: 27,3730           00027                                    TFF1/ALF                              #  1/ALFA   E:(-22-2NA) M:(-20-2NA)
053921,000598: 27,3731           57601                                    0          -3,2                       
053922,000599: 27,3732           52057                           SL*      GOTO                                  
053923,000600: 27,3733           57602                                    0          -4,2                       
053924,000601: 27,3734           57641                                    ENDTFF                                #  TFF SQRT(MU) IN MPAC E:(-45) M:(-42)
053925,000602: 

Page 1272

053927,000604:                                                                                                  #  PROGRAM NAME:      T(X)                                                   DATE:    01.17.67
053928,000605:                                                                                                  #  MOD NO:  0                                                                LOG SECTION:    TIME OF FREE FALL
053929,000606:                                                                                                  #  MOD BY:  RR BAIRNSFATHER
053930,000607:                                                                                                  #  FUNCTIONAL DESCRIPTION:        THE POLYNOMIAL T(X) IS USED BY TIME OF FLIGHT SUBROUTINES  CALCTFF AND
053931,000608:                                                                                                  #           CALCTPER TO APPROXIMATE THE SERIES
053932,000609:                                                                                                  #                             2     3
053933,000610:                                                                                                  #                  1/3 -X/5 +X /7 -X /9 ...
053934,000611: 
053935,000612:                                                                                                  #           WHERE  X = ALFA Z Z            IF ALFA Z Z LEQ 1
053936,000613:                                                                                                  #                  X = 1/(ALFA Z Z)        IF ALFA Z Z G 1
053937,000614: 
053938,000615:                                                                                                  #           ALSO   X IS NEG FOR HYPERBOLIC ORBITS
053939,000616:                                                                                                  #                  X = 0 FOR PARABOLIC ORBITS
053940,000617:                                                                                                  #                  X IS POSITIVE FOR ELLIPTIC ORBITS
053941,000618:                                                                                                  #           FOR FLIGHT 278, THE POLYNOMIAL T(X) IS FITTED OVER THE RANGE  (0,+1) AND HAS A MAXIMUM
053942,000619:                                                                                                  #           DEVIATION FROM THE SERIES OF  2 E-5      (T(X) IS A CHEBYCHEV  TYPE FIT AND WAS OBTAINED USING
053943,000620:                                                                                                  #           MAC PROGRAM AUTCURFIT294RRB  AND IS VALID TO THE SAME TOLERANCE OVER THE RANGE (-.08,+1).)
053944,000621:                                                                                                  #  CALLING SEQUENCE:  RTB
053945,000622:                                                                                                  #                            T(X)
053946,000623:                                                                                                  #           C(MPAC) = X
053947,000624: 
053948,000625:                                                                                                  #  SUBROUTINES CALLED:  NONE
053949,000626:                                                                                                  #  NORMAL EXIT MODE:    TC   DANZIG
053950,000627:                                                                                                  #  ALARMS:  NONE
053951,000628:                                                                                                  #  OUTPUT:  C(MPAC) = T(X)
053952,000629:                                                                                                  #  ERASABLE INITIALIZATION REQUIRED:
053953,000630:                                                                                                  #           C(MPAC) = X
053954,000631:                                                                                                  #  DEBRIS:  NONE
053955,000632: 
053956,000633: 27,3735           07225        T(X)               TC       POLY                                  
053957,000634: 27,3736           00004                           DEC      4          B-14                       #  N-1
053958,000635: 27,3737           12525 12525                     2DEC     3.333333333 E-1                        
053959,000636: 
053960,000637: 27,3741           71463 57703                     2DEC*    -1.999819135 E-1*                       
053961,000638: 
053962,000639: 27,3743           04423 17645                     2DEC*    1.418148467 E-1*                       
053963,000640: 
053964,000641: 27,3745           74604 43667                     2DEC*    -1.01310997 E-1*                       
053965,000642: 
053966,000643: 27,3747           01626 37256                     2DEC*    5.609004986 E-2*                       
053967,000644: 
053968,000645: 27,3751           77404 52071                     2DEC*    -1.536156925 E-2*                       
053969,000646: 
053970,000647: 27,3753           06064        ENDT(X)            TC       DANZIG                                
053971,000648: 
053972,000649: 27,3754  27,3753               TCDANZIG           =        ENDT(X)                               
053973,000650: 

Page 1273

053975,000652:                                                                                                  #  TFF CONSTANTS
053976,000653: 
053977,000654: 32,3764                                           BANK     32                                    
053978,000655: 
053979,000656: 27,2000                                           SETLOC   TOF-FF1                               
053980,000657: 27,2000                                           BANK                                           
053981,000658: 
053982,000659:                                                                                                  #                                                NOTE _  NOTE _  ADJUSTED MUE FOR NEAR EARTH TRAJ.
053983,000660:                                                                                                  # MUE            =       3.990815471 E10         M CUBE/CS SQ
053984,000661:                                                                                                  # RTMUE          =       1.997702549 E5 B-18*    MODIFIED EARTH MU
053985,000662: 
053986,000663:                                                                                                  #                                                NOTE _  NOTE _  ADJUSTED MUE FOR NEAR EARTH TRAJ.
053987,000664:                                                                                                  # MUM            =       4.902778 E8             M CUBE/CS SQ
053988,000665:                                                                                                  # RTMUM          2DEC*   2.21422176 E4 B-18*
053989,000666: 
053990,000667: 27,3754           06220 37553  PI/16              2DEC     3.141592653 B-4                        
053991,000668: 
053992,000669: 27,3756           37777 37700  LIM(-22)           2OCT     3777737700                            #  1.0 -B(-22)
053993,000670: 
053994,000671: 27,3760           00000 00100  DP(-22)            2OCT     0000000100                            #  B(-22)
053995,000672: 
053996,000673: 27,3762           04000 00000  DP2(-3)            2DEC     1          B-3                        
053997,000674: 
053998,000675: 27,3764           02000 00000  DP2(-4)            2DEC     1          B-4                        #  1/16
053999,000676: 
054000,000677:                                                                                                  #  RPAD1         2DEC    6373338 B-29            M (-29) = 20909901.57 FT
054001,000678: 
054002,000679: 27,3766  23,2337               RPAD1              =        RPAD                                  
054003,000680: 
054004,000681: 27,3766           00305 11205  R300K              2DEC     6464778    B-29                       #  (-29) M
054005,000682: 
054006,000683: 27,3770           37777 37777  NEARONE            2DEC     .999999999                            
054007,000684: 
054008,000685: 27,3772  23,2523               TFFZEROS           EQUALS   HI6ZEROS                              
054009,000686: 27,3772  23,2513               TFF1/4             EQUALS   HIDP1/4                               
054010,000687: 

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