Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move sw_redist, sw_frac, sw_dtemp from thermo to shortwave namelist #540

Merged
merged 4 commits into from
Dec 11, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
177 changes: 91 additions & 86 deletions cicecore/cicedynB/general/ice_init.F90
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ subroutine input_data

use ice_broadcast, only: broadcast_scalar, broadcast_array
use ice_diagnostics, only: diag_file, print_global, print_points, latpnt, lonpnt
use ice_domain, only: close_boundaries, ns_boundary_type, orca_halogrid
use ice_domain, only: close_boundaries, orca_halogrid
use ice_domain_size, only: ncat, nilyr, nslyr, nblyr, nfsd, nfreq, &
n_iso, n_aero, n_zaero, n_algae, &
n_doc, n_dic, n_don, n_fed, n_fep, &
Expand Down Expand Up @@ -190,7 +190,6 @@ subroutine input_data
kitd, ktherm, conduct, ksno, &
a_rapid_mode, Rac_rapid_mode, aspect_rapid_mode, &
dSdt_slow_mode, phi_c_slow_mode, phi_i_mushy, &
sw_redist, sw_frac, sw_dtemp, &
floediam, hfrazilmin

namelist /dynamics_nml/ &
Expand All @@ -213,6 +212,7 @@ subroutine input_data
shortwave, albedo_type, &
albicev, albicei, albsnowv, albsnowi, &
ahmax, R_ice, R_pnd, R_snw, &
sw_redist, sw_frac, sw_dtemp, &
dT_mlt, rsnw_mlt, kalg

namelist /ponds_nml/ &
Expand Down Expand Up @@ -1169,16 +1169,8 @@ subroutine input_data
write(nu_diag,*) 'grid_type = ', &
trim(grid_type),': user-defined grid with rotated north pole'
if (trim(grid_type) == 'tripole') then
write(nu_diag,*) 'grid_type = ', &
write(nu_diag,*) 'grid_type = ', &
trim(grid_type),': user-defined grid with northern hemisphere zipper'
if (trim(ns_boundary_type) == 'tripole') then
tmpstr2 = ' on U points (nodes)'
elseif (trim(ns_boundary_type) == 'tripoleT') then
tmpstr2 = ' on T points (cell centers)'
else
tmpstr2 = ' '
endif
write(nu_diag,*) 'ns_boundary_type = ', trim(ns_boundary_type),trim(tmpstr2)
eclare108213 marked this conversation as resolved.
Show resolved Hide resolved
endif
if (trim(grid_type) /= 'rectangular') then
if (use_bathymetry) then
Expand All @@ -1187,7 +1179,9 @@ subroutine input_data
tmpstr2 = ' bathymetric input data is not used'
endif
write(nu_diag,1012) ' use_bathymetry = ', use_bathymetry,trim(tmpstr2)
write(nu_diag,*) ' bathymetry_format= ', trim(bathymetry_format)
write(nu_diag,*) 'bathymetry_format= ', trim(bathymetry_format)
else ! rectangular
write(nu_diag,1010) ' close_boundaries = ', close_boundaries
eclare108213 marked this conversation as resolved.
Show resolved Hide resolved
endif
write(nu_diag,1022) ' nilyr = ', nilyr, ' number of ice layers (equal thickness)'
write(nu_diag,1022) ' nslyr = ', nslyr, ' number of snow layers (equal thickness)'
Expand Down Expand Up @@ -1248,17 +1242,25 @@ subroutine input_data
tmpstr2 = ' revised EVP formulation not used'
endif
write(nu_diag,1012) ' revised_evp = ', revised_evp,trim(tmpstr2)
write(nu_diag,1022) ' kevp_kernel = ', kevp_kernel,' EVP solver'

if (kevp_kernel == 0) then
tmpstr2 = ' original EVP solver'
elseif (kevp_kernel == 2 .or. kevp_kernel == 102) then
tmpstr2 = ' vectorized EVP solver'
else
tmpstr2 = ' : unknown value'
endif
write(nu_diag,1022) ' kevp_kernel = ', kevp_kernel,trim(tmpstr2)

