# Add variable coefficient in turbulence model

 Register Blogs Members List Search Today's Posts Mark Forums Read

 September 15, 2020, 06:23 Add variable coefficient in turbulence model #1 New Member   Riccardo Join Date: Sep 2020 Posts: 1 Rep Power: 0 Hi everyone, I need to add a variable parameter in front of the production term of the omega equation in the k-omega turbulence model. It should be like D omega / Dt = beta(x,y) * P(k,omega,U) - D(k,omega;U) + T(k,omega,U) I'm new to OpenFoam so i thought to add a volScalarField betaNew kOmega.H as volScalarField betaNew = 1; kOmega.C as betaNew ( IOobject ( "betaNew", this->runTime.timeName(), this->mesh_, IOobject::NO_READ, IOobject::AUTO_WRITE ) this->mesh_ ) What I'm trying to do is: - initialize betaNew as unit over the domain - print its distribution on a file - modify its distribution somehow - run the case providing a different distribution Thank you all

 December 1, 2020, 09:05 #2 Senior Member   René Thibault Join Date: Dec 2019 Location: Canada Posts: 114 Rep Power: 6 Hi Riccardo! Did you find a solution about what you trying to do? I'm working on something similar, but with the k-epsilon model, and I'm still working on it. I found something on GitHub about adding a source term in a turbulence model, but the source term is a scalar not function of 'x', 'y' and 'z'. It is relatively simple to understand, but because our variable is function of 'x', 'y' (and possibly 'z'), it's less complicated compare of what we're trying to attempt. In case you're interested, here is the link: https://github.com/AndreaDesan/LaunderSharmaKEYap Applying correction to the k-e transport equation Distance of a 'North' and 'South' surface of a cell for 2D mesh Last edited by Tibo99; December 1, 2020 at 14:19.

 Tags implementation, turbulence models, volscalarfield