Commit | Line | Data |
---|---|---|
7af5ad59 PH |
1 | / |
2 | / C S I N | |
3 | / - - - - | |
4 | / | |
5 | / VERSION 5A 4-27-77 PT | |
6 | / | |
7 | /COMPLEX SIN AND COS ROUTINE | |
8 | / | |
9 | /CCOS(X+I*Y)=COS(X)*COSH(Y)-SIN(X)*SINH(Y) | |
10 | / | |
11 | /CSIN(X+I*Y)=SIN(X)*COSH(Y)+COS(X)*SINH(Y) | |
12 | / | |
13 | /CALLS SIN,COS,COSH,SINH | |
14 | / | |
15 | SECT CSIN | |
16 | JA #CSIN | |
17 | DPCHK | |
18 | TEXT +CSIN + | |
19 | CSINXR, SETX XR | |
20 | SETB BP | |
21 | JA .+3 | |
22 | BP, F 0.0 | |
23 | XR, F 0.0 | |
24 | ARG, F 0.0 | |
25 | F 0.0 | |
26 | C, F 0.0 | |
27 | CH, F 0.0 | |
28 | S, F 0.0 | |
29 | ORG 10*3+BP | |
30 | FNOP | |
31 | JA CSINXR | |
32 | 0 | |
33 | ||
34 | RT, JA . | |
35 | SH, F 0.0 | |
36 | BASE 0 | |
37 | #CSIN, SETX XR | |
38 | LDX 0,0 | |
39 | COM, STARTD | |
40 | FLDA 10*3 | |
41 | FSTA RT | |
42 | FLDA 0 | |
43 | SETB BP | |
44 | BASE BP | |
45 | LDX 1,1 | |
46 | FSTA BP | |
47 | FLDA% BP,1 | |
48 | FSTA BP | |
49 | STARTE | |
50 | FLDA% BP | |
51 | FSTA ARG | |
52 | STARTF | |
53 | EXTERN COS | |
54 | JSR COS | |
55 | JA CSA | |
56 | JA ARG /COS(X) | |
57 | CSA, FSTA C | |
58 | EXTERN SIN | |
59 | JSR SIN | |
60 | JA CSB | |
61 | JA ARG | |
62 | CSB, FSTA S /SIN(X) | |
63 | EXTERN SINH | |
64 | JSR SINH | |
65 | JA CSC | |
66 | JA ARG+3 | |
67 | CSC, FSTA SH /SINH(Y) | |
68 | EXTERN COSH | |
69 | JSR COSH | |
70 | JA CSD | |
71 | JA ARG+3 | |
72 | CSD, FSTA CH /COSH(Y) | |
73 | /XR0 IS 0 FOR CSIN AND 1 FOR CCOS | |
74 | JXN CALCOS,0 | |
75 | FLDA S | |
76 | FMUL CH | |
77 | FSTA ARG /SIN*COSH | |
78 | FLDA C | |
79 | CSE, FMUL SH | |
80 | FSTA ARG+3 /COS*SINH | |
81 | STARTE | |
82 | FLDA ARG | |
83 | FSTA #CAC | |
84 | JA RT | |
85 | EXTERN #CAC | |
86 | /DO COS | |
87 | / | |
88 | CALCOS, FLDA C | |
89 | FMUL CH | |
90 | FSTA ARG | |
91 | FLDA S | |
92 | FNEG | |
93 | JA CSE | |
94 | ENTRY CCOS | |
95 | CCOS, SETX XR | |
96 | LDX 1,0 | |
97 | JA COM | |
98 | \f |