[11991] | 1 | Index: /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/shared/Elements/elements.h
|
---|
| 2 | ===================================================================
|
---|
| 3 | --- /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/shared/Elements/elements.h (revision 11655)
|
---|
| 4 | +++ /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/shared/Elements/elements.h (revision 11656)
|
---|
| 5 | @@ -16,8 +16,8 @@
|
---|
| 6 | int GetNumberOfDofs( Node** nodes,int numnodes,int setenum,int approximation_enum);
|
---|
| 7 | int* GetLocalDofList( Node** nodes,int numnodes,int setenum,int approximation_enum);
|
---|
| 8 | int* GetGlobalDofList(Node** nodes,int numnodes,int setenum,int approximation_enum);
|
---|
| 9 | +#ifdef _HAVE_DIAGNOSTIC_
|
---|
| 10 | void CoordinateSystemTransform(double** ptransform,Node** nodes,int numnodes,int* cs_array);
|
---|
| 11 | -#ifdef _HAVE_DIAGNOSTIC_
|
---|
| 12 | void TransformInvStiffnessMatrixCoord(ElementMatrix* Ke,Node** nodes,int numnodes,int cs_enum);
|
---|
| 13 | void TransformInvStiffnessMatrixCoord(ElementMatrix* Ke,Node** nodes,int numnodes,int* cs_array);
|
---|
| 14 | void TransformStiffnessMatrixCoord(ElementMatrix* Ke,Node** nodes,int numnodes,int cs_enum);
|
---|
| 15 | Index: /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/Makefile.am
|
---|
| 16 | ===================================================================
|
---|
| 17 | --- /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/Makefile.am (revision 11655)
|
---|
| 18 | +++ /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/Makefile.am (revision 11656)
|
---|
| 19 | @@ -203,7 +203,6 @@
|
---|
| 20 | ./shared/Elements/GetLocalDofList.cpp\
|
---|
| 21 | ./shared/Elements/GetGlobalDofList.cpp\
|
---|
| 22 | ./shared/Elements/GetNumberOfDofs.cpp\
|
---|
| 23 | - ./shared/Elements/CoordinateSystemTransform.cpp\
|
---|
| 24 | ./shared/String/sharedstring.h\
|
---|
| 25 | ./toolkits/petsc\
|
---|
| 26 | ./toolkits/petsc/patches\
|
---|
| 27 | @@ -501,6 +500,7 @@
|
---|
| 28 | ./modules/ModelProcessorx/DiagnosticHutter/CreateNodesDiagnosticHutter.cpp \
|
---|
| 29 | ./modules/ModelProcessorx/DiagnosticHutter/CreateConstraintsDiagnosticHutter.cpp \
|
---|
| 30 | ./modules/ModelProcessorx/DiagnosticHutter/CreateLoadsDiagnosticHutter.cpp \
|
---|
| 31 | + ./shared/Elements/CoordinateSystemTransform.cpp\
|
---|
| 32 | ./shared/Elements/TransformLoadVectorCoord.cpp \
|
---|
| 33 | ./shared/Elements/TransformStiffnessMatrixCoord.cpp \
|
---|
| 34 | ./shared/Elements/TransformInvStiffnessMatrixCoord.cpp \
|
---|
| 35 | Index: /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Loads/Pengrid.cpp
|
---|
| 36 | ===================================================================
|
---|
| 37 | --- /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Loads/Pengrid.cpp (revision 11655)
|
---|
| 38 | +++ /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Loads/Pengrid.cpp (revision 11656)
|
---|
| 39 | @@ -318,15 +318,19 @@
|
---|
| 40 | this->parameters->FindParam(&analysis_type,AnalysisTypeEnum);
|
---|
| 41 |
|
---|
| 42 | switch(analysis_type){
|
---|
| 43 | + #ifdef _HAVE_DIAGNOSTIC_
|
---|
| 44 | case DiagnosticHorizAnalysisEnum: case AdjointHorizAnalysisEnum:
|
---|
| 45 | Ke=PenaltyCreateKMatrixDiagnosticStokes(kmax);
|
---|
| 46 | break;
|
---|
| 47 | + #endif
|
---|
| 48 | + #ifdef _HAVE_THERMAL_
|
---|
| 49 | case ThermalAnalysisEnum:
|
---|
| 50 | Ke=PenaltyCreateKMatrixThermal(kmax);
|
---|
| 51 | break;
|
---|
| 52 | case MeltingAnalysisEnum:
|
---|
| 53 | Ke=PenaltyCreateKMatrixMelting(kmax);
|
---|
| 54 | break;
|
---|
| 55 | + #endif
|
---|
| 56 | default:
|
---|
| 57 | _error_("analysis %i (%s) not supported yet",analysis_type,EnumToStringx(analysis_type));
|
---|
| 58 | }
|
---|
| 59 | @@ -347,14 +351,18 @@
|
---|
| 60 | this->parameters->FindParam(&analysis_type,AnalysisTypeEnum);
|
---|
| 61 |
|
---|
| 62 | switch(analysis_type){
|
---|
| 63 | + #ifdef _HAVE_DIAGNOSTIC_
|
---|
| 64 | case ThermalAnalysisEnum:
|
---|
| 65 | pe=PenaltyCreatePVectorThermal(kmax);
|
---|
| 66 | break;
|
---|
| 67 | + #endif
|
---|
| 68 | + #ifdef _HAVE_THERMAL_
|
---|
| 69 | case MeltingAnalysisEnum:
|
---|
| 70 | pe=PenaltyCreatePVectorMelting(kmax);
|
---|
| 71 | break;
|
---|
| 72 | case DiagnosticHorizAnalysisEnum: case AdjointHorizAnalysisEnum:
|
---|
| 73 | break;
|
---|
| 74 | + #endif
|
---|
| 75 | default:
|
---|
| 76 | _error_("analysis %i (%s) not supported yet",analysis_type,EnumToStringx(analysis_type));
|
---|
| 77 | }
|
---|
| 78 | @@ -538,6 +546,7 @@
|
---|
| 79 | *punstable=unstable;
|
---|
| 80 | }
|
---|
| 81 | /*}}}1*/
|
---|
| 82 | +#ifdef _HAVE_DIAGNOSTIC_
|
---|
| 83 | /*FUNCTION Pengrid::PenaltyCreateKMatrixDiagnosticStokes {{{1*/
|
---|
| 84 | ElementMatrix* Pengrid::PenaltyCreateKMatrixDiagnosticStokes(double kmax){
|
---|
| 85 |
|
---|
| 86 | @@ -570,6 +579,8 @@
|
---|
| 87 | return Ke;
|
---|
| 88 | }
|
---|
| 89 | /*}}}1*/
|
---|
| 90 | +#endif
|
---|
| 91 | +#ifdef _HAVE_THERMAL_
|
---|
| 92 | /*FUNCTION Pengrid::PenaltyCreateKMatrixMelting {{{1*/
|
---|
| 93 | ElementMatrix* Pengrid::PenaltyCreateKMatrixMelting(double kmax){
|
---|
| 94 |
|
---|
| 95 | @@ -689,6 +700,7 @@
|
---|
| 96 | return pe;
|
---|
| 97 | }
|
---|
| 98 | /*}}}1*/
|
---|
| 99 | +#endif
|
---|
| 100 | /*FUNCTION Pengrid::ResetConstraint {{{1*/
|
---|
| 101 | void Pengrid::ResetConstraint(void){
|
---|
| 102 | active=0;
|
---|
| 103 | Index: /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Loads/Pengrid.h
|
---|
| 104 | ===================================================================
|
---|
| 105 | --- /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Loads/Pengrid.h (revision 11655)
|
---|
| 106 | +++ /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Loads/Pengrid.h (revision 11656)
|
---|
| 107 | @@ -83,11 +83,15 @@
|
---|
| 108 | bool InAnalysis(int analysis_type);
|
---|
| 109 | /*}}}*/
|
---|
| 110 | /*Pengrid management {{{1*/
|
---|
| 111 | + #ifdef _HAVE_DIAGNOSTIC_
|
---|
| 112 | ElementMatrix* PenaltyCreateKMatrixDiagnosticStokes(double kmax);
|
---|
| 113 | + #endif
|
---|
| 114 | + #ifdef _HAVE_THERMAL_
|
---|
| 115 | ElementMatrix* PenaltyCreateKMatrixThermal(double kmax);
|
---|
| 116 | ElementMatrix* PenaltyCreateKMatrixMelting(double kmax);
|
---|
| 117 | ElementVector* PenaltyCreatePVectorThermal(double kmax);
|
---|
| 118 | ElementVector* PenaltyCreatePVectorMelting(double kmax);
|
---|
| 119 | + #endif
|
---|
| 120 | void ConstraintActivate(int* punstable);
|
---|
| 121 | void ConstraintActivateThermal(int* punstable);
|
---|
| 122 | void UpdateInputs(double* solution);
|
---|
| 123 | Index: /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Element.h
|
---|
| 124 | ===================================================================
|
---|
| 125 | --- /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Element.h (revision 11655)
|
---|
| 126 | +++ /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Element.h (revision 11656)
|
---|
| 127 | @@ -57,6 +57,7 @@
|
---|
| 128 | virtual void ProcessResultsUnits(void)=0;
|
---|
| 129 | virtual void RequestedOutput(int output_enum,int step,double time)=0;
|
---|
| 130 |
|
---|
| 131 | + virtual int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units)=0;
|
---|
| 132 | virtual void InputScale(int enum_type,double scale_factor)=0;
|
---|
| 133 | virtual void GetVectorFromInputs(Vec vector, int name_enum)=0;
|
---|
| 134 | virtual void GetVectorFromResults(Vec vector,int id,int interp)=0;
|
---|
| 135 | @@ -87,7 +88,6 @@
|
---|
| 136 | virtual double MassFlux(double* segment,bool process_units)=0;
|
---|
| 137 | virtual void ElementResponse(double* presponse,int response_enum,bool process_units)=0;
|
---|
| 138 | virtual double IceVolume(void)=0;
|
---|
| 139 | - virtual int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units)=0;
|
---|
| 140 | #endif
|
---|
| 141 |
|
---|
| 142 | #ifdef _HAVE_CONTROL_
|
---|
| 143 | Index: /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Tria.cpp
|
---|
| 144 | ===================================================================
|
---|
| 145 | --- /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Tria.cpp (revision 11655)
|
---|
| 146 | +++ /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Tria.cpp (revision 11656)
|
---|
| 147 | @@ -2122,6 +2122,37 @@
|
---|
| 148 | return my_rank;
|
---|
| 149 | }
|
---|
| 150 | /*}}}*/
|
---|
| 151 | +/*FUNCTION Tria::NodalValue {{{1*/
|
---|
| 152 | +int Tria::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){
|
---|
| 153 | +
|
---|
| 154 | + int i;
|
---|
| 155 | + int found=0;
|
---|
| 156 | + double value;
|
---|
| 157 | + Input* data=NULL;
|
---|
| 158 | + GaussTria *gauss = NULL;
|
---|
| 159 | +
|
---|
| 160 | + /*First, serarch the input: */
|
---|
| 161 | + data=inputs->GetInput(natureofdataenum);
|
---|
| 162 | +
|
---|
| 163 | + /*figure out if we have the vertex id: */
|
---|
| 164 | + found=0;
|
---|
| 165 | + for(i=0;i<NUMVERTICES;i++){
|
---|
| 166 | + if(index==nodes[i]->GetVertexId()){
|
---|
| 167 | + /*Do we have natureofdataenum in our inputs? :*/
|
---|
| 168 | + if(data){
|
---|
| 169 | + /*ok, we are good. retrieve value of input at vertex :*/
|
---|
| 170 | + gauss=new GaussTria(); gauss->GaussVertex(i);
|
---|
| 171 | + data->GetInputValue(&value,gauss);
|
---|
| 172 | + found=1;
|
---|
| 173 | + break;
|
---|
| 174 | + }
|
---|
| 175 | + }
|
---|
| 176 | + }
|
---|
| 177 | +
|
---|
| 178 | + if(found)*pvalue=value;
|
---|
| 179 | + return found;
|
---|
| 180 | +}
|
---|
| 181 | +/*}}}*/
|
---|
| 182 | /*FUNCTION Tria::PatchFill{{{1*/
|
---|
| 183 | void Tria::PatchFill(int* prow, Patch* patch){
|
---|
| 184 |
|
---|
| 185 | @@ -2738,37 +2769,6 @@
|
---|
| 186 | *pminvz=minvz;
|
---|
| 187 | }
|
---|
| 188 | /*}}}*/
|
---|
| 189 | -/*FUNCTION Tria::NodalValue {{{1*/
|
---|
| 190 | -int Tria::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){
|
---|
| 191 | -
|
---|
| 192 | - int i;
|
---|
| 193 | - int found=0;
|
---|
| 194 | - double value;
|
---|
| 195 | - Input* data=NULL;
|
---|
| 196 | - GaussTria *gauss = NULL;
|
---|
| 197 | -
|
---|
| 198 | - /*First, serarch the input: */
|
---|
| 199 | - data=inputs->GetInput(natureofdataenum);
|
---|
| 200 | -
|
---|
| 201 | - /*figure out if we have the vertex id: */
|
---|
| 202 | - found=0;
|
---|
| 203 | - for(i=0;i<NUMVERTICES;i++){
|
---|
| 204 | - if(index==nodes[i]->GetVertexId()){
|
---|
| 205 | - /*Do we have natureofdataenum in our inputs? :*/
|
---|
| 206 | - if(data){
|
---|
| 207 | - /*ok, we are good. retrieve value of input at vertex :*/
|
---|
| 208 | - gauss=new GaussTria(); gauss->GaussVertex(i);
|
---|
| 209 | - data->GetInputValue(&value,gauss);
|
---|
| 210 | - found=1;
|
---|
| 211 | - break;
|
---|
| 212 | - }
|
---|
| 213 | - }
|
---|
| 214 | - }
|
---|
| 215 | -
|
---|
| 216 | - if(found)*pvalue=value;
|
---|
| 217 | - return found;
|
---|
| 218 | -}
|
---|
| 219 | -/*}}}*/
|
---|
| 220 | /*FUNCTION Tria::ElementResponse{{{1*/
|
---|
| 221 | void Tria::ElementResponse(double* presponse,int response_enum,bool process_units){
|
---|
| 222 |
|
---|
| 223 | Index: /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Tria.h
|
---|
| 224 | ===================================================================
|
---|
| 225 | --- /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Tria.h (revision 11655)
|
---|
| 226 | +++ /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Tria.h (revision 11656)
|
---|
| 227 | @@ -105,6 +105,7 @@
|
---|
| 228 | void DeleteResults(void);
|
---|
| 229 | void MaterialUpdateFromTemperature(void){_error_("not implemented yet");};
|
---|
| 230 | void MigrateGroundingLine(double* oldfloating,double* sheet_ungrounding);
|
---|
| 231 | + int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);
|
---|
| 232 | void PotentialSheetUngrounding(Vec potential_sheet_ungrounding);
|
---|
| 233 | void PositiveDegreeDay(void);
|
---|
| 234 | void RequestedOutput(int output_enum,int step,double time);
|
---|
| 235 | @@ -126,7 +127,6 @@
|
---|
| 236 | void MinVx(double* pminvx, bool process_units);
|
---|
| 237 | void MinVy(double* pminvy, bool process_units);
|
---|
| 238 | void MinVz(double* pminvz, bool process_units);
|
---|
| 239 | - int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);
|
---|
| 240 | double MassFlux(double* segment,bool process_units);
|
---|
| 241 | void MaxAbsVx(double* pmaxabsvx, bool process_units);
|
---|
| 242 | void MaxAbsVy(double* pmaxabsvy, bool process_units);
|
---|
| 243 | Index: /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Penta.cpp
|
---|
| 244 | ===================================================================
|
---|
| 245 | --- /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Penta.cpp (revision 11655)
|
---|
| 246 | +++ /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Penta.cpp (revision 11656)
|
---|
| 247 | @@ -2326,6 +2326,37 @@
|
---|
| 248 | return my_rank;
|
---|
| 249 | }
|
---|
| 250 | /*}}}*/
|
---|
| 251 | +/*FUNCTION Penta::NodalValue {{{1*/
|
---|
| 252 | +int Penta::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){
|
---|
| 253 | +
|
---|
| 254 | + int i;
|
---|
| 255 | + int found=0;
|
---|
| 256 | + double value;
|
---|
| 257 | + Input* data=NULL;
|
---|
| 258 | + GaussPenta* gauss=NULL;
|
---|
| 259 | +
|
---|
| 260 | + /*First, serarch the input: */
|
---|
| 261 | + data=inputs->GetInput(natureofdataenum);
|
---|
| 262 | +
|
---|
| 263 | + /*figure out if we have the vertex id: */
|
---|
| 264 | + found=0;
|
---|
| 265 | + for(i=0;i<NUMVERTICES;i++){
|
---|
| 266 | + if(index==nodes[i]->GetVertexId()){
|
---|
| 267 | + /*Do we have natureofdataenum in our inputs? :*/
|
---|
| 268 | + if(data){
|
---|
| 269 | + /*ok, we are good. retrieve value of input at vertex :*/
|
---|
| 270 | + gauss=new GaussPenta(); gauss->GaussVertex(i);
|
---|
| 271 | + data->GetInputValue(&value,gauss);
|
---|
| 272 | + found=1;
|
---|
| 273 | + break;
|
---|
| 274 | + }
|
---|
| 275 | + }
|
---|
| 276 | + }
|
---|
| 277 | +
|
---|
| 278 | + if(found)*pvalue=value;
|
---|
| 279 | + return found;
|
---|
| 280 | +}
|
---|
| 281 | +/*}}}*/
|
---|
| 282 | /*FUNCTION Penta::PatchFill{{{1*/
|
---|
| 283 | void Penta::PatchFill(int* pcount, Patch* patch){
|
---|
| 284 |
|
---|
| 285 | @@ -3001,37 +3032,6 @@
|
---|
| 286 | return base*height;
|
---|
| 287 | }
|
---|
| 288 | /*}}}*/
|
---|
| 289 | -/*FUNCTION Penta::NodalValue {{{1*/
|
---|
| 290 | -int Penta::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){
|
---|
| 291 | -
|
---|
| 292 | - int i;
|
---|
| 293 | - int found=0;
|
---|
| 294 | - double value;
|
---|
| 295 | - Input* data=NULL;
|
---|
| 296 | - GaussPenta* gauss=NULL;
|
---|
| 297 | -
|
---|
| 298 | - /*First, serarch the input: */
|
---|
| 299 | - data=inputs->GetInput(natureofdataenum);
|
---|
| 300 | -
|
---|
| 301 | - /*figure out if we have the vertex id: */
|
---|
| 302 | - found=0;
|
---|
| 303 | - for(i=0;i<NUMVERTICES;i++){
|
---|
| 304 | - if(index==nodes[i]->GetVertexId()){
|
---|
| 305 | - /*Do we have natureofdataenum in our inputs? :*/
|
---|
| 306 | - if(data){
|
---|
| 307 | - /*ok, we are good. retrieve value of input at vertex :*/
|
---|
| 308 | - gauss=new GaussPenta(); gauss->GaussVertex(i);
|
---|
| 309 | - data->GetInputValue(&value,gauss);
|
---|
| 310 | - found=1;
|
---|
| 311 | - break;
|
---|
| 312 | - }
|
---|
| 313 | - }
|
---|
| 314 | - }
|
---|
| 315 | -
|
---|
| 316 | - if(found)*pvalue=value;
|
---|
| 317 | - return found;
|
---|
| 318 | -}
|
---|
| 319 | -/*}}}*/
|
---|
| 320 | /*FUNCTION Penta::MinVel{{{1*/
|
---|
| 321 | void Penta::MinVel(double* pminvel, bool process_units){
|
---|
| 322 |
|
---|
| 323 | Index: /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Penta.h
|
---|
| 324 | ===================================================================
|
---|
| 325 | --- /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Penta.h (revision 11655)
|
---|
| 326 | +++ /proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/objects/Elements/Penta.h (revision 11656)
|
---|
| 327 | @@ -117,6 +117,7 @@
|
---|
| 328 | double SurfaceArea(void);
|
---|
| 329 | void Update(int index, IoModel* iomodel,int analysis_counter,int analysis_type);
|
---|
| 330 | int UpdatePotentialSheetUngrounding(double* potential_sheet_ungrounding,Vec vec_nodes_on_iceshelf,double* nodes_on_iceshelf);
|
---|
| 331 | + int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);
|
---|
| 332 | double TimeAdapt();
|
---|
| 333 | int* GetHorizontalNeighboorSids(void);
|
---|
| 334 | void ViscousHeatingCreateInput(void);
|
---|
| 335 | @@ -128,7 +129,6 @@
|
---|
| 336 | void MinVx(double* pminvx, bool process_units);
|
---|
| 337 | void MinVy(double* pminvy, bool process_units);
|
---|
| 338 | void MinVz(double* pminvz, bool process_units);
|
---|
| 339 | - int NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);
|
---|
| 340 | double MassFlux(double* segment,bool process_units);
|
---|
| 341 | void MaxAbsVx(double* pmaxabsvx, bool process_units);
|
---|
| 342 | void MaxAbsVy(double* pmaxabsvy, bool process_units);
|
---|