Go to the documentation of this file.
7 use mom_cpu_clock,
only : cpu_clock_id, cpu_clock_begin, cpu_clock_end, clock_routine
29 implicit none ;
private
31 #include <MOM_memory.h>
38 logical :: use_files = .false.
39 logical :: use_kelvin = .false.
40 logical :: use_tidal_bay = .false.
41 logical :: use_shelfwave = .false.
42 logical :: use_dyed_channel = .false.
67 character(len=40) :: mdl =
"MOM_boundary_update"
69 # include "version_variable.h"
70 if (
associated(cs))
then
71 call mom_error(warning,
"call_OBC_register called with an associated "// &
74 else ;
allocate(cs) ;
endif
78 call get_param(param_file, mdl,
"USE_FILE_OBC", cs%use_files, &
79 "If true, use external files for the open boundary.", &
81 call get_param(param_file, mdl,
"USE_TIDAL_BAY_OBC", cs%use_tidal_bay, &
82 "If true, use the tidal_bay open boundary.", &
84 call get_param(param_file, mdl,
"USE_KELVIN_WAVE_OBC", cs%use_Kelvin, &
85 "If true, use the Kelvin wave open boundary.", &
87 call get_param(param_file, mdl,
"USE_SHELFWAVE_OBC", cs%use_shelfwave, &
88 "If true, use the shelfwave open boundary.", &
90 call get_param(param_file, mdl,
"USE_DYED_CHANNEL_OBC", cs%use_dyed_channel, &
91 "If true, use the dyed channel open boundary.", &
94 if (cs%use_files) cs%use_files = &
97 if (cs%use_tidal_bay) cs%use_tidal_bay = &
98 register_tidal_bay_obc(param_file, cs%tidal_bay_OBC_CSp, &
100 if (cs%use_Kelvin) cs%use_Kelvin = &
101 register_kelvin_obc(param_file, cs%Kelvin_OBC_CSp, &
103 if (cs%use_shelfwave) cs%use_shelfwave = &
104 register_shelfwave_obc(param_file, cs%shelfwave_OBC_CSp, &
106 if (cs%use_dyed_channel) cs%use_dyed_channel = &
107 register_dyed_channel_obc(param_file, cs%dyed_channel_OBC_CSp, &
118 real,
dimension(SZI_(G),SZJ_(G),SZK_(G)),
intent(inout) :: h
121 type(time_type),
intent(in) :: time
124 logical :: read_obc_eta = .false.
125 logical :: read_obc_uv = .false.
126 logical :: read_obc_ts = .false.
127 integer :: i, j, k, itt, is, ie, js, je, isd, ied, jsd, jed, nz
128 integer :: isd_off, jsd_off
129 integer :: isdb, iedb, jsdb, jedb
130 character(len=40) :: mdl =
"update_OBC_data"
131 character(len=200) :: filename, obc_file, inputdir
133 is = g%isc ; ie = g%iec ; js = g%jsc ; je = g%jec ; nz = g%ke
134 isd = g%isd ; ied = g%ied ; jsd = g%jsd ; jed = g%jed
135 isdb = g%IsdB ; iedb = g%IedB ; jsdb = g%JsdB ; jedb = g%JedB
140 if (cs%use_tidal_bay) &
141 call tidal_bay_set_obc_data(obc, cs%tidal_bay_OBC_CSp, g, h, time)
143 call kelvin_set_obc_data(obc, cs%Kelvin_OBC_CSp, g, gv, us, h, time)
144 if (cs%use_shelfwave) &
145 call shelfwave_set_obc_data(obc, cs%shelfwave_OBC_CSp, g, h, time)
146 if (cs%use_dyed_channel) &
147 call dyed_channel_update_flow(obc, cs%dyed_channel_OBC_CSp, g, time)
148 if (obc%needs_IO_for_data) &
149 call update_obc_segment_data(g, gv, us, obc, tv, h, time)
161 if (
associated(cs))
deallocate(cs)
subroutine, public tidal_bay_set_obc_data(OBC, CS, G, h, Time)
This subroutine sets the properties of flow at open boundary conditions.
subroutine, public update_obc_segment_data(G, GV, US, OBC, tv, h, Time)
Update the OBC values on the segments.
subroutine, public kelvin_set_obc_data(OBC, CS, G, GV, US, h, Time)
This subroutine sets the properties of flow at open boundary conditions.
subroutine, public dyed_channel_obc_end(CS)
Clean up the dyed_channel OBC from registry.
Provides a transparent vertical ocean grid type and supporting routines.
subroutine, public file_obc_end(CS)
Clean up the file OBC from registry.
An overloaded interface to log version information about modules.
Controls where open boundary conditions are applied.
logical function, public register_dyed_channel_obc(param_file, CS, OBC_Reg)
Add dyed channel to OBC registry.
Pointers to an assortment of thermodynamic fields that may be available, including potential temperat...
Contains a shareable dynamic type for describing horizontal grids and metric data and utilty routines...
Configures the model for the Kelvin wave experiment.
subroutine, public shelfwave_set_obc_data(OBC, CS, G, h, Time)
This subroutine sets the properties of flow at open boundary conditions.
subroutine, public mom_mesg(message, verb, all_print)
This provides a convenient interface for writing an informative comment.
subroutine, public shelfwave_obc_end(CS)
Clean up the shelfwave OBC from registry.
Configures the model for the idealized shelfwave test case.
This module contains the tracer_registry_type and the subroutines that handle registration of tracers...
A structure that can be parsed to read and document run-time parameters.
The control structure for the MOM_boundary_update module.
An overloaded interface to read and log the values of various types of parameters.
Control structure for Kelvin wave open boundaries.
Describes various unit conversion factors.
logical function, public register_tidal_bay_obc(param_file, CS, OBC_Reg)
Add tidal bay to OBC registry.
subroutine, public obc_register_end(CS)
Clean up the OBC registry.
logical function, public register_kelvin_obc(param_file, CS, OBC_Reg)
Add Kelvin wave to OBC registry.
Control structure for open boundaries that read from files. Probably lots to update here.
Type to carry basic OBC information needed for updating values.
Describes the vertical ocean grid, including unit conversion factors.
Provides transparent structures with groups of MOM6 variables and supporting routines.
Controls where open boundary conditions are applied.
Wraps the MPP cpu clock functions.
subroutine, public tidal_bay_obc_end(CS)
Clean up the tidal bay OBC from registry.
The MOM6 facility to parse input files for runtime parameters.
logical function, public register_file_obc(param_file, CS, OBC_Reg)
Add file to OBC registry.
Control structure for shelfwave open boundaries.
Type to carry basic tracer information.
Control structure for dyed-channel open boundaries.
subroutine, public dyed_channel_update_flow(OBC, CS, G, Time)
This subroutine updates the long-channel flow.
Provides the ocean grid type.
logical function, public register_shelfwave_obc(param_file, CS, OBC_Reg)
Add shelfwave to OBC registry.
Provides a transparent unit rescaling type to facilitate dimensional consistency testing.
Control structure for tidal bay open boundaries.
subroutine, public mom_error(level, message, all_print)
This provides a convenient interface for writing an mpp_error message with run-time filter based on a...
subroutine, public update_obc_data(OBC, G, GV, US, tv, h, CS, Time)
Calls appropriate routine to update the open boundary conditions.
An overloaded interface to log the values of various types of parameters.
Initialization for the dyed_channel configuration.
Configures the model for the "tidal_bay" experiment. tidal_bay = Tidally resonant bay from Zygmunt Ko...
Routines for error handling and I/O management.
subroutine, public kelvin_obc_end(CS)
Clean up the Kelvin wave OBC from registry.
subroutine, public call_obc_register(param_file, CS, OBC)
The following subroutines and associated definitions provide the machinery to register and call the s...
Describes the horizontal ocean grid with only dynamic memory arrays.
Ocean grid type. See mom_grid for details.
integer id_clock_pass
A CPU time clock ID.