README for Multiphase Cases Repository by HZDR

[[TOC]]

Multiphase Cases Repository by HZDR

This repository contains simulation setups of the Multiphase Cases Repository by HZDR for OpenFOAM Foundation Software 1. The simulation setups are divided into mono- and polydisperse bubbly flows utilising the set of Baseline models of HZDR2, setups using the morphology-adaptive multifield two-fluid model3 (unresolved and resolved interfaces) and miscellaneous cases.

Acknowledgement: OpenFOAM(R) is a registered trade mark of OpenCFD Limited, producer and distributor of the OpenFOAM(R) software via www.openfoam.com. The Multiphase Cases Repository by HZDR for OpenFOAM Foundation Software is not compatible with the software released by OpenCFD Limited, but is based on the software released by the OpenFOAM Foundation via www.openfoam.org.

Highlights of the Multiphase Cases Repository by HZDR

Cases using the Baseline model set by HZDR

Folder Reference for Experiment Reference for Case Setup
cases/baseline/1998_Liu Liu (1998)4 Rzehak et al. (2021)5, Kriebitzsch and Rzehak (2016)6
cases/baseline/1999_Pfleger_et_al Pfleger et al. (1999)7 :x:
cases/baseline/2000_Deen_et_al Deen et al. (2000)8 :x:
cases/baseline/2005_Lucas_et_al Lucas et al. (2005)9 Lehnigk et al. (2022)10
cases/baseline/2008_Shawkat Shawkat et al. (2008)11 Kriebitzsch and Rzehak (2016)[^8]
cases/baseline/2009_Hosokawa Hosokawa and Tomiyama (2009)12 Rzehak et al. (2021)[^15]
cases/baseline/2009_Mudde_et_al Mudde et al. (2009)13 :x:
cases/baseline/2012_Akbar_et_al Akbar et al. (2012)14 :x:
cases/baseline/2013_Hosokawa_and_Tomiyama Hosokawa and Tomiyama (2013)15 Kriebitzsch and Rzehak (2016)[^8], Liao et al. (2020)16
cases/baseline/2016_Kim_et_al Kim et al. (2016)17 Liao et al. (2020)[^10]
cases/baseline/2019_Ziegenhein_and_Lucas Ziegenhein and Lucas (2019)18 :x:

Cases using the morphology-adaptive modelling approach

Folder Reference for Experiment/Direct Numerical Simulation Reference for Case Setup
cases/multimorph/1937_Taylor_and_Green Taylor and Green (1937)19 :x:
cases/multimorph/2007_Staebler Staebler (2007)20 Tekavcic et al. (2021, 2022)21,22
cases/multimorph/2009_Hysing_et_al Hysing et al. (2009)23 Hysing et al. (2009)[^6], Meller et al. (2021)24
cases/multimorph/2014_Adelsberger_et_al :x: Adelsberger et al. (2014) 25
cases/multimorph/2014_Cubero_et_al :x: Cubero et al. (2014)26
cases/multimorph/2015_Balcazar_et_al Bhaga and Weber (1981)27, Balcazar et al. (2015)28 Meller et al. (2021)[^13]
cases/multimorph/2021_Porombka_et_al Porombka et al. (2021)29 Porombka (2023)30, Riviera (2024)31
cases/multimorph/2023_Wiedemann_et_al Wiedemann et al. (2023)32 Wiedemann et al. (2023)[^33]
cases/multimorph/hydraulicJump2D :x: :x:
cases/multimorph/plungingJetChansonEtAl2004 Chanson et al. (2004)33 Meller et al. (2024)34
cases/multimorph/risingBubbleFrederixEtAl2021/regimeII Tripathi et al. (2015)35 Frederix et al. (2021)36
cases/multimorph/risingBubbleHysingEtAl2009 :x: Meller et al. (2021, 2022)[^13],37
cases/multimorph/risingBubbleMellerEtAl2022 :x: Meller et al. (2022)[^14]
cases/multimorph/shipHullAirLubrication Elbing et al. (2008)38 :x:

Miscellaneous cases

Folder Reference for Experiment Reference for Case Setup
cases/misc/multiphase/addonMultiphaseEuler/1991_Akhtar_et_al Akhtar et al. (1991)39 Lehnigk et al. (2022)[^9]

Installation

Prerequisites

For running the cases in this repository, you need to install the software provided through the Multiphase Code Repository by HZDR for OpenFOAM Foundation Software. Depending on what you have access to

  • Helmholtz Code Base40: For Helmholtz and Friends via Helmholtz AAI41 or using a HZDR guest account
  • Rossendorf Data Repository (RODARE)[^19]: For everybody

you can install the software in several ways:

  • as Debian packages
  • by compiling from sources
  • by pulling the provided Docker or Apptainer Images

