This repository contains a turbulence generator for inlet boundary condition, developed for OpenFOAM 2.3.X based on two papers by Kornev et al.:
N Kornev, H Kröger, J Turnow, and E Hassel. Synthesis of artificial turbulent fields with prescribed second-order statistics using the random-spot method. Proceedings in Applied Mathematics and Mechanics, 7(1):2100047-2100048, 2007.
- N Kornev, H Kröger, and E Hassel. Synthesis of homogeneous anisotropic turbulent fields with prescribed second-order statistics by the random spots method. Communications in Numerical Methods in Engineering, 24(10):875-877, 2008.
This library is developed for OpenFOAM 2.3.X, and requires the latter version of the Open Source CFD Toolbox. For more information on how to install this version, the reader is referred to this web page.
Compile the library using:
wmake libso
This will create the library libInflowTurbulence.so in your $FOAM_USER_LIBBIN folder.
Add this to the case controlDict:
libs ("libInflowTurbulence.so");
And specify for U at inlet with settings fitting your case
inlet
{
overlap 0.5; // How much the vortons can overlap each other
L 0.01; // Integral length scale
eta 1e-04; // Kolmogorov length
Cl 6.783; // Constant used for E(k) 6.783 in paper
Ceta 0.4; // Constant used for E(k) 0.4 in paper
type inflowGenerator<homogeneousTurbulence>;
fluctuationScale (1 1 1); // Fluctuation scale in each direction
referenceField uniform (10 0 0); // Reference value for inlet
R uniform (1 0 0 1 0 1); // Reynolds stress tensor
value uniform (10 0 0);
}