
[Sponsors] 
March 31, 2011, 09:10 
Fixed heat flux BC in buoyantPimpleFoam

#1 
Member
Bjorn H. Hjertager
Join Date: Mar 2009
Posts: 72
Rep Power: 17 
Hi,
I am running buoyantPimpleFoam with a builtin boundary condition for heat transfer based on heat transfer coefficient (aphaWall) and outside temperature (Tinf) like this: window { type wallHeatTransfer; alphaWall uniform 1.5; Tinf uniform 263; value uniform 293.; } This work perfectly. Now I want to impose a fixed heat flux ( eg 50 W/sq m) on a patch (radiator). How do I do this in the solver? Is there a builtin BC condition for this. I know that the solver demands boundary conditions for temperature but the enthalpy is used for solving the energy equation. Can anybody give me a hint? Regards Bjorn Last edited by bhh; March 31, 2011 at 22:06. 

March 31, 2011, 10:26 

#2 
Senior Member
Aram Amouzandeh
Join Date: Mar 2009
Location: Vienna, Vienna, Austria
Posts: 190
Rep Power: 17 
Hi!
Check out this BC (for RAS turbulence models): src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature. It applies for the heated boundary patch as a temperature boundary condition like that: Code:
heatedPatch { type compressible::turbulentHeatFluxTemperature; heatSource power; q uniform 65.0; value uniform 293.0; } Aram 

March 31, 2011, 11:18 

#3 
Member
Bjorn H. Hjertager
Join Date: Mar 2009
Posts: 72
Rep Power: 17 
Hi Aram!
It works like a charm! Thank you very much rgds Bjorn 

March 31, 2011, 21:54 

#4 
Member
Bjorn H. Hjertager
Join Date: Mar 2009
Posts: 72
Rep Power: 17 
Hi Aram,
One thing that is unclear about the BC: is power q given in Watts or Watts per sq m for the patch in question? rgds Bjorn 

April 1, 2011, 03:28 

#5 
Senior Member
Aram Amouzandeh
Join Date: Mar 2009
Location: Vienna, Vienna, Austria
Posts: 190
Rep Power: 17 
hi bjorn!
see src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C lines 176  202. if you set Code:
heatSource power; Code:
heatSource flux; cheers! aram 

April 1, 2011, 04:52 

#6 
Member
Bjorn H. Hjertager
Join Date: Mar 2009
Posts: 72
Rep Power: 17 
Hi Aram,
Thanks again! This clarified the situation rgds Bjorn 

April 1, 2011, 22:41 

#7 
Member
MSR CHANDRA MURTHY
Join Date: Mar 2009
Posts: 33
Rep Power: 17 
Dear Aram,
In the calculation of gradient() [ turbulentHeatFluxTemperatureFvPatchScalarField.C, lines 180 and 185 ], effective thermal conductivity is calculated as (Cp*alphaEff). I guess it should have been (Cp*alphaEff.Rho). 

April 1, 2011, 22:44 

#8 
Member
MSR CHANDRA MURTHY
Join Date: Mar 2009
Posts: 33
Rep Power: 17 
Please read (Cp*alphaEff.Rho) as (Cp*alphaEff*Rho)


April 4, 2011, 04:02 

#9 
Senior Member
Aram Amouzandeh
Join Date: Mar 2009
Location: Vienna, Vienna, Austria
Posts: 190
Rep Power: 17 
hi!
alpha = a*rho = k/cp (kg/s/m) denotes the effective enthalpy (energy) diffusivity, whereas "a" (m^2/s) stands for the thermal diffusivity. hence, conductivity k = cp*alpha. cheers, aram 

June 7, 2011, 00:36 

#10 
Member
Kevin
Join Date: May 2011
Posts: 33
Rep Power: 14 
Code:
heatedPatch { type compressible::turbulentHeatFluxTemperature; heatSource power; q uniform 65.0; value uniform 293.0; } 

June 7, 2011, 02:51 

#11  
Senior Member
Aram Amouzandeh
Join Date: Mar 2009
Location: Vienna, Vienna, Austria
Posts: 190
Rep Power: 17 
Quote:
Code:
value uniform 293.0; Aram 

June 10, 2011, 05:24 
Setting a variable heat flux for laminar flow

