CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

Laminar Isothermal Flow in a duct

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 25, 2012, 07:15
Default Laminar Isothermal Flow in a duct
  #1
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Hello,

First of all, I would like to say that I have developed a code using the FEM (Finite Element Method) based on the CBS (Characteristic Based Split) Algorithm.
Using this code, now, I would like to simulate a Laminar Isothermal Flow in a rectangular channel for an incompressible flow.

I have set up the following boundary conditions:
1. Inlet condition:
U1 = 1.0 U2 = 0.0
2. Solid wall condition (walls of the rectangular channel/duct)
U1 = 0.0 U2 = 0.0
3. Outlet condition:
P = 0.0

But, to my surprised, using this boundary conditions for an incompressible fluid flow, what I get is a recirculation of the flow. When stating a recirculation, I mean to say that the flow at the end of the duct (outlet) enters the domain instead of following the inlet velocity.
Very strange.

I cannot see the flow developing with the length of the duct / channel.

Does anybody have an idea why this is happening?
Do I have missed anything?

Best regards,
Hector.
HectorRedal is offline   Reply With Quote

Old   April 25, 2012, 11:59
Default
  #2
Senior Member
 
cdegroot's Avatar
 
Chris DeGroot
Join Date: Nov 2011
Location: Canada
Posts: 414
Rep Power: 18
cdegroot is on a distinguished road
What are the rest of your BCs? How do you specify pressure at the inlet and walls and how do you specify velocity at the outlet? Is the duct long enough for the flow to exit fully-developed?
cdegroot is offline   Reply With Quote

Old   April 25, 2012, 12:15
Default
  #3
Member
 
Mosi Owa
Join Date: Nov 2011
Posts: 35
Rep Power: 15
BMCombustor is on a distinguished road
Regardless of the duct length, you shouldn't have recirculation. I don't know how you set up pressure outlet but why don't you change your outlet BC to outflow? By that, you just need to set zero gradient for all variables at your outlet and just check for the continuity to be satisfied.
BMCombustor is offline   Reply With Quote

Old   April 25, 2012, 19:49
Default
  #4
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by cdegroot View Post
What are the rest of your BCs? How do you specify pressure at the inlet and walls and how do you specify velocity at the outlet? Is the duct long enough for the flow to exit fully-developed?
Neither do I specify the pressure at the inlet nor at the walls.
In the inlet and in the walls I specify the velocity.
I only specify the velocity at the inlet. I don't specify the pressure at the outlet.
The length of the duct is ten time the required length for the flow to be developed.
HectorRedal is offline   Reply With Quote

Old   April 25, 2012, 19:55
Default
  #5
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by BMCombustor View Post
Regardless of the duct length, you shouldn't have recirculation. I don't know how you set up pressure outlet but why don't you change your outlet BC to outflow? By that, you just need to set zero gradient for all variables at your outlet and just check for the continuity to be satisfied.
Do you refer by outflow condition to null velocity gradient?
HectorRedal is offline   Reply With Quote

Old   April 25, 2012, 20:34
Default
  #6
Senior Member
 
cdegroot's Avatar
 
Chris DeGroot
Join Date: Nov 2011
Location: Canada
Posts: 414
Rep Power: 18
cdegroot is on a distinguished road
Quote:
Originally Posted by HectorRedal View Post
Neither do I specify the pressure at the inlet nor at the walls.
In the inlet and in the walls I specify the velocity.
I only specify the velocity at the inlet. I don't specify the pressure at the outlet.
The length of the duct is ten time the required length for the flow to be developed.
Hmm... you need to have a boundary condition for both velocity and pressure at all boundaries. You should be extrapolating pressure to the inlet and wall boundaries. Is that what you mean by not specifying pressure perhaps?
cdegroot is offline   Reply With Quote

Old   April 25, 2012, 21:08
Default
  #7
Member
 
