Spray: dual-fidelity liquid/gas phase coupling (aka Many-to-one)#633
Merged
baperry2 merged 120 commits intoAMReX-Combustion:developmentfrom Feb 18, 2026
Merged
Spray: dual-fidelity liquid/gas phase coupling (aka Many-to-one)#633baperry2 merged 120 commits intoAMReX-Combustion:developmentfrom
baperry2 merged 120 commits intoAMReX-Combustion:developmentfrom
Conversation
…anges My spray multicomponent changes
Warnings are printed by every processor.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR refactors spray species deposition so multiple liquid spray species can map to a single gas-phase species by removing the erroneous indx mapping, fully adopting dep_indx, and introducing a CSR-form mapping matrix L (plus pc_indx/N_pc) to drive phase-change coupling.
Changes:
- Replace legacy fuel→gas indexing (
indx) withdep_indxand build a CSR mapping (L_row/L_col) plus a phase-change species set (pc_indx,N_pc). - Update evaporation/source-term accumulation to work over phase-change gas species (
N_pc) rather than assuming one-to-one liquid↔gas species. - Update documentation to describe many-to-one mapping and add/adjust visualization assets.
Reviewed changes
Copilot reviewed 10 out of 15 changed files in this pull request and generated 10 comments.
Show a summary per file
| File | Description |
|---|---|
| Source/Spray/SpraySetup.cpp | Builds dep_indx, CSR mapping L, pc_indx/N_pc; adds manifold deposition-name handling and debug prints. |
| Source/Spray/SprayFuelData.H | Introduces CSR storage and helpers; changes fluid_Y_dot sizing; adds manifold index arrays. |
| Source/Spray/SprayProperties.H | Requires per-species input values when needed; updates MW initialization for many-to-one. |
| Source/Spray/SprayParticles.cpp | Accumulates species source terms over phase-change set (N_pc). |
| Source/Spray/SprayParticles.H | Applies gas-phase species source terms using pc_indx/N_pc; updates helper accessor. |
| Source/Spray/SprayJet.cpp | Tightens input parsing for jet composition array length. |
| Source/Spray/SprayInterpolation.H | Uses dep_indx when extracting chemical species from the EOS. |
| Source/Spray/Drag.H | Updates vapor/reference-state calculations to use CSR mapping and phase-change species set. |
| Source/Spray/BreakupSplash/WallFilm.H | Updates wall-film evaporation/source logic to use CSR mapping and phase-change species set. |
| Docs/sphinx/Spray.rst | Documents many-to-one mapping and manifold-model considerations; updates inputs/validation text. |
| Docs/sphinx/Visualization/nomura_res_2025.png | Adds/updates a visualization asset. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Resolved conflicts in: - Source/Spray/Drag.H: Kept many-to-one variable naming (mn_dot, X_vn, L_n) and added template syntax for amrex::min/max - Source/Spray/BreakupSplash/WallFilm.H: Kept many-to-one variable naming and added template syntax for amrex::min/max
Manifold with dual fidelity spray model
Contributor
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 12 out of 17 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
baperry2
approved these changes
Feb 17, 2026
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.

This cleans up the indexing in the spray module, specifically how liquid spray species deposit to corresponding gas-phase species. The changes include:
SPRAY_FUEL_NUM <= NUM_SPECIESrequirement. This requires molecular weights to be read in from the input file for both the GCM and MP models. Users can now have multiple spray species deposit to a single, or multiple gas-phase species.fdat.indx. This erroneously mapped species to a gas species with the exact same name regardless of howfdat.dep_indxwas defined.fdat.dep_indxThe implementation has been tested with the
SingleDropEvapvalidation cases, specifically WongLin, Daif, and the RungeJP8 tests (see PeleLMeX #593). For the WongLin and Daif cases, a test mechanism was created that mapped multiple species of heptane or decane to a single heptane or decane species (eg. NC7H16_1, NC7H16_2, ... mapped to a single NC7H16).The RungeJP8 case was tested with 67 liquid fuel components mapping to a single Hychem species for POSF10264 with and without Manifold EOS. The figure below shows results comparing the new "many-to-one" capability to a detailed mechanism for POSF10264. The PeleMP cases demonstrate the impact of using different models for saturated vapor pressure. Note that the PeleMP: Antoine Many-to-One and the PeleGCM: Many-to-One are the same because the Antoine coefficients used in the PeleMP model are generated from FuelLib, so both models have effectively the same saturated vapor pressure implementation.
To do:
SPRAY_FUEL_NUM > NUM_SPECIESas long as the molecular weights for each species is provided.SPRAY_FUEL_NUM > NUM_SPECIES (see [PeleLMeX #593](https://github.com/AMReX-Combustion/PeleLMeX/pull/593))SingleDropEvaptests to include many-to-one validation for RungeJP8 (see PeleLMeX #593)