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

Problem with porous media

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

Like Tree1Likes
  • 1 Post By wyldckat

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 25, 2016, 05:31
Default Problem with porous media
  #1
New Member
 
Lisa
Join Date: Dec 2015
Posts: 8
Rep Power: 10
Lisl is on a distinguished road
Hello foamers,

I have a Problem with my porousSimpleFoam case. In the attached Picture you can see a cylinder located in a box. I want to generate a flow through the box. The cylinder has a porosity i defined in porosity properties. My Problem is that OpenFoam seems to ignore my porous media because there is no velocity in the cylinder (i can see that when i do a plot over line for the velocity in paraView)

The box and the cylinder are two different meshes. I generated both with snappyHexMesh and merged them into one case for my simulations with porousSimpleFoam..
Do you think there could be a Problem?

Thanks!
Attached Images
File Type: png cell_Modell1.png (161.9 KB, 113 views)
Lisl is offline   Reply With Quote

Old   January 31, 2016, 13:51
Default
  #2
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,974
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quick answer: If you only merged the two meshes, then they are technically considered by OpenFOAM has being two completely independent regions, even if they are overlapped over each other.

You will need to use one of the following solutions:
  1. Stitch the two meshes together, which requires that the two meshes complement each other.
  2. To use AMI boundary conditions, for establishing the boundary connections between each mesh.
  3. To mesh the two regions in a single meshing operation, where the internal cylinder is meshed as a cellZone and the porosity is later assigned with an fvOption.
  4. To follow the same case set-up as the tutorial "heatTransfer/chtMultiRegionSimpleFoam/heatExchanger" that is available at least since OpenFOAM 3.0.
svramana likes this.
__________________
wyldckat is offline   Reply With Quote

Old   February 1, 2016, 03:56
Default
  #3
New Member
 
Lisa
Join Date: Dec 2015
Posts: 8
Rep Power: 10
Lisl is on a distinguished road
Thank you very much for your quick answer!

I tried the stitchMesh Utility but i get the following error:


--> FOAM FATAL ERROR:
Points on patch sides do not match to within tolerance 5.39231e-06


OpenFOAM thinks the meshes don't complement each other, am i right?
Where can i Change the tolerance of stitchMesh? I can't find something about that...


For better understanding my case: My box and my cylinder were first overlapping each other( like in my Picture above)
But for using stitchMesh i meshed my box without the volume of my cylinder and meshed my cylinder seperatly so that i can put both meshes together with mergeMeshes. I did that so that i get two patches i can put together.
What am i doing wrong?


my boundary after merging:

zylinder // patch from box without volume of cylinder
{
type patch;
nFaces 8880;
startFace 870467;
}
porosity
//patch from cylinder merged into box
{
type patch;
nFaces 19802;
startFace 879347;
}


Last edited by Lisl; February 2, 2016 at 04:56.
Lisl is offline   Reply With Quote

Old   February 3, 2016, 03:31
Default
  #4
New Member
 
Lisa
Join Date: Dec 2015
Posts: 8
Rep Power: 10
Lisl is on a distinguished road
I found a toleranceDict and changed some values (made the tolerances larger)
But the error is still there.
I executed stitchMesh with

stitchMesh -perfect -toleranceDict (nameDict) masterPatch slavePatch

Here are the entries for my toleranceDict:


pointMergeTol 0.3;

edgeMergeTol 0.0201;

nFacesPerSlaveEdge 5;

edgeFaceEscapeLimit 10;

integralAdjTol 0.8;

edgeMasterCatchFraction 0.4;

edgeCoPlanarTol 0.8;

edgeEndCutoffTol 0.0001;

What am I doing wrong?
Can please someone give me a hint??

Thanks!
Lisl is offline   Reply With Quote

Old   February 21, 2016, 14:32
Default
  #5
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,974
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quick answer: Sorry for the late reply, but without access to the case, there isn't much I can do.

Nonetheless, I did look into similar cases several months ago and they are all documented here: http://www.cfd-online.com/Forums/ope...mesh-used.html - please study the content of that thread! If after reading it all you still can figure it out, please provide access to your case, even if it has to be through a DropBox or Google Drive link provided via private message.
__________________
wyldckat is offline   Reply With Quote