write(nu_diag,1022) ' ndtd = ', ndtd, ' number of dynamics/advection/ridging/steps per thermo timestep'
write(nu_diag,1022) ' ndte = ', ndte, ' number of EVP or EAP subcycles'
endif
endif

if (kdyn == 1 .or. kdyn == 3) then
write(nu_diag,*) 'yield_curve = ', trim(yield_curve)
if (trim(yield_curve) == 'ellipse') &
write(nu_diag,1007) ' e_ratio = ', e_ratio, ' aspect ratio of ellipse'
endif
if (kdyn == 1 .or. kdyn == 3) then
write(nu_diag,*) 'yield_curve = ', trim(yield_curve)
if (trim(yield_curve) == 'ellipse') &
write(nu_diag,1007) ' e_ratio = ', e_ratio, ' aspect ratio of ellipse'
endif

if (trim(coriolis) == 'latitude') then
tmpstr2 = ': latitude-dependent Coriolis parameter'
Expand Down Expand Up @@ -1307,6 +1309,33 @@ subroutine input_data
write(nu_diag,1007) ' threshold_hw = ', threshold_hw, ' max water depth for grounding ice'
endif
write(nu_diag,1007) ' Ktens = ', Ktens, ' tensile strength factor'

if (kdyn == 3) then
write(nu_diag,1020) ' maxits_nonlin = ', maxits_nonlin
write(nu_diag,1030) ' precond = ', precond
write(nu_diag,1020) ' dim_fgmres = ', dim_fgmres
write(nu_diag,1020) ' dim_pgmres = ', dim_pgmres
write(nu_diag,1020) ' maxits_fgmres = ', maxits_fgmres
write(nu_diag,1020) ' maxits_pgmres = ', maxits_pgmres
write(nu_diag,1010) ' monitor_nonlin = ', monitor_nonlin
write(nu_diag,1010) ' monitor_fgmres = ', monitor_fgmres
write(nu_diag,1010) ' monitor_pgmres = ', monitor_pgmres
write(nu_diag,1030) ' ortho_type = ', ortho_type
write(nu_diag,1008) ' reltol_nonlin = ', reltol_nonlin
write(nu_diag,1008) ' reltol_fgmres = ', reltol_fgmres
write(nu_diag,1008) ' reltol_pgmres = ', reltol_pgmres
write(nu_diag,1030) ' algo_nonlin = ', algo_nonlin
write(nu_diag,1010) ' use_mean_vrel = ', use_mean_vrel
write(nu_diag,1020) ' fpfunc_andacc = ', fpfunc_andacc
if (algo_nonlin == 'anderson') then
write(nu_diag,1020) ' fpfunc_andacc = ', fpfunc_andacc
write(nu_diag,1020) ' dim_andacc = ', dim_andacc
write(nu_diag,1008) ' reltol_andacc = ', reltol_andacc
write(nu_diag,1005) ' damping_andacc = ', damping_andacc
write(nu_diag,1020) ' start_andacc = ', start_andacc
endif
endif

endif ! kdyn enabled

