Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
34 changes: 32 additions & 2 deletions config_src/coupled_driver/ocean_model_MOM.F90
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ module ocean_model_mod
use MOM_time_manager, only : operator(/=)
use MOM_tracer_flow_control, only : call_tracer_register, tracer_flow_control_init
use MOM_variables, only : surface

use MOM_ice_shelf, only : initialize_ice_shelf, shelf_calc_flux, ice_shelf_CS
use MOM_ice_shelf, only : ice_shelf_end, ice_shelf_save_restart
use coupler_types_mod, only : coupler_2d_bc_type
use mpp_domains_mod, only : domain2d, mpp_get_layout, mpp_get_global_domain
use mpp_domains_mod, only : mpp_define_domains, mpp_get_compute_domain, mpp_get_data_domain
Expand Down Expand Up @@ -151,7 +152,8 @@ module ocean_model_mod
type(time_type) :: write_energy_time ! The next time to write to the energy file.

integer :: nstep = 0 ! The number of calls to update_ocean.

logical :: use_ice_shelf = .false. ! If true, the ice shelf model is enabled.
type(ice_shelf_CS), pointer :: Ice_shelf_CSp => NULL()
logical :: restore_salinity ! If true, the coupled MOM driver adds a term to
! restore salinity to a specified value.
real :: press_to_z ! A conversion factor between pressure and ocean
Expand Down Expand Up @@ -263,10 +265,19 @@ subroutine ocean_model_init(Ocean_sfc, OS, Time_init, Time_in)
call get_param(param_file, mod, "G_EARTH", G_Earth, &
"The gravitational acceleration of the Earth.", &
units="m s-2", default = 9.80)

call get_param(param_file,mod,"ICE_SHELF",OS%use_ice_shelf)


OS%press_to_z = 1.0/(Rho0*G_Earth)

call surface_forcing_init(Time_in, OS%grid, param_file, OS%MOM_CSp%diag, &
OS%forcing_CSp, OS%restore_salinity)

if (OS%use_ice_shelf) then
call initialize_ice_shelf(OS%Time, OS%ice_shelf_CSp,OS%MOM_CSp%diag, OS%fluxes)
endif

call MOM_sum_output_init(OS%grid, param_file, OS%dirs%output_directory, &
OS%MOM_CSp%ntrunc, Time_init, OS%sum_output_CSp)

Expand Down Expand Up @@ -362,6 +373,14 @@ subroutine update_ocean_model(Ice_ocean_boundary, OS, Ocean_sfc, &
call enable_averaging(time_step, OS%Time + Ocean_coupling_time_step, OS%MOM_CSp%diag) ! Needed to allow diagnostics in convert_IOB
call convert_IOB_to_fluxes(Ice_ocean_boundary, OS%fluxes, index_bnds, OS%Time, &
OS%grid, OS%forcing_CSp, OS%state, OS%restore_salinity)

! Add ice shelf fluxes

if (OS%use_ice_shelf) then
call shelf_calc_flux(OS%State, OS%fluxes, OS%Time, time_step, OS%Ice_shelf_CSp)
endif


call disable_averaging(OS%MOM_CSp%diag)
Master_time = OS%Time ; Time1 = OS%Time

Expand Down Expand Up @@ -412,12 +431,18 @@ subroutine ocean_model_restart(OS, timestamp)
OS%MOM_CSp%restart_CSp, .true.)
call forcing_save_restart(OS%forcing_CSp, OS%grid, OS%Time, &
OS%dirs%restart_output_dir, .true.)
if (OS%use_ice_shelf) then
call ice_shelf_save_restart(OS%Ice_shelf_CSp, OS%Time, OS%dirs%restart_output_dir, .true.)
endif
endif
if (BTEST(OS%Restart_control,0)) then
call save_restart(OS%dirs%restart_output_dir, OS%Time, OS%grid, &
OS%MOM_CSp%restart_CSp)
call forcing_save_restart(OS%forcing_CSp, OS%grid, OS%Time, &
OS%dirs%restart_output_dir)
if (OS%use_ice_shelf) then
call ice_shelf_save_restart(OS%Ice_shelf_CSp, OS%Time, OS%dirs%restart_output_dir)
endif
endif

