Changeset 18034
- Timestamp:
- 05/20/14 16:10:51 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/analyses/DamageEvolutionAnalysis.cpp
r18033 r18034 88 88 void DamageEvolutionAnalysis::CreateConstraints(Constraints* constraints,IoModel* iomodel){/*{{{*/ 89 89 90 int stabilization;91 90 int finiteelement; 92 iomodel->Constant(&stabilization,DamageStabilizationEnum);93 91 iomodel->Constant(&finiteelement,DamageElementinterpEnum); 94 92 … … 450 448 451 449 /*Fetch number of vertices and allocate output*/ 452 int num vertices = element->GetNumberOfVertices();453 IssmDouble* f = xNew<IssmDouble>(num vertices);450 int numnodes = element->GetNumberOfNodes(); 451 IssmDouble* f = xNew<IssmDouble>(numnodes); 454 452 455 453 /*retrieve parameters:*/ … … 481 479 /*Calculate damage evolution source term: */ 482 480 Gauss* gauss=element->NewGauss(); 483 for (int i v=0;iv<numvertices;iv++){484 gauss->Gauss Vertex(iv);481 for (int i=0;i<numnodes;i++){ 482 gauss->GaussNode(element->GetElementType(),i); 485 483 486 484 damage_input->GetInputValue(&damage,gauss); … … 509 507 NegPsi=max(-Chi,0.); /* healing only for compressive stresses */ 510 508 511 f[i v]= c1*(pow(PosPsi,c2) - healing*pow(NegPsi,c2))*pow((1.-damage),-c3);509 f[i]= c1*(pow(PosPsi,c2) - healing*pow(NegPsi,c2))*pow((1.-damage),-c3); 512 510 } 513 511
Note:
See TracChangeset
for help on using the changeset viewer.