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

sourceterm in EPSILON equation

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 10, 2023, 05:22
Default sourceterm in EPSILON equation
  #1
Lil
New Member
 
Lila
Join Date: Nov 2019
Posts: 7
Rep Power: 7
Lil is on a distinguished road
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
Lil is offline   Reply With Quote

Old   February 11, 2023, 21:14
Default
  #2
Member
 
s1291's Avatar
 
Join Date: Aug 2017
Location: Algeria
Posts: 98
Rep Power: 9
s1291 is on a distinguished road
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
s1291 is offline   Reply With Quote

Old   February 19, 2023, 06:53
Default
  #3
Senior Member
 
shinji nakagawa
Join Date: Mar 2009
Location: Japan
Posts: 113
Blog Entries: 1
Rep Power: 18
snak is on a distinguished road
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
snak is offline   Reply With Quote

Reply


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
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


All times are GMT -4. The time now is 21:38.