Changeset 2965 for trunk/LMDZ.MARS/libf/phymars
- Timestamp:
- May 17, 2023, 12:31:18 PM (20 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.MARS/libf/phymars/physiq_mod.F
r2963 r2965 546 546 547 547 ! Variable for ice table 548 REAL :: rhowater_surf(ngrid,nslope) 549 REAL :: rhowater_surf_sat(ngrid,nslope) 550 REAL :: rhowater_soil(ngrid,nsoilmx,nslope) 551 REAL,PARAMETER :: alph_clap = -6143.7552 REAL,PARAMETER :: beta_clap = 28.9074553 REAL :: pvap_surf(ngrid) 554 REAL,PARAMETER :: m_co2 = 44.01E-3 ! CO2 molecular mass (kg/mol)555 REAL,PARAMETER :: m_noco2 = 33.37E-3 ! Non condensible mol mass (kg/mol)556 REAL :: ztmp1,ztmp2 548 REAL :: rhowater_surf(ngrid,nslope) ! Water density at the surface [kg/m^3] 549 REAL :: rhowater_surf_sat(ngrid,nslope) ! Water density at the surface at saturation [kg/m^3] 550 REAL :: rhowater_soil(ngrid,nsoilmx,nslope) ! Water density in soil layers [kg/m^3] 551 REAL,PARAMETER :: alpha_clap_h2o = 28.9074 ! Coeff for Clapeyron law [/] 552 REAL,PARAMETER :: beta_clap_h2o = -6143.7 ! Coeff for Clapeyron law [K] 553 REAL :: pvap_surf(ngrid) ! Water vapor partial pressure in first layer [Pa] 554 REAL,PARAMETER :: m_co2 = 44.01E-3 ! CO2 molecular mass [kg/mol] 555 REAL,PARAMETER :: m_noco2 = 33.37E-3 ! Non condensible mol mass [kg/mol] 556 REAL :: ztmp1,ztmp2 ! intermediate variables to compute the mean molar mass of the layer 557 557 558 558 c======================================================================= … … 3847 3847 3848 3848 DO islope = 1,nslope 3849 ! Clapeyron law for psat (psat = exp(beta/Th2o+alpha)),following Murphy and Koop 2005 3849 3850 rhowater_surf_sat(ig,islope) = 3850 & exp( alph_clap/tsurf(ig,islope)+beta_clap)3851 & exp(beta_clap_h2o/tsurf(ig,islope)+alpha_clap_h2o) 3851 3852 & / tsurf(ig,islope) 3853 & * mmol(igcm_h2o_vap)/(mugaz*r) 3852 3854 3853 3855 if(qsurf(ig,igcm_h2o_ice,islope).gt.(1.e-4)) then 3854 rhowater_surf(ig,islope) = 3855 & exp(alph_clap/tsurf(ig,islope)+beta_clap) 3856 & / tsurf(ig,islope) 3856 ! we consider to be at saturation above 1.e-4 kg.m-2 3857 rhowater_surf(ig,islope) = rhowater_surf_sat(ig,islope) 3857 3858 else 3859 ! otherwise, use vapor partial pressure 3858 3860 rhowater_surf(ig,islope) = pvap_surf(ig) 3859 3861 & / tsurf(ig,islope) 3862 & * mmol(igcm_h2o_vap)/(mugaz*r) 3860 3863 endif 3861 3864 DO isoil = 1,nsoilmx 3862 3865 rhowater_soil(ig,isoil,islope) = 3863 & exp( alph_clap/tsoil(ig,isoil,islope)+beta_clap)3866 & exp(beta_clap_h2o/tsoil(ig,isoil,islope)+alpha_clap_h2o) 3864 3867 & / tsoil(ig,isoil,islope) 3868 & * mmol(igcm_h2o_vap)/(mugaz*r) 3865 3869 ENDDO 3866 3870 ENDDO … … 3869 3873 DO islope = 1,nslope 3870 3874 write(str2(1:2),'(i2.2)') islope 3871 CALL send_xios_field("Waterdensity_soil_slope"//str2, 3875 CALL write_output("Waterdensity_soil_slope"//str2, 3876 & "rhowater_soil_slope"//str2,'kg.m-3', 3872 3877 & rhowater_soil(:,:,islope)) 3873 CALL send_xios_field("Waterdensity_surface"//str2, 3878 CALL write_output("Waterdensity_surface"//str2, 3879 & "rhowater_surface"//str2,'kg.m-3', 3874 3880 & rhowater_surf(:,islope)) 3875 3881 ENDDO 3876 3882 3877 CALL send_xios_field("h2o_layer1",zq(:,1,igcm_h2o_vap)) 3878 CALL send_xios_field("co2_layer1",zq(:,1,igcm_co2)) 3883 CALL write_output("h2o_layer1","h2o mass mr in the first layer", 3884 & 'kg/kg',zq(:,1,igcm_h2o_vap)) 3885 CALL write_output("co2_layer1","co2 mass mr in the first layer", 3886 & 'kg/kg',zq(:,1,igcm_co2)) 3879 3887 3880 3888 !PREVIOUSLY IN 1D ONLY
Note: See TracChangeset
for help on using the changeset viewer.