12 integer(IK),
allocatable :: factor(:)
14 type(display_type) :: disp
19 complex(CKG),
allocatable :: data(:), coef(:), work(:)
21 call disp%show(
"data = [complex(CKG) :: (1., -6.), (2., -5.), (3., -4.), (4., -3.), (5., -2.), (6., -1.)]")
22 data = [
complex(CKG) :: (
1.,
-6.), (
2.,
-5.), (
3.,
-4.), (
4.,
-3.), (
5.,
-2.), (
6.,
-1.)]
23 call disp%show(
"if (allocated(coef)) deallocate(coef); allocate(coef, mold = data)")
24 if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
25 call disp%show(
"if (allocated(work)) deallocate(work); allocate(work, mold = data)")
26 if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
27 call disp%show(
"factor = getfactorFFT(data, coef)")
28 factor
= getfactorFFT(data, coef)
33 call disp%show(
"call setFFTF(factor, coef, data, work, inwork)")
34 call setFFTF(factor, coef, data, work, inwork)
35 call disp%show(
"if (inwork) data = work")
36 if (inwork)
data = work
40 call disp%show(
"call setFFTI(factor, coef, data, work, inwork)")
41 call setFFTI(factor, coef, data, work, inwork)
42 call disp%show(
"if (inwork) data = work")
43 if (inwork)
data = work
51 complex(CKG),
allocatable :: data(:), coef(:), work(:)
53 call disp%show(
"data = [complex(CKG) :: (1., -6.), (2., -5.), (3., -4.), (4., -3.), (5., -2.), (6., -1.)]")
54 data = [
complex(CKG) :: (
1.,
-6.), (
2.,
-5.), (
3.,
-4.), (
4.,
-3.), (
5.,
-2.), (
6.,
-1.)]
55 call disp%show(
"if (allocated(coef)) deallocate(coef); allocate(coef, mold = data)")
56 if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
57 call disp%show(
"if (allocated(work)) deallocate(work); allocate(work, mold = data)")
58 if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
59 call disp%show(
"factor = getfactorFFT(data, coef)")
60 factor
= getfactorFFT(data, coef)
65 call disp%show(
"call setFFTF(factor, coef, data, work, inwork)")
66 call setFFTF(factor, coef, data, work, inwork)
67 call disp%show(
"if (inwork) data = work")
68 if (inwork)
data = work
72 call disp%show(
"call setFFTI(factor, coef, data, work, inwork)")
73 call setFFTI(factor, coef, data, work, inwork)
74 call disp%show(
"if (inwork) data = work")
75 if (inwork)
data = work
83 complex(CKG),
allocatable :: data(:), coef(:), work(:)
85 call disp%show(
"data = [complex(CKG) :: (1., -6.), (2., -5.), (3., -4.), (4., -3.), (5., -2.), (6., -1.)]")
86 data = [
complex(CKG) :: (
1.,
-6.), (
2.,
-5.), (
3.,
-4.), (
4.,
-3.), (
5.,
-2.), (
6.,
-1.)]
87 call disp%show(
"if (allocated(coef)) deallocate(coef); allocate(coef, mold = data)")
88 if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
89 call disp%show(
"if (allocated(work)) deallocate(work); allocate(work, mold = data)")
90 if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
91 call disp%show(
"factor = getfactorFFT(data, coef)")
92 factor
= getfactorFFT(data, coef)
97 call disp%show(
"call setFFTF(factor, coef, data, work, inwork)")
98 call setFFTF(factor, coef, data, work, inwork)
99 call disp%show(
"if (inwork) data = work")
100 if (inwork)
data = work
104 call disp%show(
"call setFFTI(factor, coef, data, work, inwork)")
105 call setFFTI(factor, coef, data, work, inwork)
106 call disp%show(
"if (inwork) data = work")
107 if (inwork)
data = work
115 real(RKG),
allocatable :: data(:), coef(:), work(:)
117 call disp%show(
"data = [real(RKG) :: 1., 2., 3., 4., 5., 6.5]")
118 data = [
real(RKG) ::
1.,
2.,
3.,
4.,
5.,
6.5]
119 call disp%show(
"if (allocated(coef)) deallocate(coef); allocate(coef, mold = data)")
120 if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
121 call disp%show(
"if (allocated(work)) deallocate(work); allocate(work, mold = data)")
122 if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
123 call disp%show(
"factor = getfactorFFT(data, coef)")
124 factor
= getfactorFFT(data, coef)
129 call disp%show(
"call setFFTF(factor, coef, data, work, inwork)")
130 call setFFTF(factor, coef, data, work, inwork)
131 call disp%show(
"if (inwork) data = work")
132 if (inwork)
data = work
136 call disp%show(
"call setFFTI(factor, coef, data, work, inwork)")
137 call setFFTI(factor, coef, data, work, inwork)
138 call disp%show(
"if (inwork) data = work")
139 if (inwork)
data = work
147 real(RKG),
allocatable :: data(:), coef(:), work(:)
149 call disp%show(
"data = [real(RKG) :: 1., 2., 3., 4., 5., 6.5]")
150 data = [
real(RKG) ::
1.,
2.,
3.,
4.,
5.,
6.5]
151 call disp%show(
"if (allocated(coef)) deallocate(coef); allocate(coef, mold = data)")
152 if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
153 call disp%show(
"if (allocated(work)) deallocate(work); allocate(work, mold = data)")
154 if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
155 call disp%show(
"factor = getfactorFFT(data, coef)")
156 factor
= getfactorFFT(data, coef)
161 call disp%show(
"call setFFTF(factor, coef, data, work, inwork)")
162 call setFFTF(factor, coef, data, work, inwork)
163 call disp%show(
"if (inwork) data = work")
164 if (inwork)
data = work
168 call disp%show(
"call setFFTI(factor, coef, data, work, inwork)")
169 call setFFTI(factor, coef, data, work, inwork)
170 call disp%show(
"if (inwork) data = work")
171 if (inwork)
data = work
179 real(RKG),
allocatable :: data(:), coef(:), work(:)
181 call disp%show(
"data = [real(RKG) :: 1., 2., 3., 4., 5., 6.5]")
182 data = [
real(RKG) ::
1.,
2.,
3.,
4.,
5.,
6.5]
183 call disp%show(
"if (allocated(coef)) deallocate(coef); allocate(coef, mold = data)")
184 if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
185 call disp%show(
"if (allocated(work)) deallocate(work); allocate(work, mold = data)")
186 if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
187 call disp%show(
"factor = getfactorFFT(data, coef)")
188 factor
= getfactorFFT(data, coef)
193 call disp%show(
"call setFFTF(factor, coef, data, work, inwork)")
194 call setFFTF(factor, coef, data, work, inwork)
195 call disp%show(
"if (inwork) data = work")
196 if (inwork)
data = work
200 call disp%show(
"call setFFTI(factor, coef, data, work, inwork)")
201 call setFFTI(factor, coef, data, work, inwork)
202 call disp%show(
"if (inwork) data = work")
203 if (inwork)
data = work
Allocate or resize (shrink or expand) an input allocatable scalar string or array of rank 1....
Return the Forward Fourier Transform (or equivalently, the Fourier coefficients) of a periodic sequen...
This is a generic method of the derived type display_type with pass attribute.
This is a generic method of the derived type display_type with pass attribute.
This module contains procedures and generic interfaces for resizing allocatable arrays of various typ...
This module contains classes and procedures for input/output (IO) or generic display operations on st...
type(display_type) disp
This is a scalar module variable an object of type display_type for general display.
This module defines the relevant Fortran kind type-parameters frequently used in the ParaMonte librar...
integer, parameter LK
The default logical kind in the ParaMonte library: kind(.true.) in Fortran, kind(....
integer, parameter CKH
The scalar integer constant of intrinsic default kind, representing the highest-precision complex kin...
integer, parameter CKS
The single-precision complex kind in Fortran mode. On most platforms, this is a 32-bit real kind.
integer, parameter IK
The default integer kind in the ParaMonte library: int32 in Fortran, c_int32_t in C-Fortran Interoper...
integer, parameter CKD
The double precision complex kind in Fortran mode. On most platforms, this is a 64-bit real kind.
integer, parameter RKD
The double precision real kind in Fortran mode. On most platforms, this is an 64-bit real kind.
integer, parameter SK
The default character kind in the ParaMonte library: kind("a") in Fortran, c_char in C-Fortran Intero...
integer, parameter RKH
The scalar integer constant of intrinsic default kind, representing the highest-precision real kind t...
integer, parameter RKS
The single-precision real kind in Fortran mode. On most platforms, this is an 32-bit real kind.
Generate and return an object of type display_type.
2data = [
complex(CKG) :: (
1.,
-6.), (
2.,
-5.), (
3.,
-4.), (
4.,
-3.), (
5.,
-2.), (
6.,
-1.)]
3if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
4if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
5factor
= getfactorFFT(data, coef)
7(
+1.00000000,
+0.00000000), (
+0.499999970,
+0.866025448), (
-0.500000060,
+0.866025388), (
+1.00000000,
+0.00000000), (
+1.00000000,
+0.00000000), (
-0.499999911,
-0.866025448)
10call setFFTF(factor, coef, data, work, inwork)
11if (inwork)
data = work
13(
+21.0000000,
-21.0000000), (
-8.19615173,
+2.19615269), (
-4.73205090,
-1.26794922), (
-3.00000000,
-2.99999976), (
-1.26794922,
-4.73205090), (
+2.19615221,
-8.19615269)
15call setFFTI(factor, coef, data, work, inwork)
16if (inwork)
data = work
18(
+1.00000000,
-6.00000000), (
+2.00000000,
-5.00000000), (
+3.00000000,
-4.00000000), (
+4.00000000,
-3.00000000), (
+5.00000000,
-2.00000024), (
+6.00000000,
-1.00000000)
21data = [
complex(CKG) :: (
1.,
-6.), (
2.,
-5.), (
3.,
-4.), (
4.,
-3.), (
5.,
-2.), (
6.,
-1.)]
22if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
23if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
24factor
= getfactorFFT(data, coef)
26(
+1.0000000000000000,
+0.0000000000000000), (
+0.50000000000000011,
+0.86602540378443860), (
-0.49999999999999978,
+0.86602540378443871), (
+1.0000000000000000,
+0.0000000000000000), (
+1.0000000000000000,
+0.0000000000000000), (
-0.50000000000000044,
-0.86602540378443837)
29call setFFTF(factor, coef, data, work, inwork)
30if (inwork)
data = work
32(
+21.000000000000000,
-21.000000000000000), (
-8.1961524227066320,
+2.1961524227066302), (
-4.7320508075688767,
-1.2679491924311228), (
-2.9999999999999991,
-3.0000000000000000), (
-1.2679491924311228,
-4.7320508075688767), (
+2.1961524227066320,
-8.1961524227066302)
34call setFFTI(factor, coef, data, work, inwork)
35if (inwork)
data = work
37(
+1.0000000000000000,
-6.0000000000000000), (
+2.0000000000000000,
-4.9999999999999991), (
+3.0000000000000004,
-4.0000000000000000), (
+4.0000000000000000,
-3.0000000000000000), (
+4.9999999999999991,
-2.0000000000000000), (
+6.0000000000000000,
-1.0000000000000004)
40data = [
complex(CKG) :: (
1.,
-6.), (
2.,
-5.), (
3.,
-4.), (
4.,
-3.), (
5.,
-2.), (
6.,
-1.)]
41if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
42if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
43factor
= getfactorFFT(data, coef)
45(
+1.00000000000000000000000000000000000,
+0.00000000000000000000000000000000000), (
+0.499999999999999999999999999999999952,
+0.866025403784438646763723170752936161), (
-0.500000000000000000000000000000000096,
+0.866025403784438646763723170752936161), (
+1.00000000000000000000000000000000000,
+0.00000000000000000000000000000000000), (
+1.00000000000000000000000000000000000,
+0.00000000000000000000000000000000000), (
-0.499999999999999999999999999999999856,
-0.866025403784438646763723170752936257)
48call setFFTF(factor, coef, data, work, inwork)
49if (inwork)
data = work
51(
+21.0000000000000000000000000000000000,
-21.0000000000000000000000000000000000), (
-8.19615242270663188058233902451761697,
+2.19615242270663188058233902451761774), (
-4.73205080756887729352744634150587232,
-1.26794919243112270647255365849412768), (
-3.00000000000000000000000000000000077,
-3.00000000000000000000000000000000039), (
-1.26794919243112270647255365849412768,
-4.73205080756887729352744634150587232), (
+2.19615242270663188058233902451761774,
-8.19615242270663188058233902451761851)
53call setFFTI(factor, coef, data, work, inwork)
54if (inwork)
data = work
56(
+1.00000000000000000000000000000000000,
-6.00000000000000000000000000000000000), (
+2.00000000000000000000000000000000000,
-5.00000000000000000000000000000000000), (
+3.00000000000000000000000000000000000,
-4.00000000000000000000000000000000000), (
+4.00000000000000000000000000000000000,
-3.00000000000000000000000000000000000), (
+5.00000000000000000000000000000000000,
-2.00000000000000000000000000000000000), (
+6.00000000000000000000000000000000000,
-1.00000000000000000000000000000000000)
59data = [
real(RKG) ::
1.,
2.,
3.,
4.,
5.,
6.5]
60if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
61if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
62factor
= getfactorFFT(data, coef)
64+0.499999970,
+0.866025448,
+0.00000000,
+0.00000000,
+0.145802732E-18,
+0.378001102E-38
67call setFFTF(factor, coef, data, work, inwork)
68if (inwork)
data = work
70+21.5000000,
-2.75000000,
+5.62916517,
-3.25000000,
+2.16506338,
-3.50000000
72call setFFTI(factor, coef, data, work, inwork)
73if (inwork)
data = work
75+1.00000000,
+1.99999988,
+3.00000000,
+4.00000000,
+5.00000000,
+6.50000000
78data = [
real(RKG) ::
1.,
2.,
3.,
4.,
5.,
6.5]
79if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
80if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
81factor
= getfactorFFT(data, coef)
83+0.50000000000000011,
+0.86602540378443860,
-512.00012254714966,
-32.000007688999176,
-2.0000023888424039,
-0.78125018844730221E-2
86call setFFTF(factor, coef, data, work, inwork)
87if (inwork)
data = work
89+21.500000000000000,
-2.7500000000000009,
+5.6291651245988508,
-3.2499999999999991,
+2.1650635094610968,
-3.5000000000000000
91call setFFTI(factor, coef, data, work, inwork)
92if (inwork)
data = work
94+1.0000000000000000,
+1.9999999999999996,
+3.0000000000000000,
+4.0000000000000000,
+5.0000000000000000,
+6.5000000000000000
97data = [
real(RKG) ::
1.,
2.,
3.,
4.,
5.,
6.5]
98if (
allocated(coef))
deallocate(coef);
allocate(coef,
mold = data)
99if (
allocated(work))
deallocate(work);
allocate(work,
mold = data)
100factor
= getfactorFFT(data, coef)
102+0.499999999999999999999999999999999952,
+0.866025403784438646763723170752936161,
-131072.000000000116472165245795622493,
-512.000000000000455191440096314181574,
-2.00000000000000177852524374522147316,
-0.305175781250002439851934786410429801E-4
105call setFFTF(factor, coef, data, work, inwork)
106if (inwork)
data = work
108+21.5000000000000000000000000000000000,
-2.75000000000000000000000000000000000,
+5.62916512459885120396420060989408543,
-3.25000000000000000000000000000000000,
+2.16506350946109661690930792688234040,
-3.50000000000000000000000000000000000
110call setFFTI(factor, coef, data, work, inwork)
111if (inwork)
data = work
113+1.00000000000000000000000000000000000,
+2.00000000000000000000000000000000000,
+3.00000000000000000000000000000000000,
+4.00000000000000000000000000000000000,
+5.00000000000000000000000000000000000,
+6.50000000000000000000000000000000000