Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Glacier surface mass balance (Flgl_qice) should be added to the budget tables in med_diag_mod

Open
#660 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
45/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Tech stack
fortran
Domain
backend

Research direction

Start by locating med_diag_mod and the budget-table code, then review discussion 344 for context. Trace the GLC-grid fluxes, icemask_coupled_fluxes, and elevation-class handling for Flgl_qice and Flgl_qice_elev. Done means the water and heat fluxes appear in the budget tables without counting excluded or already-accounted-for cells twice.

Written by the indexing model from the issue text.

Description

Emerging from https://github.com/NCAR/cesm_dev/discussions/344 - though this is something I've periodically remembered and later forgotten for a long time....

I believe that we need to add glacier surface mass balance (Flgl_qice / Flgl_qice_elev) to the budget tables. This is an output flux from lnd and an input flux to glc; there is a water flux and a corresponding heat flux.

A few things make this more challenging than other fluxes in the budget tables (and I think this is part of why we haven't already done this):

(1) In some configurations, there is a non-zero qice flux but it shouldn't be included in the budgets because it is just a diagnostic term that is already accounted for with other fluxes. This was the case for CISM in NOEVOLVE mode. Now that we're using DGLC for NOEVOLVE mode, this is less of an issue. It would still be an issue if running CISM in NOEVOLVE mode (though @mvertens is doing some work to make CISM in NOEVOLVE mode work more like DGLC's NOEVOLVE mode, in that it will handle these fluxes), or with some less common configurations (CISM options that we can perhaps ignore).

(2) Even in now-standard configurations, we still shouldn't be including qice in the budget tables for all grid cells: I think CTSM sends non-zero qice even in areas where GLC can't handle these fluxes (as determined by icemask_coupled_fluxes); in these places, CTSM also sends an equivalent flux to the river; so including qice in the budget tables in these locations would be double-counting.

(3) QICE from LND is broken down by elevation class, so requires some custom code to make global averages (weighting each elevation class appropriately). (This could possibly be worked around by using the field mapped to the GLC grid, and not trying to work with the field on the LND grid.)

My initial thought on how to handle all this is: compute this piece of the budgets on the GLC grid rather than the LND grid; that will deal with point (3) (this wouldn't allow us to check the conservation of the lnd->glc mapping with the budget tables, but I think that's a reasonable price to pay). Multiply the GLC grid cell values by Sg_icemask_coupled_fluxes in computing the budget numbers; this will deal with both points (1) and (2).

Dominant language
Fortran
Stars
36
Forks
107
Avg merge
1d 2h
Merged PRs (30d)
3

Getting set up

  • No Dockerfile or Docker Compose file
  • Has a pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from ESCOMP/CMEPS

All issues in ESCOMP/CMEPS

Similar issues

More Backend & API Design issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.