Mosi Owa
Join Date: Nov 2011
Posts: 35
Rep Power: 15
BMCombustor is on a distinguished road
Quote:
Originally Posted by HectorRedal View Post
Do you refer by outflow condition to null velocity gradient?
I'm not familiar with the term "null velocity gradient" but I mean that for general variable "PHI" at outlet node is equal to its neighbor, i.e. PHI(N,J)=PHI(N-1,J) which N stands for the outlet node.
BMCombustor is offline   Reply With Quote

Old   April 26, 2012, 00:30
Default
  #8
New Member
 
mj
Join Date: Apr 2010
Posts: 5
Rep Power: 16
doctor evil is on a distinguished road
I'm not quite sure about what did u mean by "3. Outlet condition:P = 0.0". But I guess the outlet BC might be the problem. I agree with BMCombustor's reply.
doctor evil is offline   Reply With Quote

Old   April 26, 2012, 05:57
Default
  #9
New Member
 
Dr. Madhukar M Rao
Join Date: Nov 2010
Location: Bangalore, India
Posts: 21
Rep Power: 16
madhukar_m_rao is on a distinguished road
Assuming that the CBS has been implemented following the description in "The Finite Element Method - Vol. 3" by Zienkiewicz, Taylor, and Nithiarasu, Chapter 3, the boundary conditions for outflow have been discussed in section 3.8.1 of that book.
madhukar_m_rao is offline   Reply With Quote

Old   April 27, 2012, 12:36
Default
  #10
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by cdegroot View Post
Hmm... you need to have a boundary condition for both velocity and pressure at all boundaries. You should be extrapolating pressure to the inlet and wall boundaries. Is that what you mean by not specifying pressure perhaps?
May I can disagree with you on this?

I am following an example of the following book:
Fundamentals of the Finite Element Method for Heat and Fluid Flow.
Roland W. Lewis and Perumal Nithiarasu.
Example 7.01.1, on page 218.
As an attachment, I have uploaded the drawing that appears for this example.
You can see, that on boundaries you only need to specify one of the variables: either pressure or velocity.

On the other hand, I totally agree with you that on boundaries you need to extrapolate the pressure, but in my opinion using the velocity boundary condition, and the conservation momentum equation.

Do you agree on this?
Attached Images
File Type: jpg example_7_10_1.jpg (24.8 KB, 12 views)
HectorRedal is offline   Reply With Quote

Old   April 27, 2012, 12:41
Default
  #11
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by BMCombustor View Post
I'm not familiar with the term "null velocity gradient" but I mean that for general variable "PHI" at outlet node is equal to its neighbor, i.e. PHI(N,J)=PHI(N-1,J) which N stands for the outlet node.
Sorry for the misleading information I could have provided you with.
When stating "null velocity gradient", I mean to say that the gradient of the velocity is null. This is equivalent to say that at the far end of the duct, the velocity at one point is the same as the velocity of their neighbors. I think that this statement is in agreement with what you have stated.

Maybe then I need to change the boundary condition at the end of the duct for a boundary condition that enforces this condition.

Thanks for your help and support.
HectorRedal is offline   Reply With Quote

Old   April 27, 2012, 12:46
Default
  #12
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by madhukar_m_rao View Post
Assuming that the CBS has been implemented following the description in "The Finite Element Method - Vol. 3" by Zienkiewicz, Taylor, and Nithiarasu, Chapter 3, the boundary conditions for outflow have been discussed in section 3.8.1 of that book.
Hello madhukar.

As you have correctly mentioned, I am following the description of the book from Zienkiewicz.
But, I am trying to simulate the example that appears on other book:
Fundamentals of the Finite Element Method for Heat and Fluid flow, W. Lewis and P. Nithiarasu.
You can find it on chapter 7.10.1.
I have uploaded in a previous response a copy of the drawing that appears in the book related to this example.

You can take a look at it.
Any comment suggestion will be highly appreciated.

Thanks for your comments and support.
HectorRedal is offline   Reply With Quote

Old   April 27, 2012, 12:51
Default
  #13
Senior Member
 
cdegroot's Avatar
 
