Changeset 11656
- Timestamp:
- 03/07/12 13:38:04 (13 years ago)
- Location:
- issm/trunk-jpl/src/c
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/Makefile.am
r11643 r11656 204 204 ./shared/Elements/GetGlobalDofList.cpp\ 205 205 ./shared/Elements/GetNumberOfDofs.cpp\ 206 ./shared/Elements/CoordinateSystemTransform.cpp\207 206 ./shared/String/sharedstring.h\ 208 207 ./toolkits/petsc\ … … 502 501 ./modules/ModelProcessorx/DiagnosticHutter/CreateConstraintsDiagnosticHutter.cpp \ 503 502 ./modules/ModelProcessorx/DiagnosticHutter/CreateLoadsDiagnosticHutter.cpp \ 503 ./shared/Elements/CoordinateSystemTransform.cpp\ 504 504 ./shared/Elements/TransformLoadVectorCoord.cpp \ 505 505 ./shared/Elements/TransformStiffnessMatrixCoord.cpp \ -
issm/trunk-jpl/src/c/objects/Elements/Element.h
r11508 r11656 58 58 virtual void RequestedOutput(int output_enum,int step,double time)=0; 59 59 60 virtual int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units)=0; 60 61 virtual void InputScale(int enum_type,double scale_factor)=0; 61 62 virtual void GetVectorFromInputs(Vec vector, int name_enum)=0; … … 88 89 virtual void ElementResponse(double* presponse,int response_enum,bool process_units)=0; 89 90 virtual double IceVolume(void)=0; 90 virtual int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units)=0;91 91 #endif 92 92 -
issm/trunk-jpl/src/c/objects/Elements/Penta.cpp
r11508 r11656 2325 2325 extern int my_rank; 2326 2326 return my_rank; 2327 } 2328 /*}}}*/ 2329 /*FUNCTION Penta::NodalValue {{{1*/ 2330 int Penta::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){ 2331 2332 int i; 2333 int found=0; 2334 double value; 2335 Input* data=NULL; 2336 GaussPenta* gauss=NULL; 2337 2338 /*First, serarch the input: */ 2339 data=inputs->GetInput(natureofdataenum); 2340 2341 /*figure out if we have the vertex id: */ 2342 found=0; 2343 for(i=0;i<NUMVERTICES;i++){ 2344 if(index==nodes[i]->GetVertexId()){ 2345 /*Do we have natureofdataenum in our inputs? :*/ 2346 if(data){ 2347 /*ok, we are good. retrieve value of input at vertex :*/ 2348 gauss=new GaussPenta(); gauss->GaussVertex(i); 2349 data->GetInputValue(&value,gauss); 2350 found=1; 2351 break; 2352 } 2353 } 2354 } 2355 2356 if(found)*pvalue=value; 2357 return found; 2327 2358 } 2328 2359 /*}}}*/ … … 3002 3033 } 3003 3034 /*}}}*/ 3004 /*FUNCTION Penta::NodalValue {{{1*/3005 int Penta::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){3006 3007 int i;3008 int found=0;3009 double value;3010 Input* data=NULL;3011 GaussPenta* gauss=NULL;3012 3013 /*First, serarch the input: */3014 data=inputs->GetInput(natureofdataenum);3015 3016 /*figure out if we have the vertex id: */3017 found=0;3018 for(i=0;i<NUMVERTICES;i++){3019 if(index==nodes[i]->GetVertexId()){3020 /*Do we have natureofdataenum in our inputs? :*/3021 if(data){3022 /*ok, we are good. retrieve value of input at vertex :*/3023 gauss=new GaussPenta(); gauss->GaussVertex(i);3024 data->GetInputValue(&value,gauss);3025 found=1;3026 break;3027 }3028 }3029 }3030 3031 if(found)*pvalue=value;3032 return found;3033 }3034 /*}}}*/3035 3035 /*FUNCTION Penta::MinVel{{{1*/ 3036 3036 void Penta::MinVel(double* pminvel, bool process_units){ -
issm/trunk-jpl/src/c/objects/Elements/Penta.h
r11508 r11656 118 118 void Update(int index, IoModel* iomodel,int analysis_counter,int analysis_type); 119 119 int UpdatePotentialSheetUngrounding(double* potential_sheet_ungrounding,Vec vec_nodes_on_iceshelf,double* nodes_on_iceshelf); 120 int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units); 120 121 double TimeAdapt(); 121 122 int* GetHorizontalNeighboorSids(void); … … 129 130 void MinVy(double* pminvy, bool process_units); 130 131 void MinVz(double* pminvz, bool process_units); 131 int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);132 132 double MassFlux(double* segment,bool process_units); 133 133 void MaxAbsVx(double* pmaxabsvx, bool process_units); -
issm/trunk-jpl/src/c/objects/Elements/Tria.cpp
r11563 r11656 2123 2123 } 2124 2124 /*}}}*/ 2125 /*FUNCTION Tria::NodalValue {{{1*/ 2126 int Tria::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){ 2127 2128 int i; 2129 int found=0; 2130 double value; 2131 Input* data=NULL; 2132 GaussTria *gauss = NULL; 2133 2134 /*First, serarch the input: */ 2135 data=inputs->GetInput(natureofdataenum); 2136 2137 /*figure out if we have the vertex id: */ 2138 found=0; 2139 for(i=0;i<NUMVERTICES;i++){ 2140 if(index==nodes[i]->GetVertexId()){ 2141 /*Do we have natureofdataenum in our inputs? :*/ 2142 if(data){ 2143 /*ok, we are good. retrieve value of input at vertex :*/ 2144 gauss=new GaussTria(); gauss->GaussVertex(i); 2145 data->GetInputValue(&value,gauss); 2146 found=1; 2147 break; 2148 } 2149 } 2150 } 2151 2152 if(found)*pvalue=value; 2153 return found; 2154 } 2155 /*}}}*/ 2125 2156 /*FUNCTION Tria::PatchFill{{{1*/ 2126 2157 void Tria::PatchFill(int* prow, Patch* patch){ … … 2737 2768 /*Assign output pointers:*/ 2738 2769 *pminvz=minvz; 2739 }2740 /*}}}*/2741 /*FUNCTION Tria::NodalValue {{{1*/2742 int Tria::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){2743 2744 int i;2745 int found=0;2746 double value;2747 Input* data=NULL;2748 GaussTria *gauss = NULL;2749 2750 /*First, serarch the input: */2751 data=inputs->GetInput(natureofdataenum);2752 2753 /*figure out if we have the vertex id: */2754 found=0;2755 for(i=0;i<NUMVERTICES;i++){2756 if(index==nodes[i]->GetVertexId()){2757 /*Do we have natureofdataenum in our inputs? :*/2758 if(data){2759 /*ok, we are good. retrieve value of input at vertex :*/2760 gauss=new GaussTria(); gauss->GaussVertex(i);2761 data->GetInputValue(&value,gauss);2762 found=1;2763 break;2764 }2765 }2766 }2767 2768 if(found)*pvalue=value;2769 return found;2770 2770 } 2771 2771 /*}}}*/ -
issm/trunk-jpl/src/c/objects/Elements/Tria.h
r11508 r11656 106 106 void MaterialUpdateFromTemperature(void){_error_("not implemented yet");}; 107 107 void MigrateGroundingLine(double* oldfloating,double* sheet_ungrounding); 108 int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units); 108 109 void PotentialSheetUngrounding(Vec potential_sheet_ungrounding); 109 110 void PositiveDegreeDay(void); … … 127 128 void MinVy(double* pminvy, bool process_units); 128 129 void MinVz(double* pminvz, bool process_units); 129 int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);130 130 double MassFlux(double* segment,bool process_units); 131 131 void MaxAbsVx(double* pmaxabsvx, bool process_units); -
issm/trunk-jpl/src/c/objects/Loads/Pengrid.cpp
r10576 r11656 319 319 320 320 switch(analysis_type){ 321 #ifdef _HAVE_DIAGNOSTIC_ 321 322 case DiagnosticHorizAnalysisEnum: case AdjointHorizAnalysisEnum: 322 323 Ke=PenaltyCreateKMatrixDiagnosticStokes(kmax); 323 324 break; 325 #endif 326 #ifdef _HAVE_THERMAL_ 324 327 case ThermalAnalysisEnum: 325 328 Ke=PenaltyCreateKMatrixThermal(kmax); … … 328 331 Ke=PenaltyCreateKMatrixMelting(kmax); 329 332 break; 333 #endif 330 334 default: 331 335 _error_("analysis %i (%s) not supported yet",analysis_type,EnumToStringx(analysis_type)); … … 348 352 349 353 switch(analysis_type){ 354 #ifdef _HAVE_DIAGNOSTIC_ 350 355 case ThermalAnalysisEnum: 351 356 pe=PenaltyCreatePVectorThermal(kmax); 352 357 break; 358 #endif 359 #ifdef _HAVE_THERMAL_ 353 360 case MeltingAnalysisEnum: 354 361 pe=PenaltyCreatePVectorMelting(kmax); … … 356 363 case DiagnosticHorizAnalysisEnum: case AdjointHorizAnalysisEnum: 357 364 break; 365 #endif 358 366 default: 359 367 _error_("analysis %i (%s) not supported yet",analysis_type,EnumToStringx(analysis_type)); … … 539 547 } 540 548 /*}}}1*/ 549 #ifdef _HAVE_DIAGNOSTIC_ 541 550 /*FUNCTION Pengrid::PenaltyCreateKMatrixDiagnosticStokes {{{1*/ 542 551 ElementMatrix* Pengrid::PenaltyCreateKMatrixDiagnosticStokes(double kmax){ … … 571 580 } 572 581 /*}}}1*/ 582 #endif 583 #ifdef _HAVE_THERMAL_ 573 584 /*FUNCTION Pengrid::PenaltyCreateKMatrixMelting {{{1*/ 574 585 ElementMatrix* Pengrid::PenaltyCreateKMatrixMelting(double kmax){ … … 690 701 } 691 702 /*}}}1*/ 703 #endif 692 704 /*FUNCTION Pengrid::ResetConstraint {{{1*/ 693 705 void Pengrid::ResetConstraint(void){ -
issm/trunk-jpl/src/c/objects/Loads/Pengrid.h
r11327 r11656 84 84 /*}}}*/ 85 85 /*Pengrid management {{{1*/ 86 #ifdef _HAVE_DIAGNOSTIC_ 86 87 ElementMatrix* PenaltyCreateKMatrixDiagnosticStokes(double kmax); 88 #endif 89 #ifdef _HAVE_THERMAL_ 87 90 ElementMatrix* PenaltyCreateKMatrixThermal(double kmax); 88 91 ElementMatrix* PenaltyCreateKMatrixMelting(double kmax); 89 92 ElementVector* PenaltyCreatePVectorThermal(double kmax); 90 93 ElementVector* PenaltyCreatePVectorMelting(double kmax); 94 #endif 91 95 void ConstraintActivate(int* punstable); 92 96 void ConstraintActivateThermal(int* punstable); -
issm/trunk-jpl/src/c/shared/Elements/elements.h
r11197 r11656 17 17 int* GetLocalDofList( Node** nodes,int numnodes,int setenum,int approximation_enum); 18 18 int* GetGlobalDofList(Node** nodes,int numnodes,int setenum,int approximation_enum); 19 #ifdef _HAVE_DIAGNOSTIC_ 19 20 void CoordinateSystemTransform(double** ptransform,Node** nodes,int numnodes,int* cs_array); 20 #ifdef _HAVE_DIAGNOSTIC_21 21 void TransformInvStiffnessMatrixCoord(ElementMatrix* Ke,Node** nodes,int numnodes,int cs_enum); 22 22 void TransformInvStiffnessMatrixCoord(ElementMatrix* Ke,Node** nodes,int numnodes,int* cs_array);
Note:
See TracChangeset
for help on using the changeset viewer.