1 CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC
4 CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC
10 C Authors: Paul N. Swarztrauber and Richard A. Valent
11 C National Center for Atmospheric Research
12 C PO 3000, Boulder, Colorado
14 C Date: Wed Mar 29 18:31:13 MST 1995
16 C Description: Lower-level auxiliary routine
18 SUBROUTINE CMF5KF
(LOT
,IDO
,L1
,NA
,CC
,IM1
,IN1
,CH
,IM2
,IN2
,WA
)
19 REAL CC
(2,IN1
,L1
,IDO
,5),CH
(2,IN2
,L1
,5,IDO
),WA
(IDO
,4,2)
20 DATA TR11
,TI11
,TR12
,TI12
/.3090169943749474,-.9510565162951536,
21 1-.8090169943749474,-.5877852522924731/
23 C FFTPACK 5.0 auxiliary routine
27 IF (IDO
.GT
. 1) GO TO 102
29 IF (NA
.EQ
. 1) GO TO 106
32 TI5
= CC
(2,M1
,K
,1,2)-CC
(2,M1
,K
,1,5)
33 TI2
= CC
(2,M1
,K
,1,2)+CC
(2,M1
,K
,1,5)
34 TI4
= CC
(2,M1
,K
,1,3)-CC
(2,M1
,K
,1,4)
35 TI3
= CC
(2,M1
,K
,1,3)+CC
(2,M1
,K
,1,4)
36 TR5
= CC
(1,M1
,K
,1,2)-CC
(1,M1
,K
,1,5)
37 TR2
= CC
(1,M1
,K
,1,2)+CC
(1,M1
,K
,1,5)
38 TR4
= CC
(1,M1
,K
,1,3)-CC
(1,M1
,K
,1,4)
39 TR3
= CC
(1,M1
,K
,1,3)+CC
(1,M1
,K
,1,4)
40 CHOLD1
= SN*
(CC
(1,M1
,K
,1,1)+TR2
+TR3
)
41 CHOLD2
= SN*
(CC
(2,M1
,K
,1,1)+TI2
+TI3
)
42 CR2
= CC
(1,M1
,K
,1,1)+TR11*TR2
+TR12*TR3
43 CI2
= CC
(2,M1
,K
,1,1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)+TR11*TI2
+TR12*TI3
110 CR3
= CC
(1,M1
,K
,1,1)+TR12*TR2
+TR11*TR3
111 CI3
= CC
(2,M1
,K
,1,1)+TR12*TI2
+TR11*TI3
112 CR5
= TI11*TR5
+TI12*TR4
113 CI5
= TI11*TI5
+TI12*TI4
114 CR4
= TI12*TR5
-TI11*TR4
115 CI4
= TI12*TI5
-TI11*TI4
116 CH
(1,M2
,K
,2,1) = CR2
-CI5
117 CH
(1,M2
,K
,5,1) = CR2
+CI5
118 CH
(2,M2
,K
,2,1) = CI2
+CR5
119 CH
(2,M2
,K
,3,1) = CI3
+CR4
120 CH
(1,M2
,K
,3,1) = CR3
-CI4
121 CH
(1,M2
,K
,4,1) = CR3
+CI4
122 CH
(2,M2
,K
,4,1) = CI3
-CR4
123 CH
(2,M2
,K
,5,1) = CI2
-CR5
130 TI5
= CC
(2,M1
,K
,I
,2)-CC
(2,M1
,K
,I
,5)
131 TI2
= CC
(2,M1
,K
,I
,2)+CC
(2,M1
,K
,I
,5)
132 TI4
= CC
(2,M1
,K
,I
,3)-CC
(2,M1
,K
,I
,4)
133 TI3
= CC
(2,M1
,K
,I
,3)+CC
(2,M1
,K
,I
,4)
134 TR5
= CC
(1,M1
,K
,I
,2)-CC
(1,M1
,K
,I
,5)
135 TR2
= CC
(1,M1
,K
,I
,2)+CC
(1,M1
,K
,I
,5)
136 TR4
= CC
(1,M1
,K
,I
,3)-CC
(1,M1
,K
,I
,4)
137 TR3
= CC
(1,M1
,K
,I
,3)+CC
(1,M1
,K
,I
,4)
138 CH
(1,M2
,K
,1,I
) = CC
(1,M1
,K
,I
,1)+TR2
+TR3
139 CH
(2,M2
,K
,1,I
) = CC
(2,M1
,K
,I
,1)+TI2
+TI3
140 CR2
= CC
(1,M1
,K
,I
,1)+TR11*TR2
+TR12*TR3
141 CI2
= CC
(2,M1
,K
,I
,1)+TR11*TI2
+TR12*TI3
142 CR3
= CC
(1,M1
,K
,I
,1)+TR12*TR2
+TR11*TR3
143 CI3
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