Closed grantfirl closed 2 years ago
@JongilHan66 Please review the changes in SAS and see the description of the problem solved by @matusmartini in the PR description.
@JongilHan66 Please review the changes in SAS and see the description of the problem solved by @matusmartini in the PR description. 1) to limit overshooting not to be deeper than the actual cloud, please initially set ktcon1(i)=ktcon(i) in addtion to matusmartini's changes [currrently ktcon1(i)=kmax(i) in samfdeepcnv.f and ktcon1(i)=kmax(i)-1 in sascnvn_run].
2) please do not limit q1, i.e., remove those changes in lines 3060-3061 of samfdeepcnv.f and lines 1882-1883 of sascnvn_run. This limit would cause a problem in global total water conservation. Also, any possible negative q1 is effectively removed in the latest samfdeepcnv version without hurting total water conservation.
@JongilHan66 Please review the changes in SAS and see the description of the problem solved by @matusmartini in the PR description.
- to limit overshooting not to be deeper than the actual cloud, please initially set ktcon1(i)=ktcon(i) in addtion to matusmartini's changes [currrently ktcon1(i)=kmax(i) in samfdeepcnv.f and ktcon1(i)=kmax(i)-1 in sascnvn_run].
- please do not limit q1, i.e., remove those changes in lines 3060-3061 of samfdeepcnv.f and lines 1882-1883 of sascnvn_run. This limit would cause a problem in global total water conservation. Also, any possible negative q1 is effectively removed in the latest samfdeepcnv version without hurting total water conservation.
Sure, @JongilHan66, I can make those changes. @matusmartini Do you think this modification will suit your purposes?
@JongilHan66 @matusmartini We could also potentially add a flag to control whether this overshooting limiter is active. Thoughts?
Since the overshooting layers are smaller than the cloud depth most of time, I don't think adding a flag for the overshooting limiter is necessary.
@JongilHan66 Can you verify that https://github.com/NCAR/ccpp-physics/pull/954/commits/19440817b331576b7696bd2cc2dd732f62ba9682 is what you had in mind please?
Yes, your modification is what I had in mind.
@JongilHan66 Please review the changes in SAS and see the description of the problem solved by @matusmartini in the PR description.
- to limit overshooting not to be deeper than the actual cloud, please initially set ktcon1(i)=ktcon(i) in addtion to matusmartini's changes [currrently ktcon1(i)=kmax(i) in samfdeepcnv.f and ktcon1(i)=kmax(i)-1 in sascnvn_run].
- please do not limit q1, i.e., remove those changes in lines 3060-3061 of samfdeepcnv.f and lines 1882-1883 of sascnvn_run. This limit would cause a problem in global total water conservation. Also, any possible negative q1 is effectively removed in the latest samfdeepcnv version without hurting total water conservation.
Sure, @JongilHan66, I can make those changes. @matusmartini Do you think this modification will suit your purposes?
This looks good! @grantfirl Thank you! @JongilHan66
@JongilHan66 Please review the changes in SAS and see the description of the problem solved by @matusmartini in the PR description.
- to limit overshooting not to be deeper than the actual cloud, please initially set ktcon1(i)=ktcon(i) in addtion to matusmartini's changes [currrently ktcon1(i)=kmax(i) in samfdeepcnv.f and ktcon1(i)=kmax(i)-1 in sascnvn_run].
- please do not limit q1, i.e., remove those changes in lines 3060-3061 of samfdeepcnv.f and lines 1882-1883 of sascnvn_run. This limit would cause a problem in global total water conservation. Also, any possible negative q1 is effectively removed in the latest samfdeepcnv version without hurting total water conservation.
Sure, @JongilHan66, I can make those changes. @matusmartini Do you think this modification will suit your purposes?
This looks good! @grantfirl Thank you! @JongilHan66
I've looked into the overshoot modification and found a problem. The line, 'tem1=zi(i,ktcon1(i))-zi(i,ktcon(i))', should be changed to 'tem1=zi(i,k)-zi(i,ktcon(i))' in both samfdeepcnv & sascnvn.
@JongilHan66 Please review the changes in SAS and see the description of the problem solved by @matusmartini in the PR description.
- to limit overshooting not to be deeper than the actual cloud, please initially set ktcon1(i)=ktcon(i) in addtion to matusmartini's changes [currrently ktcon1(i)=kmax(i) in samfdeepcnv.f and ktcon1(i)=kmax(i)-1 in sascnvn_run].
- please do not limit q1, i.e., remove those changes in lines 3060-3061 of samfdeepcnv.f and lines 1882-1883 of sascnvn_run. This limit would cause a problem in global total water conservation. Also, any possible negative q1 is effectively removed in the latest samfdeepcnv version without hurting total water conservation.
Sure, @JongilHan66, I can make those changes. @matusmartini Do you think this modification will suit your purposes?
This looks good! @grantfirl Thank you! @JongilHan66
I've looked into the overshoot modification and found a problem. The line, 'tem1=zi(i,ktcon1(i))-zi(i,ktcon(i))', should be changed to 'tem1=zi(i,k)-zi(i,ktcon(i))' in both samfdeepcnv & sascnvn.
Inboth samfdeepcnv & sascnvn, please modify them to more compact form and overshooting not to be deeper than half of the actual cloud as:
if(aa2(i) < 0.) then
ktcon1(i) = k
flg(i) = .false.
endif
!NRL MNM: Limit overshooting not to be deeper than the actual cloud
tem = zi(i,ktcon(i))-zi(i,kbcon(i))
tem1 = zi(i,ktcon1(i))-zi(i,ktcon(i))
if(tem1.ge.tem) then
ktcon1(i) = k
flg(i) = .false.
endif
==>
tem = 0.5 * (zi(i,ktcon(i))-zi(i,kbcon(i)))
tem1 = zi(i,k)-zi(i,ktcon(i))
!NRL MNM: Limit overshooting not to be deeper than half of the actual cloud if(aa2(i) < 0. .or. tem1 >= tem) then ktcon1(i) = k flg(i) = .false. endif
Thank you.
@JongilHan66 I think that I addressed your comments in https://github.com/NCAR/ccpp-physics/pull/954/commits/4cd35abbfca7f783e2e284ab1f597d15c6cb11bc if you'd like to verify.
@grantfirl I confirm the changes are correct and what I meant.
All of these changes originally came from https://github.com/NCAR/ccpp-physics/pull/772. These changes were split from the single precision work since they were unrelated, but they're still relevant and should be merged since they fix several bugs. @michalakes, @areinecke, and @matusmartini deserve the credit. My work was only to update it to the latest main and test it in FV3/SCM.
The first 4 commits do not change any UFS RT results. They represent the following:
The last commit introduces a change to SAS-based deep convection schemes to avoid negative qv. Any UFS RTs that use samfdeepcnv or sascnvn will need new baselines if this is merged. The following description is from @matusmartini: