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

Variable T_inf for convection problem in a pipe using groovyBC

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   September 4, 2013, 13:50
Default Variable T_inf for convection problem in a pipe using groovyBC
  #1
Senior Member
 
Mojtaba.a's Avatar
 
Mojtaba Amiraslanpour
Join Date: Jun 2011
Location: Zanjan, Iran
Posts: 233
Rep Power: 7
Mojtaba.a is on a distinguished road
Send a message via Yahoo to Mojtaba.a
Hi all,
I am trying to simulate a simple pipe with constant heat flux walls, which are cooled by fluid flow going through the pipe.

Here is an image for better illustration:



Here is what I am gonna do. For wall BC I want to use:

Code:
dT/dn= (q-h*(T-T_inf))/(k_f)
In which T_inf is the average bulk temperature of the fluid, which varies across the pipe.

To calculate bulk temperature I want to use the average value of T as a variable of x (Length from the inlet).

How can I calculate this average in each x and use it as T_inf?

Is it possible to do this using groovyBC?
Attached Images
File Type: png pipe.png (10.6 KB, 21 views)
__________________
Complex Heat & Flow Simulation Research Group
If you can't explain it simply, you don't understand it well enough. "Richard Feynman"
Mojtaba.a is offline   Reply With Quote

Old   September 4, 2013, 15:08
Default
  #2
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 3,915
Rep Power: 40
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by Mojtaba.a View Post
Hi all,
I am trying to simulate a simple pipe with constant heat flux walls, which are cooled by fluid flow going through the pipe.

Here is an image for better illustration:



Here is what I am gonna do. For wall BC I want to use:

Code:
dT/dn= (q-h*(T-T_inf))/(k_f)
In which T_inf is the average bulk temperature of the fluid, which varies across the pipe.

To calculate bulk temperature I want to use the average value of T as a variable of x (Length from the inlet).

How can I calculate this average in each x and use it as T_inf?

Is it possible to do this using groovyBC?
Not the way you'd want to.

The first thing is that T_avg(s) is not really well defined after the pipe bend (BTW: convention is that x is a component of cartesian coordinates. The string length which you mean is s. At least the way I learned it). So the first thing would be to specify/calculate it for the whole geometry. Then you can calculate your T_avg(s) (for this there is actually a functionObject swakExpressionAverageDistribution in the development verson. But currently there is no way to feed that data back to your BC)
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request
gschaider is offline   Reply With Quote

Old   September 4, 2013, 15:50
Default
  #3
Senior Member
 
Mojtaba.a's Avatar
 
Mojtaba Amiraslanpour
Join Date: Jun 2011
Location: Zanjan, Iran
Posts: 233
Rep Power: 7
Mojtaba.a is on a distinguished road
Send a message via Yahoo to Mojtaba.a
Quote:
Originally Posted by gschaider View Post
Not the way you'd want to.

The first thing is that T_avg(s) is not really well defined after the pipe bend (BTW: convention is that x is a component of cartesian coordinates. The string length which you mean is s. At least the way I learned it). So the first thing would be to specify/calculate it for the whole geometry. Then you can calculate your T_avg(s) (for this there is actually a functionObject swakExpressionAverageDistribution in the development verson. But currently there is no way to feed that data back to your BC)
Thank you Bernhard.
__________________
Complex Heat & Flow Simulation Research Group
If you can't explain it simply, you don't understand it well enough. "Richard Feynman"
Mojtaba.a is offline   Reply With Quote

Old   September 4, 2013, 18:21
Default
  #4
Senior Member
 
Joachim Herb
Join Date: Sep 2010
Posts: 291
Rep Power: 9
jherb is on a distinguished road
Why don't you use the turbulentHeatFluxTemperature boundary condition?

See also buoyantBoussinesqPimpleFoam & turbulentHeatFluxTemperature
jherb is offline   Reply With Quote

Old   September 4, 2013, 19:10
Default
  #5
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 3,915
Rep Power: 40
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by jherb View Post
Why don't you use the turbulentHeatFluxTemperature boundary condition?

See also buoyantBoussinesqPimpleFoam & turbulentHeatFluxTemperature
In principle you're right. The problem is the T_inf he wants: an average of the T in the fluid. I don't think turbulentHeatFluxTemperature does that (last time I looked you specified the T_inf. It didn't get calculated from the solution)
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request
gschaider is offline   Reply With Quote

Reply

Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
GroovyBC problem in the defining inlet velocity iampolaris OpenFOAM Running, Solving & CFD 7 October 18, 2014 09:25
simple pipe problem kantipudi Main CFD Forum 2 April 7, 2008 14:30
Replace periodic by inlet-outlet pair lego CFX 3 November 5, 2002 21:09
Flow through a pipe problem Mark Wisom Main CFD Forum 4 July 25, 2002 13:20
fluid flow fundas ram Main CFD Forum 5 June 17, 2000 21:31


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