Giter Club home page Giter Club logo

boundaryvaluediffeq.jl's Introduction

BoundaryValueDiffEq

Join the chat at https://julialang.zulipchat.com #sciml-bridged Global Docs

Build Status codecov Package Downloads Aqua QA

ColPrac: Contributor's Guide on Collaborative Practices for Community Packages SciML Code Style

BoundaryValueDiffEq.jl is a component package in the DifferentialEquations ecosystem. It holds the boundary value problem solvers and utilities. While completely independent and usable on its own, users interested in using this functionality should check out DifferentialEquations.jl.

API

BoundaryValueDiffEq.jl is part of the JuliaDiffEq common interface, but can be used independently of DifferentialEquations.jl. The only requirement is that the user passes a BoundaryValueDiffEq.jl algorithm to solve. For example, we can solve the BVP tutorial from the documentation using the MIRK4() algorithm:

using BoundaryValueDiffEq
tspan = (0.0, pi / 2)
function simplependulum!(du, u, p, t)
    θ = u[1]
    dθ = u[2]
    du[1] = dθ
    du[2] = -9.81 * sin(θ)
end
function bc!(residual, u, p, t)
    residual[1] = u[end ÷ 2][1] + pi / 2
    residual[2] = u[end][1] - pi / 2
end
prob = BVProblem(simplependulum!, bc!, [pi / 2, pi / 2], tspan)
sol = solve(prob, MIRK4(), dt = 0.05)

Available Solvers

For the list of available solvers, please refer to the DifferentialEquations.jl BVP Solvers page. For options for the solve command, see the common solver options page.

Controlling Precompilation

Precompilation can be controlled via Preferences.jl

  • PrecompileMIRK -- Precompile the MIRK2 - MIRK6 algorithms (default: true).
  • PrecompileShooting -- Precompile the single shooting algorithms (default: false). This is triggered when OrdinaryDiffEq is loaded.
  • PrecompileMultipleShooting -- Precompile the multiple shooting algorithms (default: false). This is triggered when OrdinaryDiffEq is loaded.
  • PrecompileMIRKNLLS -- Precompile the MIRK2 - MIRK6 algorithms for under-determined and over-determined BVPs (default: false).
  • PrecompileShootingNLLS -- Precompile the single shooting algorithms for under-determined and over-determined BVPs (default: false). This is triggered when OrdinaryDiffEq is loaded.
  • PrecompileMultipleShootingNLLS -- Precompile the multiple shooting algorithms for under-determined and over-determined BVPs (default: false ). This is triggered when OrdinaryDiffEq is loaded.

To set these preferences before loading the package, do the following (replacing PrecompileShooting with the preference you want to set, or pass in multiple pairs to set them together):

using Preferences, UUIDs
Preferences.set_preferences!(UUID("764a87c0-6b3e-53db-9096-fe964310641d"),
    "PrecompileShooting" => false)

Running Benchmarks Locally

We include a small set of benchmarks in the benchmarks folder. These are not extensive and mainly used to track regressions during development. For more extensive benchmarks, see the SciMLBenchmarks repository.

To run benchmarks locally install AirspeedVelocity.jl and run the following command in the package directory:

benchpkg BoundaryValueDiffEq --rev="master,<git sha for your commit>" --bench-on="master"

boundaryvaluediffeq.jl's People

Contributors

chrisrackauckas avatar avik-pal avatar yingboma avatar erikqqy avatar dependabot[bot] avatar github-actions[bot] avatar christopher-dg avatar dlfivefifty avatar femtocleaner[bot] avatar scottpjones avatar ranocha avatar thazhemadam avatar aayushsabharwal avatar asinghvi17 avatar devmotion avatar juliatagbot avatar kanav99 avatar lilithhafner avatar magerton avatar matfi avatar oscardssmith avatar dextorious avatar jamesjscully avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.