update land energy/water conservation functions#1232
update land energy/water conservation functions#1232juliasloan25 wants to merge 1 commit intomainfrom
Conversation
2bf196d to
c3fcb2c
Compare
| function Interfacer.get_field(sim::ClimaLandSimulation, ::Val{:water}, level) | ||
| surface_field = similar(sim.integrator.p.soil.sfc_scratch) | ||
| return sum( | ||
| CL.total_liq_water_vol_per_area!( |
There was a problem hiding this comment.
and one other thought is that we will need to multiply by density here or somewhere else to get mass
caeebc2 to
134102c
Compare
kmdeck
left a comment
There was a problem hiding this comment.
This looks right to me! Since sum includes the entire globe (the land domain is the entire surface, not just land), this will include a bunch of ocean points. I think that's OK for checking conservation as long as the fluxes for those points is zero (no change over time, then), but Im not sure they are (maybe coupler needs to multiply them by the land area fraction?)
The fluxes from atmosphere to land aren't multiplied by land area fraction - this would give incorrect results if we ever have fractional land fraction (though we don't right now). Maybe instead we could zero out the result of and same for water |
134102c to
50cc236
Compare
Purpose
Update integrated land conservation functions to use the ClimaLand functions introduced in CliMA/ClimaLand.jl#1071. Note that these provide the energy and water per area, so we integrate horizontally via
sum. We also convert the volumetric water content to water content.Since we don't run slabplanet + conservation checks with the integrated land, these functions aren't being exercised, but they may be nice to have in the future.