|
| 1 | +(dev-ocean-ice-shelf-2d)= |
| 2 | + |
| 3 | +# ice_shelf_2d |
| 4 | + |
| 5 | +The `ice_shelf_2d` test group |
| 6 | +(`polaris.ocean.tasks.ice_shelf_2d.IceShelf2d`) |
| 7 | +implements a very simplified ice-shelf cavity that is invariant in the x |
| 8 | +direction (see {ref}`ocean-ice-shelf-2d`). Here, we describe the shared |
| 9 | +framework for this test group and the 2 test cases. |
| 10 | + |
| 11 | +(dev-ocean-ice-shelf-2d-framework)= |
| 12 | + |
| 13 | +## framework |
| 14 | + |
| 15 | +The shared config options for the `ice_shelf_2d` test group |
| 16 | +are described in {ref}`ocean-ice-shelf-2d` in the User's Guide. |
| 17 | + |
| 18 | +Additionally, the test group has shared `ssh_forward.yaml` and `forward.yaml` |
| 19 | +files with common namelist options and streams related to the `ssh_adjustment` |
| 20 | +and `forward` steps, respectively. |
| 21 | + |
| 22 | +The test case class is inherited from |
| 23 | +{py:class}`polaris.ocean.ice_shelf.IceShelfTask` and |
| 24 | +its {py:class}`polaris.ocean.ice_shelf.ssh_forward.SshForward` and |
| 25 | +{py:class}`polaris.ocean.ice_shelf.ssh_adjustment.SshAdjustment` step classes |
| 26 | +are used to set up one of each step for each iteration given by the config |
| 27 | +option `ssh_adjustment:iterations`. |
| 28 | + |
| 29 | +### init |
| 30 | + |
| 31 | +The class :py:class:`polaris.ocean.tasks.ice_shelf_2d.init.Init` |
| 32 | +defines a step for setting up the initial state for each test case. |
| 33 | + |
| 34 | +First, a mesh appropriate for the resolution is generated using |
| 35 | +{py:func}`mpas_tools.planar_hex.make_planar_hex_mesh()`. Then, the mesh is |
| 36 | +culled to remove periodicity in the y direction. A vertical grid is generated, |
| 37 | +with 20 layers of 100-m thickness each by default. Then, the 1D grid is either |
| 38 | +"squashed" down so the sea-surface height corresponds to the location of the |
| 39 | +ice-ocean interface (ice draft) using a z-star {ref}`dev-ocean-framework-vertical` |
| 40 | +or top layers are removed where there is an ice shelf using a z-level |
| 41 | +coordinate. Finally, the initial salinity profile is computed along with |
| 42 | +uniform temperature and zero initial velocity. |
| 43 | + |
| 44 | +### forward |
| 45 | + |
| 46 | +The class {py:class}`compass.ocean.tests.ice_shelf_2d.forward.Forward` |
| 47 | +defines a step for running MPAS-Ocean from the initial condition produced in |
| 48 | +the `init` step. For MPAS-Ocean, PIO namelist options are modified and a |
| 49 | +graph partition is generated as part of `runtime_setup()`. Next, the ocean |
| 50 | +model is run. |
| 51 | + |
| 52 | +### validate |
| 53 | + |
| 54 | +The class {py:class}`polaris.ocean.tasks.ice_shelf_2d.validate.Validate` |
| 55 | +defines a step for validating outputs in two step directories against one |
| 56 | +another. This step ensures that `temperature`, `salinity`, `layerThickness` |
| 57 | +and `normalVelocity` are identical in `output.nc` files in the two steps. |
| 58 | +It also checks a number of land ice variables and frazil variables stored in |
| 59 | +`land_ice_fluxes.nc` and `frazil.nc`, respectively. This step is used by the |
| 60 | +restart test (see {ref}`dev-ocean-ice-shelf-2d-restart`). |
| 61 | + |
| 62 | +### viz |
| 63 | + |
| 64 | +The class {py:class}`polaris.ocean.tasks.ice_shelf_2d.viz.Viz` uses the planar |
| 65 | +visualization capabilities provided by |
| 66 | +{py:func}`polaris.ocean.viz.compute_transect()`. |
| 67 | + |
| 68 | +(dev-ocean-ice-shelf-2d-default)= |
| 69 | + |
| 70 | +## default |
| 71 | + |
| 72 | +The {py:class}`polaris.ocean.tasks.ice_shelf_2d.default.Default` test case |
| 73 | +config options are described in {ref}`ocean-ice-shelf-2d-default`. |
| 74 | + |
| 75 | +The test creates and mesh and initial condition, performs 15 iterations of |
| 76 | +SSH adjustment to make sure the SSH is as close as possible to being in |
| 77 | +dynamic balance with the land-ice pressure. Then, it performs a 10-minute |
| 78 | + forward simulation. If a baseline is provided, a large number of variables |
| 79 | +(both prognostic and related to land-ice fluxes) are checked to make sure |
| 80 | +they match the baseline. |
| 81 | + |
| 82 | +The restart test, `ocean/planar/ice_shelf_2d/$RES/$COORD_TYPE/default/with_restart` |
| 83 | +is just a variant of the default test that has two additional steps, a `forward` |
| 84 | +step and a `validate` step. |
| 85 | + |
| 86 | +The tidal forcing test, `ocean/planar/ice_shelf_2d/$RES/$COORD_TYPE/default_tidal_forcing` |
| 87 | +is a variant of the `default` test that has tidal forcing, is run for longer |
| 88 | +(0.1 days), and uses the RK4 time integration scheme by default. |
0 commit comments