Skip to content

Commit

Permalink
Add doc for option all in add*set! (#527)
Browse files Browse the repository at this point in the history
* Add doc for option all in add*set!

* Remove redundant default note
  • Loading branch information
KnutAM committed Jan 7, 2023
1 parent 0861ac3 commit a57b1c6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Grid/grid.jl
Original file line number Diff line number Diff line change
Expand Up @@ -561,7 +561,9 @@ _warn_emptyset(set, name) = length(set) == 0 && @warn("no entities added to the
Adds a cellset to the grid with key `name`.
Cellsets are typically used to define subdomains of the problem, e.g. two materials in the computational domain.
The `MixedDofHandler` can construct different fields which live not on the whole domain, but rather on a cellset.
The `MixedDofHandler` can construct different fields which live not on the whole domain, but rather on a cellset.
`all=true` implies that `f(x)` must return `true` for all nodal coordinates `x` in the cell if the cell
should be added to the set, otherwise it suffices that `f(x)` returns `true` for one node.
```julia
addcellset!(grid, "left", Set((1,3))) #add cells with id 1 and 3 to cellset left
Expand Down Expand Up @@ -600,6 +602,8 @@ end
Adds a faceset to the grid with key `name`.
A faceset maps a `String` key to a `Set` of tuples corresponding to `(global_cell_id, local_face_id)`.
Facesets are used to initialize `Dirichlet` structs, that are needed to specify the boundary for the `ConstraintHandler`.
`all=true` implies that `f(x)` must return `true` for all nodal coordinates `x` on the face if the face
should be added to the set, otherwise it suffices that `f(x)` returns `true` for one node.
```julia
addfaceset!(gird, "right", Set(((2,2),(4,2))) #see grid manual example for reference
Expand Down

0 comments on commit a57b1c6

Please sign in to comment.