Changeset 15964
- Timestamp:
- 08/26/13 20:05:36 (12 years ago)
- Location:
- issm/trunk-jpl/src/c/classes/Elements
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/classes/Elements/Penta.cpp
r15963 r15964 11253 11253 nodes[i]->inputs->AddInput(new BoolInput(MaskVertexongroundediceEnum,false)); 11254 11254 } 11255 else if(migration_style==SoftMigrationEnum && reCast<int,IssmDouble>(sheet_ungrounding[ nodes[i]->Sid()])){11255 else if(migration_style==SoftMigrationEnum && reCast<int,IssmDouble>(sheet_ungrounding[vertices[i]->Sid()])){ 11256 11256 s[i] = (1-density)*h[i]; 11257 11257 b[i] = -density*h[i]; … … 11341 11341 if(bed_hydro>r[i]){ 11342 11342 /*Vertex that could potentially unground, flag it*/ 11343 potential_ungrounding->SetValue( nodes[i]->Sid(),1,INS_VAL);11343 potential_ungrounding->SetValue(vertices[i]->Sid(),1,INS_VAL); 11344 11344 } 11345 11345 } … … 11356 11356 for(i=0;i<NUMVERTICES;i++){ 11357 11357 if (reCast<bool,IssmDouble>(vertices_potentially_ungrounding[nodes[i]->Sid()])){ 11358 vec_nodes_on_iceshelf->SetValue( nodes[i]->Sid(),1,INS_VAL);11358 vec_nodes_on_iceshelf->SetValue(vertices[i]->Sid(),1,INS_VAL); 11359 11359 11360 11360 /*If node was not on ice shelf, we flipped*/ 11361 if(nodes_on_iceshelf[ nodes[i]->Sid()]==0){11361 if(nodes_on_iceshelf[vertices[i]->Sid()]==0){ 11362 11362 nflipped++; 11363 11363 } -
issm/trunk-jpl/src/c/classes/Elements/Tria.cpp
r15963 r15964 7312 7312 #ifdef _HAVE_GROUNDINGLINE_ 7313 7313 /*FUNCTION Tria::MigrateGroundingLine{{{*/ 7314 void Tria::MigrateGroundingLine(IssmDouble* sheet_ungrounding){7314 void Tria::MigrateGroundingLine(IssmDouble* phi_ungrounding){ 7315 7315 7316 7316 int i,migration_style; … … 7363 7363 nodes[i]->inputs->AddInput(new BoolInput(MaskVertexongroundediceEnum,false)); 7364 7364 } 7365 else if(migration_style==SoftMigrationEnum && reCast<bool>(sheet_ungrounding[nodes[i]->Sid()])){ 7365 else if(migration_style==SoftMigrationEnum && reCast<bool>(sheet_ungrounding[vertices[i]->Sid()])){ 7366 //else if(migration_style==SoftMigrationEnum && phi_ungrounding[vertices[i]->Sid()]<0.){ 7366 7367 s[i] = (1-density)*h[i]; 7367 7368 b[i] = -density*h[i]; … … 7413 7414 if(migration_style==SoftMigrationEnum){ 7414 7415 bed_hydro=-density*h[i]; 7415 if(phi[i]<0. || bed_hydro<=r[i] || reCast<bool>(sheet_ungrounding[nodes[i]->Sid()])){ 7416 //if(phi[i]<0. || bed_hydro<=r[i] || phi_ungrounding[vertices[i]->Sid()]<0.){ 7417 if(phi[i]<0. || bed_hydro<=r[i] || reCast<bool>(sheet_ungrounding[vertices[i]->Sid()])){ 7416 7418 phi[i]=h[i]+r[i]/density; 7417 7419 } … … 7444 7446 if(bed_hydro>r[i]){ 7445 7447 /*Vertex that could potentially unground, flag it*/ 7446 potential_ungrounding->SetValue( nodes[i]->Sid(),1,INS_VAL);7448 potential_ungrounding->SetValue(vertices[i]->Sid(),1,INS_VAL); 7447 7449 } 7448 7450 } … … 7458 7460 /*Go through nodes, and whoever is on the potential_ungrounding, ends up in nodes_on_iceshelf: */ 7459 7461 for(i=0;i<3;i++){ 7460 if (reCast<bool>(vertices_potentially_ungrounding[ nodes[i]->Sid()])){7461 vec_nodes_on_iceshelf->SetValue( nodes[i]->Sid(),1,INS_VAL);7462 if (reCast<bool>(vertices_potentially_ungrounding[vertices[i]->Sid()])){ 7463 vec_nodes_on_iceshelf->SetValue(vertices[i]->Sid(),1,INS_VAL); 7462 7464 7463 7465 /*If node was not on ice shelf, we flipped*/ 7464 if(nodes_on_iceshelf[ nodes[i]->Sid()]==0){7466 if(nodes_on_iceshelf[vertices[i]->Sid()]==0){ 7465 7467 nflipped++; 7466 7468 }
Note:
See TracChangeset
for help on using the changeset viewer.