Skip to content

Commit 0af84d1

Browse files
authored
add a few docstrings (#613)
for `(l|r)(diffbc|dirichlet|neumann)`, `ivp`, `bvp` and `periodic`
1 parent b7e3535 commit 0af84d1

File tree

1 file changed

+53
-0
lines changed

1 file changed

+53
-0
lines changed

src/Operators/functionals/Evaluation.jl

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -134,19 +134,72 @@ end
134134

135135

136136
evaluate(d::Domain,x) = Evaluation(d,x)
137+
138+
"""
139+
ldiffbc(d::Domain, k)
140+
141+
The boundary condition of the `k`-th order derivative on the left endpoint of `d`. See also [`rdiffbc`](@ref), [`ldirichlet`](@ref) and [`lneumann`](@ref).
142+
"""
137143
ldiffbc(d,k) = Evaluation(d,leftendpoint,k)
144+
145+
"""
146+
rdiffbc(d::Domain, k)
147+
148+
The boundary condition of the `k`-th order derivative on the right endpoint of `d`. See also [`ldiffbc`](@ref), [`rdirichlet`](@ref) and [`rneumann`](@ref).
149+
"""
138150
rdiffbc(d,k) = Evaluation(d,rightendpoint,k)
139151

152+
"""
153+
ldirichlet(d::Domain) = ldiffbc(d, 0)
154+
155+
The dirichlet boundary condition on the left endpoint of `d`. See also [`rdirichlet`](@ref) and [`ldiffbc`](@ref).
156+
"""
140157
ldirichlet(d) = ldiffbc(d,0)
158+
159+
"""
160+
rdirichlet(d::Domain) = rdiffbc(d, 0)
161+
162+
The dirichlet boundary condition on the right endpoint of `d`. See also [`ldirichlet`](@ref) and [`rdiffbc`](@ref).
163+
"""
141164
rdirichlet(d) = rdiffbc(d,0)
165+
166+
"""
167+
lneumann(d::Domain) = ldiffbc(d, 1)
168+
169+
The neumann boundary condition on the left endpoint of `d`. See also [`rneumann`](@ref) and [`ldiffbc`](@ref).
170+
"""
142171
lneumann(d) = ldiffbc(d,1)
172+
173+
"""
174+
rneumann(d::Domain) = rdiffbc(d, 1)
175+
176+
The neumann boundary condition on the right endpoint of `d`. See also [`lneumann`](@ref) and [`rdiffbc`](@ref).
177+
"""
143178
rneumann(d) = rdiffbc(d,1)
144179

180+
"""
181+
ivp(d::Domain, k) = [ldiffbc(d,i) for i=0:k-1]
182+
ivp(d) = ivp(d,2)
145183
184+
The conditions for the `k`-th order initial value problem. See also [`ldiffbc`](@ref), [`bvp`](@ref) and [`periodic`](@ref).
185+
"""
146186
ivp(d,k) = [ldiffbc(d,i) for i=0:k-1]
187+
188+
"""
189+
bvp(d::Domain, k) = vcat([ldiffbc(d,i) for i=0:div(k,2)-1],
190+
[rdiffbc(d,i) for i=0:div(k,2)-1])
191+
bvp(d) = bvp(d,2)
192+
193+
The conditions for the `k`-th order boundary value problem. See also [`ldiffbc`](@ref), [`rdiffbc`](@ref), [`ivp`](@ref) and [`periodic`](@ref).
194+
"""
147195
bvp(d,k) = vcat([ldiffbc(d,i) for i=0:div(k,2)-1],
148196
[rdiffbc(d,i) for i=0:div(k,2)-1])
149197

198+
"""
199+
periodic(d::Domain,k) = [ldiffbc(d,i) - rdiffbc(d,i) for i=0:k]
200+
201+
The conditions for the `k`-th order periodic problem. See also [`ldiffbc`](@ref), [`rdiffbc`](@ref), [`ivp`](@ref) and [`bvp`](@ref)
202+
"""
150203
periodic(d,k) = [ldiffbc(d,i) - rdiffbc(d,i) for i=0:k]
151204

152205
# shorthand for second order

0 commit comments

Comments
 (0)