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

Bug in turbulentHeatFluxTemperatureFvPatchScalarField; OF 1.6.x

Register Blogs Community New Posts Updated Threads Search

 
 
LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old   February 1, 2010, 08:40
Default Bug in turbulentHeatFluxTemperatureFvPatchScalarField; OF 1.6.x
  #1
New Member
 
Oleksiy Kurenkov
Join Date: Mar 2009
Location: Nueremberg
Posts: 16
Rep Power: 17
evrikon is on a distinguished road
Send a message via Skype™ to evrikon
Hi forum,

in OpenFoam 1.6.x the boundary condition which represents a constant heat flux through the boundary does not work for incompressible cases like buoyantBoussinesqSimpleFoam. To see the bug please have a look into

/src/turbulenceModels/incompressible/turbulentHeatFluxTemperatureFvPatchScalarField.C
:line 160

You can see:
const scalarField& Cpp =
patch().lookupPatchField<volScalarField, scalar>(CpName_);

This is not correct because an incompressible solver does not have any information about Cp.
-----------------------------------------
Here is my bugfix:

void turbulentHeatFluxTemperatureFvPatchScalarField::up dateCoeffs()
{
if (updated())
{
return;
}

const RASModel& rasModel = db().lookupObject<RASModel>("RASProperties");

const scalarField alphaEffp =
patch().lookupPatchField<volScalarField, scalar>(alphaEffName_);

// const scalarField& Cpp =
// patch().lookupPatchField<volScalarField, scalar>(CpName_);

transportModel& laminarTransport = rasModel.transport();
dimensionedScalar Cp(laminarTransport.lookup("Cp"));

gradient() = q_/(Cp.value()*alphaEffp);

fixedGradientFvPatchScalarField::updateCoeffs();
}
-------------------------------------------------------------------------------------------------
Further I specified Cp by adding one line into readTransportProperties.H for solver buoyantBoussinesqSimpleFoam:

//Bug fix OLK: Cp is needed for fixedHeatFlux boundary condition
// Heat capacity
dimensionedScalar Cp(laminarTransport.lookup("Cp"));
-------------------------------------------------------------------------------------------------
For other incompressible solvers with heat transfer it should be done too.

Now I can use the new boundary condition turbulentHeatFluxTemperature for both compressible and incompressible cases.

Cheers, Oleksiy
__________________
*************************
Cheers, Oleksiy
evrikon is offline   Reply With Quote

 


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
Error occurs when compiling OpenFoam 1.6.x with Icc fs82 OpenFOAM Bugs 5 January 20, 2010 03:08
Serious bug in LES interface fs82 OpenFOAM Bugs 21 November 16, 2009 08:15
Bug in Meshing Parameters menu Spacing1 (1e+10) Karna ANSYS Meshing & Geometry 1 October 12, 2009 14:38
Bug reports Mattijs Janssens (Mattijs) OpenFOAM 0 January 10, 2005 10:05
Forum y2k Bug Jonas Larsson Main CFD Forum 1 January 5, 2000 10:22


All times are GMT -4. The time now is 06:47.