write(nu_diag,*) ' '
Expand Down Expand Up @@ -1362,19 +1391,16 @@ subroutine input_data
elseif (ktherm == 0) then
tmpstr2 = ' zero-layer thermo'
elseif (ktherm < 0) then
tmpstr2 = ' thermodynamics disabled'
tmpstr2 = ' Thermodynamics disabled'
else
tmpstr2 = ': unknown value'
endif
write(nu_diag,1022) ' ktherm = ', ktherm,trim(tmpstr2)
if (ktherm >= 0) then
write(nu_diag,1022) ' ktherm = ', ktherm,trim(tmpstr2)
write(nu_diag,1002) ' dt = ', dt, ' thermodynamic time step'
write(nu_diag,1007) ' ksno = ', ksno,' snow thermal conductivity'
if (ktherm == 1) &
write(nu_diag,*) 'conduct = ', trim(conduct),' ice thermal conductivity'
write(nu_diag,1012) ' sw_redist = ', sw_redist,' redistribute internal shortwave to surface'
write(nu_diag,1002) ' sw_frac = ', sw_frac,' fraction redistributed'
write(nu_diag,1002) ' sw_dtemp = ', sw_dtemp,' temperature difference from freezing to redistribute'
if (ktherm == 2) then
write(nu_diag,1002) ' a_rapid_mode = ', a_rapid_mode,' brine channel diameter'
write(nu_diag,1007) ' Rac_rapid_mode = ', Rac_rapid_mode,' critical Rayleigh number'
Expand All @@ -1383,45 +1409,51 @@ subroutine input_data
write(nu_diag,1007) ' phi_c_slow_mode = ', phi_c_slow_mode,' critical liquid fraction'
write(nu_diag,1007) ' phi_i_mushy = ', phi_i_mushy,' solid fraction at lower boundary'
endif
endif
write(nu_diag,1007) ' hfrazilmin = ', hfrazilmin,' minimum new frazil ice thickness'
Comment on lines -1386 to -1387
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, so basically this makes the 'Radiation' section only show up if ktherm > 0, right ? I agree with @eclare108213 that the diff is kind of hard to read, even in commit view...

It's a little easier on the command line, where we can tell Git to color moved lines in a different color, and also to detect moved lines even if indentation changes:

git show 402a585 --color-moved --color-moved-ws=allow-indentation-change

We can also ask to ignore changes in the amount of whitespace, this also helps:

git show 402a585 --ignore-space-change --color-moved --color-moved-ws=allow-indentation-change


write(nu_diag,*) ' '
write(nu_diag,*) ' Radiation'
write(nu_diag,*) '--------------------------------'
if (trim(shortwave) == 'dEdd') then
tmpstr2 = ': delta-Eddington multiple-scattering method'
elseif (trim(shortwave) == 'ccsm3') then
tmpstr2 = ': NCAR CCSM3 distribution method'
else
tmpstr2 = ': unknown value'
endif
write(nu_diag,*) ' shortwave = ', trim(shortwave),trim(tmpstr2)
if (trim(shortwave) == 'dEdd') then
write(nu_diag,1007) ' R_ice = ', R_ice,' tuning parameter for sea ice albedo'
write(nu_diag,1007) ' R_pnd = ', R_pnd,' tuning parameter for ponded sea ice albedo'
write(nu_diag,1007) ' R_snw = ', R_snw,' tuning parameter for snow broadband albedo'
write(nu_diag,1007) ' dT_mlt = ', dT_mlt,' change in temperature per change in snow grain radius'
write(nu_diag,1002) ' rsnw_mlt = ', rsnw_mlt,' maximum melting snow grain radius'
write(nu_diag,1007) ' kalg = ', kalg,' absorption coefficient for algae'
else
if (trim(albedo_type) == 'ccsm3') then
tmpstr2 = ': NCAR CCSM3 albedos'
elseif (trim(albedo_type) == 'constant') then
tmpstr2 = ': four constant albedos'
write(nu_diag,1007) ' hfrazilmin = ', hfrazilmin,' minimum new frazil ice thickness'

