Skip to content

Commit

Permalink
doc: fix some doc build warnings (Ferrite-FEM#887)
Browse files Browse the repository at this point in the history
  • Loading branch information
fredrikekre authored Feb 29, 2024
1 parent 8e92196 commit f6a7d3d
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/src/devdocs/FEValues.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Custom FEValues, `fe_v::AbstractValues`, should normally implement the [`reinit!
* [`getnbasefunctions`](@ref)
* [`spatial_coordinate`](@ref), requires
* [`geometric_value`](@ref)
* [`getngeobasefunctions`](@ref)
* `getngeobasefunctions`
* [`getnquadpoints`](@ref)


Expand Down
3 changes: 3 additions & 0 deletions docs/src/reference/fevalues.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,14 @@ shape_value(::Ferrite.AbstractValues, ::Int, ::Int)
shape_gradient(::Ferrite.AbstractValues, ::Int, ::Int)
shape_symmetric_gradient
shape_divergence
shape_curl
geometric_value
function_value
function_gradient
function_symmetric_gradient
function_divergence
function_curl
spatial_coordinate
```

Expand Down
2 changes: 1 addition & 1 deletion docs/src/topics/FEValues.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# [FEValues](@id fevalues_topicguide)
A key type of object in `Ferrite.jl` is the so-called `FEValues`, where the most common ones are `CellValues` and `FaceValues`. These objects are used inside the element routines and are used to query the integration weights, shape function values and gradients, and much more; see [`CellValues`](@ref) and [`FaceValues`](@ref). For these values to be correct, it is necessary to reinitialize these for the current cell by using the [`reinit!`](@ref) function. This function maps the values from the reference cell to the actual cell, a process described in detail below, see [Mapping of finite elements](@ref mapping-theory). After that, we show an implementation of a [`SimpleCellValues`](@ref SimpleCellValues) type to illustrate how `CellValues` work for the most standard case, excluding the generalizations and optimization that complicates the actual code.
A key type of object in `Ferrite.jl` is the so-called `FEValues`, where the most common ones are `CellValues` and `FaceValues`. These objects are used inside the element routines and are used to query the integration weights, shape function values and gradients, and much more; see [`CellValues`](@ref) and [`FaceValues`](@ref). For these values to be correct, it is necessary to reinitialize these for the current cell by using the [`reinit!`](@ref) function. This function maps the values from the reference cell to the actual cell, a process described in detail below, see [Mapping of finite elements](@ref mapping_theory). After that, we show an implementation of a [`SimpleCellValues`](@ref SimpleCellValues) type to illustrate how `CellValues` work for the most standard case, excluding the generalizations and optimization that complicates the actual code.

## [Mapping of finite elements](@id mapping_theory)
The shape functions and gradients stored in an `FEValues` object, are reinitialized for each cell by calling the `reinit!` function.
Expand Down
6 changes: 6 additions & 0 deletions src/FEValues/common_values.jl
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,12 @@ end
divergence_from_gradient(grad::Vec) = sum(grad)
divergence_from_gradient(grad::Tensor{2}) = tr(grad)

"""
shape_curl(fe_v::AbstractValues, q_point::Int, base_function::Int)
Return the curl of shape function `base_function` evaluated in
quadrature point `q_point`.
"""
function shape_curl(cv::AbstractValues, q_point::Int, base_func::Int)
return curl_from_gradient(shape_gradient(cv, q_point, base_func))
end
Expand Down

0 comments on commit f6a7d3d

Please sign in to comment.