[17986] | 1 | Index: ../trunk-jpl/src/c/analyses/HydrologyDCEfficientAnalysis.cpp
|
---|
| 2 | ===================================================================
|
---|
| 3 | --- ../trunk-jpl/src/c/analyses/HydrologyDCEfficientAnalysis.cpp (revision 17886)
|
---|
| 4 | +++ ../trunk-jpl/src/c/analyses/HydrologyDCEfficientAnalysis.cpp (revision 17887)
|
---|
| 5 | @@ -347,7 +347,7 @@
|
---|
| 6 | if(xIsNan<IssmDouble>(eplHeads[i])) _error_("NaN found in solution vector");
|
---|
| 7 | }
|
---|
| 8 | /*Add input to the element: */
|
---|
| 9 | - element->AddBasalInput(EplHeadEnum,eplHeads,P1Enum);
|
---|
| 10 | + element->AddInput(EplHeadEnum,eplHeads,P1Enum);
|
---|
| 11 |
|
---|
| 12 | /*Free ressources:*/
|
---|
| 13 | xDelete<IssmDouble>(eplHeads);
|
---|
| 14 | Index: ../trunk-jpl/src/c/analyses/MasstransportAnalysis.cpp
|
---|
| 15 | ===================================================================
|
---|
| 16 | --- ../trunk-jpl/src/c/analyses/MasstransportAnalysis.cpp (revision 17886)
|
---|
| 17 | +++ ../trunk-jpl/src/c/analyses/MasstransportAnalysis.cpp (revision 17887)
|
---|
| 18 | @@ -734,9 +734,9 @@
|
---|
| 19 | }
|
---|
| 20 |
|
---|
| 21 | /*Add input to the element: */
|
---|
| 22 | - element->AddBasalInput(ThicknessEnum,newthickness,P1Enum);
|
---|
| 23 | - element->AddBasalInput(SurfaceEnum,newsurface,P1Enum);
|
---|
| 24 | - element->AddBasalInput(BaseEnum,newbed,P1Enum);
|
---|
| 25 | + element->AddInput(ThicknessEnum,newthickness,P1Enum);
|
---|
| 26 | + element->AddInput(SurfaceEnum,newsurface,P1Enum);
|
---|
| 27 | + element->AddInput(BaseEnum,newbed,P1Enum);
|
---|
| 28 |
|
---|
| 29 | /*Free ressources:*/
|
---|
| 30 | xDelete<IssmDouble>(newthickness);
|
---|
| 31 | Index: ../trunk-jpl/src/c/analyses/HydrologyDCInefficientAnalysis.cpp
|
---|
| 32 | ===================================================================
|
---|
| 33 | --- ../trunk-jpl/src/c/analyses/HydrologyDCInefficientAnalysis.cpp (revision 17886)
|
---|
| 34 | +++ ../trunk-jpl/src/c/analyses/HydrologyDCInefficientAnalysis.cpp (revision 17887)
|
---|
| 35 | @@ -459,9 +459,9 @@
|
---|
| 36 | }
|
---|
| 37 |
|
---|
| 38 | /*Add input to the element: */
|
---|
| 39 | - element->AddBasalInput(SedimentHeadEnum,values,P1Enum);
|
---|
| 40 | - element->AddBasalInput(SedimentHeadResidualEnum,residual,P1Enum);
|
---|
| 41 | - element->AddBasalInput(EffectivePressureEnum,pressure,P1Enum);
|
---|
| 42 | + element->AddInput(SedimentHeadEnum,values,P1Enum);
|
---|
| 43 | + element->AddInput(SedimentHeadResidualEnum,residual,P1Enum);
|
---|
| 44 | + element->AddInput(EffectivePressureEnum,pressure,P1Enum);
|
---|
| 45 |
|
---|
| 46 | /*Free ressources:*/
|
---|
| 47 | xDelete<IssmDouble>(values);
|
---|
| 48 | Index: ../trunk-jpl/src/c/analyses/DamageEvolutionAnalysis.cpp
|
---|
| 49 | ===================================================================
|
---|
| 50 | --- ../trunk-jpl/src/c/analyses/DamageEvolutionAnalysis.cpp (revision 17886)
|
---|
| 51 | +++ ../trunk-jpl/src/c/analyses/DamageEvolutionAnalysis.cpp (revision 17887)
|
---|
| 52 | @@ -419,7 +419,7 @@
|
---|
| 53 | basalelement->AddInput(DamageDbarEnum,newdamage,element->GetElementType());
|
---|
| 54 | }
|
---|
| 55 | else{
|
---|
| 56 | - basalelement->AddBasalInput(DamageDEnum,newdamage,element->GetElementType());
|
---|
| 57 | + basalelement->AddInput(DamageDEnum,newdamage,element->GetElementType());
|
---|
| 58 | }
|
---|
| 59 |
|
---|
| 60 | /*Free ressources:*/
|
---|
| 61 | Index: ../trunk-jpl/src/c/cores/masstransport_core.cpp
|
---|
| 62 | ===================================================================
|
---|
| 63 | --- ../trunk-jpl/src/c/cores/masstransport_core.cpp (revision 17886)
|
---|
| 64 | +++ ../trunk-jpl/src/c/cores/masstransport_core.cpp (revision 17887)
|
---|
| 65 | @@ -47,28 +47,23 @@
|
---|
| 66 | if(VerboseSolution()) _printf0_(" call free surface computational core\n");
|
---|
| 67 | femmodel->SetCurrentConfiguration(FreeSurfaceBaseAnalysisEnum);
|
---|
| 68 | solutionsequence_linear(femmodel);
|
---|
| 69 | - if(domaintype!=Domain2DhorizontalEnum){
|
---|
| 70 | - femmodel->parameters->SetParam(BaseEnum,InputToExtrudeEnum);
|
---|
| 71 | - extrudefrombase_core(femmodel);
|
---|
| 72 | - }
|
---|
| 73 | + femmodel->parameters->SetParam(BaseEnum,InputToExtrudeEnum);
|
---|
| 74 | + extrudefrombase_core(femmodel);
|
---|
| 75 | +
|
---|
| 76 | femmodel->SetCurrentConfiguration(FreeSurfaceTopAnalysisEnum);
|
---|
| 77 | solutionsequence_linear(femmodel);
|
---|
| 78 | - if(domaintype!=Domain2DhorizontalEnum){
|
---|
| 79 | - femmodel->parameters->SetParam(SurfaceEnum,InputToExtrudeEnum);
|
---|
| 80 | - extrudefromtop_core(femmodel);
|
---|
| 81 | - }
|
---|
| 82 | + femmodel->parameters->SetParam(SurfaceEnum,InputToExtrudeEnum);
|
---|
| 83 | + extrudefromtop_core(femmodel);
|
---|
| 84 | }
|
---|
| 85 | else{
|
---|
| 86 | if(VerboseSolution()) _printf0_(" call computational core\n");
|
---|
| 87 | solutionsequence_linear(femmodel);
|
---|
| 88 | - if(domaintype==Domain2DverticalEnum){
|
---|
| 89 | - femmodel->parameters->SetParam(ThicknessEnum,InputToExtrudeEnum);
|
---|
| 90 | - extrudefrombase_core(femmodel);
|
---|
| 91 | - femmodel->parameters->SetParam(BaseEnum,InputToExtrudeEnum);
|
---|
| 92 | - extrudefrombase_core(femmodel);
|
---|
| 93 | - femmodel->parameters->SetParam(SurfaceEnum,InputToExtrudeEnum);
|
---|
| 94 | - extrudefrombase_core(femmodel);
|
---|
| 95 | - }
|
---|
| 96 | + femmodel->parameters->SetParam(ThicknessEnum,InputToExtrudeEnum);
|
---|
| 97 | + extrudefrombase_core(femmodel);
|
---|
| 98 | + femmodel->parameters->SetParam(BaseEnum,InputToExtrudeEnum);
|
---|
| 99 | + extrudefrombase_core(femmodel);
|
---|
| 100 | + femmodel->parameters->SetParam(SurfaceEnum,InputToExtrudeEnum);
|
---|
| 101 | + extrudefrombase_core(femmodel);
|
---|
| 102 | }
|
---|
| 103 |
|
---|
| 104 | if(save_results){
|
---|
| 105 | Index: ../trunk-jpl/src/c/cores/hydrology_core.cpp
|
---|
| 106 | ===================================================================
|
---|
| 107 | --- ../trunk-jpl/src/c/cores/hydrology_core.cpp (revision 17886)
|
---|
| 108 | +++ ../trunk-jpl/src/c/cores/hydrology_core.cpp (revision 17887)
|
---|
| 109 | @@ -34,7 +34,6 @@
|
---|
| 110 | solutionsequence_nonlinear(femmodel,modify_loads);
|
---|
| 111 |
|
---|
| 112 | /*transfer water column thickness to old water column thickness: */
|
---|
| 113 | -
|
---|
| 114 | InputDuplicatex(femmodel,WatercolumnEnum,WaterColumnOldEnum);
|
---|
| 115 |
|
---|
| 116 | if(save_results){
|
---|
| 117 | @@ -60,6 +59,7 @@
|
---|
| 118 | /*Proceed now to heads computations*/
|
---|
| 119 | if(VerboseSolution()) _printf0_(" computing water head\n");
|
---|
| 120 | solutionsequence_hydro_nonlinear(femmodel);
|
---|
| 121 | +
|
---|
| 122 | if(save_results){
|
---|
| 123 | if(VerboseSolution()) _printf0_(" saving results \n");
|
---|
| 124 | if(isefficientlayer){
|
---|
| 125 | Index: ../trunk-jpl/src/c/cores/extrudefrombase_core.cpp
|
---|
| 126 | ===================================================================
|
---|
| 127 | --- ../trunk-jpl/src/c/cores/extrudefrombase_core.cpp (revision 17886)
|
---|
| 128 | +++ ../trunk-jpl/src/c/cores/extrudefrombase_core.cpp (revision 17887)
|
---|
| 129 | @@ -12,20 +12,26 @@
|
---|
| 130 | void extrudefrombase_core(FemModel* femmodel){
|
---|
| 131 |
|
---|
| 132 | /*Intermediaries*/
|
---|
| 133 | - int elementtype;
|
---|
| 134 | + int elementtype,domaintype;
|
---|
| 135 |
|
---|
| 136 | if(VerboseSolution()) _printf0_("extruding solution from base...\n");
|
---|
| 137 |
|
---|
| 138 | - femmodel->parameters->FindParam(&elementtype,MeshElementtypeEnum);
|
---|
| 139 | - if(elementtype==PentaEnum){
|
---|
| 140 | - int inputenum; femmodel->parameters->FindParam(&inputenum,InputToExtrudeEnum);
|
---|
| 141 | - InputExtrudex(femmodel,inputenum);
|
---|
| 142 | - }
|
---|
| 143 | - else{
|
---|
| 144 | - /*Call on core computations: */
|
---|
| 145 | - femmodel->SetCurrentConfiguration(ExtrudeFromBaseAnalysisEnum);
|
---|
| 146 | - femmodel->UpdateConstraintsExtrudeFromBasex();
|
---|
| 147 | - solutionsequence_linear(femmodel);
|
---|
| 148 | - }
|
---|
| 149 | + /*Get parameters*/
|
---|
| 150 | + femmodel->parameters->FindParam(&domaintype,DomainTypeEnum);
|
---|
| 151 | + femmodel->parameters->FindParam(&elementtype,MeshElementtypeEnum);
|
---|
| 152 |
|
---|
| 153 | + /*If this is a 2D horizontal domain, return (no need to extrude)*/
|
---|
| 154 | + if(domaintype==Domain2DhorizontalEnum) return;
|
---|
| 155 | +
|
---|
| 156 | + /*Special method for Penta, otherwise call solution sequence*/
|
---|
| 157 | + if(elementtype==PentaEnum){
|
---|
| 158 | + int inputenum; femmodel->parameters->FindParam(&inputenum,InputToExtrudeEnum);
|
---|
| 159 | + InputExtrudex(femmodel,inputenum);
|
---|
| 160 | + }
|
---|
| 161 | + else{
|
---|
| 162 | + /*Call on core computations: */
|
---|
| 163 | + femmodel->SetCurrentConfiguration(ExtrudeFromBaseAnalysisEnum);
|
---|
| 164 | + femmodel->UpdateConstraintsExtrudeFromBasex();
|
---|
| 165 | + solutionsequence_linear(femmodel);
|
---|
| 166 | + }
|
---|
| 167 | }
|
---|