write(nu_diag,*) ' '
write(nu_diag,*) ' Radiation'
write(nu_diag,*) '--------------------------------'
if (trim(shortwave) == 'dEdd') then
tmpstr2 = ': delta-Eddington multiple-scattering method'
elseif (trim(shortwave) == 'ccsm3') then
tmpstr2 = ': NCAR CCSM3 distribution method'
else
tmpstr2 = ': unknown value'
endif
write(nu_diag,*) 'albedo_type = ', trim(albedo_type),trim(tmpstr2)
if (trim(albedo_type) == 'ccsm3') then
write(nu_diag,1007) ' albicev = ', albicev,' visible ice albedo for thicker ice'
write(nu_diag,1007) ' albicei = ', albicei,' near infrared ice albedo for thicker ice'
write(nu_diag,1007) ' albsnowv = ', albsnowv,' visible, cold snow albedo'
write(nu_diag,1007) ' albsnowi = ', albsnowi,' near infrared, cold snow albedo'
write(nu_diag,1007) ' ahmax = ', ahmax,' albedo is constant above this thickness'
write(nu_diag,*) ' shortwave = ', trim(shortwave),trim(tmpstr2)
if (trim(shortwave) == 'dEdd') then
write(nu_diag,1007) ' R_ice = ', R_ice,' tuning parameter for sea ice albedo'
write(nu_diag,1007) ' R_pnd = ', R_pnd,' tuning parameter for ponded sea ice albedo'
write(nu_diag,1007) ' R_snw = ', R_snw,' tuning parameter for snow broadband albedo'
write(nu_diag,1007) ' dT_mlt = ', dT_mlt,' change in temperature per change in snow grain radius'
write(nu_diag,1002) ' rsnw_mlt = ', rsnw_mlt,' maximum melting snow grain radius'
write(nu_diag,1007) ' kalg = ', kalg,' absorption coefficient for algae'
else
if (trim(albedo_type) == 'ccsm3') then
tmpstr2 = ': NCAR CCSM3 albedos'
elseif (trim(albedo_type) == 'constant') then
tmpstr2 = ': four constant albedos'
else
tmpstr2 = ': unknown value'
endif
write(nu_diag,*) 'albedo_type = ', trim(albedo_type),trim(tmpstr2)
if (trim(albedo_type) == 'ccsm3') then
write(nu_diag,1007) ' albicev = ', albicev,' visible ice albedo for thicker ice'
write(nu_diag,1007) ' albicei = ', albicei,' near infrared ice albedo for thicker ice'
write(nu_diag,1007) ' albsnowv = ', albsnowv,' visible, cold snow albedo'
write(nu_diag,1007) ' albsnowi = ', albsnowi,' near infrared, cold snow albedo'
write(nu_diag,1007) ' ahmax = ', ahmax,' albedo is constant above this thickness'
write(nu_diag,1007) ' ahmax = ', ahmax,' albedo is constant above this thickness'
endif
endif
write(nu_diag,1007) ' emissivity = ', emissivity,' emissivity of snow and ice'
write(nu_diag,1012) ' sw_redist = ', sw_redist,' redistribute internal shortwave to surface'
if (sw_redist) then
write(nu_diag,1002) ' sw_frac = ', sw_frac,' fraction redistributed'
write(nu_diag,1002) ' sw_dtemp = ', sw_dtemp,' temperature difference from freezing to redistribute'
endif
endif
write(nu_diag,1007) ' emissivity = ', emissivity,' emissivity of snow and ice'

write(nu_diag,*) ' '
write(nu_diag,*) ' Atmospheric Forcing / Coupling'
Expand All @@ -1434,7 +1466,7 @@ subroutine input_data
tmpstr2 = ': stability-based boundary layer'
write(nu_diag,1012) ' highfreq = ', highfreq,' high-frequency atmospheric coupling'
write(nu_diag,1022) ' natmiter = ', natmiter,' number of atmo boundary layer iterations'
write(nu_diag,1006) ' atmiter_conv = ', atmiter_conv,' convergence criterion for ustar'
write(nu_diag,*) 'atmiter_conv = ', atmiter_conv,' convergence criterion for ustar'
elseif (trim(atmbndy) == 'constant') then
tmpstr2 = ': boundary layer uses bulk transfer coefficients'
else
Expand Down Expand Up @@ -1638,36 +1670,9 @@ subroutine input_data
write(nu_diag,*) ' kmt_file = ', &
trim(kmt_file)
endif
write(nu_diag,1010) ' close_boundaries = ', &
close_boundaries
write(nu_diag,1010) ' orca_halogrid = ', &
orca_halogrid

