|
[Sponsors] |
February 10, 2023, 05:22 |
sourceterm in EPSILON equation
|
#1 |
New Member
Lila
Join Date: Nov 2019
Posts: 7
Rep Power: 7 |
Hello,
Can anyone please tell me what is the source term (epsilonSource()) in epsilon equ stands for? ANd how is it calculated ? // Dissipation equation tmp<fvScalarMatrix> epsEqn ( fvm::ddt(alpha, rho, epsilon_) + fvm::div(alphaRhoPhi, epsilon_) - fvm::laplacian(alpha*rho*DepsilonEff(), epsilon_) == C1_*alpha()*rho()*GbyNu*Cmu_*k_() - fvm::SuSp(((2.0/3.0)*C1_ - C3_)*alpha()*rho()*divU, epsilon_) - fvm::Sp(C2_*alpha()*rho()*epsilon_()/k_(), epsilon_) + epsilonSource() + fvOptions(alpha, rho, epsilon_) ); Thank you |
|
February 11, 2023, 21:14 |
|
#2 |
Member
Join Date: Aug 2017
Location: Algeria
Posts: 98
Rep Power: 9 |
Someone can correct me if I am wrong, but I think this is used to add source terms to equations via scalarCodedSource (or vectorCodedSource) in the fvOptions file.
Here is an example with some comments: Code:
codedSource { type scalarCodedSource; selectionMode all; fields (epsilon); // You need to specify the field here, e.g. epsilon, k, etc. name my_source; codeAddSup #{ scalarField& mySource = eqn.source(); // <<<<<<< you have a reference to epsilonSource (or wharever field you've specified above) // Retrieve the cell centres const scalarField& cells = mesh_.C(); // iterate over the cells to assign the source term // Apply the source forAll(cells, i) { // cell volume specific source mySource[i] += 42; // add the expressions here }; #}; }
__________________
"When in doubt, use brute force." -- Ken Thompson |
|
February 19, 2023, 06:53 |
|
#3 |
Senior Member
|
Hi,
You can search functions at the extended code guide site. https://www.openfoam.com/documentati...des/v2112/doc/ searcheAtExtendedCodeGuide.png If you search epsilonSource, you will find each kEpsilon models have its own epsilonSource function. for instance, a epsilonSource function in a standard kEpsilon model is shown in the following link: https://www.openfoam.com/documentati...ce.html#l00069 You can use the search function at source code repositories too. https://develop.openfoam.com/search?...ory_ref=master |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Setting the height of the stream in the free channel | kevinmccartin | CFX | 12 | October 13, 2022 22:43 |
Long output in terminal. | ssa_cfd | OpenFOAM Running, Solving & CFD | 1 | March 18, 2019 06:25 |
epsilon and K blowing up. | sivakumar | OpenFOAM Running, Solving & CFD | 1 | October 25, 2012 05:50 |
value of k and epsilon in N-S equation | smith | FLUENT | 0 | September 9, 2007 06:51 |
bouyancy term in epsilon equation | Michael | Main CFD Forum | 1 | June 25, 1999 11:20 |