forked from E3SM-Project/E3SM
-
Notifications
You must be signed in to change notification settings - Fork 0
Apply berg flux spreading using DIB pattern #134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
matthewhoffman
wants to merge
9
commits into
E3SM-Ocean-Discussion:master
Choose a base branch
from
E3SM-Project:matthewhoffman/ice/rofi-spreading-using-dib
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Apply berg flux spreading using DIB pattern #134
matthewhoffman
wants to merge
9
commits into
E3SM-Ocean-Discussion:master
from
E3SM-Project:matthewhoffman/ice/rofi-spreading-using-dib
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This moves the calving flux from being passed to the ocean to being passed to sea ice.
The Fixx_rofi solid runoff flux has existed in the coupler for some time, but it had not been attached to MPAS-Seaice. This commit adds the connection to MPAS-Seaice in the ice_comp_mct import routine. The Fixx_rofi flux is passed to bergFreshwaterFlux. bergLatentHeatFlux is then calculated using ice temperature specified by config_iceberg_temperature. This commit also changes ice_export_mct so that Fioi_bergw/h are always exported - they will now either come from the coupler or from data.
With Fixx_rofi now being coupled to ice, the berg variables will be used all the time when running in E3SM, as opposed to just when data icebergs are active. Note that this is unlikely to be the most desirable solution; the berg variables would ideally be disabled for standalone MPAS-Seaice, but with this change they will always be allocated. I could not find an obvious way to make the package conditional on MPAS-Seaice being run within E3SM, which I think would be the preferred criterion. Also, if the solution of having the berg variables be always allocated is acceptable, then there is no longer a need for the berg package and it could be fully removed. So either way, this commit will need to be revisited.
This coupler flag is what tells the coupler to send rofi fluxes from ROF and GLC to ICE. This will allow seaice to act as a pass-through for rofi fluxes to the ocean. When an iceberg model is eventually added to MPAS-Seaice, it can redistribute icebergs before they are passed on to the ocean.
Fixx_rofi had been specified in this list when Fixx_rofi coupling was partially implemented (but not tested) years ago. However, that is the wrong variable at this point in the coupling chain - Figg_rofi is the field that needs to be remapped at this stage. Note that usually a previously defined list of variables is used at this stage, as opposed to hardcoding a variable name/list, but I am modifying the existing implementation and not changing that here.
This commit adds mapping file specifications needed to run a LR G-case. This commit should be followed up with a more complete addition for other grids.
Replace config_scale_dib_by_removed_ice_runoff option with config_dib_scale_mode option that can take on 3 values: 'none', 'removed_ice_runoff','coupler_ice_runoff'. If it's set to coupler_ice_runoff, the get_data_iceberg_fluxes routine calculates a global sum of the bergFreshwaterFlux field and uses that to scale the bergFreshwaterFluxData field (i.e., DIB). There are some to-do items in this commit: * need to know how to throw an error in MPAS-Seaice for an invalid namelist option value * logic at 3 places where "if (.not. config_use_data_icebergs) then" was removed in ice_comp_mct.F needs to be added to not do things if the coupler flux is not actually needed (i.e. if DIB is being used)
This commit does 2 things: * Most obviously, I moved the code that uses the global sum of the coupler iceberg flux to ice_comp_mct. I did this because the spreading was not occurring and I thought there might be a sequencing problem with it being called from mpas_seaice_forcing.F. By putting the scalign directly after the Fixx_rofi field is imported to bergFreshwaterFlux, it ensures there is not a lag in the scaling being applied. * Adds areaIntegAnnMeanDataIcebergFreshwaterFlux to the input stream reading DIB information. Without this, the areaIntegAnnMeanDataIcebergFreshwaterFlux field will default to 0, which could well be the explanation for why the previous commit didn't work right. So it is possible the scaling could move back to mpas_seaice_forcing.F, but I feel it is more appropriate to have it occur immediately after importing the field. However, this decision should be informed by input from other developers. This commit has some to-do items: * Currently the global sum of bergFreshwaterFlux is used for DIB scaling. This ignores the fact that bergFreshwaterFlux could exist for both ice sheets, as well as the fact that bergFreshwaterFlux is assigned value from Fixx_rofi, which as designed will include rofi from both GLC and ROF components (but ROF is not currently hooked up). It is unclear if we want the scaling/spreading to use rofi from ROF. Handling the other issue - treating AIS and GIS bergFreshwaterFlux separately - is likely to require a mask or latitude assumption combined with using multiple DIB files. Note that if we adopt the Schmidt and Mankoff DIB-by-region mappings, we could use the region masks to handle the separation between ice sheets - by appending the regions from the ice sheets, nothing about the implementation would need to know that a specific region applies to one ice sheet or the other. So it might be worth adding that to this PR and making region masks a requirement. * indentation needs cleanup
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
NOTE: IN PROGRESS
This PR introduces the ability for MPAS-Seaice to spread berg fluxes received from the coupler by a data iceberg (DIB) pattern.
This branch is currently based on #133. The new changes are only in the final two commits. Note there are a number of to-do items and design decisions discussed in those two commit messages.
After discussion with @cbegeman , I plan to rework this to use the Schmidt and Mankoff regional spreading functions. In addition to being an updated dataset relative to Merino, by using region masks it will be easy to support AIS and GIS at the same time, while also ensuring scaling does not include rofi from non-ice-sheet regions. The easiest implementation would likely replace the existing DIB code with the new, region-based version. Backwards compatibility, if desired, could be maintained by creating an input file with a single region based on Merino. Note that this approach also means that rofi from the runoff component could be handled in the same way as rofi from MALI with no additional work. (It would also be possible to not apply the data spreading functions for backwards compatibility.)