Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move ARS docs to new types, delete old imp #127

Merged
merged 1 commit into from
Dec 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion docs/src/algorithms.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,12 @@ ARK548L2SA2KennedyCarpenter

### ARS

TODO: add `ARS111`, `ARS121`, and `ARS343` docs.
```@docs
ARS111
ARS121
ARS232
ARS343
```

## Multirate

Expand Down
1 change: 0 additions & 1 deletion src/ClimaTimeSteppers.jl
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ include("solvers/multirate.jl")
include("solvers/lsrk.jl")
include("solvers/ssprk.jl")
include("solvers/ark.jl")
# include("solvers/ars.jl") # previous implementations of ARS schemes
include("solvers/mis.jl")
include("solvers/wickerskamarock.jl")
include("solvers/rosenbrock.jl")
Expand Down
299 changes: 0 additions & 299 deletions src/solvers/ars.jl

This file was deleted.

32 changes: 31 additions & 1 deletion src/solvers/imex_ark_tableaus.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export AbstractIMEXARKTableau
export ARS111, ARS121, ARS122, ARS233, ARS232, ARS222, ARS443
export ARS111, ARS121, ARS122, ARS233, ARS232, ARS222, ARS343, ARS443
export IMKG232a, IMKG232b, IMKG242a, IMKG242b, IMKG252a, IMKG252b
export IMKG253a, IMKG253b, IMKG254a, IMKG254b, IMKG254c, IMKG342a, IMKG343a
export DBM453, HOMMEM1
Expand Down Expand Up @@ -48,13 +48,31 @@ end
# the number of explicit stages, and p is the order of accuracy

# This algorithm is equivalent to OrdinaryDiffEq.IMEXEuler.

"""
ARS111

The Forward-Backward (1,1,1) implicit-explicit (IMEX) Runge-Kutta scheme of
[ARS1997](@cite), section 2.1.

This is equivalent to the `OrdinaryDiffEq.IMEXEuler` algorithm.
"""
struct ARS111 <: AbstractIMEXARKTableau end

function tableau(::ARS111)
IMEXARKTableau(; a_exp = @SArray([0 0; 1 0]), a_imp = @SArray([0 0; 0 1]))
end

"""
ARS121

The Forward-Backward (1,2,1) implicit-explicit (IMEX) Runge-Kutta scheme of
[ARS1997](@cite), section 2.2.

This is equivalent to the `OrdinaryDiffEq.IMEXEulerARK` algorithm.
"""
struct ARS121 <: AbstractIMEXARKTableau end

function tableau(::ARS121)
IMEXARKTableau(; a_exp = @SArray([0 0; 1 0]), b_exp = @SArray([0, 1]), a_imp = @SArray([0 0; 0 1]))
end
Expand Down Expand Up @@ -88,6 +106,12 @@ function tableau(::ARS233)
)
end

"""
ARS232

The Forward-Backward (2,3,2) implicit-explicit (IMEX) Runge-Kutta scheme of
[ARS1997](@cite), section 2.5.
"""
struct ARS232 <: AbstractIMEXARKTableau end
function tableau(::ARS232)
γ = 1 - √2 / 2
Expand Down Expand Up @@ -122,6 +146,12 @@ function tableau(::ARS222)
]))
end

"""
ARS343

The L-stable, third-order (3,4,3) implicit-explicit (IMEX) Runge-Kutta scheme of
[ARS1997](@cite), section 2.7.
"""
struct ARS343 <: AbstractIMEXARKTableau end
function tableau(::ARS343)
γ = 0.4358665215084590
Expand Down