Follow the installation instructions for your preferred approach and make sure your environment is setup correctly, e.g. by running foamVersion.

General remarks

The installation instructions will use the following environment variable:

  • FOAM_RUN: directory where simulation setups are stored

Multiphase Cases Repository by HZDR from Helmholtz Code Base

Note that this repository includes content that is versioned using git-lfs42 to store large binary files in the repository

sudo apt update
sudo apt install git-lfs

After successful installation, simply clone the repository

mkdir -p $FOAM_RUN
git clone --single-branch git@codebase.helmholtz.cloud:fwdc/multiphase/cases.git $FOAM_RUN

Multiphase Cases Repository by HZDR from Rossendorf Data Repository (RODARE)

Download tar archive 43 from RODARE and unpack it

mkdir -p $FOAM_RUN
tar -xzf Multiphase-Cases-Repository-<version>.tgz -C $FOAM_RUN

Snakemake workflow for Computational Fluid Dynamics software

This repository is prepared for convenient batch processing of the contained simulation setups both on workstations and HPC systems. For information on how to install and use the system, please refer to the corresponding documentation. If you are not authorized to access it, you can build it locally by

cd $FOAM_RUN
python -m venv .venv
. .venv/bin/activate
pip install mkdocs
mkdocs build

Then open the site/index.html file in your browser.

Model Testing

For efficiently testing the influence of a certain model or parameter selection for a range of simulation setups, e.g. in the scope of a Snakemake workflow, the corresponding dictionary entry can be placed at a central location and included in individual cases using the #include directive provided by OpenFOAM.

In the following example, the lift model selection in constant/phaseProperties for a case using the addonMultiphaseEuler solver module is centralized.

lift
{
    air_dispersedIn_water
    {
        #include "~/OpenFOAM/cases/models/lift.cfg"
    }
}

The content of ~/OpenFOAM/cases/models/lift.cfg could be

type  Tomiyama;

aspectRatio
{
    type  Wellek;
}

Note: To allow parallel testing of different model selections, the directory containing the files to be included should be relative to the directory to which the Cases Repository was cloned. Globally overwriting a model via the #includeEtc is discouraged for this reason.

Quantification of the CFD Prediction Quality

A systematic analysis of results can be supported by a quantification of the agreement of simulation results and experimental data. For that purpose a fuzzy logic controller 44 is introduced that allows a comparison of two one- dimensional data sets, e.g. line samples or probes. It generates a concise value between 0 and 1 quantifying the prediction quality or performance of a simulation result. This performance evaluation is performed for all available validation data individually. For details on the fuzzy controller please checkout the mpyfuzzy utility of the multiphasepy package 45 and use mpyfuzzy --help for further options.

For plotting purposes a jupyter notebook to be found under workflow/scripts/plotCFDPerformance.ipynb can be used and a working environment for launching the notebook is provided with the multiphasepy package [^34]. Note that for the notebook script to work it has to be copied into the top-level workflow directory. The script plots the error metrics and performance results for all validation fields for the selected cases. The script also averages performance results over all the individual validation data in order to produce an overall performance value for each case, and plots this for all selected cases.

Analysing the Feature Hierarchy of Cases

Results of Model testing can be visualized using a decision tree analysis 46. Keywords describing each case and listed in the case.yml files serve as labels, while the values computed as a Quantification of the prediction quality can be used as the target feature for building decision tree models.

An automated script for plotting a decision tree from the change in performance after model testing can be found under workflow/scripts/decisionTreeAnalysis.ipynb. In order to use the script the sklearn47 package needs to be installed, everything else is provided with the multiphasepy package [^34].

Repository Structure

The repository includes the following main directories and files:

Directory Description
etc header templates for dictionaries, scripts and Snakefiles, template for case setup, keyword list
profiles contains configuration files for executing the Snakemake48 workflow locally or on a cluster
cases/baseline directory containing mono- and poly-disperse bubbly flow cases
cases/flotation directory for three-phase flotation cases
cases/misc directory for various incompressibleVoF and addonMultiphaseEuler setups with experimental data
cases/multimorph directory for cases using the morphology-adaptive modelling approach
workflow stores files relevant for batch processing with Snakemake workflow execution and report generation
codemeta.json software metadata according to The CodeMeta Project49
CONTRIBUTING.md how to contribute to the project
LICENSE licensing information
workflow.yml top-level configuration file for batch runs

How to cite us?

When using the Multiphase Cases Repository by HZDR cite as

