From 038dc0f399786115b9261b4e3291b2437fc3e0b9 Mon Sep 17 00:00:00 2001 From: Rich Fiorella Date: Mon, 15 Apr 2024 12:22:36 -0600 Subject: [PATCH] Add excess ground ice as a column variable Adds excess ground ice to the col_ws / column water state data structure as a varaible needed for NGEE-Arctic Phase 3 IM1 (improved inundation fraction). Not yet connected to any of the new polygonal ground subtypes of the vegetated columns. --- .../elm/src/data_types/ColumnDataType.F90 | 158 ++++++++++-------- components/elm/src/main/surfrdMod.F90 | 2 +- 2 files changed, 86 insertions(+), 74 deletions(-) diff --git a/components/elm/src/data_types/ColumnDataType.F90 b/components/elm/src/data_types/ColumnDataType.F90 index 32ebf37af051..66f167fbb4c0 100644 --- a/components/elm/src/data_types/ColumnDataType.F90 +++ b/components/elm/src/data_types/ColumnDataType.F90 @@ -47,7 +47,7 @@ module ColumnDataType use CNDecompCascadeConType , only : decomp_cascade_con use ColumnType , only : col_pp use LandunitType , only : lun_pp - use timeInfoMod , only : nstep_mod + use timeInfoMod , only : nstep_mod ! ! !PUBLIC TYPES: implicit none @@ -142,7 +142,8 @@ module ColumnDataType real(r8), pointer :: snow_persistence (:) => null() ! length of time that ground has had non-zero snow thickness (sec) real(r8), pointer :: snw_rds_top (:) => null() ! snow grain radius (top layer) (m^-6, microns) logical , pointer :: do_capsnow (:) => null() ! true => do snow capping - real(r8), pointer :: h2osoi_tend_tsl_col(:) => null() ! col moisture tendency due to vertical movement at topmost layer (m3/m3/s) + real(r8), pointer :: h2osoi_tend_tsl_col(:) => null() ! col moisture tendency due to vertical movement at topmost layer (m3/m3/s) + real(r8), pointer :: excess_ice (:) => null() ! NGEE-Arctic: tracking excess ground ice ! Area fractions real(r8), pointer :: frac_sno (:) => null() ! fraction of ground covered by snow (0 to 1) real(r8), pointer :: frac_sno_eff (:) => null() ! fraction of ground covered by snow (0 to 1) @@ -559,7 +560,7 @@ module ColumnDataType real(r8), pointer :: phr_vr (:,:) => null() ! potential hr (not N-limited) (gC/m3/s) real(r8), pointer :: fphr (:,:) => null() ! fraction of potential heterotrophic respiration real(r8), pointer :: som_c_leached (:) => null() ! total SOM C loss from vertical transport (gC/m^2/s) - real(r8), pointer :: som_c_runoff (:) => null() + real(r8), pointer :: som_c_runoff (:) => null() ! phenology: litterfall and crop fluxes real(r8), pointer :: phenology_c_to_litr_met_c (:,:) => null() ! C fluxes associated with phenology (litterfall and crop) to litter metabolic pool (gC/m3/s) real(r8), pointer :: phenology_c_to_litr_cel_c (:,:) => null() ! C fluxes associated with phenology (litterfall and crop) to litter cellulose pool (gC/m3/s) @@ -775,10 +776,10 @@ module ColumnDataType ! leaching fluxes real(r8), pointer :: smin_no3_leached_vr (:,:) => null() ! vertically-resolved soil mineral NO3 loss to leaching (gN/m3/s) real(r8), pointer :: smin_no3_leached (:) => null() ! soil mineral NO3 pool loss to leaching (gN/m2/s) - real(r8), pointer :: smin_nh4_leached (:) => null() + real(r8), pointer :: smin_nh4_leached (:) => null() real(r8), pointer :: smin_no3_runoff_vr (:,:) => null() ! vertically-resolved rate of mineral NO3 loss with runoff (gN/m3/s) real(r8), pointer :: smin_no3_runoff (:) => null() ! soil mineral NO3 pool loss to runoff (gN/m2/s) - real(r8), pointer :: smin_nh4_runoff (:) => null() + real(r8), pointer :: smin_nh4_runoff (:) => null() real(r8), pointer :: nh3_soi_flx (:) => null() ! nitrification /denitrification diagnostic quantities real(r8), pointer :: smin_no3_massdens_vr (:,:) => null() ! (ugN / g soil) soil nitrate concentration @@ -875,7 +876,7 @@ module ColumnDataType real(r8), pointer :: nh3_stores (:) => null() ! NH3 emission from manure storage, (gN/m2/s) real(r8), pointer :: nh3_grz (:) => null() ! NH3 emission from manure on pastures, (gN/m2/s) real(r8), pointer :: nh3_manure_app (:) => null() ! NH3 emission from manure applied on crops and grasslands, (gN/m - real(r8), pointer :: nh3_fert (:) => null() ! NH3 emission from fertilizers applied on crops and grasslands, + real(r8), pointer :: nh3_fert (:) => null() ! NH3 emission from fertilizers applied on crops and grasslands, real(r8), pointer :: nh3_otherfert (:) => null() ! NH3 emission from non-urea fertilizers applied on crops and gra real(r8), pointer :: nh3_total (:) => null() ! Total NH3 emission from agriculture real(r8), pointer :: manure_no3_to_soil (:) => null() ! Nitrification flux from manure (gN/m2/s) @@ -888,7 +889,7 @@ module ColumnDataType real(r8), pointer :: fan_totnin (:) => null() ! Total output N from FAN pools, gN/m2/s real(r8), pointer :: manure_n_to_sminn (:) => null() ! Manure N from FAN pools to soil mineral pools, gN/m2/s real(r8), pointer :: synthfert_n_to_sminn (:) => null() ! Fertilizer N from FAN pools to soil mineral pools, gN/m2/s - real(r8), pointer :: manure_n_total (:) => null() ! Total manure N produced, gN/m2/s + real(r8), pointer :: manure_n_total (:) => null() ! Total manure N produced, gN/m2/s contains procedure, public :: Init => col_nf_init @@ -941,7 +942,7 @@ module ColumnDataType real(r8), pointer :: actual_immob_p (:) => null() ! vert-int (diagnostic) actual P immobilization (gP/m2/s) real(r8), pointer :: sminp_to_plant_vr (:,:) => null() ! vertically-resolved plant uptake of soil mineral P (gP/m3/s) real(r8), pointer :: sminp_to_plant (:) => null() ! vert-int (diagnostic) plant uptake of soil mineral P (gP/m2/s) - real(r8), pointer :: net_mineralization_p_vr (:,:) => null() + real(r8), pointer :: net_mineralization_p_vr (:,:) => null() real(r8), pointer :: supplement_to_sminp_vr (:,:) =>null() ! vertically-resolved supplemental P supply (gP/m3/s) real(r8), pointer :: supplement_to_sminp (:) =>null() ! vert-int (diagnostic) supplemental P supply (gP/m2/s) real(r8), pointer :: gross_pmin_vr (:,:) =>null() ! vertically-resolved gross rate of P mineralization (gP/m3/s) @@ -1383,10 +1384,10 @@ subroutine col_ws_init(this, begc, endc, h2osno_input, snow_depth_input, watsat_ allocate(this%h2osoi_liq (begc:endc,-nlevsno+1:nlevgrnd)) ; this%h2osoi_liq (:,:) = spval allocate(this%h2osoi_ice (begc:endc,-nlevsno+1:nlevgrnd)) ; this%h2osoi_ice (:,:) = spval allocate(this%h2osoi_vol (begc:endc, 1:nlevgrnd)) ; this%h2osoi_vol (:,:) = spval - allocate(this%h2osfc (begc:endc)) ; this%h2osfc (:) = spval - allocate(this%h2ocan (begc:endc)) ; this%h2ocan (:) = spval + allocate(this%h2osfc (begc:endc)) ; this%h2osfc (:) = spval + allocate(this%h2ocan (begc:endc)) ; this%h2ocan (:) = spval allocate(this%wslake_col (begc:endc)) ; this%wslake_col (:) = spval - allocate(this%total_plant_stored_h2o(begc:endc)) ; this%total_plant_stored_h2o(:)= spval + allocate(this%total_plant_stored_h2o(begc:endc)) ; this%total_plant_stored_h2o(:)= spval allocate(this%h2osoi_liqvol (begc:endc,-nlevsno+1:nlevgrnd)) ; this%h2osoi_liqvol (:,:) = spval allocate(this%h2osoi_icevol (begc:endc,-nlevsno+1:nlevgrnd)) ; this%h2osoi_icevol (:,:) = spval allocate(this%h2osoi_liq_old (begc:endc,-nlevsno+1:nlevgrnd)) ; this%h2osoi_liq_old (:,:) = spval @@ -1416,6 +1417,7 @@ subroutine col_ws_init(this, begc, endc, h2osno_input, snow_depth_input, watsat_ if (use_fan) then allocate(this%h2osoi_tend_tsl_col(begc:endc)) ; this%h2osoi_tend_tsl_col(:) = spval end if + allocate(this%excess_ice (begc:endc)) ; this%excess_ice (:) = spval allocate(this%snw_rds_top (begc:endc)) ; this%snw_rds_top (:) = spval allocate(this%do_capsnow (begc:endc)) allocate(this%frac_sno (begc:endc)) ; this%frac_sno (:) = spval @@ -1562,7 +1564,12 @@ subroutine col_ws_init(this, begc, endc, h2osno_input, snow_depth_input, watsat_ ptr_col=this%h2osoi_tend_tsl_col, l2g_scale_type='veg', & default='inactive') end if - + + this%excess_ice(begc:endc) = spval + call hist_addfld1d (fname='EXCESS_ICE', units = 'kg/m2', & + avgflag='A', long_name='Excess ground ice', & + ptr_col=this$excess_ice, l2g_scale_type='veg') ! <- RPF: should this be natveg? + this%frac_sno(begc:endc) = spval call hist_addfld1d (fname='FSNO', units='1', & avgflag='A', long_name='fraction of ground covered by snow', & @@ -1584,9 +1591,9 @@ subroutine col_ws_init(this, begc, endc, h2osno_input, snow_depth_input, watsat_ call hist_addfld1d (fname='FH2OSFC', units='1', & avgflag='A', long_name='fraction of ground covered by surface water', & ptr_col=this%frac_h2osfc) - + this%frac_h2osfc_act(begc:endc) = spval - + if (use_cn) then this%wf(begc:endc) = spval call hist_addfld1d (fname='WF', units='proportion', & @@ -1819,12 +1826,12 @@ subroutine col_ws_restart(this, bounds, ncid, flag, watsat_input) this%h2osfc(bounds%begc:bounds%endc) = 0.0_r8 end if - if(do_budgets) then + if(do_budgets) then call restartvar(ncid=ncid, flag=flag, varname='ENDWB', xtype=ncd_double, & dim1name='column', & long_name='water balance at end of timestep', units='kg/m2', & interpinic_flag='interp', readvar=readvar, data=this%endwb) - end if + end if call restartvar(ncid=ncid, flag=flag, varname='H2OSOI_LIQ', xtype=ncd_double, & dim1name='column', dim2name='levtot', switchdim=.true., & @@ -1899,6 +1906,11 @@ subroutine col_ws_restart(this, bounds, ncid, flag, watsat_input) this%snow_persistence(:) = 0.0_r8 end if + call restartvar(ncid=ncid, flag=flag, varname='EXCESS_ICE', xtype=ncd_double, & + dim1name='column', & + long_name='excess ground ice', units='kg/m2', & + interpinic_flag='interp', readvar=readvar, data=this%excess_ice) + call restartvar(ncid=ncid, flag=flag, varname='frac_sno', xtype=ncd_double, & dim1name='column', & long_name='fraction of ground covered by snow (0 to 1)',units='1',& @@ -2055,8 +2067,8 @@ subroutine col_cs_init(this, begc, endc, carbon_type, ratio, c12_carbonstate_var allocate(this%totcolc (begc:endc)) ; this%totcolc (:) = spval allocate(this%totblgc (begc:endc)) ; this%totblgc (:) = spval allocate(this%totvegc_abg (begc:endc)) ; this%totvegc_abg (:) = spval - allocate(this%begcb (begc:endc)) ; this%begcb (:) = spval - allocate(this%endcb (begc:endc)) ; this%endcb (:) = spval + allocate(this%begcb (begc:endc)) ; this%begcb (:) = spval + allocate(this%endcb (begc:endc)) ; this%endcb (:) = spval allocate(this%errcb (begc:endc)) ; this%errcb (:) = spval allocate(this%totpftc_beg (begc:endc)) ; this%totpftc_beg (:) = spval allocate(this%cwdc_beg (begc:endc)) ; this%cwdc_beg (:) = spval @@ -2092,7 +2104,7 @@ subroutine col_cs_init(this, begc, endc, carbon_type, ratio, c12_carbonstate_var ! Do not define history variables for CWD when fates is active if( decomp_cascade_con%is_cwd(l) .and. use_fates ) cycle - + if ( nlevdecomp_full > 1 ) then data2dptr => this%decomp_cpools_vr(:,:,l) fieldname = trim(decomp_cascade_con%decomp_pool_name_history(l))//'C_vr' @@ -3267,18 +3279,18 @@ subroutine col_ns_init(this, begc, endc, col_cs) allocate(this%tan_f1 (begc:endc)) ; this%tan_f1 (:) = spval allocate(this%tan_f2 (begc:endc)) ; this%tan_f2 (:) = spval allocate(this%tan_f3 (begc:endc)) ; this%tan_f3 (:) = spval - allocate(this%tan_f4 (begc:endc)) ; this%tan_f4 (:) = spval - allocate(this%fert_u1 (begc:endc)) ; this%fert_u1 (:) = spval - allocate(this%fert_u2 (begc:endc)) ; this%fert_u2 (:) = spval - allocate(this%manure_u_grz (begc:endc)) ; this%manure_u_grz (:) = spval - allocate(this%manure_a_grz (begc:endc)) ; this%manure_a_grz (:) = spval - allocate(this%manure_r_grz (begc:endc)) ; this%manure_r_grz (:) = spval - allocate(this%manure_u_app (begc:endc)) ; this%manure_u_app (:) = spval - allocate(this%manure_a_app (begc:endc)) ; this%manure_a_app (:) = spval - allocate(this%manure_r_app (begc:endc)) ; this%manure_r_app (:) = spval - allocate(this%manure_n_stored (begc:endc)) ; this%manure_n_stored (:) = spval - allocate(this%manure_tan_stored (begc:endc)) ; this%manure_tan_stored (:) = spval - allocate(this%fan_grz_fract (begc:endc)) ; this%fan_grz_fract (:) = spval + allocate(this%tan_f4 (begc:endc)) ; this%tan_f4 (:) = spval + allocate(this%fert_u1 (begc:endc)) ; this%fert_u1 (:) = spval + allocate(this%fert_u2 (begc:endc)) ; this%fert_u2 (:) = spval + allocate(this%manure_u_grz (begc:endc)) ; this%manure_u_grz (:) = spval + allocate(this%manure_a_grz (begc:endc)) ; this%manure_a_grz (:) = spval + allocate(this%manure_r_grz (begc:endc)) ; this%manure_r_grz (:) = spval + allocate(this%manure_u_app (begc:endc)) ; this%manure_u_app (:) = spval + allocate(this%manure_a_app (begc:endc)) ; this%manure_a_app (:) = spval + allocate(this%manure_r_app (begc:endc)) ; this%manure_r_app (:) = spval + allocate(this%manure_n_stored (begc:endc)) ; this%manure_n_stored (:) = spval + allocate(this%manure_tan_stored (begc:endc)) ; this%manure_tan_stored (:) = spval + allocate(this%fan_grz_fract (begc:endc)) ; this%fan_grz_fract (:) = spval end if allocate(this%fan_totn (begc:endc)) ; this%fan_totn (:) = spval allocate(this%totpftn_beg (begc:endc)) ; this%totpftn_beg (:) = spval @@ -3316,7 +3328,7 @@ subroutine col_ns_init(this, begc, endc, col_cs) do l = 1, ndecomp_pools if( decomp_cascade_con%is_cwd(l) .and. use_fates ) cycle - + if ( nlevdecomp_full > 1 ) then data2dptr => this%decomp_npools_vr(:,:,l) fieldname = trim(decomp_cascade_con%decomp_pool_name_history(l))//'N_vr' @@ -5092,7 +5104,7 @@ subroutine col_ps_restart ( this, bounds, ncid, flag, cnstate_vars) ! assume soil below 50 cm has the same p pool concentration ! divide 0.5m when convert p pools from g/m2 to g/m3 ! assume p pools evenly distributed at dif layers - if (nu_com .eq. 'RD') then + if (nu_com .eq. 'RD') then smax_c = smax(isoilorder(c)) ks_sorption_c = ks_sorption(isoilorder(c)) this%solutionp_vr(c,j) = (cnstate_vars%labp_col(c)/0.5_r8*ks_sorption_c)/& @@ -6149,12 +6161,12 @@ subroutine col_cf_init(this, begc, endc, carbon_type) call hist_addfld1d (fname='NEP', units='gC/m^2/s', & avgflag='A', long_name='net ecosystem production, excludes fire, landuse, and harvest flux, positive for sink', & ptr_col=this%nep) - + this%nbp(begc:endc) = spval call hist_addfld1d (fname='NBP', units='gC/m^2/s', & avgflag='A', long_name='net biome production, includes fire, landuse, and harvest flux, positive for sink', & ptr_col=this%nbp) - + this%nee(begc:endc) = spval call hist_addfld1d (fname='NEE', units='gC/m^2/s', & avgflag='A', long_name='net ecosystem exchange of carbon, includes fire, landuse,'& @@ -6177,13 +6189,13 @@ subroutine col_cf_init(this, begc, endc, carbon_type) call hist_addfld1d (fname='CWDC_HR', units='gC/m^2/s', & avgflag='A', long_name='coarse woody debris C heterotrophic respiration', & ptr_col=this%cwdc_hr) - + this%cwdc_loss(begc:endc) = spval call hist_addfld1d (fname='CWDC_LOSS', units='gC/m^2/s', & avgflag='A', long_name='coarse woody debris C loss', & ptr_col=this%cwdc_loss) end if - + this%lithr(begc:endc) = spval call hist_addfld1d (fname='LITTERC_HR', units='gC/m^2/s', & avgflag='A', long_name='litter C heterotrophic respiration', & @@ -6585,20 +6597,20 @@ subroutine col_cf_init(this, begc, endc, carbon_type) avgflag='A', long_name='annual sum of column-level NPP', & ptr_col=this%annsum_npp, default='inactive') - if(.not.use_fates)then + if(.not.use_fates)then ! C4MIP output variable, plant carbon flux to cwd (a part of fVegLitter) this%plant_c_to_cwdc(begc:endc) = spval call hist_addfld1d (fname='VEGC_TO_CWDC', units='gC/m^2/s', & avgflag='A', long_name='plant carbon flux to cwd', & ptr_col=this%plant_c_to_cwdc, default='inactive') - + ! C4MIP output variable, plant phosphorus flux to cwd (a part of fVegLitter) this%plant_p_to_cwdp(begc:endc) = spval call hist_addfld1d (fname='VEGP_TO_CWDP', units='gP/m^2/s', & avgflag='A', long_name='plant phosphorus flux to cwd', & ptr_col=this%plant_p_to_cwdp, default='inactive') end if - + ! end of C12 block else if ( carbon_type == 'c13' ) then @@ -7712,7 +7724,7 @@ subroutine col_cf_setvalues ( this, num_column, filter_column, value_column) this%f_co2_soil_vr(i,j) = value_column end do end do - + do k = 1, ndecomp_pools do j = 1, nlevdecomp_full do fi = 1,num_column @@ -7722,7 +7734,7 @@ subroutine col_cf_setvalues ( this, num_column, filter_column, value_column) end do end do ! pflotran - if(nstep_mod == 0 .or. is_first_restart_step()) then + if(nstep_mod == 0 .or. is_first_restart_step()) then do k = 1, ndecomp_pools do j = 1, nlevdecomp_full do fi = 1,num_column @@ -7736,7 +7748,7 @@ subroutine col_cf_setvalues ( this, num_column, filter_column, value_column) this%f_co2_soil(i) = value_column this%externalc_to_decomp_delta(i) = value_column end do - end if + end if do k = 1, ndecomp_pools do fi = 1,num_column @@ -7744,7 +7756,7 @@ subroutine col_cf_setvalues ( this, num_column, filter_column, value_column) this%decomp_cpools_yield(i,k) = value_column !if ero_ccycle this%m_decomp_cpools_to_fire(i,k) = value_column end do - end do + end do do fi = 1,num_column i = filter_column(fi) @@ -7762,7 +7774,7 @@ subroutine col_cf_setvalues ( this, num_column, filter_column, value_column) this%coutputs(i) = value_column this%cwdc_hr(i) = value_column this%litterc_loss(i) = value_column - + this%nee(i) = value_column ! Zero p2c column fluxes @@ -7776,8 +7788,8 @@ subroutine col_cf_setvalues ( this, num_column, filter_column, value_column) this%wood_harvestc(i) = value_column this%hrv_xsmrpool_to_atm(i) = value_column end do - - if(use_crop) then + + if(use_crop) then do fi = 1,num_column i = filter_column(fi) this%somc_fire(i) = value_column @@ -7795,16 +7807,16 @@ subroutine col_cf_setvalues ( this, num_column, filter_column, value_column) this%somc_erode(i) = value_column this%somc_deposit(i) = value_column this%somc_yield(i) = value_column - enddo - end if + enddo + end if do k = 1, ndecomp_pools do fi = 1,num_column i = filter_column(fi) this%decomp_cpools_leached(i,k) = value_column this%decomp_cpools_erode(i,k) = value_column this%decomp_cpools_deposit(i,k) = value_column - end do - end do + end do + end do do k = 1, ndecomp_pools do j = 1, nlevdecomp_full do fi = 1,num_column @@ -7847,7 +7859,7 @@ subroutine col_cf_zero_forfates_veg(this, bounds, num_soilc, filter_soilc) this%hrv_xsmrpool_to_atm(c) = 0._r8 end do - + do k = 1, ndecomp_pools do j = 1, nlevdecomp_full do fc = 1,num_soilc @@ -8276,7 +8288,7 @@ subroutine col_nf_init(this, begc, endc) allocate(this%actual_immob_no3 (begc:endc)) ; this%actual_immob_no3 (:) = spval allocate(this%actual_immob_nh4 (begc:endc)) ; this%actual_immob_nh4 (:) = spval allocate(this%smin_no3_to_plant (begc:endc)) ; this%smin_no3_to_plant (:) = spval - allocate(this%smin_nh4_to_plant (begc:endc)) ; this%smin_nh4_to_plant (:) = spval + allocate(this%smin_nh4_to_plant (begc:endc)) ; this%smin_nh4_to_plant (:) = spval allocate(this%plant_to_litter_nflux (begc:endc)) ; this%plant_to_litter_nflux (:) = 0._r8 allocate(this%plant_to_cwd_nflux (begc:endc)) ; this%plant_to_cwd_nflux (:) = spval ! C4MIP output variable @@ -8334,7 +8346,7 @@ subroutine col_nf_init(this, begc, endc) allocate(this%fan_totnin (begc:endc)) ; this%fan_totnin (:) = spval allocate(this%fan_totnout (begc:endc)) ; this%fan_totnout (:) = spval end if - + !----------------------------------------------------------------------- ! initialize history fields for select members of col_nf !----------------------------------------------------------------------- @@ -8362,13 +8374,13 @@ subroutine col_nf_init(this, begc, endc) ptr_col=this%nfix_to_sminn) ! C4MIP output variable, plant nitrogen flux to cwd (a part of fVegLitter) - if(.not.use_fates)then + if(.not.use_fates)then this%plant_n_to_cwdn(begc:endc) = spval call hist_addfld1d (fname='VEGN_TO_CWDN', units='gN/m^2/s', & avgflag='A', long_name='plant nitrogen flux to cwd', & ptr_col=this%plant_n_to_cwdn, default='inactive') end if - + do k = 1, ndecomp_pools if ( decomp_cascade_con%is_litter(k) .or. decomp_cascade_con%is_cwd(k) ) then this%m_decomp_npools_to_fire(begc:endc,k) = spval @@ -9331,7 +9343,7 @@ subroutine col_nf_setvalues ( this, num_column, filter_column, value_column) end do end do - if( use_pflotran .and. pf_cmode) then + if( use_pflotran .and. pf_cmode) then do j = 1, nlevdecomp_full do fi = 1,num_column @@ -9339,13 +9351,13 @@ subroutine col_nf_setvalues ( this, num_column, filter_column, value_column) ! pflotran this%plant_ndemand_vr(i,j) = value_column !use_elm_interface.and.use_pflotran .and. pf_cmode this%f_ngas_decomp_vr(i,j) = value_column ! "" - this%f_ngas_nitri_vr(i,j) = value_column ! "" + this%f_ngas_nitri_vr(i,j) = value_column ! "" this%f_ngas_denit_vr(i,j) = value_column this%f_n2o_soil_vr(i,j) = value_column this%f_n2_soil_vr(i,j) = value_column - end do - end do - end if + end do + end do + end if do fi = 1,num_column i = filter_column(fi) @@ -9361,7 +9373,7 @@ subroutine col_nf_setvalues ( this, num_column, filter_column, value_column) this%smin_no3_to_plant(i) = value_column this%fire_nloss(i) = value_column this%som_n_leached(i) = value_column - + this%hrv_deadstemn_to_prod10n(i) = value_column this%hrv_deadstemn_to_prod100n(i) = value_column this%hrv_cropn_to_prod1n(i) = value_column @@ -9466,7 +9478,7 @@ subroutine col_nf_setvalues ( this, num_column, filter_column, value_column) ! pflotran !------------------------------------------------------------------------ - if(nstep_mod == 0 .or. is_first_restart_step()) then + if(nstep_mod == 0 .or. is_first_restart_step()) then do k = 1, ndecomp_pools do j = 1, nlevdecomp_full do fi = 1,num_column @@ -9494,7 +9506,7 @@ subroutine col_nf_setvalues ( this, num_column, filter_column, value_column) this%nh4_net_transport_vr(i,j) = value_column end do end do - + do fi = 1,num_column i = filter_column(fi) ! only initializing in the first time-step @@ -9502,15 +9514,15 @@ subroutine col_nf_setvalues ( this, num_column, filter_column, value_column) end do end if - if(use_crop) then + if(use_crop) then do j = 1, nlevdecomp_full do fi = 1,num_column i = filter_column(fi) this%f_nit_vr(i,j) = value_column this%f_denit_vr(i,j) = value_column end do - end do - end if + end do + end if end subroutine col_nf_setvalues !----------------------------------------------------------------------- @@ -10904,7 +10916,7 @@ subroutine col_pf_setvalues ( this, num_column, filter_column, value_column) this%plant_pdemand_vr(i,j) = value_column this%adsorb_to_labilep_vr(i,j) = value_column this%desorb_to_solutionp_vr(i,j) = value_column - + end do end do @@ -10995,7 +11007,7 @@ subroutine col_pf_setvalues ( this, num_column, filter_column, value_column) end do end do end do - + do k = 1, ndecomp_pools do j = 1, nlevdecomp_full do fi = 1,num_column @@ -11008,7 +11020,7 @@ subroutine col_pf_setvalues ( this, num_column, filter_column, value_column) end do ! pflotran - if(nstep_mod == 0 .or. is_first_restart_step() ) then + if(nstep_mod == 0 .or. is_first_restart_step() ) then do k = 1, ndecomp_pools do j = 1, nlevdecomp_full do fi = 1,num_column @@ -11030,7 +11042,7 @@ subroutine col_pf_setvalues ( this, num_column, filter_column, value_column) this%externalp_to_decomp_delta(i) = value_column this%sminp_net_transport_delta(i) = value_column end do - end if + end if end subroutine col_pf_setvalues @@ -11211,7 +11223,7 @@ subroutine col_pf_summary(this, bounds, num_soilc, filter_soilc) end if ! vertically integrate column-level fire P losses - if(.not. use_fates) then + if(.not. use_fates) then do k = 1, ndecomp_pools do j = 1, nlevdecomp do fc = 1,num_soilc @@ -11222,7 +11234,7 @@ subroutine col_pf_summary(this, bounds, num_soilc, filter_soilc) end do end do end do - end if + end if ! vertically integrate column-level P erosion flux if (ero_ccycle) then diff --git a/components/elm/src/main/surfrdMod.F90 b/components/elm/src/main/surfrdMod.F90 index 9cbcd4b2b8e0..e35f8320b30c 100755 --- a/components/elm/src/main/surfrdMod.F90 +++ b/components/elm/src/main/surfrdMod.F90 @@ -35,7 +35,7 @@ module surfrdMod ! ! !PUBLIC MEMBER FUNCTIONS: public :: surfrd_get_globmask ! Reads global land mask (needed for setting domain decomp) - public :: surfrd_get_grid ! Read grid/ladnfrac data into domain (after domain decomp) + public :: surfrd_get_grid ! Read grid/landfrac data into domain (after domain decomp) public :: surfrd_get_topo ! Read grid topography into domain (after domain decomp) public :: surfrd_get_data ! Read surface dataset and determine subgrid weights public :: surfrd_get_grid_conn ! Reads grid connectivity information from domain file