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

Solving Stokes Flows in OpenFOAM

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 16, 2017, 15:39
Default Solving Stokes Flows in OpenFOAM
  #1
Senior Member
 
Join Date: Jul 2013
Posts: 124
Rep Power: 12
wildfire230 is on a distinguished road
Hi all,

I am interested in solving Stokes flows (zero Reynolds number) using OpenFOAM. It's my understanding that there are several different ways to do this, for example you can just delete for example fvm::div(phi, U) from the UEqn in icoFoam and recompile and have a Stokes flow solver. However, I've noticed that doing so, the amount of time to converge is still a function of viscosity nu, which I would not expect. Are there other changes that need to be made to for example icoFoam in order to accurately solve zero Reynolds number flows, or better yet, what would be the optimum approach for solving steady state Stokes flows using OpenFOAM, i.e. time resolution is not important.

I would appreciate any help.
wildfire230 is offline   Reply With Quote

Old   January 16, 2017, 21:29
Default
  #2
Senior Member
 
Arjun
Join Date: Mar 2009
Location: Nurenberg, Germany
Posts: 1,272
Rep Power: 34
arjun will become famous soon enougharjun will become famous soon enough
Quote:
Originally Posted by wildfire230 View Post
Hi all,

I am interested in solving Stokes flows (zero Reynolds number) using OpenFOAM. It's my understanding that there are several different ways to do this, for example you can just delete for example fvm::div(phi, U) from the UEqn in icoFoam and recompile and have a Stokes flow solver. However, I've noticed that doing so, the amount of time to converge is still a function of viscosity nu, which I would not expect. Are there other changes that need to be made to for example icoFoam in order to accurately solve zero Reynolds number flows, or better yet, what would be the optimum approach for solving steady state Stokes flows using OpenFOAM, i.e. time resolution is not important.

I would appreciate any help.
You can not use implicit urf for momentum in case of stokes flow that typically openfoam etc use.
This greatly affect your simulation time. You have to use urf = 1 and depend on explicit urf.

This comes with stability problems but a lower value of explicit urf would help.
arjun is offline   Reply With Quote

Old   January 16, 2017, 21:40
Default
  #3
Senior Member
 
Join Date: Jul 2013
Posts: 124
Rep Power: 12
wildfire230 is on a distinguished road
Hi arjun, thanks for the message. I'm not sure I fully understand, I did not know there were implicit and explicit under relaxation factors. I have only used under relaxation with simpleFoam. Do you mean that the best solution is to modify simpleFoam and eliminate the convection terms there? Could you please explain the difference between explicit and implicit urf?

Thanks again.
wildfire230 is offline   Reply With Quote

Old   January 16, 2017, 21:58
Default
  #4
Senior Member
 
Arjun
Join Date: Mar 2009
Location: Nurenberg, Germany
Posts: 1,272
Rep Power: 34
arjun will become famous soon enougharjun will become famous soon enough
Quote:
Originally Posted by wildfire230 View Post
Hi arjun, thanks for the message. I'm not sure I fully understand, I did not know there were implicit and explicit under relaxation factors. I have only used under relaxation with simpleFoam. Do you mean that the best solution is to modify simpleFoam and eliminate the convection terms there? Could you please explain the difference between explicit and implicit urf?

Thanks again.
Basically diagonal is scaled by urf in case of implicit urf. So the equation becomes diagonally dominant. This makes linear system converge fast.

I know it is implicit because all these solvers apply it in implicit form.
arjun is offline   Reply With Quote

Old   January 16, 2017, 22:07
Default
  #5
Senior Member
 
Join Date: Jul 2013
Posts: 124
Rep Power: 12
wildfire230 is on a distinguished road
Thanks, so if you wanted to solve a steady Stokes flow problem would you use simpleFoam?
wildfire230 is offline   Reply With Quote

Old   January 16, 2017, 22:39
Default
  #6
Senior Member
 
Arjun
Join Date: Mar 2009
Location: Nurenberg, Germany
Posts: 1,272
Rep Power: 34
arjun will become famous soon enougharjun will become famous soon enough
Quote:
Originally Posted by wildfire230 View Post
Thanks, so if you wanted to solve a steady Stokes flow problem would you use simpleFoam?
The point is in case of viscous flow momentum equation is Poisson equation. That does not like that type of urf.

You can solve stokes problem with simpleFOAM as the convective part will be calculated to be insignificant. Whole thing will be difficult to converge.
arjun is offline   Reply With Quote

Old   January 16, 2017, 22:57
Default
  #7
Senior Member
 
Join Date: Jul 2013
Posts: 124
Rep Power: 12
wildfire230 is on a distinguished road
That makes sense. So which solver would you use?
wildfire230 is offline   Reply With Quote

Old   January 16, 2017, 23:33
Default
  #8
Senior Member
 
Arjun
Join Date: Mar 2009
Location: Nurenberg, Germany
Posts: 1,272
Rep Power: 34
arjun will become famous soon enougharjun will become famous soon enough
Quote:
Originally Posted by wildfire230 View Post
That makes sense. So which solver would you use?
You can use simpleFOAM, just use urf = 1.

Also find out if you can have explicit urf, if it is available use a smaller value like 0.7 or so.
arjun is offline   Reply With Quote

Old   March 12, 2018, 10:04
Default
  #9
Member
 
Pablo Alarcón
Join Date: Mar 2018
Location: Liège
Posts: 59
Rep Power: 8
palarcon is on a distinguished road
Quote:
Originally Posted by arjun View Post
You can use simpleFOAM, just use urf = 1.

Also find out if you can have explicit urf, if it is available use a smaller value like 0.7 or so.
I'm also interested in this problem, but I want to construct a solver using (as a base) only the stokes flow, is there any possibility of having a solver considering only the stokes flow? or is it necessary to develop it from scratch?, something like taking the icofoam solver and adapt it with the SIMPLE algorithm?
palarcon 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
problem with Min/max rho tH3f0rC3 OpenFOAM 8 July 31, 2019 09:48
settlingFoam unstable? bendel_boy OpenFOAM Running, Solving & CFD 38 July 8, 2016 05:07
Micro Scale Pore, icoFoam gooya_kabir OpenFOAM Running, Solving & CFD 2 November 2, 2013 13:58
calculation stops after few time steps sivakumar OpenFOAM Running, Solving & CFD 7 March 17, 2013 06:37
Upgraded from Karmic Koala 9.10 to Lucid Lynx10.04.3 bookie56 OpenFOAM Installation 8 August 13, 2011 04:03


All times are GMT -4. The time now is 06:59.