Changeset 16817


Ignore:
Timestamp:
11/18/13 11:03:54 (11 years ago)
Author:
bdef
Message:

CHG : clean up and change in the way we treat inactive nodes for the epl thickness computation

Location:
issm/trunk-jpl/src/c
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/c/classes/Elements/Element.h

    r16816 r16817  
    202202                virtual void HydrologyEPLGetActive(Vector<IssmDouble>* active)=0;
    203203                virtual void ComputeEPLThickness(void)=0;
    204                 virtual void UpdateConstraintsL2ProjectionEPL(void)=0;
    205204                #endif
    206205
  • issm/trunk-jpl/src/c/classes/Elements/Penta.cpp

    r16816 r16817  
    97289728}
    97299729/*}}}*/
    9730 /*FUNCTION Penta::UpdateConstraintsL2ProjectionEPL{{{*/
    9731 void  Penta::UpdateConstraintsL2ProjectionEPL(void){
    9732 
    9733         IssmDouble activeEpl[NUMVERTICES];
    9734 
    9735 
    9736         if(!IsOnBed()){
    9737                 for(int i=0;i<this->NumberofNodes();i++)this->nodes[i]->Deactivate();
    9738         }
    9739         else{
    9740                 GetInputListOnVertices(&activeEpl[0],HydrologydcMaskEplactiveEnum);
    9741                 for(int i=0;i<3;i++){
    9742                         if(!reCast<bool>(activeEpl[i])){
    9743                                 this->nodes[i]->Deactivate();
    9744                         }
    9745                         else{
    9746                                 this->nodes[i]->Activate();
    9747                         }
    9748                 }
    9749         }
    9750 }
    9751 /*}}}*/
    97529730#endif
    97539731
  • issm/trunk-jpl/src/c/classes/Elements/Penta.h

    r16816 r16817  
    354354                void           HydrologyEPLGetMask(Vector<IssmDouble>* vec_mask);
    355355                void           ComputeEPLThickness(void);
    356                 void           UpdateConstraintsL2ProjectionEPL(void);
    357356                #endif
    358357
  • issm/trunk-jpl/src/c/classes/Elements/Seg.h

    r16816 r16817  
    180180                void UpdateConstraintsExtrudeFromBase(){_error_("not implemented");};
    181181                void UpdateConstraintsExtrudeFromTop(){_error_("not implemented");};
    182                 void UpdateConstraintsL2ProjectionEPL(){_error_("not implemented");};
    183182
    184183#ifdef _HAVE_RESPONSES_
  • issm/trunk-jpl/src/c/classes/Elements/Tria.cpp

    r16810 r16817  
    28842884}
    28852885/*}}}*/
    2886 /*FUNCTION Tria::UpdateConstraintsL2ProjectionEPL{{{*/
    2887 void  Tria::UpdateConstraintsL2ProjectionEPL(void){
    2888 
    2889         IssmDouble activeEpl[NUMVERTICES];
    2890  
    2891         GetInputListOnVertices(&activeEpl[0],HydrologydcMaskEplactiveEnum);
    2892         for(int i=0;i<NUMVERTICES;i++){
    2893                 if(!reCast<bool>(activeEpl[i])){
    2894                         this->nodes[i]->Deactivate();
    2895                 }
    2896                 else{
    2897                         this->nodes[i]->Activate();
    2898                 }
    2899         }
    2900 }
    2901 /*}}}*/
     2886
    29022887#ifdef _HAVE_RESPONSES_
    29032888/*FUNCTION Tria::AverageOntoPartition {{{*/
     
    70337018                GetInputListOnVertices(&bed[0],BedEnum);
    70347019               
    7035                 for(int i=0;i<numdof;i++){
     7020                if(!this->AnyActive()){
    70367021                        /*Keeping thickness to initial value if EPL is not active*/
    7037                         /* if(activeEpl[i]==0.0){ */
    7038                         /*      thickness[i]=init_thick; */
    7039                         /* } */
    7040                         /* else{ */
    7041                                 /*Compute first the effective pressure in the EPL*/
    7042                                 EPL_N=gravity*((rho_ice*ice_thickness[i])-(rho_water*(eplhead[i]-bed[i])));
    7043                                 if(EPL_N<0.0)EPL_N=0.0;
    7044                                 /*Get then the gradient of EPL heads*/
    7045                                 EPLgrad = epl_slopeX[i]+epl_slopeY[i];
    7046                                
    7047                                 /*And proceed to the real thing*/
    7048                                 thickness[i] = old_thickness[i]*(1+((rho_water*gravity*dt)/(rho_ice*latentheat))*epl_conductivity*pow(EPLgrad,2.0)-2.0*(A*dt/(pow(n,n)))*(pow(EPL_N,n)));
    7049                                 //}
     7022                        for(int i=0;i<numdof;i++){
     7023                                thickness[i]=init_thick;
     7024                        }
     7025                }
     7026                else{
     7027                        for(int i=0;i<numdof;i++){
     7028                                        /*Compute first the effective pressure in the EPL*/
     7029                                        EPL_N=gravity*((rho_ice*ice_thickness[i])-(rho_water*(eplhead[i]-bed[i])));
     7030                                        if(EPL_N<0.0)EPL_N=0.0;
     7031                                        /*Get then the gradient of EPL heads*/
     7032                                        EPLgrad = epl_slopeX[i]+epl_slopeY[i];
     7033                                       
     7034                                        /*And proceed to the real thing*/
     7035                                        thickness[i] = old_thickness[i]*(1+((rho_water*gravity*dt)/(rho_ice*latentheat))*epl_conductivity*pow(EPLgrad,2.0)-2.0*(A*dt/(pow(n,n)))*(pow(EPL_N,n)));
     7036                        }
    70507037                }
    70517038                this->inputs->AddInput(new TriaInput(HydrologydcEplThicknessEnum,thickness,P1Enum));
  • issm/trunk-jpl/src/c/classes/Elements/Tria.h

    r16816 r16817  
    346346                void           HydrologyEPLGetMask(Vector<IssmDouble>* vec_mask);
    347347                void           ComputeEPLThickness(void);
    348                 void           UpdateConstraintsL2ProjectionEPL(void);
    349348                bool           AllActive(void);
    350349                bool           AnyActive(void);
  • issm/trunk-jpl/src/c/classes/FemModel.cpp

    r16788 r16817  
    14611461        /*Update dof indexings*/
    14621462        this->UpdateConstraintsx();
    1463 
    1464         /* for(int i=0;i<elements->Size();i++){ */
    1465         /*      Element* element=dynamic_cast<Element*>(elements->GetObjectByOffset(i)); */
    1466         /*      element->UpdateConstraintsL2ProjectionEPL(); */
    1467         /* } */
    1468 
    1469 }
    1470 /*}}}*/#endif
     1463}
     1464/*}}}*/
     1465#endif
  • issm/trunk-jpl/src/c/solutionsequences/solutionsequence_hydro_nonlinear.cpp

    r16758 r16817  
    139139                                solutionsequence_linear(femmodel);
    140140
     141                                femmodel->HydrologyEPLThicknessx();
     142
    141143                                femmodel->SetCurrentConfiguration(HydrologyDCEfficientAnalysisEnum);
    142                                 femmodel->HydrologyEPLThicknessx();
     144                                //                              femmodel->HydrologyEPLThicknessx();
    143145                                //updating mask after the computation of the epl thickness (Allow to close too thin EPL)
    144146                                femmodel->HydrologyEPLupdateDomainx();
Note: See TracChangeset for help on using the changeset viewer.