if (kdyn == 3) then
write(nu_diag,1020) ' maxits_nonlin = ', maxits_nonlin
write(nu_diag,1030) ' precond = ', precond
write(nu_diag,1020) ' dim_fgmres = ', dim_fgmres
write(nu_diag,1020) ' dim_pgmres = ', dim_pgmres
write(nu_diag,1020) ' maxits_fgmres = ', maxits_fgmres
write(nu_diag,1020) ' maxits_pgmres = ', maxits_pgmres
write(nu_diag,1010) ' monitor_nonlin = ', monitor_nonlin
write(nu_diag,1010) ' monitor_fgmres = ', monitor_fgmres
write(nu_diag,1010) ' monitor_pgmres = ', monitor_pgmres
write(nu_diag,1030) ' ortho_type = ', ortho_type
write(nu_diag,1008) ' reltol_nonlin = ', reltol_nonlin
write(nu_diag,1008) ' reltol_fgmres = ', reltol_fgmres
write(nu_diag,1008) ' reltol_pgmres = ', reltol_pgmres
write(nu_diag,1030) ' algo_nonlin = ', algo_nonlin
write(nu_diag,1010) ' use_mean_vrel = ', use_mean_vrel
if (algo_nonlin == 'anderson') then
write(nu_diag,1020) ' fpfunc_andacc = ', fpfunc_andacc
write(nu_diag,1020) ' dim_andacc = ', dim_andacc
write(nu_diag,1008) ' reltol_andacc = ', reltol_andacc
write(nu_diag,1005) ' damping_andacc = ', damping_andacc
write(nu_diag,1020) ' start_andacc = ', start_andacc
endif
endif

write(nu_diag,1010) ' conserv_check = ', conserv_check

write(nu_diag,1020) ' fyear_init = ', &
Expand Down
2 changes: 1 addition & 1 deletion cicecore/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
CICE 6.1.3
CICE 6.1.4
6 changes: 3 additions & 3 deletions configuration/scripts/ice_in
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,6 @@
dSdt_slow_mode = -5.0e-8
phi_c_slow_mode = 0.05
phi_i_mushy = 0.85
sw_redist = .false.
sw_frac = 0.9d0
sw_dtemp = 0.02d0
hfrazilmin = 0.05d0
floediam = 300.0d0
/
Expand Down Expand Up @@ -172,6 +169,9 @@
dT_mlt = 1.5
rsnw_mlt = 1500.
kalg = 0.6
sw_redist = .false.
sw_frac = 0.9d0
sw_dtemp = 0.02d0
/

&ponds_nml
Expand Down
4 changes: 2 additions & 2 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,9 @@
# built documents.
#
# The short X.Y version.
version = u'6.1.3'
version = u'6.1.4'
# The full version, including alpha/beta/rc tags.
version = u'6.1.3'
version = u'6.1.4'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
6 changes: 3 additions & 3 deletions doc/source/user_guide/ug_case_settings.rst
Original file line number Diff line number Diff line change
Expand Up @@ -342,9 +342,6 @@ thermo_nml
"``phi_c_slow_mode``", ":math:`0<\phi_c < 1`", "critical liquid fraction", "0.05"
"``phi_i_mushy``", ":math:`0<\phi_i < 1`", "solid fraction at lower boundary", "0.85"
"``Rac_rapid_mode``", "real", "critical Rayleigh number", "10.0"
"``sw_redist``", "logical", "redistribute internal shortwave to surface", "``.false.``"
"``sw_frac``", "real", "fraction redistributed", "0.9"
"``sw_dtemp``", "real", "temperature difference from melt to start redistributing", "0.02"
"", "", "", ""

.. _dynamics_nml:
Expand Down Expand Up @@ -438,6 +435,9 @@ shortwave_nml
"``R_snw``", "real", "tuning parameter for snow (broadband albedo) from Delta-Eddington shortwave", "1.5"
"``shortwave``", "``ccsm3``", "NCAR CCSM3 shortwave distribution method", "``ccsm3``"
"", "``dEdd``", "Delta-Eddington method", ""
"``sw_dtemp``", "real", "temperature difference from melt to start redistributing", "0.02"
"``sw_frac``", "real", "fraction redistributed", "0.9"
"``sw_redist``", "logical", "redistribute internal shortwave to surface", "``.false.``"
"", "", "", ""

ponds_nml
Expand Down