PySDM icon indicating copy to clipboard operation
PySDM copied to clipboard

homogeneous nucleation of liquid droplets & expansion chamber example

Open claresinger opened this issue 1 year ago • 2 comments

Copy/pasting the notes @slayoo added from our conversation with @AgnieszkaZaba this morning.

  • [x] the laboratory paper uses a Normal distribution rather than Lognormal - perhaps worth adding to PySDM
  • [x] a new ExpansionChamber environment (featuring perfect gas expansion, but not featuring hydrostatics) instead of using Parcel would help in making the code readable
  • [x] new adiabatic_exponent formulae
  • [x] a SuperParticleSpawningDynamic base-class could be best to derive from two dynamics: Seeding and HomogeneousLiquidNucleation
  • [x] rename SeedingMethods to shared SpawningMethods
  • [ ] could we construct a simple adaptive substepping logic by comparing the nucleation rate and the timestep?
  • [x] test idea: J_homogeneous table from S&P
  • [ ] test idea: long vs. short timestep
  • [ ] test idea: S_max for short vs. long timestep
  • [ ] test idea: conservation of total water
  • [ ] test idea: check droplet number matches expectation from multiplicity of nucleated SDs

The expansion chamber example is aimed to mimic the laboratory experiments described here: https://arxiv.org/abs/2501.01467

claresinger avatar Jan 07 '25 21:01 claresinger

@AgnieszkaZaba @slayoo - Any status update on the super class NewParticle and code restructure to inherit Seeding dynamic from there? Probably with that structure in place I can easily extend to make the HomogeneousLiquidNucleation dynamic. Let me know if you want to call to discuss further!

claresinger avatar Jan 14 '25 15:01 claresinger

Codecov Report

Attention: Patch coverage is 88.30409% with 20 lines in your changes missing coverage. Please review.

Project coverage is 85.24%. Comparing base (17cf24a) to head (7150f84).

Files with missing lines Patch % Lines
PySDM/environments/expansion_chamber.py 68.18% 14 Missing :warning:
PySDM/environments/impl/moist_lagrangian.py 88.88% 2 Missing :warning:
.../physics/adiabatic_exponent/moist_leading_terms.py 66.66% 2 Missing :warning:
PySDM/dynamics/homogeneous_liquid_nucleation.py 96.42% 1 Missing :warning:
PySDM/physics/adiabatic_exponent/dry.py 83.33% 1 Missing :warning:
Additional details and impacted files
@@           Coverage Diff            @@
##             main    #1492    +/-   ##
========================================
  Coverage   85.24%   85.24%            
========================================
  Files         379      389    +10     
  Lines        9297     9436   +139     
========================================
+ Hits         7925     8044   +119     
- Misses       1372     1392    +20     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Feb 14 '25 16:02 codecov[bot]