! freal1a ! 15/01/87 - insert %alias for amdahl system routines ! ! freal1 ! 10/10/86 - copied from ftnreal6 !Modified 28/May/86 9.00 !**********************************************************************! !**********************************************************************! ! ! ! ! ! Support Procedures for Numeric Conversion ! ! ! ! of Real Numbers ! ! ! ! between Binary and Character Form ! ! ! ! ! !**********************************************************************! !**********************************************************************! !---------------------------------------! ! ! ! Conditional Compilation Constants ! ! ! !---------------------------------------! %constinteger emas = 0 %constinteger pnx = 1 {PNX/Accent/Whitechapel/Perq3} %constinteger ibm = 2 {Amdahl} %constinteger gould= 3 {Gould} %constinteger host= gould ! !*********************************************************************** ! ! SPECIFICATIONS OF PROCEDURES DEFINED ! !*********************************************************************** ! %LONGLONGREALFNSPEC POWER OF TEN ( %INTEGER EXP) %LONGLONGREALFNSPEC INTO RANGE (%LONGLONGREAL X, %INTEGERNAME EXP) ! !*********************************************************************** ! ! CONSTANTS ! !*********************************************************************** ! %IF HOST= EMAS %THENSTART ! ! %CONSTINTEGERARRAY PERQ {double precision} POWERS OF TEN TABLE1 ( 0:245)= %C %C {Ten to the -305} X'009C16C5' , X'C5253575' , {Ten to the -300} X'01A56E1F' , X'C2F8F358' , {Ten to the -295} X'02B05994' , X'9B708F29' , {Ten to the -290} X'03B8F2B0' , X'61AEA072' , {Ten to the -285} X'04C308A8' , X'31868AC8' , {Ten to the -280} X'05CD0B15' , X'A491EB84' , {Ten to the -275} X'06D62884' , X'F31E93FF' , {Ten to the -270} X'07E0E7C9' , X'EEBC4449' , {Ten to the -265} X'08E9CBAE' , X'7FE805B3' , {Ten to the -260} X'09F3AE35' , X'91F5B4D9' , {Ten to the -255} X'0AFE07B2' , X'7DD78B14' , {Ten to the -250} X'0C06E93F' , X'5DA2824B' , {Ten to the -245} X'0D117AD4' , X'28200C08' , {Ten to the -240} X'0E1AAC0B' , X'F9B9E65C' , {Ten to the -235} X'0F245962' , X'E2F6A490' , {Ten to the -230} X'102F0CE4' , X'839198DA' , {Ten to the -225} X'1137B086' , X'17A104EE' , {Ten to the -220} X'124212DD' , X'4DE70913' , {Ten to the -215} X'134B9408' , X'EEFEA838' , {Ten to the -210} X'14550A61' , X'10D6A9B7' , {Ten to the -205} X'15600D7B' , X'2E28C65C' , {Ten to the -200} X'16687E92' , X'154EF7AC' , {Ten to the -195} X'1772B010' , X'D3E1CF56' , {Ten to the -190} X'187C83E7' , X'AD4E6EFE' , {Ten to the -185} X'1985C162' , X'B168E70E' , {Ten to the -180} X'1A90991A' , X'9BFA58C8' , {Ten to the -175} X'1B99539E' , X'3A40DFB8' , {Ten to the -170} X'1CA3529B' , X'A7D19EAF' , {Ten to the -165} X'1DAD7BEC' , X'C2F23AC1' , {Ten to the -160} X'1EB67E9C' , X'127B6E74' , {Ten to the -155} X'1FC12978' , X'72D9CBB5' , {Ten to the -150} X'20CA2FE7' , X'6A3F9475' , {Ten to the -145} X'21D3FAAC' , X'3E3FA1F3' , {Ten to the -140} X'22DE7C5F' , X'127BD87E' , {Ten to the -135} X'23E74243' , X'48CA1C9B' , {Ten to the -130} X'24F1BEBD' , X'F578B2F4' , {Ten to the -125} X'25FB13AC' , X'9AAF4C0F' , {Ten to the -120} X'2704A872' , X'9FC3DDB7' , {Ten to the -115} X'280F8587' , X'E7083E2F' , {Ten to the -110} X'29180C90' , X'3F7379F1' , {Ten to the -105} X'2A225915' , X'CD68C9F9' , {Ten to the -100} X'2B2BFF2E' , X'E48E052F' , {Ten to the -95 } X'2C355C20' , X'76BF9A55' , {Ten to the -90 } X'2D404BD9' , X'84990E6F' , {Ten to the -85 } X'2E48DDBC' , X'C7F40BA6' , {Ten to the -80 } X'2F52F8AC' , X'174D6123' , {Ten to the -75 } X'305CF2B1' , X'970E7258' , {Ten to the -70 } X'316615E9' , X'1D8F359D' , {Ten to the -65 } X'3270D997' , X'6A5D5297' , {Ten to the -60 } X'3379B604' , X'AAACA626' , {Ten to the -55 } X'34839DAE' , X'6F76D883' , {Ten to the -50 } X'358DEE7A' , X'4AD4B81F' , {Ten to the -45 } X'3696D601' , X'AD376AB9' , {Ten to the -40 } X'37A16C26' , X'2777579C' , {Ten to the -35 } X'38AA95A5' , X'B7F87A0F' , {Ten to the -30 } X'39B4484B' , X'FEEBC2A0' , {Ten to the -25 } X'3ABEF2D0' , X'F5DA7DD9' , {Ten to the -20 } X'3BC79CA1' , X'0C924223' , {Ten to the -15 } X'3CD203AF' , X'9EE75615' , {Ten to the -10 } X'3DDB7CDF' , X'D9D7BDBB' , {Ten to the -5 } X'3EE4F8B5' , X'88E368F1' , {Ten to the 0 } X'3FF00000' , X'00000000' , {Ten to the 5 } X'40F86A00' , X'00000000' , {Ten to the 10 } X'4202A05F' , X'20000000' , {Ten to the 15 } X'430C6BF5' , X'26340000' , {Ten to the 20 } X'4415AF1D' , X'78B58C40' , {Ten to the 25 } X'45208B2A' , X'2C280290' , {Ten to the 30 } X'46293E59' , X'39A08CE9' , {Ten to the 35 } X'47334261' , X'72C74D82' , {Ten to the 40 } X'483D6329' , X'F1C35CA5' , {Ten to the 45 } X'49466BB7' , X'F0435C9E' , {Ten to the 50 } X'4A511B0E' , X'C57E6499' , {Ten to the 55 } X'4B5A19E9' , X'6A19FC41' , {Ten to the 60 } X'4C63E9E4' , X'E4C2F344' , {Ten to the 65 } X'4D6E62C4' , X'E38FF872' , {Ten to the 70 } X'4E772EBA' , X'D6DDC73D' , {Ten to the 75 } X'4F81AFD6' , X'EC0E1411' , {Ten to the 80 } X'508AFCEF' , X'51F0FB5F' , {Ten to the 85 } X'51949719' , X'56342AC8' , {Ten to the 90 } X'529F6B0F' , X'092959C7' , {Ten to the 95 } X'53A7F85D' , X'E8AD5C4E' , {Ten to the 100 } X'54B249AD' , X'2594C37D' , {Ten to the 105 } X'55BBE7AB' , X'D3781ECA' , {Ten to the 110 } X'56C54A30' , X'47C694FE' , {Ten to the 115 } X'57D03E29' , X'F5C2B18C' , {Ten to the 120 } X'58D8C8DA' , X'C6A0342A' , {Ten to the 125 } X'59E2E8BD' , X'69AA19CC' , {Ten to the 130 } X'5AECDA62' , X'055B2D9D' , {Ten to the 135 } X'5BF6035C' , X'E8B6203D' , {Ten to the 140 } X'5D00CB70' , X'D24B7378' , {Ten to the 145 } X'5E09A06D' , X'06E26112' , {Ten to the 150 } X'5F138D35' , X'2E5096AF' , {Ten to the 155 } X'601DD557' , X'45CBB7ED' , {Ten to the 160 } X'6126C2D4' , X'256FFCC3' , {Ten to the 165 } X'62315D84' , X'7AD00087' , {Ten to the 170 } X'633A7F52' , X'45E5A2CF' , {Ten to the 175 } X'64443743' , X'74F3C2C6' , {Ten to the 180 } X'654ED8D3' , X'4E547314' , {Ten to the 185 } X'665788CC' , X'B6B2CE0C' , {Ten to the 190 } X'6761F48E' , X'AF234AD3' , {Ten to the 195 } X'686B65CA' , X'37FD3A0D' , {Ten to the 200 } X'6974E718' , X'D7D7625A' , {Ten to the 205 } X'6A7FE520' , X'48590673' , {Ten to the 210 } X'6B88557F' , X'31326BBB' , {Ten to the 215 } X'6C9290BA' , X'9A38C7D1' , {Ten to the 220 } X'6D9C5416' , X'BB92E3E6' , {Ten to the 225 } X'6EA59CE7' , X'97FB817F' , {Ten to the 230 } X'6FB07D45' , X'7124123D' , {Ten to the 235 } X'70B92926' , X'15C3AA54' , {Ten to the 240 } X'71C33234' , X'DE7AD7E3' , {Ten to the 245 } X'72CD4A7B' , X'EBFA31AA' , {Ten to the 250 } X'73D658E3' , X'AB795204' , {Ten to the 255 } X'74E10CB1' , X'32C2FF63' , {Ten to the 260 } X'75EA03FD' , X'E214CAF0' , {Ten to the 265 } X'76F3D92B' , X'A28C7D15' , {Ten to the 270 } X'77FE4940' , X'34E79E5C' , {Ten to the 275 } X'79071B42' , X'CC5CF601' , {Ten to the 280 } X'7A11A0FC' , X'668AAC6F' , {Ten to the 285 } X'7B1AE645' , X'21F7595E' , {Ten to the 290 } X'7C2485CE' , X'9E7A065E' , {Ten to the 295 } X'7D2F50AC' , X'6690F1F8' , {Ten to the 300 } X'7E37E43C' , X'8800759C' , {Ten to the 305 } X'7F423A51' , X'6E82D9BA' ! ! !This table contains the Powers of Ten ! in the range 10**(-305) to 10**(305) ! in IEEE Standard form ! in double precision ! in steps of 5 %CONSTINTEGER B1= -( -305{which is the 1st power in TABLE1} // 5 {the step size}) ! !It is prefered if arrays start at subscript zero, and ! in bowing to this preference, yet still maintaining ! some level of readability this constant is added to ! any subscript value before accessing TABLE1 OF POWERS. %CONSTINTEGERARRAY PERQ {double precision} POWERS OF TEN TABLE2 ( 0:21)= %C %C {Ten to the -5 } X'3EE4F8B5' , X'88E368F1' , {Ten to the -4 } X'3F1A36E2' , X'EB1C432C' , {Ten to the -3 } X'3F50624D' , X'D2F1A9FC' , {Ten to the -2 } X'3F847AE1' , X'47AE147B' , {Ten to the -1 } X'3FB99999' , X'9999999A' , {Ten to the 0 } X'3FF00000' , X'00000000' , {Ten to the 1 } X'40240000' , X'00000000' , {Ten to the 2 } X'40590000' , X'00000000' , {Ten to the 3 } X'408F4000' , X'00000000' , {Ten to the 4 } X'40C38800' , X'00000000' , {Ten to the 5 } X'40F86A00' , X'00000000' ! ! !This table contains the Powers of Ten ! in the range 10**(-5) to 10**(5) %CONSTINTEGER B2= -( -5{which is the 1st power in TABLE2} ) ! !---as for B1 but applies to TABLE2 OF POWERS %FINISH %IF HOST= PNX %THENSTART ! ! ! DEFINE REAL CONSTANTS DIRECTLY IN IEEE STANDARD ! ! %CONSTLONGREALARRAY TABLE1 OF POWERS ( 0: 122)= %C %C {Ten to the -305} R'009C16C5C5253575' , {Ten to the -300} R'01A56E1FC2F8F358' , {Ten to the -295} R'02B059949B708F29' , {Ten to the -290} R'03B8F2B061AEA072' , {Ten to the -285} R'04C308A831868AC8' , {Ten to the -280} R'05CD0B15A491EB84' , {Ten to the -275} R'06D62884F31E93FF' , {Ten to the -270} R'07E0E7C9EEBC4449' , {Ten to the -265} R'08E9CBAE7FE805B3' , {Ten to the -260} R'09F3AE3591F5B4D9' , {Ten to the -255} R'0AFE07B27DD78B14' , {Ten to the -250} R'0C06E93F5DA2824B' , {Ten to the -245} R'0D117AD428200C08' , {Ten to the -240} R'0E1AAC0BF9B9E65C' , {Ten to the -235} R'0F245962E2F6A490' , {Ten to the -230} R'102F0CE4839198DA' , {Ten to the -225} R'1137B08617A104EE' , {Ten to the -220} R'124212DD4DE70913' , {Ten to the -215} R'134B9408EEFEA838' , {Ten to the -210} R'14550A6110D6A9B7' , {Ten to the -205} R'15600D7B2E28C65C' , {Ten to the -200} R'16687E92154EF7AC' , {Ten to the -195} R'1772B010D3E1CF56' , {Ten to the -190} R'187C83E7AD4E6EFE' , {Ten to the -185} R'1985C162B168E70E' , {Ten to the -180} R'1A90991A9BFA58C8' , {Ten to the -175} R'1B99539E3A40DFB8' , {Ten to the -170} R'1CA3529BA7D19EAF' , {Ten to the -165} R'1DAD7BECC2F23AC1' , {Ten to the -160} R'1EB67E9C127B6E74' , {Ten to the -155} R'1FC1297872D9CBB5' , {Ten to the -150} R'20CA2FE76A3F9475' , {Ten to the -145} R'21D3FAAC3E3FA1F3' , {Ten to the -140} R'22DE7C5F127BD87E' , {Ten to the -135} R'23E7424348CA1C9B' , {Ten to the -130} R'24F1BEBDF578B2F4' , {Ten to the -125} R'25FB13AC9AAF4C0F' , {Ten to the -120} R'2704A8729FC3DDB7' , {Ten to the -115} R'280F8587E7083E2F' , {Ten to the -110} R'29180C903F7379F1' , {Ten to the -105} R'2A225915CD68C9F9' , {Ten to the -100} R'2B2BFF2EE48E052F' , {Ten to the -95 } R'2C355C2076BF9A55' , {Ten to the -90 } R'2D404BD984990E6F' , {Ten to the -85 } R'2E48DDBCC7F40BA6' , {Ten to the -80 } R'2F52F8AC174D6123' , {Ten to the -75 } R'305CF2B1970E7258' , {Ten to the -70 } R'316615E91D8F359D' , {Ten to the -65 } R'3270D9976A5D5297' , {Ten to the -60 } R'3379B604AAACA626' , {Ten to the -55 } R'34839DAE6F76D883' , {Ten to the -50 } R'358DEE7A4AD4B81F' , {Ten to the -45 } R'3696D601AD376AB9' , {Ten to the -40 } R'37A16C262777579C' , {Ten to the -35 } R'38AA95A5B7F87A0F' , {Ten to the -30 } R'39B4484BFEEBC2A0' , {Ten to the -25 } R'3ABEF2D0F5DA7DD9' , {Ten to the -20 } R'3BC79CA10C924223' , {Ten to the -15 } R'3CD203AF9EE75615' , {Ten to the -10 } R'3DDB7CDFD9D7BDBB' , {Ten to the -5 } R'3EE4F8B588E368F1' , {Ten to the 0 } R'3FF0000000000000' , {Ten to the 5 } R'40F86A0000000000' , {Ten to the 10 } R'4202A05F20000000' , {Ten to the 15 } R'430C6BF526340000' , {Ten to the 20 } R'4415AF1D78B58C40' , {Ten to the 25 } R'45208B2A2C280290' , {Ten to the 30 } R'46293E5939A08CE9' , {Ten to the 35 } R'4733426172C74D82' , {Ten to the 40 } R'483D6329F1C35CA5' , {Ten to the 45 } R'49466BB7F0435C9E' , {Ten to the 50 } R'4A511B0EC57E6499' , {Ten to the 55 } R'4B5A19E96A19FC41' , {Ten to the 60 } R'4C63E9E4E4C2F344' , {Ten to the 65 } R'4D6E62C4E38FF872' , {Ten to the 70 } R'4E772EBAD6DDC73D' , {Ten to the 75 } R'4F81AFD6EC0E1411' , {Ten to the 80 } R'508AFCEF51F0FB5F' , {Ten to the 85 } R'5194971956342AC8' , {Ten to the 90 } R'529F6B0F092959C7' , {Ten to the 95 } R'53A7F85DE8AD5C4E' , {Ten to the 100 } R'54B249AD2594C37D' , {Ten to the 105 } R'55BBE7ABD3781ECA' , {Ten to the 110 } R'56C54A3047C694FE' , {Ten to the 115 } R'57D03E29F5C2B18C' , {Ten to the 120 } R'58D8C8DAC6A0342A' , {Ten to the 125 } R'59E2E8BD69AA19CC' , {Ten to the 130 } R'5AECDA62055B2D9D' , {Ten to the 135 } R'5BF6035CE8B6203D' , {Ten to the 140 } R'5D00CB70D24B7378' , {Ten to the 145 } R'5E09A06D06E26112' , {Ten to the 150 } R'5F138D352E5096AF' , {Ten to the 155 } R'601DD55745CBB7ED' , {Ten to the 160 } R'6126C2D4256FFCC3' , {Ten to the 165 } R'62315D847AD00087' , {Ten to the 170 } R'633A7F5245E5A2CF' , {Ten to the 175 } R'6444374374F3C2C6' , {Ten to the 180 } R'654ED8D34E547314' , {Ten to the 185 } R'665788CCB6B2CE0C' , {Ten to the 190 } R'6761F48EAF234AD3' , {Ten to the 195 } R'686B65CA37FD3A0D' , {Ten to the 200 } R'6974E718D7D7625A' , {Ten to the 205 } R'6A7FE52048590673' , {Ten to the 210 } R'6B88557F31326BBB' , {Ten to the 215 } R'6C9290BA9A38C7D1' , {Ten to the 220 } R'6D9C5416BB92E3E6' , {Ten to the 225 } R'6EA59CE797FB817F' , {Ten to the 230 } R'6FB07D457124123D' , {Ten to the 235 } R'70B9292615C3AA54' , {Ten to the 240 } R'71C33234DE7AD7E3' , {Ten to the 245 } R'72CD4A7BEBFA31AA' , {Ten to the 250 } R'73D658E3AB795204' , {Ten to the 255 } R'74E10CB132C2FF63' , {Ten to the 260 } R'75EA03FDE214CAF0' , {Ten to the 265 } R'76F3D92BA28C7D15' , {Ten to the 270 } R'77FE494034E79E5C' , {Ten to the 275 } R'79071B42CC5CF601' , {Ten to the 280 } R'7A11A0FC668AAC6F' , {Ten to the 285 } R'7B1AE64521F7595E' , {Ten to the 290 } R'7C2485CE9E7A065E' , {Ten to the 295 } R'7D2F50AC6690F1F8' , {Ten to the 300 } R'7E37E43C8800759C' , {Ten to the 305 } R'7F423A516E82D9BA' ! ! !This table contains the Powers of Ten ! in the range 10**(-305) to 10**(305) ! in IEEE Standard form ! in double precision ! in steps of 5 %CONSTINTEGER B1= -( -305{which is the 1st power in TABLE1} // 5 {the step size}) ! !It is prefered if arrays start at subscript zero, and ! in bowing to this preference, yet still maintaining ! some level of readability this constant is added to ! any subscript value before accessing TABLE1 OF POWERS. %CONSTLONGREALARRAY TABLE2 OF POWERS ( 0: 10)= %C %C {Ten to the -5 } R'3EE4F8B588E368F1' , {Ten to the -4 } R'3F1A36E2EB1C432C' , {Ten to the -3 } R'3F50624DD2F1A9FC' , {Ten to the -2 } R'3F847AE147AE147B' , {Ten to the -1 } R'3FB999999999999A' , {Ten to the 0 } R'3FF0000000000000' , {Ten to the 1 } R'4024000000000000' , {Ten to the 2 } R'4059000000000000' , {Ten to the 3 } R'408F400000000000' , {Ten to the 4 } R'40C3880000000000' , {Ten to the 5 } R'40F86A0000000000' ! ! !This table contains the Powers of Ten ! in the range 10**(-5) to 10**(5) %CONSTINTEGER B2= -( -5{which is the 1st power in TABLE2} ) ! !---as for B1 but applies to TABLE2 OF POWERS %CONSTLONGREAL Ten to the 305 = R'7F423A516E82D9BA' %CONSTLONGREAL Ten to the Minus 305 = R'009C16C5C5253575' %FINISH %IF HOST= IBM %THENSTART ! ! ! DEFINE REAL CONSTANTS IN 'EXCESS 64' NOTATION ! ! !CONSTLONGLONGREALARRAY TABLE OF POWERS (-78:75)= %C %C {Ten to the -78} R'001DA48CE468E7C772026520247D3556' , {Ten to the -77} R'011286D80EC190DC73617F3416CE4156' , {Ten to the -76} R'01B94470938FA89B73CEF808E40E8D5B' , {Ten to the -75} R'0273CAC65C39C96174615B058E891859' , {Ten to the -74} R'03485EBBF9A41DDC75DCD8E37915AF38' , {Ten to the -73} R'042D3B357C0692AA760A078E2BAD8D83' , {This } {Ten to the -72} R'051C45016D841BAA774644B8DB4C7872' , {Ten to the -71} R'0611AB20E472914A786BEAF3890FCB47' , {table } {Ten to the -70} R'06B0AF48EC79ACE878372D835A9DF0C7' , {Ten to the -69} R'076E6D8D93CC0C1179227C7218A2B67C' , {was } {Ten to the -68} R'084504787C5F878A7AB58DC74F65B20E' , {Ten to the -67} R'092B22CB4DBBB4B67BB1789C919F8F49' , {acquired } {Ten to the -66} R'0A1AF5BF109550F27C2EEB61DB03B98D' , {Ten to the -65} R'0B10D9976A5D52977D5D531D28E253F8' , {from } {Ten to the -64} R'0BA87FEA27A539E97DA53F2398D747B3' , {Ten to the -63} R'0C694FF258C744327E0747763F868CD0' , {PD Stephens} {Ten to the -62} R'0D41D1F7777C8A9F7F448CA9E7B41802' , {Ten to the -61} R'0E29233AAAADD6A3008AD7EA30D08F01' , {Ten to the -60} R'0F19B604AAACA6260136C6F25E825961' , {Ten to the -59} R'101011C2EAABE7D702E23C577B1177DD' , {via } {Ten to the -58} R'10A0B19D2AB70E6E02D65B6ACEAEAE9D' , {Ten to the -57} R'11646F023AB269050345F922C12D2D22' , {the } {Ten to the -56} R'123EC56164AF81A3044BBBB5B8BC3C35' , {Ten to the -55} R'13273B5CDEEDB106050F55519375A5A1' , {IBM } {Ten to the -54} R'1418851A0B548EA306C99552FC298785' , {Ten to the -53} R'14F53304714D926506DFD53DD99F4B30' , {Assembler. } {Ten to the -52} R'15993FE2C6D07B7F07ABE546A8038EFE' , {Ten to the -51} R'165FC7EDBC424D2F08CB6F4C2902395F' , {Ten to the -50} R'173BDCF495A9703D09DF258F99A163DB' , {Ten to the -49} R'18256A18DD89E6260AAB7779C004DE69' , {It } {Ten to the -48} R'1917624F8A762FD80B2B2AAC18030B02' , {Ten to the -47} R'19E9D71B689DDE710BAFAAB8F01E6E11' , {is } {Ten to the -46} R'1A9226712162AB070C0DCAB3961304CA' , {Ten to the -45} R'1B5B5806B4DDAAE40D689EB03DCBE2FF' , {claimed } {Ten to the -44} R'1C391704310A8ACE0EC1632E269F6DDF' , {Ten to the -43} R'1D23AE629EA696C10F38DDFCD823A4AB' , {to } {Ten to the -42} R'1E164CFDA3281E3810C38ABE071646EB' , {Ten to the -41} R'1EDF01E85F912E3710A36B6C46DEC52F' , {evaluate } {Ten to the -40} R'1F8B61313BBABCE211C62323AC4B3B3E' , {Ten to the -39} R'20571CBEC554B60D12BBD5F64BAF0507' , {exactly } {Ten to the -38} R'213671F73B54F1C8139565B9EF4D6324' , {Ten to the -37} R'2222073A8515171D145D5F9435905DF7' , {and } {Ten to the -36} R'23154484932D2E72155A5BBCA17A3ABA' , {Ten to the -35} R'23D4AD2DBFC3D0771587955E4EC64B45' , {round } {Ten to the -34} R'2484EC3C97DA624A16B4BD5AF13BEF0B' , {Ten to the -33} R'255313A5DEE87D6E17B0F658D6C57567' , {to } {Ten to the -32} R'2633EC47AB514E65182E99F7863B6960' , {Ten to the -31} R'272073ACCB12D0FF193D203AB3E521DC' , {128 } {Ten to the -30} R'2814484BFEEBC29F1A863424B06F352A' , {Ten to the -29} R'28CAD2F7F5359A3B1A3E096EE45813A0' , {bits. } {Ten to the -28} R'297EC3DAF94180651B06C5E54EB70C44' , {Ten to the -27} R'2A4F3A68DBC8F03F1C243BAF513267AB' , {Ten to the -26} R'2B318481895D96271D76A54D92BF80CB' , {Ten to the -25} R'2C1EF2D0F5DA7DD81EAA27507BB7B07F' , {It } {Ten to the -24} R'2D1357C299A88EA71F6A58924D52CE4F' , {Ten to the -23} R'2DC16D9A0095928A1F2775B7053C0F18' , {is } {Ten to the -22} R'2E78E480405D7B962058A9926345896F' , {Ten to the -21} R'2F4B8ED0283A6D3D21F769FB7E0B75E5' , {also } {Ten to the -20} R'302F39421924844622BAA23D2EC729AF' , {Ten to the -19} R'311D83C94FB6D2AC2334A5663D3C7A0E' , {claimed } {Ten to the -18} R'3212725DD1D243AB24A0E75FE645CC48' , {Ten to the -17} R'32B877AA3236A4B4244909BEFEB9FAD5' , {to } {Ten to the -16} R'33734ACA5F6226F025ADA6175F343CC5' , {Ten to the -15} R'34480EBE7B9D5856266C87CE9B80A5FB' , {be } {Ten to the -14} R'352D09370D4257362703D4E1213067BD' , {Ten to the -13} R'361C25C26849768128C2650CB4BE40D6' , {fully } {Ten to the -12} R'37119799812DEA1129197F27F0F6E886' , {Ten to the -11} R'37AFEBFF0BCB24AA29FEF78F69A5153A' , {validated. } {Ten to the -10} R'386DF37F675EF6EA2ADF5AB9A2072D44' , {Ten to the -9} R'3944B82FA09B5A522BCB98B405447C4B' , {Ten to the -8} R'3A2AF31DC46118732CBF3F70834ACDAF' , {Ten to the -7} R'3B1AD7F29ABCAF482D5787A6520EC08D' , {Ten to the -6} R'3C10C6F7A0B5ED8D2E36B4C7F3493858' , {Ten to the -5} R'3CA7C5AC471B47842E230FCF80DC3372' , {Ten to the -4} R'3D68DB8BAC710CB22F95E9E1B089A027' , {Ten to the -3} R'3E4189374BC6A7EF309DB22D0E560419' , {Ten to the -2} R'3F28F5C28F5C28F531C28F5C28F5C28F' , {Ten to the -1} R'4019999999999999329999999999999A' , {Ten to the 0} R'41100000000000003300000000000000' , {Ten to the 1} R'41A00000000000003300000000000000' , {Ten to the 2} R'42640000000000003400000000000000' , {Ten to the 3} R'433E8000000000003500000000000000' , {Ten to the 4} R'44271000000000003600000000000000' , {Ten to the 5} R'45186A00000000003700000000000000' , {Ten to the 6} R'45F42400000000003700000000000000' , {Ten to the 7} R'46989680000000003800000000000000' , {Ten to the 8} R'475F5E10000000003900000000000000' , {Ten to the 9} R'483B9ACA000000003A00000000000000' , {Ten to the 10} R'492540BE400000003B00000000000000' , {Ten to the 11} R'4A174876E80000003C00000000000000' , {Ten to the 12} R'4AE8D4A5100000003C00000000000000' , {Ten to the 13} R'4B9184E72A0000003D00000000000000' , {Ten to the 14} R'4C5AF3107A4000003E00000000000000' , {Ten to the 15} R'4D38D7EA4C6800003F00000000000000' , {Ten to the 16} R'4E2386F26FC100004000000000000000' , {Ten to the 17} R'4F16345785D8A0004100000000000000' , {Ten to the 18} R'4FDE0B6B3A7640004100000000000000' , {Ten to the 19} R'508AC7230489E8004200000000000000' , {Ten to the 20} R'5156BC75E2D631004300000000000000' , {Ten to the 21} R'523635C9ADC5DEA04400000000000000' , {Ten to the 22} R'5321E19E0C9BAB244500000000000000' , {Ten to the 23} R'54152D02C7E14AF64680000000000000' , {Ten to the 24} R'54D3C21BCECCEDA14600000000000000' , {Ten to the 25} R'558459516140148447A0000000000000' , {Ten to the 26} R'5652B7D2DCC80CD248E4000000000000' , {Ten to the 27} R'5733B2E3C9FD080349CE800000000000' , {Ten to the 28} R'58204FCE5E3E25024A61100000000000' , {Ten to the 29} R'591431E0FAE6D7214B7CAA0000000000' , {Ten to the 30} R'59C9F2C9CD04674E4BDEA40000000000' , {Ten to the 31} R'5A7E37BE2022C0914C4B268000000000' , {Ten to the 32} R'5B4EE2D6D415B85A4DCEF81000000000' , {Ten to the 33} R'5C314DC6448D93384EC15B0A00000000' , {Ten to the 34} R'5D1ED09BEAD87C034F78D8E640000000' , {Ten to the 35} R'5E13426172C74D82502B878FE8000000' , {Ten to the 36} R'5EC097CE7BC9071550B34B9F10000000' , {Ten to the 37} R'5F785EE10D5DA46D51900F436A000000' , {Ten to the 38} R'604B3B4CA85A86C4527A098A22400000' , {Ten to the 39} R'612F050FE938943A53CC45F655680000' , {Ten to the 40} R'621D6329F1C35CA454BFABB9F5610000' , {Ten to the 41} R'63125DFA371A19E655F7CB54395CA000' , {Ten to the 42} R'63B7ABC62705030555ADF14A3D9E4000' , {Ten to the 43} R'6472CB5BD86321E3568CB6CE6682E800' , {Ten to the 44} R'6547BF19673DF52E5737F2410011D100' , {Ten to the 45} R'662CD76FE086B93C58E2F768A00B22A0' , {Ten to the 46} R'671C06A5EC5433C6590DDAA16406F5A4' , {Ten to the 47} R'68118427B3B4A05B5AC8A8A4DE845987' , {Ten to the 48} R'68AF298D050E43955AD69670B12B7F41' , {Ten to the 49} R'696D79F82328EA3D5BA61E066EBB2F89' , {Ten to the 50} R'6A446C3B15F992665C87D2C40534FDB5' , {Ten to the 51} R'6B2AC3A4EDBBFB805D14E3BA83411E91' , {Ten to the 52} R'6C1ABA4714957D305E0D0E549208B31B' , {Ten to the 53} R'6D10B46C6CDD6E3E5F0828F4DB456FF1' , {Ten to the 54} R'6DA70C3C40A64E6C5F51999090B65F68' , {Ten to the 55} R'6E6867A5A867F10360B2FFFA5A71FBA1' , {Ten to the 56} R'6F4140C78940F6A2614FDFFC78873D45' , {Ten to the 57} R'7028C87CB5C89A256271EBFDCB54864B' , {Ten to the 58} R'71197D4DF19D60576367337E9F14D3EF' , {Ten to the 59} R'71FEE50B7025C36A630802F236D04754' , {Ten to the 60} R'729F4F2726179A22644501D762422C94' , {Ten to the 61} R'7363917877CEC055656B21269D695BDD' , {Ten to the 62} R'743E3AEB4AE138356662F4B82261D96A' , {Ten to the 63} R'7526E4D30ECCC321675DD8F3157D27E2' , {Ten to the 64} R'76184F03E93FF9F468DAA797ED6E38ED' , {Ten to the 65} R'76F316271C7FC390688A8BEF464E3946' , {Ten to the 66} R'7797EDD871CFDA3A695697758BF0E3CC' , {Ten to the 67} R'785EF4A74721E8646A761EA977768E5F' , {Ten to the 68} R'793B58E88C75313E6BC9D329EAAA18FC' , {Ten to the 69} R'7A25179157C93EC76C3E23FA32AA4F9D' , {Ten to the 70} R'7B172EBAD6DDC73C6D86D67C5FAA71C2' , {Ten to the 71} R'7BE7D34C64A9C85D6D4460DBBCA87197' , {Ten to the 72} R'7C90E40FBEEA1D3A6E4ABC8955E946FE' , {Ten to the 73} R'7D5A8E89D75252446F6EB5D5D5B1CC5F' , {Ten to the 74} R'7E3899162693736A70C531A5A58F1FBB' , {Ten to the 75} R'7F235FADD81C282271BB3F07877973D5' !CONSTLONGLONGREAL Ten to the 75= R'7F235FADD81C282271BB3F07877973D5' !CONSTLONGLONGREAL Ten to the %C minus 74= R'03485EBBF9A41DDC75DCD8E37915AF38' %FINISH !if Amdahl %IF HOST= Gould %THENSTART ! ! ! DEFINE REAL CONSTANTS IN GOULD 'EXCESS 64' NOTATION ! ! %CONSTLONGREALARRAY TABLE OF POWERS (-78:75)= %C %C {Ten to the -78} R'001DA48CE468E7C7' , {Ten to the -77} R'011286D80EC190DC' , {Ten to the -76} R'01B94470938FA89C' , {Ten to the -75} R'0273CAC65C39C961' , {Ten to the -74} R'03485EBBF9A41DDD' , {Ten to the -73} R'042D3B357C0692AA' , {Ten to the -72} R'051C45016D841BAA' , {Ten to the -71} R'0611AB20E472914A' , {Ten to the -70} R'06B0AF48EC79ACE8' , {Ten to the -69} R'076E6D8D93CC0C11' , {Ten to the -68} R'084504787C5F878B' , {Ten to the -67} R'092B22CB4DBBB4B7' , {Ten to the -66} R'0A1AF5BF109550F2' , {Ten to the -65} R'0B10D9976A5D5297' , {Ten to the -64} R'0BA87FEA27A539EB' , {Ten to the -63} R'0C694FF258C74432' , {Ten to the -62} R'0D41D1F7777C8A9F' , {Ten to the -61} R'0E29233AAAADD6A4' , {Ten to the -60} R'0F19B604AAACA626' , {Ten to the -59} R'101011C2EAABE7D8' , {Ten to the -58} R'10A0B19D2AB70E6F' , {Ten to the -57} R'11646F023AB26905' , {Ten to the -56} R'123EC56164AF81A3' , {Ten to the -55} R'13273B5CDEEDB106' , {Ten to the -54} R'1418851A0B548EA4' , {Ten to the -53} R'14F53304714D9266' , {Ten to the -52} R'15993FE2C6D07B80' , {Ten to the -51} R'165FC7EDBC424D30' , {Ten to the -50} R'173BDCF495A9703E' , {Ten to the -49} R'18256A18DD89E627' , {Ten to the -48} R'1917624F8A762FD8' , {Ten to the -47} R'19E9D71B689DDE72' , {Ten to the -46} R'1A9226712162AB07' , {Ten to the -45} R'1B5B5806B4DDAAE4' , {Ten to the -44} R'1C391704310A8ACF' , {Ten to the -43} R'1D23AE629EA696C1' , {Ten to the -42} R'1E164CFDA3281E39' , {Ten to the -41} R'1EDF01E85F912E38' , {Ten to the -40} R'1F8B61313BBABCE3' , {Ten to the -39} R'20571CBEC554B60E' , {Ten to the -38} R'213671F73B54F1C9' , {Ten to the -37} R'2222073A8515171D' , {Ten to the -36} R'23154484932D2E72' , {Ten to the -35} R'23D4AD2DBFC3D078' , {Ten to the -34} R'2484EC3C97DA624B' , {Ten to the -33} R'255313A5DEE87D6F' , {Ten to the -32} R'2633EC47AB514E65' , {Ten to the -31} R'272073ACCB12D0FF' , {Ten to the -30} R'2814484BFEEBC2A0' , {Ten to the -29} R'28CAD2F7F5359A3B' , {Ten to the -28} R'297EC3DAF9418065' , {Ten to the -27} R'2A4F3A68DBC8F03F' , {Ten to the -26} R'2B318481895D9627' , {Ten to the -25} R'2C1EF2D0F5DA7DD9' , {Ten to the -24} R'2D1357C299A88EA7' , {Ten to the -23} R'2DC16D9A0095928A' , {Ten to the -22} R'2E78E480405D7B96' , {Ten to the -21} R'2F4B8ED0283A6D3E' , {Ten to the -20} R'302F394219248447' , {Ten to the -19} R'311D83C94FB6D2AC' , {Ten to the -18} R'3212725DD1D243AC' , {Ten to the -17} R'32B877AA3236A4B4' , {Ten to the -16} R'33734ACA5F6226F1' , {Ten to the -15} R'34480EBE7B9D5856' , {Ten to the -14} R'352D09370D425736' , {Ten to the -13} R'361C25C268497682' , {Ten to the -12} R'37119799812DEA11' , {Ten to the -11} R'37AFEBFF0BCB24AB' , {Ten to the -10} R'386DF37F675EF6EB' , {Ten to the -9} R'3944B82FA09B5A53' , {Ten to the -8} R'3A2AF31DC4611874' , {Ten to the -7} R'3B1AD7F29ABCAF48' , {Ten to the -6} R'3C10C6F7A0B5ED8D' , {Ten to the -5} R'3CA7C5AC471B4784' , {Ten to the -4} R'3D68DB8BAC710CB3' , {Ten to the -3} R'3E4189374BC6A7F0' , {Ten to the -2} R'3F28F5C28F5C28F6' , {Ten to the -1} R'401999999999999A' , {Ten to the 0} R'4110000000000000' , {Ten to the 1} R'41A0000000000000' , {Ten to the 2} R'4264000000000000' , {Ten to the 3} R'433E800000000000' , {Ten to the 4} R'4427100000000000' , {Ten to the 5} R'45186A0000000000' , {Ten to the 6} R'45F4240000000000' , {Ten to the 7} R'4698968000000000' , {Ten to the 8} R'475F5E1000000000' , {Ten to the 9} R'483B9ACA00000000' , {Ten to the 10} R'492540BE40000000' , {Ten to the 11} R'4A174876E8000000' , {Ten to the 12} R'4AE8D4A510000000' , {Ten to the 13} R'4B9184E72A000000' , {Ten to the 14} R'4C5AF3107A400000' , {Ten to the 15} R'4D38D7EA4C680000' , {Ten to the 16} R'4E2386F26FC10000' , {Ten to the 17} R'4F16345785D8A000' , {Ten to the 18} R'4FDE0B6B3A764000' , {Ten to the 19} R'508AC7230489E800' , {Ten to the 20} R'5156BC75E2D63100' , {Ten to the 21} R'523635C9ADC5DEA0' , {Ten to the 22} R'5321E19E0C9BAB24' , {Ten to the 23} R'54152D02C7E14AF7' , {Ten to the 24} R'54D3C21BCECCEDA1' , {Ten to the 25} R'5584595161401485' , {Ten to the 26} R'5652B7D2DCC80CD3' , {Ten to the 27} R'5733B2E3C9FD0804' , {Ten to the 28} R'58204FCE5E3E2502' , {Ten to the 29} R'591431E0FAE6D721' , {Ten to the 30} R'59C9F2C9CD04674F' , {Ten to the 31} R'5A7E37BE2022C091' , {Ten to the 32} R'5B4EE2D6D415B85B' , {Ten to the 33} R'5C314DC6448D9339' , {Ten to the 34} R'5D1ED09BEAD87C03' , {Ten to the 35} R'5E13426172C74D82' , {Ten to the 36} R'5EC097CE7BC90716' , {Ten to the 37} R'5F785EE10D5DA46E' , {Ten to the 38} R'604B3B4CA85A86C4' , {Ten to the 39} R'612F050FE938943B' , {Ten to the 40} R'621D6329F1C35CA5' , {Ten to the 41} R'63125DFA371A19E7' , {Ten to the 42} R'63B7ABC627050306' , {Ten to the 43} R'6472CB5BD86321E4' , {Ten to the 44} R'6547BF19673DF52E' , {Ten to the 45} R'662CD76FE086B93D' , {Ten to the 46} R'671C06A5EC5433C6' , {Ten to the 47} R'68118427B3B4A05C' , {Ten to the 48} R'68AF298D050E4396' , {Ten to the 49} R'696D79F82328EA3E' , {Ten to the 50} R'6A446C3B15F99267' , {Ten to the 51} R'6B2AC3A4EDBBFB80' , {Ten to the 52} R'6C1ABA4714957D30' , {Ten to the 53} R'6D10B46C6CDD6E3E' , {Ten to the 54} R'6DA70C3C40A64E6C' , {Ten to the 55} R'6E6867A5A867F104' , {Ten to the 56} R'6F4140C78940F6A2' , {Ten to the 57} R'7028C87CB5C89A25' , {Ten to the 58} R'71197D4DF19D6057' , {Ten to the 59} R'71FEE50B7025C36A' , {Ten to the 60} R'729F4F2726179A22' , {Ten to the 61} R'7363917877CEC055' , {Ten to the 62} R'743E3AEB4AE13835' , {Ten to the 63} R'7526E4D30ECCC321' , {Ten to the 64} R'76184F03E93FF9F5' , {Ten to the 65} R'76F316271C7FC391' , {Ten to the 66} R'7797EDD871CFDA3A' , {Ten to the 67} R'785EF4A74721E864' , {Ten to the 68} R'793B58E88C75313F' , {Ten to the 69} R'7A25179157C93EC7' , {Ten to the 70} R'7B172EBAD6DDC73D' , {Ten to the 71} R'7BE7D34C64A9C85D' , {Ten to the 72} R'7C90E40FBEEA1D3A' , {Ten to the 73} R'7D5A8E89D7525244' , {Ten to the 74} R'7E3899162693736B' , {Ten to the 75} R'7F235FADD81C2823' ! !This table was derived from the ! IBM Table of Powers of Ten above %CONSTLONGREAL Ten to the 75= R'7F235FADD81C2823' %CONSTLONGREAL Ten to the %C Minus 74= R'03485EBBF9A41DDD' %FINISH !if Gould %IF HOST= EMAS %THENSTART ! !*********************************************************************** ! ! GLOBAL VARIABLES ! !*********************************************************************** ! %OWNINTEGER INITIALISED= False; !%C %C INITIALISED is only set to TRUE once we have mapped all %C the REALNAMEs below onto the relevant constants %C above. %C (NOTE that we cannot currently use R' type constants as '%C the IMP compiler assumes that they are in ICL 2900 format) %OWNLONGREALARRAYNAME TABLE1 OF POWERS {mapped onto PERQ POWERS OF TEN TABLE1} %OWNLONGREALARRAYNAME TABLE2 OF POWERS {mapped onto PERQ POWERS OF TEN TABLE2} ! %CONSTLONGREALARRAYFORMAT FORM OF TABLE1 ( (-305//5)+B1 : (305//5)+B1 ) %CONSTLONGREALARRAYFORMAT FORM OF TABLE2 ( -5 +B2 : 5 +B2 ) %OWNLONGREALNAME Ten to the 305 {mapped onto PERQ POWERS OF TEN TABLE1 (244)} %OWNLONGREALNAME Ten to the Minus 305 {mapped onto PERQ POWERS OF TEN TABLE1 ( 0)} %FINISH !if EMAS %EXTERNALLONGLONGREALFN POWER OF TEN %ALIAS "S#POWEROFTEN" (%INTEGER EXP) ! ! ! ! ! A GLOBAL PROCEDURE WHICH RETURNS A GIVEN POWER ! ! OF TEN IN DOUBLE PRECISION IEEE FORM. ! ! ! %INTEGER I,J %IF HOST=GOULD %ORC HOST= IBM %THENRESULT= TABLE OF POWERS (EXP) %C %ELSESTART %IF HOST= EMAS %AND INITIALISED= False %THENSTART ! ! Map our RealNames onto the ConstIntegers ! TABLE1 OF POWERS== ARRAY(ADDR(PERQ POWERS OF TEN TABLE1(0)),FORM OF TABLE1) TABLE2 OF POWERS== ARRAY(ADDR(PERQ POWERS OF TEN TABLE2(0)),FORM OF TABLE2) !! Ten to the 305 == TABLE1 OF POWERS ( ( 305//5)+B1 {=122}) Ten to the Minus 305 == TABLE1 OF POWERS ( (-305//5)+B1 {= 0}) INITIALISED=True %FINISH I = EXP // 5 J = EXP - (I*5) ! %IF I\= 0 %THENRESULT= TABLE1 OF POWERS (I+B1) * TABLE2 OF POWERS (J+B2) %C %ELSERESULT= TABLE2 OF POWERS (J+B2) %FINISH %END; !of POWER OF TEN %IF HOST= IBM %OR HOST= GOULD %THENSTART %EXTERNALLONGLONGREALFN INTO RANGE %ALIAS "S#INTORANGE" %C (%LONGLONGREAL X, %INTEGERNAME EXP) ! ! ! ! A PROCEDURE WHICH BRINGS THE VALUE OF THE GIVEN ! ! PARAMETER INTO THE RANGE 10.0> X >=1.0 ! ! !Additionally, the variable EXP is changed to reflect the ! magnitude (scale of 10) of the parameter. ! ! %INTEGER I; !a work variable %IF X>=10.0 %THENSTART ! ! The value is too large ! %IF X>=Ten to the 75 %THEN I=75 %ELSESTART {ELSE } I= 2 {find the scale of} I=I+1 %WHILE X>= TABLE OF POWERS(I) { the value } I=I-1 %FINISH; X =X/TABLE OF POWERS(I) EXP = EXP+I %FINISH %IF X<1.0 %THENSTART ! ! The value is too small ! X=X*10.0 %AND EXP=EXP-1 %WHILE X X >=1.0 ! ! !Note that there are two steps in scaling the value, the first is ! to bring it into the range 10.0**(5) - 10.0**(-5), and the ! second step to bring it into the range 10.0**( 1) - 10.0**(0). ! ! ! %INTEGER I,J %IF HOST= EMAS %AND INITIALISED= False %THENSTART ! ! Map our RealNames onto the ConstIntegers ! TABLE1 OF POWERS== ARRAY(ADDR(PERQ POWERS OF TEN TABLE1(0)),FORM OF TABLE1) TABLE2 OF POWERS== ARRAY(ADDR(PERQ POWERS OF TEN TABLE2(0)),FORM OF TABLE2) !! Ten to the 305 == TABLE1 OF POWERS ( ( 305//5)+B1 {=122}) Ten to the Minus 305 == TABLE1 OF POWERS ( (-305//5)+B1 {= 0}) INITIALISED=True %FINISH %IF X>= 10.0 %THENSTART ! ! ! The Value is too Large ! ! %IF X< Ten to the 305 %THENSTART ! ! Bring the Value down to below 10(** 5) ! I= 1+B1 I= I+1 %WHILE X>= TABLE1 OF POWERS (I) I= I-1 %FINISHELSE {if X>= Ten to the 305} I= (305//5)+B1 {=122} X = X/TABLE1 OF POWERS (I) ! ! Now bring the value down to the range 10**1 - 10**0 ! J= 0+B2 J= J+1 %WHILE X>= TABLE2 OF POWERS (J) J= J-1 %AND X =X/TABLE2 OF POWERS (J) EXP=EXP + (I*5) + J - (B1*5 + B2){-correction factor as arrays start at 0} %FINISH %IF X< 1.0 %THENSTART ! ! ! The Value is too Small ! ! %IF X= TABLE2 OF POWERS ( J) J=J-1 %AND X=X*TABLE2 OF POWERS (-J+B2+B2) ! EXP= EXP + (I*5) + J - (B1*5 + B2){-correction factor as arrays start at 0} %FINISH ! ! Return ! %RESULT= X %END; !of INTO RANGE (if PNX or Accent or Whitechapel or Perq3) ! ! %FINISH %ENDOFFILE