end subroutine ocean_model_restart
Expand Down Expand Up @@ -445,6 +470,7 @@ subroutine ocean_model_end(Ocean_sfc, Ocean_state, Time)

call ocean_model_save_restart(Ocean_state, Time)
call MOM_end(Ocean_state%MOM_CSp)
if (Ocean_state%use_ice_shelf) call ice_shelf_end(Ocean_state%Ice_shelf_CSp)
end subroutine ocean_model_end
! </SUBROUTINE> NAME="ocean_model_end"

Expand Down Expand Up @@ -472,6 +498,10 @@ subroutine ocean_model_save_restart(OS, Time, directory, filename_suffix)

call forcing_save_restart(OS%forcing_CSp, OS%grid, Time, restart_dir)

if (OS%use_ice_shelf) then
call ice_shelf_save_restart(OS%Ice_shelf_CSp, OS%Time, OS%dirs%restart_output_dir)
endif

end subroutine ocean_model_save_restart

!#######################################################################
Expand Down
1 change: 1 addition & 0 deletions examples/ocean_SIS/Amery/INPUT/.datasets
895 changes: 895 additions & 0 deletions examples/ocean_SIS/Amery/MOM_input

Large diffs are not rendered by default.

Empty file.
60 changes: 60 additions & 0 deletions examples/ocean_SIS/Amery/data_table
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
"ATM" , "p_surf" , "" , "" , .false. , 1.0e5
"ATM" , "p_bot" , "" , "" , .false. , 1.0e5
"ATM" , "t_bot" , "" , "" , .false. , 273.0
"ATM" , "sphum_bot" , "" , "" , .false. , 0.01
"ATM" , "u_bot" , "" , "" , .false. , 0.0
"ATM" , "u_flux" , "" , "" , .false. , 0.0
"ATM" , "v_flux" , "" , "" , .false. , 0.0
"ATM" , "v_bot" , "" , "" , .false. , 0.0
"ATM" , "z_bot" , "" , "" , .false. , 10.0
"ATM" , "gust" , "" , "" , .false. , 1.0e-4
"ATM" , "flux_sw" , "" , "" , .false. , 0.0
"ATM" , "flux_lw" , "" , "" , .false. , 0.0
"ATM" , "lprec" , "" , "" , .false. , 0.0
"ATM" , "fprec" , "" , "" , .false. , 0.0
"LND" , "t_surf" , "" , "" , .false. , 273.0
"LND" , "t_ca" , "" , "" , .false. , 273.0
"LND" , "q_ca" , "" , "" , .false. , 0.01
"LND" , "rough_mom" , "" , "" , .false. , 1.0e-3
"LND" , "rough_heat" , "" , "" , .false. , 1.0e-3
"LND" , "albedo" , "" , "" , .false. , 0.0
"LND" , "sphum_surf" , "" , "" , .false. , 0.01
"LND" , "sphum_ca" , "" , "" , .false. , 0.01
"LND" , "t_flux" , "" , "" , .false. , 0.0
"LND" , "sphum_flux" , "" , "" , .false. , 0.0
"LND" , "lw_flux" , "" , "" , .false. , 0.0
"LND" , "sw_flux" , "" , "" , .false. , 0.0
"LND" , "lprec" , "" , "" , .false. , 0.0
"LND" , "fprec" , "" , "" , .false. , 0.0
"LND" , "dhdt" , "" , "" , .false. , 1.0e-5
"LND" , "dedt" , "" , "" , .false. , 1.0e-5
"LND" , "dedq" , "" , "" , .false. , 1.0e-5
"LND" , "drdt" , "" , "" , .false. , 1.0e-5
"LND" , "drag_q" , "" , "" , .false. , 1.0e-3
"LND" , "p_surf" , "" , "" , .false. , 1.0e5
"ICE" , "lw_flux_dn" , "" , "" , .false. , 0.0
"ICE" , "sw_flux_vis_dir_dn" , "" , "" , .false. , 0.0
"ICE" , "sw_flux_vis_dif_dn" , "" , "" , .false. , 0.0
"ICE" , "sw_flux_nir_dir_dn" , "" , "" , .false. , 0.0
"ICE" , "sw_flux_nir_dif_dn" , "" , "" , .false. , 0.0
"ICE" , "runoff" , "" , "" , .false. , 0.0
"ICE" , "calving" , "" , "" , .false. , 0.0
"ICE" , "u_flux" , "" , "" , .false. , 0.0
"ICE" , "v_flux" , "" , "" , .false. , 0.0
"ICE" , "t_flux" , "" , "" , .false. , 0.0
"ICE" , "q_flux" , "" , "" , .false. , 0.0
"ICE" , "lw_flux_dn" , "" , "" , .false. , 0.0
"ICE" , "lw_flux" , "" , "" , .false. , 0.0
"ICE" , "lprec" , "" , "" , .false. , 0.0
"ICE" , "fprec" , "" , "" , .false. , 0.0
"ICE" , "dhdt" , "" , "" , .false. , 80.0
"ICE" , "dedt" , "" , "" , .false. , 2.0e-6
"ICE" , "drdt" , "" , "" , .false. , 10.0
"ICE" , "sic_obs" , "" , "" , .true. , 0.00
"ICE" , "sit_obs" , "" , "" , .true. , 0.00
"ICE" , "sst_obs" , "SST" , "./INPUT/sst_ice_clim.nc" , .false. , 1.0
"OCN" , "u_flux" , "" , "" , .true. , 0.00
"OCN" , "v_flux" , "" , "" , .true. , 0.00
"OCN" , "t_flux" , "" , "" , .true. , 0.00
"OCN" , "q_flux" , "" , "" , .true. , 0.00
"OCN" , "salt_flux" , "" , "" , .true. , 0.00
78 changes: 78 additions & 0 deletions examples/ocean_SIS/Amery/diag_table
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
Amery_baseline
1992 1 1 0 0 0
## output files
"ocean_month", 1, "months", 1, "days", "time"
"ocean_month_snap", 1, "months", 1, "days", "time"
"ocean_daily", 1, "days", 1, "days", "time"
## output variables
#
#==================
# OCEAN DIAGNOSTICS
#==================
# Monthly snapshots of tracers, interface positions and Kd
"ocean_model","e","e","ocean_month_snap","all",.false.,"none",2
"ocean_model","temp","temp","ocean_month_snap","all",.false.,"none",2
"ocean_model","salt","salt","ocean_month_snap","all",.false.,"none",2
"ocean_model","u","u","ocean_month_snap","all",.false.,"none",2
"ocean_model","v","v","ocean_month_snap","all",.false.,"none",2
"ocean_model","salt_int","salt_int","ocean_month_snap","all",.false.,"none",2
"ocean_model","temp_int","temp_int","ocean_month_snap","all",.false.,"none",2
#"ocean_model","Kd_shear","Kd_shear","ocean_month_snap","all",.false.,"none",2
"ocean_model","Kd_layer","Kd_layer","ocean_month_snap","all",.false.,"none",2
#"ocean_model","Kd_work","Kd_work","ocean_month_snap","all",.false.,"none",2
# Monthly Avg transports in sigma2
"ocean_model","uh","uh","ocean_month","all",.true.,"none",2
"ocean_model","vh","vh","ocean_month","all",.true.,"none",2
"ocean_model","wd","wd","ocean_month","all",.true.,"none",2
#"ocean_model","Res_fn","Res_fn","ocean_month","all",.true.,"none",2
#"ocean_model","col_mass","col_mass","ocean_month","all",.true.,"none",2
#"ocean_model","Tflx_dia_diff","Tflx_dia_diff","ocean_month","all",.true.,"none",2
#"ocean_model","Tflx_dia_adv","Tflx_dia_adv","ocean_month","all",.true.,"none",2
#"ocean_model","Sflx_dia_diff","Sflx_dia_diff","ocean_month","all",.true.,"none",2
#"ocean_model","Sflx_dia_adv","Sflx_dia_adv","ocean_month","all",.true.,"none",2
#"ocean_model","T_adx_2d","T_adx_2d","ocean_month","all",.true.,"none",2
#"ocean_model","T_ady_2d","T_ady_2d","ocean_month","all",.true.,"none",2
#"ocean_model","S_adx_2d","S_adx_2d","ocean_month","all",.true.,"none",2
#"ocean_model","S_ady_2d","S_ady_2d","ocean_month","all",.true.,"none",2
#"ocean_model","T_diffx_2d","T_diffx_2d","ocean_month","all",.true.,"none",2
#"ocean_model","T_diffy_2d","T_diffy_2d","ocean_month","all",.true.,"none",2
#"ocean_model","S_diffx_2d","S_diffx_2d","ocean_month","all",.true.,"none",2
#"ocean_model","S_diffy_2d","S_diffy_2d","ocean_month","all",.true.,"none",2
"ocean_model","age","age","ocean_month","all",.true.,"none",2
"ocean_model","temp_h","temp_h","ocean_month","all",.true.,"none",2
"ocean_model","salt_h","salt_h","ocean_month","all",.true.,"none",2
"ocean_model","h","h","ocean_month","all",.true.,"none",2
"ocean_model","Kd_work","Kd_work","ocean_month","all",.true.,"none",2
# Monthly Avg Stress
#"ocean_model","taux", "taux", "ocean_month","all",.true.,"none",2
#"ocean_model","tauy", "tauy", "ocean_month","all",.true.,"none",2
#===========================
# Mixed Layer and TKE Budget Terms:
#===========================
"ocean_model","h_ML","h_ML","ocean_daily","all",.true.,"none",2
"ocean_model","ustar_shelf","ustar_shelf","ocean_daily","all",.true.,"none",2
"ocean_model","SST","SST","ocean_daily","all",.true.,"none",2
"ocean_model","SST","SST_max","ocean_daily","all",max,"none",2
"ocean_model","SST","SST_min","ocean_daily","all",min,"none",2
"ocean_model","SSS","SSS","ocean_daily","all",.true.,"none",2
"ocean_model","SSH","SSH","ocean_daily","all",.true.,"none",2
"ocean_model","SSU","SSU","ocean_daily","all",.true.,"none",2
"ocean_model","SSV","SSV","ocean_daily","all",.true.,"none",2
"ocean_model","melt","melt","ocean_daily","all",.true.,"none",2
"ocean_model","uhbt","uhbt","ocean_daily","all",.true.,"none",2
"ocean_model","vhbt","vhbt","ocean_daily","all",.true.,"none",2
#==================
# Surface Forcing:
#=================
"ocean_model","taux", "taux", "ocean_daily","all",.true.,"none",2
"ocean_model","tauy", "tauy", "ocean_daily","all",.true.,"none",2
"ocean_model","ustar", "ustar", "ocean_daily","all",.true.,"none",2
"ocean_model","PRCmE", "PmE", "ocean_daily","all",.true.,"none",2
#"ocean_model","SW", "SW", "ocean_daily","all",.true.,"none",2
#"ocean_model","LwLatSens","LwLatSens","ocean_daily","all",.true.,"none",2
#"ocean_model","salt_flux","salt_flux","ocean_daily","all",.true.,"none",2
"ocean_model","exch_vel_t", "exch_vel_t", "ocean_daily","all",.true.,"none",2
"ocean_model","exch_vel_s", "exch_vel_s", "ocean_daily","all",.true.,"none",2
"ocean_model","frazil", "frazil", "ocean_daily","all",.true.,"none",2
#"ocean_model","net_heat_surface","net_heat_surface","ocean_daily","all",.true.,"none",2
#
19 changes: 19 additions & 0 deletions examples/ocean_SIS/Amery/field_table
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# specific humidity for moist runs
## check if "profile_type", "fixed", "surface_value=3.e-6" is needed for coupled model
"TRACER", "atmos_mod", "sphum"
"longname", "specific humidity"
"units", "kg/kg"
"profile_type", "fixed", "surface_value=3.e-6" /
# prognostic cloud scheme tracers
"TRACER", "atmos_mod", "liq_wat"
"longname", "cloud liquid specific humidity"
"units", "kg/kg" /
"TRACER", "atmos_mod", "ice_wat"
"longname", "cloud ice water specific humidity"
"units", "kg/kg" /
"TRACER", "atmos_mod", "cld_amt"
"longname", "cloud fraction"
"units", "none" /
"TRACER", "land_mod", "sphum"
"longname", "specific humidity"
"units", "kg/kg" /
121 changes: 121 additions & 0 deletions examples/ocean_SIS/Amery/input.nml
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
&MOM_input_nml
output_directory = 'RESTART/',
input_filename = 'n'
restart_input_dir = 'INPUT/',
restart_output_dir = 'RESTART/',
parameter_filename = 'MOM_input',
'MOM_override'
/

