Skip to content

Commit 09b8a63

Browse files
authored
Merge branch 'master' into pochhammervec
2 parents bb7f1be + 490ce9a commit 09b8a63

File tree

10 files changed

+107
-51
lines changed

10 files changed

+107
-51
lines changed

.github/workflows/CIWindows.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: CI Windows
2+
on:
3+
- push
4+
- pull_request
5+
jobs:
6+
testwindows:
7+
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
8+
runs-on: ${{ matrix.os }}
9+
strategy:
10+
matrix:
11+
version:
12+
- '1'
13+
os:
14+
- windows-latest
15+
arch:
16+
- x86
17+
- x64
18+
steps:
19+
- uses: actions/checkout@v3
20+
- uses: julia-actions/setup-julia@v1
21+
with:
22+
version: ${{ matrix.version }}
23+
arch: ${{ matrix.arch }}
24+
show-versioninfo: true
25+
- uses: actions/cache@v3
26+
env:
27+
cache-name: cache-artifacts
28+
with:
29+
path: ~/.julia/artifacts
30+
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
31+
restore-keys: |
32+
${{ runner.os }}-test-${{ env.cache-name }}-
33+
${{ runner.os }}-test-
34+
${{ runner.os }}-
35+
- uses: julia-actions/julia-buildpkg@latest
36+
- uses: julia-actions/julia-runtest@latest
37+
- uses: julia-actions/julia-processcoverage@v1
38+
- uses: codecov/codecov-action@v3
39+
with:
40+
file: lcov.info

.github/workflows/TagBot.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
name: TagBot
22
on:
3-
schedule:
4-
- cron: 0 * * * *
3+
issue_comment:
4+
types:
5+
- created
6+
workflow_dispatch:
57
jobs:
68
TagBot:
9+
if: github.event_name == 'workflow_dispatch' || github.actor == 'JuliaTagBot'
710
runs-on: ubuntu-latest
811
steps:
912
- uses: JuliaRegistries/TagBot@v1
1013
with:
1114
token: ${{ secrets.GITHUB_TOKEN }}
15+
ssh: ${{ secrets.DOCUMENTER_KEY }}

.github/workflows/ci.yml

Lines changed: 3 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -11,25 +11,23 @@ jobs:
1111
version:
1212
- '1.7'
1313
- '1'
14-
- '^1.9.0-0'
1514
os:
1615
- ubuntu-latest
1716
- macOS-latest
18-
- windows-latest
1917
arch:
2018
- x86
2119
- x64
2220
exclude:
2321
- os: macOS-latest
2422
arch: x86
2523
steps:
26-
- uses: actions/checkout@v2
24+
- uses: actions/checkout@v3
2725
- uses: julia-actions/setup-julia@v1
2826
with:
2927
version: ${{ matrix.version }}
3028
arch: ${{ matrix.arch }}
3129
show-versioninfo: true
32-
- uses: actions/cache@v1
30+
- uses: actions/cache@v3
3331
env:
3432
cache-name: cache-artifacts
3533
with:
@@ -42,23 +40,6 @@ jobs:
4240
- uses: julia-actions/julia-buildpkg@latest
4341
- uses: julia-actions/julia-runtest@latest
4442
- uses: julia-actions/julia-processcoverage@v1
45-
- uses: codecov/codecov-action@v1
43+
- uses: codecov/codecov-action@v3
4644
with:
4745
file: lcov.info
48-
docs:
49-
name: Documentation
50-
runs-on: ubuntu-latest
51-
steps:
52-
- uses: actions/checkout@v2
53-
- uses: julia-actions/setup-julia@v1
54-
with:
55-
version: '1.7'
56-
- run: |
57-
julia --project=docs -e '
58-
using Pkg
59-
Pkg.develop(PackageSpec(path=pwd()))
60-
Pkg.instantiate()'
61-
- run: julia --project=docs docs/make.jl
62-
env:
63-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
64-
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}

.github/workflows/docs.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Documentation
2+
on:
3+
- push
4+
- pull_request
5+
jobs:
6+
docs:
7+
name: Documentation
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v3
11+
- uses: julia-actions/setup-julia@v1
12+
with:
13+
version: '1'
14+
- uses: julia-actions/julia-docdeploy@releases/v1
15+
env:
16+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
17+
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}

