-
Notifications
You must be signed in to change notification settings - Fork 0
Ocean/moc streamfunction am #951
Ocean/moc streamfunction am #951
Conversation
A new subroutine has been added for constraining the min. and max. number of columns during grid generation with rx1 < rx1Max. At least config_rx1_min_levels and at most nVertLevels levels must span the space between z=ssh and z=-bottomDepth in a given column.
Previously, during each smoothing iteration, the layer containing -bottomDepth was lifted or dropped so zInterface matched -bottomDepth. This often led to cases where rx1 > rx1Max (though not by huge amounts). The new method seeks to put the lower zInterface of the layer containing -bottomDepth as close to -bottomDepth as possible without violating rx1 <= rx1Max. The result is that rx1 <= rx1Max always and a partial cells approach is not needed under ice shelves, since smoothing and constraints on rx1 ensure that the bottom layer has a reasonable thickness compared with its horizontal and vertical neighbors.
The Haney number (rx1) is also computed as a diagnostic.
Also update iterative init configuration to use an init template
deltaSSH is now only nonzero where SSH is allowed to be modified (modifySSHMask == 1)
Was still using the non-standard planar mesh from an earlier commit of sub_ice_shelf_2D
This variable can be either 'ssh' or 'ssp', depending on which field the user wishes to iteratively modify to reduce barotropic waves in the initial condition. Previously, this namelist variable was a confusing logical, config_update_ssh_not_ssp
This PR adds a module, ocn_init_ssh_and_ssp, for computing (and iteratively updating) either the sea-surface height (SSH) based on a known sea-surface pressure (SSP) or visa versa. Test cases that use this module should: 1. compute maxLevelCell, bottomDepth and refBottomDepth 2. compute either seaSurfacePressure or refSSH, depending on how the upper surface is to be determined. 3. call ocn_init_ssh_and_ssp_vertical_grid to compute the appropriate z* vertical grid (layerThickness, restingThickness and zMid) 4. compute or interpolate activeTracers on the given vertical grid 5. call ocn_init_setup_ssh_and_ssp to compute the SSH from the SSP or visa versa The module enables a process for iterative correction of the SSP and/or SSH in a subsequent comment.
This PR will add a subroutine, ocn_init_vertical_grid_with_max_rx1, that re-initializes layerThickness and maxLevelCell (as well as zMid) such that the the Haney number (rx1) remains below a threshold config_rx1_max. The Haney number is approximately the number of vertical cells by which a layer is displaced between horizontal neighbors. The steeper the vertical-coordinate slope and the thinner the vertical layers, the larger rx1 becomes. The vertical coordinate is only altered in sub-ice-shelf cavities and in a buffer region nearby (within config_rx1_horiz_smooth_open_ocean_cells of an ice-shelf cavity). Elsewhere, the default z-level coordinate is maintained.
Computes initial conditions for ISOMIP test cases Adding temperature and salinity restoring to ISOMIP init Requires a mask on restoring (maskRestore), which has been initialized to 1.0 in all other init modules that use restoring. Added variables for ice sensible heat flux to ISOMIP init The landIceTemperature is currently initialized to -25 C but will not actually be used, since landIceHeatTransferVelocity=0, meaning insulating ice. including land_ice_fluxes namelist in init mode Added surface restoring for expt2 This requires adding restoring T and S values as well as piston velocities to the namelist Initialize the effective density in ISOMIP
Also, a few minor updates to the isomip test-case module to make it compatible with recent changes in the SSH/SSP initialization module.
This commit fixes an issue with the computation interval for analysis members when the output stream is set to 'none'.
This merge fixes an issue with the computation interval for analysis members when the output stream is set to 'none'.
Adding the ISOMIP test cases to init mode. The design document for this PR can be found here: https://www.dropbox.com/s/r7vjh0n9soli1no/isomipInitModule.pdf?dl=0 or here https://acme-climate.atlassian.net/wiki/display/OCNICE/Ocean:+Ice+Shelf-Ocean+Model+Intercomparison+Project+(ISOMIP)+Experiments Further documentation on the ISOMIP experiments can be found here: http://staff.acecrc.org.au/~johunter/isomip/test_cavities.pdf
Removes buoyancy surface velocity fields and summed velocities
This commit removes trailing whitespaces which are whitespaces at the end of a line before the newline.
This commit adds missing _RKIND specifiers on reals that are hard-coded. NOTE: This might not be BFB on all compilers, as some compilers might assign hard coded values a different precision than the variable they are being assigned to.
…/develop Removes buoyancy surface velocity fields and summed velocities
This commit shortens lines to be within the 132 character limit for the NAG compiler.
This merge fixes several issues related to attempting to support the NAG compiler, and some general cleanup. Only Fortran files are modified in this PR. XML files will be cleaned up next week. This merge removes trailing whitespaces, adds _RKIND to all hard coded real values, and shortens lines that are longer than 132 characters.
…evelop New option to reconstruct cell-centered low-pass filtered velocities for output. This is a straightforward way to do a "gut check" that the time filter is sufficiently configured and performing the correct operation on the flow.
Add a variable to conveniently plot time in plots of global statistics. The new variable, timeInDays, is a floating point number of days since the start of the simulation so that this timer will work across restart files. The simulation start time is taken from config_start_time if config_restart = .false. * ocean/add_time_globalStats: Add variable daysSinceStartOfSim to time loop in forward mode. Add a timer to netcdf output of global stats AM
Land ice and grounded ice fractions are also read in, and the ssh or ssp is computed from ice draft or ice thickness, respectively.
Adds a mask for the ocean so the criterion of where there is ocean and where there is land is not just determined by the topography. This can be helpful in keeping a more accurate coastline during smoothing of topography.
Global reduction was happening only one block at a time. Now, the subroutine for computing Haney number loops over blocks. The computation of the Haney Number in isomip and sub_ice_shelf_2D test cases was modified accordingly
Previously, the interpolation used layers below maxLevelCell based on the assumption that the input data was well defined in land as well. Given that maxLevelCell can change when the vertical coordinate is modified to accommodate the SSH, the old maxLevelCell must also be stored in a scratch variable.
This required some reorganization: * The init. of the restoring fields has been put in a separate subroutine because the activeTracers may have been modified when the vertical coordinate is re-initialized * Land ice must be read in before the vertical coordinate is initialized * Tracers must be initialized before ssh/ssp can be balanced * Interface for computing Haney number was modified, and Haney must be computed after vertical coordinate has been modified. A few unused fields have been removed from the global_ocean registry
…ly region code compiles, but runtime testing still needs to be performed, since the wolf supercomputer is down
testsplots show valid results for atlantic moc (handcrafted geojson file) results still bogus, though, because no signed edge mask is generated by the mask generator changed code to use unsigned edge mask instead of signed one (remember to change this back)
This commit a few floating point exception issues within the ocean.
This merge a few floating point exception issues within the ocean.
This commit refactors a loop within GM that was over the wrong element type to work better with OpenMP (but also make it bit reproducible).
This commit fixes assorted OpenMP directives that had incorrect private clauses.
This commit fixes two issues in the Ohlman 00 shortwave scheme. First, if clearSkyRadiation is ever zero, a segFault will occur, due to division by zero. A small positive number is added to prevent this. Second, there is presently no check for the necessary data arrays prior to computing extinction coefficients. If config_sw_absorption_type is set to ohlman00 and no data arrays are provided, the code will attempt to compute extinction coefficients. In this commit a check is added for these arrays, if any are missing, a warning is printed and the code is not run.
This commit removes the warning issued if config_sw_absorption_type != none and activeTracers_bulk_forcing is false. to an error in the sw_absorption_init routines
This merge makes a few modifications to the OpenMP private clauses to be more correct, and it refactors a loop within GM and updates the OpenMP directives for that loop.
This commit fixes makefile dependencies in the ocean core, to enable the ocean core to be built in parallel.
This PR fixes two issues in the Ohlman 00 shortwave scheme. First, if clearSkyRadiation is ever zero, a segFault will occur, due to division by zero. A small positive number is added to prevent this. Second, there is presently no check for the necessary data arrays prior to computing extinction coefficients. If config_sw_absorption_type is set to ohlman00 and no data arrays are provided, the code will attempt to compute extinction coefficients. In this commit a check is added for these arrays, if any are missing, a warning is printed and the code is not run. * ocean/shortWaveBugFix: Changes warning message to error and model abort Fixes a bug in variable shortwave scheme Fixes a floating point exception when ClearSkyRad is zero
This merge incorporates several framework bug fixes including allowing fields duplicated through the duplicate_field routines to be used in IO streams. Additionally, this merge fixes an issue when using single precision floats in the new exchange group halo exchanges. * MPAS-Dev/MPAS/develop: Fix issue with halo exchanges of integer fields when running with RKIND=4 Add field tests module and attribute lists test routine Update duplicate field routines to duplicate attribute lists Add routine to duplicate attribute lists
This merge fixes makefile dependencies in the ocean core, to enable the ocean core to be built in parallel.
changed some vairable names to clarify their meanings added configuration entry for transect groups general cleanups marked vars in moc_streamfunction registry that have to be removed in the future marked passages of code in moc_streamfunction.F that will have to be changed once the transect groups are defined
Test run foldersThe analysis member has been tested using the QU_120km test case. The run directory is on the turquoise network. to the stream file. |
ResultsIn addition to the Fortran code, an jupyter notebook file is included in this pull request (although it might not belong there). It is used to plot the results of the MOC stream function computations. Global MOCNorth atlantic MOCMinimum and Maximum Value against latitude for one timestep (North Atlantic)Transport through the southern boundary of the North atlantic for one timestep |
|
@DieMuhkuh, I think you want to merge onto |
|
Please take the Jupyter notebook out of this PR, and post it on a gist, and put a link to that gist in a comment here. |
|
This is great, thanks @DieMuhkuh. Would it be possible to print a few plots and bring them to the analysis framework meeting on Monday (10am in the T-DO conf room)? |




Meridional overturning circulation (MOC) stream function analysis member
This analysis member calculates the MOC stream function for the global ocean as well as a configurable set of regions. For the regional MOC, the transport through the southern border, given as a transect, is calculated.