Changeset 21488


Ignore:
Timestamp:
01/12/17 23:31:42 (8 years ago)
Author:
bdef
Message:

CHG:putting colapse before open in EPL, fixing an index

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

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/c/analyses/HydrologyDCEfficientAnalysis.cpp

    r21479 r21488  
    234234                gauss           ->GaussPoint(ig);
    235235                basalelement    ->JacobianDeterminant(&Jdet,xyz_list,gauss);
    236 
     236               
    237237                epl_transmitivity = EplTransmitivity(basalelement,gauss,epl_thick_input,epl_head_input,base_input);
    238238                epl_storing                             = EplStoring(basalelement,gauss,epl_thick_input,epl_head_input,base_input);
     
    665665        for(int i=1;i<numnodes;i++) if(sedhead[i]<=sedheadmin)sedheadmin=sedhead[i];
    666666        for(int i=0;i<numnodes;i++){
    667                 /*If node is now closed bring its thickness back to initial*/
    668                 if (old_active[i]==0.){
    669                         epl_thickness[i]=init_thick;
    670                 }
    671                 /*Now starting to look at the activations*/
    672                 if(residual[i]>0.){
    673                         vec_mask->SetValue(basalelement->nodes[i]->Sid(),1.,INS_VAL);
    674                         if(old_active[i]==0.){
    675                                 recurence->SetValue(basalelement->nodes[i]->Sid(),1.,INS_VAL);
    676                         }
    677                 }
    678                 /*Increase of the efficient system is needed if the epl head reach the maximum value (sediment max value for now)*/
    679667                GetHydrologyDCInefficientHmax(&h_max,basalelement,basalelement->nodes[i]);
    680                 if(eplhead[i]>=h_max && active_element){
    681                         for(int j=0;j<numnodes;j++){
    682                                 /*Increase of the domain is on the downstream node in term of sediment head*/
    683                                 if(sedhead[j] == sedheadmin){
    684                                         vec_mask->SetValue(basalelement->nodes[j]->Sid(),1.,INS_VAL);
    685                                         if(old_active[i]==0.){
    686                                                 recurence->SetValue(basalelement->nodes[i]->Sid(),1.,INS_VAL);
    687                                         }
    688                                 }
    689                         }
    690                 }
    691668                /*If mask was already one, keep one or colapse*/
    692                 else if(old_active[i]>0.){
     669                if(old_active[i]>0.){
    693670                        vec_mask->SetValue(basalelement->nodes[i]->Sid(),1.,INS_VAL);
    694671                        /* If epl thickness gets under colapse thickness, close the layer */
     
    697674                                recurence->SetValue(basalelement->nodes[i]->Sid(),1.,INS_VAL);
    698675                        }
    699                         /*If epl head gets under base elevation, close the layer*/
     676                        /* If epl head gets under base elevation, close the layer */
    700677                        /* else if(eplhead[i]<(base[i]-1.0e-8)){ */
    701678                        /*      vec_mask->SetValue(basalelement->nodes[i]->Sid(),0.,INS_VAL); */
    702679                        /*      recurence->SetValue(basalelement->nodes[i]->Sid(),1.,INS_VAL); */
    703                         /* }*/
    704                 }
     680                        /* } */
     681                }
     682                /*If node is now closed bring its thickness back to initial*/
     683                if (old_active[i]==0.){
     684                        epl_thickness[i]=init_thick;
     685                }
     686                /*Activate if we have a residual from sediment*/
     687                if(residual[i]>0.){
     688                        vec_mask->SetValue(basalelement->nodes[i]->Sid(),1.,INS_VAL);
     689                        if(old_active[i]==0.){
     690                                recurence->SetValue(basalelement->nodes[i]->Sid(),1.,INS_VAL);
     691                        }
     692                }
     693                /*Increase of the efficient system is needed if the epl head reach the maximum value (sediment max value for now)*/
     694                if(eplhead[i]>=h_max && active_element){
     695                        for(int j=0;j<numnodes;j++){
     696                                /*Increase of the domain is on the downstream node in term of sediment head*/
     697                                if((sedhead[j] == sedheadmin) && (i!=j)){
     698                                        vec_mask->SetValue(basalelement->nodes[j]->Sid(),1.,INS_VAL);
     699                                        if(old_active[j]==0.){
     700                                                recurence->SetValue(basalelement->nodes[j]->Sid(),1.,INS_VAL);
     701                                        }
     702                                }
     703                        }
     704                }
     705               
    705706        }
    706707        basalelement->AddInput(HydrologydcEplThicknessEnum,epl_thickness,basalelement->GetElementType());
     
    758759
    759760        water_sheet=max(0.0,(prestep_head-base_elev));
    760         //water_sheet=prestep_head-base_elev;
    761761       
    762         //epl_transmitivity=epl_conductivity*epl_thickness;
    763         epl_transmitivity=epl_conductivity*min(water_sheet,epl_thickness);
     762        epl_transmitivity=epl_conductivity*epl_thickness;
     763        /* epl_transmitivity=max(1.0e-6,(epl_conductivity*min(water_sheet,epl_thickness))); */
    764764        return epl_transmitivity;
    765765}/*}}}*/
  • issm/trunk-jpl/src/c/classes/FemModel.cpp

    r21484 r21488  
    27192719                }
    27202720        }
    2721 
    2722        
    27232721        this->parameters->SetParam(eplzigzag_counter,this->nodes->Size(),EplZigZagCounterEnum);
    27242722        /*Assemble and serialize*/
Note: See TracChangeset for help on using the changeset viewer.