1 // Copyright (C) 2007-2022 CEA/DEN, EDF R&D
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 #include "InterpKernelGaussCoords.hxx"
22 #include "CellModel.hxx"
30 using namespace INTERP_KERNEL;
32 const double GaussInfo::SEG2A_REF[2]={-1.0, 1.0};
34 const double GaussInfo::SEG2B_REF[2]={0., 1.0};
36 const double GaussInfo::SEG3_REF[3]={-1.0, 1.0, 0.0};
38 const double GaussInfo::TRIA3A_REF[6]={-1.0, 1.0, -1.0, -1.0, 1.0, -1.0};
40 const double GaussInfo::TRIA3B_REF[6]={0.0, 0.0, 1.0, 0.0, 0.0, 1.0};
42 const double GaussInfo::TRIA6A_REF[12]={-1.0, 1.0, -1.0, -1.0, 1.0, -1.0, -1.0, 1.0, 0.0, -1.0, 0.0, 0.0};
44 const double GaussInfo::TRIA6B_REF[12]={0.0, 0.0, 1.0, 0.0, 0.0, 1.0, 0.5, 0.0, 0.5, 0.5, 0.0, 0.5};
46 const double GaussInfo::TRIA7A_REF[14]={0.0, 0.0, 1.0, 0.0, 0.0, 1.0, 0.5, 0.0, 0.5, 0.5, 0.0, 0.5, 0.3333333333333333, 0.3333333333333333};
48 const double GaussInfo::QUAD4A_REF[8]={-1.0, 1.0, -1.0, -1.0, 1.0, -1.0, 1.0, 1.0};
50 const double GaussInfo::QUAD4B_REF[8]={-1.0, -1.0, 1.0, -1.0, 1.0, 1.0, -1.0, 1.0};
52 const double GaussInfo::QUAD8A_REF[16]={-1.0, 1.0, -1.0, -1.0, 1.0, -1.0, 1.0, 1.0, -1.0, 0.0, 0.0, -1.0, 1.0, 0.0, 0.0, 1.0};
54 const double GaussInfo::QUAD8B_REF[16]={-1.0, -1.0, 1.0, -1.0, 1.0, 1.0, -1.0, 1.0, 0.0, -1.0, 1.0, 0.0, 0.0, 1.0, -1.0, 0.0};
56 const double GaussInfo::QUAD9A_REF[18]={-1.0, -1.0, 1.0, -1.0, 1.0, 1.0, -1.0, 1.0, 0.0, -1.0, 1.0, 0.0, 0.0, 1.0, -1.0, 0.0, 0.0, 0.0};
58 const double GaussInfo::TETRA4A_REF[12]={0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0};
60 const double GaussInfo::TETRA4B_REF[12]={0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 1.0, 0.0, 0.0};
62 const double GaussInfo::TETRA10A_REF[30]={0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.5, 0.5, 0.0, 0.0, 0.5, 0.0, 0.5, 0.0, 0.5, 0.5, 0.0, 0.5, 0.0, 0.5, 0.5, 0.0, 0.0};
64 const double GaussInfo::TETRA10B_REF[30]={0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 1.0, 0.0, 0.0, 0.0, 0.5, 0.0, 0.0, 0.0, 0.5, 0.0, 0.5, 0.5, 0.5, 0.5, 0.0, 0.5, 0.0, 0.0, 0.5, 0.0, 0.5};
66 const double GaussInfo::PYRA5A_REF[15]={1.0, 0.0, 0.0, 0.0, 1.0, 0.0, -1.0, 0.0, 0.0, 0.0, -1.0, 0.0, 0.0, 0.0, 1.0};
68 const double GaussInfo::PYRA5B_REF[15]={1.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0};
70 const double GaussInfo::PYRA13A_REF[39]={1.0, 0.0, 0.0, 0.0, 1.0, 0.0, -1.0, 0.0, 0.0, 0.0, -1.0, 0.0, 0.0, 0.0, 1.0, 0.5, 0.5, 0.0, -0.5, 0.5, 0.0, -0.5, -0.5, 0.0, 0.5, -0.5, 0.0, 0.5, 0.0, 0.5, 0.0, 0.5, 0.5, -0.5, 0.0, 0.5, 0.0, -0.5, 0.5};
72 const double GaussInfo::PYRA13B_REF[39]={1.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.5, -0.5, 0.0, -0.5, -0.5, 0.0, -0.5, 0.5, 0.0, 0.5, 0.5, 0.0, 0.5, 0.0, 0.5, 0.0, -0.5, 0.5, -0.5, 0.0, 0.5, 0.0, 0.5, 0.5};
74 const double GaussInfo::PENTA6A_REF[18]={-1.0, 1.0, 0.0, -1.0, -0.0, 1.0, -1.0, 0.0, 0.0, 1.0, 1.0, 0.0, 1.0, 0.0, 1.0, 1.0, 0.0, 0.0};
76 const double GaussInfo::PENTA6B_REF[18]={-1.0, 1.0, 0.0, -1.0, 0.0, 0.0, -1.0, -0.0, 1.0, 1.0, 1.0, 0.0, 1.0, 0.0, 0.0, 1.0, 0.0, 1.0};
78 const double GaussInfo::PENTA15A_REF[45]={-1.0, 1.0, 0.0, -1.0, -0.0, 1.0, -1.0, 0.0, 0.0, 1.0, 1.0, 0.0, 1.0, 0.0, 1.0, 1.0, 0.0, 0.0, -1.0, 0.5, 0.5, -1.0, 0.0, 0.5, -1.0, 0.5, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.5, 0.5, 1.0, 0.0, 0.5, 1.0, 0.5, 0.0};
80 const double GaussInfo::PENTA15B_REF[45]={-1.0, 1.0, 0.0, -1.0, 0.0, 0.0, -1.0, -0.0, 1.0, 1.0, 1.0, 0.0, 1.0, 0.0, 0.0, 1.0, 0.0, 1.0, -1.0, 0.5, 0.0, -1.0, 0.0, 0.5, -1.0, 0.5, 0.5, 1.0, 0.5, 0.0, 1.0, 0.0, 0.5, 1.0, 0.5, 0.5, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0};
82 const double GaussInfo::PENTA18A_REF[54]={-1.0, 1.0, 0.0, -1.0, -0.0, 1.0, -1.0, 0.0, 0.0, 1.0, 1.0, 0.0, 1.0, 0.0, 1.0, 1.0, 0.0, 0.0, -1.0, 0.5, 0.5, -1.0, 0.0, 0.5, -1.0, 0.5, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, 0.5, 0.5, 1.0, 0.0, 0.5, 1.0, 0.5, 0.0, 0.0, 0.5, 0.5, 0.0, 0.0, 0.5, 0.0, 0.5, 0.0};
84 const double GaussInfo::PENTA18B_REF[54]={-1.0, 1.0, 0.0, -1.0, 0.0, 0.0, -1.0, -0.0, 1.0, 1.0, 1.0, 0.0, 1.0, 0.0, 0.0, 1.0, 0.0, 1.0, -1.0, 0.5, 0.0, -1.0, 0.0, 0.5, -1.0, 0.5, 0.5, 1.0, 0.5, 0.0, 1.0, 0.0, 0.5, 1.0, 0.5, 0.5, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.5, 0.0, 0.0, 0.0, 0.5, 0.0, 0.5, 0.5};
86 const double GaussInfo::HEXA8A_REF[24]={-1.0, -1.0, -1.0, 1.0, -1.0, -1.0, 1.0, 1.0, -1.0, -1.0, 1.0, -1.0, -1.0, -1.0, 1.0, 1.0, -1.0, 1.0, 1.0, 1.0, 1.0, -1.0, 1.0, 1.0};
88 const double GaussInfo::HEXA8B_REF[24]={-1.0, -1.0, -1.0, -1.0, 1.0, -1.0, 1.0, 1.0, -1.0, 1.0, -1.0, -1.0, -1.0, -1.0, 1.0, -1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, -1.0, 1.0};
90 const double GaussInfo::HEXA20A_REF[60]={-1.0, -1.0, -1.0, 1.0, -1.0, -1.0, 1.0, 1.0, -1.0, -1.0, 1.0, -1.0, -1.0, -1.0, 1.0, 1.0, -1.0, 1.0, 1.0, 1.0, 1.0, -1.0, 1.0, 1.0, 0.0, -1.0, -1.0, 1.0, 0.0, -1.0, 0.0, 1.0, -1.0, -1.0, 0.0, -1.0, -1.0, -1.0, 0.0, 1.0, -1.0, 0.0, 1.0, 1.0, 0.0, -1.0, 1.0, 0.0, 0.0, -1.0, 1.0, 1.0, 0.0, 1.0, 0.0, 1.0, 1.0, -1.0, 0.0, 1.0};
92 const double GaussInfo::HEXA20B_REF[60]={-1.0, -1.0, -1.0, -1.0, 1.0, -1.0, 1.0, 1.0, -1.0, 1.0, -1.0, -1.0, -1.0, -1.0, 1.0, -1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, -1.0, 1.0, -1.0, 0.0, -1.0, 0.0, 1.0, -1.0, 1.0, 0.0, -1.0, 0.0, -1.0, -1.0, -1.0, 0.0, 1.0, 0.0, 1.0, 1.0, 1.0, 0.0, 1.0, 0.0, -1.0, 1.0, -1.0, -1.0, 0.0, -1.0, 1.0, 0.0, 1.0, 1.0, 0.0, 1.0, -1.0, 0.0};
94 const double GaussInfo::HEXA27A_REF[81]={-1.0, -1.0, -1.0, -1.0, 1.0, -1.0, 1.0, 1.0, -1.0, 1.0, -1.0, -1.0, -1.0, -1.0, 1.0, -1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, -1.0, 1.0, -1.0, 0.0, -1.0, 0.0, 1.0, -1.0, 1.0, 0.0, -1.0, 0.0, -1.0, -1.0, -1.0, 0.0, 1.0, 0.0, 1.0, 1.0, 1.0, 0.0, 1.0, 0.0, -1.0, 1.0, -1.0, -1.0, 0.0, -1.0, 1.0, 0.0, 1.0, 1.0, 0.0, 1.0, -1.0, 0.0, 0.0, 0.0, -1.0, -1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 1.0, 0.0, 0.0, 0.0, -1.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0};
96 //Define common part of the code in the MACRO
97 //---------------------------------------------------------------
98 #define LOCAL_COORD_MACRO_BEGIN \
99 _my_local_reference_coord.resize( _my_local_ref_dim*_my_local_nb_ref ); \
100 for( int refId = 0; refId < _my_local_nb_ref; refId++ ) \
102 double* coords = &_my_local_reference_coord[ refId*_my_local_ref_dim ]; \
106 //---------------------------------------------------------------
107 #define LOCAL_COORD_MACRO_END \
111 //---------------------------------------------------------------
112 #define SHAPE_FUN_MACRO_BEGIN \
113 for( int gaussId = 0 ; gaussId < _my_nb_gauss ; gaussId++ ) \
115 double* funValue = &_my_function_value[ gaussId * _my_nb_ref ]; \
116 const double* gc = &_my_gauss_coord[ gaussId * getGaussCoordDim() ];
118 //---------------------------------------------------------------
119 #define SHAPE_FUN_MACRO_END \
122 #define DEV_SHAPE_FUN_MACRO_BEGIN \
123 for( int gaussId = 0 ; gaussId < _my_nb_gauss ; gaussId++ ) \
125 double *devFunValue = _my_derivative_func_value.data() + gaussId * getReferenceCoordDim() * _my_nb_ref; \
126 const double *gc = _my_gauss_coord.data() + gaussId * getGaussCoordDim();
128 #define DEV_SHAPE_FUN_MACRO_END \
131 #define CHECK_MACRO \
134 std::ostringstream stream; \
135 stream << "Error in the gauss localization for the cell with type "; \
136 stream << cellModel.getRepr(); \
138 throw INTERP_KERNEL::Exception(stream.str().c_str()); \
142 //---------------------------------------------------------------
143 static bool IsEqual(double theLeft, double theRight)
145 static double EPS = 1.0E-3;
146 if(fabs(theLeft) + fabs(theRight) > EPS)
147 return fabs(theLeft-theRight)/(fabs(theLeft)+fabs(theRight)) < EPS;
152 ////////////////////////////////////////////////////////////////////////////////////////////////
153 // GAUSS INFO CLASS //
154 ////////////////////////////////////////////////////////////////////////////////////////////////
157 * Constructor of the GaussInfo
159 GaussInfo::GaussInfo( NormalizedCellType theGeometry,
160 const DataVector& theGaussCoord,
162 const DataVector& theReferenceCoord,
164 _my_geometry(theGeometry),
165 _my_nb_gauss(theNbGauss),
166 _my_gauss_coord(theGaussCoord),
167 _my_nb_ref(theNbRef),
168 _my_reference_coord(theReferenceCoord)
170 //Allocate shape function values
171 _my_function_value.resize( _my_nb_gauss * _my_nb_ref );
172 _my_derivative_func_value.resize( _my_nb_gauss * _my_nb_ref * getReferenceCoordDim() );
178 GaussInfo::~GaussInfo()
183 * Return dimension of the gauss coordinates
185 int GaussInfo::getGaussCoordDim() const
189 return (int)_my_gauss_coord.size()/_my_nb_gauss;
198 * Return dimension of the reference coordinates
200 int GaussInfo::getReferenceCoordDim() const
204 return (int)(_my_reference_coord.size()/_my_nb_ref);
213 * Return type of the cell.
215 NormalizedCellType GaussInfo::getCellType() const
221 * Return Nb of the gauss points.
223 int GaussInfo::getNbGauss() const
229 * Return Nb of the reference coordinates.
231 int GaussInfo::getNbRef() const
236 GaussInfo GaussInfo::convertToLinear() const
242 std::vector<double> a(SEG3_REF,SEG3_REF+3);
243 if(IsSatisfy(a,_my_reference_coord))
245 std::vector<double> c(SEG2A_REF,SEG2A_REF+2);
246 return GaussInfo(NORM_SEG2,_my_gauss_coord,getNbGauss(),c,2);
248 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for SEG3 !");
252 std::vector<double> a(TRIA6A_REF,TRIA6A_REF+12),b(TRIA6B_REF,TRIA6B_REF+12);
253 if(IsSatisfy(a,_my_reference_coord))
255 std::vector<double> c(TRIA3A_REF,TRIA3A_REF+6);
256 return GaussInfo(NORM_TRI3,_my_gauss_coord,getNbGauss(),c,3);
258 if(IsSatisfy(b,_my_reference_coord))
260 std::vector<double> c(TRIA3B_REF,TRIA3B_REF+6);
261 return GaussInfo(NORM_TRI3,_my_gauss_coord,getNbGauss(),c,3);
263 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for TRI6 !");
267 std::vector<double> a(TRIA7A_REF,TRIA7A_REF+14);
268 if(IsSatisfy(a,_my_reference_coord))
270 std::vector<double> c(TRIA3B_REF,TRIA3B_REF+6);
271 return GaussInfo(NORM_TRI3,_my_gauss_coord,getNbGauss(),c,3);
273 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for TRI7 !");
277 std::vector<double> a(QUAD8A_REF,QUAD8A_REF+16),b(QUAD8B_REF,QUAD8B_REF+16);
278 if(IsSatisfy(a,_my_reference_coord))
280 std::vector<double> c(QUAD4A_REF,QUAD4A_REF+8);
281 return GaussInfo(NORM_QUAD4,_my_gauss_coord,getNbGauss(),c,4);
283 if(IsSatisfy(b,_my_reference_coord))
285 std::vector<double> c(QUAD4B_REF,QUAD4B_REF+8);
286 return GaussInfo(NORM_QUAD4,_my_gauss_coord,getNbGauss(),c,4);
288 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for QUAD8 !");
292 std::vector<double> a(QUAD9A_REF,QUAD9A_REF+18);
293 if(IsSatisfy(a,_my_reference_coord))
295 std::vector<double> c(QUAD4B_REF,QUAD4B_REF+8);
296 return GaussInfo(NORM_QUAD4,_my_gauss_coord,getNbGauss(),c,4);
298 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for QUAD9 !");
302 std::vector<double> a(TETRA10A_REF,TETRA10A_REF+30),b(TETRA10B_REF,TETRA10B_REF+30);
303 if(IsSatisfy(a,_my_reference_coord))
305 std::vector<double> c(TETRA4A_REF,TETRA4A_REF+12);
306 return GaussInfo(NORM_TETRA4,_my_gauss_coord,getNbGauss(),c,4);
308 if(IsSatisfy(b,_my_reference_coord))
310 std::vector<double> c(TETRA4B_REF,TETRA4B_REF+12);
311 return GaussInfo(NORM_TETRA4,_my_gauss_coord,getNbGauss(),c,4);
313 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for TETRA10 !");
317 std::vector<double> a(PYRA13A_REF,PYRA13A_REF+39),b(PYRA13B_REF,PYRA13B_REF+39);
318 if(IsSatisfy(a,_my_reference_coord))
320 std::vector<double> c(PYRA5A_REF,PYRA5A_REF+15);
321 return GaussInfo(NORM_PYRA5,_my_gauss_coord,getNbGauss(),c,5);
323 if(IsSatisfy(b,_my_reference_coord))
325 std::vector<double> c(PYRA5B_REF,PYRA5B_REF+15);
326 return GaussInfo(NORM_PYRA5,_my_gauss_coord,getNbGauss(),c,5);
328 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for PYRA13 !");
332 std::vector<double> a(PENTA15A_REF,PENTA15A_REF+45),b(PENTA15B_REF,PENTA15B_REF+45);
333 if(IsSatisfy(a,_my_reference_coord))
335 std::vector<double> c(PENTA6A_REF,PENTA6A_REF+18);
336 return GaussInfo(NORM_PENTA6,_my_gauss_coord,getNbGauss(),c,6);
338 if(IsSatisfy(b,_my_reference_coord))
340 std::vector<double> c(PENTA6B_REF,PENTA6B_REF+18);
341 return GaussInfo(NORM_PENTA6,_my_gauss_coord,getNbGauss(),c,6);
343 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for PENTA15 !");
347 std::vector<double> a(PENTA18A_REF,PENTA18A_REF+54),b(PENTA18B_REF,PENTA18B_REF+54);
348 if(IsSatisfy(a,_my_reference_coord))
350 std::vector<double> c(PENTA6A_REF,PENTA6A_REF+18);
351 return GaussInfo(NORM_PENTA6,_my_gauss_coord,getNbGauss(),c,6);
353 if(IsSatisfy(b,_my_reference_coord))
355 std::vector<double> c(PENTA6B_REF,PENTA6B_REF+18);
356 return GaussInfo(NORM_PENTA6,_my_gauss_coord,getNbGauss(),c,6);
358 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for PENTA18 !");
362 std::vector<double> a(HEXA20A_REF,HEXA20A_REF+60),b(HEXA20B_REF,HEXA20B_REF+60);
363 if(IsSatisfy(a,_my_reference_coord))
365 std::vector<double> c(HEXA8A_REF,HEXA8A_REF+24);
366 return GaussInfo(NORM_HEXA8,_my_gauss_coord,getNbGauss(),c,8);
368 if(IsSatisfy(b,_my_reference_coord))
370 std::vector<double> c(HEXA8B_REF,HEXA8B_REF+24);
371 return GaussInfo(NORM_HEXA8,_my_gauss_coord,getNbGauss(),c,8);
373 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for HEXA20 !");
377 std::vector<double> a(HEXA27A_REF,HEXA27A_REF+81);
378 if(IsSatisfy(a,_my_reference_coord))
380 std::vector<double> c(HEXA8B_REF,HEXA8B_REF+24);
381 return GaussInfo(NORM_HEXA8,_my_gauss_coord,getNbGauss(),c,8);
383 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not recognized pattern for HEXA27 !");
386 throw INTERP_KERNEL::Exception("GaussInfo::convertToLinear : not implemented yet for other types than TETRA10, HEXA20, HEXA27, TRI3, QUAD8, QUAD8, PYRA13, PENTA15 !");
391 bool GaussInfo::IsSatisfy(const std::vector<double>& ref1, const std::vector<double>& ref2)
393 std::size_t sz(ref1.size());
396 for(std::size_t i=0;i<sz;i++)
397 if(!IsEqual(ref1[i],ref2[i]))
405 bool GaussInfo::isSatisfy()
408 bool anIsSatisfy = ((_my_local_nb_ref == _my_nb_ref) && (_my_local_ref_dim == getReferenceCoordDim()));
412 for( int refId = 0; refId < _my_local_nb_ref; refId++ )
414 double* refCoord = &_my_reference_coord[ refId*_my_local_ref_dim ];
415 double* localRefCoord = &_my_local_reference_coord[ refId*_my_local_ref_dim ];
416 bool anIsEqual = false;
417 for( int dimId = 0; dimId < _my_local_ref_dim; dimId++ )
419 anIsEqual = IsEqual( localRefCoord[dimId], refCoord[dimId]);
430 std::vector<double> GaussInfo::NormalizeCoordinatesIfNecessary(NormalizedCellType ct, int inputDim, const std::vector<double>& inputArray)
432 std::size_t sz(inputArray.size()),dim((std::size_t)inputDim);
434 throw INTERP_KERNEL::Exception("GaussInfo::NormalizeCoordinatesIfNecessary : invalid dimension ! Must be !=0 !");
436 throw INTERP_KERNEL::Exception("GaussInfo::NormalizeCoordinatesIfNecessary : invalid input array ! Inconsistent with the given dimension !");
437 const CellModel& cm(CellModel::GetCellModel(ct));
438 std::size_t baseDim((std::size_t)cm.getDimension());
441 std::size_t nbOfItems(sz/dim);
442 std::vector<double> ret(nbOfItems*baseDim);
445 for(std::size_t i=0;i<nbOfItems;i++)
449 ret[i*baseDim+j]=inputArray[i*dim+j];
456 for(std::size_t i=0;i<nbOfItems;i++)
460 ret[i*baseDim+j]=inputArray[i*dim+j];
466 std::vector<double> GaussInfo::GetDefaultReferenceCoordinatesOf(NormalizedCellType ct)
470 case INTERP_KERNEL::NORM_SEG2:
471 return std::vector<double>(SEG2A_REF,SEG2A_REF+sizeof(SEG2A_REF)/sizeof(double));
472 case INTERP_KERNEL::NORM_SEG3:
473 return std::vector<double>(SEG3_REF,SEG3_REF+sizeof(SEG3_REF)/sizeof(double));
474 case INTERP_KERNEL::NORM_TRI3:
475 return std::vector<double>(TRIA3A_REF,TRIA3A_REF+sizeof(TRIA3A_REF)/sizeof(double));
476 case INTERP_KERNEL::NORM_TRI6:
477 return std::vector<double>(TRIA6A_REF,TRIA6A_REF+sizeof(TRIA6A_REF)/sizeof(double));
478 case INTERP_KERNEL::NORM_TRI7:
479 return std::vector<double>(TRIA7A_REF,TRIA7A_REF+sizeof(TRIA7A_REF)/sizeof(double));
480 case INTERP_KERNEL::NORM_QUAD4:
481 return std::vector<double>(QUAD4A_REF,QUAD4A_REF+sizeof(QUAD4A_REF)/sizeof(double));
482 case INTERP_KERNEL::NORM_QUAD8:
483 return std::vector<double>(QUAD8A_REF,QUAD8A_REF+sizeof(QUAD8A_REF)/sizeof(double));
484 case INTERP_KERNEL::NORM_QUAD9:
485 return std::vector<double>(QUAD9A_REF,QUAD9A_REF+sizeof(QUAD9A_REF)/sizeof(double));
486 case INTERP_KERNEL::NORM_TETRA4:
487 return std::vector<double>(TETRA4A_REF,TETRA4A_REF+sizeof(TETRA4A_REF)/sizeof(double));
488 case INTERP_KERNEL::NORM_TETRA10:
489 return std::vector<double>(TETRA10A_REF,TETRA10A_REF+sizeof(TETRA10A_REF)/sizeof(double));
490 case INTERP_KERNEL::NORM_PYRA5:
491 return std::vector<double>(PYRA5A_REF,PYRA5A_REF+sizeof(PYRA5A_REF)/sizeof(double));
492 case INTERP_KERNEL::NORM_PYRA13:
493 return std::vector<double>(PYRA13A_REF,PYRA13A_REF+sizeof(PYRA13A_REF)/sizeof(double));
494 case INTERP_KERNEL::NORM_PENTA6:
495 return std::vector<double>(PENTA6A_REF,PENTA6A_REF+sizeof(PENTA6A_REF)/sizeof(double));
496 case INTERP_KERNEL::NORM_PENTA15:
497 return std::vector<double>(PENTA15A_REF,PENTA15A_REF+sizeof(PENTA15A_REF)/sizeof(double));
498 case INTERP_KERNEL::NORM_PENTA18:
499 return std::vector<double>(PENTA18A_REF,PENTA18A_REF+sizeof(PENTA18A_REF)/sizeof(double));
500 case INTERP_KERNEL::NORM_HEXA8:
501 return std::vector<double>(HEXA8A_REF,HEXA8A_REF+sizeof(HEXA8A_REF)/sizeof(double));
502 case INTERP_KERNEL::NORM_HEXA20:
503 return std::vector<double>(HEXA20A_REF,HEXA20A_REF+sizeof(HEXA20A_REF)/sizeof(double));
504 case INTERP_KERNEL::NORM_HEXA27:
505 return std::vector<double>(HEXA27A_REF,HEXA27A_REF+sizeof(HEXA27A_REF)/sizeof(double));
507 THROW_IK_EXCEPTION("Input type " << ct << "is not managed by GetDefaultReferenceCoordinatesOf")
512 * Returns true if \a ptInRefCoo is in reference cell of type \a ct (regarding GetDefaultReferenceCoordinatesOf)
513 * \sa GetDefaultReferenceCoordinatesOf
515 bool GaussInfo::IsInOrOutForReference(NormalizedCellType ct, const double *ptInRefCoo, double eps)
519 case INTERP_KERNEL::NORM_SEG2:
520 case INTERP_KERNEL::NORM_SEG3:
522 return std::fabs(ptInRefCoo[0]) < 1.0+eps;
524 case INTERP_KERNEL::NORM_QUAD4:
525 case INTERP_KERNEL::NORM_QUAD8:
526 case INTERP_KERNEL::NORM_QUAD9:
528 return std::find_if(ptInRefCoo,ptInRefCoo+2,[eps](double v){ return std::fabs(v) > 1.0+eps; }) == ptInRefCoo+2;
530 case INTERP_KERNEL::NORM_HEXA8:
531 case INTERP_KERNEL::NORM_HEXA20:
532 case INTERP_KERNEL::NORM_HEXA27:
534 return std::find_if(ptInRefCoo,ptInRefCoo+3,[eps](double v){ return std::fabs(v) > 1.0+eps; }) == ptInRefCoo+3;
537 THROW_IK_EXCEPTION("IsInOrOutForReference : not implemented for this geo type !");
541 typedef void (*MapToShapeFunction)(GaussInfo& obj);
544 * Initialize the internal vectors
546 void GaussInfo::initLocalInfo()
548 bool aSatify = false;
549 const CellModel& cellModel(CellModel::GetCellModel(_my_geometry));
550 switch( _my_geometry )
553 _my_local_ref_dim = 0;
554 _my_local_nb_ref = 1;
556 aSatify = isSatisfy();
561 _my_local_ref_dim = 1;
562 _my_local_nb_ref = 2;
564 aSatify = isSatisfy();
568 aSatify = isSatisfy();
574 _my_local_ref_dim = 1;
575 _my_local_nb_ref = 3;
577 aSatify = isSatisfy();
582 _my_local_ref_dim = 2;
583 _my_local_nb_ref = 3;
585 aSatify = isSatisfy();
590 aSatify = isSatisfy();
596 _my_local_ref_dim = 2;
597 _my_local_nb_ref = 6;
599 aSatify = isSatisfy();
603 aSatify = isSatisfy();
609 _my_local_ref_dim = 2;
610 _my_local_nb_ref = 7;
612 aSatify = isSatisfy();
618 _my_local_ref_dim = 2;
619 _my_local_nb_ref = 4;
620 MapToShapeFunction QUAD4PTR[]={Quad4aInit,Quad4bInit,Quad4cInit,Quad4DegSeg2Init};
621 std::size_t NB_OF_QUAD4PTR(sizeof(QUAD4PTR)/sizeof(MapToShapeFunction));
622 for(std::size_t i=0;i<NB_OF_QUAD4PTR && !aSatify;i++)
624 (QUAD4PTR[i])(*this);
625 aSatify = isSatisfy();
633 _my_local_ref_dim = 2;
634 _my_local_nb_ref = 8;
636 aSatify = isSatisfy();
641 aSatify = isSatisfy();
647 _my_local_ref_dim = 2;
648 _my_local_nb_ref = 9;
650 aSatify = isSatisfy();
655 _my_local_ref_dim = 3;
656 _my_local_nb_ref = 4;
658 aSatify = isSatisfy();
663 aSatify = isSatisfy();
669 _my_local_ref_dim = 3;
670 _my_local_nb_ref = 10;
672 aSatify = isSatisfy();
677 aSatify = isSatisfy();
683 _my_local_ref_dim = 3;
684 _my_local_nb_ref = 5;
686 aSatify = isSatisfy();
691 aSatify = isSatisfy();
697 _my_local_ref_dim = 3;
698 _my_local_nb_ref = 13;
700 aSatify = isSatisfy();
705 aSatify = isSatisfy();
712 _my_local_ref_dim = 3;
713 _my_local_nb_ref = 6;
714 MapToShapeFunction PENTA6PTR[]={Penta6aInit,Penta6bInit,Penta6DegTria3aInit,Penta6DegTria3bInit};
715 std::size_t NB_OF_PENTA6PTR(sizeof(PENTA6PTR)/sizeof(MapToShapeFunction));
716 for(std::size_t i=0;i<NB_OF_PENTA6PTR && !aSatify;i++)
718 (PENTA6PTR[i])(*this);
719 aSatify = isSatisfy();
725 /* _my_local_ref_dim = 3;
726 _my_local_nb_ref = 6;
728 aSatify = isSatisfy();
733 aSatify = isSatisfy();
740 _my_local_ref_dim = 3;
741 _my_local_nb_ref = 15;
742 MapToShapeFunction PENTA15PTR[]={Penta15aInit,Penta15bInit};
743 std::size_t NB_OF_PENTA15PTR(sizeof(PENTA15PTR)/sizeof(MapToShapeFunction));
744 for(std::size_t i=0;i<NB_OF_PENTA15PTR && !aSatify;i++)
746 (PENTA15PTR[i])(*this);
747 aSatify = isSatisfy();
755 _my_local_ref_dim = 3;
756 _my_local_nb_ref = 18;
757 MapToShapeFunction PENTA18PTR[]={Penta18aInit,Penta18bInit};
758 std::size_t NB_OF_PENTA18PTR(sizeof(PENTA18PTR)/sizeof(MapToShapeFunction));
759 for(std::size_t i=0;i<NB_OF_PENTA18PTR && !aSatify;i++)
761 (PENTA18PTR[i])(*this);
762 aSatify = isSatisfy();
770 _my_local_ref_dim = 3;
771 _my_local_nb_ref = 8;
772 MapToShapeFunction HEXA8PTR[]={Hexa8aInit,Hexa8bInit,Hexa8DegQuad4aInit,Hexa8DegQuad4bInit,Hexa8DegQuad4cInit};
773 std::size_t NB_OF_HEXA8PTR(sizeof(HEXA8PTR)/sizeof(MapToShapeFunction));
774 for(std::size_t i=0;i<NB_OF_HEXA8PTR && !aSatify;i++)
776 (HEXA8PTR[i])(*this);
777 aSatify = isSatisfy();
784 _my_local_ref_dim = 3;
785 _my_local_nb_ref = 20;
787 aSatify = isSatisfy();
792 aSatify = isSatisfy();
798 _my_local_ref_dim = 3;
799 _my_local_nb_ref = 27;
801 aSatify = isSatisfy();
806 throw INTERP_KERNEL::Exception("Not managed cell type !");
812 * Return shape function value by node id
814 const double *GaussInfo::getFunctionValues( const int theGaussId ) const
816 return _my_function_value.data() + _my_nb_ref*theGaussId ;
820 * Return the derivative of shape function value by node id
822 const double *GaussInfo::getDerivativeOfShapeFunctionAt( const int theGaussId ) const
824 return _my_derivative_func_value.data() + _my_nb_ref*getReferenceCoordDim()*theGaussId;
827 void GaussInfo::point1Init()
829 double *funValue(&_my_function_value[0]);
834 * Init Segment 2 Reference coordinates ans Shape function.
836 void GaussInfo::seg2aInit()
838 LOCAL_COORD_MACRO_BEGIN;
840 coords[0] = SEG2A_REF[0];
843 coords[0] = SEG2A_REF[1];
845 LOCAL_COORD_MACRO_END;
847 SHAPE_FUN_MACRO_BEGIN;
848 funValue[0] = 0.5*(1.0 - gc[0]);
849 funValue[1] = 0.5*(1.0 + gc[0]);
853 void GaussInfo::seg2bInit()
855 LOCAL_COORD_MACRO_BEGIN;
857 coords[0] = SEG2B_REF[0];
860 coords[0] = SEG2B_REF[1];
862 LOCAL_COORD_MACRO_END;
864 SHAPE_FUN_MACRO_BEGIN;
865 funValue[0] = 1.0 - gc[0];
871 * Init Segment 3 Reference coordinates ans Shape function.
873 void GaussInfo::seg3Init()
875 LOCAL_COORD_MACRO_BEGIN;
877 coords[0] = SEG3_REF[0];
880 coords[0] = SEG3_REF[1];
883 coords[0] = SEG3_REF[2];
884 LOCAL_COORD_MACRO_END;
886 SHAPE_FUN_MACRO_BEGIN;
887 funValue[0] = -0.5*(1.0 - gc[0])*gc[0];
888 funValue[1] = 0.5*(1.0 + gc[0])*gc[0];
889 funValue[2] = (1.0 + gc[0])*(1.0 - gc[0]);
894 * Init Triangle Reference coordinates ans Shape function.
897 void GaussInfo::tria3aInit()
899 LOCAL_COORD_MACRO_BEGIN;
901 coords[0] = TRIA3A_REF[0];
902 coords[1] = TRIA3A_REF[1];
905 coords[0] = TRIA3A_REF[2];
906 coords[1] = TRIA3A_REF[3];
909 coords[0] = TRIA3A_REF[4];
910 coords[1] = TRIA3A_REF[5];
912 LOCAL_COORD_MACRO_END;
914 SHAPE_FUN_MACRO_BEGIN;
915 funValue[0] = 0.5*(1.0 + gc[1]);
916 funValue[1] = -0.5*(gc[0] + gc[1]);
917 funValue[2] = 0.5*(1.0 + gc[0]);
920 DEV_SHAPE_FUN_MACRO_BEGIN;
922 devFunValue[0] = 0.0 ;
923 devFunValue[1] = 0.5 ;
925 devFunValue[2] = -0.5;
926 devFunValue[3] = -0.5;
928 devFunValue[4] = 0.5;
929 devFunValue[5] = 0.0;
931 DEV_SHAPE_FUN_MACRO_END;
935 * Init Triangle Reference coordinates ans Shape function.
938 void GaussInfo::tria3bInit()
940 LOCAL_COORD_MACRO_BEGIN;
942 coords[0] = TRIA3B_REF[0];
943 coords[1] = TRIA3B_REF[1];
946 coords[0] = TRIA3B_REF[2];
947 coords[1] = TRIA3B_REF[3];
950 coords[0] = TRIA3B_REF[4];
951 coords[1] = TRIA3B_REF[5];
953 LOCAL_COORD_MACRO_END;
955 SHAPE_FUN_MACRO_BEGIN;
956 funValue[0] = 1.0 - gc[0] - gc[1];
961 DEV_SHAPE_FUN_MACRO_BEGIN;
963 devFunValue[0] = -1.0 ;
964 devFunValue[1] = -1.0 ;
966 devFunValue[2] = 1.0 ;
967 devFunValue[3] = 0.0 ;
969 devFunValue[4] = 0.0 ;
970 devFunValue[5] = 1.0 ;
972 DEV_SHAPE_FUN_MACRO_END;
976 * Init Quadratic Triangle Reference coordinates ans Shape function.
979 void GaussInfo::tria6aInit()
981 LOCAL_COORD_MACRO_BEGIN;
983 coords[0] = TRIA6A_REF[0];
984 coords[1] = TRIA6A_REF[1];
987 coords[0] = TRIA6A_REF[2];
988 coords[1] = TRIA6A_REF[3];
991 coords[0] = TRIA6A_REF[4];
992 coords[1] = TRIA6A_REF[5];
995 coords[0] = TRIA6A_REF[6];
996 coords[1] = TRIA6A_REF[7];
999 coords[0] = TRIA6A_REF[8];
1000 coords[1] = TRIA6A_REF[9];
1003 coords[0] = TRIA6A_REF[10];
1004 coords[1] = TRIA6A_REF[11];
1006 LOCAL_COORD_MACRO_END;
1008 SHAPE_FUN_MACRO_BEGIN;
1009 funValue[0] = 0.5*(1.0 + gc[1])*gc[1];
1010 funValue[1] = 0.5*(gc[0] + gc[1])*(gc[0] + gc[1] + 1);
1011 funValue[2] = 0.5*(1.0 + gc[0])*gc[0];
1012 funValue[3] = -1.0*(1.0 + gc[1])*(gc[0] + gc[1]);
1013 funValue[4] = -1.0*(1.0 + gc[0])*(gc[0] + gc[1]);
1014 funValue[5] = (1.0 + gc[1])*(1.0 + gc[1]);
1015 SHAPE_FUN_MACRO_END;
1017 DEV_SHAPE_FUN_MACRO_BEGIN;
1019 devFunValue[0] = 0.0;
1020 devFunValue[1] = 0.5*( 2*gc[1] + 1.0 );
1022 devFunValue[2] = 0.5*( 2*gc[0] + 2.0*gc[1] + 1.0);
1023 devFunValue[3] = 0.5*( 2*gc[1] + 2.0*gc[0] + 1.0);
1025 devFunValue[4] = gc[0] + 0.5;
1026 devFunValue[5] = 0.0;
1028 devFunValue[6] = -1.0*(1.0 + gc[1]);
1029 devFunValue[7] = -1.0*(2*gc[1]+gc[0]+1.0);
1031 devFunValue[8] = -1.0*(2*gc[0]+gc[1]+1.0);
1032 devFunValue[9] = -1.0*(1.0 + gc[0]);
1034 devFunValue[10] = 0.0;
1035 devFunValue[11] = (2*gc[1]+2.0);
1037 DEV_SHAPE_FUN_MACRO_END;
1041 * Init Quadratic Triangle Reference coordinates ans Shape function.
1044 void GaussInfo::tria6bInit()
1046 LOCAL_COORD_MACRO_BEGIN;
1048 coords[0] = TRIA6B_REF[0];
1049 coords[1] = TRIA6B_REF[1];
1052 coords[0] = TRIA6B_REF[2];
1053 coords[1] = TRIA6B_REF[3];
1056 coords[0] = TRIA6B_REF[4];
1057 coords[1] = TRIA6B_REF[5];
1060 coords[0] = TRIA6B_REF[6];
1061 coords[1] = TRIA6B_REF[7];
1064 coords[0] = TRIA6B_REF[8];
1065 coords[1] = TRIA6B_REF[9];
1068 coords[0] = TRIA6B_REF[10];
1069 coords[1] = TRIA6B_REF[11];
1071 LOCAL_COORD_MACRO_END;
1073 SHAPE_FUN_MACRO_BEGIN;
1074 funValue[0] = (1.0 - gc[0] - gc[1])*(1.0 - 2.0*gc[0] - 2.0*gc[1]);
1075 funValue[1] = gc[0]*(2.0*gc[0] - 1.0);
1076 funValue[2] = gc[1]*(2.0*gc[1] - 1.0);
1077 funValue[3] = 4.0*gc[0]*(1.0 - gc[0] - gc[1]);
1078 funValue[4] = 4.0*gc[0]*gc[1];
1079 funValue[5] = 4.0*gc[1]*(1.0 - gc[0] - gc[1]);
1080 SHAPE_FUN_MACRO_END;
1082 DEV_SHAPE_FUN_MACRO_BEGIN;
1084 devFunValue[0] = 4*gc[0] + 4*gc[1] - 3.0 ;
1085 devFunValue[1] = 4*gc[1] + 4*gc[0] - 3.0 ;
1087 devFunValue[2] = 4*gc[0] - 1.0 ;
1088 devFunValue[3] = 0.0 ;
1090 devFunValue[4] = 0.0 ;
1091 devFunValue[5] = 4*gc[1] - 1.0 ;
1093 devFunValue[6] = -8.0*gc[0] - 4.0 * gc[1] + 4.0 ;
1094 devFunValue[7] = -4.0*gc[0] ;
1096 devFunValue[8] = 4.0*gc[1];
1097 devFunValue[9] = 4.0*gc[0];
1099 devFunValue[10] = -4.0*gc[1] ;
1100 devFunValue[11] = -8.0*gc[1] - 4.0*gc[0] + 4.0 ;
1102 DEV_SHAPE_FUN_MACRO_END;
1105 void GaussInfo::tria7aInit()
1107 LOCAL_COORD_MACRO_BEGIN;
1109 coords[0] = TRIA7A_REF[0];
1110 coords[1] = TRIA7A_REF[1];
1113 coords[0] = TRIA7A_REF[2];
1114 coords[1] = TRIA7A_REF[3];
1117 coords[0] = TRIA7A_REF[4];
1118 coords[1] = TRIA7A_REF[5];
1121 coords[0] = TRIA7A_REF[6];
1122 coords[1] = TRIA7A_REF[7];
1125 coords[0] = TRIA7A_REF[8];
1126 coords[1] = TRIA7A_REF[9];
1129 coords[0] = TRIA7A_REF[10];
1130 coords[1] = TRIA7A_REF[11];
1133 coords[0] = TRIA7A_REF[12];
1134 coords[1] = TRIA7A_REF[13];
1136 LOCAL_COORD_MACRO_END;
1138 SHAPE_FUN_MACRO_BEGIN;
1139 funValue[0]=1-3*(gc[0]+gc[1])+2*(gc[0]*gc[0]+gc[1]*gc[1])+7*gc[0]*gc[1]-3*gc[0]*gc[1]*(gc[0]+gc[1]);
1140 funValue[1]=gc[0]*(-1+2*gc[0]+3*gc[1]-3*gc[1]*(gc[0]+gc[1]));
1141 funValue[2]=gc[1]*(-1.+3.*gc[0]+2.*gc[1]-3.*gc[0]*(gc[0]+gc[1]));
1142 funValue[3]=4*gc[0]*(1-gc[0]-4*gc[1]+3*gc[1]*(gc[0]+gc[1]));
1143 funValue[4]=4*gc[0]*gc[1]*(-2+3*(gc[0]+gc[1]));
1144 funValue[5]=4*gc[1]*(1-4*gc[0]-gc[1]+3*gc[0]*(gc[0]+gc[1]));
1145 funValue[6]=27*gc[0]*gc[1]*(1-gc[0]-gc[1]);
1146 SHAPE_FUN_MACRO_END;
1150 * Init Quadrangle Reference coordinates ans Shape function.
1153 void GaussInfo::quad4aInit()
1155 LOCAL_COORD_MACRO_BEGIN;
1157 coords[0] = QUAD4A_REF[0];
1158 coords[1] = QUAD4A_REF[1];
1161 coords[0] = QUAD4A_REF[2];
1162 coords[1] = QUAD4A_REF[3];
1165 coords[0] = QUAD4A_REF[4];
1166 coords[1] = QUAD4A_REF[5];
1169 coords[0] = QUAD4A_REF[6];
1170 coords[1] = QUAD4A_REF[7];
1172 LOCAL_COORD_MACRO_END;
1174 SHAPE_FUN_MACRO_BEGIN;
1175 funValue[0] = 0.25*(1.0 + gc[1])*(1.0 - gc[0]);
1176 funValue[1] = 0.25*(1.0 - gc[1])*(1.0 - gc[0]);
1177 funValue[2] = 0.25*(1.0 - gc[1])*(1.0 + gc[0]);
1178 funValue[3] = 0.25*(1.0 + gc[1])*(1.0 + gc[0]);
1179 SHAPE_FUN_MACRO_END;
1181 DEV_SHAPE_FUN_MACRO_BEGIN;
1183 devFunValue[0] = -0.25*(1.0 + gc[1]);
1184 devFunValue[1] = 0.25*(1.0 - gc[0]);
1186 devFunValue[2] = -0.25*(1.0 - gc[1]);
1187 devFunValue[3] = -0.25*(1.0 - gc[0]);
1189 devFunValue[4] = 0.25*(1.0 - gc[1]);
1190 devFunValue[5] = -0.25*(1.0 + gc[0]);
1192 devFunValue[6] = 0.25*(1.0 + gc[1]);
1193 devFunValue[7] = 0.25*(1.0 + gc[0]);
1195 DEV_SHAPE_FUN_MACRO_END;
1199 * Init Quadrangle Reference coordinates ans Shape function.
1202 void GaussInfo::quad4bInit()
1204 LOCAL_COORD_MACRO_BEGIN;
1206 coords[0] = QUAD4B_REF[0];
1207 coords[1] = QUAD4B_REF[1];
1210 coords[0] = QUAD4B_REF[2];
1211 coords[1] = QUAD4B_REF[3];
1214 coords[0] = QUAD4B_REF[4];
1215 coords[1] = QUAD4B_REF[5];
1218 coords[0] = QUAD4B_REF[6];
1219 coords[1] = QUAD4B_REF[7];
1221 LOCAL_COORD_MACRO_END;
1223 SHAPE_FUN_MACRO_BEGIN;
1224 funValue[0] = 0.25*(1.0 - gc[0])*(1.0 - gc[1]);
1225 funValue[1] = 0.25*(1.0 + gc[0])*(1.0 - gc[1]);
1226 funValue[2] = 0.25*(1.0 + gc[0])*(1.0 + gc[1]);
1227 funValue[3] = 0.25*(1.0 - gc[0])*(1.0 + gc[1]);
1228 SHAPE_FUN_MACRO_END;
1230 DEV_SHAPE_FUN_MACRO_BEGIN;
1232 devFunValue[0] = -0.25*(1.0 - gc[1]);
1233 devFunValue[1] = -0.25*(1.0 - gc[0]);
1235 devFunValue[2] = 0.25*(1.0 - gc[1]);
1236 devFunValue[3] = -0.25*(1.0 + gc[0]);
1238 devFunValue[4] = 0.25*(1.0 + gc[1]);
1239 devFunValue[5] = 0.25*(1.0 + gc[0]);
1241 devFunValue[6] = -0.25*(1.0 + gc[1]);
1242 devFunValue[7] = 0.25*(1.0 - gc[0]);
1244 DEV_SHAPE_FUN_MACRO_END;
1247 void GaussInfo::quad4cInit()
1249 LOCAL_COORD_MACRO_BEGIN;
1267 LOCAL_COORD_MACRO_END;
1269 SHAPE_FUN_MACRO_BEGIN;
1270 funValue[0] = 0.25*(1.0 - gc[0])*(1.0 - gc[1]);
1271 funValue[1] = 0.25*(1.0 - gc[0])*(1.0 + gc[1]);
1272 funValue[2] = 0.25*(1.0 + gc[0])*(1.0 + gc[1]);
1273 funValue[3] = 0.25*(1.0 + gc[0])*(1.0 - gc[1]);
1274 SHAPE_FUN_MACRO_END;
1276 DEV_SHAPE_FUN_MACRO_BEGIN;
1278 devFunValue[0] = -0.25*(1.0 - gc[1]);
1279 devFunValue[1] = -0.25*(1.0 - gc[0]);
1281 devFunValue[2] = -0.25*(1.0 + gc[1]);
1282 devFunValue[3] = 0.25*(1.0 - gc[0]);
1284 devFunValue[4] = 0.25*(1.0 + gc[0]);
1285 devFunValue[5] = 0.25*(1.0 + gc[1]);
1287 devFunValue[6] = 0.25*(1.0 - gc[1]);
1288 devFunValue[7] = -0.25*(1.0 + gc[0]);
1290 DEV_SHAPE_FUN_MACRO_END;
1294 * This shapefunc map is same as degenerated seg2aInit
1296 void GaussInfo::quad4DegSeg2Init()
1298 LOCAL_COORD_MACRO_BEGIN;
1315 LOCAL_COORD_MACRO_END;
1317 SHAPE_FUN_MACRO_BEGIN;
1318 funValue[0] = 0.5*(1.0 - gc[0]);
1319 funValue[1] = 0.5*(1.0 + gc[0]);
1322 SHAPE_FUN_MACRO_END;
1326 * Init Quadratic Quadrangle Reference coordinates ans Shape function.
1329 void GaussInfo::quad8aInit()
1331 LOCAL_COORD_MACRO_BEGIN;
1333 coords[0] = QUAD8A_REF[0];
1334 coords[1] = QUAD8A_REF[1];
1337 coords[0] = QUAD8A_REF[2];
1338 coords[1] = QUAD8A_REF[3];
1341 coords[0] = QUAD8A_REF[4];
1342 coords[1] = QUAD8A_REF[5];
1345 coords[0] = QUAD8A_REF[6];
1346 coords[1] = QUAD8A_REF[7];
1349 coords[0] = QUAD8A_REF[8];
1350 coords[1] = QUAD8A_REF[9];
1353 coords[0] = QUAD8A_REF[10];
1354 coords[1] = QUAD8A_REF[11];
1357 coords[0] = QUAD8A_REF[12];
1358 coords[1] = QUAD8A_REF[13];
1361 coords[0] = QUAD8A_REF[14];
1362 coords[1] = QUAD8A_REF[15];
1364 LOCAL_COORD_MACRO_END;
1366 SHAPE_FUN_MACRO_BEGIN;
1367 funValue[0] = 0.25*(1.0 + gc[1])*(1.0 - gc[0])*(gc[1] - gc[0] - 1.0);
1368 funValue[1] = 0.25*(1.0 - gc[1])*(1.0 - gc[0])*(-gc[1] - gc[0] - 1.0);
1369 funValue[2] = 0.25*(1.0 - gc[1])*(1.0 + gc[0])*(-gc[1] + gc[0] - 1.0);
1370 funValue[3] = 0.25*(1.0 + gc[1])*(1.0 + gc[0])*(gc[1] + gc[0] - 1.0);
1371 funValue[4] = 0.5*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 + gc[1]);
1372 funValue[5] = 0.5*(1.0 - gc[1])*(1.0 - gc[0])*(1.0 + gc[0]);
1373 funValue[6] = 0.5*(1.0 + gc[0])*(1.0 - gc[1])*(1.0 + gc[1]);
1374 funValue[7] = 0.5*(1.0 + gc[1])*(1.0 - gc[0])*(1.0 + gc[0]);
1375 SHAPE_FUN_MACRO_END;
1377 DEV_SHAPE_FUN_MACRO_BEGIN;
1379 devFunValue[0] = 0.25*(1.0 + gc[1])*(2*gc[0]-gc[1]);
1380 devFunValue[1] = 0.25*(1.0 - gc[0])*(2*gc[1]-gc[0]);
1382 devFunValue[2] = 0.25*(1.0 - gc[1])*(2*gc[0]+gc[1]);
1383 devFunValue[3] = 0.25*(1.0 - gc[0])*(2*gc[1]+gc[0]);
1385 devFunValue[4] = 0.25*(1.0 - gc[1])*(2*gc[0]-gc[1]);
1386 devFunValue[5] = 0.25*(1.0 + gc[0])*(2*gc[1]-gc[0]);
1388 devFunValue[6] = 0.25*(1.0 + gc[1])*(2*gc[0]+gc[1]);
1389 devFunValue[7] = 0.25*(1.0 + gc[0])*(2*gc[1]+gc[0]);
1391 devFunValue[8] = -0.5*(1.0 - gc[1])*(1.0 + gc[1]);
1392 devFunValue[9] = 0.5*(1.0 - gc[0])*(-2*gc[1]);
1394 devFunValue[10] = 0.5*(1.0 - gc[1])*(-2*gc[0]);
1395 devFunValue[11] = -0.5*(1.0 - gc[0])*(1.0 + gc[0]);
1397 devFunValue[12] = 0.5*(1.0 - gc[1])*(1.0 + gc[1]);
1398 devFunValue[13] = 0.5*(1.0 + gc[0])*(-2*gc[1]);
1400 devFunValue[14] = 0.5*(1.0 + gc[1])*(-2*gc[0]);
1401 devFunValue[15] = 0.5*(1.0 - gc[0])*(1.0 + gc[0]);
1403 DEV_SHAPE_FUN_MACRO_END;
1407 * Init Quadratic Quadrangle Reference coordinates ans Shape function.
1410 void GaussInfo::quad8bInit()
1412 LOCAL_COORD_MACRO_BEGIN;
1414 coords[0] = QUAD8B_REF[0];
1415 coords[1] = QUAD8B_REF[1];
1418 coords[0] = QUAD8B_REF[2];
1419 coords[1] = QUAD8B_REF[3];
1422 coords[0] = QUAD8B_REF[4];
1423 coords[1] = QUAD8B_REF[5];
1426 coords[0] = QUAD8B_REF[6];
1427 coords[1] = QUAD8B_REF[7];
1430 coords[0] = QUAD8B_REF[8];
1431 coords[1] = QUAD8B_REF[9];
1434 coords[0] = QUAD8B_REF[10];
1435 coords[1] = QUAD8B_REF[11];
1438 coords[0] = QUAD8B_REF[12];
1439 coords[1] = QUAD8B_REF[13];
1442 coords[0] = QUAD8B_REF[14];
1443 coords[1] = QUAD8B_REF[15];
1445 LOCAL_COORD_MACRO_END;
1447 SHAPE_FUN_MACRO_BEGIN;
1448 funValue[0] = 0.25*(1.0 - gc[0])*(1.0 - gc[1])*(-1.0 - gc[0] - gc[1]);
1449 funValue[1] = 0.25*(1.0 + gc[0])*(1.0 - gc[1])*(-1.0 + gc[0] - gc[1]);
1450 funValue[2] = 0.25*(1.0 + gc[0])*(1.0 + gc[1])*(-1.0 + gc[0] + gc[1]);
1451 funValue[3] = 0.25*(1.0 - gc[0])*(1.0 + gc[1])*(-1.0 - gc[0] + gc[1]);
1452 funValue[4] = 0.5*(1.0 - gc[0]*gc[0])*(1.0 - gc[1]);
1453 funValue[5] = 0.5*(1.0 - gc[1]*gc[1])*(1.0 + gc[0]);
1454 funValue[6] = 0.5*(1.0 - gc[0]*gc[0])*(1.0 + gc[1]);
1455 funValue[7] = 0.5*(1.0 - gc[1]*gc[1])*(1.0 - gc[0]);
1456 SHAPE_FUN_MACRO_END;
1458 DEV_SHAPE_FUN_MACRO_BEGIN;
1460 devFunValue[0] = 0.25*(1.0 - gc[1])*(2*gc[0] + gc[1] );
1461 devFunValue[1] = 0.25*(1.0 - gc[0])*(2*gc[1] + gc[0] );
1463 devFunValue[2] = 0.25*(1.0 - gc[1])*(2*gc[0] - gc[1] );
1464 devFunValue[3] = 0.25*(1.0 + gc[0])*(2*gc[1] - gc[0] );
1466 devFunValue[4] = 0.25*(1.0 + gc[1])*(2*gc[0] + gc[1]);
1467 devFunValue[5] = 0.25*(1.0 + gc[0])*(2*gc[1] + gc[0]);
1469 devFunValue[6] = 0.25*( 1.0 + gc[1])*(2*gc[0] - gc[1] );
1470 devFunValue[7] = 0.25*(1.0 - gc[0])*(2*gc[1] - gc[0]);
1472 devFunValue[8] = -(1.0 - gc[1])*gc[0];
1473 devFunValue[9] = -0.5*(1.0 - gc[0]*gc[0]);
1475 devFunValue[10] = 0.5*(1.0 - gc[1]*gc[1]);
1476 devFunValue[11] = -(1.0 + gc[0])*gc[1];
1478 devFunValue[12] = -(1.0 + gc[1])*gc[0];
1479 devFunValue[13] = 0.5*(1.0 - gc[0]*gc[0]);
1481 devFunValue[14] = -0.5*(1.0 - gc[1]*gc[1]);
1482 devFunValue[15] = -(1.0 - gc[0])*gc[1];
1484 DEV_SHAPE_FUN_MACRO_END;
1487 void GaussInfo::quad9aInit()
1489 LOCAL_COORD_MACRO_BEGIN;
1491 coords[0] = QUAD9A_REF[0];
1492 coords[1] = QUAD9A_REF[1];
1495 coords[0] = QUAD9A_REF[2];
1496 coords[1] = QUAD9A_REF[3];
1499 coords[0] = QUAD9A_REF[4];
1500 coords[1] = QUAD9A_REF[5];
1503 coords[0] = QUAD9A_REF[6];
1504 coords[1] = QUAD9A_REF[7];
1507 coords[0] = QUAD9A_REF[8];
1508 coords[1] = QUAD9A_REF[9];
1511 coords[0] = QUAD9A_REF[10];
1512 coords[1] = QUAD9A_REF[11];
1515 coords[0] = QUAD9A_REF[12];
1516 coords[1] = QUAD9A_REF[13];
1519 coords[0] = QUAD9A_REF[14];
1520 coords[1] = QUAD9A_REF[15];
1523 coords[0] = QUAD9A_REF[16];
1524 coords[1] = QUAD9A_REF[17];
1526 LOCAL_COORD_MACRO_END;
1528 SHAPE_FUN_MACRO_BEGIN;
1529 funValue[0] = 0.25*gc[0]*gc[1]*(gc[0]-1.)*(gc[1]-1.);
1530 funValue[1] = 0.25*gc[0]*gc[1]*(gc[0]+1.)*(gc[1]-1.);
1531 funValue[2] = 0.25*gc[0]*gc[1]*(gc[0]+1.)*(gc[1]+1.);
1532 funValue[3] = 0.25*gc[0]*gc[1]*(gc[0]-1.)*(gc[1]+1.);
1533 funValue[4] = 0.5*(1.-gc[0]*gc[0])*gc[1]*(gc[1]-1.);
1534 funValue[5] = 0.5*gc[0]*(gc[0]+1.)*(1.-gc[1]*gc[1]);
1535 funValue[6] = 0.5*(1.-gc[0]*gc[0])*gc[1]*(gc[1]+1.);
1536 funValue[7] = 0.5*gc[0]*(gc[0]-1.)*(1.-gc[1]*gc[1]);
1537 funValue[8] = (1.-gc[0]*gc[0])*(1.-gc[1]*gc[1]);
1538 SHAPE_FUN_MACRO_END;
1542 * Init Tetrahedron Reference coordinates ans Shape function.
1545 void GaussInfo::tetra4aInit()
1547 LOCAL_COORD_MACRO_BEGIN;
1549 coords[0] = TETRA4A_REF[0];
1550 coords[1] = TETRA4A_REF[1];
1551 coords[2] = TETRA4A_REF[2];
1554 coords[0] = TETRA4A_REF[3];
1555 coords[1] = TETRA4A_REF[4];
1556 coords[2] = TETRA4A_REF[5];
1559 coords[0] = TETRA4A_REF[6];
1560 coords[1] = TETRA4A_REF[7];
1561 coords[2] = TETRA4A_REF[8];
1564 coords[0] = TETRA4A_REF[9];
1565 coords[1] = TETRA4A_REF[10];
1566 coords[2] = TETRA4A_REF[11];
1568 LOCAL_COORD_MACRO_END;
1570 SHAPE_FUN_MACRO_BEGIN;
1571 funValue[0] = gc[1];
1572 funValue[1] = gc[2];
1573 funValue[2] = 1.0 - gc[0] - gc[1] - gc[2];
1574 funValue[3] = gc[0];
1575 SHAPE_FUN_MACRO_END;
1579 * Init Tetrahedron Reference coordinates ans Shape function.
1582 void GaussInfo::tetra4bInit()
1584 LOCAL_COORD_MACRO_BEGIN;
1586 coords[0] = TETRA4B_REF[0];
1587 coords[1] = TETRA4B_REF[1];
1588 coords[2] = TETRA4B_REF[2];
1591 coords[0] = TETRA4B_REF[3];
1592 coords[1] = TETRA4B_REF[4];
1593 coords[2] = TETRA4B_REF[5];
1596 coords[0] = TETRA4B_REF[6];
1597 coords[1] = TETRA4B_REF[7];
1598 coords[2] = TETRA4B_REF[8];
1601 coords[0] = TETRA4B_REF[9];
1602 coords[1] = TETRA4B_REF[10];
1603 coords[2] = TETRA4B_REF[11];
1605 LOCAL_COORD_MACRO_END;
1607 SHAPE_FUN_MACRO_BEGIN;
1608 funValue[0] = gc[1];
1609 funValue[2] = gc[2];
1610 funValue[1] = 1.0 - gc[0] - gc[1] - gc[2];
1611 funValue[3] = gc[0];
1612 SHAPE_FUN_MACRO_END;
1616 * Init Quadratic Tetrahedron Reference coordinates ans Shape function.
1619 void GaussInfo::tetra10aInit()
1621 LOCAL_COORD_MACRO_BEGIN;
1623 coords[0] = TETRA10A_REF[0];
1624 coords[1] = TETRA10A_REF[1];
1625 coords[2] = TETRA10A_REF[2];
1628 coords[0] = TETRA10A_REF[3];
1629 coords[1] = TETRA10A_REF[4];
1630 coords[2] = TETRA10A_REF[5];
1633 coords[0] = TETRA10A_REF[6];
1634 coords[1] = TETRA10A_REF[7];
1635 coords[2] = TETRA10A_REF[8];
1638 coords[0] = TETRA10A_REF[9];
1639 coords[1] = TETRA10A_REF[10];
1640 coords[2] = TETRA10A_REF[11];
1643 coords[0] = TETRA10A_REF[12];
1644 coords[1] = TETRA10A_REF[13];
1645 coords[2] = TETRA10A_REF[14];
1648 coords[0] = TETRA10A_REF[15];
1649 coords[1] = TETRA10A_REF[16];
1650 coords[2] = TETRA10A_REF[17];
1653 coords[0] = TETRA10A_REF[18];
1654 coords[1] = TETRA10A_REF[19];
1655 coords[2] = TETRA10A_REF[20];
1658 coords[0] = TETRA10A_REF[21];
1659 coords[1] = TETRA10A_REF[22];
1660 coords[2] = TETRA10A_REF[23];
1663 coords[0] = TETRA10A_REF[24];
1664 coords[1] = TETRA10A_REF[25];
1665 coords[2] = TETRA10A_REF[26];
1668 coords[0] = TETRA10A_REF[27];
1669 coords[1] = TETRA10A_REF[28];
1670 coords[2] = TETRA10A_REF[29];
1672 LOCAL_COORD_MACRO_END;
1674 SHAPE_FUN_MACRO_BEGIN;
1675 funValue[0] = gc[1]*(2.0*gc[1] - 1.0);
1676 funValue[1] = gc[2]*(2.0*gc[2] - 1.0);
1677 funValue[2] = (1.0 - gc[0] - gc[1] - gc[2])*(1.0 - 2.0*gc[0] - 2.0*gc[1] - 2.0*gc[2]);
1678 funValue[3] = gc[0]*(2.0*gc[0] - 1.0);
1679 funValue[4] = 4.0*gc[1]*gc[2];
1680 funValue[5] = 4.0*gc[2]*(1.0 - gc[0] - gc[1] - gc[2]);
1681 funValue[6] = 4.0*gc[1]*(1.0 - gc[0] - gc[1] - gc[2]);
1682 funValue[7] = 4.0*gc[0]*gc[1];
1683 funValue[8] = 4.0*gc[0]*gc[2];
1684 funValue[9] = 4.0*gc[0]*(1.0 - gc[0] - gc[1] - gc[2]);
1685 SHAPE_FUN_MACRO_END;
1689 * Init Quadratic Tetrahedron Reference coordinates ans Shape function.
1692 void GaussInfo::tetra10bInit()
1694 LOCAL_COORD_MACRO_BEGIN;
1696 coords[0] = TETRA10B_REF[0];
1697 coords[1] = TETRA10B_REF[1];
1698 coords[2] = TETRA10B_REF[2];
1701 coords[0] = TETRA10B_REF[3];
1702 coords[1] = TETRA10B_REF[4];
1703 coords[2] = TETRA10B_REF[5];
1706 coords[0] = TETRA10B_REF[6];
1707 coords[1] = TETRA10B_REF[7];
1708 coords[2] = TETRA10B_REF[8];
1711 coords[0] = TETRA10B_REF[9];
1712 coords[1] = TETRA10B_REF[10];
1713 coords[2] = TETRA10B_REF[11];
1716 coords[0] = TETRA10B_REF[12];
1717 coords[1] = TETRA10B_REF[13];
1718 coords[2] = TETRA10B_REF[14];
1721 coords[0] = TETRA10B_REF[15];
1722 coords[1] = TETRA10B_REF[16];
1723 coords[2] = TETRA10B_REF[17];
1726 coords[0] = TETRA10B_REF[18];
1727 coords[1] = TETRA10B_REF[19];
1728 coords[2] = TETRA10B_REF[20];
1731 coords[0] = TETRA10B_REF[21];
1732 coords[1] = TETRA10B_REF[22];
1733 coords[2] = TETRA10B_REF[23];
1736 coords[0] = TETRA10B_REF[24];
1737 coords[1] = TETRA10B_REF[25];
1738 coords[2] = TETRA10B_REF[26];
1741 coords[0] = TETRA10B_REF[27];
1742 coords[1] = TETRA10B_REF[28];
1743 coords[2] = TETRA10B_REF[29];
1745 LOCAL_COORD_MACRO_END;
1746 SHAPE_FUN_MACRO_BEGIN;
1747 funValue[0] = gc[1]*(2.0*gc[1] - 1.0);
1748 funValue[2] = gc[2]*(2.0*gc[2] - 1.0);
1749 funValue[1] = (1.0 - gc[0] - gc[1] - gc[2])*(1.0 - 2.0*gc[0] - 2.0*gc[1] - 2.0*gc[2]);
1750 funValue[3] = gc[0]*(2.0*gc[0] - 1.0);
1751 funValue[6] = 4.0*gc[1]*gc[2];
1752 funValue[5] = 4.0*gc[2]*(1.0 - gc[0] - gc[1] - gc[2]);
1753 funValue[4] = 4.0*gc[1]*(1.0 - gc[0] - gc[1] - gc[2]);
1754 funValue[7] = 4.0*gc[0]*gc[1];
1755 funValue[9] = 4.0*gc[0]*gc[2];
1756 funValue[8] = 4.0*gc[0]*(1.0 - gc[0] - gc[1] - gc[2]);
1757 SHAPE_FUN_MACRO_END;
1761 * Init Pyramid Reference coordinates ans Shape function.
1764 void GaussInfo::pyra5aInit()
1766 LOCAL_COORD_MACRO_BEGIN;
1768 coords[0] = PYRA5A_REF[0];
1769 coords[1] = PYRA5A_REF[1];
1770 coords[2] = PYRA5A_REF[2];
1773 coords[0] = PYRA5A_REF[3];
1774 coords[1] = PYRA5A_REF[4];
1775 coords[2] = PYRA5A_REF[5];
1778 coords[0] = PYRA5A_REF[6];
1779 coords[1] = PYRA5A_REF[7];
1780 coords[2] = PYRA5A_REF[8];
1783 coords[0] = PYRA5A_REF[9];
1784 coords[1] = PYRA5A_REF[10];
1785 coords[2] = PYRA5A_REF[11];
1788 coords[0] = PYRA5A_REF[12];
1789 coords[1] = PYRA5A_REF[13];
1790 coords[2] = PYRA5A_REF[14];
1792 LOCAL_COORD_MACRO_END;
1794 SHAPE_FUN_MACRO_BEGIN;
1795 funValue[0] = 0.25*(-gc[0] + gc[1] - 1.0)*(-gc[0] - gc[1] - 1.0)*(1.0 - gc[2]);
1796 funValue[1] = 0.25*(-gc[0] - gc[1] - 1.0)*(+gc[0] - gc[1] - 1.0)*(1.0 - gc[2]);
1797 funValue[2] = 0.25*(+gc[0] + gc[1] - 1.0)*(+gc[0] - gc[1] - 1.0)*(1.0 - gc[2]);
1798 funValue[3] = 0.25*(+gc[0] + gc[1] - 1.0)*(-gc[0] + gc[1] - 1.0)*(1.0 - gc[2]);
1799 funValue[4] = gc[2];
1800 SHAPE_FUN_MACRO_END;
1802 DEV_SHAPE_FUN_MACRO_BEGIN;
1804 devFunValue[0] = 0.5*(gc[0]+1)*(1.0 - gc[2]);
1805 devFunValue[1] = -0.5*gc[1]*(1.0 - gc[2]);
1806 devFunValue[2] = -0.25*(-gc[0] + gc[1] - 1.0)*(-gc[0] - gc[1] - 1.0);
1808 devFunValue[3] = -0.5*gc[0]*(1.0 - gc[2]);
1809 devFunValue[4] = 0.5*(gc[1]+1)*(1.0 - gc[2]);
1810 devFunValue[5] = -0.25*(-gc[0] - gc[1] - 1.0)*(+gc[0] - gc[1] - 1.0);
1812 devFunValue[6] = 0.5*(gc[0]-1)*(1.0 - gc[2]);
1813 devFunValue[7] = -0.5*gc[1]*(1.0 - gc[2]);
1814 devFunValue[8] = -0.25*(+gc[0] + gc[1] - 1.0)*(+gc[0] - gc[1] - 1.0);
1816 devFunValue[9] = -0.5*gc[0]*(1.0 - gc[2]);
1817 devFunValue[10] = 0.5*(1*gc[1]-1)*(1.0 - gc[2]);
1818 devFunValue[11] = -0.25*(+gc[0] + gc[1] - 1.0)*(-gc[0] + gc[1] - 1.0);
1820 devFunValue[12] = 0.0;
1821 devFunValue[13] = 0.0;
1822 devFunValue[14] = 1.0;
1824 DEV_SHAPE_FUN_MACRO_END;
1827 * Init Pyramid Reference coordinates ans Shape function.
1830 void GaussInfo::pyra5bInit()
1832 LOCAL_COORD_MACRO_BEGIN;
1834 coords[0] = PYRA5B_REF[0];
1835 coords[1] = PYRA5B_REF[1];
1836 coords[2] = PYRA5B_REF[2];
1839 coords[0] = PYRA5B_REF[3];
1840 coords[1] = PYRA5B_REF[4];
1841 coords[2] = PYRA5B_REF[5];
1844 coords[0] = PYRA5B_REF[6];
1845 coords[1] = PYRA5B_REF[7];
1846 coords[2] = PYRA5B_REF[8];
1849 coords[0] = PYRA5B_REF[9];
1850 coords[1] = PYRA5B_REF[10];
1851 coords[2] = PYRA5B_REF[11];
1854 coords[0] = PYRA5B_REF[12];
1855 coords[1] = PYRA5B_REF[13];
1856 coords[2] = PYRA5B_REF[14];
1858 LOCAL_COORD_MACRO_END;
1860 SHAPE_FUN_MACRO_BEGIN;
1861 funValue[0] = 0.25*(-gc[0] + gc[1] - 1.0)*(-gc[0] - gc[1] - 1.0)*(1.0 - gc[2]);
1862 funValue[3] = 0.25*(-gc[0] - gc[1] - 1.0)*(+gc[0] - gc[1] - 1.0)*(1.0 - gc[2]);
1863 funValue[2] = 0.25*(+gc[0] + gc[1] - 1.0)*(+gc[0] - gc[1] - 1.0)*(1.0 - gc[2]);
1864 funValue[1] = 0.25*(+gc[0] + gc[1] - 1.0)*(-gc[0] + gc[1] - 1.0)*(1.0 - gc[2]);
1865 funValue[4] = gc[2];
1866 SHAPE_FUN_MACRO_END;
1870 * Init Quadratic Pyramid Reference coordinates ans Shape function.
1873 void GaussInfo::pyra13aInit()
1875 LOCAL_COORD_MACRO_BEGIN;
1877 coords[0] = PYRA13A_REF[0];
1878 coords[1] = PYRA13A_REF[1];
1879 coords[2] = PYRA13A_REF[2];
1882 coords[0] = PYRA13A_REF[3];
1883 coords[1] = PYRA13A_REF[4];
1884 coords[2] = PYRA13A_REF[5];
1887 coords[0] = PYRA13A_REF[6];
1888 coords[1] = PYRA13A_REF[7];
1889 coords[2] = PYRA13A_REF[8];
1892 coords[0] = PYRA13A_REF[9];
1893 coords[1] = PYRA13A_REF[10];
1894 coords[2] = PYRA13A_REF[11];
1897 coords[0] = PYRA13A_REF[12];
1898 coords[1] = PYRA13A_REF[13];
1899 coords[2] = PYRA13A_REF[14];
1902 coords[0] = PYRA13A_REF[15];
1903 coords[1] = PYRA13A_REF[16];
1904 coords[2] = PYRA13A_REF[17];
1907 coords[0] = PYRA13A_REF[18];
1908 coords[1] = PYRA13A_REF[19];
1909 coords[2] = PYRA13A_REF[20];
1912 coords[0] = PYRA13A_REF[21];
1913 coords[1] = PYRA13A_REF[22];
1914 coords[2] = PYRA13A_REF[23];
1917 coords[0] = PYRA13A_REF[24];
1918 coords[1] = PYRA13A_REF[25];
1919 coords[2] = PYRA13A_REF[26];
1922 coords[0] = PYRA13A_REF[27];
1923 coords[1] = PYRA13A_REF[28];
1924 coords[2] = PYRA13A_REF[29];
1927 coords[0] = PYRA13A_REF[30];
1928 coords[1] = PYRA13A_REF[31];
1929 coords[2] = PYRA13A_REF[32];
1932 coords[0] = PYRA13A_REF[33];
1933 coords[1] = PYRA13A_REF[34];
1934 coords[2] = PYRA13A_REF[35];
1937 coords[0] = PYRA13A_REF[36];
1938 coords[1] = PYRA13A_REF[37];
1939 coords[2] = PYRA13A_REF[38];
1941 LOCAL_COORD_MACRO_END;
1943 SHAPE_FUN_MACRO_BEGIN;
1944 funValue[0] = 0.5*(-gc[0] + gc[1] + gc[2] - 1.0)*(-gc[0] - gc[1] + gc[2] - 1.0)*
1945 (gc[0] - 0.5)/(1.0 - gc[2]);
1946 funValue[1] = 0.5*(-gc[0] - gc[1] + gc[2] - 1.0)*(+gc[0] - gc[1] + gc[2] - 1.0)*
1947 (gc[1] - 0.5)/(1.0 - gc[2]);
1948 funValue[2] = 0.5*(+gc[0] - gc[1] + gc[2] - 1.0)*(+gc[0] + gc[1] + gc[2] - 1.0)*
1949 (-gc[0] - 0.5)/(1.0 - gc[2]);
1950 funValue[3] = 0.5*(+gc[0] + gc[1] + gc[2] - 1.0)*(-gc[0] + gc[1] + gc[2] - 1.0)*
1951 (-gc[1] - 0.5)/(1.0 - gc[2]);
1953 funValue[4] = 2.0*gc[2]*(gc[2] - 0.5);
1955 funValue[5] = 0.5*(-gc[0] + gc[1] + gc[2] - 1.0)*(-gc[0] - gc[1] + gc[2] - 1.0)*
1956 (gc[0] - gc[1] + gc[2] - 1.0)/(1.0 - gc[2]);
1957 funValue[6] = 0.5*(-gc[0] - gc[1] + gc[2] - 1.0)*(gc[0] - gc[1] + gc[2] - 1.0)*
1958 (gc[0] + gc[1] + gc[2] - 1.0)/(1.0 - gc[2]);
1959 funValue[7] = 0.5*(gc[0] - gc[1] + gc[2] - 1.0)*(gc[0] + gc[1] + gc[2] - 1.0)*
1960 (-gc[0] + gc[1] + gc[2] - 1.0)/(1.0 - gc[2]);
1961 funValue[8] = 0.5*(gc[0] + gc[1] + gc[2] - 1.0)*(-gc[0] + gc[1] + gc[2] - 1.0)*
1962 (-gc[0] - gc[1] + gc[2] - 1.0)/(1.0 - gc[2]);
1964 funValue[9] = 0.5*gc[2]*(-gc[0] + gc[1] + gc[2] - 1.0)*(-gc[0] - gc[1] + gc[2] - 1.0)/
1966 funValue[10] = 0.5*gc[2]*(-gc[0] - gc[1] + gc[2] - 1.0)*(gc[0] - gc[1] + gc[2] - 1.0)/
1968 funValue[11] = 0.5*gc[2]*(gc[0] - gc[1] + gc[2] - 1.0)*(gc[0] + gc[1] + gc[2] - 1.0)/
1970 funValue[12] = 0.5*gc[2]*(gc[0] + gc[1] + gc[2] - 1.0)*(-gc[0] + gc[1] + gc[2] - 1.0)/
1972 SHAPE_FUN_MACRO_END;
1976 * Init Quadratic Pyramid Reference coordinates ans Shape function.
1979 void GaussInfo::pyra13bInit()
1981 LOCAL_COORD_MACRO_BEGIN;
1983 coords[0] = PYRA13B_REF[0];
1984 coords[1] = PYRA13B_REF[1];
1985 coords[2] = PYRA13B_REF[2];
1988 coords[0] = PYRA13B_REF[3];
1989 coords[1] = PYRA13B_REF[4];
1990 coords[2] = PYRA13B_REF[5];
1993 coords[0] = PYRA13B_REF[6];
1994 coords[1] = PYRA13B_REF[7];
1995 coords[2] = PYRA13B_REF[8];
1998 coords[0] = PYRA13B_REF[9];
1999 coords[1] = PYRA13B_REF[10];
2000 coords[2] = PYRA13B_REF[11];
2003 coords[0] = PYRA13B_REF[12];
2004 coords[1] = PYRA13B_REF[13];
2005 coords[2] = PYRA13B_REF[14];
2008 coords[0] = PYRA13B_REF[15];
2009 coords[1] = PYRA13B_REF[16];
2010 coords[2] = PYRA13B_REF[17];
2013 coords[0] = PYRA13B_REF[18];
2014 coords[1] = PYRA13B_REF[19];
2015 coords[2] = PYRA13B_REF[20];
2018 coords[0] = PYRA13B_REF[21];
2019 coords[1] = PYRA13B_REF[22];
2020 coords[2] = PYRA13B_REF[23];
2023 coords[0] = PYRA13B_REF[24];
2024 coords[1] = PYRA13B_REF[25];
2025 coords[2] = PYRA13B_REF[26];
2028 coords[0] = PYRA13B_REF[27];
2029 coords[1] = PYRA13B_REF[28];
2030 coords[2] = PYRA13B_REF[29];
2033 coords[0] = PYRA13B_REF[30];
2034 coords[1] = PYRA13B_REF[31];
2035 coords[2] = PYRA13B_REF[32];
2038 coords[0] = PYRA13B_REF[33];
2039 coords[1] = PYRA13B_REF[34];
2040 coords[2] = PYRA13B_REF[35];
2043 coords[0] = PYRA13B_REF[36];
2044 coords[1] = PYRA13B_REF[37];
2045 coords[2] = PYRA13B_REF[38];
2047 LOCAL_COORD_MACRO_END;
2049 SHAPE_FUN_MACRO_BEGIN;
2050 funValue[0] =0.5*(-gc[0]+gc[1]+gc[2]-1.0)*(-gc[0]-gc[1]+gc[2]-1.0)*(gc[0]-0.5)/(1.0-gc[2]);
2051 funValue[1] =0.5*(+gc[0]+gc[1]+gc[2]-1.0)*(-gc[0]+gc[1]+gc[2]-1.0)*(-gc[1]-0.5)/(1.0-gc[2]);
2052 funValue[2] =0.5*(+gc[0]-gc[1]+gc[2]-1.0)*(+gc[0]+gc[1]+gc[2]-1.0)*(-gc[0]-0.5)/(1.0-gc[2]);
2053 funValue[3] =0.5*(-gc[0]-gc[1]+gc[2]-1.0)*(+gc[0]-gc[1]+gc[2]-1.0)*(gc[1]-0.5)/(1.0-gc[2]);
2055 funValue[4] =2.*gc[2]*(gc[2]-0.5);
2057 funValue[5] =-0.5*(gc[0]+gc[1]+gc[2]-1.0)*(-gc[0]+gc[1]+gc[2]-1.0)*(-gc[0]-gc[1]+gc[2]-1.0)/(1.0-gc[2]);
2058 funValue[6] =-0.5*(gc[0]-gc[1]+gc[2]-1.0)*(gc[0]+gc[1]+gc[2]-1.0)*(-gc[0]+gc[1]+gc[2]-1.0)/(1.0-gc[2]);
2059 funValue[7] =-0.5*(-gc[0]-gc[1]+gc[2]-1.0)*(gc[0]-gc[1]+gc[2]-1.0)*(gc[0]+gc[1]+gc[2]-1.0)/(1.0-gc[2]);
2060 funValue[8] =-0.5*(-gc[0]+gc[1]+gc[2]-1.0)*(-gc[0]-gc[1]+gc[2]-1.0)*(gc[0]-gc[1]+gc[2]-1.0)/(1.0-gc[2]);
2062 funValue[9] =gc[2]*(-gc[0]+gc[1]+gc[2]-1.0)*(-gc[0]-gc[1]+gc[2]-1.0)/(1.0-gc[2]);
2063 funValue[10]=gc[2]*(gc[0]+gc[1]+gc[2]-1.0)*(-gc[0]+gc[1]+gc[2]-1.0)/(1.0-gc[2]);
2064 funValue[11]=gc[2]*(gc[0]-gc[1]+gc[2]-1.0)*(gc[0]+gc[1]+gc[2]-1.0)/(1.0-gc[2]);
2065 funValue[12]=gc[2]*(-gc[0]-gc[1]+gc[2]-1.0)*(gc[0]-gc[1]+gc[2]-1.0)/(1.0-gc[2]);
2067 SHAPE_FUN_MACRO_END;
2072 * Init Pentahedron Reference coordinates and Shape function.
2075 void GaussInfo::penta6aInit()
2077 LOCAL_COORD_MACRO_BEGIN;
2079 coords[0] = PENTA6A_REF[0];
2080 coords[1] = PENTA6A_REF[1];
2081 coords[2] = PENTA6A_REF[2];
2084 coords[0] = PENTA6A_REF[3];
2085 coords[1] = PENTA6A_REF[4];
2086 coords[2] = PENTA6A_REF[5];
2089 coords[0] = PENTA6A_REF[6];
2090 coords[1] = PENTA6A_REF[7];
2091 coords[2] = PENTA6A_REF[8];
2094 coords[0] = PENTA6A_REF[9];
2095 coords[1] = PENTA6A_REF[10];
2096 coords[2] = PENTA6A_REF[11];
2099 coords[0] = PENTA6A_REF[12];
2100 coords[1] = PENTA6A_REF[13];
2101 coords[2] = PENTA6A_REF[14];
2104 coords[0] = PENTA6A_REF[15];
2105 coords[1] = PENTA6A_REF[16];
2106 coords[2] = PENTA6A_REF[17];
2108 LOCAL_COORD_MACRO_END;
2110 SHAPE_FUN_MACRO_BEGIN;
2111 funValue[0] = 0.5*gc[1]*(1.0 - gc[0]);
2112 funValue[1] = 0.5*gc[2]*(1.0 - gc[0]);
2113 funValue[2] = 0.5*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2115 funValue[3] = 0.5*gc[1]*(gc[0] + 1.0);
2116 funValue[4] = 0.5*gc[2]*(gc[0] + 1.0);
2117 funValue[5] = 0.5*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2118 SHAPE_FUN_MACRO_END;
2120 DEV_SHAPE_FUN_MACRO_BEGIN;
2122 devFunValue[0] = 0.5*gc[1]*(-1.0);
2123 devFunValue[1] = 0.5*(1.0 - gc[0]);
2124 devFunValue[2] = 0.0;
2126 devFunValue[3] = 0.5*gc[2]*(-1.0);
2127 devFunValue[4] = 0.0;
2128 devFunValue[5] = 0.5*(1.0 - gc[0]);
2130 devFunValue[6] = 0.5*(1.0 - gc[1] - gc[2])*(-1.0);
2131 devFunValue[7] = 0.5*(-1.0)*(1.0 - gc[0]);
2132 devFunValue[8] = 0.5*(-1.0)*(1.0 - gc[0]);
2134 devFunValue[9] = 0.5*gc[1];
2135 devFunValue[10] = 0.5*(gc[0] + 1.0);
2136 devFunValue[11] = 0.0;
2138 devFunValue[12] = 0.5*gc[2];
2139 devFunValue[13] = 0.0;
2140 devFunValue[14] = 0.5*(gc[0] + 1.0);
2142 devFunValue[15] = 0.5*(1.0 - gc[1] - gc[2]);
2143 devFunValue[16] = 0.5*(-1.0)*(1.0 + gc[0]);
2144 devFunValue[17] = 0.5*(-1.0)*(1.0 + gc[0]);
2146 DEV_SHAPE_FUN_MACRO_END;
2150 * Init Pentahedron Reference coordinates and Shape function.
2153 void GaussInfo::penta6bInit()
2155 LOCAL_COORD_MACRO_BEGIN;
2157 coords[0] = PENTA6B_REF[0];
2158 coords[1] = PENTA6B_REF[1];
2159 coords[2] = PENTA6B_REF[2];
2162 coords[0] = PENTA6B_REF[3];
2163 coords[1] = PENTA6B_REF[4];
2164 coords[2] = PENTA6B_REF[5];
2167 coords[0] = PENTA6B_REF[6];
2168 coords[1] = PENTA6B_REF[7];
2169 coords[2] = PENTA6B_REF[8];
2172 coords[0] = PENTA6B_REF[9];
2173 coords[1] = PENTA6B_REF[10];
2174 coords[2] = PENTA6B_REF[11];
2177 coords[0] = PENTA6B_REF[12];
2178 coords[1] = PENTA6B_REF[13];
2179 coords[2] = PENTA6B_REF[14];
2182 coords[0] = PENTA6B_REF[15];
2183 coords[1] = PENTA6B_REF[16];
2184 coords[2] = PENTA6B_REF[17];
2186 LOCAL_COORD_MACRO_END;
2188 SHAPE_FUN_MACRO_BEGIN;
2189 funValue[0] = 0.5*gc[1]*(1.0 - gc[0]);
2190 funValue[2] = 0.5*gc[2]*(1.0 - gc[0]);
2191 funValue[1] = 0.5*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2192 funValue[3] = 0.5*gc[1]*(gc[0] + 1.0);
2193 funValue[5] = 0.5*gc[2]*(gc[0] + 1.0);
2194 funValue[4] = 0.5*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2195 SHAPE_FUN_MACRO_END;
2199 * This shapefunc map is same as degenerated tria3aInit
2201 void GaussInfo::penta6DegTria3aInit()
2203 LOCAL_COORD_MACRO_BEGIN;
2234 LOCAL_COORD_MACRO_END;
2236 SHAPE_FUN_MACRO_BEGIN;
2237 funValue[0] = 0.5*(1.0 + gc[1]);
2238 funValue[1] = -0.5*(gc[0] + gc[1]);
2239 funValue[2] = 0.5*(1.0 + gc[0]);
2243 SHAPE_FUN_MACRO_END;
2247 * This shapefunc map is same as degenerated tria3bInit
2249 void GaussInfo::penta6DegTria3bInit()
2251 LOCAL_COORD_MACRO_BEGIN;
2282 LOCAL_COORD_MACRO_END;
2284 SHAPE_FUN_MACRO_BEGIN;
2285 funValue[0] = 1.0 - gc[0] - gc[1];
2286 funValue[1] = gc[0];
2287 funValue[2] = gc[1];
2291 SHAPE_FUN_MACRO_END;
2295 * Init Pentahedron Reference coordinates and Shape function.
2298 void GaussInfo::penta15aInit()
2300 LOCAL_COORD_MACRO_BEGIN;
2302 coords[0] = PENTA15A_REF[0];
2303 coords[1] = PENTA15A_REF[1];
2304 coords[2] = PENTA15A_REF[2];
2307 coords[0] = PENTA15A_REF[3];
2308 coords[1] = PENTA15A_REF[4];
2309 coords[2] = PENTA15A_REF[5];
2312 coords[0] = PENTA15A_REF[6];
2313 coords[1] = PENTA15A_REF[7];
2314 coords[2] = PENTA15A_REF[8];
2317 coords[0] = PENTA15A_REF[9];
2318 coords[1] = PENTA15A_REF[10];
2319 coords[2] = PENTA15A_REF[11];
2322 coords[0] = PENTA15A_REF[12];
2323 coords[1] = PENTA15A_REF[13];
2324 coords[2] = PENTA15A_REF[14];
2327 coords[0] = PENTA15A_REF[15];
2328 coords[1] = PENTA15A_REF[16];
2329 coords[2] = PENTA15A_REF[17];
2332 coords[0] = PENTA15A_REF[18];
2333 coords[1] = PENTA15A_REF[19];
2334 coords[2] = PENTA15A_REF[20];
2337 coords[0] = PENTA15A_REF[21];
2338 coords[1] = PENTA15A_REF[22];
2339 coords[2] = PENTA15A_REF[23];
2342 coords[0] = PENTA15A_REF[24];
2343 coords[1] = PENTA15A_REF[25];
2344 coords[2] = PENTA15A_REF[26];
2347 coords[0] = PENTA15A_REF[27];
2348 coords[1] = PENTA15A_REF[28];
2349 coords[2] = PENTA15A_REF[29];
2352 coords[0] = PENTA15A_REF[30];
2353 coords[1] = PENTA15A_REF[31];
2354 coords[2] = PENTA15A_REF[32];
2357 coords[0] = PENTA15A_REF[33];
2358 coords[1] = PENTA15A_REF[34];
2359 coords[2] = PENTA15A_REF[35];
2362 coords[0] = PENTA15A_REF[36];
2363 coords[1] = PENTA15A_REF[37];
2364 coords[2] = PENTA15A_REF[38];
2367 coords[0] = PENTA15A_REF[39];
2368 coords[1] = PENTA15A_REF[40];
2369 coords[2] = PENTA15A_REF[41];
2372 coords[0] = PENTA15A_REF[42];
2373 coords[1] = PENTA15A_REF[43];
2374 coords[2] = PENTA15A_REF[44];
2376 LOCAL_COORD_MACRO_END;
2378 SHAPE_FUN_MACRO_BEGIN;
2379 funValue[0] = 0.5*gc[1]*(1.0 - gc[0])*(2.0*gc[1] - 2.0 - gc[0]);
2380 funValue[1] = 0.5*gc[2]*(1.0 - gc[0])*(2.0*gc[2] - 2.0 - gc[0]);
2381 funValue[2] = 0.5*(gc[0] - 1.0)*(1.0 - gc[1] - gc[2])*(gc[0] + 2.0*gc[1] + 2.0*gc[2]);
2383 funValue[3] = 0.5*gc[1]*(1.0 + gc[0])*(2.0*gc[1] - 2.0 + gc[0]);
2384 funValue[4] = 0.5*gc[2]*(1.0 + gc[0])*(2.0*gc[2] - 2.0 + gc[0]);
2385 funValue[5] = 0.5*(-gc[0] - 1.0)*(1.0 - gc[1] - gc[2])*(-gc[0] + 2.0*gc[1] + 2.0*gc[2]);
2387 funValue[6] = 2.0*gc[1]*gc[2]*(1.0 - gc[0]);
2388 funValue[7] = 2.0*gc[2]*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2389 funValue[8] = 2.0*gc[1]*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2391 funValue[9] = gc[1]*(1.0 - gc[0]*gc[0]);
2392 funValue[10] = gc[2]*(1.0 - gc[0]*gc[0]);
2393 funValue[11] = (1.0 - gc[1] - gc[2])*(1.0 - gc[0]*gc[0]);
2395 funValue[12] = 2.0*gc[1]*gc[2]*(1.0 + gc[0]);
2396 funValue[13] = 2.0*gc[2]*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2397 funValue[14] = 2.0*gc[1]*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2398 SHAPE_FUN_MACRO_END;
2400 DEV_SHAPE_FUN_MACRO_BEGIN;
2402 devFunValue[0] = 0.5*gc[1]*(2 * gc[0] - 2 * gc[1] + 1.0 );
2403 devFunValue[1] = (1.0 - gc[0])*(2.0*gc[1] -1 - 0.5*gc[0]);
2404 devFunValue[2] = 0.0;
2406 devFunValue[3] = 0.5*gc[2]*(2 * gc[0] - 2 * gc[2] + 1.0 );
2407 devFunValue[4] = 0.0;
2408 devFunValue[5] = (1.0 - gc[0])*(2.0*gc[2] -1 - 0.5*gc[0]);
2410 devFunValue[6] = 0.5*(1.0 - gc[1] - gc[2])*(2*gc[0] -1.0 + 2*gc[1] + 2*gc[2]);
2411 devFunValue[7] = 0.5*(gc[0] - 1.0)* ( -4*gc[1] -gc[0] -4*gc[2] + 2.0);
2412 devFunValue[8] = 0.5*(gc[0] - 1.0)* ( -4*gc[2] -4*gc[1] -gc[0] + 2.0);
2414 devFunValue[9] = 0.5*gc[1]*( 2*gc[0] + 2*gc[1] -1.0 );
2415 devFunValue[10] = (1.0 + gc[0])*(2.0*gc[1] - 1.0 + 0.5*gc[0]);
2416 devFunValue[11] = 0.0;
2418 devFunValue[12] = 0.5*gc[2]*( 2*gc[0] + 2*gc[2] -1.0 );
2419 devFunValue[13] = 0.0;
2420 devFunValue[14] = (1.0 + gc[0])*(2.0*gc[2] - 1.0 + 0.5*gc[0]);
2422 devFunValue[15] = 0.5*(1.0 - gc[1] - gc[2])*(2 * gc[0] - 2.0 * gc[1] - 2.0 * gc[2] + 1.0 );
2423 devFunValue[16] = 0.5*(-gc[0] - 1.0) * (-4.0*gc[1] + gc[0] - 4.0 * gc[2] + 2.0) ;
2424 devFunValue[17] = 0.5*(-gc[0] - 1.0) * (-4.0*gc[2] - 4*gc[1] + gc[0] + 2.0 );
2426 devFunValue[18] = - 2.0*gc[1]*gc[2];
2427 devFunValue[19] = 2.0*gc[2]*(1.0 - gc[0]);
2428 devFunValue[20] = 2.0*gc[1]*(1.0 - gc[0]);
2430 devFunValue[21] = -2.0*gc[2]*(1.0 - gc[1] - gc[2]);
2431 devFunValue[22] = -2.0*gc[2]*(1.0 - gc[0]);
2432 devFunValue[23] = (-4*gc[2]-2*gc[1]+2.0)*(1.0 - gc[0]);
2434 devFunValue[24] = -2.0*gc[1]*(1.0 - gc[1] - gc[2]);
2435 devFunValue[25] = (-4*gc[1]-2*gc[2]+2)*(1.0 - gc[0]);
2436 devFunValue[26] = -2.0*gc[1]*(1.0 - gc[0]);
2438 devFunValue[27] = gc[1]*(- 2.0 * gc[0]);
2439 devFunValue[28] = (1.0 - gc[0]*gc[0]);
2440 devFunValue[29] = 0.0;
2442 devFunValue[30] = -2.0 * gc[2] *gc[0];
2443 devFunValue[31] = 0.0;
2444 devFunValue[32] = (1.0 - gc[0]*gc[0]);
2446 devFunValue[33] = -2.0 * (1.0 - gc[1] - gc[2]) * gc[0];
2447 devFunValue[34] = -1.0*(1.0 - gc[0]*gc[0]);
2448 devFunValue[35] = -1.0*(1.0 - gc[0]*gc[0]);
2450 devFunValue[36] = 2.0*gc[1]*gc[2];
2451 devFunValue[37] = 2.0*gc[2]*(1.0 + gc[0]);
2452 devFunValue[38] = 2.0*gc[1]*(1.0 + gc[0]);
2454 devFunValue[39] = 2.0*gc[2]*(1.0 - gc[1] - gc[2]);
2455 devFunValue[40] = -2.0*gc[2]*(1.0 + gc[0]);
2456 devFunValue[41] = (2.0 - 2.0 * gc[1] - 4.0 * gc[2])*(1.0 + gc[0]);
2458 devFunValue[42] = 2.0*gc[1]*(1.0 - gc[1] - gc[2]);
2459 devFunValue[43] = (2.0 - 4*gc[1] - 2*gc[2])*(1.0 + gc[0]);
2460 devFunValue[44] = -2.0*gc[1]*(1.0 + gc[0]);
2462 DEV_SHAPE_FUN_MACRO_END;
2466 * Init Qaudratic Pentahedron Reference coordinates and Shape function.
2469 void GaussInfo::penta15bInit()
2471 LOCAL_COORD_MACRO_BEGIN;
2473 coords[0] = PENTA15B_REF[0];
2474 coords[1] = PENTA15B_REF[1];
2475 coords[2] = PENTA15B_REF[2];
2478 coords[0] = PENTA15B_REF[3];
2479 coords[1] = PENTA15B_REF[4];
2480 coords[2] = PENTA15B_REF[5];
2483 coords[0] = PENTA15B_REF[6];
2484 coords[1] = PENTA15B_REF[7];
2485 coords[2] = PENTA15B_REF[8];
2488 coords[0] = PENTA15B_REF[9];
2489 coords[1] = PENTA15B_REF[10];
2490 coords[2] = PENTA15B_REF[11];
2493 coords[0] = PENTA15B_REF[12];
2494 coords[1] = PENTA15B_REF[13];
2495 coords[2] = PENTA15B_REF[14];
2498 coords[0] = PENTA15B_REF[15];
2499 coords[1] = PENTA15B_REF[16];
2500 coords[2] = PENTA15B_REF[17];
2503 coords[0] = PENTA15B_REF[18];
2504 coords[1] = PENTA15B_REF[19];
2505 coords[2] = PENTA15B_REF[20];
2508 coords[0] = PENTA15B_REF[21];
2509 coords[1] = PENTA15B_REF[22];
2510 coords[2] = PENTA15B_REF[23];
2513 coords[0] = PENTA15B_REF[24];
2514 coords[1] = PENTA15B_REF[25];
2515 coords[2] = PENTA15B_REF[26];
2518 coords[0] = PENTA15B_REF[27];
2519 coords[1] = PENTA15B_REF[28];
2520 coords[2] = PENTA15B_REF[29];
2523 coords[0] = PENTA15B_REF[30];
2524 coords[1] = PENTA15B_REF[31];
2525 coords[2] = PENTA15B_REF[32];
2528 coords[0] = PENTA15B_REF[33];
2529 coords[1] = PENTA15B_REF[34];
2530 coords[2] = PENTA15B_REF[35];
2533 coords[0] = PENTA15B_REF[36];
2534 coords[1] = PENTA15B_REF[37];
2535 coords[2] = PENTA15B_REF[38];
2538 coords[0] = PENTA15B_REF[39];
2539 coords[1] = PENTA15B_REF[40];
2540 coords[2] = PENTA15B_REF[41];
2543 coords[0] = PENTA15B_REF[42];
2544 coords[1] = PENTA15B_REF[43];
2545 coords[2] = PENTA15B_REF[44];
2547 LOCAL_COORD_MACRO_END;
2549 SHAPE_FUN_MACRO_BEGIN;
2550 funValue[0] = 0.5*gc[1]*(1.0 - gc[0])*(2.0*gc[1] - 2.0 - gc[0]);
2551 funValue[2] = 0.5*gc[2]*(1.0 - gc[0])*(2.0*gc[2] - 2.0 - gc[0]);
2552 funValue[1] = 0.5*(gc[0] - 1.0)*(1.0 - gc[1] - gc[2])*(gc[0] + 2.0*gc[1] + 2.0*gc[2]);
2554 funValue[3] = 0.5*gc[1]*(1.0 + gc[0])*(2.0*gc[1] - 2.0 + gc[0]);
2555 funValue[5] = 0.5*gc[2]*(1.0 + gc[0])*(2.0*gc[2] - 2.0 + gc[0]);
2556 funValue[4] = 0.5*(-gc[0] - 1.0)*(1.0 - gc[1] - gc[2])*(-gc[0] + 2.0*gc[1] + 2.0*gc[2]);
2558 funValue[8] = 2.0*gc[1]*gc[2]*(1.0 - gc[0]);
2559 funValue[7] = 2.0*gc[2]*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2560 funValue[6] = 2.0*gc[1]*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2562 funValue[12] = gc[1]*(1.0 - gc[0]*gc[0]);
2563 funValue[14] = gc[2]*(1.0 - gc[0]*gc[0]);
2564 funValue[13] = (1.0 - gc[1] - gc[2])*(1.0 - gc[0]*gc[0]);
2566 funValue[11] = 2.0*gc[1]*gc[2]*(1.0 + gc[0]);
2567 funValue[10] = 2.0*gc[2]*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2568 funValue[9] = 2.0*gc[1]*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2569 SHAPE_FUN_MACRO_END;
2572 void GaussInfo::penta18aInit()
2574 LOCAL_COORD_MACRO_BEGIN;
2576 coords[0] = PENTA18A_REF[0];
2577 coords[1] = PENTA18A_REF[1];
2578 coords[2] = PENTA18A_REF[2];
2581 coords[0] = PENTA18A_REF[3];
2582 coords[1] = PENTA18A_REF[4];
2583 coords[2] = PENTA18A_REF[5];
2586 coords[0] = PENTA18A_REF[6];
2587 coords[1] = PENTA18A_REF[7];
2588 coords[2] = PENTA18A_REF[8];
2591 coords[0] = PENTA18A_REF[9];
2592 coords[1] = PENTA18A_REF[10];
2593 coords[2] = PENTA18A_REF[11];
2596 coords[0] = PENTA18A_REF[12];
2597 coords[1] = PENTA18A_REF[13];
2598 coords[2] = PENTA18A_REF[14];
2601 coords[0] = PENTA18A_REF[15];
2602 coords[1] = PENTA18A_REF[16];
2603 coords[2] = PENTA18A_REF[17];
2606 coords[0] = PENTA18A_REF[18];
2607 coords[1] = PENTA18A_REF[19];
2608 coords[2] = PENTA18A_REF[20];
2611 coords[0] = PENTA18A_REF[21];
2612 coords[1] = PENTA18A_REF[22];
2613 coords[2] = PENTA18A_REF[23];
2616 coords[0] = PENTA18A_REF[24];
2617 coords[1] = PENTA18A_REF[25];
2618 coords[2] = PENTA18A_REF[26];
2621 coords[0] = PENTA18A_REF[27];
2622 coords[1] = PENTA18A_REF[28];
2623 coords[2] = PENTA18A_REF[29];
2626 coords[0] = PENTA18A_REF[30];
2627 coords[1] = PENTA18A_REF[31];
2628 coords[2] = PENTA18A_REF[32];
2631 coords[0] = PENTA18A_REF[33];
2632 coords[1] = PENTA18A_REF[34];
2633 coords[2] = PENTA18A_REF[35];
2636 coords[0] = PENTA18A_REF[36];
2637 coords[1] = PENTA18A_REF[37];
2638 coords[2] = PENTA18A_REF[38];
2641 coords[0] = PENTA18A_REF[39];
2642 coords[1] = PENTA18A_REF[40];
2643 coords[2] = PENTA18A_REF[41];
2646 coords[0] = PENTA18A_REF[42];
2647 coords[1] = PENTA18A_REF[43];
2648 coords[2] = PENTA18A_REF[44];
2651 coords[0] = PENTA18A_REF[45];
2652 coords[1] = PENTA18A_REF[46];
2653 coords[2] = PENTA18A_REF[47];
2656 coords[0] = PENTA18A_REF[48];
2657 coords[1] = PENTA18A_REF[49];
2658 coords[2] = PENTA18A_REF[50];
2661 coords[0] = PENTA18A_REF[51];
2662 coords[1] = PENTA18A_REF[52];
2663 coords[2] = PENTA18A_REF[53];
2665 LOCAL_COORD_MACRO_END;
2667 SHAPE_FUN_MACRO_BEGIN;
2668 funValue[0] = 0.5*gc[1]*(1.0 - gc[0])*(2.0*gc[1] - 2.0 - gc[0]);
2669 funValue[1] = 0.5*gc[2]*(1.0 - gc[0])*(2.0*gc[2] - 2.0 - gc[0]);
2670 funValue[2] = 0.5*(gc[0] - 1.0)*(1.0 - gc[1] - gc[2])*(gc[0] + 2.0*gc[1] + 2.0*gc[2]);
2672 funValue[3] = 0.5*gc[1]*(1.0 + gc[0])*(2.0*gc[1] - 2.0 + gc[0]);
2673 funValue[4] = 0.5*gc[2]*(1.0 + gc[0])*(2.0*gc[2] - 2.0 + gc[0]);
2674 funValue[5] = 0.5*(-gc[0] - 1.0)*(1.0 - gc[1] - gc[2])*(-gc[0] + 2.0*gc[1] + 2.0*gc[2]);
2676 funValue[6] = 2.0*gc[1]*gc[2]*(1.0 - gc[0]);
2677 funValue[7] = 2.0*gc[2]*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2678 funValue[8] = 2.0*gc[1]*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2680 funValue[9] = gc[1]*(1.0 - gc[0]*gc[0]);
2681 funValue[10] = gc[2]*(1.0 - gc[0]*gc[0]);
2682 funValue[11] = (1.0 - gc[1] - gc[2])*(1.0 - gc[0]*gc[0]);
2684 funValue[12] = 2.0*gc[1]*gc[2]*(1.0 + gc[0]);
2685 funValue[13] = 2.0*gc[2]*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2686 funValue[14] = 2.0*gc[1]*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2688 funValue[15] = 4.0*gc[1]*gc[2]*(1.0 - gc[0] * gc[0]);
2689 funValue[16] = 4.0*gc[2]*(gc[0] * gc[0] - 1) * ( gc[2] + gc[1] - 1);
2690 funValue[17] = 4.0*gc[1]*(gc[0] * gc[0] - 1) * ( gc[2] + gc[1] - 1);
2691 SHAPE_FUN_MACRO_END;
2694 void GaussInfo::penta18bInit()
2696 LOCAL_COORD_MACRO_BEGIN;
2698 coords[0] = PENTA18B_REF[0];
2699 coords[1] = PENTA18B_REF[1];
2700 coords[2] = PENTA18B_REF[2];
2703 coords[0] = PENTA18B_REF[3];
2704 coords[1] = PENTA18B_REF[4];
2705 coords[2] = PENTA18B_REF[5];
2708 coords[0] = PENTA18B_REF[6];
2709 coords[1] = PENTA18B_REF[7];
2710 coords[2] = PENTA18B_REF[8];
2713 coords[0] = PENTA18B_REF[9];
2714 coords[1] = PENTA18B_REF[10];
2715 coords[2] = PENTA18B_REF[11];
2718 coords[0] = PENTA18B_REF[12];
2719 coords[1] = PENTA18B_REF[13];
2720 coords[2] = PENTA18B_REF[14];
2723 coords[0] = PENTA18B_REF[15];
2724 coords[1] = PENTA18B_REF[16];
2725 coords[2] = PENTA18B_REF[17];
2728 coords[0] = PENTA18B_REF[18];
2729 coords[1] = PENTA18B_REF[19];
2730 coords[2] = PENTA18B_REF[20];
2733 coords[0] = PENTA18B_REF[21];
2734 coords[1] = PENTA18B_REF[22];
2735 coords[2] = PENTA18B_REF[23];
2738 coords[0] = PENTA18B_REF[24];
2739 coords[1] = PENTA18B_REF[25];
2740 coords[2] = PENTA18B_REF[26];
2743 coords[0] = PENTA18B_REF[27];
2744 coords[1] = PENTA18B_REF[28];
2745 coords[2] = PENTA18B_REF[29];
2748 coords[0] = PENTA18B_REF[30];
2749 coords[1] = PENTA18B_REF[31];
2750 coords[2] = PENTA18B_REF[32];
2753 coords[0] = PENTA18B_REF[33];
2754 coords[1] = PENTA18B_REF[34];
2755 coords[2] = PENTA18B_REF[35];
2758 coords[0] = PENTA18B_REF[36];
2759 coords[1] = PENTA18B_REF[37];
2760 coords[2] = PENTA18B_REF[38];
2763 coords[0] = PENTA18B_REF[39];
2764 coords[1] = PENTA18B_REF[40];
2765 coords[2] = PENTA18B_REF[41];
2768 coords[0] = PENTA18B_REF[42];
2769 coords[1] = PENTA18B_REF[43];
2770 coords[2] = PENTA18B_REF[44];
2773 coords[0] = PENTA18B_REF[45];
2774 coords[1] = PENTA18B_REF[46];
2775 coords[2] = PENTA18B_REF[47];
2778 coords[0] = PENTA18B_REF[48];
2779 coords[1] = PENTA18B_REF[49];
2780 coords[2] = PENTA18B_REF[50];
2783 coords[0] = PENTA18B_REF[51];
2784 coords[1] = PENTA18B_REF[52];
2785 coords[2] = PENTA18B_REF[53];
2787 LOCAL_COORD_MACRO_END;
2789 SHAPE_FUN_MACRO_BEGIN;
2790 funValue[0] = 0.5*gc[1]*(1.0 - gc[0])*(2.0*gc[1] - 2.0 - gc[0]);
2791 funValue[2] = 0.5*gc[2]*(1.0 - gc[0])*(2.0*gc[2] - 2.0 - gc[0]);
2792 funValue[1] = 0.5*(gc[0] - 1.0)*(1.0 - gc[1] - gc[2])*(gc[0] + 2.0*gc[1] + 2.0*gc[2]);
2794 funValue[3] = 0.5*gc[1]*(1.0 + gc[0])*(2.0*gc[1] - 2.0 + gc[0]);
2795 funValue[5] = 0.5*gc[2]*(1.0 + gc[0])*(2.0*gc[2] - 2.0 + gc[0]);
2796 funValue[4] = 0.5*(-gc[0] - 1.0)*(1.0 - gc[1] - gc[2])*(-gc[0] + 2.0*gc[1] + 2.0*gc[2]);
2798 funValue[8] = 2.0*gc[1]*gc[2]*(1.0 - gc[0]);
2799 funValue[7] = 2.0*gc[2]*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2800 funValue[6] = 2.0*gc[1]*(1.0 - gc[1] - gc[2])*(1.0 - gc[0]);
2802 funValue[12] = gc[1]*(1.0 - gc[0]*gc[0]);
2803 funValue[14] = gc[2]*(1.0 - gc[0]*gc[0]);
2804 funValue[13] = (1.0 - gc[1] - gc[2])*(1.0 - gc[0]*gc[0]);
2806 funValue[11] = 2.0*gc[1]*gc[2]*(1.0 + gc[0]);
2807 funValue[10] = 2.0*gc[2]*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2808 funValue[9] = 2.0*gc[1]*(1.0 - gc[1] - gc[2])*(1.0 + gc[0]);
2810 funValue[17] = 4.0*gc[1]*gc[2]*(1.0 - gc[0] * gc[0]);
2811 funValue[16] = 4.0*gc[2]*(gc[0] * gc[0] - 1) * ( gc[2] + gc[1] - 1);
2812 funValue[15] = 4.0*gc[1]*(gc[0] * gc[0] - 1) * ( gc[2] + gc[1] - 1);
2813 SHAPE_FUN_MACRO_END;
2817 * Init Hehahedron Reference coordinates and Shape function.
2820 void GaussInfo::hexa8aInit()
2822 LOCAL_COORD_MACRO_BEGIN;
2824 coords[0] = HEXA8A_REF[0];
2825 coords[1] = HEXA8A_REF[1];
2826 coords[2] = HEXA8A_REF[2];
2829 coords[0] = HEXA8A_REF[3];
2830 coords[1] = HEXA8A_REF[4];
2831 coords[2] = HEXA8A_REF[5];
2834 coords[0] = HEXA8A_REF[6];
2835 coords[1] = HEXA8A_REF[7];
2836 coords[2] = HEXA8A_REF[8];
2839 coords[0] = HEXA8A_REF[9];
2840 coords[1] = HEXA8A_REF[10];
2841 coords[2] = HEXA8A_REF[11];
2844 coords[0] = HEXA8A_REF[12];
2845 coords[1] = HEXA8A_REF[13];
2846 coords[2] = HEXA8A_REF[14];
2849 coords[0] = HEXA8A_REF[15];
2850 coords[1] = HEXA8A_REF[16];
2851 coords[2] = HEXA8A_REF[17];
2854 coords[0] = HEXA8A_REF[18];
2855 coords[1] = HEXA8A_REF[19];
2856 coords[2] = HEXA8A_REF[20];
2859 coords[0] = HEXA8A_REF[21];
2860 coords[1] = HEXA8A_REF[22];
2861 coords[2] = HEXA8A_REF[23];
2863 LOCAL_COORD_MACRO_END;
2865 SHAPE_FUN_MACRO_BEGIN;
2866 funValue[0] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 - gc[2]);
2867 funValue[1] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(1.0 - gc[2]);
2868 funValue[2] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(1.0 - gc[2]);
2869 funValue[3] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(1.0 - gc[2]);
2871 funValue[4] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 + gc[2]);
2872 funValue[5] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(1.0 + gc[2]);
2873 funValue[6] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(1.0 + gc[2]);
2874 funValue[7] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(1.0 + gc[2]);
2875 SHAPE_FUN_MACRO_END;
2877 DEV_SHAPE_FUN_MACRO_BEGIN;
2879 devFunValue[0] = 0.125 * (-1.0) * (1.0 - gc[1])*(1.0 - gc[2]);
2880 devFunValue[1] = 0.125 * (1.0 - gc[0]) * (-1.0) * (1.0 - gc[2]);
2881 devFunValue[2] = 0.125 * (1.0 - gc[0]) * (1.0 - gc[1]) *(-1.0);
2883 devFunValue[3] = 0.125*(1.0 - gc[1])*(1.0 - gc[2]);
2884 devFunValue[4] = 0.125*(1.0 + gc[0])*(-1.0)*(1.0 - gc[2]);
2885 devFunValue[5] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(-1.0);
2887 devFunValue[6] = 0.125*(1.0 + gc[1])*(1.0 - gc[2]);
2888 devFunValue[7] = 0.125*(1.0 + gc[0])*(1.0 - gc[2]);
2889 devFunValue[8] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(-1.0);
2891 devFunValue[9 ] = 0.125*(-1.0)*(1.0 + gc[1])*(1.0 - gc[2]);
2892 devFunValue[10] = 0.125*(1.0 - gc[0])*(1.0 - gc[2]);
2893 devFunValue[11] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(-1.0);
2895 devFunValue[12] = 0.125*(-1.0)*(1.0 - gc[1])*(1.0 + gc[2]);
2896 devFunValue[13] = 0.125*(1.0 - gc[0])*(-1.0)*(1.0 + gc[2]);
2897 devFunValue[14] = 0.125*(1.0 - gc[0])*(1.0 - gc[1]);
2899 devFunValue[15] = 0.125*(1.0 - gc[1])*(1.0 + gc[2]);
2900 devFunValue[16] = 0.125*(1.0 + gc[0])*(-1.0)*(1.0 + gc[2]);
2901 devFunValue[17] = 0.125*(1.0 + gc[0])*(1.0 - gc[1]);
2903 devFunValue[18] = 0.125*(1.0 + gc[1])*(1.0 + gc[2]);
2904 devFunValue[19] = 0.125*(1.0 + gc[0])*(1.0 + gc[2]);
2905 devFunValue[20] = 0.125*(1.0 + gc[0])*(1.0 + gc[1]);
2907 devFunValue[21] = 0.125*(-1.0)*(1.0 + gc[1])*(1.0 + gc[2]);
2908 devFunValue[22] = 0.125*(1.0 - gc[0])*(1.0 + gc[2]);
2909 devFunValue[23] = 0.125*(1.0 - gc[0])*(1.0 + gc[1]);
2911 DEV_SHAPE_FUN_MACRO_END;
2915 * Init Hehahedron Reference coordinates and Shape function.
2918 void GaussInfo::hexa8bInit()
2920 LOCAL_COORD_MACRO_BEGIN;
2922 coords[0] = HEXA8B_REF[0];
2923 coords[1] = HEXA8B_REF[1];
2924 coords[2] = HEXA8B_REF[2];
2927 coords[0] = HEXA8B_REF[3];
2928 coords[1] = HEXA8B_REF[4];
2929 coords[2] = HEXA8B_REF[5];
2932 coords[0] = HEXA8B_REF[6];
2933 coords[1] = HEXA8B_REF[7];
2934 coords[2] = HEXA8B_REF[8];
2937 coords[0] = HEXA8B_REF[9];
2938 coords[1] = HEXA8B_REF[10];
2939 coords[2] = HEXA8B_REF[11];
2942 coords[0] = HEXA8B_REF[12];
2943 coords[1] = HEXA8B_REF[13];
2944 coords[2] = HEXA8B_REF[14];
2947 coords[0] = HEXA8B_REF[15];
2948 coords[1] = HEXA8B_REF[16];
2949 coords[2] = HEXA8B_REF[17];
2952 coords[0] = HEXA8B_REF[18];
2953 coords[1] = HEXA8B_REF[19];
2954 coords[2] = HEXA8B_REF[20];
2957 coords[0] = HEXA8B_REF[21];
2958 coords[1] = HEXA8B_REF[22];
2959 coords[2] = HEXA8B_REF[23];
2961 LOCAL_COORD_MACRO_END;
2963 SHAPE_FUN_MACRO_BEGIN;
2964 funValue[0] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 - gc[2]);
2965 funValue[3] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(1.0 - gc[2]);
2966 funValue[2] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(1.0 - gc[2]);
2967 funValue[1] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(1.0 - gc[2]);
2969 funValue[4] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 + gc[2]);
2970 funValue[7] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(1.0 + gc[2]);
2971 funValue[6] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(1.0 + gc[2]);
2972 funValue[5] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(1.0 + gc[2]);
2973 SHAPE_FUN_MACRO_END;
2977 * This shapefunc map is same as degenerated quad4bInit
2979 void GaussInfo::hexa8DegQuad4aInit()
2981 LOCAL_COORD_MACRO_BEGIN;
3022 LOCAL_COORD_MACRO_END;
3024 SHAPE_FUN_MACRO_BEGIN;
3025 funValue[0] = 0.25*(1.0 + gc[1])*(1.0 - gc[0]);
3026 funValue[1] = 0.25*(1.0 - gc[1])*(1.0 - gc[0]);
3027 funValue[2] = 0.25*(1.0 - gc[1])*(1.0 + gc[0]);
3028 funValue[3] = 0.25*(1.0 + gc[0])*(1.0 + gc[1]);
3033 SHAPE_FUN_MACRO_END;
3037 * This shapefunc map is same as degenerated quad4bInit
3039 void GaussInfo::hexa8DegQuad4bInit()
3041 LOCAL_COORD_MACRO_BEGIN;
3082 LOCAL_COORD_MACRO_END;
3084 SHAPE_FUN_MACRO_BEGIN;
3085 funValue[0] = 0.25*(1.0 - gc[0])*(1.0 - gc[1]);
3086 funValue[1] = 0.25*(1.0 + gc[0])*(1.0 - gc[1]);
3087 funValue[2] = 0.25*(1.0 + gc[0])*(1.0 + gc[1]);
3088 funValue[3] = 0.25*(1.0 - gc[0])*(1.0 + gc[1]);
3093 SHAPE_FUN_MACRO_END;
3097 * This shapefunc map is same as degenerated quad4cInit
3099 void GaussInfo::hexa8DegQuad4cInit()
3101 LOCAL_COORD_MACRO_BEGIN;
3143 LOCAL_COORD_MACRO_END;
3145 SHAPE_FUN_MACRO_BEGIN;
3146 funValue[0] = 0.25*(1.0 - gc[0])*(1.0 - gc[1]);
3147 funValue[1] = 0.25*(1.0 - gc[0])*(1.0 + gc[1]);
3148 funValue[2] = 0.25*(1.0 + gc[0])*(1.0 + gc[1]);
3149 funValue[3] = 0.25*(1.0 + gc[0])*(1.0 - gc[1]);
3154 SHAPE_FUN_MACRO_END;
3158 * Init Qaudratic Hehahedron Reference coordinates and Shape function.
3161 void GaussInfo::hexa20aInit()
3163 LOCAL_COORD_MACRO_BEGIN;
3165 coords[0] = HEXA20A_REF[0];
3166 coords[1] = HEXA20A_REF[1];
3167 coords[2] = HEXA20A_REF[2];
3170 coords[0] = HEXA20A_REF[3];
3171 coords[1] = HEXA20A_REF[4];
3172 coords[2] = HEXA20A_REF[5];
3175 coords[0] = HEXA20A_REF[6];
3176 coords[1] = HEXA20A_REF[7];
3177 coords[2] = HEXA20A_REF[8];
3180 coords[0] = HEXA20A_REF[9];
3181 coords[1] = HEXA20A_REF[10];
3182 coords[2] = HEXA20A_REF[11];
3185 coords[0] = HEXA20A_REF[12];
3186 coords[1] = HEXA20A_REF[13];
3187 coords[2] = HEXA20A_REF[14];
3190 coords[0] = HEXA20A_REF[15];
3191 coords[1] = HEXA20A_REF[16];
3192 coords[2] = HEXA20A_REF[17];
3195 coords[0] = HEXA20A_REF[18];
3196 coords[1] = HEXA20A_REF[19];
3197 coords[2] = HEXA20A_REF[20];
3200 coords[0] = HEXA20A_REF[21];
3201 coords[1] = HEXA20A_REF[22];
3202 coords[2] = HEXA20A_REF[23];
3205 coords[0] = HEXA20A_REF[24];
3206 coords[1] = HEXA20A_REF[25];
3207 coords[2] = HEXA20A_REF[26];
3210 coords[0] = HEXA20A_REF[27];
3211 coords[1] = HEXA20A_REF[28];
3212 coords[2] = HEXA20A_REF[29];
3215 coords[0] = HEXA20A_REF[30];
3216 coords[1] = HEXA20A_REF[31];
3217 coords[2] = HEXA20A_REF[32];
3220 coords[0] = HEXA20A_REF[33];
3221 coords[1] = HEXA20A_REF[34];
3222 coords[2] = HEXA20A_REF[35];
3225 coords[0] = HEXA20A_REF[36];
3226 coords[1] = HEXA20A_REF[37];
3227 coords[2] = HEXA20A_REF[38];
3230 coords[0] = HEXA20A_REF[39];
3231 coords[1] = HEXA20A_REF[40];
3232 coords[2] = HEXA20A_REF[41];
3235 coords[0] = HEXA20A_REF[42];
3236 coords[1] = HEXA20A_REF[43];
3237 coords[2] = HEXA20A_REF[44];
3240 coords[0] = HEXA20A_REF[45];
3241 coords[1] = HEXA20A_REF[46];
3242 coords[2] = HEXA20A_REF[47];
3245 coords[0] = HEXA20A_REF[48];
3246 coords[1] = HEXA20A_REF[49];
3247 coords[2] = HEXA20A_REF[50];
3250 coords[0] = HEXA20A_REF[51];
3251 coords[1] = HEXA20A_REF[52];
3252 coords[2] = HEXA20A_REF[53];
3255 coords[0] = HEXA20A_REF[54];
3256 coords[1] = HEXA20A_REF[55];
3257 coords[2] = HEXA20A_REF[56];
3260 coords[0] = HEXA20A_REF[57];
3261 coords[1] = HEXA20A_REF[58];
3262 coords[2] = HEXA20A_REF[59];
3264 LOCAL_COORD_MACRO_END;
3266 SHAPE_FUN_MACRO_BEGIN;
3267 funValue[0] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 - gc[2])*
3268 (-2.0 - gc[0] - gc[1] - gc[2]);
3269 funValue[1] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(1.0 - gc[2])*
3270 (-2.0 + gc[0] - gc[1] - gc[2]);
3271 funValue[2] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(1.0 - gc[2])*
3272 (-2.0 + gc[0] + gc[1] - gc[2]);
3273 funValue[3] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(1.0 - gc[2])*
3274 (-2.0 - gc[0] + gc[1] - gc[2]);
3275 funValue[4] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 + gc[2])*
3276 (-2.0 - gc[0] - gc[1] + gc[2]);
3277 funValue[5] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(1.0 + gc[2])*
3278 (-2.0 + gc[0] - gc[1] + gc[2]);
3279 funValue[6] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(1.0 + gc[2])*
3280 (-2.0 + gc[0] + gc[1] + gc[2]);
3281 funValue[7] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(1.0 + gc[2])*
3282 (-2.0 - gc[0] + gc[1] + gc[2]);
3284 funValue[8] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 - gc[1])*(1.0 - gc[2]);
3285 funValue[9] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 + gc[0])*(1.0 - gc[2]);
3286 funValue[10] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 + gc[1])*(1.0 - gc[2]);
3287 funValue[11] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 - gc[0])*(1.0 - gc[2]);
3288 funValue[12] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 - gc[0])*(1.0 - gc[1]);
3289 funValue[13] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 + gc[0])*(1.0 - gc[1]);
3290 funValue[14] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 + gc[0])*(1.0 + gc[1]);
3291 funValue[15] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 - gc[0])*(1.0 + gc[1]);
3292 funValue[16] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 - gc[1])*(1.0 + gc[2]);
3293 funValue[17] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 + gc[0])*(1.0 + gc[2]);
3294 funValue[18] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 + gc[1])*(1.0 + gc[2]);
3295 funValue[19] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 - gc[0])*(1.0 + gc[2]);
3296 SHAPE_FUN_MACRO_END;
3298 DEV_SHAPE_FUN_MACRO_BEGIN;
3300 devFunValue[0] = 0.125*(1. + gc[1] + gc[2] + 2* gc[0]) * (1.0 - gc[1])*(1.0 - gc[2]);
3301 devFunValue[1] = 0.125*(1.0 - gc[0])*(1. + gc[0] + gc[2] + 2 * gc[1])*(1.0 - gc[2]);
3302 devFunValue[2] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 + gc[0] + gc[1] + 2 *gc[2]);
3304 devFunValue[3] = 0.125*(-1.0 - gc[1] - gc[2] + 2*gc[0])*(1.0 - gc[1])*(1.0 - gc[2]);
3305 devFunValue[4] = 0.125*(1.0 + gc[0])* (1 - gc[0] + gc[2] + 2*gc[1]) *(1.0 - gc[2]);
3306 devFunValue[5] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])* (1 - gc[0] + gc[1] + 2*gc[2]);
3308 devFunValue[6] = 0.125*(-1.0 + gc[1] - gc[2] + 2*gc[0])*(1.0 + gc[1])*(1.0 - gc[2]);
3309 devFunValue[7] = 0.125*(1.0 + gc[0])* (-1 + gc[0] - gc[2] + 2*gc[1]) *(1.0 - gc[2]);
3310 devFunValue[8] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(1.0 - gc[0] - gc[1] + 2*gc[2]);
3312 devFunValue[9] = 0.125*(1.0 - gc[1] + gc[2] + 2*gc[0])*(1.0 + gc[1])*(1.0 - gc[2]);
3313 devFunValue[10] = 0.125*(1.0 - gc[0])*(-1 - gc[0] - gc[2] + 2*gc[1])*(1.0 - gc[2]);
3314 devFunValue[11] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(1.0 + gc[0] - gc[1] + 2*gc[2]);
3316 devFunValue[12] = 0.125*(1.0 + gc[1] - gc[2] + 2*gc[0])*(1.0 - gc[1])*(1.0 + gc[2]);
3317 devFunValue[13] = 0.125*(1.0 - gc[0])*(1 + gc[0] - gc[2] + 2*gc[1])*(1.0 + gc[2]);
3318 devFunValue[14] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(-1.0 - gc[0] - gc[1] + 2*gc[2]);
3320 devFunValue[15] = 0.125*(-1.0 - gc[1] + gc[2] + 2*gc[0])*(1.0 - gc[1])*(1.0 + gc[2]);
3321 devFunValue[16] = 0.125*(1.0 + gc[0])*(1 - gc[0] - gc[2] + 2*gc[1])*(1.0 + gc[2]);
3322 devFunValue[17] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(-1.0 + gc[0] - gc[1] + 2*gc[2]);
3324 devFunValue[18] = 0.125*(-1.0 + gc[1] + gc[2] + 2*gc[0])*(1.0 + gc[1])*(1.0 + gc[2]);
3325 devFunValue[19] = 0.125*(1.0 + gc[0])*(-1 + gc[0] + gc[2] + 2*gc[1])*(1.0 + gc[2]);
3326 devFunValue[20] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(-1.0 + gc[0] + gc[1] + 2*gc[2]);
3328 devFunValue[21] = 0.125*(1.0 - gc[1] - gc[2] + 2*gc[0])*(1.0 + gc[1])*(1.0 + gc[2]);
3329 devFunValue[22] = 0.125*(1.0 - gc[0])*(-1 - gc[0] + gc[2] + 2*gc[1])*(1.0 + gc[2]);
3330 devFunValue[23] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(-1.0 - gc[0] + gc[1] + 2*gc[2]);
3332 devFunValue[24] = 0.25*(-2.0*gc[0])*(1.0 - gc[1])*(1.0 - gc[2]);
3333 devFunValue[25] = 0.25*(1.0 - gc[0]*gc[0])*(-1)*(1.0 - gc[2]);
3334 devFunValue[26] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 - gc[1])*(-1.0);
3336 devFunValue[27] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 - gc[2]);
3337 devFunValue[28] = 0.25*(-2.0*gc[1])*(1.0 + gc[0])*(1.0 - gc[2]);
3338 devFunValue[29] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 + gc[0])*(-1.0);
3340 devFunValue[30] = 0.25*(-2.0*gc[0])*(1.0 + gc[1])*(1.0 - gc[2]);
3341 devFunValue[31] = 0.25*(1.0 - gc[0]*gc[0])*(1.0)*(1.0 - gc[2]);
3342 devFunValue[32] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 + gc[1])*(-1.0);
3344 devFunValue[33] = 0.25*(1.0 - gc[1]*gc[1])*(-1.0)*(1.0 - gc[2]);
3345 devFunValue[34] = 0.25*(-2.0*gc[1])*(1.0 - gc[0])*(1.0 - gc[2]);
3346 devFunValue[35] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 - gc[0])*(-1.0);
3348 devFunValue[36] = 0.25*(1.0 - gc[2]*gc[2])*(-1.0)*(1.0 - gc[1]);
3349 devFunValue[37] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 - gc[0])*(-1.0);
3350 devFunValue[38] = 0.25*(-2.0*gc[2])*(1.0 - gc[0])*(1.0 - gc[1]);
3352 devFunValue[39] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 - gc[1]);
3353 devFunValue[40] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 + gc[0])*(-1.0);
3354 devFunValue[41] = 0.25*(-2.0*gc[2])*(1.0 + gc[0])*(1.0 - gc[1]);
3356 devFunValue[42] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 + gc[1]);
3357 devFunValue[43] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 + gc[0]);
3358 devFunValue[44] = 0.25*(-2.0*gc[2])*(1.0 + gc[0])*(1.0 + gc[1]);
3360 devFunValue[45] = 0.25*(1.0 - gc[2]*gc[2])*(-1.0)*(1.0 + gc[1]);
3361 devFunValue[46] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 - gc[0]);
3362 devFunValue[47] = 0.25*(-2.0*gc[2])*(1.0 - gc[0])*(1.0 + gc[1]);
3364 devFunValue[48] = 0.25*(-2.0*gc[0])*(1.0 - gc[1])*(1.0 + gc[2]);
3365 devFunValue[49] = 0.25*(1.0 - gc[0]*gc[0])*(-1.0)*(1.0 + gc[2]);
3366 devFunValue[50] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 - gc[1]);
3368 devFunValue[51] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 + gc[2]);
3369 devFunValue[52] = 0.25*(-2.0*gc[1])*(1.0 + gc[0])*(1.0 + gc[2]);
3370 devFunValue[53] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 + gc[0]);
3372 devFunValue[54] = 0.25*(-2.0*gc[0])*(1.0 + gc[1])*(1.0 + gc[2]);
3373 devFunValue[55] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 + gc[2]);
3374 devFunValue[56] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 + gc[1]);
3376 devFunValue[57] = 0.25*(1.0 - gc[1]*gc[1])*(-1.0)*(1.0 + gc[2]);
3377 devFunValue[58] = 0.25*(-2.0*gc[1])*(1.0 - gc[0])*(1.0 + gc[2]);
3378 devFunValue[59] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 - gc[0]);
3380 SHAPE_FUN_MACRO_END;
3384 * Init Qaudratic Hehahedron Reference coordinates and Shape function.
3387 void GaussInfo::hexa20bInit()
3389 LOCAL_COORD_MACRO_BEGIN;
3391 coords[0] = HEXA20B_REF[0];
3392 coords[1] = HEXA20B_REF[1];
3393 coords[2] = HEXA20B_REF[2];
3396 coords[0] = HEXA20B_REF[3];
3397 coords[1] = HEXA20B_REF[4];
3398 coords[2] = HEXA20B_REF[5];
3401 coords[0] = HEXA20B_REF[6];
3402 coords[1] = HEXA20B_REF[7];
3403 coords[2] = HEXA20B_REF[8];
3406 coords[0] = HEXA20B_REF[9];
3407 coords[1] = HEXA20B_REF[10];
3408 coords[2] = HEXA20B_REF[11];
3411 coords[0] = HEXA20B_REF[12];
3412 coords[1] = HEXA20B_REF[13];
3413 coords[2] = HEXA20B_REF[14];
3416 coords[0] = HEXA20B_REF[15];
3417 coords[1] = HEXA20B_REF[16];
3418 coords[2] = HEXA20B_REF[17];
3421 coords[0] = HEXA20B_REF[18];
3422 coords[1] = HEXA20B_REF[19];
3423 coords[2] = HEXA20B_REF[20];
3426 coords[0] = HEXA20B_REF[21];
3427 coords[1] = HEXA20B_REF[22];
3428 coords[2] = HEXA20B_REF[23];
3431 coords[0] = HEXA20B_REF[24];
3432 coords[1] = HEXA20B_REF[25];
3433 coords[2] = HEXA20B_REF[26];
3436 coords[0] = HEXA20B_REF[27];
3437 coords[1] = HEXA20B_REF[28];
3438 coords[2] = HEXA20B_REF[29];
3441 coords[0] = HEXA20B_REF[30];
3442 coords[1] = HEXA20B_REF[31];
3443 coords[2] = HEXA20B_REF[32];
3446 coords[0] = HEXA20B_REF[33];
3447 coords[1] = HEXA20B_REF[34];
3448 coords[2] = HEXA20B_REF[35];
3451 coords[0] = HEXA20B_REF[36];
3452 coords[1] = HEXA20B_REF[37];
3453 coords[2] = HEXA20B_REF[38];
3456 coords[0] = HEXA20B_REF[39];
3457 coords[1] = HEXA20B_REF[40];
3458 coords[2] = HEXA20B_REF[41];
3461 coords[0] = HEXA20B_REF[42];
3462 coords[1] = HEXA20B_REF[43];
3463 coords[2] = HEXA20B_REF[44];
3466 coords[0] = HEXA20B_REF[45];
3467 coords[1] = HEXA20B_REF[46];
3468 coords[2] = HEXA20B_REF[47];
3471 coords[0] = HEXA20B_REF[48];
3472 coords[1] = HEXA20B_REF[49];
3473 coords[2] = HEXA20B_REF[50];
3476 coords[0] = HEXA20B_REF[51];
3477 coords[1] = HEXA20B_REF[52];
3478 coords[2] = HEXA20B_REF[53];
3481 coords[0] = HEXA20B_REF[54];
3482 coords[1] = HEXA20B_REF[55];
3483 coords[2] = HEXA20B_REF[56];
3486 coords[0] = HEXA20B_REF[57];
3487 coords[1] = HEXA20B_REF[58];
3488 coords[2] = HEXA20B_REF[59];
3490 LOCAL_COORD_MACRO_END;
3492 SHAPE_FUN_MACRO_BEGIN;
3494 funValue[0] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 - gc[2])*
3495 (-2.0 - gc[0] - gc[1] - gc[2]);
3496 funValue[3] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(1.0 - gc[2])*
3497 (-2.0 + gc[0] - gc[1] - gc[2]);
3498 funValue[2] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(1.0 - gc[2])*
3499 (-2.0 + gc[0] + gc[1] - gc[2]);
3500 funValue[1] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(1.0 - gc[2])*
3501 (-2.0 - gc[0] + gc[1] - gc[2]);
3502 funValue[4] = 0.125*(1.0 - gc[0])*(1.0 - gc[1])*(1.0 + gc[2])*
3503 (-2.0 - gc[0] - gc[1] + gc[2]);
3504 funValue[7] = 0.125*(1.0 + gc[0])*(1.0 - gc[1])*(1.0 + gc[2])*
3505 (-2.0 + gc[0] - gc[1] + gc[2]);
3506 funValue[6] = 0.125*(1.0 + gc[0])*(1.0 + gc[1])*(1.0 + gc[2])*
3507 (-2.0 + gc[0] + gc[1] + gc[2]);
3508 funValue[5] = 0.125*(1.0 - gc[0])*(1.0 + gc[1])*(1.0 + gc[2])*
3509 (-2.0 - gc[0] + gc[1] + gc[2]);
3511 funValue[11] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 - gc[1])*(1.0 - gc[2]);
3512 funValue[10] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 + gc[0])*(1.0 - gc[2]);
3513 funValue[9] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 + gc[1])*(1.0 - gc[2]);
3514 funValue[8] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 - gc[0])*(1.0 - gc[2]);
3515 funValue[16] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 - gc[0])*(1.0 - gc[1]);
3516 funValue[19] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 + gc[0])*(1.0 - gc[1]);
3517 funValue[18] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 + gc[0])*(1.0 + gc[1]);
3518 funValue[17] = 0.25*(1.0 - gc[2]*gc[2])*(1.0 - gc[0])*(1.0 + gc[1]);
3519 funValue[15] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 - gc[1])*(1.0 + gc[2]);
3520 funValue[14] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 + gc[0])*(1.0 + gc[2]);
3521 funValue[13] = 0.25*(1.0 - gc[0]*gc[0])*(1.0 + gc[1])*(1.0 + gc[2]);
3522 funValue[12] = 0.25*(1.0 - gc[1]*gc[1])*(1.0 - gc[0])*(1.0 + gc[2]);
3523 SHAPE_FUN_MACRO_END;
3526 void GaussInfo::hexa27aInit()
3528 LOCAL_COORD_MACRO_BEGIN;
3530 coords[0] = HEXA27A_REF[0];
3531 coords[1] = HEXA27A_REF[1];
3532 coords[2] = HEXA27A_REF[2];
3535 coords[0] = HEXA27A_REF[3];
3536 coords[1] = HEXA27A_REF[4];
3537 coords[2] = HEXA27A_REF[5];
3540 coords[0] = HEXA27A_REF[6];
3541 coords[1] = HEXA27A_REF[7];
3542 coords[2] = HEXA27A_REF[8];
3545 coords[0] = HEXA27A_REF[9];
3546 coords[1] = HEXA27A_REF[10];
3547 coords[2] = HEXA27A_REF[11];
3550 coords[0] = HEXA27A_REF[12];
3551 coords[1] = HEXA27A_REF[13];
3552 coords[2] = HEXA27A_REF[14];
3555 coords[0] = HEXA27A_REF[15];
3556 coords[1] = HEXA27A_REF[16];
3557 coords[2] = HEXA27A_REF[17];
3560 coords[0] = HEXA27A_REF[18];
3561 coords[1] = HEXA27A_REF[19];
3562 coords[2] = HEXA27A_REF[20];
3565 coords[0] = HEXA27A_REF[21];
3566 coords[1] = HEXA27A_REF[22];
3567 coords[2] = HEXA27A_REF[23];
3570 coords[0] = HEXA27A_REF[24];
3571 coords[1] = HEXA27A_REF[25];
3572 coords[2] = HEXA27A_REF[26];
3575 coords[0] = HEXA27A_REF[27];
3576 coords[1] = HEXA27A_REF[28];
3577 coords[2] = HEXA27A_REF[29];
3580 coords[0] = HEXA27A_REF[30];
3581 coords[1] = HEXA27A_REF[31];
3582 coords[2] = HEXA27A_REF[32];
3585 coords[0] = HEXA27A_REF[33];
3586 coords[1] = HEXA27A_REF[34];
3587 coords[2] = HEXA27A_REF[35];
3590 coords[0] = HEXA27A_REF[36];
3591 coords[1] = HEXA27A_REF[37];
3592 coords[2] = HEXA27A_REF[38];
3595 coords[0] = HEXA27A_REF[39];
3596 coords[1] = HEXA27A_REF[40];
3597 coords[2] = HEXA27A_REF[41];
3600 coords[0] = HEXA27A_REF[42];
3601 coords[1] = HEXA27A_REF[43];
3602 coords[2] = HEXA27A_REF[44];
3605 coords[0] = HEXA27A_REF[45];
3606 coords[1] = HEXA27A_REF[46];
3607 coords[2] = HEXA27A_REF[47];
3610 coords[0] = HEXA27A_REF[48];
3611 coords[1] = HEXA27A_REF[49];
3612 coords[2] = HEXA27A_REF[50];
3615 coords[0] = HEXA27A_REF[51];
3616 coords[1] = HEXA27A_REF[52];
3617 coords[2] = HEXA27A_REF[53];
3620 coords[0] = HEXA27A_REF[54];
3621 coords[1] = HEXA27A_REF[55];
3622 coords[2] = HEXA27A_REF[56];
3625 coords[0] = HEXA27A_REF[57];
3626 coords[1] = HEXA27A_REF[58];
3627 coords[2] = HEXA27A_REF[59];
3630 coords[0] = HEXA27A_REF[60];
3631 coords[1] = HEXA27A_REF[61];
3632 coords[2] = HEXA27A_REF[62];
3635 coords[0] = HEXA27A_REF[63];
3636 coords[1] = HEXA27A_REF[64];
3637 coords[2] = HEXA27A_REF[65];
3640 coords[0] = HEXA27A_REF[66];
3641 coords[1] = HEXA27A_REF[67];
3642 coords[2] = HEXA27A_REF[68];
3645 coords[0] = HEXA27A_REF[69];
3646 coords[1] = HEXA27A_REF[70];
3647 coords[2] = HEXA27A_REF[71];
3650 coords[0] = HEXA27A_REF[72];
3651 coords[1] = HEXA27A_REF[73];
3652 coords[2] = HEXA27A_REF[74];
3655 coords[0] = HEXA27A_REF[75];
3656 coords[1] = HEXA27A_REF[76];
3657 coords[2] = HEXA27A_REF[77];
3660 coords[0] = HEXA27A_REF[78];
3661 coords[1] = HEXA27A_REF[79];
3662 coords[2] = HEXA27A_REF[80];
3664 LOCAL_COORD_MACRO_END;
3666 SHAPE_FUN_MACRO_BEGIN;
3668 funValue[0] =0.125*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]-1.);
3669 funValue[1] =0.125*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]-1.);
3670 funValue[2] =0.125*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]-1.);
3671 funValue[3] =0.125*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]-1.);
3672 funValue[4] =0.125*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]+1.);
3673 funValue[5] =0.125*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]+1.);
3674 funValue[6] =0.125*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]+1.);
3675 funValue[7] =0.125*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]+1.);
3676 funValue[8] =0.25*gc[0]*(gc[0]-1.)*(1.-gc[1]*gc[1])*gc[2]*(gc[2]-1.);
3677 funValue[9] =0.25*(1.-gc[0]*gc[0])*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]-1.);
3678 funValue[10]=0.25*gc[0]*(gc[0]+1.)*(1.-gc[1]*gc[1])*gc[2]*(gc[2]-1.);
3679 funValue[11]=0.25*(1.-gc[0]*gc[0])*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]-1.);
3680 funValue[12]=0.25*gc[0]*(gc[0]-1.)*(1.-gc[1]*gc[1])*gc[2]*(gc[2]+1.);
3681 funValue[13]=0.25*(1.-gc[0]*gc[0])*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]+1.);
3682 funValue[14]=0.25*gc[0]*(gc[0]+1.)*(1.-gc[1]*gc[1])*gc[2]*(gc[2]+1.);
3683 funValue[15]=0.25*(1.-gc[0]*gc[0])*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]+1.);
3684 funValue[16]=0.25*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]-1.)*(1.-gc[2]*gc[2]);
3685 funValue[17]=0.25*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]+1.)*(1.-gc[2]*gc[2]);
3686 funValue[18]=0.25*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]+1.)*(1.-gc[2]*gc[2]);
3687 funValue[19]=0.25*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]-1.)*(1.-gc[2]*gc[2]);
3688 funValue[20]=0.5*(1.-gc[0]*gc[0])*(1.-gc[1]*gc[1])*gc[2]*(gc[2]-1.);
3689 funValue[21]=0.5*gc[0]*(gc[0]-1.)*(1.-gc[1]*gc[1])*(1.-gc[2]*gc[2]);
3690 funValue[22]=0.5*(1.-gc[0]*gc[0])*gc[1]*(gc[1]+1.)*(1.-gc[2]*gc[2]);
3691 funValue[23]=0.5*gc[0]*(gc[0]+1.)*(1.-gc[1]*gc[1])*(1.-gc[2]*gc[2]);
3692 funValue[24]=0.5*(1.-gc[0]*gc[0])*gc[1]*(gc[1]-1.)*(1.-gc[2]*gc[2]);
3693 funValue[25]=0.5*(1.-gc[0]*gc[0])*(1.-gc[1]*gc[1])*gc[2]*(gc[2]+1.);
3694 funValue[26]=(1.-gc[0]*gc[0])*(1.-gc[1]*gc[1])*(1.-gc[2]*gc[2]);
3696 SHAPE_FUN_MACRO_END;
3698 DEV_SHAPE_FUN_MACRO_BEGIN;
3700 devFunValue[0] = 0.125*(2*gc[0]-1.)*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]-1.);
3701 devFunValue[1] = 0.125*gc[0]*(gc[0]-1.)*(2*gc[1]-1.)*gc[2]*(gc[2]-1.);
3702 devFunValue[2] = 0.125*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]-1.)*(2*gc[2]-1.);
3704 devFunValue[3] = 0.125*(2*gc[0]-1.)*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]-1.);
3705 devFunValue[4] = 0.125*gc[0]*(gc[0]-1.)*(2*gc[1]+1.)*gc[2]*(gc[2]-1.);
3706 devFunValue[5] = 0.125*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]+1.)*(2*gc[2]-1.);
3708 devFunValue[6] = 0.125*(2*gc[0]+1.)*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]-1.);
3709 devFunValue[7] = 0.125*gc[0]*(gc[0]+1.)*(2*gc[1]+1.)*gc[2]*(gc[2]-1.);
3710 devFunValue[8] = 0.125*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]+1.)*(2*gc[2]-1.);
3712 devFunValue[9] = 0.125*(2*gc[0]+1.)*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]-1.);
3713 devFunValue[10] = 0.125*gc[0]*(gc[0]+1.)*(2*gc[1]-1.)*gc[2]*(gc[2]-1.);
3714 devFunValue[11] = 0.125*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]-1.)*(2*gc[2]-1.);
3716 devFunValue[12] = 0.125*(2*gc[0]-1.)*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]+1.);
3717 devFunValue[13] = 0.125*gc[0]*(gc[0]-1.)*(2*gc[1]-1.)*gc[2]*(gc[2]+1.);
3718 devFunValue[14] = 0.125*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]-1.)*(2*gc[2]+1.);
3720 devFunValue[15] = 0.125*(2*gc[0]-1.)*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]+1.);
3721 devFunValue[16] = 0.125*gc[0]*(gc[0]-1.)*(2*gc[1]+1.)*gc[2]*(gc[2]+1.);
3722 devFunValue[17] = 0.125*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]+1.)*(2*gc[2]+1.);
3724 devFunValue[18] = 0.125*(2*gc[0]+1.)*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]+1.);
3725 devFunValue[19] = 0.125*gc[0]*(gc[0]+1.)*(2*gc[1]+1.)*gc[2]*(gc[2]+1.);
3726 devFunValue[20] = 0.125*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]+1.)*(2*gc[2]+1.);
3728 devFunValue[21] = 0.125*(2*gc[0]+1.)*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]+1.);
3729 devFunValue[22] = 0.125*gc[0]*(gc[0]+1.)*(2*gc[1]-1.)*gc[2]*(gc[2]+1.);
3730 devFunValue[23] = 0.125*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]-1.)*(2*gc[2]+1.);
3732 devFunValue[24] = 0.25*(2*gc[0]-1.)*(1.-gc[1]*gc[1])*gc[2]*(gc[2]-1.);
3733 devFunValue[25] = 0.25*gc[0]*(gc[0]-1.)*(-2*gc[1])*gc[2]*(gc[2]-1.);
3734 devFunValue[26] = 0.25*gc[0]*(gc[0]-1.)*(1.-gc[1]*gc[1])*(2*gc[2]-1.);
3736 devFunValue[27] = 0.25*(-2*gc[0])*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]-1.);
3737 devFunValue[28] = 0.25*(1.-gc[0]*gc[0])*(2*gc[1]+1.)*gc[2]*(gc[2]-1.);
3738 devFunValue[29] = 0.25*(1.-gc[0]*gc[0])*gc[1]*(gc[1]+1.)*(2*gc[2]-1.);
3740 devFunValue[30] = 0.25*(2*gc[0]+1.)*(1.-gc[1]*gc[1])*gc[2]*(gc[2]-1.);
3741 devFunValue[31] = 0.25*gc[0]*(gc[0]+1.)*(-2*gc[1])*gc[2]*(gc[2]-1.);
3742 devFunValue[32] = 0.25*gc[0]*(gc[0]+1.)*(1.-gc[1]*gc[1])*(2*gc[2]-1.);
3744 devFunValue[33] = 0.25*(-2*gc[0])*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]-1.);
3745 devFunValue[34] = 0.25*(1.-gc[0]*gc[0])*(2*gc[1]-1.)*gc[2]*(gc[2]-1.);
3746 devFunValue[35] = 0.25*(1.-gc[0]*gc[0])*gc[1]*(gc[1]-1.)*(2*gc[2]-1.);
3748 devFunValue[36] = 0.25*(2*gc[0]-1.)*(1.-gc[1]*gc[1])*gc[2]*(gc[2]+1.);
3749 devFunValue[37] = 0.25*gc[0]*(gc[0]-1.)*(-2*gc[1])*gc[2]*(gc[2]+1.);
3750 devFunValue[38] = 0.25*gc[0]*(gc[0]-1.)*(1.-gc[1]*gc[1])*(2*gc[2]+1.);
3752 devFunValue[39] = 0.25*(-2*gc[0])*gc[1]*(gc[1]+1.)*gc[2]*(gc[2]+1.);
3753 devFunValue[40] = 0.25*(1.-gc[0]*gc[0])*(2*gc[1]+1.)*gc[2]*(gc[2]+1.);
3754 devFunValue[41] = 0.25*(1.-gc[0]*gc[0])*gc[1]*(gc[1]+1.)*(2*gc[2]+1.);
3756 devFunValue[42] = 0.25*(2*gc[0]+1.)*(1.-gc[1]*gc[1])*gc[2]*(gc[2]+1.);
3757 devFunValue[43] = 0.25*gc[0]*(gc[0]+1.)*(-2*gc[1])*gc[2]*(gc[2]+1.);
3758 devFunValue[44] = 0.25*gc[0]*(gc[0]+1.)*(1.-gc[1]*gc[1])*(2*gc[2]+1.);
3760 devFunValue[45] = 0.25*(-2*gc[0])*gc[1]*(gc[1]-1.)*gc[2]*(gc[2]+1.);
3761 devFunValue[46] = 0.25*(1.-gc[0]*gc[0])*(2*gc[1]-1.)*gc[2]*(gc[2]+1.);
3762 devFunValue[47] = 0.25*(1.-gc[0]*gc[0])*gc[1]*(gc[1]-1.)*(2*gc[2]+1.);
3764 devFunValue[48] = 0.25*(2*gc[0]-1.)*gc[1]*(gc[1]-1.)*(1.-gc[2]*gc[2]);
3765 devFunValue[49] = 0.25*gc[0]*(gc[0]-1.)*(2*gc[1]-1.)*(1.-gc[2]*gc[2]);
3766 devFunValue[50] = 0.25*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]-1.)*(-2*gc[2]);
3768 devFunValue[51] = 0.25*(2*gc[0]-1.)*gc[1]*(gc[1]+1.)*(1.-gc[2]*gc[2]);
3769 devFunValue[52] = 0.25*gc[0]*(gc[0]-1.)*(2*gc[1]+1.)*(1.-gc[2]*gc[2]);
3770 devFunValue[53] = 0.25*gc[0]*(gc[0]-1.)*gc[1]*(gc[1]+1.)*(-2*gc[2]);
3772 devFunValue[54] = 0.25*(2*gc[0]+1.)*gc[1]*(gc[1]+1.)*(1.-gc[2]*gc[2]);
3773 devFunValue[55] = 0.25*gc[0]*(gc[0]+1.)*(2*gc[1]+1.)*(1.-gc[2]*gc[2]);
3774 devFunValue[56] = 0.25*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]+1.)*(-2*gc[2]);
3776 devFunValue[57] = 0.25*(2*gc[0]+1.)*gc[1]*(gc[1]-1.)*(1.-gc[2]*gc[2]);
3777 devFunValue[58] = 0.25*gc[0]*(gc[0]+1.)*(2*gc[1]-1.)*(1.-gc[2]*gc[2]);
3778 devFunValue[59] = 0.25*gc[0]*(gc[0]+1.)*gc[1]*(gc[1]-1.)*(-2*gc[2]);
3780 devFunValue[60] = 0.5*(-2*gc[0])*(1.-gc[1]*gc[1])*gc[2]*(gc[2]-1.);
3781 devFunValue[61] = 0.5*(1.-gc[0]*gc[0])*(-2*gc[1])*gc[2]*(gc[2]-1.);
3782 devFunValue[62] = 0.5*(1.-gc[0]*gc[0])*(1.-gc[1]*gc[1])*(2*gc[2]-1.);
3784 devFunValue[63] = 0.5*(2*gc[0]-1.)*(1.-gc[1]*gc[1])*(1.-gc[2]*gc[2]);
3785 devFunValue[64] = 0.5*gc[0]*(gc[0]-1.)*(-2*gc[1])*(1.-gc[2]*gc[2]);
3786 devFunValue[65] = 0.5*gc[0]*(gc[0]-1.)*(1.-gc[1]*gc[1])*(-2*gc[2]);
3788 devFunValue[66] = 0.5*(-2*gc[0])*gc[1]*(gc[1]+1.)*(1.-gc[2]*gc[2]);
3789 devFunValue[67] = 0.5*(1.-gc[0]*gc[0])*(2*gc[1]+1.)*(1.-gc[2]*gc[2]);
3790 devFunValue[68] = 0.5*(1.-gc[0]*gc[0])*gc[1]*(gc[1]+1.)*(-2*gc[2]);
3792 devFunValue[69] = 0.5*(2*gc[0]+1.)*(1.-gc[1]*gc[1])*(1.-gc[2]*gc[2]);
3793 devFunValue[70] = 0.5*gc[0]*(gc[0]+1.)*(-2*gc[1])*(1.-gc[2]*gc[2]);
3794 devFunValue[71] = 0.5*gc[0]*(gc[0]+1.)*(1.-gc[1]*gc[1])*(-2*gc[2]);
3796 devFunValue[72] = 0.5*(-2*gc[0])*gc[1]*(gc[1]-1.)*(1.-gc[2]*gc[2]);
3797 devFunValue[73] = 0.5*(1.-gc[0]*gc[0])*(2*gc[1]-1.)*(1.-gc[2]*gc[2]);
3798 devFunValue[74] = 0.5*(1.-gc[0]*gc[0])*gc[1]*(gc[1]-1.)*(-2*gc[2]);
3800 devFunValue[75] = 0.5*(-2*gc[0])*(1.-gc[1]*gc[1])*gc[2]*(gc[2]+1.);
3801 devFunValue[76] = 0.5*(1.-gc[0]*gc[0])*(-2*gc[1])*gc[2]*(gc[2]+1.);
3802 devFunValue[77] = 0.5*(1.-gc[0]*gc[0])*(1.-gc[1]*gc[1])*(2*gc[2]+1.);
3804 devFunValue[78] = (-2*gc[0])*(1.-gc[1]*gc[1])*(1.-gc[2]*gc[2]);
3805 devFunValue[79] = (1.-gc[0]*gc[0])*(-2*gc[1])*(1.-gc[2]*gc[2]);
3806 devFunValue[80] = (1.-gc[0]*gc[0])*(1.-gc[1]*gc[1])*(-2*gc[2]);
3808 DEV_SHAPE_FUN_MACRO_END;
3811 ////////////////////////////////////////////////////////////////////////////////////////////////
3812 // GAUSS COORD CLASS //
3813 ////////////////////////////////////////////////////////////////////////////////////////////////
3817 GaussCoords::GaussCoords()
3824 GaussCoords::~GaussCoords()
3826 GaussInfoVector::iterator it = _my_gauss_info.begin();
3827 for( ; it != _my_gauss_info.end(); it++ )
3835 * Add Gauss localization info
3837 void GaussCoords::addGaussInfo( NormalizedCellType theGeometry,
3839 const double* theGaussCoord,
3840 mcIdType theNbGauss,
3841 const double* theReferenceCoord,
3844 GaussInfoVector::iterator it = _my_gauss_info.begin();
3845 for( ; it != _my_gauss_info.end(); it++ )
3847 if( (*it)->getCellType() == theGeometry )
3853 DataVector aGaussCoord;
3854 for(int i = 0 ; i < theNbGauss*coordDim; i++ )
3855 aGaussCoord.push_back(theGaussCoord[i]);
3857 DataVector aReferenceCoord;
3858 for(int i = 0 ; i < theNbRef*coordDim; i++ )
3859 aReferenceCoord.push_back(theReferenceCoord[i]);
3862 GaussInfo* info = new GaussInfo( theGeometry, aGaussCoord, FromIdType<int>(theNbGauss), aReferenceCoord, FromIdType<int>(theNbRef));
3863 info->initLocalInfo();
3865 //If info with cell type doesn't exist add it
3866 if( it == _my_gauss_info.end() )
3868 _my_gauss_info.push_back(info);
3870 // If information exists, update it
3874 std::size_t index = std::distance(_my_gauss_info.begin(),it);
3876 _my_gauss_info[index] = info;
3882 * Calculate gauss points coordinates
3884 double* GaussCoords::calculateCoords( NormalizedCellType theGeometry,
3885 const double *theNodeCoords,
3886 const int theSpaceDim,
3887 const mcIdType *theIndex)
3889 const GaussInfo *info = getInfoGivenCellType(theGeometry);
3890 int nbCoords = theSpaceDim * info->getNbGauss();
3891 double *aCoords = new double[nbCoords];
3892 calculateCoordsAlg(info,theNodeCoords,theSpaceDim,theIndex,aCoords);
3897 void GaussCoords::calculateCoords( NormalizedCellType theGeometry, const double *theNodeCoords, const int theSpaceDim, const mcIdType *theIndex, double *result)
3899 const GaussInfo *info = getInfoGivenCellType(theGeometry);
3900 calculateCoordsAlg(info,theNodeCoords,theSpaceDim,theIndex,result);
3903 void GaussCoords::calculateCoordsAlg(const GaussInfo *info, const double* theNodeCoords, const int theSpaceDim, const mcIdType *theIndex, double *result)
3905 int aConn = info->getNbRef();
3907 int nbCoords = theSpaceDim * info->getNbGauss();
3908 std::fill(result,result+nbCoords,0.);
3910 for( int gaussId = 0; gaussId < info->getNbGauss(); gaussId++ )
3912 double *coord=result+gaussId*theSpaceDim;
3913 const double *function=info->getFunctionValues(gaussId);
3914 for ( int connId = 0; connId < aConn ; connId++ )
3916 const double* nodeCoord = theNodeCoords + (theIndex[connId]*theSpaceDim);
3917 for( int dimId = 0; dimId < theSpaceDim; dimId++ )
3918 coord[dimId] += nodeCoord[dimId]*function[connId];
3923 const GaussInfo *GaussCoords::getInfoGivenCellType(NormalizedCellType cellType)
3925 GaussInfoVector::const_iterator it = _my_gauss_info.begin();
3926 //Try to find gauss localization info
3927 for( ; it != _my_gauss_info.end() ; it++ )
3928 if( (*it)->getCellType()==cellType)
3930 throw INTERP_KERNEL::Exception("Can't find gauss localization information !");