21 #ifndef fiber_surface_grad_3d_functor_hpp
22 #define fiber_surface_grad_3d_functor_hpp
24 #include "../common/common.hpp"
26 #include "basis_data.hpp"
27 #include "geometrical_data.hpp"
28 #include "collection_of_3d_arrays.hpp"
29 #include "shape_transformation_functor_wrappers.hpp"
31 #include <boost/array.hpp>
36 template <
typename CoordinateType_>
40 typedef CoordinateType_ CoordinateType;
42 int argumentDimension()
const {
return 1; }
43 int resultDimension()
const {
return 3; }
45 void addDependencies(
size_t& basisDeps,
size_t& geomDeps)
const {
46 basisDeps |= DERIVATIVES;
47 geomDeps |= JACOBIAN_INVERSES_TRANSPOSED;
50 template <
typename ValueType>
56 assert(geomData.dimWorld() == 3);
60 result(0) = basisData.
derivatives(0, 0) * geomData.jacobianInverseTransposed(0, 0) +
61 basisData.
derivatives(0, 1) * geomData.jacobianInverseTransposed(0, 1);
62 result(1) = basisData.
derivatives(0, 0) * geomData.jacobianInverseTransposed(1, 0) +
63 basisData.
derivatives(0, 1) * geomData.jacobianInverseTransposed(1, 1);
64 result(2) = basisData.
derivatives(0, 0) * geomData.jacobianInverseTransposed(2, 0) +
65 basisData.
derivatives(0, 1) * geomData.jacobianInverseTransposed(2, 1);
73 template <
typename CoordinateType_>
76 SurfaceGrad3dElementaryFunctor<CoordinateType_> >
79 typedef CoordinateType_ CoordinateType;
int componentCount() const
Return the number of components of the function.
Definition: basis_data.hpp:111
Functor calculating the surface gradient of a scalar field in 3D.
Definition: surface_grad_3d_functor.hpp:74
Definition: surface_grad_3d_functor.hpp:37
Lightweight encapsulation of a 1D slice of a 3D array.
Definition: _3d_array.hpp:155
ValueType derivatives(int dim, int direction) const
Return the value of the dim'th component of the derivative of the function in a given direction...
Definition: basis_data.hpp:106
Access to slices of geometrical data.
Definition: geometrical_data.hpp:88
Access to values and/or derivatives of shape functions.
Definition: basis_data.hpp:91