Skip to content

Commit

Permalink
Remove onboundary from Neumann BC introduction (#473)
Browse files Browse the repository at this point in the history
onboundary is just an optimization, which only works if
grid.boundary_matrix is correctly initialized. This patch removes the
mention of onboundary from the Neumann BC introduction.
  • Loading branch information
fredrikekre committed Aug 29, 2022
1 parent 6b049b2 commit b9998a0
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions docs/src/manual/boundary_conditions.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ to evaluate the boundary integral:

```julia
for face in 1:nfaces(cell)
if onboundary(cell, face) && (cellid(cell), face) getfaceset(grid, "Neumann Boundary")
if (cellid(cell), face) getfaceset(grid, "Neumann Boundary")
reinit!(facevalues, cell, face)
for q_point in 1:getnquadpoints(facevalues)
= getdetJdV(facevalues, q_point)
Expand All @@ -116,9 +116,8 @@ for face in 1:nfaces(cell)
end
```

We start by looping over all the faces of the cell, next we have to check if
this particular face is located on the boundary, and then also check that the
face is located on our face-set called `"Neumann Boundary"`. If we have determined
We start by looping over all the faces of the cell, next we check if this particular face is
located on our faceset of interest called `"Neumann Boundary"`. If we have determined
that the current face is indeed on the boundary and in our faceset, then we
reinitialize `facevalues` for this face, using [`reinit!`](@ref). When `reinit!`ing
`facevalues` we also need to give the face number in addition to the cell.
Expand Down

0 comments on commit b9998a0

Please sign in to comment.