1 subroutine r1f4kb ( ido, l1, cc, in1, ch, in2, wa1, wa2, wa3 )
3 !*****************************************************************************80
5 !! R1F4KB 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,ido,4,l1)
42 real ( kind = 4 ) ch(in2,ido,l1,4)
43 integer ( kind = 4 ) i
44 integer ( kind = 4 ) ic
45 integer ( kind = 4 ) idp2
46 integer ( kind = 4 ) k
47 real ( kind = 4 ) sqrt2
48 real ( kind = 4 ) wa1(ido)
49 real ( kind = 4 ) wa2(ido)
50 real ( kind = 4 ) wa3(ido)
52 sqrt2 = sqrt ( 2.0E+00 )
55 ch(1,1,k,3) = ( cc(1,1,1,k) + cc(1,ido,4,k) ) &
56 - ( cc(1,ido,2,k) + cc(1,ido,2,k) )
57 ch(1,1,k,1) = ( cc(1,1,1,k) + cc(1,ido,4,k) ) &
58 + ( cc(1,ido,2,k) + cc(1,ido,2,k) )
59 ch(1,1,k,4) = ( cc(1,1,1,k) - cc(1,ido,4,k) ) &
60 + ( cc(1,1,3,k) + cc(1,1,3,k) )
61 ch(1,1,k,2) = ( cc(1,1,1,k) - cc(1,ido,4,k) ) &
62 - ( cc(1,1,3,k) + cc(1,1,3,k) )
76 ch(1,i-1,k,1) = (cc(1,i-1,1,k)+cc(1,ic-1,4,k)) &
77 +(cc(1,i-1,3,k)+cc(1,ic-1,2,k))
78 ch(1,i,k,1) = (cc(1,i,1,k)-cc(1,ic,4,k)) &
79 +(cc(1,i,3,k)-cc(1,ic,2,k))
80 ch(1,i-1,k,2) = wa1(i-2)*((cc(1,i-1,1,k)-cc(1,ic-1,4,k)) &
81 -(cc(1,i,3,k)+cc(1,ic,2,k)))-wa1(i-1) &
82 *((cc(1,i,1,k)+cc(1,ic,4,k))+(cc(1,i-1,3,k)-cc(1,ic-1,2,k)))
83 ch(1,i,k,2) = wa1(i-2)*((cc(1,i,1,k)+cc(1,ic,4,k)) &
84 +(cc(1,i-1,3,k)-cc(1,ic-1,2,k)))+wa1(i-1) &
85 *((cc(1,i-1,1,k)-cc(1,ic-1,4,k))-(cc(1,i,3,k)+cc(1,ic,2,k)))
86 ch(1,i-1,k,3) = wa2(i-2)*((cc(1,i-1,1,k)+cc(1,ic-1,4,k)) &
87 -(cc(1,i-1,3,k)+cc(1,ic-1,2,k)))-wa2(i-1) &
88 *((cc(1,i,1,k)-cc(1,ic,4,k))-(cc(1,i,3,k)-cc(1,ic,2,k)))
89 ch(1,i,k,3) = wa2(i-2)*((cc(1,i,1,k)-cc(1,ic,4,k)) &
90 -(cc(1,i,3,k)-cc(1,ic,2,k)))+wa2(i-1) &
91 *((cc(1,i-1,1,k)+cc(1,ic-1,4,k))-(cc(1,i-1,3,k) &
93 ch(1,i-1,k,4) = wa3(i-2)*((cc(1,i-1,1,k)-cc(1,ic-1,4,k)) &
94 +(cc(1,i,3,k)+cc(1,ic,2,k)))-wa3(i-1) &
95 *((cc(1,i,1,k)+cc(1,ic,4,k))-(cc(1,i-1,3,k)-cc(1,ic-1,2,k)))
96 ch(1,i,k,4) = wa3(i-2)*((cc(1,i,1,k)+cc(1,ic,4,k)) &
97 -(cc(1,i-1,3,k)-cc(1,ic-1,2,k)))+wa3(i-1) &
98 *((cc(1,i-1,1,k)-cc(1,ic-1,4,k))+(cc(1,i,3,k)+cc(1,ic,2,k)))
102 if ( mod ( ido, 2 ) == 1 ) then
109 ch(1,ido,k,1) = ( cc(1,ido,1,k) + cc(1,ido,3,k) ) &
110 + ( cc(1,ido,1,k) + cc(1,ido,3,k))
111 ch(1,ido,k,2) = sqrt2 * ( ( cc(1,ido,1,k) - cc(1,ido,3,k) ) &
112 - ( cc(1,1,2,k) + cc(1,1,4,k) ) )
113 ch(1,ido,k,3) = ( cc(1,1,4,k) - cc(1,1,2,k) ) &
114 + ( cc(1,1,4,k) - cc(1,1,2,k) )
115 ch(1,ido,k,4) = -sqrt2 * ( ( cc(1,ido,1,k) - cc(1,ido,3,k) ) &
116 + ( cc(1,1,2,k) + cc(1,1,4,k) ) )