1 subroutine c1f3kf ( ido, l1, na, cc, in1, ch, in2, wa )
3 !*****************************************************************************80
5 !! C1F3KF is an FFTPACK5 auxiliary routine.
8 ! Copyright (C) 1995-2004, Scientific Computing Division,
9 ! University Corporation for Atmospheric Research
23 ! Vectorizing the Fast Fourier Transforms,
24 ! in Parallel Computations,
25 ! edited by G. Rodrigue,
26 ! Academic Press, 1982.
29 ! Fast Fourier Transform Algorithms for Vector Computers,
30 ! Parallel Computing, pages 45-63, 1984.
36 integer ( kind = 4 ) ido
37 integer ( kind = 4 ) in1
38 integer ( kind = 4 ) in2
39 integer ( kind = 4 ) l1
41 real ( kind = 4 ) cc(in1,l1,ido,3)
42 real ( kind = 4 ) ch(in2,l1,3,ido)
51 integer ( kind = 4 ) i
52 integer ( kind = 4 ) k
53 integer ( kind = 4 ) na
55 real ( kind = 4 ), parameter :: taui = -0.866025403784439E+00
56 real ( kind = 4 ), parameter :: taur = -0.5E+00
59 real ( kind = 4 ) wa(ido,2,2)
65 tr2 = cc(1,k,1,2)+cc(1,k,1,3)
66 cr2 = cc(1,k,1,1)+taur*tr2
67 ch(1,k,1,1) = cc(1,k,1,1)+tr2
68 ti2 = cc(2,k,1,2)+cc(2,k,1,3)
69 ci2 = cc(2,k,1,1)+taur*ti2
70 ch(2,k,1,1) = cc(2,k,1,1)+ti2
71 cr3 = taui*(cc(1,k,1,2)-cc(1,k,1,3))
72 ci3 = taui*(cc(2,k,1,2)-cc(2,k,1,3))
74 ch(1,k,2,1) = cr2 - ci3
75 ch(1,k,3,1) = cr2 + ci3
76 ch(2,k,2,1) = ci2 + cr3
77 ch(2,k,3,1) = ci2 - cr3
84 tr2 = cc(1,k,i,2)+cc(1,k,i,3)
85 cr2 = cc(1,k,i,1)+taur*tr2
86 ch(1,k,1,i) = cc(1,k,i,1)+tr2
87 ti2 = cc(2,k,i,2)+cc(2,k,i,3)
88 ci2 = cc(2,k,i,1)+taur*ti2
89 ch(2,k,1,i) = cc(2,k,i,1)+ti2
90 cr3 = taui*(cc(1,k,i,2)-cc(1,k,i,3))
91 ci3 = taui*(cc(2,k,i,2)-cc(2,k,i,3))
98 ch(2,k,2,i) = wa(i,1,1) * di2 - wa(i,1,2) * dr2
99 ch(1,k,2,i) = wa(i,1,1) * dr2 + wa(i,1,2) * di2
100 ch(2,k,3,i) = wa(i,2,1) * di3 - wa(i,2,2) * dr3
101 ch(1,k,3,i) = wa(i,2,1) * dr3 + wa(i,2,2) * di3
106 else if ( na == 1 ) then
108 sn = 1.0E+00 / real ( 3 * l1, kind = 4 )
111 tr2 = cc(1,k,1,2)+cc(1,k,1,3)
112 cr2 = cc(1,k,1,1)+taur*tr2
113 ch(1,k,1,1) = sn*(cc(1,k,1,1)+tr2)
114 ti2 = cc(2,k,1,2)+cc(2,k,1,3)
115 ci2 = cc(2,k,1,1)+taur*ti2
116 ch(2,k,1,1) = sn*(cc(2,k,1,1)+ti2)
117 cr3 = taui*(cc(1,k,1,2)-cc(1,k,1,3))
118 ci3 = taui*(cc(2,k,1,2)-cc(2,k,1,3))
120 ch(1,k,2,1) = sn*(cr2-ci3)
121 ch(1,k,3,1) = sn*(cr2+ci3)
122 ch(2,k,2,1) = sn*(ci2+cr3)
123 ch(2,k,3,1) = sn*(ci2-cr3)
129 sn = 1.0E+00 / real ( 3 * l1, kind = 4 )
133 tr2 = cc(1,k,1,2)+cc(1,k,1,3)
134 cr2 = cc(1,k,1,1)+taur*tr2
135 cc(1,k,1,1) = sn*(cc(1,k,1,1)+tr2)
136 ti2 = cc(2,k,1,2)+cc(2,k,1,3)
137 ci2 = cc(2,k,1,1)+taur*ti2
138 cc(2,k,1,1) = sn*(cc(2,k,1,1)+ti2)
139 cr3 = taui*(cc(1,k,1,2)-cc(1,k,1,3))
140 ci3 = taui*(cc(2,k,1,2)-cc(2,k,1,3))
142 cc(1,k,1,2) = sn*(cr2-ci3)
143 cc(1,k,1,3) = sn*(cr2+ci3)
144 cc(2,k,1,2) = sn*(ci2+cr3)
145 cc(2,k,1,3) = sn*(ci2-cr3)