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

DirectMapped

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 3, 2010, 09:34
Default DirectMapped
  #1
Member
 
Primoz Ternik
Join Date: Apr 2009
Location: Maribor, Slovenia
Posts: 65
Rep Power: 17
ternik is on a distinguished road
Hi Foamers,

I need a help on the following - I would like to calculate fully developed (from inlet to outlet) channel flow (Hagen-Poiseuille) of non-Newtonian fluid for a given mass flow rate (actually for a given average velocity, since I know the channel height and density of a fluid). Is the DirectMapped type of boundary condition for a velocity the only choice for this (for Carreau-Yasuda non-Newtonian fluid there is no theoretical experssion for fully developed velocity profile)? If so, what is the meaning of offset (0.05 0 0) (I looked for this example in oodles/pitzDailyDirectMapped tutorial?

Thanks in advance!

Cheers,
Primoz
ternik is offline   Reply With Quote

Old   March 3, 2010, 09:45
Default
  #2
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Hi Primoz

The offset-vector states in what direction and how far away from the given boundary patch data should be extracted and mapped back onto the given patch.

Best regards,

Niels
ngj is offline   Reply With Quote

Old   March 3, 2010, 10:05
Default
  #3
Member
 
Primoz Ternik
Join Date: Apr 2009
Location: Maribor, Slovenia
Posts: 65
Rep Power: 17
ternik is on a distinguished road
Quote:
Originally Posted by ngj View Post
Hi Primoz

The offset-vector states in what direction and how far away from the given boundary patch data should be extracted and mapped back onto the given patch.

Best regards,

Niels
Hi Niels,

thank you! So, offset (1 0 0) means that flow field (e.g. velocity) is mapped from "plane" that is 1 unit far away from inlet in x-direction?

Enjoy,
primoz
ternik is offline   Reply With Quote

Old   March 3, 2010, 10:20
Default
  #4
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Exactly!

Have fun.
ngj is offline   Reply With Quote

Old   March 3, 2010, 13:50
Default
  #5
Member
 
Primoz Ternik
Join Date: Apr 2009
Location: Maribor, Slovenia
Posts: 65
Rep Power: 17
ternik is on a distinguished road
Quote:
Originally Posted by ngj View Post
Exactly!

Have fun.
Hi Niels,

sorry, but I have some "issues" with directMapped method. I have calculated (with nonNewtonianIcoFoam) flow of a Newtonian fluid in a channel (L=2, H=1) using your suggestion. The velocity looks fine (fully developed from inlet to outlet) but the pressure looks "strange" - I would expect to get the linear pressure variation from inlet to outlet (theoretical pressure drop=2.4Pa), but the situation is quite different (please see attached figures).

Can you (or someone else) make any comment, suggestions... I hope that I am doing something wrong, rather than blame the OpenFoam. For that I have also attached my case.

enjoy,
Primoz
Attached Images
File Type: jpg PressureCentreline.jpg (38.7 KB, 42 views)
File Type: jpg VxCentreline.jpg (24.6 KB, 31 views)
Attached Files
File Type: gz DirectMapped.tar.gz (3.3 KB, 49 views)
ternik is offline   Reply With Quote

Old   March 3, 2010, 15:04
Default
  #6
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Hi Primoz

Could you please tell me what solver you are using? I might have an idea.

Best regards,

Niels
ngj is offline   Reply With Quote

Old   March 3, 2010, 15:16
Default
  #7
Member
 
Primoz Ternik
Join Date: Apr 2009
Location: Maribor, Slovenia
Posts: 65
Rep Power: 17
ternik is on a distinguished road
Quote:
Originally Posted by ngj View Post
Hi Primoz

Could you please tell me what solver you are using? I might have an idea.

Best regards,

Niels
Hi Niels,

nonNewtonianIcoFoam!

Looking forward for your idea !

Enjoy,
Primoz
ternik is offline   Reply With Quote

Old   March 3, 2010, 16:41
Default
  #8
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Hi

It was something else than I suspected, however I found out that the error lies with the use of CrankNicholson. Using either Euler or backward yielded good results. You might consider reporting it as a bug in the CrankNicholson. At least it is unsatisfactory that the time scheme has such a significant effect on the result, e.g. from right to wrong.

Best regards,

Niels
ngj is offline   Reply With Quote

Old   March 3, 2010, 17:27
Default
  #9
Member
 
Primoz Ternik
Join Date: Apr 2009
Location: Maribor, Slovenia
Posts: 65
Rep Power: 17
ternik is on a distinguished road
Quote:
Originally Posted by ngj View Post
Hi

It was something else than I suspected, however I found out that the error lies with the use of CrankNicholson. Using either Euler or backward yielded good results. You might consider reporting it as a bug in the CrankNicholson. At least it is unsatisfactory that the time scheme has such a significant effect on the result, e.g. from right to wrong.

Best regards,

Niels
Hi,

thank for your tip! I will run some tests tomorrow (using all three time schemes), document them well and put results on-line (on forum)!

One last question - do you think that the "plane" of mapping (offset value) influences results (time evolution of flow in a straight channel)? Now I was mapping from the middle of a channel and I wonder if mapping from some other axial position (e.g. closer to inlet or outlet) would yield different results?!

Cheers,
Primoz
ternik is offline   Reply With Quote

Old   March 4, 2010, 01:24
Default
  #10
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Good morning

Well, I do not think that the final steady-state solution will be affected by the length of the mapping zone, however the length will most certainly affect the necessary simulation time as a short zone will require longer simulation time than a longer one.
I you at some point is going to consider turbulence, the length of the mapping zone become important for the final result, at least for LES, however as long as you are in the laminar regime, there are no issues with respect to "result as a function of mapping length".

Have a good day,

Niels
ngj is offline   Reply With Quote

Old   March 4, 2010, 08:34
Default
  #11
Member
 
Primoz Ternik
Join Date: Apr 2009
Location: Maribor, Slovenia
Posts: 65
Rep Power: 17
ternik is on a distinguished road
Quote:
Originally Posted by ngj View Post
Good morning

Well, I do not think that the final steady-state solution will be affected by the length of the mapping zone, however the length will most certainly affect the necessary simulation time as a short zone will require longer simulation time than a longer one.
I you at some point is going to consider turbulence, the length of the mapping zone become important for the final result, at least for LES, however as long as you are in the laminar regime, there are no issues with respect to "result as a function of mapping length".

Have a good day,

Niels
Hi Niels,

thank you for your time and explanations! I have just finished a study with all three differencing schemes. Results are as expected (regarding your previous post) - Euler and Backward differencing schemes yield good results, while Crank Nicholson ... See attached figures for the pressure drop (PressureDrop_Backward.png, PressureDrop_Euler.png, PressureDrop_CrankNicholson.png) and time evolution of centreline velocity (VxCentreline_TimeDiffScheme.pdf)! Please note, that the theoretical pressure drop for this case (at fully developed flow conditions) is 2.4Pa and the pressure varies (reduces) linearly with axial position!

In adition, I have also tested (possible) influence of "mapping plane" position - according to your post, there is no influence of offset value on time evolution of centreline velocity (see attached figure - VxCentreline_OffsetValue.pdf).

Thank you again!

Enjoy,
Primoz
Attached Images
File Type: jpg PressureDrop_Backward.jpg (38.3 KB, 31 views)
File Type: jpg PressureDrop_CrankNicholson.jpg (38.7 KB, 28 views)
File Type: jpg PressureDrop_Euler.jpg (38.3 KB, 26 views)
Attached Files
File Type: pdf VxCentreline_TimeDiffScheme.pdf (17.2 KB, 21 views)
File Type: pdf VxCentreline_OffsetValue.pdf (80.2 KB, 21 views)
ternik 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
Cyclic vs ggi vs directMapped Patches jens_klostermann OpenFOAM Running, Solving & CFD 33 May 3, 2013 02:45
DirectMapped inlet + Experimental Inlet Kr_kim OpenFOAM Running, Solving & CFD 0 February 8, 2010 18:12
directMapped Method in OF-1.6 Kr_kim OpenFOAM Bugs 2 February 4, 2010 17:36
sample error in directMapped BC matthias OpenFOAM 0 November 13, 2009 17:00
directMapped BC in parallel turnow OpenFOAM 0 August 13, 2009 06:35


All times are GMT -4. The time now is 14:52.