Old   February 18, 2018, 03:42
Default
  #6
Member
 
Ramana
Join Date: Jul 2017
Location: India
Posts: 58
Rep Power: 8
svramana is on a distinguished road
Quote:
Originally Posted by wyldckat View Post
Quick answer: If you only merged the two meshes, then they are technically considered by OpenFOAM has being two completely independent regions, even if they are overlapped over each other.

You will need to use one of the following solutions:
  1. Stitch the two meshes together, which requires that the two meshes complement each other.
  2. To use AMI boundary conditions, for establishing the boundary connections between each mesh.
  3. To mesh the two regions in a single meshing operation, where the internal cylinder is meshed as a cellZone and the porosity is later assigned with an fvOption.
  4. To follow the same case set-up as the tutorial "heatTransfer/chtMultiRegionSimpleFoam/heatExchanger" that is available at least since OpenFOAM 3.0.
Hello Bruno,
I am doing case similar to the one specified above.

my goal is to simulate "Incompressible Flow and heat transfer from a heated(const.Temp Tw) porous cylinder to flowing wind( temp. Tf).
The computational domain appended as below
After going through similar threads on this forum, i wanted to create customized solver to run my simulation
and I did the following steps for simulation.

Solver modification
Code:
  1. created OF/user(.OFversion)/application/solver directory
  2. Copied PisoFoam solver from installation directory(i want to to transient simulation)
  3. renamed as "my_porousPisoFoam" with relevant modifications
  4. included the porosity as momentum sink in UEqn.H
  5. New TEq.H created and included in my_porousPisoFoam.C & defined "T" as VolScalarField and "DT" as dimensinedScalar in "createField.H"
  6. compiled as new solver with "Wclen&wmake " in make folder
compilation was done without errors
Case simulation
Code:
  1. Created domain(single) using blockMesh.
  2. Porous cylinder defined as porous zone using "topSet"
  3. Assigned porosity (Darcy-Forchheimer model) using "fvOptions"
  4. Assigned Fixed temp.(Tw) using "scalarFixedValueConstraint" to the porouszone.
i wanted to run the simulation for 200 sec to validate for the following literature values
Code:
Flow and heat transfer parameters considered
Re 40 
Darcy no (Da ): 10e-2
porosity value: 0.993
Pr :0.71
i have calculated the Drag and lift coefficients using "postprocessing utility "forcecoeffcient" and

Nusselt number through Paraview in following steps

Code:
  1. load the case in praview and select porous zone and "T" from pipeline browser/advance toggle options.
  2. run the simulation till last step and "apply"
  3. calculate derivatives(gradT)
  4. calculator to calculate "Nu" on all four faces and plot the variation along the length of porouszone
"i have no idea how to write the code to calculate local and average Nusselt Number for the porous cylinder (as i have defined cylinder as porous zone and the interaction between fluid and cylinder is "interface" there is no wall/patch to extract the values")

Cd and "Nu" values are not matching with the literature values.i am clueless what went wrong in my case setup i am struck i need help to proceed further.
case,solver and literature is enclosed for your advise.
https://www.dropbox.com/sh/16iu1o6mn...z4l_ApTia?dl=0

Last edited by svramana; March 20, 2018 at 01:09.
svramana is offline   Reply With Quote

Old   March 7, 2018, 15:36
Default
  #7
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,974
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quick answer: I don't have enough time to look into this myself, but please check the cases and reports that are available here: http://www.tfd.chalmers.se/~hani/kurser/OS_CFD/ - I believe that there are at least a examples there on heat sources and porosity sources.
__________________
wyldckat is offline   Reply With Quote

Old   March 20, 2018, 01:27
Default Heat transfer from PorousZone
  #8
Member
 
Ramana
Join Date: Jul 2017
Location: India
Posts: 58
Rep Power: 8
svramana is on a distinguished road
Quote:
Originally Posted by wyldckat View Post
Quick answer: I don't have enough time to look into this myself, but please check the cases and reports that are available here: http://www.tfd.chalmers.se/~hani/kurser/OS_CFD/ - I believe that there are at least a examples there on heat sources and porosity sources.
Bruno,
i have gone through the link ,unfortunately i did not find any clue regarding porous heat transfer related case.

