LinearBasisFunction.hpp
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #ifndef _LINEARBASISFUNCTION_HPP_
00029 #define _LINEARBASISFUNCTION_HPP_
00030
00031 #include "ChastePoint.hpp"
00032
00037 template <unsigned ELEMENT_DIM>
00038 class LinearBasisFunction
00039 {
00040 public:
00041
00051 static double ComputeBasisFunction(const ChastePoint<ELEMENT_DIM>& rPoint, unsigned basisIndex);
00052
00065 static c_vector<double, ELEMENT_DIM> ComputeBasisFunctionDerivative(const ChastePoint<ELEMENT_DIM>& rPoint, unsigned basisIndex);
00066
00067 static void ComputeBasisFunctions(const ChastePoint<ELEMENT_DIM>& rPoint, c_vector<double, ELEMENT_DIM+1>& rReturnValue);
00068 static void ComputeBasisFunctionDerivatives(const ChastePoint<ELEMENT_DIM>& rPoint,
00069 c_matrix<double, ELEMENT_DIM, ELEMENT_DIM+1>& rReturnValue);
00070
00071 static void ComputeTransformedBasisFunctionDerivatives(const ChastePoint<ELEMENT_DIM>& rPoint,
00072 const c_matrix<double, ELEMENT_DIM, ELEMENT_DIM>& rInverseJacobian,
00073 c_matrix<double, ELEMENT_DIM, ELEMENT_DIM+1>& rReturnValue);
00074 };
00075
00079 template <>
00080 class LinearBasisFunction<0>
00081 {
00082 public:
00083 static double ComputeBasisFunction(const ChastePoint<0>& rPoint, unsigned basisIndex);
00084 static void ComputeBasisFunctions(const ChastePoint<0>& rPoint,c_vector<double,1>& rReturnValue);
00085 };
00086
00087 #endif //_LINEARBASISFUNCTION_HPP_