OOFEM  2.4
OOFEM.org - Object Oriented Finite Element Solver
trplanstrssxfem.C
Go to the documentation of this file.
1 /*
2  * trplanstrssxfem.C
3  *
4  * Created on: Jun 3, 2013
5  * Author: svennine
6  */
7 
8 #include "../sm/Elements/PlaneStress/trplanstrssxfem.h"
9 
10 #include "../sm/Materials/structuralmaterial.h"
11 #include "../sm/CrossSections/structuralcrosssection.h"
12 #include "vtkxmlexportmodule.h"
15 #include "xfem/enrichmentitem.h"
16 #include "xfem/delaunay.h"
17 #include "xfem/XFEMDebugTools.h"
18 #include "feinterpol.h"
19 #include "node.h"
20 #include "crosssection.h"
21 #include "gausspoint.h"
22 #include "gaussintegrationrule.h"
23 #include "floatmatrix.h"
24 #include "floatarray.h"
25 #include "intarray.h"
26 #include "mathfem.h"
27 #include "classfactory.h"
28 #include "dynamicinputrecord.h"
29 
30 #ifdef __OOFEG
31  #include "oofeggraphiccontext.h"
32  #include "oofegutils.h"
34 #endif
35 
36 
37 
38 #include <string>
39 #include <sstream>
40 
41 
42 namespace oofem {
43 REGISTER_Element(TrPlaneStress2dXFEM);
44 
46 {
49 }
50 
52 {
55 }
56 
57 
59 
61 {
63  return 1;
64 }
65 
66 Interface *
68 {
69  if ( it == XfemElementInterfaceType ) {
70  return static_cast< XfemElementInterface * >(this);
71  } else if ( it == VTKXMLExportModuleElementInterfaceType ) {
72  return static_cast< VTKXMLExportModuleElementInterface * >(this);
73  } else {
75  }
76 }
77 
79 {
80  int ndofs = 0;
81 
82  for ( int i = 1; i <= this->giveNumberOfDofManagers(); i++ ) {
83  ndofs += this->giveDofManager(i)->giveNumberOfDofs();
84  }
85 
86  return ndofs;
87 }
88 
90 {
91  if ( giveDomain()->hasXfemManager() ) {
93 
94  if ( xMan->isElementEnriched(this) ) {
97  }
98  } else {
100  }
101  } else {
103  }
104 }
105 
107 {
108  XfemElementInterface_createEnrBmatrixAt(answer, * gp, * this);
109 }
110 
112 {
113  XfemElementInterface_createEnrBHmatrixAt(answer, * gp, * this);
114 }
115 
117 {
118  XfemElementInterface_createEnrNmatrixAt(answer, iLocCoord, * this, false);
119 }
120 
121 
122 
123 void
125 {
126  // Continuous part
128 
129  // Discontinuous part
130  if( this->giveDomain()->hasXfemManager() ) {
131  DofManager *dMan = giveDofManager(inode);
133 
134  int placeInArray = domain->giveDofManPlaceInArray(dMan->giveGlobalNumber());
135  const std::vector<int> &nodeEiIndices = xMan->giveNodeEnrichmentItemIndices( placeInArray );
136  for ( size_t i = 0; i < nodeEiIndices.size(); i++ ) {
137  EnrichmentItem *ei = xMan->giveEnrichmentItem(nodeEiIndices[i]);
138  if ( ei->isDofManEnriched(* dMan) ) {
139  IntArray eiDofIdArray;
140  ei->computeEnrichedDofManDofIdArray(eiDofIdArray, *dMan);
141  answer.followedBy(eiDofIdArray);
142  }
143  }
144  }
145 }
146 
147 void
149 {
151 }
152 
153 void
155 {
157 }
158 
160 {
161  TrPlaneStress2d :: computeStiffnessMatrix(answer, rMode, tStep);
163 
164 
165  const double tol = mRegCoeffTol;
166  const double regularizationCoeff = mRegCoeff;
167  int numRows = answer.giveNumberOfRows();
168  for(int i = 0; i < numRows; i++) {
169  if( fabs(answer(i,i)) < tol ) {
170  answer(i,i) += regularizationCoeff;
171 // printf("Found zero on diagonal.\n");
172  }
173  }
174 }
175 
177 {
179 }
180 
181 void
183 {
184  TrPlaneStress2d :: giveInternalForcesVector(answer, tStep, useUpdatedGpRecord);
186 
187 
188 #if 0
189  // Contribution from regularization
191  FloatMatrix K;
192  computeStiffnessMatrix(K, TangentStiffness, tStep);
193 
194  FloatArray u;
195  this->computeVectorOf(VM_Total, tStep, u);
196  // subtract initial displacements, if defined
197  if ( initialDisplacements ) {
199  }
200 
201  const double tol = mRegCoeffTol+mRegCoeff;
202  const double regularizationCoeff = mRegCoeff;
203  int numRows = K.giveNumberOfRows();
204  for(int i = 0; i < numRows; i++) {
205  if( fabs(K(i,i)) < tol ) {
206  answer(i) += regularizationCoeff*u(i);
207 // printf("Found zero on diagonal.\n");
208  }
209  }
210 #endif
211 }
212 
213 
216 {
217  if ( this->giveDomain()->hasXfemManager() ) {
218  XfemManager *xMan = this->giveDomain()->giveXfemManager();
219  if ( xMan->isElementEnriched(this) ) {
220  return EGT_Composite;
221  } else {
222  return EGT_Composite;
223  }
224  } else {
225  return EGT_triangle_1;
226  }
227 }
228 
229 #ifdef __OOFEG
230 // TODO: FIX OOFEG implementation
232 {
233  if ( !gc.testElementGraphicActivity(this) ) {
234  return;
235  }
236 
237  XfemManager *xf = this->giveDomain()->giveXfemManager();
238  if ( !xf->isElementEnriched(this) ) {
240  } else {
241  if ( integrationRulesArray.size() > 1 ) {
242 #if 0
243  for ( auto &ir: integrationRulesArray ) {
244  // TODO: Implement visualization.
245  PatchIntegrationRule *iRule = dynamic_cast< PatchIntegrationRule * >( ir );
246  if ( iRule ) {
247  iRule->givePatch()->draw(gc);
248  }
249  }
250 #endif
251  } else {
253  }
254  }
255 }
256 
258 {
259  if ( !gc.testElementGraphicActivity(this) ) {
260  return;
261  }
262 
263  XfemManager *xf = this->giveDomain()->giveXfemManager();
264  if ( !xf->isElementEnriched(this) ) {
266  } else {
267  if ( gc.giveIntVarMode() == ISM_local ) {
268  int indx;
269  double val;
270  FloatArray s(3), v;
271 
272  indx = gc.giveIntVarIndx();
273 
274  for ( auto &ir: integrationRulesArray ) {
275  PatchIntegrationRule *iRule = dynamic_cast< PatchIntegrationRule * >(ir.get());
276 
277  #if 0
278  val = iRule->giveMaterial();
279  #else
280  val = 0.0;
281  for ( GaussPoint *gp: *iRule ) {
282  giveIPValue(v, gp, gc.giveIntVarType(), tStep);
283  val += v.at(indx);
284  }
285 
286  val /= iRule->giveNumberOfIntegrationPoints();
287  #endif
288  s.at(1) = s.at(2) = s.at(3) = val;
289  // TODO: Implement visualization.
290  // iRule->givePatch()->drawWD(gc, s);
291  }
292  } else {
294  }
295  }
296 }
297 #endif
298 
301 {
302  IRResultType result; // Required by IR_GIVE_FIELD macro
304  if ( result != IRRT_OK ) {
305  return result;
306  }
307 
309  if ( result != IRRT_OK ) {
310  return result;
311  }
312 
315  }
316 
319  }
320 
321  return result;
322 }
323 
325 {
327 }
328 
330 {
333 
336 
337 }
338 
339 
340 void
342 {
343  // TODO: Validate implementation.
344 
345  FloatArray u;
346  FloatMatrix n;
347 
348  XfemElementInterface_createEnrNmatrixAt(n, lcoords, * this, false);
349 
350  this->computeVectorOf(mode, tStep, u);
351  answer.beProductOf(n, u);
352 }
353 
354 
355 void
357 {
358  // TODO: For now, take only the continuous part
360 }
361 
362 void
363 TrPlaneStress2dXFEM :: giveCompositeExportData(std::vector< VTKPiece > &vtkPieces, IntArray &primaryVarsToExport, IntArray &internalVarsToExport, IntArray cellVarsToExport, TimeStep *tStep)
364 {
365  vtkPieces.resize(1);
366 
367  const int numCells = mSubTri.size();
368  if(numCells == 0) {
369  // Enriched but uncut element
370  // Visualize as a triangle
371  vtkPieces[0].setNumberOfCells(1);
372 
373  int numTotalNodes = 3;
374  vtkPieces[0].setNumberOfNodes(numTotalNodes);
375 
376  // Node coordinates
377  std :: vector< FloatArray >nodeCoords;
378  for(int i = 1; i <= 3; i++) {
380  nodeCoords.push_back(x);
381 
382  vtkPieces[0].setNodeCoords(i, x);
383  }
384 
385  // Connectivity
386  IntArray nodes1 = {1, 2, 3};
387  vtkPieces[0].setConnectivity(1, nodes1);
388 
389  // Offset
390  int offset = 3;
391  vtkPieces[0].setOffset(1, offset);
392 
393  // Cell types
394  vtkPieces[0].setCellType(1, 5); // Linear triangle
395 
396 
397 
398 
399  // Export nodal variables from primary fields
400  vtkPieces[0].setNumberOfPrimaryVarsToExport(primaryVarsToExport.giveSize(), numTotalNodes);
401 
402  for ( int fieldNum = 1; fieldNum <= primaryVarsToExport.giveSize(); fieldNum++ ) {
403  UnknownType type = ( UnknownType ) primaryVarsToExport.at(fieldNum);
404 
405  for ( int nodeInd = 1; nodeInd <= numTotalNodes; nodeInd++ ) {
406 
407  if ( type == DisplacementVector ) { // compute displacement
408 
409  FloatArray u = {0.0, 0.0, 0.0};
410 
411  // Fetch global coordinates (in undeformed configuration)
412  const FloatArray &x = nodeCoords[nodeInd-1];
413 
414  // Compute local coordinates
415  FloatArray locCoord;
416  computeLocalCoordinates(locCoord, x);
417 
418  // Compute displacement in point
419  FloatMatrix NMatrix;
420  computeNmatrixAt(locCoord, NMatrix);
421  FloatArray solVec;
422  computeVectorOf(VM_Total, tStep, solVec);
423  FloatArray uTemp;
424  uTemp.beProductOf(NMatrix, solVec);
425 
426  if(uTemp.giveSize() == 3) {
427  u = uTemp;
428  }
429  else {
430  u = {uTemp[0], uTemp[1], 0.0};
431  }
432 
433  vtkPieces[0].setPrimaryVarInNode(fieldNum, nodeInd, u);
434  } else {
435  printf("fieldNum: %d\n", fieldNum);
436  // TODO: Implement
437 // ZZNodalRecoveryMI_recoverValues(values, layer, ( InternalStateType ) 1, tStep); // does not work well - fix
438 // for ( int j = 1; j <= numCellNodes; j++ ) {
439 // vtkPiece.setPrimaryVarInNode(fieldNum, nodeNum, values [ j - 1 ]);
440 // nodeNum += 1;
441 // }
442  }
443  }
444  }
445 
446 
447  // Export nodal variables from internal fields
448  vtkPieces[0].setNumberOfInternalVarsToExport(0, numTotalNodes);
449 
450 
451  // Export cell variables
452  vtkPieces[0].setNumberOfCellVarsToExport(cellVarsToExport.giveSize(), 1);
453  for ( int i = 1; i <= cellVarsToExport.giveSize(); i++ ) {
454  InternalStateType type = ( InternalStateType ) cellVarsToExport.at(i);
455  FloatArray average;
456  std :: unique_ptr< IntegrationRule > &iRule = integrationRulesArray [ 0 ];
457  VTKXMLExportModule :: computeIPAverage(average, iRule.get(), this, type, tStep);
458  if(average.giveSize() == 0) {
459  average = {0., 0., 0., 0., 0., 0.};
460  }
461 
462  if(average.giveSize() == 1) {
463  vtkPieces[0].setCellVar( i, 1, average );
464  }
465 
466  if(average.giveSize() == 6) {
467  FloatArray averageV9(9);
468  averageV9.at(1) = average.at(1);
469  averageV9.at(5) = average.at(2);
470  averageV9.at(9) = average.at(3);
471  averageV9.at(6) = averageV9.at(8) = average.at(4);
472  averageV9.at(3) = averageV9.at(7) = average.at(5);
473  averageV9.at(2) = averageV9.at(4) = average.at(6);
474 
475  vtkPieces[0].setCellVar( i, 1, averageV9 );
476  }
477  }
478 
479 
480  // Export of XFEM related quantities
481  if ( domain->hasXfemManager() ) {
483 
484  int nEnrIt = xMan->giveNumberOfEnrichmentItems();
485  vtkPieces[0].setNumberOfInternalXFEMVarsToExport(xMan->vtkExportFields.giveSize(), nEnrIt, numTotalNodes);
486 
487  const int nDofMan = giveNumberOfDofManagers();
488 
489 
490  for ( int field = 1; field <= xMan->vtkExportFields.giveSize(); field++ ) {
491  XFEMStateType xfemstype = ( XFEMStateType ) xMan->vtkExportFields [ field - 1 ];
492 
493  for ( int enrItIndex = 1; enrItIndex <= nEnrIt; enrItIndex++ ) {
494  EnrichmentItem *ei = xMan->giveEnrichmentItem(enrItIndex);
495  for ( int nodeInd = 1; nodeInd <= numTotalNodes; nodeInd++ ) {
496 
497  const FloatArray &x = nodeCoords[nodeInd-1];
498  FloatArray locCoord;
499  computeLocalCoordinates(locCoord, x);
500 
501  FloatArray N;
503  interp->evalN( N, locCoord, FEIElementGeometryWrapper(this) );
504 
505 
506  if ( xfemstype == XFEMST_LevelSetPhi ) {
507  double levelSet = 0.0, levelSetInNode = 0.0;
508 
509  for(int elNodeInd = 1; elNodeInd <= nDofMan; elNodeInd++) {
510  DofManager *dMan = giveDofManager(elNodeInd);
511  ei->evalLevelSetNormalInNode(levelSetInNode, dMan->giveGlobalNumber(), *(dMan->giveCoordinates()) );
512 
513  levelSet += N.at(elNodeInd)*levelSetInNode;
514  }
515 
516 
517  FloatArray valueArray = {levelSet};
518  vtkPieces[0].setInternalXFEMVarInNode(field, enrItIndex, nodeInd, valueArray);
519 
520  } else if ( xfemstype == XFEMST_LevelSetGamma ) {
521  double levelSet = 0.0, levelSetInNode = 0.0;
522 
523  for(int elNodeInd = 1; elNodeInd <= nDofMan; elNodeInd++) {
524  DofManager *dMan = giveDofManager(elNodeInd);
525  ei->evalLevelSetTangInNode(levelSetInNode, dMan->giveGlobalNumber(), *(dMan->giveCoordinates()) );
526 
527  levelSet += N.at(elNodeInd)*levelSetInNode;
528  }
529 
530 
531  FloatArray valueArray = {levelSet};
532  vtkPieces[0].setInternalXFEMVarInNode(field, enrItIndex, nodeInd, valueArray);
533 
534  } else if ( xfemstype == XFEMST_NodeEnrMarker ) {
535  double nodeEnrMarker = 0.0, nodeEnrMarkerInNode = 0.0;
536 
537  for(int elNodeInd = 1; elNodeInd <= nDofMan; elNodeInd++) {
538  DofManager *dMan = giveDofManager(elNodeInd);
539  ei->evalNodeEnrMarkerInNode(nodeEnrMarkerInNode, dMan->giveGlobalNumber() );
540 
541  nodeEnrMarker += N.at(elNodeInd)*nodeEnrMarkerInNode;
542  }
543 
544 
545  FloatArray valueArray = {nodeEnrMarker};
546  vtkPieces[0].setInternalXFEMVarInNode(field, enrItIndex, nodeInd, valueArray);
547  }
548 
549  }
550  }
551  }
552  }
553 
554  }
555  else {
556  // Enriched and cut element
557 
558  XfemStructuralElementInterface::giveSubtriangulationCompositeExportData(vtkPieces, primaryVarsToExport, internalVarsToExport, cellVarsToExport, tStep);
559 
560 
561  }
562 
563 }
564 
565 } /* namespace oofem */
virtual void drawScalar(oofegGraphicContext &gc, TimeStep *tStep)
int testElementGraphicActivity(Element *)
Test if particular element passed fulfills various filtering criteria for its graphics output...
InternalStateType
Type representing the physical meaning of element or constitutive model internal variable.
void setField(int item, InputFieldType id)
void subtract(const FloatArray &src)
Subtracts array src to receiver.
Definition: floatarray.C:258
#define _IFT_TrPlaneStress2dXFEM_RegCoeff
virtual void giveInternalForcesVector(FloatArray &answer, TimeStep *tStep, int useUpdatedGpRecord)
Evaluates nodal representation of real internal forces.
Abstract class representing entity, which is included in the FE model using one (or more) global func...
virtual void XfemElementInterface_computeDeformationGradientVector(FloatArray &answer, GaussPoint *gp, TimeStep *tStep)
virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep)
Returns the integration point corresponding value in full form.
bool evalNodeEnrMarkerInNode(double &oNodeEnrMarker, int iNodeInd) const
virtual void evalN(FloatArray &answer, const FloatArray &lcoords, const FEICellGeometry &cellgeo)=0
Evaluates the array of interpolation functions (shape functions) at given point.
void giveSubtriangulationCompositeExportData(std::vector< VTKPiece > &vtkPieces, IntArray &primaryVarsToExport, IntArray &internalVarsToExport, IntArray cellVarsToExport, TimeStep *tStep)
VTK Interface.
void computeVectorOf(ValueModeType u, TimeStep *tStep, FloatArray &answer)
Returns local vector of unknowns.
Definition: element.C:86
bool isDofManEnriched(const DofManager &iDMan) const
virtual void giveInputRecord(DynamicInputRecord &input)
Setups the input record string of receiver.
virtual void computeEnrichedDofManDofIdArray(IntArray &oDofIdArray, DofManager &iDMan)
Compute Id&#39;s of enriched dofs for a given DofManager.
Element_Geometry_Type
Enumerative type used to classify element geometry Possible values are: EGT_point - point in space EG...
int giveGlobalNumber() const
Definition: dofmanager.h:501
Domain * domain
Link to domain object, useful for communicating with other FEM components.
Definition: femcmpnn.h:82
virtual FEInterpolation * giveInterpolation() const
Definition: trplanstrss.C:69
#define _IFT_TrPlaneStress2dXFEM_RegCoeffTol
virtual void computeGaussPoints()
Initializes the array of integration rules member variable.
Provides Xfem interface for an element.
std::unique_ptr< FloatArray > initialDisplacements
Initial displacement vector, describes the initial nodal displacements when element has been casted...
const std::vector< int > & giveNodeEnrichmentItemIndices(int iNodeIndex) const
Definition: xfemmanager.h:248
double & at(int i)
Coefficient access function.
Definition: floatarray.h:131
void XfemElementInterface_createEnrBHmatrixAt(FloatMatrix &oAnswer, GaussPoint &iGP, Element &iEl)
Creates enriched BH-matrix.
ValueModeType
Type representing the mode of UnknownType or CharType, or similar types.
Definition: valuemodetype.h:78
virtual void drawScalar(oofegGraphicContext &gc, TimeStep *tStep)
Definition: trplanstrss.C:320
Elements with geometry defined as EGT_Composite are exported using individual pieces.
oofem::oofegGraphicContext gc[OOFEG_LAST_LAYER]
virtual int checkConsistency()
Performs consistency check.
virtual FloatArray * giveCoordinates()
Definition: dofmanager.h:382
virtual bool hasField(InputFieldType id)=0
Returns true if record contains field identified by idString keyword.
virtual void drawRawGeometry(oofegGraphicContext &gc, TimeStep *tStep)
Definition: trplanstrss.C:259
Base class for dof managers.
Definition: dofmanager.h:113
virtual void computeStiffnessMatrix(FloatMatrix &answer, MatResponseMode rMode, TimeStep *tStep)
Computes the stiffness matrix of receiver.
MaterialMode
Type representing material mode of integration point.
Definition: materialmode.h:89
Class implementing an array of integers.
Definition: intarray.h:61
int & at(int i)
Coefficient access function.
Definition: intarray.h:103
MatResponseMode
Describes the character of characteristic material matrix.
void XfemElementInterface_createEnrBmatrixAt(FloatMatrix &oAnswer, GaussPoint &iGP, Element &iEl)
Creates enriched B-matrix.
virtual void giveCZInputRecord(DynamicInputRecord &input)
virtual void computeBmatrixAt(GaussPoint *gp, FloatMatrix &answer, int lowerIndx=1, int upperIndx=ALL_STRAINS)
Computes the geometrical matrix of receiver in given integration point.
XfemManager * giveXfemManager()
Definition: domain.C:375
virtual int giveNumberOfDofManagers() const
Definition: element.h:656
virtual IRResultType initializeCZFrom(InputRecord *ir)
virtual void computeStressVector(FloatArray &answer, const FloatArray &strain, GaussPoint *gp, TimeStep *tStep)
Computes the stress vector of receiver at given integration point, at time step tStep.
virtual void computeCohesiveTangent(FloatMatrix &answer, TimeStep *tStep)
Class representing a general abstraction for finite element interpolation class.
Definition: feinterpol.h:132
int giveNumberOfEnrichmentItems() const
Definition: xfemmanager.h:185
InternalStateType giveIntVarType()
void updateYourselfCZ(TimeStep *tStep)
int giveNumberOfDofs() const
Definition: dofmanager.C:279
virtual int computeNumberOfDofs()
Computes or simply returns total number of element&#39;s local DOFs.
virtual int checkConsistency()
Performs consistency check.
REGISTER_Element(LSpace)
virtual void computeBHmatrixAt(GaussPoint *gp, FloatMatrix &answer)
Computes a matrix which, multiplied by the column matrix of nodal displacements, gives the displaceme...
virtual void drawRawGeometry(oofegGraphicContext &gc, TimeStep *tStep)
UnknownType
Type representing particular unknown (its physical meaning).
Definition: unknowntype.h:55
bool evalLevelSetNormalInNode(double &oLevelSet, int iNodeInd, const FloatArray &iGlobalCoord) const
void XfemElementInterface_createEnrNmatrixAt(FloatMatrix &oAnswer, const FloatArray &iLocCoord, Element &iEl, bool iSetDiscontContribToZero)
Creates enriched N-matrix.
Wrapper around element definition to provide FEICellGeometry interface.
Definition: feinterpol.h:95
virtual void giveDofManDofIDMask(int inode, IntArray &answer) const
Returns dofmanager dof mask for node.
void beProductOf(const FloatMatrix &aMatrix, const FloatArray &anArray)
Receiver becomes the result of the product of aMatrix and anArray.
Definition: floatarray.C:676
virtual void computeField(ValueModeType mode, TimeStep *tStep, const FloatArray &lcoords, FloatArray &answer)
Computes the unknown vector interpolated at the specified local coordinates.
#define N(p, q)
Definition: mdm.C:367
virtual void giveElementDofIDMask(IntArray &answer) const
Returns element dof mask for node.
Definition: element.h:498
virtual void computeNmatrixAt(const FloatArray &iLocCoord, FloatMatrix &answer)
Computes interpolation matrix for element unknowns.
virtual MaterialMode giveMaterialMode()
Returns material mode for receiver integration points.
int giveDofManPlaceInArray(int iGlobalDofManNum) const
Returns the array index of the dofman with global number iGlobalDofManNum, so that it can be fetched ...
Definition: domain.C:196
InternalStateMode giveIntVarMode()
bool hasXfemManager()
Definition: domain.C:386
virtual Interface * giveInterface(InterfaceType)
Interface requesting service.
Definition: trplanstrss.C:72
bool evalLevelSetTangInNode(double &oLevelSet, int iNodeInd, const FloatArray &iGlobalCoord) const
virtual void giveInputRecord(DynamicInputRecord &input)
Setups the input record string of receiver.
Class representing vector of real numbers.
Definition: floatarray.h:82
virtual Element_Geometry_Type giveGeometryType() const
Returns the element geometry type.
virtual void computeDeformationGradientVector(FloatArray &answer, GaussPoint *gp, TimeStep *tStep)
Computes the deformation gradient in Voigt form at integration point ip and at time step tStep...
Implementation of matrix containing floating point numbers.
Definition: floatmatrix.h:94
This class manages the xfem part.
Definition: xfemmanager.h:109
IRResultType
Type defining the return values of InputRecord reading operations.
Definition: irresulttype.h:47
virtual void updateYourself(TimeStep *tStep)
Updates element state after equilibrium in time step has been reached.
static void computeIPAverage(FloatArray &answer, IntegrationRule *iRule, Element *elem, InternalStateType isType, TimeStep *tStep)
Computes a cell average of an InternalStateType varible based on the weights in the integrationpoints...
virtual void computeStiffnessMatrix(FloatMatrix &answer, MatResponseMode rMode, TimeStep *tStep)
Computes the stiffness matrix of receiver.
IntArray vtkExportFields
List with the fields that should be exported to VTK.
Definition: xfemmanager.h:167
virtual void postInitialize()
Performs post initialization steps.
Class representing the general Input Record.
Definition: inputrecord.h:101
bool isElementEnriched(const Element *elem)
Definition: xfemmanager.C:104
Class Interface.
Definition: interface.h:82
XFEMStateType
Definition: xfemmanager.h:92
void followedBy(const IntArray &b, int allocChunk=0)
Appends array b at the end of receiver.
Definition: intarray.C:145
Class representing the a dynamic Input Record.
EnrichmentItem * giveEnrichmentItem(int n)
Definition: xfemmanager.h:184
virtual bool computeLocalCoordinates(FloatArray &answer, const FloatArray &gcoords)
Computes the element local coordinates from given global coordinates.
Definition: element.C:1222
std::vector< std::unique_ptr< IntegrationRule > > integrationRulesArray
List of integration rules of receiver (each integration rule contains associated integration points a...
Definition: element.h:170
virtual bool XfemElementInterface_updateIntegrationRule()
Updates integration rule based on the triangulation.
Domain * giveDomain() const
Definition: femcmpnn.h:100
InterfaceType
Enumerative type, used to identify interface type.
Definition: interfacetype.h:43
virtual void updateYourself(TimeStep *tStep)
Updates element state after equilibrium in time step has been reached.
void push_back(const double &iVal)
Add one element.
Definition: floatarray.h:118
virtual void giveInternalForcesVector(FloatArray &answer, TimeStep *tStep, int useUpdatedGpRecord=0)
Evaluates nodal representation of real internal forces.
virtual void giveCompositeExportData(std::vector< VTKPiece > &vtkPieces, IntArray &primaryVarsToExport, IntArray &internalVarsToExport, IntArray cellVarsToExport, TimeStep *tStep)
VTK Interface.
virtual void giveElementDofIDMask(IntArray &answer) const
Returns element dof mask for node.
virtual void postInitialize()
Performs post initialization steps.
virtual Interface * giveInterface(InterfaceType it)
Interface requesting service.
int giveSize() const
Definition: intarray.h:203
int giveSize() const
Returns the size of receiver.
Definition: floatarray.h:218
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
the oofem namespace is to define a context or scope in which all oofem names are defined.
virtual void computeConstitutiveMatrixAt(FloatMatrix &answer, MatResponseMode rMode, GaussPoint *, TimeStep *tStep)
Computes constitutive matrix of receiver.
DofManager * giveDofManager(int i) const
Definition: element.C:514
virtual void computeCohesiveForces(FloatArray &answer, TimeStep *tStep)
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
virtual void giveDofManDofIDMask(int inode, IntArray &answer) const
Returns dofmanager dof mask for node.
virtual void computeGaussPoints()
Initializes the array of integration rules member variable.
int giveNumberOfRows() const
Returns number of rows of receiver.
Definition: floatmatrix.h:156
Class representing integration point in finite element program.
Definition: gausspoint.h:93
IRResultType giveOptionalField(int &answer, InputFieldType id)
Reads the integer field value.
Definition: inputrecord.C:64
Class representing solution step.
Definition: timestep.h:80
virtual void XfemElementInterface_computeConstitutiveMatrixAt(FloatMatrix &answer, MatResponseMode rMode, GaussPoint *, TimeStep *tStep)
PatchIntegrationRule provides integration over a triangle patch.
static FEI2dTrLin interp
Definition: trplanstrss.h:67
virtual void XfemElementInterface_computeStressVector(FloatArray &answer, const FloatArray &strain, GaussPoint *gp, TimeStep *tStep)

This page is part of the OOFEM documentation. Copyright (c) 2011 Borek Patzak
Project e-mail: info@oofem.org
Generated at Tue Jan 2 2018 20:07:32 for OOFEM by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2011