Skip to content

Latest commit

 

History

372 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SteadyStateDiffEq.jl

Join the chat at https://julialang.zulipchat.com #sciml-bridged Build Status Coverage Status codecov.io

SteadyStateDiffEq.jl is a component package in the DifferentialEquations ecosystem. It holds the steady state solvers for differential equations. While completely independent and usable on its own, users interested in using this functionality should check out DifferentialEquations.jl.

Usage

SteadyStateDiffEq.jl provides three algorithms for finding steady states:

SSRootfind - Nonlinear Solver Approach

Use a nonlinear solver to directly find the steady state:

using SciMLBase: SteadyStateProblem, solve
using SteadyStateDiffEq
using NonlinearSolve

function f!(du, u, p, t)
    du[1] = 2 - 2u[1]
    du[2] = u[1] - 4u[2]
end

u0 = zeros(2)
prob = SteadyStateProblem(f!, u0)
sol = solve(prob, SSRootfind())

DynamicSS - Time Evolution Approach

Evolve the system forward in time until derivatives approach zero:

using SciMLBase: SteadyStateProblem, solve
using SteadyStateDiffEq
using Sundials: CVODE_BDF

prob = SteadyStateProblem((u, p, t) -> 1 .- u, [0.0])
sol = solve(prob, DynamicSS(CVODE_BDF()); dt = 1.0)

SICNM - Semi-Implicit Continuous Newton Method

Integrate the continuous Newton flow with a mass-matrix solver:

using SciMLBase: SteadyStateProblem, solve
using SteadyStateDiffEq
using OrdinaryDiffEqRosenbrock: Rodas3d

prob = SteadyStateProblem((u, p, t) -> 1 .- u, [0.0])
sol = solve(prob, SICNM(Rodas3d()))

For more details, see the SciML documentation.

Breaking Changes in v2

  1. NLsolve.jl dependency has been dropped. SSRootfind requires a nonlinear solver to be specified.
  2. DynamicSS no longer stores abstol and reltol. To use separate tolerances for the odesolve and the termination, specify odesolve_kwargs in solve.
  3. The deprecated termination conditions are dropped, see NonlinearSolve.jl Docs for details on this.

About

Solvers for steady states in scientific machine learning (SciML)

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

30 stars

Watchers

4 watching

Forks

Releases

Sponsor this project

Packages

Used by

Contributors

Languages