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

Bug in ice delimiter #110

Closed
DirkOlivie opened this issue Nov 8, 2023 · 3 comments
Closed

Bug in ice delimiter #110

DirkOlivie opened this issue Nov 8, 2023 · 3 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@DirkOlivie
Copy link

What happened?

There is an artificial limit on the number of ice particles.

What are the steps to reproduce the bug?

Run the standard NorESM2 code.

What CAM-Nor tag were you using?

cam_cesm2_1_rel_05-Nor_v1.0.5

What machine were you running CAM (or NorESM) on?

Betzy

What compiler were you using?

Intel

Path to a case directory, if applicable

No response

Will you be addressing this bug yourself?

No

Extra info

The subroutine micro_mg_tend in the file src/NorESM/micro_mg2_0.F90 has to be changed :

The lines

!  if (do_cldice .and. nitend(i,k).gt.0._r8.and.ni(i,k)+nitend(i,k)*deltat.gt.nimax(i,k)) then
!    nitncons(i,k) = nitncons(i,k) + nitend(i,k)-max(0._r8,(nimax(i,k)-ni(i,k))/deltat) !AL
!     nitend(i,k)=max(0._r8,(nimax(i,k)-ni(i,k))/deltat)
!  end if

should be replaced by

!shofer---
! OS Also added the term from secondary ice formation (but we don't need that now)
if (nnucct(i,k)+nnuccc(i,k)+nnudep(i,k).gt.0._r8) then
!		nimax(i,k) = nimax(i,k)+(nnucct(i,k)+nnuccc(i,k)+nnudep(i,k)+SIP_RATE(i,k))*lcldm(i,k)*deltat	
		nimax(i,k) = nimax(i,k)+(nnucct(i,k)+nnuccc(i,k)+nnudep(i,k))*lcldm(i,k)*delta
end if

if (do_cldice.and.nitend(i,k).gt.0._r8.and.ni(i,k)+nitend(i,k)*deltat.gt.nimax(i,k)) then
		nitncons(i,k) = nitncons(i,k) + nitend(i,k)-max(0._r8,(nimax(i,k)-ni(i,k))/deltat)
		nitend(i,k)=max(0._r8,(nimax(i,k)-ni(i,k))/deltat)
end if
!shofer---
@DirkOlivie DirkOlivie added the bug Something isn't working label Nov 8, 2023
@DirkOlivie DirkOlivie added this to the NorESM2.1 milestone Nov 8, 2023
@gold2718
Copy link

gold2718 commented Dec 1, 2023

BTW, I assume line 1089 is supposed to be:

nimax(i,k) = nimax(i,k)+(nnucct(i,k)+nnuccc(i,k)+nnudep(i,k))*lcldm(i,k)*deltaT

correct?

@DirkOlivie
Copy link
Author

Yes, you are right : there should be a "t".

gold2718 added a commit that referenced this issue Dec 1, 2023
Summary: Address remaining NorESM2.1 GitHub issues

Contributors: @gold2718, @DirkOlivie, @mvertens 

Reviewers: @mvertens

Purpose of changes:
-  Bug in ice delimiter (#110)
-  Aerosol dry deposition bug (#111)
-  Some outfld calls have a ncol / pcols mismatch (#112)
-  Remove preprocessorDefinitions.h (#117)

Github PR URL: #119

Changes made to build system: None

Changes made to the namelist: None

Changes to the defaults for the boundary datasets: None

Substantial timing or memory changes: None

- Fixed questionable and incorrect outfld calls
- Remove processorDefinitions.h SourceMods files
- Fix aerosol dry deposition computation (see Issue #111)
- Replace ice limiter in microphysics (see Issue #110)

test suite: aux_cam_noresm on Betzy
- Expected baseline and nlcomp differences, plus one new test:
- FAIL ERP_Ln9.f09_f09_mtn14.NF1850frc2norbc_aer2014.betzy_intel.cam-outfrq9s BASELINE cam_cesm2_1_rel_05-Nor_v1.0.7
- FAIL ERP_Ln9.f09_f09_mtn14.NF1850frc2norbc.betzy_intel.cam-outfrq9s BASELINE cam_cesm2_1_rel_05-Nor_v1.0.7
- FAIL ERP_Ln9.f09_f09_mtn14.NFHISTnorpddmsbc.betzy_intel.cam-outfrq9s BASELINE cam_cesm2_1_rel_05-Nor_v1.0.7
- FAIL ERP_Ln9.f19_f19_mtn14.F2000climo.betzy_intel.cam-outfrq9s NLCOMP
- FAIL ERP_Ln9.f19_f19_mtn14.F2000climo.betzy_intel.cam-outfrq9s BASELINE cam_cesm2_1_rel_05-Nor_v1.0.7: ERROR BFAIL baseline directory '/cluster/shared/noresm/noresm_baselines/cam_cesm2_1_rel_05-Nor_v1.0.7/ERP_Ln9.f19_f19_mtn14.F2000climo.betzy_intel.cam-outfrq9s' does not exist
- FAIL ERP_Ln9.f19_f19_mtn14.NF1850norbc_aer2014.betzy_intel.cam-aerocom NLCOMP
- FAIL ERP_Ln9.f19_f19_mtn14.NF1850norbc_aer2014.betzy_intel.cam-aerocom BASELINE cam_cesm2_1_rel_05-Nor_v1.0.7
-  FAIL ERP_Ln9.f19_f19_mtn14.NF1850norbc_aer2014.betzy_intel.cam-outfrq9s BASELINE cam_cesm2_1_rel_05-Nor_v1.0.7
- FAIL ERP_Ln9.f19_f19_mtn14.NF1850norbc.betzy_intel.cam-outfrq9s BASELINE cam_cesm2_1_rel_05-Nor_v1.0.7
- FAIL SMS_D_Ln9.f19_f19_mtn14.NF1850norbc_aer2014.betzy_intel.cam-outfrq9s BASELINE cam_cesm2_1_rel_05-Nor_v1.0.7
- FAIL SMS_D_Ln9.f19_f19_mtn14.NF1850norbc.betzy_intel.cam-outfrq9s BASELINE cam_cesm2_1_rel_05-Nor_v1.0.7

closes #110
closes #111
closes #112
closes #117
@gold2718
Copy link

gold2718 commented Dec 2, 2023

Closed by #119

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants