-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
2183: Remove dependence on OrdinaryDiffEq r=charleskawczynski a=charleskawczynski This PR removes the dependence on OrdinaryDiffEq 💥. I did have to add a function for computing indefinite integrals: ```julia function column_indefinite_integral!( f::Function, ᶠintegral::Fields.ColumnField, x₀, ᶜzfield::Fields.ColumnField, average = (a, b) -> (a + b) / 2, ) ``` (I guess we could maybe get rid of `ᶜzfield` and extract it from `ᶠintegral`?) Which returns a new `ColumnInterpolatableField` object: ```julia struct ColumnInterpolatableField{F, D} f::F data::D function ColumnInterpolatableField(f::Fields.ColumnField) zdata = vec(parent(Fields.Fields.coordinate_field(f).z)) fdata = vec(parent(f)) `@assert` length(zdata) == length(fdata) data = Dierckx.Spline1D(zdata, fdata; k = 1) return new{typeof(f), typeof(data)}(f, data) end end (f::ColumnInterpolatableField)(z) = Spaces.undertype(axes(f.f))(f.data(z)) ``` Ultimately, this replaces `ODE.solve`, which itself is not an issue, but `ODE.Tsit5()` (and every other ODE algo implementation) is (reasonably) not in SciMLBase. Co-authored-by: Charles Kawczynski <kawczynski.charles@gmail.com>
- Loading branch information
Showing
10 changed files
with
99 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
import OrdinaryDiffEq as ODE | ||
import Logging | ||
import TerminalLoggers | ||
import LinearAlgebra as LA | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import ClimaTimeSteppers as CTS | ||
import OrdinaryDiffEq as ODE | ||
|
||
struct EfficiencyStats{TS <: Tuple, WT} | ||
tspan::TS | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters