Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GitHub CCPP update with VLab master changes 20190419 #237

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions physics/gfdl_cloud_microphys.F90
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,10 @@ subroutine gfdl_cloud_microphys_run( &
real(kind=kind_phys), dimension(:,:), allocatable :: den
real(kind=kind_phys) :: onebg
real(kind=kind_phys) :: tem
#ifdef TRANSITION
real(kind=kind_phys), volatile :: volatile_var
#endif


! Initialize CCPP error handling variables
errmsg = ''
Expand Down Expand Up @@ -317,10 +321,17 @@ subroutine gfdl_cloud_microphys_run( &
! calculate fraction of frozen precipitation using unscaled
! values of rain0, ice0, snow0, graupel0 (for bit-for-bit)
do i=1,im
#ifdef TRANSITION
volatile_var = rain0(i)+snow0(i)+ice0(i)+graupel0(i)
prcp0(i) = volatile_var * tem
if ( volatile_var * tem > rainmin ) then
sr(i) = (snow0(i) + ice0(i) + graupel0(i)) / volatile_var
#else
prcp0(i) = (rain0(i)+snow0(i)+ice0(i)+graupel0(i)) * tem
if ( prcp0(i) > rainmin ) then
sr(i) = (snow0(i) + ice0(i) + graupel0(i)) &
/ (rain0(i) + snow0(i) + ice0(i) + graupel0(i))
#endif
else
sr(i) = 0.0
endif
Expand Down
Loading