CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

Add variable coefficient in turbulence model

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 15, 2020, 06:23
Default Add variable coefficient in turbulence model
  #1
New Member
 
Riccardo
Join Date: Sep 2020
Posts: 1
Rep Power: 0
GiordiR is on a distinguished road
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
GiordiR is offline   Reply With Quote

Old   December 1, 2020, 09:05
Default
  #2
Member
 
René Thibault
Join Date: Dec 2019
Location: Canada
Posts: 84
Rep Power: 3
Tibo99 is on a distinguished road
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.
Tibo99 is offline   Reply With Quote

Reply

Tags
implementation, turbulence models, volscalarfield

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Question about adaptive timestepping Guille1811 CFX 25 November 12, 2017 17:38
Multiphase flow - incorrect velocity on inlet Mike_Tom CFX 6 September 29, 2016 01:27
emag beta feature: charge density charlotte CFX 4 March 22, 2011 09:14
Centrifugal Pump and Turbulence Model Michiel CFX 12 January 25, 2010 03:20
Discussion: Reason of Turbulence!! Wen Long Main CFD Forum 3 May 15, 2009 09:52


All times are GMT -4. The time now is 02:29.