You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 19, 2023. It is now read-only.
Creates a periodic boundary condition, where the lower index end of some u is extended with the upper index end and vice versa.
24
-
It is not recommended to concretize this BC type in to a BandedMatrix, since the vast majority of bands will be all 0s. SpatseMatrix concretization is recommended.
25
-
"""
26
17
struct PeriodicBC{T} <:AtomicBC{T}
27
18
PeriodicBC(T::Type) =new{T}()
28
19
end
29
-
30
-
"""
31
-
q = RobinBC(left_coefficients, right_coefficients, dx::T, approximation_order) where T # When this BC extends a dimension with a uniform step size
32
-
33
-
q = RobinBC(left_coefficients, right_coefficients, dx::Vector{T}, approximation_order) where T # When this BC extends a dimension with a non uniform step size. dx should be the vector of step sizes for the whole dimension
The variables in l are [αl, βl, γl], and correspond to a BC of the form αl*u(0) + βl*u'(0) = γl imposed on the lower index boundary.
38
-
The variables in r are [αl, βl, γl], and correspond to an analogous boundary on the higher index end.
39
-
Implements a robin boundary condition operator Q that acts on a vector to give an extended vector as a result
40
-
Referring to (https://github.com/JuliaDiffEq/DiffEqOperators.jl/files/3267835/ghost_node.pdf)
41
-
Write vector b̄₁ as a vertical concatenation with b0 and the rest of the elements of b̄ ₁, denoted b̄`₁, the same with ū into u0 and ū`. b̄`₁ = b̄`_2 = fill(β/Δx, length(stencil)-1)
42
-
Pull out the product of u0 and b0 from the dot product. The stencil used to approximate u` is denoted s. b0 = α+(β/Δx)*s[1]
43
-
Rearrange terms to find a general formula for u0:= -b̄`₁̇⋅ū`/b0 + γ/b0, which is dependent on ū` the robin coefficients and Δx.
44
-
The non identity part of Qa is qa:= -b`₁/b0 = -β.*s[2:end]/(α+β*s[1]/Δx). The constant part is Qb = γ/(α+β*s[1]/Δx)
45
-
do the same at the other boundary (amounts to a flip of s[2:end], with the other set of boundary coeffs)
0 commit comments