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

Integrated conjugate heat transfer solver in OpenFOAM

Register Blogs Community New Posts Updated Threads Search

Like Tree6Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   December 21, 2007, 06:06
Default Hi All, I have recently rel
  #1
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33
hjasak will become famous soon enough
Hi All,

I have recently released a top-level solver and tutorial for conjugate heat transfer simulations in OpenFOAM using a new coupled matrix approach. The new classes allow you to create a multi-mesh domain and couple equations on various meshes on a per-variable basis.

For example, in conjugate heat transfer, flow equations are solver only on a fluid mesh, while the energy equation is solved in a coupled manner for the fluid and solid domain at the matrix level.

A code snippet showing how the coupling is achieved is given below:


coupledFvScalarMatrix TEqns(2);

// Add fluid equation
TEqns.set
(
0,
new fvScalarMatrix
(
fvm::ddt(T)
+ fvm::div(phi, T)
- fvm::laplacian(DT, T)
)
);

// Add solid equation
TEqns.set
(
1,
new fvScalarMatrix
(
fvm::ddt(Tsolid) - fvm::laplacian(DTsolid, Tsolid)
)
);

TEqns.solve();


As a good object-oriented citizen I have implemented the machinery to allow arbitrary multi-mesh and multi-variable coupling: this allows you to tackle any coupled problems involving multiple meshes.

Code:

OpenFOAM-1.4.1-dev/applications/solvers/conjugate/conjugateHeatFoam

Tutorial case:

OpenFOAM-1.4.1-dev/tutorials/conjugateHeatFoam/conjugateCavity + heatedBlock

Enjoy,

Hrv
fawad likes this.
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   December 21, 2007, 07:57
Default Thak you, Hrvoje Jasak for Ope
  #2
Senior Member
 
mkraposhin's Avatar
 
Matvey Kraposhin
Join Date: Mar 2009
Location: Moscow, Russian Federation
Posts: 355
Rep Power: 21
mkraposhin is on a distinguished road
Thak you, Hrvoje Jasak for OpenFOAM! For the last month, i'm trying to couple heat transfer in solid and liquid regions (water as fluid, steel as solid), but, without success.
Where can i find links, mentioned by You in prvious post?
mkraposhin is offline   Reply With Quote

Old   December 21, 2007, 10:14
Default Hrv Congratulation for your wo
  #3
Member
 
Michele Vascellari
Join Date: Mar 2009
Posts: 70
Rep Power: 17
mighelone is on a distinguished road
Hrv Congratulation for your work!

If I well understood, is the CHT code able to support multiple fluid and solid regions, like for example two fluids separated with a solid region?

If it is so! I'd like to test the code with some CHT calculation previously done with Fluent.

Michele
mighelone is offline   Reply With Quote

Old   December 21, 2007, 18:56
Default This is why I started getting
  #4
connclark
Guest
 
Posts: n/a
This is why I started getting involved with openFoam in the first place. Now I can try and figure out how to convert my printed circuit board design files into openfoam format and model the air flow in our companies product. The timing is right too we just finished some temperature testing. We have some components getting over 118C


Hrv,

Are you sure you don't live at the north pole and have reindeer? If so thank you Santa. If not thank you any ways for the wonderful christmas present
  Reply With Quote

Old   December 21, 2007, 18:59
Default Great! Merry Christmas :-)
  #5
Senior Member
 
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,912
Rep Power: 36
alberto will become famous soon enoughalberto will become famous soon enough
Great!

Merry Christmas :-)
__________________
Alberto Passalacqua

GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as in both physical and virtual formats (current status: http://albertopassalacqua.com/?p=1541)
OpenQBMM - An open-source implementation of quadrature-based moment methods.

To obtain more accurate answers, please specify the version of OpenFOAM you are using.
alberto is offline   Reply With Quote

Old   December 22, 2007, 02:39
Default This looks great. Are there di
  #6
Senior Member
 
Michael Jaworski
Join Date: Mar 2009
Location: Champaign, IL, USA
Posts: 126
Rep Power: 17
mike_jaworski is on a distinguished road
This looks great. Are there direct links to the download, or instructions on where to get the files?

-Mike
mike_jaworski is offline   Reply With Quote

Old   December 22, 2007, 20:55
Default You can download it from the O
  #7
Senior Member
 
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,912
Rep Power: 36
alberto will become famous soon enoughalberto will become famous soon enough
You can download it from the OpenFOAM-extend project :

http://openfoam-extend.wiki.sourceforge.net/

The SVN directory of the solver is:

/trunk/Core/OpenFOAM-1.4.1-dev/applications/solvers/conjugate

Regards,
Alberto
__________________
Alberto Passalacqua

GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as in both physical and virtual formats (current status: http://albertopassalacqua.com/?p=1541)
OpenQBMM - An open-source implementation of quadrature-based moment methods.

To obtain more accurate answers, please specify the version of OpenFOAM you are using.
alberto is offline   Reply With Quote

Old   December 23, 2007, 22:45
Default Hi, Alberto, I am wondering
  #8
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 317
Rep Power: 18
hsieh is on a distinguished road
Hi, Alberto,

I am wondering if you can assist me on compiling the development version.

I have been using the standard OF on SuSE without any problem. I would like to try out the conjugate H.T. on the development version. The compilation of the development version seemed different. Is it based on FreeBSD? Would I be able to compile the development version using the same steps of the stadnard OF on SuSE? The development version uses additional utilities, such as gdb and cmake. Are these two packages needed for the development? How do I compile new solver? Will wmake still works? Can I use the same gcc compiler downloaded from the standard OF distribution?

Pei
hsieh is offline   Reply With Quote

Old   December 26, 2007, 07:59
Default hi, thanks for this nice so
  #9
Senior Member
 
Stephan Gerber
Join Date: Mar 2009
Location: Germany
Posts: 118
Rep Power: 17
stephan is on a distinguished road
hi,

thanks for this nice solver!!!!
best regards
stephan
stephan is offline   Reply With Quote

Old   December 29, 2007, 00:56
Default Pei, I have been wrestling
  #10
Senior Member
 
Michael Jaworski
Join Date: Mar 2009
Location: Champaign, IL, USA
Posts: 126
Rep Power: 17
mike_jaworski is on a distinguished road
Pei,
I have been wrestling with the development version and finally got it to build and everything working with the exception of FoamX, which I don't really need anyways. From what I can see, all the standard steps needed to compile the 1.4.1 version will apply to 1.4.1-dev. I have OpenSUSE 10.3 but I ended up following the wiki article very closely (http://openfoamwiki.net/index.php/Ho...mpile_OpenFOAM) in order to get things working. A major stumbling block was finding out I needed binutils and such. 1.4.1-dev also contains dxFoam but you only need that if you don't want to use paraFoam or some other postProcessor you may already use. If you follow the wiki page, though, precisely, things should work.

Hrv: Thank you for the solver. Is there any associated write-up or something to follow along to understand this material? When I attempt to run conjugateHeatFoam . conjugateCavity I get the following error:

--> FOAM FATAL ERROR : Attempt to cast type wall to type lduInterface

From function refCast<to>(From&)
in file /home/mjaworsk/OpenFOAM/OpenFOAM-1.4.1-dev/src/OpenFOAM/lnInclude/typeInfo.H at line 103.

FOAM aborting

I'm new to this so any help is greatly appreciated as are hints on how to better *understand* how these things work.

Thanks and best regards,
Mike
mike_jaworski is offline   Reply With Quote

Old   December 29, 2007, 09:19
Default Hi, Mike, Thanks a lot for
  #11
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 317
Rep Power: 18
hsieh is on a distinguished road
Hi, Mike,

Thanks a lot for the link to openfoamwiki. I will give it a try.

Are you using 32 bit or 64 bit SuSE? Prior to OF-1.4, gcc was installed under linuxAMD64, now it is in linux64. If you are using 64 bit SuSE, did you install gcc in linux64?

I was able to compile the development version from source on a 32 bit Ubuntu (but, dx and paraview failed). I ran the conjugateHeatFoam without any problem.

Pei
hsieh is offline   Reply With Quote

Old   December 29, 2007, 16:04
Default Pei, I have a 32bit system
  #12
Senior Member
 
Michael Jaworski
Join Date: Mar 2009
Location: Champaign, IL, USA
Posts: 126
Rep Power: 17
mike_jaworski is on a distinguished road
Pei,
I have a 32bit system. However, there are notes on compiling for 64bit a bit lower on that wiki page. I got both dx and paraview to work but I had to dig into those websites and find all their dependencies and the necessary compiler options. The other thing is going in and modifying the following files:
$HOME/OpenFOAM-1.4.1-dev/.bashrc
$HOME/OpenFOAM-1.4.1-dev/.OpenFOAM-1.4.1-dev/bashrc
$HOME/OpenFOAM-1.4.1-dev/.OpenFOAM-1.4.1-dev/apps/dxFoam/bashrc
$HOME/OpenFOAM-1.4.1-dev/.OpenFOAM-1.4.1-dev/apps/paraview/bashrc

or cshrc as the case may be. You need to alter any values to reflect the locations and version numbers of the dependencies you have. For dxFOAM, this includes the location of the openMotif libraries. For paraview, I think it expects to find cmake files in certain spots. The .bashrc file contains the pointers to the gcc files and versions, etc that you need.

For me, this whole process meant digging into dxFoam's website (www.opendx.org) to figure out all these issues and even then, there was a symlink or other issue along the way that needed to be resolved. I was able to google for most of the error messages though, and find a solution.

Good luck,
Mike
mike_jaworski is offline   Reply With Quote

Old   December 30, 2007, 11:44
Default Hi, Mike, Thanks a lot for
  #13
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 317
Rep Power: 18
hsieh is on a distinguished road
Hi, Mike,

Thanks a lot for the great help!

By following the wiki steps, I was able to compile gcc-4.2.2 on 64 bit SuSE 10.2. I am not able to compile dx and paraview successfully, but, I probably made some mistakes along the way. I also had trouble compiling dx and paraview on 32 bit Ubuntu, but, openFoam-1.4.1-dev went fine. So, I am compiling the OpenFOAM-1.4.1-dev on 64 bit SuSE 10.2 now.

Pei
hsieh is offline   Reply With Quote

Old   December 30, 2007, 15:33
Default Pei, both paraview and dx
  #14
Senior Member
 
Michael Jaworski
Join Date: Mar 2009
Location: Champaign, IL, USA
Posts: 126
Rep Power: 17
mike_jaworski is on a distinguished road
Pei,
both paraview and dx have a long list of dependencies in order to compile correctly. In particular, dx requires a number of ImageMagick libraries and openMotif libraries. Paraview requires not just cmake, but QT as well. If you're having problems with them, I recommend downloading and recompiling those libraries into the ~/OpenFOAM/linux directory and making sure those libraries are specified when you compile dx and paraview.

Also, when you ran conjugateHeatFoam, did you do so through FoamX, or command line? was there any special order/steps during mesh generation?

-Mike
mike_jaworski is offline   Reply With Quote

Old   December 30, 2007, 17:08
Default Hi, Mike, Thanks for the su
  #15
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 317
Rep Power: 18
hsieh is on a distinguished road
Hi, Mike,

Thanks for the suggestions regarding dx and paraview. I will try your suggestions later.

I am able to compile 64 version of OpenFOAM-1.4.1-dev successfully. I basically ran the tutorial, that is, conjugateCavity. I ran the case using command line, not FoamX (like you did: "conjugateHeatFoam . conjugateCavity"). I have no problem running the tutorial case, except that, I cannot view the results due to failure in dx/paraview. I did not regenerate the mesh. Mesh were already generated in the tutorial case. I am still trying to understand how to use this conjugateHeatFoam solver and how to set up new cases.

I tried SuSE 10.3 64 bit, but, had some strange problem. So, I reverted back to SuSE 10.2.

Pei
hsieh is offline   Reply With Quote

Old   December 31, 2007, 00:01
Default Pei, Thanks for letting m
  #16
Senior Member
 
Michael Jaworski
Join Date: Mar 2009
Location: Champaign, IL, USA
Posts: 126
Rep Power: 17
mike_jaworski is on a distinguished road
Pei,
Thanks for letting me know about running conjugateHeatFoam straight "out of the box". It ran, though now I'm left wondering what special items have to take place in order to build meshes and the like.
-Mike
mike_jaworski is offline   Reply With Quote

Old   December 31, 2007, 10:07
Default Hi, Mike, I am still learni
  #17
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 317
Rep Power: 18
hsieh is on a distinguished road
Hi, Mike,

I am still learning this conjugateHeatFoam solver. Right now, I am stuck installing paraview.

My guess is that, you will generate the fluid mesh and the solid mesh separately. Then, put the solid mesh under the case you are solving. What I am not sure at this point is that, is there a requirement that the mesh has to be conformal at the fluid/solid boundaries.

Another question is that, can one has several solid regions with different conductivity/heat capacity/density?

I am also curious about the efficiency of its parallel solver.

Pei
hsieh is offline   Reply With Quote

Old   January 8, 2008, 17:48
Default Hrv, I finally got aroun
  #18
connclark
Guest
 
Posts: n/a
Hrv,

I finally got around to trying your conjugateHeatFoam solver and I was trying to duplicate each step of the process using the OpenFOAM-1.4.1-dev tree. I can run your solver on the conjugateCavity case, However I can't recreate the meshes using the blockmesh command. I get an error saying "Unknown polyPatch type regionCouple for patch 'whatever' "

Are there some patches to apply to blockmesh and other utils that you could apply to the dev tree?

Thanks
Conn
  Reply With Quote

Old   January 8, 2008, 18:06
Default You have to specify the region
  #19
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33
hjasak will become famous soon enough
You have to specify the regionCouple patches by hand. Move the boundary file somewhere, create the meshes using blockMesh and then edit the two boundary files to specify the coupling. You've got the example - it is in the current boundary file.

I am still looking to sort out the user interface, but at least the solver is working properly.

Enjoy,

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   January 8, 2008, 18:07
Default P.S. Nice pets - you need a ne
  #20
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33
hjasak will become famous soon enough
P.S. Nice pets - you need a new one. May I recommend 911 Turbo, model 997?
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak 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
conjugate heat transfer ajay chandra FLUENT 3 October 26, 2010 18:14
heat transfer in conjugate heat problems cirilo Siemens 1 April 18, 2006 10:16
What's conjugate heat transfer? Larva-nymph Main CFD Forum 7 March 16, 2005 08:27
Conjugate Heat Transfer A. Roy Phoenics 1 June 26, 2002 19:35
Conjugate Heat Transfer Thomas P. Abraham Main CFD Forum 11 May 7, 1999 11:46


All times are GMT -4. The time now is 17:38.