Project.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "FastTransforms"
22
uuid = "057dd010-8810-581a-b7be-e3fc3b93f78c"
3-
version = "0.15.4"
3+
version = "0.15.7"
44

55
[deps]
66
AbstractFFTs = "621f4979-c628-5d54-868e-fcf4e3e8185c"
@@ -18,7 +18,7 @@ ToeplitzMatrices = "c751599d-da0a-543b-9d20-d0a503d91d24"
1818

1919
[compat]
2020
AbstractFFTs = "1.0"
21-
FFTW = "1.6"
21+
FFTW = "1.7"
2222
FastGaussQuadrature = "0.4, 0.5"
2323
FastTransforms_jll = "0.6.2"
2424
FillArrays = "0.9, 0.10, 0.11, 0.12, 0.13, 1"

README.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -157,12 +157,14 @@ julia> @time norm(ipaduatransform(paduatransform(v)) - v)/norm(v)
157157

158158
```
159159

160-
# References:
160+
# References
161161

162-
[1] D. Ruiz—Antolín and A. Townsend. <a href="https://doi.org/10.1137/17M1134822">A nonuniform fast Fourier transform based on low rank approximation</a>, *SIAM J. Sci. Comput.*, **40**:A529–A547, 2018.
162+
[1] D. Ruiz—Antolín and A. Townsend, [A nonuniform fast Fourier transform based on low rank approximation](https://doi.org/10.1137/17M1134822), *SIAM J. Sci. Comput.*, **40**:A529–A547, 2018.
163163

164-
[2] S. Olver, R. M. Slevinsky, and A. Townsend. <a href="https://doi.org/10.1017/S0962492920000045">Fast algorithms using orthogonal polynomials</a>, *Acta Numerica*, **29**:573—699, 2020.
164+
[2] T. S. Gutleb, S. Olver and R. M. Slevinsky, [Polynomial and rational measure modifications of orthogonal polynomials via infinite-dimensional banded matrix factorizations](https://arxiv.org/abs/2302.08448), arXiv:2302.08448, 2023.
165165

166-
[3] R. M. Slevinsky. <a href="https://doi.org/10.1016/j.acha.2017.11.001">Fast and backward stable transforms between spherical harmonic expansions and bivariate Fourier series</a>, *Appl. Comput. Harmon. Anal.*, **47**:585—606, 2019.
166+
[3] S. Olver, R. M. Slevinsky, and A. Townsend, [Fast algorithms using orthogonal polynomials](https://doi.org/10.1017/S0962492920000045), *Acta Numerica*, **29**:573—699, 2020.
167167

168-
[4] R. M. Slevinsky, <a href="https://arxiv.org/abs/1711.07866">Conquering the pre-computation in two-dimensional harmonic polynomial transforms</a>, arXiv:1711.07866, 2017.
168+
[4] R. M. Slevinsky, [Fast and backward stable transforms between spherical harmonic expansions and bivariate Fourier series](https://doi.org/10.1016/j.acha.2017.11.001), *Appl. Comput. Harmon. Anal.*, **47**:585—606, 2019.
169+
170+
[5] R. M. Slevinsky, [Conquering the pre-computation in two-dimensional harmonic polynomial transforms](https://arxiv.org/abs/1711.07866), arXiv:1711.07866, 2017.

docs/src/dev.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Development Documentation
22

3-
The core of `FastTransforms.jl` is developed in parallel with the [C library](https://github.com/MikaelSlevinsky/FastTransforms) of the same name. Julia and C interoperability is enhanced by the [BinaryBuilder](https://github.com/JuliaPackaging/BinaryBuilder.jl) infrastructure, which provides the user a safe and seamless experience using a package in a different language.
3+
The core of [`FastTransforms.jl`](https://github.com/JuliaApproximation/FastTransforms.jl) is developed in parallel with the [C library](https://github.com/MikaelSlevinsky/FastTransforms) of the same name. Julia and C interoperability is enhanced by the [BinaryBuilder](https://github.com/JuliaPackaging/BinaryBuilder.jl) infrastructure, which provides the user a safe and seamless experience using a package in a different language.
44

55
## Why two packages?
66

docs/src/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
## Introduction
44

5-
`FastTransforms.jl` allows the user to conveniently work with orthogonal polynomials with degrees well into the millions.
5+
[`FastTransforms.jl`](https://github.com/JuliaApproximation/FastTransforms.jl) allows the user to conveniently work with orthogonal polynomials with degrees well into the millions.
66

77
This package provides a Julia wrapper for the [C library](https://github.com/MikaelSlevinsky/FastTransforms) of the same name. Additionally, all three types of nonuniform fast Fourier transforms available, as well as the Padua transform.
88

src/chebyshevtransform.jl

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,9 @@ ChebyshevTransformPlan{T,kind}(plan::FFTW.r2rFFTWPlan{T,K,inplace,N,R}) where {T
1919
ChebyshevTransformPlan{T,kind,K,inplace,N,R}(plan)
2020

2121
# jump through some hoops to make inferrable
22-
@inline kindtuple(N) = NTuple{N,Int32}
23-
@inline kindtuple(N,region...) = Vector{Int32}
2422
function plan_chebyshevtransform!(x::AbstractArray{T,N}, ::Val{1}, dims...; kws...) where {T<:fftwNumber,N}
2523
if isempty(x)
26-
ChebyshevTransformPlan{T,1,kindtuple(N,dims...),true,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
24+
ChebyshevTransformPlan{T,1,Vector{Int32},true,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
2725
else
2826
ChebyshevTransformPlan{T,1}(FFTW.plan_r2r!(x, FIRSTKIND, dims...; kws...))
2927
end
@@ -36,7 +34,7 @@ end
3634

3735
function plan_chebyshevtransform(x::AbstractArray{T,N}, ::Val{1}, dims...; kws...) where {T<:fftwNumber,N}
3836
if isempty(x)
39-
ChebyshevTransformPlan{T,1,kindtuple(N,dims...),false,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
37+
ChebyshevTransformPlan{T,1,Vector{Int32},false,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
4038
else
4139
ChebyshevTransformPlan{T,1}(FFTW.plan_r2r(x, FIRSTKIND, dims...; kws...))
4240
end
@@ -250,7 +248,7 @@ inv(P::IChebyshevTransformPlan{T,1}) where {T} = ChebyshevTransformPlan{T,1}(inv
250248

251249
function plan_ichebyshevtransform!(x::AbstractArray{T,N}, ::Val{1}, dims...; kws...) where {T<:fftwNumber,N}
252250
if isempty(x)
253-
IChebyshevTransformPlan{T,1,kindtuple(N,dims...),true,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
251+
IChebyshevTransformPlan{T,1,Vector{Int32},true,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
254252
else
255253
IChebyshevTransformPlan{T,1}(FFTW.plan_r2r!(x, IFIRSTKIND, dims...; kws...))
256254
end
@@ -262,7 +260,7 @@ end
262260

263261
function plan_ichebyshevtransform(x::AbstractArray{T,N}, ::Val{1}, dims...; kws...) where {T<:fftwNumber,N}
264262
if isempty(x)
265-
IChebyshevTransformPlan{T,1,kindtuple(N,dims...),false,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
263+
IChebyshevTransformPlan{T,1,Vector{Int32},false,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
266264
else
267265
IChebyshevTransformPlan{T,1}(FFTW.plan_r2r(x, IFIRSTKIND, dims...; kws...))
268266
end
@@ -390,7 +388,7 @@ ChebyshevUTransformPlan{T,kind}(plan::FFTW.r2rFFTWPlan{T,K,inplace,N,R}) where {
390388

391389
function plan_chebyshevutransform!(x::AbstractArray{T,N}, ::Val{1}, dims...; kws...) where {T<:fftwNumber,N}
392390
if isempty(x)
393-
ChebyshevUTransformPlan{T,1,kindtuple(N,dims...),true,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
391+
ChebyshevUTransformPlan{T,1,Vector{Int32},true,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
394392
else
395393
ChebyshevUTransformPlan{T,1}(FFTW.plan_r2r!(x, UFIRSTKIND, dims...; kws...))
396394
end
@@ -402,7 +400,7 @@ end
402400

403401
function plan_chebyshevutransform(x::AbstractArray{T,N}, ::Val{1}, dims...; kws...) where {T<:fftwNumber,N}
404402
if isempty(x)
405-
ChebyshevUTransformPlan{T,1,kindtuple(N,dims...),false,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
403+
ChebyshevUTransformPlan{T,1,Vector{Int32},false,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
406404
else
407405
ChebyshevUTransformPlan{T,1}(FFTW.plan_r2r(x, UFIRSTKIND, dims...; kws...))
408406
end
@@ -511,7 +509,7 @@ IChebyshevUTransformPlan{T,kind}(F::FFTW.r2rFFTWPlan{T,K,inplace,N,R}) where {T,
511509

512510
function plan_ichebyshevutransform!(x::AbstractArray{T,N}, ::Val{1}, dims...; kws...) where {T<:fftwNumber,N}
513511
if isempty(x)
514-
IChebyshevUTransformPlan{T,1,kindtuple(N,dims...),true,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
512+
IChebyshevUTransformPlan{T,1,Vector{Int32},true,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
515513
else
516514
IChebyshevUTransformPlan{T,1}(FFTW.plan_r2r!(x, IUFIRSTKIND, dims...; kws...))
517515
end
@@ -523,7 +521,7 @@ end
523521

524522
function plan_ichebyshevutransform(x::AbstractArray{T,N}, ::Val{1}, dims...; kws...) where {T<:fftwNumber,N}
525523
if isempty(x)
526-
IChebyshevUTransformPlan{T,1,kindtuple(N,dims...),false,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
524+
IChebyshevUTransformPlan{T,1,Vector{Int32},false,N,isempty(dims) ? NTuple{N,Int} : typeof(dims[1])}()
527525
else
528526
IChebyshevUTransformPlan{T,1}(FFTW.plan_r2r(x, IUFIRSTKIND, dims...; kws...))
529527
end

test/chebyshevtests.jl

Lines changed: 22 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,17 @@ using FastTransforms, Test
6969
@test g fcopy
7070
@test_throws ArgumentError Pi * T[1,2]
7171

72-
@test chebyshevtransform(T[1]) == T[1]
73-
@test ichebyshevtransform(T[1]) == T[1]
74-
@test chebyshevtransform(T[]) == T[]
75-
@test ichebyshevtransform(T[]) == T[]
72+
v = T[1]
73+
@test chebyshevtransform(v) == v
74+
@test ichebyshevtransform(v) == v
75+
@test chebyshevtransform!(v) === v
76+
@test ichebyshevtransform!(v) === v
77+
78+
v = T[]
79+
@test chebyshevtransform(v) == v
80+
@test ichebyshevtransform(v) == v
81+
@test chebyshevtransform!(v) === v
82+
@test ichebyshevtransform!(v) === v
7683
end
7784
end
7885
@testset "Chebyshev second kind points <-> first kind coefficients" begin
@@ -192,10 +199,17 @@ using FastTransforms, Test
192199
@test g fcopy
193200
@test_throws ArgumentError Pi * T[1,2]
194201

195-
@test chebyshevutransform(T[1]) == T[1]
196-
@test ichebyshevutransform(T[1]) == T[1]
197-
@test chebyshevutransform(T[]) == T[]
198-
@test ichebyshevutransform(T[]) == T[]
202+
v = T[1]
203+
@test chebyshevutransform(v) == v
204+
@test ichebyshevutransform(v) == v
205+
@test chebyshevutransform!(v) === v
206+
@test ichebyshevutransform!(v) === v
207+
208+
v = T[]
209+
@test chebyshevutransform(v) == v
210+
@test ichebyshevutransform(v) == v
211+
@test chebyshevutransform!(v) === v
212+
@test ichebyshevutransform!(v) === v
199213
end
200214
end
201215
@testset "Chebyshev second kind points <-> second kind coefficients" begin

0 commit comments

Comments
 (0)