#12 
Member
Matthias Hettel
Join Date: Apr 2011
Location: Karlsruhe, Germany
Posts: 31
Rep Power: 15 
Hello,
I´m relatively new in applying OpenFoam. My question is if anyone can give me an advice where I have to search if I want to apply a heat flux to walls in case of laminar flows (solver rhoSimpleFoam). I`d like to have access to all wall cells and want to set a different heat flux for every cell according to values which I get from somewhere else (measured or calculated data). I think an approach like using src/turbulenceModels/compressible/RAS/derivedFvPatchFields/turbulentHeatFluxTemperature would be right. But I can use this only for turbulent flows ? Or do you think that I could use a RAScode for laminar flow and replace the values Ap, Cpp, alphaEffp in such a manner that I get the desired heat flux? Thanks in advance for any information Matthias 

June 10, 2011, 08:44 

#13 
Member
MSR CHANDRA MURTHY
Join Date: Mar 2009
Posts: 33
Rep Power: 17 
Nearest matching BC for your requirement is timeVaryingMappedFixedValue. You have to tweak around slightly to make it timeVaryingMappedFixedHeatFlux. in base class inherit fixedGradient instead fixedValue.


June 10, 2011, 09:38 

#14 
Member
Matthias Hettel
Join Date: Apr 2011
Location: Karlsruhe, Germany
Posts: 31
Rep Power: 15 
Hi Chandramurthy,
many thanks for your reply. I got also an other advice from Aran (see above). He wrote me, that I should govern the laminar heat flux with the temperature gradient (Fourier's law) on the respective patch (fixedGradient). I`ll search in both ways ... but ... as I`m a beginner it will take a lot of time to succeed. If I will be successful I will post the result in the forum. Greetings Matthias 

June 14, 2011, 17:11 

#15 
Member
Kevin
Join Date: May 2011
Posts: 33
Rep Power: 14 
It appears that the turbulentHeatFluxTemperature only works for heat gains and not heat losses, is that correct? Or am I doing something wrong? I just tried making the "q" value a negative number, but I get a heat gain. Is there a way to make this work or am I stuck with temperature gradients?


June 15, 2011, 09:48 

#16 
Member
Matthias Hettel
Join Date: Apr 2011
Location: Karlsruhe, Germany
Posts: 31
Rep Power: 15 
Hi Kevin,
it should work in both ways (for positive and negative gradient). This would be physically and numerically right. Maybe, the code uses somewhere only the absolute value of and nobody tried it before, or you made something wrong. The flux is not independent from your coordinate system ! Be sure that you "think" in the right direction. Greetings Matthias 

June 29, 2011, 23:14 

#17 
Member
Kevin
Join Date: May 2011
Posts: 33
Rep Power: 14 
Matthais,
Sorry, I forgot that I never got back to you. You are correct that this BC handles negative heat transfer. At one point, I did see what appeared to be heat gain, but I think somehow my turbulence model was causing it to create pockets of heat (and a heat loss overall). Thanks for your help. 

June 30, 2011, 00:18 

#18 
Member
Kevin
Join Date: May 2011
Posts: 33
Rep Power: 14 
It looks like this boundary condition has changed in ver 2.0. I now get the error "Keyword K is undefined in [my boundary condition]" Anyone know what that means?


June 30, 2011, 01:18 

#19  
Senior Member
Aram Amouzandeh
Join Date: Mar 2009
Location: Vienna, Vienna, Austria
Posts: 190
Rep Power: 17 
Quote:
Code:
hotWall { type compressible::turbulentHeatFluxTemperature; heatSource flux; // power [W]; flux [W/m2] q uniform 10; // heat power or flux K basicThermo; // calculate K by alphaEff*thermo.Cp value uniform 300; // initial temperature value } Aram 

June 30, 2011, 02:00 

#20 
Member
Kevin
Join Date: May 2011
Posts: 33
Rep Power: 14 
Thanks. I didn't realize there were examples in the code for these things.
Issue now is that it's saying "KName is undefined." As you showed, that's not listed in the example. I see somewhere online that it's "CHARACTER*(*) array of species names," but I don't know what that means 

Thread Tools  Search this Thread 
Display Modes  


Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Total heat transf. rate vs Total surface heat flux  Renato Sousa  FLUENT  1  April 14, 2020 03:27 
Sign of Heat Flux at wall  Kyung  FLUENT  2  February 26, 2016 16:25 
Variable name for heat flux  peterle  CFX  4  February 13, 2014 02:21 
Heat Flux Wall Boundary Confusion.  Joee  FLUENT  1  August 21, 2010 12:20 
Heat flux in ansys cfx  juliom  OpenFOAM Running, Solving & CFD  2  April 14, 2009 14:30 