Limit aerosol optics range warnings to active bins#2352
Open
saneku wants to merge 1 commit into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Limit aerosol optics range warnings to active bins
TYPE: bug fix
KEYWORDS: Mie, refractive index, diagnostics, aerosols
SOURCE: Alexander Ukhov (KAUST)
DESCRIPTION OF CHANGES:
Problem:
The aerosol optics Mie calculation clamps refractive indices to lookup-table bounds before interpolation. For empty
or nearly empty optical bins, fallback refractive indices such as (1.5,0.0) can trigger repeated range-warning
messages, especially when zero imaginary refractive index values are compared against the table's small negative
upper bound. This produces excessive log output without indicating a meaningful optical impact.
Solution:
The existing refractive-index clamping behavior is preserved. The diagnostic warning messages are now printed only when the particle number concentration in the optical bin is significant. For upper-bound imaginary-index warnings, diagnostics are also suppressed for effectively zero absorption using abs(refi).gt.1.e-12. This keeps the interpolation guard in place while avoiding warning spam from empty or trace aerosol bins. Warnings are still retained for active aerosol bins whose refractive indices fall outside the lookup-table range.
If the user still receives excessive log output, for example:
Warning: refr is smaller than lookup table range and reset to minimum bound at LW band 1
Warning: refr is smaller than lookup table range and reset to minimum bound at LW band 2
these specific warning messages can commented by the user in the source file.
LIST OF MODIFIED FILES:
M chem/module_optical_averaging.F
TESTS CONDUCTED:
Test simulations were conducted. The simulation results are unchanged, and the excessive refractive-index range warnings no longer appear in the model output.
RELEASE NOTE:
Suppresses repeated WRF-Chem aerosol optics refractive-index range warnings from empty or trace optical bins while
preserving existing Mie lookup-table clamping behavior.