&coupler_nml
months = 12,
days = 0,
current_date = 1992,1,1,0,0,0,
calendar = 'JULIAN',
dt_cpld = 3600,
dt_atmos = 3600,
do_atmos = .true.,
do_land = .false.,
do_ice = .true.,
do_ocean = .true.,
do_flux = .true.,
atmos_npes = 32,
ocean_npes = 240,
concurrent = .true.
use_lag_fluxes=.true.
check_stocks = 0
/

&diag_manager_nml
max_axes = 100,
max_num_axis_sets = 100,
max_input_fields = 699
max_output_fields = 699
mix_snapshot_average_fields=.false.
conserve_water=.true.
/

&flux_exchange_nml
debug_stocks = .FALSE.
divert_stocks_report = .TRUE.
do_area_weighted_flux = .FALSE.
/

&fms_io_nml
fms_netcdf_restart=.true.
threading_read='multi'
threading_write='single'
fileset_write='single'
max_files_r = 200
max_files_w = 200
/

&fms_nml
clock_grain='ROUTINE'
clock_flags='NONE'
domains_stack_size = 5000000
stack_size =0
/

&ice_albedo_nml
t_range = 10.
/

&ice_model_nml
layout=8,4
nsteps_dyn=144
nsteps_adv=2
num_part = 6
wd_turn = 0.0
spec_ice=.false.
ice_bulk_salin = 0.010
alb_sno = 0.85 ! keep CM2 setting
alb_ice = 0.65 ! keep CM2 setting
t_range_melt = 1.0 ! NOTE: CM2 uses 1.0
heat_rough_ice = 5.0e-4
cm2_bugs = .false.
do_icebergs = .false.
atmos_winds=.true.
add_diurnal_sw = .false.
do_ice_limit=.false.
max_ice_limit=10.0
channel_viscosity=5.e-5
chan_cfl_limit=0.001
h_lo_lim = 1.e-10
io_layout=1,1
/

