Skip to content

Commit

Permalink
Docs being able to deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
ErikQQY committed Jan 8, 2025
1 parent 5efb718 commit e9d1e87
Show file tree
Hide file tree
Showing 15 changed files with 84 additions and 36 deletions.
2 changes: 2 additions & 0 deletions docs/Project.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
[deps]
ADTypes = "47edcb42-4c32-4615-8424-f2b9edc5f35b"
BoundaryValueDiffEq = "764a87c0-6b3e-53db-9096-fe964310641d"
BoundaryValueDiffEqAscher = "7227322d-7511-4e07-9247-ad6ff830280e"
BoundaryValueDiffEqCore = "56b672f2-a5fe-4263-ab2d-da677488eb3a"
BoundaryValueDiffEqFIRK = "85d9eb09-370e-4000-bb32-543851f73618"
Expand All @@ -19,6 +20,7 @@ SimpleBoundaryValueDiffEq = "be0294bd-f90f-4760-ac4e-3421ce2b2da0"

[compat]
ADTypes = "1.9"
BoundaryValueDiffEq = "5.12.0"
BoundaryValueDiffEqCore = "1.1"
BoundaryValueDiffEqFIRK = "1.1"
BoundaryValueDiffEqMIRK = "1.1"
Expand Down
6 changes: 6 additions & 0 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ cp(joinpath(@__DIR__, "Project.toml"),

include("pages.jl")

bib = CitationBibliography(joinpath(@__DIR__, "src", "refs.bib"))

interlinks = InterLinks("ADTypes" => "https://sciml.github.io/ADTypes.jl/stable/",
"LineSearch" => "https://sciml.github.io/LineSearch.jl/dev/")

makedocs(; sitename = "BoundaryValueDiffEq.jl",
authors = "SciML",
modules = [BoundaryValueDiffEqCore, BoundaryValueDiffEqMIRK, BoundaryValueDiffEqFIRK,
Expand All @@ -25,6 +30,7 @@ makedocs(; sitename = "BoundaryValueDiffEq.jl",
doctest = false,
checkdocs = :exports,
warnonly = [:missing_docs],
plugins = [bib, interlinks],
format = Documenter.HTML(assets = ["assets/favicon.ico"],
canonical = "https://docs.sciml.ai/BoundaryValueDiffEq/stable/"),
pages)
37 changes: 37 additions & 0 deletions docs/src/assets/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[deps]
ADTypes = "47edcb42-4c32-4615-8424-f2b9edc5f35b"
BoundaryValueDiffEq = "764a87c0-6b3e-53db-9096-fe964310641d"
BoundaryValueDiffEqAscher = "7227322d-7511-4e07-9247-ad6ff830280e"
BoundaryValueDiffEqCore = "56b672f2-a5fe-4263-ab2d-da677488eb3a"
BoundaryValueDiffEqFIRK = "85d9eb09-370e-4000-bb32-543851f73618"
BoundaryValueDiffEqMIRK = "1a22d4ce-7765-49ea-b6f2-13c8438986a6"
BoundaryValueDiffEqMIRKN = "9255f1d6-53bf-473e-b6bd-23f1ff009da4"
BoundaryValueDiffEqShooting = "ed55bfe0-3725-4db6-871e-a1dc9f42a757"
DiffEqBase = "2b5f629d-d688-5b77-993f-72d75c75574e"
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
DocumenterCitations = "daee34ce-89f3-4625-b898-19384cb65244"
DocumenterInterLinks = "d12716ef-a0f6-4df4-a9f1-a5a34e75c656"
LineSearch = "87fe0de2-c867-4266-b59a-2f0a94fc965b"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
LinearSolve = "7ed4a6bd-45f5-4d41-b270-4a48e9bafcae"
OrdinaryDiffEq = "1dea7af3-3e70-54e6-95c3-0bf5283fa5ed"
SciMLBase = "0bca4576-84f4-4d90-8ffe-ffa030f20462"
SimpleBoundaryValueDiffEq = "be0294bd-f90f-4760-ac4e-3421ce2b2da0"

[compat]
ADTypes = "1.9"
BoundaryValueDiffEq = "5.12.0"
BoundaryValueDiffEqCore = "1.1"
BoundaryValueDiffEqFIRK = "1.1"
BoundaryValueDiffEqMIRK = "1.1"
BoundaryValueDiffEqShooting = "1.1"
DiffEqBase = "6.158.3"
Documenter = "1"
DocumenterCitations = "1"
DocumenterInterLinks = "1.0.0"
LineSearch = "0.1.4"
LinearAlgebra = "1.10"
LinearSolve = "2.36.2"
OrdinaryDiffEq = "6.90.1"
SciMLBase = "2.60.0"
SimpleBoundaryValueDiffEq = "1.1.0"
2 changes: 1 addition & 1 deletion docs/src/basics/autodiff.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# # Automatic Differentiation Backends
# Automatic Differentiation Backends

!!! note

Expand Down
4 changes: 1 addition & 3 deletions docs/src/basics/bvp_functions.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,5 @@ The SciML ecosystem provides an extensive interface for declaring extra function

```@docs
SciMLBase.BVPFunction
SciMLBase.TwoPointBVPFunction
SciMLBase.SecondOrderBVPFunction
SciMLBase.TwoPointSecondOrderBVPFunction
SciMLBase.DynamicalBVPFunction
```
4 changes: 0 additions & 4 deletions docs/src/basics/solve.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
# [Common Solver Options (Solve Keyword Arguments)](@id solver_options)

```@docs
solve(::AbstractBVProblem, args...; kwargs...)
```

## Iteration Controls

- `maxiters::Int`: The maximum number of iterations to perform. Defaults to `1000`.
Expand Down
4 changes: 2 additions & 2 deletions docs/src/devdocs/internal_interfaces.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

## Solvers

```@docs
BoundaryValueDiffEqCore.BuondaryValueDiffEqAlgorithm
```julia
BoundaryValueDiffEqCore.BoundaryValueDiffEqAlgorithm
```
8 changes: 8 additions & 0 deletions docs/src/refs.bib
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
@article{Muir2001MonoImplicitRM,
title={Mono-Implicit Runge-Kutta-Nystr{\"o}m Methods with Application to Boundary Value Ordinary Differential Equations},
author={Paul H. Muir and Mark F. Adams},
journal={BIT Numerical Mathematics},
year={2001},
volume={41},
pages={776-799},
}
14 changes: 7 additions & 7 deletions docs/src/solvers/ascher.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# [BoundaryValueDiffEqAscher.jl](@id ascher)
# [BoundaryValueDiffEqAscher](@id ascher)

Gauss Legendre collocation methods with Ascher's error control adaptivity and mesh refinement routines. To be able to access the solvers in BoundaryValueDiffEqFIRK, you must first install them use the Julia package manager:

Expand All @@ -15,12 +15,12 @@ solve(prob::TwoPointBVProblem, alg; kwargs...)
## Full List of Methods

- `Ascher1`: 1 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher2`: 1 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher3`: 1 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher4`: 1 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher5`: 1 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher6`: 1 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher7`: 1 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher2`: 2 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher3`: 3 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher4`: 4 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher5`: 5 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher6`: 6 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.
- `Ascher7`: 7 stage Gauss Legendre collocation method with Ascher's error control adaptivity and mesh refinement.

## Detailed Solvers Explanation

Expand Down
2 changes: 1 addition & 1 deletion docs/src/solvers/firk.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# [BoundaryValueDiffEqFIRK.jl](@id firk)
# [BoundaryValueDiffEqFIRK](@id firk)

Fully Implicit Runge Kutta(FIRK) Methods. To be able to access the solvers in BoundaryValueDiffEqFIRK, you must first install them use the Julia package manager:

Expand Down
2 changes: 1 addition & 1 deletion docs/src/solvers/mirk.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# [BoundaryValueDiffEqMIRK.jl](@id mirk)
# [BoundaryValueDiffEqMIRK](@id mirk)

Monotonic Implicit Runge Kutta(MIRK) Methods. To only use the MIRK methods form BoundaryVaueDiffEq.jl, you need to install them use the Julia package manager:

Expand Down
5 changes: 3 additions & 2 deletions docs/src/solvers/mirkn.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# [BoundaryValueDiffEqMIRKN.jl](@id mirkn)
# [BoundaryValueDiffEqMIRKN](@id mirkn)

Monotonic Implicit Runge Kutta Nyström(MIRKN) Methods. To only use the MIRKN methods form BoundaryVaueDiffEq.jl, you need to install them use the Julia package manager:

Expand All @@ -12,8 +12,9 @@ solve(prob::SecondOrderBVProblem, alg; kwargs...)
solve(prob::TwoPointSecondOrderBVProblem, alg; kwargs...)
```

!!! note "MIRKN don't have defect control adaptivity"
!!! note "Defect control adaptivity"

MIRKN don't have defect control adaptivity

## Full List of Methods

Expand Down
2 changes: 1 addition & 1 deletion docs/src/solvers/shooting.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# [BoundaryValueDiffEqShooting.jl](@id shooting)
# [BoundaryValueDiffEqShooting](@id shooting)

Single shooting method and multiple shooting method. To only use the Shooting methods form BoundaryVaueDiffEq.jl, you need to install them use the Julia package manager:

Expand Down
4 changes: 2 additions & 2 deletions docs/src/solvers/simple_solvers.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# [SimpleBoundaryValueDiffEq.jl](@id simpleboundaryvaluediffeq)
# [SimpleBoundaryValueDiffEq](@id simpleboundaryvaluediffeq)

## Full List of Methods

```@docs
```julia
SimpleBoundaryValueDiffEq.SimpleMIRK4
SimpleBoundaryValueDiffEq.SimpleMIRK5
SimpleBoundaryValueDiffEq.SimpleMIRK6
Expand Down
24 changes: 12 additions & 12 deletions docs/src/tutorials/getting_started.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@

When ordinary differential equations has constraints over the time span, we should model the ordinary differential equations as a boundary value problem which has the form of:

$$
```math
\frac{du}{dt}=f(u, p, t)\\
g(u(a),u(b))=0
$$
```

BoundaryValueDiffEq.jl address three types of BVProblem.

1. General boundary value problems:, i.e., differential equations with constraints applied over the time span. This is a system where you would like to obtain the solution of the differential equations and make sure the solution satisfy the boundary conditions simutanously.
2. General second order boundary value problems, i.e., differential equations with constraints for both solution and derivative of solution applied over time span. This is a system where you would like to obtain the solution of the differential equations and make sure the solution satisfy the boundary conditions simutanously.
3. Boundary value differential algebraic equations, i.e., apart from constraints applied over the time span, BVDAE has additional algebraic equations which state the algebraic relationship of different states in BVDAE.

## Linear two-point boundary value problem
## Solving Linear two-point boundary value problem

Consider the linear two-point boundary value problem from [standard BVP test problem](https://archimede.uniba.it/%7Ebvpsolvers/testsetbvpsolvers/?page_id=29).

Expand Down Expand Up @@ -58,20 +58,20 @@ sol = solve(prob, MIRK4(), dt = 0.01)

Consirder the test problem from example problems in MIRKN paper.

$$
```math
\begin{cases}
y_1'(x)= y_2(x),\\
\epsilon y_2'(x)=-y_1(x)y_2'(x)- y_3(x)y_3'(x),\\
\epsilon y_3'(x)=y_1'(x) y_3(x)- y_1(x) y_3 '(x)
\end{cases}
$$
```

with initial conditions:

$$
```math
y_1(0) = y_1'(0)= y_1(1)=y_1'(1)=0,y_3(0)=
-1, y_3(1)=1
$$
```

```julia
function f!(ddu, du, u, p, t)
Expand All @@ -98,20 +98,20 @@ sol = solve(prob, MIRKN4(), dt = 0.01)

Consider the nonlinear semi-explicit DAE of index at most 2

$$
```math
\begin{cases}
x_1'=(\epsilon+x_2-p_2(t))y+p_1'(t) \\
x_2'=p_2'(t) \\
x_3'=y \\
0=(x_1-p_1(t))(y-e^t)
\end{cases}
$$
```

with boundary conditions

$$
```math
x_1(0)=0,x_3(0)=1,x_2(1)=\sin(1)
$$
```

```julia
function f!(du, u, p, t)
Expand All @@ -121,7 +121,7 @@ function f!(du, u, p, t)
du[3] = u[4]
du[4] = (u[1] - sin(t)) * (u[4] - e^t)
end
function bc1!(res, u, p, t)
function bc!(res, u, p, t)
res[1] = u[1]
res[2] = u[3] - 1
res[3] = u[2] - sin(1.0)
Expand Down

0 comments on commit e9d1e87

Please sign in to comment.