Reference documentation for deal.II version Git b8493d4166 20190519 17:48:39 +0200

Classes  
struct  Scalar 
struct  SymmetricTensor 
struct  Tensor 
struct  Vector 
A namespace in which we declare "extractors", i.e. classes that when used as subscripts in operator[] expressions on FEValues, FEFaceValues, and FESubfaceValues objects extract certain components of a vectorvalued element. The result of applying an extractor to these objects is an object with corresponding type from the namespace FEValuesViews. There are extractors for single scalar components, vector components consisting of dim
elements, and second order symmetric tensors consisting of (dim*dim + dim)/2
components, as well as second order nonsymmetric tensors.
One can think of extractors as the equivalent of an index, or an index range. In the case of scalar extractors (i.e., the FEValuesExtractors::Scalar class), creating an object like (see step20 for this use)
can be thought of as creating a single index with value dim
. By itself, an index does not know what it is an index to, so it takes the equivalent of an array to extract anything. Consequently, assume that there is a finite element with at least dim+1
vector components (as indeed there is in step20), and an FEValues object that operates on it, then writing
results in an object that represents the shape functions of only the dim
th component of the overall element. In the example, these would be the values of the pressure shape functions, or more precisely: the (scalar) pressure values of all shape functions (even for shape functions that are not associated with the pressure, but for example the velocity). In the example above, the result of using operator[]
on the fe_values
object as shown is of type FEValuesViews::Scalar.
Likewise, when using
then the object so created can be thought of as an index range, starting at zero and extending exactly dim
components on. In Matlab notation, one could write this as 0:dim1
. Then, writing
will result in an object that represents the values of a subset of exactly dim
vector components of the overall finite element, in much the same way as writing array(3:7)
in Matlab would return an array of length 5 that has been extracted from the original array by looking at indices 3 through 7 (inclusive).
See the description of the Handling vector valued problems module for examples how to use the features of this namespace.