|
|||||
|
|
|
#1 |
|
New Member
Valentin Mayer
Join Date: Jul 2009
Posts: 5
Rep Power: 3 ![]() |
Hello
I new in OpenFoam user and I try to get the bulk temperautre about a area. the theory: my problem tbulk = integration(U*T*dA) / integration(U*dA) the nummerical: I'm not really sure how to sovle this problem. Postprocessing or ? I think that you need a summation about the area,like: sum = sum + T(n)*U(n)*dy (Fortran 2D) How can i fixed this problem? Have somebody a idea? Thanks valentin |
|
|
|
|
|
|
|
|
#2 |
|
Senior Member
Henrik Rusche
Join Date: Mar 2009
Location: Braunschweig, Niedersachsen, Germany
Posts: 242
Rep Power: 4 ![]() |
Dear Valentin,
There are two issues. How to define the area and how to parallelise. I would also advise you to use the flux rather than the velocity since it is guaranteed to be conservative. Neglecting parallelisation issues and assuming that you want to work with patch (iP) the following will the job: Code:
heatFlux =
sum(T.boundaryField()[iP]*phi.boundaryField()[iP])/sum(phi.boundaryField()[iP]);
|
|
|
|
|
|
|
|
|
#3 |
|
New Member
Valentin Mayer
Join Date: Jul 2009
Posts: 5
Rep Power: 3 ![]() |
Hi Henrik,
sorry for this Question. But i'm not in used to work with openFoam. what means [ip] ? It is for direction, like [x]. I'm not sure if i get you wrong: Your equation mean: q=sum(t*flux)/sum(flux)=sum(t*rho*U)/sum((rho*U)) ? Is there no multiply wirh dy and dx? Thanks Valentin |
|
|
|
|
|
|
|
|
#4 | ||
|
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 1,492
Rep Power: 11 ![]() |
Quote:
Bernhard |
|||
|
|
|
|||
|
|
|
#5 |
|
Senior Member
Henrik Rusche
Join Date: Mar 2009
Location: Braunschweig, Niedersachsen, Germany
Posts: 242
Rep Power: 4 ![]() |
Dear Valentin,
thanks for your private message (in German). I hope you don't mind if I repeat what I understand is what you are trying to do. Valentin is seeking to evaluate the local Nusselt number and needs the bulk temperature to do so. The local Nusselt number would be per wall face (additional averaging may apply) and the bulk temperature is a function of the axial position in the pipe (x-coordinate in his case). The problem is now to evaluate the bulk temperature for a given axial position. Is this correct? Henrik |
|
|
|
|
|
|
|
|
#6 |
|
New Member
Valentin Mayer
Join Date: Jul 2009
Posts: 5
Rep Power: 3 ![]() |
Hello Hendriks,
that's right. I search for a summation (lilke (sum(sum( T.yz*U.yz*dy)dz)each Cells) about an area (yz).And every summation should go every cells in x-> direction. Perhaps somebody has an idea. Thanks Valentin |
|
|
|
|
|
|
|
|
#7 |
|
Senior Member
Henrik Rusche
Join Date: Mar 2009
Location: Braunschweig, Niedersachsen, Germany
Posts: 242
Rep Power: 4 ![]() |
Dear Valentin,
Okay. I would try the following. Create a lookup table for T_bulk as a function of x. To do so, you need a function that maps x into an index. Code:
scalarField vol(nCellsx, 0.0);
scalarField Tbulk(nCellsx, 0.0);
forAll(T, cellI)
{
if ( inBulkRegion(mesh.C()[cellI]) )
{
label index = floor(mesh.C()[cellI].x()/length*nCellsx);
vol[index] += mesh.V()[cellI];
Tbulkl[index] += T[cellI]*mesh.V()[cellI];
}
}
Tbulk /= vol;
This is by no means elegant, it will not parallelise easily and there are better ways of doing this. However, this will get you a long way. Henrik |
|
|
|
|
|
|
|
|
#8 |
|
New Member
Valentin Mayer
Join Date: Jul 2009
Posts: 5
Rep Power: 3 ![]() |
Hello Hendrik,
thanks a lot.Have a nice evening (in German). Bye Valentin |
|
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| UDF or any approach for Bulk Temperature calculation | vemps | FLUENT | 0 | May 1, 2009 01:09 |
| how to find bulk temperature plot and results in fluent | cadcamvijay | Main CFD Forum | 2 | March 21, 2009 01:36 |
| CFX Solver Memory Error | mike | CFX | 1 | March 19, 2008 08:22 |
| Bulk temperature for HTC extimation | Italy | CFX | 4 | July 12, 2007 00:05 |
| bulk temperature calculation | Yogesh | FLUENT | 0 | February 18, 2005 15:37 |