Implementation of irrigation stream file
Description of changes
In this pull request, we added the irrigation stream file where you can customize the irrigation-related parameters. Before: Most of the irrigation-related parameters apply to all crops and all gridcells. You just need to set them in user namelist files After: Now you can give different values to irrigation-related files for different crops and different gridcells.
Specific notes
Please note that this pull request is replacing the pull request #2026
Contributors other than yourself, if any: @swensosc @samsrabin
CTSM Issues Fixed (include github issue #): #2026 It does not only fix the issue but also grants users more flexibility. In next steps, a default irrigation stream files or its generation tools may be given
Are answers expected to change (and if so in what way)?
Any User Interface Changes (namelist or namelist defaults changes)? yes. in the namelist we can add if use_irrigation_stream is true or wrong
Testing performed, if any: (List what testing you did to show your changes worked as expected) (This can be manual testing or running of the different test suites) (Documentation on system testing is here: https://github.com/ESCOMP/ctsm/wiki/System-Testing-Guide) (aux_clm on cheyenne for intel/gnu and izumi for intel/gnu/nag/pgi is the standard for tags on master)
NOTE: Be sure to check your coding style against the standard (https://github.com/ESCOMP/ctsm/wiki/CTSM-coding-guidelines) and review the list of common problems to watch out for (https://github.com/ESCOMP/CTSM/wiki/List-of-common-problems).
Some additional things upon further inspection/testing/discussion with @swensosc (some of which solve issues that predate this PR):
- [ ] In
QflxH2osfcSurf(), move the setting ofqflx_h2osfc_surf(c)= 0._r8to in front of theifloop. - [ ] Get rid of
sprinkleranddripnames; just use above/below canopy, for consistency and disambiguation. - [ ]
sfc_irrig_rate_patchshould probably just beirrig_rate_patch - [ ] To improve code readability, try to minimize the number of places that things are set. E.g.
sfc_irrig_rate_patchshould not be set in bothIrrigationModandIrrigationStreamMod. - [ ] Where things are in column loops, change them to patch loops followed by
p2c()calls. This will allow flexibility in case we ever have multiple irrigated PFTs on a single column, at the cost of more memory usage. - [ ] Add option, set on stream file, to prevent drainage for irrigated crops.
- [x] ~~Unit testing: Get test_irrigation.pf to compile.~~ Done with 6a4de49.
- [ ] Unit testing: Get
test_irrigation_suiteto pass. - [ ] Add new unit tests?
- [ ] Add system testing.
Sorry Sam I may close it accidently.
I think the "crop_fsat_equals_zero" reduces runoff for crop, so that only infiltration excess runoff occurs when it is active.
On Sun, Aug 20, 2023 at 3:15 AM YiYaoVUB @.***> wrote:
@.**** commented on this pull request.
In src/biogeophys/IrrigationMod.F90 https://github.com/ESCOMP/CTSM/pull/2102#discussion_r1299342307:
@@ -235,6 +244,9 @@ module IrrigationMod integer, parameter, public :: irrig_method_drip = 1 ! Sprinkler is applied directly to canopy integer, parameter, public :: irrig_method_sprinkler = 2
- ! Flood is applied to soil surface
- !(currently, the only difference between drip and flood is the target soil water, which can be implemented in Irrigation stream files. We leave it here in case future changes)
Yes it is true but I am still wondering in the future, the drip irrigation shall be re-designed. In the current version of the code, the drip irrigation would also cause many runoff, which is not very realistic. Just some thoughts: like applying water into the soil directly?
— Reply to this email directly, view it on GitHub https://github.com/ESCOMP/CTSM/pull/2102#discussion_r1299342307, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGRN57H4ERFB3RYFRECRSGDXWHITRANCNFSM6AAAAAA3PXECCU . You are receiving this because you were mentioned.Message ID: @.***>
my comment seems to have been placed at the bottom of the discussion, but it was: I think the "crop_fsat_equals_zero" reduces runoff for crop, so that only infiltration excess runoff occurs when it is active. So basically, I think our treatment of runoff can be handled separately from the treatment of irrigation method.
On Tue, Aug 22, 2023 at 9:53 AM Sam Rabin @.***> wrote:
@.**** commented on this pull request.
In src/biogeophys/IrrigationMod.F90 https://github.com/ESCOMP/CTSM/pull/2102#discussion_r1301857260:
@@ -235,6 +244,9 @@ module IrrigationMod integer, parameter, public :: irrig_method_drip = 1 ! Sprinkler is applied directly to canopy integer, parameter, public :: irrig_method_sprinkler = 2
- ! Flood is applied to soil surface
- !(currently, the only difference between drip and flood is the target soil water, which can be implemented in Irrigation stream files. We leave it here in case future changes)
Good point—there might eventually be a true "drip" irrigation that's distinct from a below-canopy sprinkler. @swensosc https://github.com/swensosc, what do you think?
— Reply to this email directly, view it on GitHub https://github.com/ESCOMP/CTSM/pull/2102#discussion_r1301857260, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGRN57CWECHIG5I23IEFWYTXWTIW3ANCNFSM6AAAAAA3PXECCU . You are receiving this because you were mentioned.Message ID: @.***>
There is more work to be done here. So I'm changing it to a draft. It's still important that just helps us to see what is ready to go now and what is a work in progress.
Note that, currently, the following CFTs are being merged into rice:
rice: ['cassava', 'cocoa', 'coffee', 'groundnuts', 'oilpalm', 'rice']
This may need to change once rice receives paddy irrigation.