
Public Member Functions | |
| MappingQ1 () | |
| virtual Point< dim > | transform_unit_to_real_cell (const typename Triangulation< dim >::cell_iterator &cell, const Point< dim > &p) const |
| virtual Point< dim > | transform_real_to_unit_cell (const typename Triangulation< dim >::cell_iterator &cell, const Point< dim > &p) const |
| virtual void | transform_covariant (const VectorSlice< const std::vector< Tensor< 1, dim > > > input, const unsigned int offset, VectorSlice< std::vector< Tensor< 1, dim > > > output, const typename Mapping< dim >::InternalDataBase &internal) const |
| virtual void | transform_covariant (const VectorSlice< const std::vector< Tensor< 2, dim > > > input, const unsigned int offset, VectorSlice< std::vector< Tensor< 2, dim > > > output, const typename Mapping< dim >::InternalDataBase &internal) const |
| virtual void | transform_contravariant (const VectorSlice< const std::vector< Tensor< 1, dim > > > input, const unsigned int offset, VectorSlice< std::vector< Tensor< 1, dim > > > output, const typename Mapping< dim >::InternalDataBase &internal) const |
| virtual void | transform_contravariant (const VectorSlice< const std::vector< Tensor< 2, dim > > > input, const unsigned int offset, VectorSlice< std::vector< Tensor< 2, dim > > > output, const typename Mapping< dim >::InternalDataBase &internal) const |
| virtual Mapping< dim > * | clone () const |
Protected Types | |
| typedef QProjector< dim > ::DataSetDescriptor | DataSetDescriptor |
Protected Member Functions | |
| virtual void | fill_fe_values (const typename Triangulation< dim >::cell_iterator &cell, const Quadrature< dim > &quadrature, typename Mapping< dim >::InternalDataBase &mapping_data, typename std::vector< Point< dim > > &quadrature_points, std::vector< double > &JxW_values, std::vector< Tensor< 2, dim > > &jacobians, std::vector< Tensor< 3, dim > > &jacobian_grads, std::vector< Tensor< 2, dim > > &inverse_jacobians) const |
| virtual void | fill_fe_face_values (const typename Triangulation< dim >::cell_iterator &cell, const unsigned int face_no, const Quadrature< dim-1 > &quadrature, typename Mapping< dim >::InternalDataBase &mapping_data, typename std::vector< Point< dim > > &quadrature_points, std::vector< double > &JxW_values, typename std::vector< Tensor< 1, dim > > &boundary_form, typename std::vector< Point< dim > > &normal_vectors, std::vector< double > &cell_JxW_values) const |
| virtual void | fill_fe_subface_values (const typename Triangulation< dim >::cell_iterator &cell, const unsigned int face_no, const unsigned int sub_no, const Quadrature< dim-1 > &quadrature, typename Mapping< dim >::InternalDataBase &mapping_data, typename std::vector< Point< dim > > &quadrature_points, std::vector< double > &JxW_values, typename std::vector< Tensor< 1, dim > > &boundary_form, typename std::vector< Point< dim > > &normal_vectors, std::vector< double > &cell_JxW_values) const |
| void | compute_shapes (const std::vector< Point< dim > > &unit_points, InternalData &data) const |
| void | compute_data (const UpdateFlags flags, const Quadrature< dim > &quadrature, const unsigned int n_orig_q_points, InternalData &data) const |
| void | compute_face_data (const UpdateFlags flags, const Quadrature< dim > &quadrature, const unsigned int n_orig_q_points, InternalData &data) const |
| void | compute_fill (const typename Triangulation< dim >::cell_iterator &cell, const unsigned int npts, const DataSetDescriptor data_set, InternalData &data, std::vector< Point< dim > > &quadrature_points) const |
| void | compute_fill_face (const typename Triangulation< dim >::cell_iterator &cell, const unsigned int face_no, const unsigned int subface_no, const unsigned int npts, const DataSetDescriptor data_set, const std::vector< double > &weights, InternalData &mapping_data, std::vector< Point< dim > > &quadrature_points, std::vector< double > &JxW_values, std::vector< Tensor< 1, dim > > &boundary_form, std::vector< Point< dim > > &normal_vectors, std::vector< double > &cell_JxW_values) const |
| virtual void | compute_shapes_virtual (const std::vector< Point< dim > > &unit_points, InternalData &data) const |
| Point< dim > | transform_unit_to_real_cell_internal (const InternalData &mdata) const |
| void | transform_real_to_unit_cell_internal (const typename Triangulation< dim >::cell_iterator &cell, const Point< dim > &p, InternalData &mdata, Point< dim > &p_unit) const |
Private Member Functions | |
| virtual UpdateFlags | update_once (const UpdateFlags flags) const |
| virtual UpdateFlags | update_each (const UpdateFlags flags) const |
| virtual Mapping< dim > ::InternalDataBase * | get_data (const UpdateFlags, const Quadrature< dim > &quadrature) const |
| virtual Mapping< dim > ::InternalDataBase * | get_face_data (const UpdateFlags flags, const Quadrature< dim-1 > &quadrature) const |
| virtual Mapping< dim > ::InternalDataBase * | get_subface_data (const UpdateFlags flags, const Quadrature< dim-1 > &quadrature) const |
| virtual void | compute_mapping_support_points (const typename Triangulation< dim >::cell_iterator &cell, std::vector< Point< dim > > &a) const |
Static Private Attributes | |
| static const unsigned int | n_shape_functions = GeometryInfo<dim>::vertices_per_cell |
Classes | |
| class | InternalData |
This function maps the unit cell to a general grid cell with straight lines in
dimensions (remark that in 3D the surfaces may be curved, even if the edges are not). This is the well-known mapping for polyhedral domains.
Shape function for this mapping are the same as for the finite element FE_Q of order 1. Therefore, coupling these two yields an isoparametric element.
typedef QProjector<dim>::DataSetDescriptor MappingQ1< dim >::DataSetDescriptor [protected] |
Declare a convenience typedef for the class that describes offsets into quadrature formulas projected onto faces and subfaces.
| virtual Point<dim> MappingQ1< dim >::transform_unit_to_real_cell | ( | const typename Triangulation< dim >::cell_iterator & | cell, | |
| const Point< dim > & | p | |||
| ) | const [virtual] |
Transforms the point p on the unit cell to the point p_real on the real cell cell and returns p_real.
Implements Mapping< dim >.
Reimplemented in MappingQ< dim >.
| virtual Point<dim> MappingQ1< dim >::transform_real_to_unit_cell | ( | const typename Triangulation< dim >::cell_iterator & | cell, | |
| const Point< dim > & | p | |||
| ) | const [virtual] |
Transforms the point p on the real cell to the point p_unit on the unit cell cell and returns p_unit.
Uses Newton iteration and the transform_unit_to_real_cell function.
Implements Mapping< dim >.
Reimplemented in MappingQ< dim >.
| virtual void MappingQ1< dim >::transform_covariant | ( | const VectorSlice< const std::vector< Tensor< 1, dim > > > | input, | |
| const unsigned int | offset, | |||
| VectorSlice< std::vector< Tensor< 1, dim > > > | output, | |||
| const typename Mapping< dim >::InternalDataBase & | internal | |||
| ) | const [virtual] |
Reimplemented in MappingQ< dim >.
| virtual void MappingQ1< dim >::transform_covariant | ( | const VectorSlice< const std::vector< Tensor< 2, dim > > > | input, | |
| const unsigned int | offset, | |||
| VectorSlice< std::vector< Tensor< 2, dim > > > | output, | |||
| const typename Mapping< dim >::InternalDataBase & | internal | |||
| ) | const [virtual] |
Reimplemented in MappingQ< dim >.
| virtual void MappingQ1< dim >::transform_contravariant | ( | const VectorSlice< const std::vector< Tensor< 1, dim > > > | input, | |
| const unsigned int | offset, | |||
| VectorSlice< std::vector< Tensor< 1, dim > > > | output, | |||
| const typename Mapping< dim >::InternalDataBase & | internal | |||
| ) | const [virtual] |
Transform a field of contravariant vectors. The contravariant transformation multiplies a vector from the left with the Jacobian matrix of the transformation from unit to real space cell.
The list of arguments is as follows: we transform as many elements in the input field, starting from offset, as there are elements in output. The input array may hold more elements than are needed (some finite element classes use this for a denser storage of data), but it needs to have at least output.size() elements starting with element offset.
Implements Mapping< dim >.
Reimplemented in MappingQ< dim >.
| virtual void MappingQ1< dim >::transform_contravariant | ( | const VectorSlice< const std::vector< Tensor< 2, dim > > > | intput, | |
| const unsigned int | offset, | |||
| VectorSlice< std::vector< Tensor< 2, dim > > > | output, | |||
| const typename Mapping< dim >::InternalDataBase & | internal | |||
| ) | const [virtual] |
Transform a set of matrices contravariantly, i.e. multiply each function in the input range by the inverse Jacobian matrices at the different quadrature points from the right. Note that here it is no more equivalent to multiplication with the transpose of the inverse matrices from the left, unless the matrices to be multiplied with are symmetric.
The same applies as to the function above regarding input and output arguments.
Implements Mapping< dim >.
Reimplemented in MappingQ< dim >.
Return a pointer to a copy of the present object. The caller of this copy then assumes ownership of it.
Implements Mapping< dim >.
Reimplemented in MappingC1< dim >, MappingQ< dim >, MappingQ1Eulerian< dim, EulerVectorType >, and MappingQEulerian< dim, EulerVectorType >.
| virtual void MappingQ1< dim >::fill_fe_values | ( | const typename Triangulation< dim >::cell_iterator & | cell, | |
| const Quadrature< dim > & | quadrature, | |||
| typename Mapping< dim >::InternalDataBase & | mapping_data, | |||
| typename std::vector< Point< dim > > & | quadrature_points, | |||
| std::vector< double > & | JxW_values, | |||
| std::vector< Tensor< 2, dim > > & | jacobians, | |||
| std::vector< Tensor< 3, dim > > & | jacobian_grads, | |||
| std::vector< Tensor< 2, dim > > & | inverse_jacobians | |||
| ) | const [protected, virtual] |
Implementation of the interface in Mapping.
Reimplemented in MappingQ< dim >.
| virtual void MappingQ1< dim >::fill_fe_face_values | ( | const typename Triangulation< dim >::cell_iterator & | cell, | |
| const unsigned int | face_no, | |||
| const Quadrature< dim-1 > & | quadrature, | |||
| typename Mapping< dim >::InternalDataBase & | mapping_data, | |||
| typename std::vector< Point< dim > > & | quadrature_points, | |||
| std::vector< double > & | JxW_values, | |||
| typename std::vector< Tensor< 1, dim > > & | boundary_form, | |||
| typename std::vector< Point< dim > > & | normal_vectors, | |||
| std::vector< double > & | cell_JxW_values | |||
| ) | const [protected, virtual] |
Implementation of the interface in Mapping.
Reimplemented in MappingQ< dim >.
| virtual void MappingQ1< dim >::fill_fe_subface_values | ( | const typename Triangulation< dim >::cell_iterator & | cell, | |
| const unsigned int | face_no, | |||
| const unsigned int | sub_no, | |||
| const Quadrature< dim-1 > & | quadrature, | |||
| typename Mapping< dim >::InternalDataBase & | mapping_data, | |||
| typename std::vector< Point< dim > > & | quadrature_points, | |||
| std::vector< double > & | JxW_values, | |||
| typename std::vector< Tensor< 1, dim > > & | boundary_form, | |||
| typename std::vector< Point< dim > > & | normal_vectors, | |||
| std::vector< double > & | cell_JxW_values | |||
| ) | const [protected, virtual] |
Implementation of the interface in Mapping.
Reimplemented in MappingQ< dim >.
| void MappingQ1< dim >::compute_shapes | ( | const std::vector< Point< dim > > & | unit_points, | |
| InternalData & | data | |||
| ) | const [protected] |
Compute shape values and/or derivatives.
Calls either the compute_shapes_virtual of this class or that of the derived class, depending on whether data.is_mapping_q1_data equals true or false.
| void MappingQ1< dim >::compute_data | ( | const UpdateFlags | flags, | |
| const Quadrature< dim > & | quadrature, | |||
| const unsigned int | n_orig_q_points, | |||
| InternalData & | data | |||
| ) | const [protected] |
Do the computations for the get_data functions. Here, the data vectors of InternalData are reinitialized to proper size and shape values are computed.
| void MappingQ1< dim >::compute_face_data | ( | const UpdateFlags | flags, | |
| const Quadrature< dim > & | quadrature, | |||
| const unsigned int | n_orig_q_points, | |||
| InternalData & | data | |||
| ) | const [protected] |
Do the computations for the get_face_data functions. Here, the data vectors of InternalData are reinitialized to proper size and shape values and derivatives are computed. Furthermore unit_tangential vectors of the face are computed.
| void MappingQ1< dim >::compute_fill | ( | const typename Triangulation< dim >::cell_iterator & | cell, | |
| const unsigned int | npts, | |||
| const DataSetDescriptor | data_set, | |||
| InternalData & | data, | |||
| std::vector< Point< dim > > & | quadrature_points | |||
| ) | const [protected] |
Do the computation for the fill_* functions.
| void MappingQ1< dim >::compute_fill_face | ( | const typename Triangulation< dim >::cell_iterator & | cell, | |
| const unsigned int | face_no, | |||
| const unsigned int | subface_no, | |||
| const unsigned int | npts, | |||
| const DataSetDescriptor | data_set, | |||
| const std::vector< double > & | weights, | |||
| InternalData & | mapping_data, | |||
| std::vector< Point< dim > > & | quadrature_points, | |||
| std::vector< double > & | JxW_values, | |||
| std::vector< Tensor< 1, dim > > & | boundary_form, | |||
| std::vector< Point< dim > > & | normal_vectors, | |||
| std::vector< double > & | cell_JxW_values | |||
| ) | const [protected] |
Do the computation for the fill_* functions.
| virtual void MappingQ1< dim >::compute_shapes_virtual | ( | const std::vector< Point< dim > > & | unit_points, | |
| InternalData & | data | |||
| ) | const [protected, virtual] |
Compute shape values and/or derivatives.
| Point<dim> MappingQ1< dim >::transform_unit_to_real_cell_internal | ( | const InternalData & | mdata | ) | const [protected] |
Transforms a point p on the unit cell to the point p_real on the real cell cell and returns p_real.
This function is called by transform_unit_to_real_cell and multiply (through the Newton iteration) by transform_real_to_unit_cell_internal.
Takes a reference to an InternalData that must already include the shape values at point p and the mapping support points of the cell.
This InternalData argument avoids multiple computations of the shape values at point p and especially multiple computations of the mapping support points.
| void MappingQ1< dim >::transform_real_to_unit_cell_internal | ( | const typename Triangulation< dim >::cell_iterator & | cell, | |
| const Point< dim > & | p, | |||
| InternalData & | mdata, | |||
| Point< dim > & | p_unit | |||
| ) | const [protected] |
Transforms the point p on the real cell to the point p_unit on the unit cell cell by a Newton iteration.
Takes a reference to an InternalData that is assumed to be previously created by the get_data function with UpdateFlags including update_transformation_values and update_transformation_gradients and a one point Quadrature including the given point p_unit. Hence this function assumes that mdata already includes the transformation shape values and gradients computed at p_unit.
These assumptions should be fulfilled by the calling function. That is up to now only the function transform_real_to_unit_cell and its overloaded versions. mdata will be changed by this function.
| virtual UpdateFlags MappingQ1< dim >::update_once | ( | const UpdateFlags | flags | ) | const [private, virtual] |
Implementation of the interface in Mapping.
Description of effects:
update_quadrature_points is required, the output will contain update_transformation_values. This computes the values of the transformation basis polynomials at the unit cell quadrature points. update_covariant_transformation, update_contravariant_transformation, update_JxW_values, update_boundary_forms, update_normal_vectors is required, the output will contain update_transformation_gradients to compute derivatives of the transformation basis polynomials. Implements Mapping< dim >.
| virtual UpdateFlags MappingQ1< dim >::update_each | ( | const UpdateFlags | flags | ) | const [private, virtual] |
Implementation of the interface in Mapping.
Description of effects if flags contains:
update_quadrature_points is copied to the output to compute the quadrature points on the real cell. update_JxW_values is copied and requires update_boundary_forms on faces. The latter, because the surface element is just the norm of the boundary form. update_normal_vectors is copied and requires update_boundary_forms. The latter, because the normal vector is the normalized boundary form. update_covariant_transformation is copied and requires update_contravariant_transformation, since it is computed as the inverse of the latter. update_JxW_values is copied and requires update_contravariant_transformation, since it is computed as one over determinant of the latter. update_boundary_forms is copied and requires update_contravariant_transformation, since the boundary form is computed as the contravariant image of the normal vector to the unit cell. Implements Mapping< dim >.
| virtual Mapping<dim>::InternalDataBase* MappingQ1< dim >::get_data | ( | const | UpdateFlags, | |
| const Quadrature< dim > & | quadrature | |||
| ) | const [private, virtual] |
Prepare internal data structures and fill in values independent of the cell.
Implements Mapping< dim >.
Reimplemented in MappingQ< dim >.
| virtual Mapping<dim>::InternalDataBase* MappingQ1< dim >::get_face_data | ( | const UpdateFlags | flags, | |
| const Quadrature< dim-1 > & | quadrature | |||
| ) | const [private, virtual] |
Prepare internal data structure for transformation of faces and fill in values independent of the cell.
Implements Mapping< dim >.
Reimplemented in MappingQ< dim >.
| virtual Mapping<dim>::InternalDataBase* MappingQ1< dim >::get_subface_data | ( | const UpdateFlags | flags, | |
| const Quadrature< dim-1 > & | quadrature | |||
| ) | const [private, virtual] |
Prepare internal data structure for transformation of children of faces and fill in values independent of the cell.
Implements Mapping< dim >.
Reimplemented in MappingQ< dim >.
| virtual void MappingQ1< dim >::compute_mapping_support_points | ( | const typename Triangulation< dim >::cell_iterator & | cell, | |
| std::vector< Point< dim > > & | a | |||
| ) | const [private, virtual] |
Computes the support points of the mapping. For MappingQ1 these are the vertices. However, other classes may override this function. In particular, the MappingQ1Eulerian class does exactly this by not computing the support points from the geometry of the current cell but instead evaluating an externally given displacement field in addition to the geometry of the cell.
Reimplemented in MappingQ< dim >, MappingQ1Eulerian< dim, EulerVectorType >, and MappingQEulerian< dim, EulerVectorType >.
const unsigned int MappingQ1< dim >::n_shape_functions = GeometryInfo<dim>::vertices_per_cell [static, private] |
Number of shape functions. Is simply the number of vertices per cell for the Q1 mapping.
Reimplemented in MappingQ< dim >.
documentation generated on Fri Nov 21 07:13:16 2008 by
doxygen
1.5.6