Skip to content

Commit

Permalink
Merge branch 'feature.BGKMoleculeMixture' into 'master.dev'
Browse files Browse the repository at this point in the history
BGK for molecule mixtures with internal energies

See merge request piclas/piclas!837
  • Loading branch information
scopplestone committed Sep 1, 2023
2 parents 02a8273 + 53d19e0 commit 98d36ae
Show file tree
Hide file tree
Showing 27 changed files with 1,366 additions and 1,066 deletions.
4 changes: 2 additions & 2 deletions REGGIE.md
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@ Overview of the test cases performed every week.
| ** | Flow_N2_70degCone | ** | 2D axisymmetric 70 degree cone | nProcs=6 | Surface Sampling, includes CalcSurfaceImpact and adaptive wall temperature | [Link](regressioncheck/WEK_DSMC/Flow_N2_70degCone/readme.md) |
| ** | fully_periodic_3D | ** | Periodic boundary conditions in all three directions | nProcs=10,20,30 | Check whether particles end up outside of the domain | [Link](regressioncheck/WEK_DSMC/fully_periodic_3D/readme.md) |
| ** | Surface_Sticking_Coefficient | ** | Channel flow with a sticking coefficient model | nProcs=5 | Surface sampling | [Link](regressioncheck/WEK_DSMC/Surface_Sticking_Coefficient/readme.md) |
| 5 | Flow_N2-O2_70degCone | [BGK](regressioncheck/WEK_BGKFlow/builds.ini) | 2D axisymmetric 70 degree cone with a N2-O2 mixture | nProcs=6 | | [Link](regressioncheck/WEK_DSMC/Flow_N2-O2_70degCone/readme.md) |
| ** | Flow_N2_70degCone | ** | 2D axisymmetric 70 degree cone | nProcs=6 | | [Link](regressioncheck/WEK_DSMC/Flow_N2_70degCone/readme.md) |
| 5 | Flow_N2_70degCone | [BGK](regressioncheck/WEK_BGKFlow/builds.ini) | 2D axisymmetric 70 degree cone | nProcs=6 | | [Link](regressioncheck/WEK_DSMC/Flow_N2_70degCone/readme.md) |
| ** | MultiSpec_Supersonic_Couette_Ar-He | ** | Supersonic Couette flow with an Ar-He mixture | nProcs=5 | Temperature | [Link](regressioncheck/WEK_DSMC/MultiSpec_Supersonic_Couette_Ar-He/readme.md) |
| ** | MultiSpec_Supersonic_Couette_CO2-N2 | ** | Supersonic Couette flow with a CO2-N2 mixture | nProcs=5 | Temperature | [Link](regressioncheck/WEK_DSMC/MultiSpec_Supersonic_Couette_CO2-N2/readme.md) |
| 6 | Flow_N2_70degCone | [FP](regressioncheck/WEK_FPFlow/builds.ini) | 2D axisymmetric 70 degree cone | nProcs=6 | Surface Sampling, includes CalcSurfaceImpact | [Link](regressioncheck/WEK_DSMC/Flow_N2_70degCone/readme.md) |
11 changes: 10 additions & 1 deletion docs/documentation/references.bib
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,15 @@ @article{Pfeiffer2018b
volume = {30},
year = {2018}
}
@ARTICLE{Pfeiffer2021,
author = {Pfeiffer, Marcel and Mirza, Asim and Nizenkov, Paul},
year = "2021",
journal = "Physics of Fluids",
volume = "33",
pages = "036106",
doi = "10.1063/5.0037915",
title = {{Multi-species modeling in the particle-based ellipsoidal statistical Bhatnagar–Gross–Krook method for monatomic gas species}},
}

