Google
 

Trailing-Edge - PDP-10 Archives - decuslib20-01 - decus/20-0013/cot.mac
There are 2 other files named cot.mac in the archive. Click here to see a list.
	TITLE	COT ANGENT FUNCTION
	SUBTTL	V.001  R.S.TOMLINSON  18 FEB 69
	ENTRY	COT
	INTERN	COT
	EXTERN	SIN,COS

; THIS PROGRAM COMPUTES COT(X) BY THE SIMPLE EXPEDIENT OF
; COT(X) = COS(X)/SIN(X)
; Modified to PUSHJ/POPJ convention 11 Oct 1980
; by Paul T. Robinson, Wesleyan Univ. for DECUS conversion to DEC-20

;COT:	Z
;	MOVE 0,@0(16)
;	MOVEM 0,COTT#
;	JSA 16,SIN
;	JUMP COTT
;	MOVEM 0,COTT2#
;	JSA 16,COS
;	JUMP COTT
;	FDVR 0,COTT2
;	JRA 16,1(16)

; Use the arg block that FORTRAN gives to call sin and cos routines
cot:	pushj	17,sin
	movem	0,cott#
	pushj	17,cos
	fdvr	0,cott
	popj	17,

	END