I am currently looking for a way to modify the vertical grid scheme so that I can have increased bottom vertical grid numbers to resolve the bottom mixed layer, for example. Ideally, I would like to have a grid that has high resolution for the surface mixed layer and the bottom mixed layer, with relatively sparse points in the interior.
So I thought of starting with a vertical grid scheme similar to that of the UPWELLING case, with a seemingly exponential increase in grid spacing from the surface to the bottom. Then I would like to modify it so that I can have an exponential decrease in grid spacing from the middle of the interior to the bottom. In that case, I can have a vertical grid that have high resolution near the surface and the bottom, but with a relatively low resolution in the interior.
Now I wonder how to proceed with such a change? I looked through the ROMS manual (2018 version) and files in trunk folder, but achieved little success. Perhaps I am missing out something obvious, or due to my poor ability to disentangle the information in the code. From the manual, I found the following initial set-up files are associated with the grid:
>> ana_grid Compute the grid(s) internally.
>> get_grid Read in the curvilinear coordinate arrays as well as f and h from one NetCDF file per grid.
>> mod_grid.F This provides the storage for the model grid fields.
These appear to be relevant. So I went into the \trunk file in the ROMS folder, and I went through ana_grid.h, it doesn’t show where I can modify the vertical grid spacing/scheme. So I feel mod_grid.F might be where the information is hidden, but I can't quite figure out where it is embedded within the code (if it is).
Appreciate any advice on how to proceed with this! many thanks