Flow123d
3.9.0-9663d1cde
|
Enum type UpdateFlags indicates which quantities are to be recomputed on each finite element cell. More...
Go to the source code of this file.
Enumerations | |
enum | UpdateFlags { update_default = 0, update_values = 0x0001, update_gradients = 0x0002, update_quadrature_points = 0x0004, update_JxW_values = 0x0008, update_normal_vectors = 0x0010, update_jacobians = 0x0020, update_inverse_jacobians = 0x0040, update_volume_elements = 0x0080, update_side_JxW_values = 0x0100 } |
Enum type UpdateFlags indicates which quantities are to be recomputed on each finite element cell. More... | |
Functions | |
template<class STREAM > | |
STREAM & | operator<< (STREAM &s, UpdateFlags u) |
UpdateFlags | operator| (UpdateFlags f1, UpdateFlags f2) |
UpdateFlags & | operator|= (UpdateFlags &f1, UpdateFlags f2) |
UpdateFlags | operator& (UpdateFlags f1, UpdateFlags f2) |
UpdateFlags & | operator&= (UpdateFlags &f1, UpdateFlags f2) |
Enum type UpdateFlags indicates which quantities are to be recomputed on each finite element cell.
* Copyright (C) 2015 Technical University of Liberec. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 3 as published by the Free Software Foundation. (http://www.gnu.org/licenses/gpl-3.0.en.html)
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
Definition in file update_flags.hh.
enum UpdateFlags |
Enum type UpdateFlags indicates which quantities are to be recomputed on each finite element cell.
Selecting these flags in a restrictive way is crucial for the efficiency of FEValues::reinit() and FESideValues::reinit(). Therefore, only the flags actually needed should be selected. It is the responsibility of the involved Mapping and FiniteElement to add additional flags according to their own requirements.
By default, all flags are off, i.e. no reinitialization will be done.
You can select more than one flag by concatenation using the bitwise or operator|(UpdateFlags,UpdateFlags).
When given a set of UpdateFlags flags
, the FEValues object must determine, which values will have to be computed once only for the reference cell and which values will have to be updated for each cell. Here, it is important to note that in many cases, the FiniteElement will require additional updates from the Mapping. To this end, the following auxiliary functions have been implemented:
FiniteElement::update_each() determine the values required by the FiniteElement on each cell. The same function exists in Mapping.
FEValuesBase::update_each() is used to compute the union of all values to be computed ever. It does this by first adding to the flags set by the user all flags added by the FiniteElement. This new set of flags is then given to the Mapping and all flags required there are added.
This union of all flags is given to Mapping::fill_fe_values() and FiniteElement::fill_fe_values(), where the quantities indicated by the flags are computed.
The flags finally stored in FEValues then are the union of all the flags required by the user, by FiniteElement and by Mapping, for computation once or on each cell.
Definition at line 67 of file update_flags.hh.
|
inline |
Global operator which returns an object in which all bits are set which are set in the first as well as the second argument. This operator exists since if it did not then the result of the bit-and operator &
would be an integer which would in turn trigger a compiler warning when we tried to assign it to an object of type UpdateFlags.
Definition at line 227 of file update_flags.hh.
|
inline |
Global operator which clears all the bits in the first argument if they are not also set in the second argument.
Definition at line 243 of file update_flags.hh.
|
inline |
Output operator which outputs update flags as a set of or'd text values.
Definition at line 164 of file update_flags.hh.
|
inline |
Global operator which returns an object in which all bits are set which are either set in the first or the second argument. This operator exists since if it did not then the result of the bit-or operator |
would be an integer which would in turn trigger a compiler warning when we tried to assign it to an object of type UpdateFlags.
Definition at line 190 of file update_flags.hh.
|
inline |
Global operator which sets the bits from the second argument also in the first one.
Definition at line 208 of file update_flags.hh.