Chris DeGroot
Join Date: Nov 2011
Location: Canada
Posts: 414
Rep Power: 18
cdegroot is on a distinguished road
Quote:
Originally Posted by HectorRedal View Post
May I can disagree with you on this?

I am following an example of the following book:
Fundamentals of the Finite Element Method for Heat and Fluid Flow.
Roland W. Lewis and Perumal Nithiarasu.
Example 7.01.1, on page 218.
As an attachment, I have uploaded the drawing that appears for this example.
You can see, that on boundaries you only need to specify one of the variables: either pressure or velocity.

On the other hand, I totally agree with you that on boundaries you need to extrapolate the pressure, but in my opinion using the velocity boundary condition, and the conservation momentum equation.

Do you agree on this?
You may indeed disagree. First, I must admit I am not experienced in finite element methods; my background is in finite volume methods. However, in order to have a well-posed mathematical problem, a parabolic PDE needs conditions on all boundaries. If your numerical method somehow internally takes care of the pressure at boundaries where it is not specified, then fine, but this is still a boundary condition. Can you perhaps elaborate on how your method treats pressure at boundaries where it is unspecified? Similarly, how are you treating velocity at the outlet?
cdegroot is offline   Reply With Quote

Old   April 27, 2012, 18:01
Default
  #14
Senior Member
 
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,882
Rep Power: 73
FMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura about
Can I have some answer about the following points?
- Are you using a 2D steady or unsteady formulation ? What about your Re number?
- Have you checked the divergence-free constraint in each element?
- What about the shape functions for V and p?
- Have you checked if the solution is independent from the fixed pressure value? It must be...
FMDenaro is offline   Reply With Quote

Old   April 28, 2012, 11:41
Default
  #15
New Member
 
Dr. Madhukar M Rao
Join Date: Nov 2010
Location: Bangalore, India
Posts: 21
Rep Power: 16
madhukar_m_rao is on a distinguished road
Dear Hector,

Have you validated your code for the driven cavity problem or any similar benchmark problem without inlet/outlet?

