diff --git a/cime_config/testdefs/testmods_dirs/cam/outfrq_trcdata_bam_derecho/user_nl_cam b/cime_config/testdefs/testmods_dirs/cam/outfrq_trcdata_bam_derecho/user_nl_cam index 63698ed56..c45aa9428 100644 --- a/cime_config/testdefs/testmods_dirs/cam/outfrq_trcdata_bam_derecho/user_nl_cam +++ b/cime_config/testdefs/testmods_dirs/cam/outfrq_trcdata_bam_derecho/user_nl_cam @@ -1,17 +1,22 @@ ! these snapshots were constructed to specifically test whether the data read into the ! physics buffer by tracer_data in CAM will match the data read by CAM-SIMA bit-for-bit. ! this was done by -! (1) taking a FHIST_C4 snapshot (which has prescribed_ozone and aero) -! in this case a ne3pg3_fhistc4_gw_drag_cam4_oro snapshot, +! (1) taking a FHIST_C4 snapshot (which has prescribed_ozone, aero, aerodep_flx, and volcaero) +! using a "user_set" location at the beginning of tphysbc, before check_energy_fix +! this is because the prescribed data modules run during timestep_init; +! the energy fixer will change model state, causing changes in the interpolation, +! so the "before" snapshot before the global energy fixer needs to be used. ! (2) using nco to zero out the prescribed ozone and aero fields from the snapshot data, -! to create the "before" snapshot. -! (3) the "after" snapshot is the original snapshot file (which has non-zero values for prescribed -! ozone and aerosols) +! to create the "before" snapshot: +! ncap2 -O -s 'pbuf_ozone=0.0*pbuf_ozone' h1i_v2.nc 0xozone.nc +! ncap2 -O -s 'pbuf_sulf=0.0*pbuf_sulf;pbuf_bcar1=0.0*pbuf_sulf;pbuf_bcar2=0.0*pbuf_sulf;pbuf_ocar1=0.0*pbuf_sulf;pbuf_ocar2=0.0*pbuf_sulf;pbuf_sslt1=0.0*pbuf_sulf;pbuf_sslt2=0.0*pbuf_sulf;pbuf_sslt3=0.0*pbuf_sulf;pbuf_sslt4=0.0*pbuf_sulf;pbuf_dust1=0.0*pbuf_sulf;pbuf_dust2=0.0*pbuf_sulf;pbuf_dust3=0.0*pbuf_sulf;pbuf_dust4=0.0*pbuf_sulf;pbuf_VOLC_RAD_GEOM=0.0*pbuf_VOLC_RAD_GEOM;pbuf_VOLC_MMR=0.0*pbuf_VOLC_MMR' 0xozone.nc 0xozone_aero_volcaero.nc +! (3) the "after" snapshot is the original "before" snapshot file +! (which has non-zero values for prescribed ozone and aerosol) ! the test will pass iff. the tracer_data utility in CAM-SIMA and the prescribed_ozone/aerosols schemes ! can populate the prescribed fields bit-for-bit compared to the original snapshot file. -ncdata = '/glade/campaign/cesm/community/amwg/sima_baselines/cam_sima_test_snapshots/cam_ne3pg3_fhistc4_tracer_data_0xprescribed-ozone-aero_from_cam4_oro_snapshot_derecho_gnu_after_c20251028.nc' -ncdata_check = '/glade/campaign/cesm/community/amwg/sima_baselines/cam_sima_test_snapshots/cam_ne3pg3_fhistc4_gw_drag_cam4_oro_snapshot_derecho_gnu_after_c20250826.nc' +ncdata = '/glade/campaign/cesm/community/amwg/sima_baselines/cam_sima_test_snapshots/cam_ne3pg3_fhistc4_tracer_data_0xprescribed-ozone-aero-volcaero_from_energy_fixer_derecho_gnu_before_c20260312.nc' +ncdata_check = '/glade/campaign/cesm/community/amwg/sima_baselines/cam_sima_test_snapshots/cam_ne3pg3_fhistc4_tracer_data_0xprescribed-ozone-aero-volcaero_from_energy_fixer_derecho_gnu_after_c20260312.nc' ! tolerances for testing ncdata_check_err = .true. @@ -20,7 +25,7 @@ min_difference = 2e-15 ! cam4 vertical levels (FHIST_C4 snapshots) pver = 26 -prescribed_aero_datapath = "/glade/campaign/cesm/cesmdata/inputdata/atm/cam/chem/trop_mozart_aero/aero" +prescribed_aero_datapath = "${DIN_LOC_ROOT}/atm/cam/chem/trop_mozart_aero/aero" prescribed_aero_file = "aero_1.9x2.5_L26_1850-2005_c091112.nc" prescribed_aero_filelist = "aero_1.9x2.5_L26_list_c070514.txt" prescribed_aero_model = "bulk" @@ -30,14 +35,14 @@ prescribed_aero_cycle_yr = 0 prescribed_aero_fixed_tod = 0 prescribed_aero_fixed_ymd = 0 -aerodep_flx_datapath = '/glade/campaign/cesm/cesmdata/inputdata/atm/cam/chem/trop_mozart_aero/aero' +aerodep_flx_datapath = '${DIN_LOC_ROOT}/atm/cam/chem/trop_mozart_aero/aero' aerodep_flx_file = 'aerosoldep_monthly_1849-2006_1.9x2.5_c090803.nc' aerodep_flx_specifier = 'BCDEPWET', 'BCPHODRY', 'BCPHIDRY', 'OCDEPWET', 'OCPHODRY', 'OCPHIDRY', 'DSTX01DD', 'DSTX02DD', 'DSTX03DD', 'DSTX04DD', 'DSTX01WD', 'DSTX02WD', 'DSTX03WD', 'DSTX04WD' aerodep_flx_type = 'INTERP_MISSING_MONTHS' aerodep_flx_cycle_yr = 0 -prescribed_ozone_datapath = "/glade/campaign/cesm/cesmdata/inputdata/atm/cam/ozone" +prescribed_ozone_datapath = "${DIN_LOC_ROOT}/atm/cam/ozone" prescribed_ozone_file = "ozone_1.9x2.5_L26_1850-2005_c091112.nc" prescribed_ozone_filelist = "UNSET" prescribed_ozone_name = "O3" @@ -46,8 +51,12 @@ prescribed_ozone_fixed_tod = 0 prescribed_ozone_fixed_ymd = 0 prescribed_ozone_cycle_yr = 0 +prescribed_volcaero_datapath = "${DIN_LOC_ROOT}/atm/cam/volc" +prescribed_volcaero_file = "CCSM4_volcanic_1850-2008_prototype1.nc" + hist_output_frequency;h1: 1*nsteps hist_max_frames;h1: 1 hist_add_inst_fields;h1:ozone hist_add_inst_fields;h1:sulf_D,bcar1_D,bcar2_D,ocar1_D,ocar2_D,sslt1_D,sslt2_D,sslt3_D,sslt4_D,dust1_D,dust2_D,dust3_D,dust4_D +hist_add_inst_fields;h1:VOLC_MMR,VOLC_RAD_GEOM,VOLC_MASS,VOLC_MASS_C hist_precision;h1: REAL64 diff --git a/src/data/physconst.F90 b/src/data/physconst.F90 index c73989dca..e560b1c87 100644 --- a/src/data/physconst.F90 +++ b/src/data/physconst.F90 @@ -46,7 +46,7 @@ module physconst !! \htmlinclude physconst.html ! Constants based off share code or defined in physconst real(kind_phys), public, parameter :: avogad = real(shr_const_avogad, kind_phys) ! Avogadro's number (molecules kmole-1) - real(kind_phys), public, parameter :: boltz = real(shr_const_boltz, kind_phys) ! Boltzman's constant (J K-1 molecule-1) + real(kind_phys), public, parameter :: boltz = real(shr_const_boltz, kind_phys) ! Boltzmann's constant (J K-1) real(kind_phys), public, parameter :: cday = real(shr_const_cday, kind_phys) ! sec in calendar day (seconds) real(kind_phys), public, parameter :: cpliq = real(shr_const_cpfw, kind_phys) ! specific heat of fresh h2o (J K-1 kg-1) real(kind_phys), public, parameter :: cpice = real(shr_const_cpice, kind_phys) ! specific heat of ice (J K-1 kg-1) diff --git a/src/data/physconst.meta b/src/data/physconst.meta index 72b6c8237..3f1c00839 100644 --- a/src/data/physconst.meta +++ b/src/data/physconst.meta @@ -7,7 +7,7 @@ [ avogad ] standard_name = avogadro_number long_name = Avogadro's Number - units = molecules mole-1 + units = molecules kmol-1 type = real | kind = kind_phys dimensions = () protected = True diff --git a/src/data/registry.xml b/src/data/registry.xml index 83ba849e0..25573d5e4 100644 --- a/src/data/registry.xml +++ b/src/data/registry.xml @@ -1707,6 +1707,20 @@ dust4 pbuf_dust4 cnst_dust4 + + + horizontal_dimension vertical_layer_dimension + VOLC_MMR pbuf_VOLC_MMR + + + horizontal_dimension vertical_layer_dimension + VOLC_RAD_GEOM pbuf_VOLC_RAD_GEOM + +