@article{Jun2019,
author = {Jun, Eunji and Pfeiffer, Marcel and Mieussens, Luc and Gorji, M. Hossein},
Expand Down Expand Up @@ -336,7 +345,7 @@ @article{Abe1994
}

@phdthesis{Farbar2010,
author = {Farbar, Erin D.},
author = {Farbar, Erin D.},
title = {Kinetic Simulation of Rarefied and Weakly Ionized Hypersonic Flow Fields.},
school = {University of Michigan, Horace H. Rackham School of Graduate Studies},
year = 2010,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Bhatnagar-Gross-Krook Collision Operator

The implementation of the BGK-based collision operator is based on the publications by {cite}`Pfeiffer2018a` and {cite}`Pfeiffer2018b`.
It allows the simulation of gas flows in the continuum and transitional regime, where the DSMC method is computationally too expensive.
It allows the simulation of gas flows in the continuum and transitional regimes, where the DSMC method is computationally too expensive.
The collision integral is hereby approximated by a relaxation process:

$$ \left.\frac{\partial f}{\partial t}\right|_{\mathrm{coll}} \approx \nu(f^t-f), $$
Expand All @@ -11,74 +11,59 @@ where $f^t$ is the target distribution function and $\nu$ the relaxation frequen

The current implementation supports:

- 3 different methods (i.e. different target distribution functions): Ellipsoidal Statistical, Shakov, and standard BGK
- Single species, monatomic and polyatomic gases
- Multi species, monatomic and diatomic gas mixtures
- Three different BGK methods (i.e. different target distribution functions): Ellipsoidal Statistical, Shakov, and standard BGK
- Single species: monatomic, diatomic, and polyatomic gases
- Gas mixtures with an arbitrary number of monatomic, diatomic, and polyatomic species
- Thermal non-equilibrium with rotational and vibrational excitation (continuous or quantized treatment)
- 2D/Axisymmetric simulations
- 2D axisymmetric simulations
- Variable time step (adaption of the distribution according to the maximal relaxation factor and linear scaling)

Relevant publications of the developers:

- Implementation and comparison of the ESBGK, SBGK, and Unified models in PICLas for atomic species {cite}`Pfeiffer2018a`
- Extension of the modelling to diatomic species including quantized vibrational energy treatment, validation of ESBGK with the Mach
20 hypersonic flow measurements of the heat flux on a $70^\circ$ cone {cite}`Pfeiffer2018b`
- Simulation of a nozzle expansion (including the pressure chamber) with ESBGK, SBGK and coupled ESBGK-DSMC, comparison to experimental
measurements {cite}`Pfeiffer2019a`,{cite}`Pfeiffer2019b`
- Extension to polyatomic molecules, simulation of the carbon dioxide hypersonic flow around a flat-faced cylinder, comparison of
ESBGK, SBGK and DSMC regarding the shock structure and heat flux {cite}`Pfeiffer2019c`
- Implemention of Brull's multi-species modelling using Wilke's mixture rules and collision integrals for the calculation of
transport coefficients (under review)
- Extension of the modeling to diatomic species including quantized vibrational energy treatment, validation of ESBGK with the Mach 20 hypersonic flow measurements of the heat flux on a $70^\circ$ cone {cite}`Pfeiffer2018b`
- Simulation of a nozzle expansion (including the pressure chamber) with ESBGK, SBGK and coupled ESBGK-DSMC, comparison to experimental measurements {cite}`Pfeiffer2019a`,{cite}`Pfeiffer2019b`
- Extension to polyatomic molecules, simulation of the carbon dioxide hypersonic flow around a flat-faced cylinder, comparison of ESBGK, SBGK and DSMC regarding the shock structure and heat flux {cite}`Pfeiffer2019c`
- Implemention of Brull's multi-species modeling for monatomic gas mixtures using Wilke's mixture rules and collision integrals for the calculation of transport coefficients {cite}`Pfeiffer2021`
- Extension of the implementation of Brull's ESBGK multi-species model to diatomic gas mixtures using Wilke's mixture rules (under review)
- Extension of the ESBGK method to multi-species modeling of polyatomic molecules, based on the ESBGK models of Mathiaud, Mieussens, Pfeiffer, and Brull, and including internal energies with multiple vibrational degrees of freedom, using Wilke's mixture rules and collision integrals in comparison (under review)

To enable the simulation with the BGK module, the respective compiler setting has to be activated:

PICLAS_TIMEDISCMETHOD = BGK-Flow

A parameter file and species initialization file is required, analogous to the DSMC setup. It is recommended to utilize a previous
DSMC parameter file to ensure a complete simulation setup. To enable the simulation with the BGK methods, select the BGK method,
ES (`= 1`), Shakov (`= 2`), and standard BGK (`= 3`):
A parameter file and species initialization file is required, analogous to the DSMC setup. It is recommended to utilize a previous DSMC parameter file to ensure a complete simulation setup. To enable the simulation with the BGK methods, select the BGK method, ES (`= 1`), Shakov (`= 2`), and standard BGK (`= 3`):

Particles-BGK-CollModel = 1

The **recommended method is ESBGK**. If the simulation contains a gas mixture, a choice for the determination of the transport
coefficients is available. The first model uses Wilke's mixture rules (`= 1`) to calculate the gas mixture viscosity and thermal
conductivity. The second model utilizes collision integrals (derived for the VHS model, `= 2`) to calculate these mixture properties.
While both allow mixtures with three or more components, only the implementation of Wilke's mixing rules allows diatomic molecules.
The **recommended method is ESBGK**. If the simulation contains a gas mixture, a choice for the determination of the transport coefficients is available. The first model uses Wilke's mixture rules (`= 1`) to calculate the gas mixture viscosity and thermal conductivity. The **recommended second model utilizes collision integrals** (derived for the VHS model, `= 2`) to calculate these mixture properties.

Particles-BGK-MixtureModel = 1
Particles-BGK-MixtureModel = 2

The vibrational excitation can be controlled with the following flags, including the choice between continuous and quantized
vibrational energy. Quantized vibrational energy levels are currently only available for the single-species implementation.
The vibrational excitation can be controlled with the following flags, including the choice between continuous and quantized vibrational energy.

Particles-BGK-DoVibRelaxation = T
Particles-BGK-UseQuantVibEn = T

An octree cell refinement until the given number of particles is reached can be utilized, which corresponds to an equal refinement
in all three directions (x,y,z):
An octree cell refinement can be utilized until the given number of particles is reached, which corresponds to an equal refinement in all three directions (x,y,z):

Particles-BGK-DoCellAdaptation = T
Particles-BGK-MinPartsPerCell = 10

It is recommended to utilize at least between 7 and 10 particles per (sub)cell. To enable the cell refinement above a certain number
density, the following option can be utilized
It is recommended to utilize at least between 7 and 10 particles per (sub)cell. To enable the cell refinement above a certain number density, the following option can be utilized:

Particles-BGK-SplittingDens = 1E23

A coupled BGK-DSMC simulation can be enabled, where the BGK method will be utilized if the number density $[\text{m}^{-3}]$ is
above a certain value:
A coupled BGK-DSMC simulation can be enabled, where the BGK method will be utilized if the number density $[\text{m}^{-3}]$ is above a certain value:

Particles-CoupledBGKDSMC = T
Particles-BGK-DSMC-SwitchDens = 1E22

The flag `Particles-DSMC-CalcQualityFactors` controls the output of quality factors such as mean/maximal relaxation factor (mean:
average over a cell, max: maximal value within the octree), max rotational relaxation factor, which are defined as
The flag `Particles-DSMC-CalcQualityFactors` controls the output of quality factors such as mean/maximum relaxation factor (mean: average over a cell, max: maximal value within the octree), max. rotational relaxation factor, which are defined as

$$ \frac{\Delta t}{\tau} < 1,$$

where $\Delta t$ is the chosen time step and $1/\tau$ the relaxation frequency. The time step should be chosen as such that the
relaxation factors are below unity. The `BGK_DSMC_Ratio` gives the percentage of the sampled time during which the BGK model was
utilized. In a couple BGK-DSMC simulation this variable indicates the boundary between BGK and DSMC. However, a value below 1 can
occur for pure BGK simulations due to low particle numbers, when an element is skipped.
where $\Delta t$ is the chosen time step and $1/\tau$ the relaxation frequency. The time step should be chosen as such that the relaxation factors are below unity. The `BGK_DSMC_Ratio` gives the percentage of the sampled time during which the BGK model was utilized. In a coupled BGK-DSMC simulation this variable indicates the boundary between BGK and DSMC. However, a value below 1 can occur for pure BGK simulations due to low particle numbers, when an element is skipped.

An option is available to utilize a moving average for the variables used in the calculation of the relaxation frequency:

Expand All @@ -88,7 +73,6 @@ The purpose is to increase the sample size and reduce the noise for steady gas f

Particles-BGK-MovingAverageFac = 0.01

between zero and one must be defined with which the old $M^n$ and newly sampled moments $M$ are weighted
to define the moments for the next time step $M^{n+1}$:
between zero and one must be defined with which the old $M^n$ and newly sampled moments $M$ are weighted to define the moments for the next time step $M^{n+1}$:

$$ M^{n+1}=f M+(1-f) M^n.$$
Binary file not shown.
21 changes: 0 additions & 21 deletions regressioncheck/WEK_BGKFlow/Flow_N2-O2_70degCone/DSMC.ini

This file was deleted.

7 changes: 0 additions & 7 deletions regressioncheck/WEK_BGKFlow/Flow_N2-O2_70degCone/analyze.ini

This file was deleted.

Binary file not shown.
Loading

0 comments on commit 98d36ae

Please sign in to comment.