KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
pfem_gid_io.h
Go to the documentation of this file.
1 /*
2 ==============================================================================
3 Kratos
4 A General Purpose Software for Multi-Physics Finite Element Analysis
5 Version 1.0 (Released on march 05, 2007).
6 
7 Copyright 2007
8 Pooyan Dadvand, Riccardo Rossi
9 pooyan@cimne.upc.edu
10 rrossi@cimne.upc.edu
11 CIMNE (International Center for Numerical Methods in Engineering),
12 Gran Capita' s/n, 08034 Barcelona, Spain
13 
14 Permission is hereby granted, free of charge, to any person obtaining
15 a copy of this software and associated documentation files (the
16 "Software"), to deal in the Software without restriction, including
17 without limitation the rights to use, copy, modify, merge, publish,
18 distribute, sublicense and/or sell copies of the Software, and to
19 permit persons to whom the Software is furnished to do so, subject to
20 the following condition:
21 
22 Distribution of this code for any commercial purpose is permissible
23 ONLY BY DIRECT ARRANGEMENT WITH THE COPYRIGHT OWNER.
24 
25 The above copyright notice and this permission notice shall be
26 included in all copies or substantial portions of the Software.
27 
28 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
29 EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
30 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
31 IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
32 CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
33 TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
34 SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
35 
36 ==============================================================================
37 */
38 
39 //
40 // Project Name: Kratos
41 // Last Modified by: $Author: anonymous $
42 // Date: $Date: 2009-01-15 14:50:34 $
43 // Revision: $Revision: 1.2 $
44 //
45 //
46 
47 #if !defined(KRATOS_PFEM_GID_IO_BASE_H_INCLUDED)
48 #define KRATOS_PFEM_GID_IO_BASE_H_INCLUDED
49 
50 // System includes
51 #include <string>
52 #include <iostream>
53 #include <fstream>
54 #include <sstream>
55 #include <cstddef>
56 
57 
58 // Project includes
59 #include "includes/define.h"
60 //#include "includes/datafile_io.h"
61 #include "includes/gid_io.h"
62 
63 namespace Kratos
64 {
73 
79 {
80 public:
82  PfemGidGaussPointsContainer( char* gp_title, KratosGeometryFamily geometryFamily,
83  GiD_ElementType gid_element_type,
84  int number_of_integration_points,
85  std::vector<int> index_container )
86  :mGPTitle(gp_title),mKratosElementFamily(geometryFamily),
87  mGidElementFamily(gid_element_type), mSize(number_of_integration_points),
88  mIndexContainer(index_container) {}
89 
90  bool AddElement( const ModelPart::ElementsContainerType::iterator pElemIt )
91  {
93  if( pElemIt->GetGeometry().GetGeometryFamily() == mKratosElementFamily
94  && pElemIt->GetGeometry().IntegrationPoints(
95  pElemIt->GetIntegrationMethod() ).size() == mSize )
96  {
97  mMeshElements.push_back( *(pElemIt.base() ) );
98  return true;
99  }
100  else return false;
101  KRATOS_CATCH("")
102  }
103 
104  bool AddCondition( const ModelPart::ConditionsContainerType::iterator pCondIt )
105  {
106  KRATOS_TRY
107  if( pCondIt->GetGeometry().GetGeometryFamily() == mKratosElementFamily
108  && pCondIt->GetGeometry().IntegrationPoints().size() == mSize )
109  {
110  mMeshConditions.push_back( *(pCondIt.base() ) );
111  return true;
112  }
113  else return false;
114  KRATOS_CATCH("")
115  }
116 
117  void PrintResults( Variable<double> rVariable, ModelPart& r_model_part,
118  double SolutionTag, int value_index = 0 )
119  {
120  if( mMeshElements.size() != 0 || mMeshConditions.size() != 0 )
121  {
123  GiD_BeginResult( (char *)(rVariable.Name()).c_str(), "Kratos", SolutionTag,
124  GiD_Scalar, GiD_OnGaussPoints, mGPTitle, NULL, 0, NULL );
125  std::vector<double> ValuesOnIntPoint(mSize);
126  if( mMeshElements.size() != 0 )
127  {
128  for( ModelPart::ElementsContainerType::iterator it = mMeshElements.begin();
129  it != mMeshElements.end(); it++ )
130  {
131  it->CalculateOnIntegrationPoints( rVariable, ValuesOnIntPoint,
132  r_model_part.GetProcessInfo() );
133  for(unsigned int i=0; i<mIndexContainer.size(); i++)
134  {
135  int index = mIndexContainer[i];
136  GiD_WriteScalar( it->Id(), ValuesOnIntPoint[index] );
137  }
138  }
139  }
140  if( mMeshConditions.size() != 0 )
141  {
142  for( ModelPart::ConditionsContainerType::iterator it = mMeshConditions.begin();
143  it != mMeshConditions.end(); it++ )
144  {
145  it->CalculateOnIntegrationPoints( rVariable, ValuesOnIntPoint,
146  r_model_part.GetProcessInfo() );
147  for(unsigned int i=0; i<mIndexContainer.size(); i++)
148  {
149  int index = mIndexContainer[i];
150  GiD_WriteScalar( it->Id(), ValuesOnIntPoint[index] );
151  }
152  }
153  }
154  GiD_EndResult();
155  }
156  }
157 
158  void PrintResults( Variable<Vector> rVariable, ModelPart& r_model_part,
159  double SolutionTag, int value_index = 0 )
160  {
161  if( mMeshElements.size() != 0 || mMeshConditions.size() != 0 )
162  {
164  GiD_BeginResult( (char *)(rVariable.Name()).c_str(), "Kratos", SolutionTag,
165  GiD_Vector, GiD_OnGaussPoints, mGPTitle, NULL, 0, NULL );
166  std::vector<Vector> ValuesOnIntPoint(mSize);
167  if( mMeshElements.size() != 0 )
168  {
169  for( ModelPart::ElementsContainerType::iterator it = mMeshElements.begin();
170  it != mMeshElements.end(); ++it )
171  {
172  it->CalculateOnIntegrationPoints( rVariable, ValuesOnIntPoint,
173  r_model_part.GetProcessInfo() );
174  for(unsigned int i=0; i<mIndexContainer.size(); i++)
175  {
176  int index = mIndexContainer[i];
177  if( ValuesOnIntPoint[0].size() == 3 )
178  GiD_WriteVector( it->Id(), ValuesOnIntPoint[index][0],
179  ValuesOnIntPoint[index][1], ValuesOnIntPoint[index][2] );
180  }
181  }
182  }
183  if( mMeshConditions.size() != 0 )
184  {
185  for( ModelPart::ConditionsContainerType::iterator it = mMeshConditions.begin();
186  it != mMeshConditions.end(); it++ )
187  {
188  it->CalculateOnIntegrationPoints( rVariable, ValuesOnIntPoint,
189  r_model_part.GetProcessInfo() );
190  for(unsigned int i=0; i<mIndexContainer.size(); i++)
191  {
192  int index = mIndexContainer[i];
193  if( ValuesOnIntPoint[0].size() == 3 )
194  GiD_WriteVector( it->Id(), ValuesOnIntPoint[index][0],
195  ValuesOnIntPoint[index][1], ValuesOnIntPoint[index][2] );
196  }
197  }
198  }
199  GiD_EndResult();
200  }
201  }
202 
203  void PrintResults( Variable<Matrix> rVariable, ModelPart& r_model_part,
204  double SolutionTag, int value_index = 0 )
205  {
206  if( mMeshElements.size() != 0 || mMeshConditions.size() != 0 )
207  {
209  GiD_BeginResult( (char *)(rVariable.Name()).c_str(), "Kratos", SolutionTag,
210  GiD_Matrix, GiD_OnGaussPoints, mGPTitle, NULL, 0, NULL );
211  std::vector<Matrix> ValuesOnIntPoint(mSize);
212  if( mMeshElements.size() != 0 )
213  {
214  for( ModelPart::ElementsContainerType::iterator it = mMeshElements.begin();
215  it != mMeshElements.end(); ++it )
216  {
217  it->CalculateOnIntegrationPoints( rVariable, ValuesOnIntPoint,
218  r_model_part.GetProcessInfo() );
219  for(unsigned int i=0; i<mIndexContainer.size(); i++)
220  {
221  int index = mIndexContainer[i];
222  if(ValuesOnIntPoint[index].size1() ==3
223  && ValuesOnIntPoint[index].size2() ==3)
224  GiD_Write3DMatrix( it->Id(), ValuesOnIntPoint[index](0,0),
225  ValuesOnIntPoint[index](1,1), ValuesOnIntPoint[index](2,2),
226  ValuesOnIntPoint[index](0,1), ValuesOnIntPoint[index](1,2),
227  ValuesOnIntPoint[index](0,2) );
228  if(ValuesOnIntPoint[index].size1() ==1
229  && ValuesOnIntPoint[index].size2() ==6)
230  GiD_Write3DMatrix( it->Id(), ValuesOnIntPoint[index](0,0),
231  ValuesOnIntPoint[index](0,1), ValuesOnIntPoint[index](0,2),
232  ValuesOnIntPoint[index](0,3), ValuesOnIntPoint[index](0,4),
233  ValuesOnIntPoint[index](0,5) );
234  }
235  }
236  }
237  if( mMeshConditions.size() != 0 )
238  {
239  for( ModelPart::ConditionsContainerType::iterator it = mMeshConditions.begin();
240  it != mMeshConditions.end(); it++ )
241  {
242  it->CalculateOnIntegrationPoints( rVariable, ValuesOnIntPoint,
243  r_model_part.GetProcessInfo() );
244  for(unsigned int i=0; i<mIndexContainer.size(); i++)
245  {
246  int index = mIndexContainer[i];
247  if(ValuesOnIntPoint[index].size1() ==3
248  && ValuesOnIntPoint[index].size2() ==3)
249  GiD_Write3DMatrix( it->Id(), ValuesOnIntPoint[index](0,0),
250  ValuesOnIntPoint[index](1,1), ValuesOnIntPoint[index](2,2),
251  ValuesOnIntPoint[index](0,1), ValuesOnIntPoint[index](1,2),
252  ValuesOnIntPoint[index](0,2) );
253  if(ValuesOnIntPoint[index].size1() ==1
254  && ValuesOnIntPoint[index].size2() ==6)
255  GiD_Write3DMatrix( it->Id(), ValuesOnIntPoint[index](0,0),
256  ValuesOnIntPoint[index](0,1), ValuesOnIntPoint[index](0,2),
257  ValuesOnIntPoint[index](0,3), ValuesOnIntPoint[index](0,4),
258  ValuesOnIntPoint[index](0,5) );
259  }
260  }
261  }
262  GiD_EndResult();
263  }
264  }
265 
266  void Reset()
267  {
268  mMeshElements.clear();
269  mMeshConditions.clear();
270  }
271 
272 protected:
274  {
275  //setting up gauss points
276  if( mGidElementFamily == GiD_Tetrahedra && mSize == 5 )
277  {
278  GiD_BeginGaussPoint( mGPTitle, GiD_Tetrahedra, NULL, 4, 0, 0 );
279  GiD_WriteGaussPoint3D( 1.0/6.0, 1.0/6.0, 1.0/6.0 );
280  GiD_WriteGaussPoint3D( 1.0/2.0, 1.0/6.0, 1.0/6.0 );
281  GiD_WriteGaussPoint3D( 1.0/6.0, 1.0/2.0, 1.0/6.0 );
282  GiD_WriteGaussPoint3D( 1.0/6.0, 1.0/6.0, 1.0/2.0 );
283  GiD_EndGaussPoint();
284  }
285  else if( mGidElementFamily == GiD_Tetrahedra && mSize == 10 )
286  {
287  GiD_BeginGaussPoint("tet10_element_gp", GiD_Tetrahedra, NULL, 4, 0, 0);
288  GiD_WriteGaussPoint3D( 1.0/14.0, 1.0/14.0, 1.0/14.0 );
289  GiD_WriteGaussPoint3D( 11.0/14.0, 1.0/14.0, 1.0/14.0 );
290  GiD_WriteGaussPoint3D( 1.0/14.0, 11.0/14.0, 1.0/14.0 );
291  GiD_WriteGaussPoint3D( 1.0/14.0, 1.0/14.0, 11.0/14.0 );
292  GiD_EndGaussPoint();
293  }
294  else
295  {
296  GiD_BeginGaussPoint(mGPTitle, mGidElementFamily, NULL,
297  mSize, 0, 1);
298  GiD_EndGaussPoint();
299  }
300  }
301 
304  GiD_ElementType mGidElementFamily;
305  std::vector<int> mIndexContainer;
306  int mSize;
307  char* mGPTitle;
310 };//class PfemGidGaussPointsContainer
311 
317 {
318 public:
321  GiD_ElementType elementType, char* mesh_title )
322  :mGeometryType(geometryType), mGidElementType(elementType), mMeshTitle(mesh_title) {}
323 
324  bool AddElement( const ModelPart::ElementsContainerType::iterator pElemIt )
325  {
326  KRATOS_TRY
327  if( pElemIt->GetGeometry().GetGeometryType() == mGeometryType )
328  {
329  mMeshElements.push_back( *(pElemIt.base() ) );
330  Geometry<Node >&geom = pElemIt->GetGeometry();
331  for( Element::GeometryType::iterator it = geom.begin(); it != geom.end(); it++)
332  {
333  mMeshNodes.push_back( *(it.base() ) );
334  }
335  return true;
336  }
337  else
338  return false;
339  KRATOS_CATCH("")
340  }
341 
342  bool AddCondition(const ModelPart::ConditionsContainerType::iterator pCondIt)
343  {
344  KRATOS_TRY
345  if( pCondIt->GetGeometry().GetGeometryType() == mGeometryType )
346  {
347  mMeshConditions.push_back( *(pCondIt.base() ) );
348  Geometry<Node >&geom = pCondIt->GetGeometry();
349  for( Condition::GeometryType::iterator it = geom.begin(); it != geom.end(); it++)
350  {
351  mMeshNodes.push_back( *(it.base() ) );
352  }
353  return true;
354  }
355  else
356  return false;
357  KRATOS_CATCH("")
358  }
359 
361  {
362  if( mMeshElements.size() != 0 )
363  {
364  mMeshNodes.Unique();
365  }
366  }
367 
368  void WriteMesh(bool deformed)
369  {
370  KRATOS_TRY
371  if( mMeshElements.size() != 0 )
372  {
373  if( mMeshElements.begin()->GetGeometry().WorkingSpaceDimension() == 2 )
374  {
375  std::cout << "writing a 2D mesh" << std::endl;
376  GiD_BeginMesh( "Volume mesh", GiD_2D, mGidElementType,
377  mMeshElements.begin()->GetGeometry().size() );
378  }
379  else if( mMeshElements.begin()->GetGeometry().WorkingSpaceDimension() == 3 )
380  {
381  std::cout << "writing a 3D mesh" << std::endl;
382  GiD_BeginMesh( "Volume mesh", GiD_3D, mGidElementType,
383  mMeshElements.begin()->GetGeometry().size() );
384  }
385  else
386  KRATOS_THROW_ERROR(std::logic_error,"check working space dimension of model","");
387  //printing nodes
388  GiD_BeginCoordinates();
389  for( ModelPart::NodesContainerType::iterator it = mMeshNodes.begin();
390  it != mMeshNodes.end(); ++it )
391  {
392  if( deformed )
393  GiD_WriteCoordinates( (it)->Id(), (it)->X(),
394  (it)->Y(), (it)->Z());
395  else
396  GiD_WriteCoordinates( (it)->Id(), (it)->X0(),
397  (it)->Y0(), (it)->Z0());
398  }
399  GiD_EndCoordinates();
400  //printing elements
401  GiD_BeginElements();
402  int* nodes_id = new int[mMeshElements.begin()->GetGeometry().size()+1];
403  for( ModelPart::ElementsContainerType::iterator it = mMeshElements.begin();
404  it != mMeshElements.end(); ++it )
405  {
406  for( unsigned int i=0; i<(it)->GetGeometry().size(); i++ )
407  nodes_id[i] = (it)->GetGeometry()[i].Id();
408 
409  //setting the color for either fluid or solid or contact element
410  unsigned int n_fl=0;
411  unsigned int n_str=0;
412  unsigned int n_intf=0;
413  unsigned int color=13;
414  for ( unsigned int i=0; i<(it)->GetGeometry().size(); i++ )
415  {
416  n_fl += it->GetGeometry()[i].FastGetSolutionStepValue(IS_FLUID);
417  n_str+= it->GetGeometry()[i].FastGetSolutionStepValue(IS_STRUCTURE);
418  n_intf+= it->GetGeometry()[i].FastGetSolutionStepValue(IS_INTERFACE);
419  }
420  if (n_fl==(it)->GetGeometry().size() && n_intf!=30)// && n_str!= (it)->GetGeometry().size())
421  {
422  color=4;
423  }
424  if (n_str==(it)->GetGeometry().size())// && n_fl!=(it)->GetGeometry().size())
425  {
426  color=14;
427  }
428  if (n_intf==30)// && n_fl!=(it)->GetGeometry().size())
429  {
430  color=5;
431  }
432  nodes_id[(it)->GetGeometry().size()]= color;
433 
434  GiD_WriteElementMat((it)->Id(), nodes_id);
435  }
436  delete [] nodes_id;
437  GiD_EndElements();
438  GiD_EndMesh();
439  }
440  if( mMeshConditions.size() != 0 )
441  {
442  KRATOS_WATCH( mMeshConditions.begin()->GetGeometry().WorkingSpaceDimension() )
443 
444  if( mMeshConditions.begin()->GetGeometry().WorkingSpaceDimension() == 3 )
445  {
446  std::cout << "writing a 3D mesh of the faces" << std::endl;
447  GiD_BeginMesh( "Surface Structure Mesh", GiD_3D, GiD_Triangle, 3);
448  }
449  else
450  KRATOS_THROW_ERROR(std::logic_error,"Check your space dimensions","");
451  //printing nodes
452  GiD_BeginCoordinates();
453 
454  GiD_EndCoordinates();
455  //printing elements
456  GiD_BeginElements();
457  //for every face of tetrahedron we create a list of its nodes
458  int* nodes_id = new int[4];
459 
460 
461  for( ModelPart::ConditionsContainerType::iterator it = mMeshConditions.begin();
462  it != mMeshConditions.end(); ++it )
463  {
464  for( unsigned int i=0; i<(it)->GetGeometry().size(); i++ )
465  nodes_id[i] = (it)->GetGeometry()[i].Id();
466 
467  unsigned int n_str=0;
468 
469  unsigned int n_free_surf=0;
470 
471  for (int i=0; i<3; i++)
472  {
473  n_free_surf+=(it)->GetGeometry()[i].FastGetSolutionStepValue(IS_FREE_SURFACE);
474  n_str+=(it)->GetGeometry()[i].FastGetSolutionStepValue(IS_STRUCTURE);
475  }
476  if (n_str==it->GetGeometry().size())// && n_free_surf!=it->GetGeometry().size())
477  {
478  nodes_id[3]=3;
479  GiD_WriteElementMat((it)->Id(), nodes_id);
480  }
481 
482  }
483  delete [] nodes_id;
484  GiD_EndElements();
485  GiD_EndMesh();
486  }
487  if( mMeshConditions.size() != 0 )
488  {
489  KRATOS_WATCH( mMeshConditions.begin()->GetGeometry().WorkingSpaceDimension() )
490  if( mMeshConditions.begin()->GetGeometry().WorkingSpaceDimension() == 3 )
491  {
492  std::cout << "writing a 3D mesh of the faces" << std::endl;
493  GiD_BeginMesh( "Surface Fluid Mesh", GiD_3D, GiD_Triangle, 3);
494  }
495  else
496  KRATOS_THROW_ERROR(std::logic_error,"Check your space dimensions","");
497 
498  //now writing the fluid surface mesh
499  //printing nodes
500  GiD_BeginCoordinates();
501 
502  GiD_EndCoordinates();
503  //printing elements
504  GiD_BeginElements();
505  //for every face of tetrahedron we create a list of its nodes
506  //int* nodes_id = new int[4];
507 
508 
509  int* nodes_id = new int[4];
510 
511 
512 
513  for( ModelPart::ConditionsContainerType::iterator it = mMeshConditions.begin();
514  it != mMeshConditions.end(); ++it )
515  {
516  for( unsigned int i=0; i<(it)->GetGeometry().size(); i++ )
517  nodes_id[i] = (it)->GetGeometry()[i].Id();
518  unsigned int n_fl=0;
519  unsigned int n_str=0;
520 
521  for (int i=0; i<3; i++)
522  {
523  n_str+=(it)->GetGeometry()[i].FastGetSolutionStepValue(IS_STRUCTURE);
524  n_fl+=(it)->GetGeometry()[i].FastGetSolutionStepValue(IS_FLUID);
525 
526  }
527  //if (n_free_surf==it->GetGeometry().size())
528  // nodes_id[3]=1;
529  if (n_fl==it->GetGeometry().size())
530  {
531  //the color of water
532  nodes_id[3]=6;
533  GiD_WriteElementMat((it)->Id(), nodes_id);
534  }
535 
536  }
537  delete [] nodes_id;
538  GiD_EndElements();
539  GiD_EndMesh();
540  }
541 
542  KRATOS_CATCH("")
543  }
544 
545  void Reset()
546  {
547  mMeshNodes.clear();
548  mMeshElements.clear();
549  mMeshConditions.clear();
550  }
551 
552 private:
554  GeometryData::KratosGeometryType mGeometryType;
555  GiD_ElementType mGidElementType;
557  ModelPart::ElementsContainerType mMeshElements;
558  ModelPart::ConditionsContainerType mMeshConditions;
559  char* mMeshTitle;
560 };//class PfemGidMeshContainer
561 
562 }// namespace Kratos.
563 
564 
565 #endif // KRATOS_PFEM_GID_IO_BASE_H_INCLUDED defined
KratosGeometryType
Definition: geometry_data.h:110
IntegrationMethod
Definition: geometry_data.h:76
KratosGeometryFamily
Definition: geometry_data.h:91
Geometry base class.
Definition: geometry.h:71
PointsArrayType::iterator iterator
PointsArrayType typedefs.
Definition: geometry.h:213
iterator begin()
Definition: geometry.h:465
iterator end()
Definition: geometry.h:473
This class aims to manage meshes for multi-physics simulations.
Definition: model_part.h:77
MeshType::ConditionsContainerType ConditionsContainerType
Condintions container. A vector set of Conditions with their Id's as key.
Definition: model_part.h:183
MeshType::ElementsContainerType ElementsContainerType
Element container. A vector set of Elements with their Id's as key.
Definition: model_part.h:168
ProcessInfo & GetProcessInfo()
Definition: model_part.h:1746
MeshType::NodesContainerType NodesContainerType
Nodes container. Which is a vector set of nodes with their Id's as key.
Definition: model_part.h:128
Definition: pfem_gid_io.h:79
int mSize
Definition: pfem_gid_io.h:306
void PrintResults(Variable< double > rVariable, ModelPart &r_model_part, double SolutionTag, int value_index=0)
Definition: pfem_gid_io.h:117
ModelPart::ConditionsContainerType mMeshConditions
Definition: pfem_gid_io.h:309
GiD_ElementType mGidElementFamily
Definition: pfem_gid_io.h:304
void PrintResults(Variable< Vector > rVariable, ModelPart &r_model_part, double SolutionTag, int value_index=0)
Definition: pfem_gid_io.h:158
KratosGeometryFamily mKratosElementFamily
member variables
Definition: pfem_gid_io.h:303
void Reset()
Definition: pfem_gid_io.h:266
char * mGPTitle
Definition: pfem_gid_io.h:307
bool AddCondition(const ModelPart::ConditionsContainerType::iterator pCondIt)
Definition: pfem_gid_io.h:104
void WriteGaussPoints()
Definition: pfem_gid_io.h:273
bool AddElement(const ModelPart::ElementsContainerType::iterator pElemIt)
Definition: pfem_gid_io.h:90
std::vector< int > mIndexContainer
Definition: pfem_gid_io.h:305
ModelPart::ElementsContainerType mMeshElements
Definition: pfem_gid_io.h:308
void PrintResults(Variable< Matrix > rVariable, ModelPart &r_model_part, double SolutionTag, int value_index=0)
Definition: pfem_gid_io.h:203
PfemGidGaussPointsContainer(char *gp_title, KratosGeometryFamily geometryFamily, GiD_ElementType gid_element_type, int number_of_integration_points, std::vector< int > index_container)
Constructor.
Definition: pfem_gid_io.h:82
Definition: pfem_gid_io.h:317
PfemGidMeshContainer(GeometryData::KratosGeometryType geometryType, GiD_ElementType elementType, char *mesh_title)
Constructor.
Definition: pfem_gid_io.h:320
void FinalizeMeshCreation()
Definition: pfem_gid_io.h:360
bool AddElement(const ModelPart::ElementsContainerType::iterator pElemIt)
Definition: pfem_gid_io.h:324
void WriteMesh(bool deformed)
Definition: pfem_gid_io.h:368
void Reset()
Definition: pfem_gid_io.h:545
bool AddCondition(const ModelPart::ConditionsContainerType::iterator pCondIt)
Definition: pfem_gid_io.h:342
const std::string & Name() const
Definition: variable_data.h:201
#define KRATOS_THROW_ERROR(ExceptionType, ErrorMessage, MoreInfo)
Definition: define.h:77
#define KRATOS_CATCH(MoreInfo)
Definition: define.h:110
#define KRATOS_WATCH(variable)
Definition: define.h:806
#define KRATOS_TRY
Definition: define.h:109
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
GeometryData::IntegrationMethod IntegrationMethodType
Definition: gid_gauss_point_container.h:44
ModelPart::ConditionsContainerType ConditionsArrayType
Definition: gid_gauss_point_container.h:43
ModelPart::NodesContainerType NodesArrayType
Definition: gid_gauss_point_container.h:42
ModelPart::ElementsContainerType ElementsArrayType
Definition: gid_gauss_point_container.h:41
GeometryData::KratosGeometryFamily KratosGeometryFamily
Definition: gid_gauss_point_container.h:45
color
Definition: all_t_win_vs_m_fixed_error.py:230
integer i
Definition: TensorModule.f:17