&icebergs_nml
verbose=.FALSE.
traj_sample_hrs=0
verbose_hrs=2400
/

&monin_obukhov_nml
stable_option = 2,
rich_crit = 10.0,
zeta_trans = 0.5
/

&ocean_albedo_nml
ocean_albedo_option = 2
/

&ocean_rough_nml
rough_scheme = 'beljaars'
/

&sat_vapor_pres_nml
construct_table_wrt_liq = .true.
construct_table_wrt_liq_and_ice = .true.
/

&surface_flux_nml
gust_min = 1.e-10
/

&xgrid_nml
make_exchange_reproduce = .false.
interp_method = 'second_order'
/

9 changes: 9 additions & 0 deletions examples/ocean_SIS/GIS_0125/MOM_channel_list
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
! This file specifies restricted channel widths in MOM. The order is:
! [UV]_WIDTH, min_longitude, max_longitude, min_latitude, max_latitude, width

U_width, -6.1, -5.4, 35.8, 36.0, 12000.0 ! Gibraltar
U_width, 26.4, 26.8, 40.4, 40.6, 5000.0 ! Dardanelles

V_width, 28.8, 29.0, 41.1, 41.2, 2500.0 ! Bosporus - should be 1km wide.
V_width, 43.25, 43.5, 12.6, 12.8, 10000.0 ! Red Sea, Bab-el-Mendeb
V_width, 141.5, 141.7, 52.0, 52.15, 2500.0 ! Between Sakhalin & Russia
Loading