@@ -12,7 +12,7 @@ mutable struct TestPlan{T,N,inplace} <: Plan{T}
12
12
return new {T,N,inplace} (region, sz)
13
13
end
14
14
end
15
- TestPlan {T} (region, sz) where {T} = TestPlan {T,false } (region, sz)
15
+ TestPlan {T} (region, sz) where {T} = TestPlan {T,0 } (region, sz)
16
16
17
17
mutable struct InverseTestPlan{T,N,inplace} <: Plan{T}
18
18
region
@@ -22,7 +22,7 @@ mutable struct InverseTestPlan{T,N,inplace} <: Plan{T}
22
22
return new {T,N,inplace} (region, sz)
23
23
end
24
24
end
25
- InverseTestPlan {T} (region, sz) where {T} = InverseTestPlan {T,false } (region, sz)
25
+ InverseTestPlan {T} (region, sz) where {T} = InverseTestPlan {T,0 } (region, sz)
26
26
27
27
Base. size (p:: TestPlan ) = p. sz
28
28
Base. ndims (:: TestPlan{T,N} ) where {T,N} = N
@@ -37,10 +37,10 @@ function AbstractFFTs.plan_bfft(x::AbstractArray{T}, region; kwargs...) where {T
37
37
end
38
38
39
39
function AbstractFFTs. plan_fft! (x:: AbstractArray{T} , region; kwargs... ) where {T}
40
- return TestPlan {T,true } (region, size (x))
40
+ return TestPlan {T,1 } (region, size (x))
41
41
end
42
42
function AbstractFFTs. plan_bfft! (x:: AbstractArray{T} , region; kwargs... ) where {T}
43
- return InverseTestPlan {T,true } (region, size (x))
43
+ return InverseTestPlan {T,1 } (region, size (x))
44
44
end
45
45
46
46
function AbstractFFTs. plan_inv (p:: TestPlan{T,N,inplace} ) where {T,N,inplace}
@@ -89,23 +89,23 @@ function dft!(
89
89
end
90
90
91
91
function mul! (
92
- y:: AbstractArray{<:Complex,N} , p:: TestPlan{T,N,false } , x:: AbstractArray{<:Union{Complex,Real},N}
92
+ y:: AbstractArray{<:Complex,N} , p:: TestPlan{T,N,0 } , x:: AbstractArray{<:Union{Complex,Real},N}
93
93
) where {T,N}
94
94
size (y) == size (p) == size (x) || throw (DimensionMismatch ())
95
95
dft! (y, x, p. region, - 1 )
96
96
end
97
97
function mul! (
98
- y:: AbstractArray{<:Complex,N} , p:: InverseTestPlan{T,N,false } , x:: AbstractArray{<:Union{Complex,Real},N}
98
+ y:: AbstractArray{<:Complex,N} , p:: InverseTestPlan{T,N,0 } , x:: AbstractArray{<:Union{Complex,Real},N}
99
99
) where {T,N}
100
100
size (y) == size (p) == size (x) || throw (DimensionMismatch ())
101
101
dft! (y, x, p. region, 1 )
102
102
end
103
103
104
- Base.:* (p:: TestPlan{T,N,false } , x:: AbstractArray ) where {T,N} = mul! (similar (x, complex (float (eltype (x)))), p, x)
105
- Base.:* (p:: InverseTestPlan{T,N,false } , x:: AbstractArray ) where {T,N} = mul! (similar (x, complex (float (eltype (x)))), p, x)
104
+ Base.:* (p:: TestPlan{T,N,0 } , x:: AbstractArray ) where {T,N} = mul! (similar (x, complex (float (eltype (x)))), p, x)
105
+ Base.:* (p:: InverseTestPlan{T,N,0 } , x:: AbstractArray ) where {T,N} = mul! (similar (x, complex (float (eltype (x)))), p, x)
106
106
107
- Base.:* (p:: TestPlan{T,N,true } , x:: AbstractArray ) where {T,N} = copy! (x, dft! (similar (x), x, p. region, - 1 ))
108
- Base.:* (p:: InverseTestPlan{T,N,true } , x:: AbstractArray ) where {T,N} = copy! (x, dft! (similar (x), x, p. region, 1 ))
107
+ Base.:* (p:: TestPlan{T,N,1 } , x:: AbstractArray ) where {T,N} = copy! (x, dft! (similar (x), x, p. region, - 1 ))
108
+ Base.:* (p:: InverseTestPlan{T,N,1 } , x:: AbstractArray ) where {T,N} = copy! (x, dft! (similar (x), x, p. region, 1 ))
109
109
110
110
mutable struct TestRPlan{T,N} <: Plan{T}
111
111
region
0 commit comments