|
[Sponsors] |
Why ESI and Foundation have different k-epsilon implementation? |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
February 19, 2024, 08:50 |
Why ESI and Foundation have different k-epsilon implementation?
|
#1 |
Member
Marķa Rosales
Join Date: Mar 2023
Location: Spain
Posts: 48
Rep Power: 3 |
Dear community, maybe my math skills are not current enough to confirm these 02 implementations are the same. Please check with me the production term and the FIRST term in the right side of the dissipation rate equation that for both software, are not the same, or are they?:
In openfoam ESI either 2012 or 2306 we have for production term: Code:
const volScalarField::Internal divU (fvc::div(fvc::absolute(this->phi(), U))().v() ); tmp<volTensorField> tgradU = fvc::grad(U); const volScalarField::Internal GbyNu ( this->type() + ":GbyNu", tgradU().v() && dev(twoSymm(tgradU().v())) ); const volScalarField::Internal G(this->GName(), nut()*GbyNu); tgradU.clear(); Code:
// 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_) ); In openfoam Foundation 9, we have for production term: Code:
volScalarField::Internal divU ( fvc::div(fvc::absolute(this->phi(), U))() ); tmp<volTensorField> tgradU = fvc::grad(U); volScalarField::Internal G ( this->GName(), nut()*(dev(twoSymm(tgradU().v())) && tgradU().v()) ); tgradU.clear(); Code:
// Dissipation equation tmp<fvScalarMatrix> epsEqn ( fvm::ddt(alpha, rho, epsilon_) + fvm::div(alphaRhoPhi, epsilon_) - fvm::laplacian(alpha*rho*DepsilonEff(), epsilon_) == C1_*alpha()*rho()*G*epsilon_()/k_() - fvm::SuSp(((2.0/3.0)*C1_ - C3_)*alpha()*rho()*divU, epsilon_) - fvm::Sp(C2_*alpha()*rho()*epsilon_()/k_(), epsilon_) + epsilonSource() + fvModels.source(alpha, rho, epsilon_) ); 1) In the section of Production G definition in ESI version, these variables are set as constants, would this imply they won't be modifiable while running the simulation? 2) Curiousity, is this math operation conmmutative of dot products commutative in order to asume that both source codes 'implements the same' ? ESI: const volScalarField::Internal GbyNu ( IOobject::scopedName(this->type(), "GbyNu"), tgradU().v() && devTwoSymm(tgradU().v()) ); const volScalarField::Internal G(this->GName(), nut()*GbyNu); Foundation: volScalarField::Internal G ( this->GName(), nut()*(dev(twoSymm(tgradU().v())) && tgradU().v()) ); 3) The first term in RHS of dissipation equation... both are the same, right? ESI: C1_*alpha()*rho()*GbyNu*Cmu_*k_() Foundation: C1_*alpha()*rho()*G*epsilon_()/k_() I'd truly appreciate any clarification. Last edited by MMRC; February 19, 2024 at 16:25. Reason: Improving redaction |
|
February 29, 2024, 08:09 |
|
#2 |
Member
Marķa Rosales
Join Date: Mar 2023
Location: Spain
Posts: 48
Rep Power: 3 |
Hello community,
I solved my inquiry. Even though ESI and Foundation looks different in code implementation, at the end is the same. I tested by changing the definition of G and the first term of the RHS of transport of epsilon, in different tests and it prompts the same. My inquiry came from the trying to implement a new type of turbulence model based on k-e and changing the way of cumputing nut. My first experience was getting different results than expected, and the issue was in these lines of code where my modified nut was not considered because old definition was used. |
|
February 29, 2024, 08:39 |
|
#3 | |||
Senior Member
Join Date: Apr 2020
Location: UK
Posts: 736
Rep Power: 14 |
Quote:
Quote:
Quote:
|
||||
February 29, 2024, 10:27 |
|
#4 |
Member
Marķa Rosales
Join Date: Mar 2023
Location: Spain
Posts: 48
Rep Power: 3 |
Hola Tobermory, I trully appreciate your reply, thanks for the clarifications.
Quote:
|
|
Tags |
kepsilon, openfoam, source code |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Formulation in compressibleInterFoam | scttmllr | OpenFOAM Running, Solving & CFD | 72 | June 26, 2023 08:42 |
[solidMechanics] Support thread for "Solid Mechanics Solvers added to OpenFOAM Extend" | bigphil | OpenFOAM CC Toolkits for Fluid-Structure Interaction | 686 | December 22, 2022 10:10 |
OpenFOAM version switch from ESI to Foundation | vronti | OpenFOAM | 1 | May 2, 2022 04:48 |
AMI implementation: Foundation vs. ESI | heksel8i | OpenFOAM Programming & Development | 1 | July 1, 2021 12:53 |
Overview on the different OF-players like "CFD Direct" or OpenCFD Ltd (ESI Group) | elvis | OpenFOAM | 4 | August 16, 2017 15:34 |