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

Solving the total energy equation

Register Blogs Community New Posts Updated Threads Search

Like Tree21Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 13, 2014, 00:07
Default
  #21
New Member
 
fairuz
Join Date: Jan 2014
Location: University of Queensland, Australia
Posts: 4
Rep Power: 12
fairuz is on a distinguished road
Quote:
Originally Posted by cliffoi View Post
Hi all,
I have spent some time looking at this and finally implemented the total enthalpy equation as follows:

volScalarField Ek = 0.5*magSqr(U);
htot = h + Ek;
htot.correctBoundaryConditions();

{
solve
(
fvm::ddt(rho, htot)
+ fvm::div(phi, htot)
- fvm::laplacian(turbulence->alphaEff(), htot)
+ fvc::laplacian(turbulence->alphaEff(), Ek)
==
fvc::ddt(p)
+ fvc::div(tau & U, "div((muEff*dev(twoSymm(fvc::grad(U))))&U)")
);
}

h = htot - Ek;
h.correctBoundaryConditions();

Here tau is the stress tensor. Even though it's small I have included it in my solver.
Note that the total enthalpy requires customized boundaries, like the gradientEnthalpyFvPatchScalarField and similar classes supplied in thermophysicalModels to get consistent solutions.
The solutions from this implementation are looking pretty good.
Going back to my previous comment, if we use enthalpy we don't have to worry about whether turbulence->alphaEff() is applicable.
Hi Ivor

So doing this is sufficient enough?Do u have done any other modification in order to correct the boundary condition?
fairuz is offline   Reply With Quote

Old   June 13, 2014, 01:44
Default
  #22
Member
 
Ivor Clifford
Join Date: Mar 2009
Location: Switzerland
Posts: 94
Rep Power: 17
cliffoi is on a distinguished road
I typically use custom boundaries for a problem like this since often we're looking to fix a temperature, velocity, heat flux or apply some other heat source/sink at the boundary, and we need to supply expressions for total enthalpy in terms of these variables . This is no different from what OpenFOAM already does for the enthalpy equation... I just customized it for my specific case.
I have attached the boundary I use that takes the temperature and velocity boundaries conditions and defines the total enthalpy in terms of these.

Regards
Ivor
Attached Files
File Type: zip totalEnthalpyFvPatchField.zip (3.8 KB, 45 views)
cliffoi 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
How to write k and epsilon before the abnormal end xiuying OpenFOAM Running, Solving & CFD 8 August 27, 2013 16:33
Error log vw.cfd OpenFOAM 6 August 7, 2009 06:44
Differences between serial and parallel runs carsten OpenFOAM Bugs 11 September 12, 2008 12:16
Unknown error sivakumar OpenFOAM Pre-Processing 9 September 9, 2008 13:53
Why FVM for high-Re flows? Zhong Lei Main CFD Forum 23 May 14, 1999 14:22


All times are GMT -4. The time now is 12:03.