Changeset 14763
- Timestamp:
- 04/25/13 15:59:57 (12 years ago)
- Location:
- issm/trunk-jpl/src/c
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/classes/objects/Elements/Penta.cpp
r14761 r14763 267 267 268 268 /* Get node coordinates and dof list: */ 269 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);269 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 270 270 for(i=0;i<3;i++) for(j=0;j<3;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 271 271 … … 335 335 336 336 /* Get node coordinates and dof list: */ 337 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);337 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 338 338 339 339 /*Retrieve all inputs we will be needing: */ … … 970 970 971 971 /*Get xyz list: */ 972 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);972 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 973 973 xmin=xyz_list[0][0]; xmax=xyz_list[0][0]; 974 974 ymin=xyz_list[0][1]; ymax=xyz_list[0][1]; … … 1317 1317 IssmDouble z_list[NUMVERTICES]; 1318 1318 1319 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);1319 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 1320 1320 for(i=0;i<NUMVERTICES;i++) z_list[i]=xyz_list[i][2]; 1321 1321 PentaRef::GetInputValue(&z,z_list,gauss); … … 1541 1541 1542 1542 /*Step2: Create element thickness input*/ 1543 GetVerticesCoordinates(&xyz_list[0][0],penta-> nodes,NUMVERTICES);1543 GetVerticesCoordinates(&xyz_list[0][0],penta->vertices,NUMVERTICES); 1544 1544 for(i=0;i<3;i++){ 1545 1545 Helem_list[i]=xyz_list[i+3][2]-xyz_list[i][2]; … … 2984 2984 2985 2985 /* Get node coordinates and dof list: */ 2986 GetVerticesCoordinates(&xyz_list[0][0], this->nodes,NUMVERTICES);2986 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 2987 2987 2988 2988 minx=xyz_list[0][0]; … … 3203 3203 3204 3204 /*Retrieve all inputs and parameters*/ 3205 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3205 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3206 3206 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); 3207 3207 Input* vy_input=inputs->GetInput(VyEnum); _assert_(vy_input); … … 3246 3246 if(IsOnWater())return 0; 3247 3247 3248 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3248 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3249 3249 3250 3250 /*First calculate the area of the base (cross section triangle) … … 3474 3474 if(IsOnWater() || !IsOnSurface()) return 0.; 3475 3475 3476 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3476 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3477 3477 3478 3478 /*First calculate the area of the base (cross section triangle) … … 3553 3553 3554 3554 /*Retrieve all inputs and parameters*/ 3555 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3555 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3556 3556 rho_water=matpar->GetRhoWater(); 3557 3557 rho_ice=matpar->GetRhoIce(); … … 3703 3703 rho_ice=matpar->GetRhoIce(); 3704 3704 heatcapacity=matpar->GetHeatCapacity(); 3705 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3705 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3706 3706 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<3;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 3707 3707 … … 3786 3786 3787 3787 /*Retrieve all inputs and parameters*/ 3788 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3788 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3789 3789 rho_water=matpar->GetRhoWater(); 3790 3790 rho_ice=matpar->GetRhoIce(); … … 3934 3934 rho_ice=matpar->GetRhoIce(); 3935 3935 heatcapacity=matpar->GetHeatCapacity(); 3936 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3936 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3937 3937 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<3;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 3938 3938 … … 4004 4004 4005 4005 /*Retrieve all inputs and parameters*/ 4006 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4006 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4007 4007 rho_ice=matpar->GetRhoIce(); 4008 4008 heatcapacity=matpar->GetHeatCapacity(); … … 4096 4096 4097 4097 /*Retrieve all inputs and parameters*/ 4098 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4098 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4099 4099 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<3;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 4100 4100 mixed_layer_capacity=matpar->GetMixedLayerCapacity(); … … 4157 4157 4158 4158 /*Retrieve all inputs and parameters*/ 4159 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4159 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4160 4160 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<2;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 4161 4161 parameters->FindParam(&analysis_type,AnalysisTypeEnum); … … 4266 4266 4267 4267 /*Retrieve all inputs and parameters*/ 4268 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4268 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4269 4269 rho_ice=matpar->GetRhoIce(); 4270 4270 heatcapacity=matpar->GetHeatCapacity(); … … 4350 4350 4351 4351 /*Retrieve all inputs and parameters*/ 4352 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4352 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4353 4353 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<3;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 4354 4354 mixed_layer_capacity=matpar->GetMixedLayerCapacity(); … … 4409 4409 4410 4410 /*Retrieve all inputs and parameters*/ 4411 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4411 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4412 4412 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<2;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 4413 4413 parameters->FindParam(&analysis_type,AnalysisTypeEnum); … … 4543 4543 4544 4544 /*Get all inputs and parameters*/ 4545 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4545 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4546 4546 Input* surface_input=inputs->GetInput(SurfaceEnum); _assert_(surface_input); 4547 4547 … … 4611 4611 4612 4612 /*Get all inputs and parameters*/ 4613 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4613 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4614 4614 GetInputListOnVertices(&pressure[0],PressureEnum); 4615 4615 Input* surface_input=inputs->GetInput(SurfaceEnum); _assert_(surface_input); … … 4811 4811 4812 4812 /*Retrieve all inputs and parameters*/ 4813 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4813 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4814 4814 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); 4815 4815 Input* vy_input=inputs->GetInput(VyEnum); _assert_(vy_input); … … 4879 4879 4880 4880 /*Retrieve all inputs and parameters*/ 4881 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4881 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4882 4882 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); 4883 4883 Input* vy_input=inputs->GetInput(VyEnum); _assert_(vy_input); … … 5133 5133 parameters->FindParam(&analysis_type,AnalysisTypeEnum); 5134 5134 GradientIndexing(&vertexpidlist[0],control_index); 5135 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5135 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5136 5136 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<2;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 5137 5137 Input* adjointx_input=inputs->GetInput(AdjointxEnum); _assert_(adjointx_input); … … 5205 5205 /*Retrieve all inputs and parameters*/ 5206 5206 parameters->FindParam(&analysis_type,AnalysisTypeEnum); 5207 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5207 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5208 5208 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<2;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 5209 5209 GradientIndexing(&vertexpidlist[0],control_index); … … 6009 6009 6010 6010 /* Get node coordinates and dof list: */ 6011 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6011 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6012 6012 this->parameters->FindParam(&viscosity_overshoot,DiagnosticViscosityOvershootEnum); 6013 6013 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 6099 6099 6100 6100 /*retrieve inputs :*/ 6101 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6101 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6102 6102 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<2;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 6103 6103 parameters->FindParam(&analysis_type,AnalysisTypeEnum); … … 6219 6219 6220 6220 /* Get node coordinates and dof list: */ 6221 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6221 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6222 6222 parameters->FindParam(&stokesreconditioning,DiagnosticStokesreconditioningEnum); 6223 6223 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 6323 6323 6324 6324 /*Retrieve all inputs and parameters*/ 6325 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6325 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6326 6326 parameters->FindParam(&analysis_type,AnalysisTypeEnum); 6327 6327 parameters->FindParam(&stokesreconditioning,DiagnosticStokesreconditioningEnum); … … 6611 6611 6612 6612 /*Retrieve all inputs and parameters*/ 6613 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6613 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6614 6614 this->parameters->FindParam(&viscosity_overshoot,DiagnosticViscosityOvershootEnum); 6615 6615 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 6758 6758 6759 6759 /*Retrieve all inputs and parameters*/ 6760 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6760 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6761 6761 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); 6762 6762 Input* vy_input=inputs->GetInput(VyEnum); _assert_(vy_input); … … 6855 6855 /*Retrieve all inputs and parameters*/ 6856 6856 inputs->GetInputValue(&approximation,ApproximationEnum); 6857 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6857 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6858 6858 this->parameters->FindParam(&viscosity_overshoot,DiagnosticViscosityOvershootEnum); 6859 6859 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 6923 6923 6924 6924 /*Retrieve all inputs and parameters*/ 6925 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6925 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6926 6926 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<2;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 6927 6927 parameters->FindParam(&migration_style,GroundinglineMigrationEnum); … … 7027 7027 7028 7028 /*Retrieve all inputs and parameters*/ 7029 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7029 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7030 7030 parameters->FindParam(&stokesreconditioning,DiagnosticStokesreconditioningEnum); 7031 7031 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 7094 7094 7095 7095 /*Retrieve all inputs and parameters*/ 7096 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7096 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7097 7097 parameters->FindParam(&analysis_type,AnalysisTypeEnum); 7098 7098 parameters->FindParam(&stokesreconditioning,DiagnosticStokesreconditioningEnum); … … 7172 7172 7173 7173 /*Retrieve all inputs and parameters*/ 7174 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7174 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7175 7175 7176 7176 /* Start looping on the number of gaussian points: */ … … 7218 7218 7219 7219 /*Retrieve all inputs and parameters*/ 7220 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7220 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7221 7221 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<3;j++) xyz_list_tria[i][j]=xyz_list[i+3][j]; 7222 7222 SurfaceNormal(&surface_normal[0],xyz_list_tria); … … 7282 7282 7283 7283 /*Retrieve all inputs and parameters*/ 7284 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7284 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7285 7285 this->parameters->FindParam(&stokesreconditioning,DiagnosticStokesreconditioningEnum); 7286 7286 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 7349 7349 7350 7350 /*Retrieve all inputs and parameters*/ 7351 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7351 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7352 7352 parameters->FindParam(&analysis_type,AnalysisTypeEnum); 7353 7353 this->parameters->FindParam(&stokesreconditioning,DiagnosticStokesreconditioningEnum); … … 7433 7433 7434 7434 /*Retrieve all inputs and parameters*/ 7435 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7435 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7436 7436 this->parameters->FindParam(&stokesreconditioning,DiagnosticStokesreconditioningEnum); 7437 7437 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 7500 7500 7501 7501 /*Retrieve all inputs and parameters*/ 7502 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7502 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7503 7503 parameters->FindParam(&analysis_type,AnalysisTypeEnum); 7504 7504 this->parameters->FindParam(&stokesreconditioning,DiagnosticStokesreconditioningEnum); … … 7643 7643 7644 7644 /*Retrieve all inputs and parameters*/ 7645 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7645 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7646 7646 rho_ice=matpar->GetRhoIce(); 7647 7647 gravity=matpar->GetG(); … … 7754 7754 7755 7755 /*Retrieve all inputs and parameters*/ 7756 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7756 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7757 7757 Input* thickness_input=inputs->GetInput(ThicknessEnum); _assert_(thickness_input); 7758 7758 Input* surface_input=inputs->GetInput(SurfaceEnum); _assert_(surface_input); … … 7830 7830 rho_ice=matpar->GetRhoIce(); 7831 7831 gravity=matpar->GetG(); 7832 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7832 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7833 7833 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); 7834 7834 Input* vy_input=inputs->GetInput(VyEnum); _assert_(vy_input); … … 7913 7913 rho_water=matpar->GetRhoWater(); 7914 7914 gravity=matpar->GetG(); 7915 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7915 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7916 7916 Input* bed_input=inputs->GetInput(BedEnum); _assert_(bed_input); 7917 7917 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 7988 7988 7989 7989 /*Retrieve all inputs and parameters*/ 7990 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);7990 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 7991 7991 inputs->GetInputValue(&approximation,ApproximationEnum); 7992 7992 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 8047 8047 8048 8048 /*Retrieve all inputs and parameters*/ 8049 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);8049 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 8050 8050 for(i=0;i<NUMVERTICES2D;i++) for(j=0;j<3;j++) xyz_list_tria[i][j]=xyz_list[i][j]; 8051 8051 inputs->GetInputValue(&approximation,ApproximationEnum); … … 8164 8164 8165 8165 /*Retrieve all inputs and parameters*/ 8166 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);8166 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 8167 8167 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); 8168 8168 Input* vy_input=inputs->GetInput(VyEnum); _assert_(vy_input); … … 8229 8229 8230 8230 /*Retrieve all inputs and parameters*/ 8231 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);8231 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 8232 8232 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); 8233 8233 Input* vy_input=inputs->GetInput(VyEnum); _assert_(vy_input); … … 8595 8595 8596 8596 /*Get node data: */ 8597 GetVerticesCoordinates(&xyz_list[0][0],penta-> nodes,NUMVERTICES);8597 GetVerticesCoordinates(&xyz_list[0][0],penta->vertices,NUMVERTICES); 8598 8598 8599 8599 /*Now Compute vel*/ … … 8658 8658 8659 8659 /*Get node data: */ 8660 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);8660 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 8661 8661 8662 8662 /*Use the dof list to index into the solution vector: */ … … 8745 8745 8746 8746 /*Get node data: */ 8747 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);8747 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 8748 8748 8749 8749 /*Use the dof list to index into the solution vector: */ … … 8860 8860 8861 8861 /*Get node data: */ 8862 GetVerticesCoordinates(&xyz_list[0][0],penta-> nodes,NUMVERTICES);8862 GetVerticesCoordinates(&xyz_list[0][0],penta->vertices,NUMVERTICES); 8863 8863 8864 8864 /*Now Compute vel*/ … … 8914 8914 8915 8915 /*Get node data: */ 8916 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);8916 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 8917 8917 8918 8918 /*Use the dof list to index into the solution vector: */ … … 8999 8999 9000 9000 /*Get node data: */ 9001 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);9001 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 9002 9002 9003 9003 /*Use the dof list to index into the solution vector: */ … … 9082 9082 9083 9083 /*Get node data: */ 9084 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);9084 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 9085 9085 9086 9086 /*Use the dof list to index into the solution vector: */ … … 9153 9153 /*Get dof list and vertices coordinates: */ 9154 9154 GetDofList(&doflist,NoneApproximationEnum,GsetEnum); 9155 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);9155 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 9156 9156 9157 9157 /*Use the dof list to index into the solution vector vz: */ -
issm/trunk-jpl/src/c/classes/objects/Elements/Tria.cpp
r14761 r14763 297 297 298 298 /*Retrieve all inputs and parameters*/ 299 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);299 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 300 300 latentheat=matpar->GetLatentHeat(); 301 301 heatcapacity=matpar->GetHeatCapacity(); … … 363 363 364 364 /*Retrieve all inputs and parameters*/ 365 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);365 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 366 366 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 367 367 this->parameters->FindParam(&dim,MeshDimensionEnum); … … 478 478 479 479 /*Retrieve all inputs and parameters*/ 480 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);480 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 481 481 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 482 482 this->parameters->FindParam(&dim,MeshDimensionEnum); … … 546 546 ElementMatrix* Ke=new ElementMatrix(nodes,NUMVERTICES,this->parameters,NoneApproximationEnum); 547 547 548 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);548 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 549 549 550 550 /* Start looping on the number of gaussian points: */ … … 667 667 668 668 /*Retrieve all inputs and parameters*/ 669 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);669 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 670 670 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 671 671 Input* surface_mass_balance_input=inputs->GetInput(SurfaceforcingsMassBalanceEnum); _assert_(surface_mass_balance_input); … … 718 718 /*Retrieve all inputs and parameters*/ 719 719 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 720 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);720 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 721 721 Input* surface_mass_balance_input=inputs->GetInput(SurfaceforcingsMassBalanceEnum); _assert_(surface_mass_balance_input); 722 722 Input* basal_melting_input=inputs->GetInput(BasalforcingsMeltingRateEnum); _assert_(basal_melting_input); … … 764 764 /*Retrieve all inputs and parameters*/ 765 765 parameters->FindParam(&analysis_type,AnalysisTypeEnum); 766 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);766 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 767 767 Input* slope_input=NULL; 768 768 if ( (analysis_type==SurfaceSlopeXAnalysisEnum) || (analysis_type==SurfaceSlopeYAnalysisEnum)){ … … 855 855 856 856 /* Get node coordinates and dof list: */ 857 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);857 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 858 858 859 859 /*Retrieve all inputs we will be needing: */ … … 1082 1082 1083 1083 /*Get xyz list: */ 1084 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);1084 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 1085 1085 x1=xyz_list[0][0]; y1=xyz_list[0][1]; 1086 1086 x2=xyz_list[1][0]; y2=xyz_list[1][1]; … … 2538 2538 if(IsOnWater())return 0; 2539 2539 2540 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);2540 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 2541 2541 2542 2542 for(int i=0;i<3;i++){ … … 2602 2602 2603 2603 /* Get node coordinates and dof list: */ 2604 GetVerticesCoordinates(&xyz_list[0][0], this->nodes,NUMVERTICES);2604 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 2605 2605 2606 2606 minx=xyz_list[0][0]; … … 2755 2755 if(IsOnWater())return 0; 2756 2756 2757 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);2757 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 2758 2758 2759 2759 /*First calculate the area of the base (cross section triangle) … … 2796 2796 2797 2797 /*Get xyz list: */ 2798 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);2798 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 2799 2799 2800 2800 /*get area coordinates of 0 and 1 locations: */ … … 3031 3031 if(IsOnWater())return 0; 3032 3032 3033 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3033 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3034 3034 3035 3035 /*First calculate the area of the base (cross section triangle) … … 3120 3120 3121 3121 /*figure out gravity center of our element: */ 3122 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3122 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3123 3123 x0=(xyz_list[0][0]+xyz_list[1][0]+xyz_list[2][0])/3.0; 3124 3124 y0=(xyz_list[0][1]+xyz_list[1][1]+xyz_list[2][1])/3.0; … … 3202 3202 3203 3203 /*Retrieve all inputs and parameters*/ 3204 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3204 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3205 3205 Input* thickness_input=inputs->GetInput(ThicknessEnum); _assert_(thickness_input); 3206 3206 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 3273 3273 3274 3274 /*Retrieve all inputs and parameters*/ 3275 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3275 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3276 3276 parameters->FindParam(&migration_style,GroundinglineMigrationEnum); 3277 3277 Input* surface_input=inputs->GetInput(SurfaceEnum); _assert_(surface_input); … … 3371 3371 3372 3372 /*Retrieve all inputs and parameters*/ 3373 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3373 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3374 3374 Input* thickness_input=inputs->GetInput(ThicknessEnum); _assert_(thickness_input); 3375 3375 Input* surface_input=inputs->GetInput(SurfaceEnum); _assert_(surface_input); … … 3478 3478 3479 3479 /*Retrieve all inputs and parameters*/ 3480 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3480 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3481 3481 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); 3482 3482 Input* vy_input=inputs->GetInput(VyEnum); _assert_(vy_input); … … 3742 3742 3743 3743 /*Retrieve all inputs we will be needing: */ 3744 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3744 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3745 3745 Input* weights_input = inputs->GetInput(InversionCostFunctionsCoefficientsEnum); _assert_(weights_input); 3746 3746 Input* thickness_input = inputs->GetInput(ThicknessEnum); _assert_(thickness_input); … … 3957 3957 3958 3958 /*Retrieve all inputs we will be needing: */ 3959 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3959 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 3960 3960 GradientIndexing(&vertexpidlist[0],control_index); 3961 3961 Input* rheologyb_input=material->inputs->GetInput(MaterialsRheologyBbarEnum); _assert_(rheologyb_input); … … 3997 3997 3998 3998 /*Retrieve all inputs we will be needing: */ 3999 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);3999 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4000 4000 GradientIndexing(&vertexpidlist[0],control_index); 4001 4001 Input* rheologyz_input=material->inputs->GetInput(MaterialsRheologyZbarEnum); _assert_(rheologyz_input); … … 4039 4039 4040 4040 /* Get node coordinates and dof list: */ 4041 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4041 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4042 4042 GradientIndexing(&doflist[0],control_index); 4043 4043 … … 4096 4096 4097 4097 /* Get node coordinates and dof list: */ 4098 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4098 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4099 4099 GradientIndexing(&doflist[0],control_index); 4100 4100 … … 4160 4160 /*retrive parameters: */ 4161 4161 parameters->FindParam(&analysis_type,AnalysisTypeEnum); 4162 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4162 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4163 4163 GradientIndexing(&vertexpidlist[0],control_index); 4164 4164 this->GetConnectivityList(&connectivity[0]); … … 4240 4240 /*Retrieve all inputs we will be needing: */ 4241 4241 if(IsFloating())return; 4242 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4242 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4243 4243 GradientIndexing(&vertexpidlist[0],control_index); 4244 4244 Input* dragcoefficient_input=inputs->GetInput(FrictionCoefficientEnum); _assert_(dragcoefficient_input); … … 4300 4300 4301 4301 /* Get node coordinates and dof list: */ 4302 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4302 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4303 4303 GradientIndexing(&vertexpidlist[0],control_index); 4304 4304 … … 4343 4343 4344 4344 /* Get node coordinates and dof list: */ 4345 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4345 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4346 4346 GradientIndexing(&vertexpidlist[0],control_index); 4347 4347 … … 4392 4392 4393 4393 /* Get node coordinates and dof list: */ 4394 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4394 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4395 4395 GradientIndexing(&vertexpidlist[0],control_index); 4396 4396 4397 4397 /*Retrieve all inputs and parameters*/ 4398 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4398 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4399 4399 this->parameters->FindParam(&num_responses,InversionNumCostFunctionsEnum); 4400 4400 this->parameters->FindParam(&responses,NULL,NULL,StepResponsesEnum); … … 4512 4512 4513 4513 /*Retrieve all inputs we will be needing: */ 4514 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4514 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4515 4515 Input* weights_input =inputs->GetInput(InversionCostFunctionsCoefficientsEnum); _assert_(weights_input); 4516 4516 Input* rheologyb_input=material->inputs->GetInput(MaterialsRheologyBbarEnum); _assert_(rheologyb_input); … … 4551 4551 4552 4552 /* Get node coordinates and dof list: */ 4553 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4553 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4554 4554 4555 4555 /*Retrieve all inputs we will be needing: */ … … 4612 4612 4613 4613 /* Get node coordinates and dof list: */ 4614 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4614 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4615 4615 4616 4616 /*Retrieve all inputs we will be needing: */ … … 4674 4674 4675 4675 /* Get node coordinates and dof list: */ 4676 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4676 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4677 4677 4678 4678 /*Retrieve all inputs we will be needing: */ … … 4734 4734 4735 4735 /* Get node coordinates and dof list: */ 4736 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4736 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4737 4737 4738 4738 /*Retrieve all inputs we will be needing: */ … … 4795 4795 4796 4796 /* Get node coordinates and dof list: */ 4797 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4797 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4798 4798 4799 4799 /*Retrieve all inputs we will be needing: */ … … 4858 4858 4859 4859 /*Retrieve all inputs we will be needing: */ 4860 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4860 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4861 4861 Input* weights_input =inputs->GetInput(InversionCostFunctionsCoefficientsEnum); _assert_(weights_input); 4862 4862 Input* thickness_input=inputs->GetInput(ThicknessEnum); _assert_(thickness_input); … … 4902 4902 4903 4903 /*Retrieve all inputs we will be needing: */ 4904 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4904 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4905 4905 Input* weights_input = inputs->GetInput(InversionCostFunctionsCoefficientsEnum); _assert_(weights_input); 4906 4906 Input* thickness_input= inputs->GetInput(ThicknessEnum); _assert_(thickness_input); … … 4953 4953 4954 4954 /*Retrieve all inputs we will be needing: */ 4955 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);4955 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 4956 4956 Input* weights_input = inputs->GetInput(InversionCostFunctionsCoefficientsEnum); _assert_(weights_input); 4957 4957 Input* thickness_input= inputs->GetInput(ThicknessEnum); _assert_(thickness_input); … … 5001 5001 5002 5002 /*Retrieve all inputs we will be needing: */ 5003 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5003 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5004 5004 Input* thickness_input =inputs->GetInput(ThicknessEnum); _assert_(thickness_input); 5005 5005 Input* thicknessobs_input=inputs->GetInput(InversionThicknessObsEnum);_assert_(thicknessobs_input); … … 5053 5053 5054 5054 /*Retrieve all inputs and parameters*/ 5055 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5055 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5056 5056 this->parameters->FindParam(&num_responses,InversionNumCostFunctionsEnum); 5057 5057 this->parameters->FindParam(&responses,NULL,NULL,StepResponsesEnum); … … 5142 5142 5143 5143 /*Retrieve all inputs and parameters*/ 5144 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5144 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5145 5145 this->parameters->FindParam(&num_responses,InversionNumCostFunctionsEnum); 5146 5146 this->parameters->FindParam(&responses,NULL,NULL,StepResponsesEnum); … … 5324 5324 5325 5325 /*Retrieve all inputs and parameters*/ 5326 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5326 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5327 5327 this->parameters->FindParam(&num_responses,InversionNumCostFunctionsEnum); 5328 5328 this->parameters->FindParam(&responses,NULL,NULL,StepResponsesEnum); … … 5502 5502 5503 5503 /*Retrieve all inputs we will be needing: */ 5504 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5504 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5505 5505 Input* weights_input=inputs->GetInput(InversionCostFunctionsCoefficientsEnum); _assert_(weights_input); 5506 5506 Input* drag_input =inputs->GetInput(FrictionCoefficientEnum); _assert_(drag_input); … … 5575 5575 5576 5576 /*Retrieve all inputs and parameters*/ 5577 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5577 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5578 5578 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); 5579 5579 Input* vy_input=inputs->GetInput(VyEnum); _assert_(vy_input); … … 5857 5857 5858 5858 /*Retrieve all inputs and parameters*/ 5859 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5859 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5860 5860 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 5861 5861 this->parameters->FindParam(&diffusivity,HydrologyshreveStabilizationEnum); … … 5949 5949 5950 5950 /*Retrieve all inputs and parameters*/ 5951 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);5951 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 5952 5952 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 5953 5953 sediment_storing = matpar->GetSedimentStoring(); … … 6010 6010 6011 6011 /*Retrieve all inputs and parameters*/ 6012 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6012 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6013 6013 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 6014 6014 epl_storing = matpar->GetEplStoring(); … … 6095 6095 6096 6096 /*Retrieve all inputs and parameters*/ 6097 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6097 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6098 6098 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 6099 6099 Input* basal_melting_input=inputs->GetInput(BasalforcingsMeltingRateEnum); _assert_(basal_melting_input); … … 6142 6142 /*Retrieve all inputs and parameters*/ 6143 6143 sediment_storing = matpar->GetSedimentStoring(); 6144 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6144 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6145 6145 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 6146 6146 Input* water_input=inputs->GetInput(BasalforcingsMeltingRateEnum); _assert_(water_input); … … 6199 6199 /*Retrieve all inputs and parameters*/ 6200 6200 epl_storing = matpar->GetEplStoring(); 6201 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6201 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6202 6202 this->parameters->FindParam(&dt,TimesteppingTimeStepEnum); 6203 6203 Input* water_input=inputs->GetInput(BasalforcingsMeltingRateEnum); _assert_(water_input); … … 6526 6526 6527 6527 /*Retrieve all Inputs and parameters: */ 6528 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6528 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6529 6529 this->parameters->FindParam(&stabilization,BalancethicknessStabilizationEnum); 6530 6530 this->parameters->FindParam(&dim,MeshDimensionEnum); … … 6630 6630 6631 6631 /*Retrieve all inputs and parameters*/ 6632 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6632 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6633 6633 this->parameters->FindParam(&dim,MeshDimensionEnum); 6634 6634 Input* vx_input=inputs->GetInput(VxEnum); _assert_(vx_input); … … 6695 6695 6696 6696 /*Retrieve all inputs and parameters*/ 6697 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6697 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6698 6698 Input* surface_mass_balance_input=inputs->GetInput(SurfaceforcingsMassBalanceEnum); _assert_(surface_mass_balance_input); 6699 6699 Input* basal_melting_input=inputs->GetInput(BasalforcingsMeltingRateEnum); _assert_(basal_melting_input); … … 6738 6738 6739 6739 /*Retrieve all inputs and parameters*/ 6740 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES);6740 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 6741 6741 Input* surface_mass_balance_input=inputs->GetInput(SurfaceforcingsMassBalanceEnum); _assert_(surface_mass_balance_input); 6742 6742 Input* basal_melting_input=inputs->GetInput(BasalforcingsMeltingRateEnum); _assert_(basal_melting_input); -
issm/trunk-jpl/src/c/classes/objects/Loads/Icefront.cpp
r14761 r14763 521 521 522 522 /*Retrieve all inputs and parameters*/ 523 GetVerticesCoordinates(&xyz_list[0][0], nodes,numnodes);523 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICESSEG); 524 524 Input* thickness_input=tria->inputs->GetInput(ThicknessEnum); _assert_(thickness_input); 525 525 Input* bed_input =tria->inputs->GetInput(BedEnum); _assert_(bed_input); … … 641 641 642 642 /*Retrieve all inputs and parameters*/ 643 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICESQUA);643 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICESQUA); 644 644 Input* surface_input =penta->inputs->GetInput(SurfaceEnum); _assert_(surface_input); 645 645 inputs->GetInputValue(&fill,FillEnum); … … 718 718 719 719 /*Retrieve all inputs and parameters*/ 720 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICESQUA);720 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICESQUA); 721 721 inputs->GetInputValue(&fill,FillEnum); 722 722 rho_water=matpar->GetRhoWater(); -
issm/trunk-jpl/src/c/classes/objects/Loads/Numericalflux.cpp
r14761 r14763 20 20 21 21 /*Load macros*/ 22 #define NUMVERTICES_INTERNAL 4 23 #define NUMVERTICES_BOUNDARY 2 22 #define NUMVERTICES 2 23 #define NUMNODES_INTERNAL 4 24 #define NUMNODES_BOUNDARY 2 24 25 25 26 /*Numericalflux constructors and destructor*/ … … 132 133 /*Hooks: */ 133 134 this->hnodes =new Hook(numericalflux_node_ids,num_nodes); 134 this->hvertices =new Hook( numericalflux_vertex_ids,2);135 this->hvertices =new Hook(&numericalflux_vertex_ids[0],2); 135 136 this->helement =new Hook(numericalflux_elem_ids,1); // take only the first element for now 136 137 … … 327 328 switch(type){ 328 329 case InternalEnum: 329 for(int i=0;i<NUM VERTICES_INTERNAL;i++) sidlist[i]=nodes[i]->Sid();330 for(int i=0;i<NUMNODES_INTERNAL;i++) sidlist[i]=nodes[i]->Sid(); 330 331 return; 331 332 case BoundaryEnum: 332 for(int i=0;i<NUM VERTICES_BOUNDARY;i++) sidlist[i]=nodes[i]->Sid();333 for(int i=0;i<NUMNODES_BOUNDARY;i++) sidlist[i]=nodes[i]->Sid(); 333 334 return; 334 335 default: … … 345 346 switch(type){ 346 347 case InternalEnum: 347 return NUM VERTICES_INTERNAL;348 return NUMNODES_INTERNAL; 348 349 case BoundaryEnum: 349 return NUM VERTICES_BOUNDARY;350 return NUMNODES_BOUNDARY; 350 351 default: 351 352 _error_("Numericalflux type " << EnumToStringx(type) << " not supported yet"); … … 454 455 455 456 /* constants*/ 456 const int numdof=NDOF1*NUM VERTICES_INTERNAL;457 const int numdof=NDOF1*NUMNODES_INTERNAL; 457 458 458 459 /* Intermediaries*/ 459 460 int i,j,ig,index1,index2; 460 461 IssmDouble DL1,DL2,Jdet,dt,vx,vy,UdotN; 461 IssmDouble xyz_list[NUMVERTICES _INTERNAL][3];462 IssmDouble xyz_list[NUMVERTICES][3]; 462 463 IssmDouble normal[2]; 463 464 IssmDouble B[numdof]; … … 470 471 Tria* tria=(Tria*)element; 471 472 if(tria->IsOnWater()) return NULL; 472 ElementMatrix* Ke=new ElementMatrix(nodes,NUM VERTICES_INTERNAL,this->parameters);473 ElementMatrix* Ke=new ElementMatrix(nodes,NUMNODES_INTERNAL,this->parameters); 473 474 474 475 /*Retrieve all inputs and parameters*/ 475 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES_INTERNAL);476 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 476 477 parameters->FindParam(&dt,TimesteppingTimeStepEnum); 477 478 Input* vxaverage_input=tria->inputs->GetInput(VxEnum); … … 519 520 520 521 /* constants*/ 521 const int numdof=NDOF1*NUM VERTICES_BOUNDARY;522 const int numdof=NDOF1*NUMNODES_BOUNDARY; 522 523 523 524 /* Intermediaries*/ 524 525 int i,j,ig,index1,index2; 525 526 IssmDouble DL,Jdet,dt,vx,vy,mean_vx,mean_vy,UdotN; 526 IssmDouble xyz_list[NUMVERTICES _BOUNDARY][3];527 IssmDouble xyz_list[NUMVERTICES][3]; 527 528 IssmDouble normal[2]; 528 529 IssmDouble L[numdof]; … … 536 537 537 538 /*Retrieve all inputs and parameters*/ 538 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES_BOUNDARY);539 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 539 540 parameters->FindParam(&dt,TimesteppingTimeStepEnum); 540 541 Input* vxaverage_input=tria->inputs->GetInput(VxEnum); _assert_(vxaverage_input); … … 557 558 } 558 559 else{ 559 Ke=new ElementMatrix(nodes,NUM VERTICES_BOUNDARY,this->parameters);560 Ke=new ElementMatrix(nodes,NUMNODES_BOUNDARY,this->parameters); 560 561 } 561 562 … … 607 608 608 609 /* constants*/ 609 const int numdof=NDOF1*NUM VERTICES_INTERNAL;610 const int numdof=NDOF1*NUMNODES_INTERNAL; 610 611 611 612 /* Intermediaries*/ 612 613 int i,j,ig,index1,index2; 613 614 IssmDouble DL1,DL2,Jdet,vx,vy,UdotN; 614 IssmDouble xyz_list[NUMVERTICES _INTERNAL][3];615 IssmDouble xyz_list[NUMVERTICES][3]; 615 616 IssmDouble normal[2]; 616 617 IssmDouble B[numdof]; … … 623 624 Tria* tria=(Tria*)element; 624 625 if(tria->IsOnWater()) return NULL; 625 ElementMatrix* Ke=new ElementMatrix(nodes,NUM VERTICES_INTERNAL,this->parameters);626 ElementMatrix* Ke=new ElementMatrix(nodes,NUMNODES_INTERNAL,this->parameters); 626 627 627 628 /*Retrieve all inputs and parameters*/ 628 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES_INTERNAL);629 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 629 630 Input* vxaverage_input=tria->inputs->GetInput(VxEnum); 630 631 Input* vyaverage_input=tria->inputs->GetInput(VyEnum); … … 671 672 672 673 /* constants*/ 673 const int numdof=NDOF1*NUM VERTICES_BOUNDARY;674 const int numdof=NDOF1*NUMNODES_BOUNDARY; 674 675 675 676 /* Intermediaries*/ 676 677 int i,j,ig,index1,index2; 677 678 IssmDouble DL,Jdet,vx,vy,mean_vx,mean_vy,UdotN; 678 IssmDouble xyz_list[NUMVERTICES _BOUNDARY][3];679 IssmDouble xyz_list[NUMVERTICES][3]; 679 680 IssmDouble normal[2]; 680 681 IssmDouble L[numdof]; … … 688 689 689 690 /*Retrieve all inputs and parameters*/ 690 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES_BOUNDARY);691 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 691 692 Input* vxaverage_input=tria->inputs->GetInput(VxEnum); 692 693 Input* vyaverage_input=tria->inputs->GetInput(VyEnum); … … 708 709 } 709 710 else{ 710 Ke=new ElementMatrix(nodes,NUM VERTICES_BOUNDARY,this->parameters);711 Ke=new ElementMatrix(nodes,NUMNODES_BOUNDARY,this->parameters); 711 712 } 712 713 … … 798 799 799 800 /* constants*/ 800 const int numdof=NDOF1*NUM VERTICES_BOUNDARY;801 const int numdof=NDOF1*NUMNODES_BOUNDARY; 801 802 802 803 /* Intermediaries*/ 803 804 int i,ig,index1,index2; 804 805 IssmDouble DL,Jdet,dt,vx,vy,mean_vx,mean_vy,UdotN,thickness; 805 IssmDouble xyz_list[NUMVERTICES _BOUNDARY][3];806 IssmDouble xyz_list[NUMVERTICES][3]; 806 807 IssmDouble normal[2]; 807 808 IssmDouble L[numdof]; … … 814 815 815 816 /*Retrieve all inputs and parameters*/ 816 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES_BOUNDARY);817 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 817 818 parameters->FindParam(&dt,TimesteppingTimeStepEnum); 818 819 Input* vxaverage_input =tria->inputs->GetInput(VxEnum); _assert_(vxaverage_input); … … 836 837 } 837 838 else{ 838 pe=new ElementVector(nodes,NUM VERTICES_BOUNDARY,this->parameters);839 pe=new ElementVector(nodes,NUMNODES_BOUNDARY,this->parameters); 839 840 } 840 841 … … 892 893 893 894 /* constants*/ 894 const int numdof=NDOF1*NUM VERTICES_BOUNDARY;895 const int numdof=NDOF1*NUMNODES_BOUNDARY; 895 896 896 897 /* Intermediaries*/ 897 898 int i,ig,index1,index2; 898 899 IssmDouble DL,Jdet,vx,vy,mean_vx,mean_vy,UdotN,thickness; 899 IssmDouble xyz_list[NUMVERTICES _BOUNDARY][3];900 IssmDouble xyz_list[NUMVERTICES][3]; 900 901 IssmDouble normal[2]; 901 902 IssmDouble L[numdof]; … … 908 909 909 910 /*Retrieve all inputs and parameters*/ 910 GetVerticesCoordinates(&xyz_list[0][0], nodes,NUMVERTICES_BOUNDARY);911 GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES); 911 912 Input* vxaverage_input=tria->inputs->GetInput(VxEnum); _assert_(vxaverage_input); 912 913 Input* vyaverage_input=tria->inputs->GetInput(VyEnum); _assert_(vyaverage_input); … … 928 929 } 929 930 else{ 930 pe=new ElementVector(nodes,NUM VERTICES_BOUNDARY,this->parameters);931 pe=new ElementVector(nodes,NUMNODES_BOUNDARY,this->parameters); 931 932 } 932 933 -
issm/trunk-jpl/src/c/classes/objects/Node.cpp
r13761 r14763 599 599 } 600 600 /*}}}*/ 601 /*FUNCTION Node::GetSigma {{{*/602 IssmDouble Node::GetSigma(){603 Vertex* vertex=NULL;604 605 vertex=(Vertex*)hvertex->delivers();606 return vertex->sigma;607 }608 /*}}}*/609 /*FUNCTION Node::GetX {{{*/610 IssmDouble Node::GetX(){611 Vertex* vertex=NULL;612 613 vertex=(Vertex*)hvertex->delivers();614 return vertex->x;615 }616 /*}}}*/617 /*FUNCTION Node::GetY {{{*/618 IssmDouble Node::GetY(){619 Vertex* vertex=NULL;620 621 vertex=(Vertex*)hvertex->delivers();622 return vertex->y;623 }624 /*}}}*/625 /*FUNCTION Node::GetZ {{{*/626 IssmDouble Node::GetZ(){627 Vertex* vertex=NULL;628 629 vertex=(Vertex*)hvertex->delivers();630 return vertex->z;631 }632 /*}}}*/633 601 /*FUNCTION Node::IsClone {{{*/ 634 602 int Node::IsClone(){ -
issm/trunk-jpl/src/c/classes/objects/Node.h
r13623 r14763 84 84 int GetVertexPid(void); 85 85 int GetVertexSid(void); 86 IssmDouble GetX();87 IssmDouble GetY();88 IssmDouble GetZ();89 IssmDouble GetSigma();90 86 int IsOnBed(); 91 87 int IsOnSurface(); -
issm/trunk-jpl/src/c/classes/objects/Vertex.cpp
r14648 r14763 105 105 int Vertex::Connectivity(void){return connectivity;} 106 106 /*}}}*/ 107 /*FUNCTION Vertex::GetX {{{*/ 108 IssmDouble Vertex::GetX(){ 109 return this->x; 110 } 111 /*}}}*/ 112 /*FUNCTION Vertex::GetY {{{*/ 113 IssmDouble Vertex::GetY(){ 114 return this->y; 115 } 116 /*}}}*/ 117 /*FUNCTION Vertex::GetZ {{{*/ 118 IssmDouble Vertex::GetZ(){ 119 return this->z; 120 } 121 /*}}}*/ 107 122 /*FUNCTION Vertex::Sid{{{*/ 108 123 int Vertex::Sid(void){ return sid; } -
issm/trunk-jpl/src/c/classes/objects/Vertex.h
r14648 r14763 46 46 /*}}}*/ 47 47 /*Vertex management:*/ 48 int Sid(void); 49 int Connectivity(void); 50 void UpdatePosition(Vector<IssmDouble>* vz,Parameters* parameters,IssmDouble* thickness,IssmDouble* bed); 51 void DistributePids(int* ppidcount); 52 void OffsetPids(int pidcount); 53 void ShowTruePids(int* borderpids); 54 void UpdateClonePids(int* allborderpids); 55 void SetClone(int* minranks); 56 void ToXYZ(Matrix<IssmDouble>* matrix); 57 void VertexCoordinates(Vector<IssmDouble>* vx,Vector<IssmDouble>* vy,Vector<IssmDouble>* vz); 48 int Sid(void); 49 int Connectivity(void); 50 IssmDouble GetX(void); 51 IssmDouble GetY(void); 52 IssmDouble GetZ(void); 53 void UpdatePosition(Vector<IssmDouble>* vz,Parameters* parameters,IssmDouble* thickness,IssmDouble* bed); 54 void DistributePids(int* ppidcount); 55 void OffsetPids(int pidcount); 56 void ShowTruePids(int* borderpids); 57 void UpdateClonePids(int* allborderpids); 58 void SetClone(int* minranks); 59 void ToXYZ(Matrix<IssmDouble>* matrix); 60 void VertexCoordinates(Vector<IssmDouble>* vx,Vector<IssmDouble>* vy,Vector<IssmDouble>* vz); 58 61 }; 59 62 #endif /* _VERTEX_H */ -
issm/trunk-jpl/src/c/shared/Elements/GetVerticesCoordinates.cpp
r12475 r14763 5 5 #include "./elements.h" 6 6 7 void GetVerticesCoordinates(IssmDouble* xyz, Node** nodes, int numvertices){7 void GetVerticesCoordinates(IssmDouble* xyz,Vertex** vertices, int numvertices){ 8 8 9 /*In debugging mode, check that nodes is not a NULL pointer*/10 _assert_( nodes);9 _assert_(vertices); 10 _assert_(xyz); 11 11 12 12 for(int i=0;i<numvertices;i++) { 13 xyz[i*3+0]= nodes[i]->GetX();14 xyz[i*3+1]= nodes[i]->GetY();15 xyz[i*3+2]= nodes[i]->GetZ();13 xyz[i*3+0]=vertices[i]->GetX(); 14 xyz[i*3+1]=vertices[i]->GetY(); 15 xyz[i*3+2]=vertices[i]->GetZ(); 16 16 } 17 17 } -
issm/trunk-jpl/src/c/shared/Elements/elements.h
r14735 r14763 10 10 class ElementMatrix; 11 11 class ElementVector; 12 class Vertex; 12 13 13 14 IssmDouble Paterson(IssmDouble temperature); … … 21 22 IssmDouble* TemperaturesLgm, IssmDouble* TemperaturesPresentday, 22 23 IssmDouble* monthlytemperaturesout, IssmDouble* monthlyprecout); 23 void GetVerticesCoordinates(IssmDouble* xyz, Node** nodes,int numvertices);24 void GetVerticesCoordinates(IssmDouble* xyz,Vertex** vertices,int numvertices); 24 25 int GetNumberOfDofs( Node** nodes,int numnodes,int setenum,int approximation_enum); 25 26 int* GetLocalDofList( Node** nodes,int numnodes,int setenum,int approximation_enum);
Note:
See TracChangeset
for help on using the changeset viewer.