replace rd_insol with soluble_fraction - #89
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates the parcel-model aerosol JSON interface by replacing the rd_insol field with a soluble-fraction field, and propagates that change through argument validation, microphysics initialization, and the test suite.
Changes:
- Replace aerosol JSON key
rd_insolwithsol_fracacross runtime code and tests. - Update aerosol argument validation and parcel() documentation/defaults to require/describe the new field.
- Remove the tracked generated plot output
plots/outputs/plot_schemes_ice.svg.
Reviewed changes
Copilot reviewed 12 out of 13 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
parcel.py |
Updates default aerosol JSON and docstring examples/field description to sol_frac. |
parcel_common.py |
Updates aerosol argument validation keys and range-checks for sol_frac (0–1). |
micro_lgrngn.py |
Updates the dry distribution keying to use (kappa, sol_frac) instead of (kappa, rd_insol). |
unit_test/test_RH.py |
Updates aerosol JSON used in RH test to use sol_frac. |
unit_test/test_moments.py |
Updates aerosol JSON fixture to use sol_frac. |
unit_test/test_init.py |
Updates parametrized aerosol inputs to use sol_frac. |
unit_test/test_chem_henry.py |
Updates aerosol JSON used for chemistry Henry-law test to use sol_frac. |
long_test/test_timestep.py |
Updates aerosol JSON used in timestep long test to use sol_frac. |
long_test/test_plot_schemes_ice.py |
Updates aerosol JSON used in ice-schemes plotting test to use sol_frac. |
long_test/test_plot_ice_SD.py |
Updates loop variable and aerosol JSON to use sol_frac for plot-generation runs. |
long_test/test_ice_SD.py |
Updates aerosol JSON used in reference-comparison long test to use sol_frac. |
chem_conditions.py |
Updates chemistry test conditions aerosol JSON construction to use sol_frac. |
plots/outputs/plot_schemes_ice.svg |
Removes a previously committed generated plot artifact. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
72
to
79
| aerosol (Optional[json str]): dict of dicts defining aerosol distribution, e.g.: | ||
|
|
||
| {"ammonium_sulfate": {"kappa": 0.61, "rd_insol": 0.0, "mean_r": [0.02e-6, 0.07e-7], "gstdev": [1.4, 1.2], "n_tot": [120.0e6, 80.0e6]} | ||
| "gccn" : {"kappa": 1.28, "rd_insol": 0.0, "mean_r": [2e-6], "gstdev": [1.6], "n_tot": [1e2]}} | ||
| {"ammonium_sulfate": {"kappa": 0.61, "sol_frac": 1.0, "mean_r": [0.02e-6, 0.07e-7], "gstdev": [1.4, 1.2], "n_tot": [120.0e6, 80.0e6]} | ||
| "gccn" : {"kappa": 1.28, "sol_frac": 1.0, "mean_r": [2e-6], "gstdev": [1.6], "n_tot": [1e2]}} | ||
|
|
||
| where kappa - hygroscopicity parameter (see doi:10.5194/acp-7-1961-2007) | ||
| rd_insol - insoluble dry radius | ||
| sol_frac - soluble volume fraction (0-1) | ||
| mean_r - lognormal distribution mean soluble dry radius [m] (list if multimodal distribution) |
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.
No description provided.