Flow is incompressible Re=40,Pr=0.7

Code:
My problem here is to simulate heat transfer between fluid at say 283K and porous zone at 343k.
The flow is modeled as single domain and porous zone is defined here as flow resistance(Darcy -Forchheimer model) by adding addional sink term to N-S equations
  1. Average Nusselt number on porous zone surface is not effected by variation of porosity values( inertial and viscous resistance ).
  2. Do i need to define thermal boundary conditions at the fluid -fluid interface(internal faces/no physical boundary).
Regards,
Ramana
svramana is offline   Reply With Quote

Old   March 20, 2018, 10:49
Default Porous heat transfer model
  #9
Senior Member
 
Lasse Brams Vinther
Join Date: Oct 2015
Posts: 112
Rep Power: 10
Swagga5aur is on a distinguished road
Hello Ramana,

I have developed a solver that handles heat transfer between porous media and surrounding fluid in a single domain approach with solver determined Nusselts number, Reynolds number and heat transfer coefficient.

The sovler is attached in the following link:
https://www.dropbox.com/s/affha5r5ht...am.tar.gz?dl=0

You may be able to use some the code, the relevant part for you is in the reactor region of the solver, with EEqn and TcEqn being the fluid and porous media solvers.

I would implement the same approach in your solver and assign the epsilon to be 1 for the entire domain except in the porous region, with the issue being the implementation of the external heat transfer from the outer surface to the porous absent domain.

I'll attach an example when I get to my home computer but the above link should be sufficient for an approach of your own.

Note its for openFOAM V4.

Note I have not immensely tested it and I have some issues exist with the AoV scale vs the heat transfer coefficient unit in the solver, but I'm looking into it.
Swagga5aur is offline   Reply With Quote

Old   March 21, 2018, 00:52
Default
  #10
Member
 
Ramana
Join Date: Jul 2017
Location: India
Posts: 58
Rep Power: 8
svramana is on a distinguished road
Quote:
Originally Posted by Swagga5aur View Post
Hello Ramana,

I have developed a solver that handles heat transfer between porous media and surrounding fluid in a single domain approach with solver determined Nusselts number, Reynolds number and heat transfer coefficient.

The sovler is attached in the following link:
https://www.dropbox.com/s/affha5r5ht...am.tar.gz?dl=0

You may be able to use some the code, the relevant part for you is in the reactor region of the solver, with EEqn and TcEqn being the fluid and porous media solvers.

I would implement the same approach in your solver and assign the epsilon to be 1 for the entire domain except in the porous region, with the issue being the implementation of the external heat transfer from the outer surface to the porous absent domain.

I'll attach an example when I get to my home computer but the above link should be sufficient for an approach of your own.

Note its for openFOAM V4.

Note I have not immensely tested it and I have some issues exist with the AoV scale vs the heat transfer coefficient unit in the solver, but I'm looking into it.
Hello Lasse,
i wanna submit my thesis this month end ,i don't want to try new solver at this point .i have done some modifications and developed a solver for my case. The only problem being the heat transfer between fixed temperature porous zone and fluid.i will be glad if you can help me in this

The solver and test case can be found here
https://www.dropbox.com/s/l9nzgqjwc2...er.tar.gz?dl=0


Regards,
Ramana
svramana is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
mass transfer through porous media Ahmed Khattab OpenFOAM Running, Solving & CFD 1 October 16, 2015 03:44
Pressure drag problem in porous media with interFoam skp OpenFOAM Running, Solving & CFD 8 May 27, 2015 08:10
Porous media solving problem mulfal OpenFOAM Running, Solving & CFD 2 June 23, 2010 05:31
species mass source in porous media ? PK FLUENT 0 February 16, 2007 11:12
Testing the integrity of POROUS media and por jump Azman FLUENT 0 July 31, 2006 11:11


All times are GMT -4. The time now is 01:55.