/ 
/ 
/                   FIRST PRINTING, FEBRUARY 1974
/ 
/ THE INFORMATION IN THIS DOCUMENT IS SUBJECT TO 
/ CHANGE WITHOUT NOTICE AND SHOULD NOT BE CONSTRUED
/ AS A COMMITMENT BY DIGITAL EQUIPMENT CORPORATION.
/ DIGITAL EQUIPMENT CORPORATION ASSUMES NO RESPON-
/ SIBILITY FOR ANY ERRORS THAT MAY APPEAR IN THIS
/ DOCUMENT.
/ 
/ THE SOFTWARE DESCRIBED IN THIS DOCUMENT IS FUR-
/ NISHED TO THE PURCHASER UNDER A LICENSE FOR USE ON
/ A SINGLE COMPUTER SYSTEM AND CAN BE COPIED (WITH
/ INCLUSION OF DIGITAL'S COPYRIGHT NOTICE) ONLY FOR 
/ USE IN SUCH SYSTEM, EXCEPT AS MAY OTHERWISE BE PRO-
/ VIDED IN WRITING BY DIGITAL.
/ 
/ DIGITAL EQUIPMENT CORPORATION ASSUMES NO RESPONSIBILITY
/ FOR THE USE OR RELIABILITY OF ITS SOFTWARE ON EQUIP-
/ MENT THAT IS NOT SUPPLIED BY DIGITAL.
/ 
/ COPYRIGHT (C) 1974, BY DIGITAL EQUIPMENT CORPORATION
/ 
/ 
        .EJECT
/COPYRIGHT 1970,1971, DIGITAL EQUIPMENT CORP., MAYNARD, MASS.
/EDIT 5   2-17-71
/FOR HARDWARE FLOATING POINT PROCESSOR (FPP), DEFINE % FPP,
     .TITLE .BH	 RAISE DOUBLE BASE (A) TO DOUBLE POWER (B)  A**B
       .GLOBL .BH,.CB,.DE,.DF,.ER,
	.IFUND %FPP
	.GLOBL .AB,.AS
	.ENDC
	.IFUND %FPP
	.DEFIN DMP%,A
	JMS* A			/DOUBLE MULTIPLY (.AS)
	.ENDM
	.ENDC
	.IFDEF %FPP
DMP=711540
	.DEFIN DMP%
	DMP
	.ENDM
	.ENDC
/      JMS*   (.BH) 	SURB CALL (A IN FLOAT ACC)
/      CAL/XCTADDR		ADDR OF B (XCT IF INDIRECT)
/      NEXT   INSTRUCTION	SUBR RETURN (RESULT IN FLOAT ACC)
/DIRECT ASSIGN. FOR FPP
	.IFDEF %FPP
BNA=716610
	.ENDC
/
.BH    CAL    0	         /ENTRY-EXIT
       JMS*   .CB	         /SHORT GET ARG (.CB)
BH02   CAL    0	         /ADDR OF B
	.IFDEF %FPP
	BNA			/BR ON NOT EQUAL 0
	BH06
	.ENDC
	.IFUND %FPP
	LAC* .AB
	SZA
	JMP BH06
	.ENDC
	ISZ BH02		/PASS EXP. WORD
	LAC* BH02		/CHECK EXP. MANT.
	SPA!SNA!CLA
	JMS* .ER		/OTS 15
	AND 15			/DUMMY INSTR (500015)
	JMP* .BH		/ANS=BASE
BH06	JMS*   .DE	         /COMPUTE LOG2(A) (.DE)
       DMP%   .AS	         /MULTIPLY DOUBLE (.AS)
       .DSA   BH05	         / (LOG2(A) * LOGE(2) = LOGE(A))
       DMP%   .AS	         /MULTIPLY DOUBLE (.AS)
	.DSA	BH02+400000	/ *** DDS JAN69 ***
       JMS*   .DF	         /COMPUTE EXP (B * LOGE(A))
       JMP*   .BH	         /EXIT
BH05	    0	         /LOGE(2) (1)  (0.6931471806)
	    261344         /        (2)
	    137700         /        (3)
       .END
