bug fix for FVEG scaling of canopy heat storage#87
bug fix for FVEG scaling of canopy heat storage#87cenlinhe merged 1 commit intoNCAR:release-v4.5-WRFfrom
Conversation
| @@ -4052,14 +4052,14 @@ SUBROUTINE VEGE_FLUX(parameters,NSNOW ,NSOIL ,ISNOW ,VEGTYP ,VEG , & | |||
|
|
|||
| B = SAV-IRC-SHC-EVC-TR+PAHV !additional w/m2 | |||
| ! A = FVEG*(4.0*CIR*TV**3 + CSH + (CEV+CTR)*DESTV) !volumetric heat capacity | |||
There was a problem hiding this comment.
maybe take this as a chance to remove this commented line, but maybe it's not necessary in this legacy code
|
I run a case with this bug fix in WRFv4.5 with urban option = 3 (BEM) without use_wudapt_lcz in the Southeast United States, in two nested domain, 5km and 1km for eight days. The run starts from 2015-08-02_02:00:00 but crashes at 2015-08-06_21:43:00 with the following error. d01 2015-08-06_21:43:00 3 points exceeded v_cfl = 2 in domain d01 at time 2015-08-06_21:43:00 hours |
|
This is weird. But I did identify another urban-related bug in Noah-MP driver: https://github.com/NCAR/noahmp/blob/release-v4.5-WRF/drivers/wrf/module_sf_noahmpdrv.F#L1464 This if-statement is not correct for urban_physics >0, because when urban_physics>0, Noah-MP main column model should simulate the rural portion of the grid as natural vegetation: https://github.com/NCAR/noahmp/blob/release-v4.5-WRF/drivers/wrf/module_sf_noahmpdrv.F#L926 Thus, the current code still simulates a bulk urban (i.e., urban_flag = true) for rural portion in Noah-MP for urban_physics>0 even veg_type is set to natural_veg (the urban_flag overwrites a lot of surface properties in the Noah-MP lsm code). A fix could be adding " .and. (SF_URBAN_PHYSICS == 0)" in the above if-statement for urban_flag: |
|
do you mean there is missing (i,j) even it set to natural vegetation type?! |
|
No, I meant even the vegetation type (VEGTYP) is assigned as NATURAL_TABLE, the parameters%URBAN_FLAG is still set to true. So for the rural portion of urban grid, Noah-MP main code will treat it as "urban" instead of "NATURAL_TABLE" type. You can double-check the URBAN_FLAG variable in module_sf_noahmpdrv.F file. |
|
Only looking the codes you posted here, I think urban flag is false, for urban option not equal zero and urban flag is set in TRANSFER_MP_PARAMETERS. Does I miss anything else here?! I should also set up a run to understand what is the issue. |
|
Sorry, I was wrong and you are right. The current code is correct. The parameter transfer is called after the VEGTYP is assigned. So everything is good in this part. |
|
This bug is in the version 5.0 and I have corrected it: Let me know if this fix looks good to you. (originally, noahmp%config%domain%FlagUrban is set to true as long as the grid is urban type no matter urban_physics_option is > 0 or =0. Now I only assign FlagUrban to be true when urban_physics_option=0). |
|
The fix in version 5 looks good to me, thanks! |
|
Is this a different issue? It seems that this should be moved to a different urban discussion for clarity. |
yes, should discuss elsewhere |
This is a bug fix to solve the issue: #86
Specifically, current canopy heat storage change term is not scaled by FVEG (vegetation fraction), but all the other canopy-related heat flux terms are scaled by FVEG to get the grid-level value before calculating the energy balance. So a FVEG scaling is needed to apply to the canopy heat storage change term.