For the channel problem, how are you calculating / setting the pressure at the inlet
and the velocities at the outlet? (See Fig 3.2 in Zienkiewicz's book).

Regards,
madhukar_m_rao is offline   Reply With Quote

Old   April 28, 2012, 12:13
Default
  #16
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by madhukar_m_rao View Post
Dear Hector,

Have you validated your code for the driven cavity problem or any similar benchmark problem without inlet/outlet?

For the channel problem, how are you calculating / setting the pressure at the inlet
and the velocities at the outlet? (See Fig 3.2 in Zienkiewicz's book).

Regards,
Dear Madhukar,

I have validated my code towards the benchmark typical test case that is the lid driven cavity flow problem, as you precisely has stated.
The results that I am getting for this test case can be found at the following link to my personal web site:
https://sites.google.com/site/hector.../cfd-example-1

They are not very good results. There is a slightly error. I bitterly must admit that I don't know where the problem is. I am struggling to discover where the error is.

Regarding the boundary conditions, as mentioned before, I do not set neither the pressure at the inlet, nor the velocity at the outlet.

Kind regards,
HectorRedal is offline   Reply With Quote

Old   April 28, 2012, 12:17
Default
  #17
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by FMDenaro View Post
Can I have some answer about the following points?
- Are you using a 2D steady or unsteady formulation ? What about your Re number?
- Have you checked the divergence-free constraint in each element?
- What about the shape functions for V and p?
- Have you checked if the solution is independent from the fixed pressure value? It must be...
Dear Filippo,

I am using a unsteady formulation.
The Reynolds number I am using is 10 (Re = 10).
I am using the an equal shape formulation for the Velocity and Pressure fields.
I have not checked if the solution is independent from the fixed pressure value, but once I check it, I will come back with the results.

Thanks for your help and support.
Kind regards.
HectorRedal is offline   Reply With Quote

Old   April 28, 2012, 14:15
Default
  #18
Senior Member
 
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,882
Rep Power: 73
FMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura about
Quote:
Originally Posted by HectorRedal View Post
Dear Filippo,

I am using a unsteady formulation.
The Reynolds number I am using is 10 (Re = 10).
I am using the an equal shape formulation for the Velocity and Pressure fields.
I have not checked if the solution is independent from the fixed pressure value, but once I check it, I will come back with the results.

Thanks for your help and support.
Kind regards.
ok,m don't forget to check the divergence-free constraint.
Furthermore, how do you check the steady condition? I am not an expert of FEM, however I remember that velocity and pressure should have different degree in the shape functions, try to check the BB conditions.
Are you using a coupling velocity-pressure formulation?
FMDenaro is offline   Reply With Quote

Old   May 1, 2012, 02:05
Default
  #19
New Member
 
Dr. Madhukar M Rao
Join Date: Nov 2010
Location: Bangalore, India
Posts: 21
Rep Power: 16
madhukar_m_rao is on a distinguished road
Quote:
Originally Posted by HectorRedal View Post
Dear Madhukar,

I have validated my code towards the benchmark typical test case that is the lid driven cavity flow problem, as you precisely has stated.
The results that I am getting for this test case can be found at the following link to my personal web site:
https://sites.google.com/site/hector.../cfd-example-1

They are not very good results. There is a slightly error. I bitterly must admit that I don't know where the problem is. I am struggling to discover where the error is.

Regarding the boundary conditions, as mentioned before, I do not set neither the pressure at the inlet, nor the velocity at the outlet.

Kind regards,
[1] Regarding the driven cavity case on your website, you can try
mesh refinement to see if you get a better match.

[2] I would recommend verification and validation as described in the
book, "Verification of Computer Codes in Computational Science and
Engineering," by Knupp and Salari, Chapman & Hall/CRC, 2003.

[3] For the channel problem, what are your initial conditions?
and time step?

[4] After the first time step, what is the computed pressure at the
inlet nodes and the computed velocities at the outlet nodes?
madhukar_m_rao is offline   Reply With Quote

Old   May 3, 2012, 14:31
Default
  #20
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by madhukar_m_rao View Post
[1] Regarding the driven cavity case on your website, you can try
mesh refinement to see if you get a better match.

[2] I would recommend verification and validation as described in the
book, "Verification of Computer Codes in Computational Science and
Engineering," by Knupp and Salari, Chapman & Hall/CRC, 2003.

[3] For the channel problem, what are your initial conditions?
and time step?

[4] After the first time step, what is the computed pressure at the
inlet nodes and the computed velocities at the outlet nodes?
Dear Madhukar,
First of all, I would like to thank you for your ideas and help you had provided to me.

Next, I am going to answer your questions, so as to pinpoint which is the problem with my code.

The initial conditions for the problem are the following:
- velocity equal to zero in all nodes that do not have a boundary condition for the velocity
- pressure equal to zero in all nodes that do not have a boundary condition for the pressure.

The time step is set to a value minor than the value specified for the CFL condition for this algorithm.

After the first step of the algorithm, I have observed the following strange behaviour (I am using an structured grid formed with quad elements):
For odd nodes, the velocity goes in the same direction than the velocity boundary conditions.
For even nodes, the velocity goes in the contrary direction than the velocity boundary conditions.

In the outlet, the velocity goes in the same direction as in the inlet, but as you can observe, there are a lot of nodes (inner nodes) that have the velocity with a direction opposite to the boundary conditions.

Quite strange!

Does this behaviour have to do with the incompressiblity of the fluid?

Best regards,
HectorRedal 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
Laminar flow and wall roughness junbbung FLUENT 2 November 26, 2022 22:22
Laminar Flow rvallejo CFX 1 November 16, 2009 10:49
Laminar field as initial state for turbulent two phase pipe flow kjetil OpenFOAM Running, Solving & CFD 3 July 21, 2009 10:15
flow simulation across a small fan jane luo Main CFD Forum 15 April 12, 2004 18:49
Divergence of Laminar Flow With Eddy ??? Peter Kostka Main CFD Forum 3 May 9, 2002 18:02


All times are GMT -4. The time now is 21:18.