Ignore:
Timestamp:
03/01/18 14:48:25 (7 years ago)
Author:
youngmc3
Message:

CHG: updated crevasse-depth calving law

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/c/classes/Elements/Tria.cpp

    r22473 r22488  
    302302        IssmDouble  calvingrate[NUMVERTICES];
    303303        IssmDouble  vx,vy,vel;
    304         IssmDouble  rheology_B,critical_fraction,water_height;
    305         IssmDouble  bathymetry,Ho,thickness,float_depth,groundedice;
     304        IssmDouble  critical_fraction,water_height;
     305        IssmDouble  bed,Ho,thickness,float_depth;
    306306        IssmDouble  surface_crevasse[NUMVERTICES], basal_crevasse[NUMVERTICES], crevasse_depth[NUMVERTICES], H_surf, H_surfbasal;
    307307        IssmDouble  strainparallel, straineffective;
    308         IssmDouble  yts;
     308        IssmDouble  s_xx,s_xy,s_yy,s1,s2,stmp;
    309309
    310310        /* Get node coordinates and dof list: */
     
    313313        /*Get the critical fraction of thickness surface and basal crevasses penetrate for calving onset*/
    314314        this->parameters->FindParam(&critical_fraction,CalvingCrevasseDepthEnum);
    315         this->parameters->FindParam(&yts,ConstantsYtsEnum);
    316315               
    317316        IssmDouble rho_ice        = this->GetMaterialParameter(MaterialsRhoIceEnum);
     
    321320        IssmDouble rheology_n     = this->GetMaterialParameter(MaterialsRheologyNEnum);
    322321
    323         Input*   B_input       = inputs->GetInput(MaterialsRheologyBbarEnum);   _assert_(B_input);
    324         Input*   H_input       = inputs->GetInput(ThicknessEnum); _assert_(H_input);
    325         Input*   bed           = inputs->GetInput(BedEnum); _assert_(bed);
    326         Input*   surface       = inputs->GetInput(SurfaceEnum); _assert_(surface);
    327         Input*  strainrateparallel  = inputs->GetInput(StrainRateparallelEnum);  _assert_(strainrateparallel);
    328         Input*  strainrateeffective = inputs->GetInput(StrainRateeffectiveEnum); _assert_(strainrateeffective);
    329         Input*  vx_input = inputs->GetInput(VxEnum); _assert_(vx_input);
    330         Input*  vy_input = inputs->GetInput(VxEnum); _assert_(vy_input);
    331         Input*  gr_input = inputs->GetInput(MaskGroundediceLevelsetEnum); _assert_(gr_input);
    332         Input*   waterheight_input = inputs->GetInput(WaterheightEnum); _assert_(waterheight_input);
    333 
     322        Input*   H_input                 = inputs->GetInput(ThicknessEnum); _assert_(H_input);
     323        Input*   bed_input               = inputs->GetInput(BedEnum); _assert_(bed_input);
     324        Input*   surface_input           = inputs->GetInput(SurfaceEnum); _assert_(surface_input);
     325        Input*  strainrateparallel_input  = inputs->GetInput(StrainRateparallelEnum);  _assert_(strainrateparallel_input);
     326        Input*  strainrateeffective_input = inputs->GetInput(StrainRateeffectiveEnum); _assert_(strainrateeffective_input);
     327        Input*  vx_input                  = inputs->GetInput(VxEnum); _assert_(vx_input);
     328        Input*  vy_input                  = inputs->GetInput(VxEnum); _assert_(vy_input);
     329        Input*   waterheight_input       = inputs->GetInput(WaterheightEnum); _assert_(waterheight_input);
     330        Input*   s_xx_input              = inputs->GetInput(DeviatoricStressxxEnum);     _assert_(s_xx_input);
     331        Input*   s_xy_input              = inputs->GetInput(DeviatoricStressxyEnum);     _assert_(s_xy_input);
     332        Input*   s_yy_input              = inputs->GetInput(DeviatoricStressyyEnum);     _assert_(s_yy_input);
     333       
    334334        /*Loop over all elements of this partition*/
    335335        GaussTria* gauss=new GaussTria();
     
    337337                gauss->GaussVertex(iv);
    338338       
    339                 B_input->GetInputValue(&rheology_B,gauss);
    340339                H_input->GetInputValue(&thickness,gauss);
    341                 bed->GetInputValue(&bathymetry,gauss);
    342                 surface->GetInputValue(&float_depth,gauss);
    343                 strainrateparallel->GetInputValue(&strainparallel,gauss);
    344                 strainrateeffective->GetInputValue(&straineffective,gauss);
     340                bed_input->GetInputValue(&bed,gauss);
     341                surface_input->GetInputValue(&float_depth,gauss);
     342                strainrateparallel_input->GetInputValue(&strainparallel,gauss);
     343                strainrateeffective_input->GetInputValue(&straineffective,gauss);
    345344                vx_input->GetInputValue(&vx,gauss);
    346345                vy_input->GetInputValue(&vy,gauss);
    347                 gr_input->GetInputValue(&groundedice,gauss);
    348346                waterheight_input->GetInputValue(&water_height,gauss);
     347                s_xx_input->GetInputValue(&s_xx,gauss);
     348                s_xy_input->GetInputValue(&s_xy,gauss);
     349                s_yy_input->GetInputValue(&s_yy,gauss);
     350               
    349351                vel=sqrt(vx*vx+vy*vy)+1.e-14;
    350352
    351                 Ho = thickness - (rho_seawater/rho_ice) * (-bathymetry);
     353                s1=(s_xx+s_yy)/2.+sqrt(pow((s_xx-s_yy)/2.,2)+pow(s_xy,2));
     354                s2=(s_xx+s_yy)/2.-sqrt(pow((s_xx-s_yy)/2.,2)+pow(s_xy,2));
     355                if(fabs(s2)>fabs(s1)){stmp=s2; s2=s1; s1=stmp;}
     356               
     357                Ho = thickness - (rho_seawater/rho_ice) * (-bed);
    352358                if(Ho<0.)  Ho=0.;
    353359
    354360                /*Otero2010: balance between the tensile deviatoric stress and ice overburden pressure*/
    355361                /*surface crevasse*/
    356                 surface_crevasse[iv] = rheology_B * strainparallel * pow(straineffective, ((1 / rheology_n)-1)) / (rho_ice * constant_g);
    357                 //surface_crevasse[iv] = 2 * rheology_B * pow(max(strainparallel,0.),(1/rheology_n)) / (rho_ice * constant_g);
     362                //surface_crevasse[iv] = rheology_B * strainparallel * pow(straineffective, ((1 / rheology_n)-1)) / (rho_ice * constant_g);
     363                surface_crevasse[iv] = s1 / (rho_ice*constant_g);
    358364                if (surface_crevasse[iv]<0.) {
    359365                        surface_crevasse[iv]=0.;
    360366                        water_height = 0.;
    361367                }
    362                 if (surface_crevasse[iv]<water_height){
    363                         water_height = surface_crevasse[iv];
    364                 }
     368                //if (surface_crevasse[iv]<water_height){
     369                //      water_height = surface_crevasse[iv];
     370                //}
    365371               
    366372                /*basal crevasse*/
    367                 basal_crevasse[iv] = (rho_ice/(rho_seawater-rho_ice)) * (rheology_B * strainparallel * pow(straineffective,((1/rheology_n)-1)) / (rho_ice*constant_g) - Ho);
    368                 //basal_crevasse[iv] = (rho_ice/(rho_seawater-rho_ice)) * (2 * rheology_B * pow(max(strainparallel,0.),(1/rheology_n)) / (rho_ice*constant_g) - Ho);
     373                //basal_crevasse[iv] = (rho_ice/(rho_seawater-rho_ice)) * (rheology_B * strainparallel * pow(straineffective,((1/rheology_n)-1)) / (rho_ice*constant_g) - Ho);
     374                basal_crevasse[iv] = (rho_ice/(rho_seawater-rho_ice))* (s1/ (rho_ice*constant_g)-Ho);
    369375                if (basal_crevasse[iv]<0.) basal_crevasse[iv]=0.;
    370                 if (bathymetry>0.) basal_crevasse[iv] = 0.;
     376                if (bed>0.) basal_crevasse[iv] = 0.;
    371377       
    372378                H_surf = surface_crevasse[iv] + (rho_freshwater/rho_ice)*water_height - critical_fraction*float_depth;
     
    374380               
    375381                crevasse_depth[iv] = max(H_surf,H_surfbasal);
     382        }
    376383       
    377                 /*Assign values */
    378                 if(crevasse_depth[iv]>=0. && bathymetry<=0.){
    379                  calvingrate[iv] = vel+3000./yts;
    380                 }       
    381                 else
    382                  calvingrate[iv]=0.;
    383         }
    384 
    385384        this->inputs->AddInput(new TriaInput(SurfaceCrevasseEnum,&surface_crevasse[0],P1Enum));
    386385        this->inputs->AddInput(new TriaInput(BasalCrevasseEnum,&basal_crevasse[0],P1Enum));
    387386        this->inputs->AddInput(new TriaInput(CrevasseDepthEnum,&crevasse_depth[0],P1Enum));
    388         this->inputs->AddInput(new TriaInput(CalvingCalvingrateEnum,&calvingrate[0],P1Enum));
    389387
    390388        delete gauss;
Note: See TracChangeset for help on using the changeset viewer.