> Haensch, S., Draw, M., Evdokimov, I., Khan, H., Kamble, V., Krull, B., Lehnigk, R., Liao, Y., Lyu, H., Meller, R., Schlegel, F., Li, S., Tekavcic, M. (2024). Multiphase Cases Repository by HZDR for OpenFOAM Foundation Software. Rodare. http://doi.org/10.14278/rodare.811 >


  1. https://doi.org/10.14278/rodare.767

  2. https://www.hzdr.de/db/Cms?pNid=121&pOid=50671

  3. https://hzdr.de/multimorph

  4. Liu, T. J. (1998, June). The role of bubble size on liquid phase turbulent structure in two-phase bubbly flow. In Proc. Third International Congress on Multiphase Flow ICMF (Vol. 98, pp. 8-12).

  5. Rzehak, R., Liao, Y., Meller, R., Schlegel, F., Lehnigk, R., & Lucas, D. (2021). Radial pressure forces in Euler-Euler simulations of turbulent bubbly pipe flows. Nuclear Engineering and Design, 374, 111079.

  6. Kriebitzsch, S., & Rzehak, R. (2016). Baseline model for bubbly flows: simulation of monodisperse flow in pipes of different diameters. Fluids, 1(3), 29.

  7. Pfleger, D., Gomes, S., Gilbert, N., & Wagner, H. G. (1999). Hydrodynamic simulations of laboratory scale bubble columns fundamental studies of the Eulerian-Eulerian modelling approach. Chemical Engineering Science, 54(21), 5091-5099.

  8. Deen, N.G., Hjertager, B.H., & Solberg, T. (2000a) Comparison of PIV and LDA Measurement Methods Applied to the Gas-Liquid Flow in a Bubble-Column. In: 10th Int. Symp. on Appl. of Laser Techniques to Fluid Mech., Lisbon, Portugal.

  9. Lucas, D., Krepper, E., & Prasser, H. M. (2005). Development of co-current air-water flow in a vertical pipe. International Journal of Multiphase Flow, 31(12), 1304-1328.

  10. Lehnigk, R., Bainbridge, W., Liao, Y., Lucas, D., Niemi, T., Peltola, J., & Schlegel, F. (2022). An open-source population balance modeling framework for the simulation of polydisperse multiphase flows. AIChE Journal, 68(3), e17539.

  11. Shawkat, M. E., Ching, C. Y., & Shoukri, M. (2008). Bubble and liquid turbulence characteristics of bubbly flow in a large diameter vertical pipe. International Journal of Multiphase Flow, 34(8), 767-785.

  12. Hosokawa, S., & Tomiyama, A. (2009). Multi-fluid simulation of turbulent bubbly pipe flows. Chemical Engineering Science, 64(24), 5308-5318.

  13. Mudde, R. F., Harteveld, W. K., and van den Akker, H. E. A., (2009). Uniform flow in bubble-columns. Industrial & Engineering Chemistry Research 48, 148-158.

  14. Akbar, M. H. M., Hayashi, K., Hosokawa, S., & Tomiyama, A. (2012). Bubble tracking simulation of bubble-induced pseudoturbulence. Multiphase Science and Technology, 24, 197-222.

  15. Hosokawa, S., & Tomiyama, A. (2013). Bubble-induced pseudo turbulence in laminar pipe flows. International journal of heat and fluid flow, 40, 97-105.

  16. Liao, Y., Upadhyay, K., & Schlegel, F. (2020). Eulerian-Eulerian two-fluid model for laminar bubbly pipe flows: Validation of the baseline model. Computers & Fluids, 202, 104496.

  17. Kim, M., Lee, J. H., & Park, H. (2016). Study of bubble-induced turbulence in upward laminar bubbly pipe flows measured with a two-phase particle image velocimetry. Experiments in Fluids, 57(4), 1-21.

  18. Ziegenhein, T. and Lucas, D. 2019. The critical bubble diameter of the lift force in technical and environmental, buoyancy-driven bubbly flows. International Journal of Multiphase Flow, 116, 26-38.

  19. Taylor, G. I., & Green, A. E. (1937). Mechanism of the production of small eddies from large ones. Proceedings of the Royal Society of London. Series A - Mathematical and Physical Sciences, 158, Article 895.

  20. Staebler, T. D. (2007). Experimentelle Untersuchung und physikalische Beschreibung der Schichtenstroemung in horizontalen Kanaelen. PhD Thesis, Universitaet Stuttgart.

  21. Tekavcic, M., Meller, R., & Schlegel, F. (2021). Validation of a morphology adaptive multi-field two-fluid model considering counter-current stratified flow with interfacial turbulence damping. Nuclear Engineering and Design, 379, 111223.

  22. Tekavcic, M., Meller, R., Krull, B., & Schlegel, F. (2022). Simulation of Liquid Waves With Flow Reversal in Stratified Counter-Current Flow With a Hybrid Multi-Fluid Model. Proceedings of the International Conference Nuclear Energy for New Europe, 31, 408.

  23. Hysing, S. R., Turek, S., Kuzmin, D., Parolini, N., Burman, E., Ganesan, S., & Tobiska, L. (2009). Quantitative benchmark computations of two-dimensional bubble dynamics. International Journal for Numerical Methods in Fluids, 60(11), 1259-1288.

  24. Meller, R., Schlegel, F., & Lucas, D. (2021). Basic verification of a numerical framework applied to a morphology adaptive multifield two-fluid model considering bubble motions. International Journal for Numerical Methods in Fluids, 93(3), 748-773.

  25. Adelsberger, J., Esser, P., Griebel, M., Gross, S., Klitz, M., & Ruettgers, A. (2014). 3D incompressible two-phase flow benchmark computations for rising droplets. In Proceedings of the 11th world congress on computational mechanics (WCCM XI), Barcelona, Spain (Vol. 179).

  26. Cubero, A., Sanchez-Insa, A., & Fueyo, N. (2014). A consistent momentum interpolation method for steady and unsteady multiphase flows. Computers & chemical engineering, 62, 96-107.

  27. Bhaga, D., & Weber, M. E. (1981). Bubbles in viscous liquids: shapes, wakes and velocities. Journal of fluid Mechanics, 105, 61-85.

  28. Balcazar, N., Lehmkuhl, O., Jofre, L., & Oliva, A. (2015). Level-set simulations of buoyancy-driven motion of single and multiple bubbles. International Journal of Heat and Fluid Flow, 56, 91-107.

  29. Porombka, P., Boden, S., Lucas, D., & Hampel, U. (2021). Horizontal annular flow through orifice studied by X-ray microtomography. Experiments in Fluids, 62, 1-14.

  30. Porombka, P. (2023). Experimental Investigation and Modelling of Annular Flow in Pipes and the Prediction of the Liquid Distribution in Compact Heat Exchangers. PhD Thesis, Technische Universitaet Dresden.

  31. Riviera, E. (2024). CFD Simulation of Horizontal Annular Flow in Simple Pipe and through an Orifice Plate using a Hybrid Morphology-Adaptive Two-Fluid Model. Master Thesis, Politecnico di Milano.

  32. Wiedemann, P., Meller, R., Schubert, M., & Hampel, U. (2023). Application of a hybrid multiphase CFD approach to the simulation of gas-liquid flow at a trapezoid fixed valve for distillation trays. Chemical Engineering Research and Design, 193, 777-786.

  33. Chanson, H., Aoki, S. I., & Hoque, A. (2004). Physical modelling and similitude of air bubble entrainment at vertical circular plunging jets. Chemical engineering science, 59(4), 747-758.

  34. Meller, R., Krull, B., Schlegel, F., & Tekavcic, M. (2024). Numerical transfer towards unresolved morphology representation in the MultiMorph model. Nuclear Engineering and Design, 428, 113470.

  35. Tripathi, M. K., Sahu, K. C., & Govindarajan, R. (2015). Dynamics of an initially spherical bubble rising in quiescent liquid. Nature communications, 6(1), 1-9.

  36. Frederix, E. M. A., Dovizio, D., Mathur, A., & Komen, E. M. J. (2021). All-regime two-phase flow modeling using a novel four-field large interface simulation approach. International Journal of Multiphase Flow, 145, 103822.

  37. Meller, R., Schlegel, F., & Klein, M. (2022). Sub-grid Scale Modelling and a-Posteriori Tests with a Morphology Adaptive Multifield Two-Fluid Model Considering Rising Gas Bubbles. Flow, Turbulence and Combustion 108, 895-922.

  38. Elbing, B. R., Winkel, E. S., Lay, K. A., Ceccio, S. L., Dowling, D. R., & Perlin, M. (2008). Bubble-induced skin-friction drag reduction and the abrupt transition to air-layer drag reduction. Journal of Fluid Mechanics, 612, 201-236. https://doi.org/10.1017/s0022112008003029

  39. Akhtar, M. K., Xiong, Y., & Pratsinis, S. E. (1991). Vapor synthesis of titania powder by titanium tetrachloride oxidation. AIChE Journal, 37(10), 1561-1570.

  40. https://codebase.helmholtz.cloud/fwdc/multiphase/code

  41. https://aai.helmholtz.de

  42. https://git-lfs.github.com

  43. https://doi.org/10.14278/rodare.811

  44. Haensch, S., Evdokimov, I. & Schlegel, F. (2021). A workflow for the sustainable development of closure models for bubbly flows. Chemical Engineering Science, 244, 116807.

  45. https://codebase.helmholtz.cloud/fwdc/python

  46. Evdokimov, I. & Haensch, S. (2021). Quality Assessment of CFD Software Using Workflows and Decision Trees. In: Ivannikov ISPRAS Open Conference, Moscow, Russian Federation.

  47. https://scikit-learn.org/stable/

  48. https://snakemake.readthedocs.io/en/stable/

  49. https://codemeta.github.io