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

When to use upwind or central differencing schemes?

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

Like Tree13Likes
  • 2 Post By quarkz
  • 10 Post By leflix
  • 1 Post By leflix

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 16, 2011, 10:26
Default When to use upwind or central differencing schemes?
  #1
Senior Member
 
TWB
Join Date: Mar 2009
Posts: 414
Rep Power: 19
quarkz is on a distinguished road
Hi,

I am using central differencing scheme currently.

I read that it is preferable to use an upwind scheme at high Re of 10,000 to ensure convergence.

Is this true?

Also, is upwind scheme only suitable for problems with a general direction of flow e.g flow past a cylinder, from left to right?

In that case, if I'm trying to simulate a flapping foil in a hovering configuration (with no inflow and symmetry BC all around), will I need to use an upwind scheme?

Thanks!
hogsonik and Kamal Kosta like this.
quarkz is offline   Reply With Quote

Old   August 17, 2011, 16:20
Default
  #2
Senior Member
 
Join Date: Aug 2011
Posts: 272
Rep Power: 16
leflix is on a distinguished road
Quote:
Originally Posted by quarkz View Post
Hi,


I read that it is preferable to use an upwind scheme at high Re of 10,000 to ensure convergence.

Is this true?
yes more or less...

upwind scheme as well as central differencing scheme are finite difference schemes which will use different locations of the variable you want to derive.
Imagine you want to discretize a first, second,....derivative of a given function f at a i location. To do that if you use f(i), f(i+1), f(i-1), f(i+2), f(i-2).. these expressions will refer as centred (means centred around i)
If you use f(i) f(i-1), f(i-2)... this one will refer as upwind because you only use upwind location around i.
If you use f(i), f(i+1), f(i+2)...this expression will refer as downwind.

The choice of one possible expression instead of another one will have somme consequences on accuracy and stability.

Now when you plan to discretize the Navier-Stokes equations this notion apply on the discretization of the convective term of the NS equations.
Let's imagine you use finite volume method , but in finite difference or in finite element the problem is the same.
In the discretization process you will need to the value of the velocity on the faces of your control volume. For example on the "east" side you will need u_e. in finite difference this location is generally noted i+1/2
If you use a centred scheme you will say U_e= (U_E+U_P)/2 (if the east face is at the mid distance between E and P.
If you use an upwind scheme you will say U_e= U_P is the convective velocity is positive and U_e=U_E is the convective velocity is negative. Saying that you understand why we speak of "upwind" scheme.

centred scheme is 2nd order accurate while upwind scheme is only first order. upwind scheme is also more diffusive than centred scheme but it is also more stable than centred scheme which can lead to some spurious oscillations (dispersive errors). It is well known than when peclet number is >2 it is preferable to switch from centred scheme to upwind scheme.

So due to this possible oscillating behaviour of the centred scheme, especially on convective dominated flow (high re number) the use of the upwind scheme could stabilize the solution.
But it will be in the same time less accurate..
But other options are possible.

in fact I should have told you first, to refer to CFD wiki
http://www.cfd-online.com/Wiki/Appro...grids_-_Common

You will understand the point.


Quote:
Also, is upwind scheme only suitable for problems with a general direction of flow e.g flow past a cylinder, from left to right?

In that case, if I'm trying to simulate a flapping foil in a hovering configuration (with no inflow and symmetry BC all around), will I need to use an upwind scheme?

Thanks!
Not at all ! now you will undertsand that it has nothing to do. Even if your flow is from right to left, it may be wise to use also upwind scheme for high reynolds number flows.
For the upwind scheme what is important is the local direction of the velocity.
Even if the flow is from left to right if you have some recirculating regions or vortices evolving in the flow, the velocity could be locally negative and thus you will retain U_E to compute U_e on the "east" side of the control volume .
leflix is offline   Reply With Quote

Old   August 18, 2011, 04:34
Default
  #3
Senior Member
 
TWB
Join Date: Mar 2009
Posts: 414
Rep Power: 19
quarkz is on a distinguished road
Thanks leflix for the in depth answer.

Just to confirm, the key point of the upwind scheme is the local convective velocity. Hence for high Re flow, no matter if the inflow is left to right, or if it is a hovering case with symmetrical BC, an upwind scheme is preferred. Is that so?
quarkz is offline   Reply With Quote

Old   August 18, 2011, 05:42
Default
  #4
Senior Member
 
Join Date: Aug 2011
Posts: 272
Rep Power: 16
leflix is on a distinguished road
Quote:
Originally Posted by quarkz View Post
Just to confirm, the key point of the upwind scheme is the local convective velocity.
yes

Quote:
Hence for high Re flow, no matter if the inflow is left to right, or if it is a hovering case with symmetrical BC, an upwind scheme is preferred. Is that so?
"preferred" is not the word. It is very problem dependent. If the code converge with a centred scheme use rather this one because the accuracy is better. But sometimes the solution could diverge with a centred scheme and converge with the upwind one.
In any case you can always use an upwind scheme. When it is necessary it will bring stability because of its propensity to numerical diffusion. But in the same time its accuracy is lower than other scheme for the same number of grid nodes.
Kamal Kosta likes this.
leflix is offline   Reply With Quote

Old   August 18, 2011, 05:47
Default
  #5
Senior Member
 
andy
Join Date: May 2009
Posts: 313
Rep Power: 18
andy_ is on a distinguished road
Quote:
Originally Posted by quarkz View Post
I read that it is preferable to use an upwind scheme at high Re of 10,000 to ensure convergence. Is this true?
Perhaps. It depends on the design and objectives of the numerical scheme.

Quote:
Originally Posted by quarkz View Post
Also, is upwind scheme only suitable for problems with a general direction of flow e.g flow past a cylinder, from left to right?
No. Upwinding is applied at a cell or cell face level and so varies throughout the grid.

Quote:
Originally Posted by quarkz View Post
In that case, if I'm trying to simulate a flapping foil in a hovering configuration (with no inflow and symmetry BC all around), will I need to use an upwind scheme?
Perhaps. It depends on the numerical scheme adopted.

At high Reynolds number upwinding introduces stability in a physically reasonable manner and so is generally good thing. However, the scheme may seek to introduce stability by numerically conserving physically quantities in a global manner (e.g. energy conservation is popular with LES schemes) which may preclude the use of upwinding which introduces "dissipative" terms.
andy_ is offline   Reply With Quote

Old   August 19, 2011, 03:21
Default
  #6
Senior Member
 
TWB
Join Date: Mar 2009
Posts: 414
Rep Power: 19
quarkz is on a distinguished road
Thanks andy_ for the additional info.

Currently, my flapping foil simulation at Re=10000 converges with central differencing. However, I'm getting non-periodical solution when it's supposed to be periodical based on experiments.

Is central differencing the problem? Should I use some form of upwind scheme? But leflix says central scheme should be more accurate.

Another reason could be turbulence, since my solver is only solving laminar flow.
quarkz is offline   Reply With Quote

Old   August 19, 2011, 04:24
Default
  #7
Senior Member
 
andy
Join Date: May 2009
Posts: 313
Rep Power: 18
andy_ is on a distinguished road
Quote:
Originally Posted by quarkz View Post
Currently, my flapping foil simulation at Re=10000 converges with central differencing. However, I'm getting non-periodical solution when it's supposed to be periodical based on experiments.
Turbulence isn't periodic and so if the flow is turbulent it can only be periodic after the turbulent motion has been averaged in some sense.

Quote:
Originally Posted by quarkz View Post
Is central differencing the problem? Should I use some form of upwind scheme? But leflix says central scheme should be more accurate.
Centred schemes and upwind schemes introduce numerical errors that behave differently. Which type of error is preferable depends on the details of how you go about solving the Navier Stokes equations.

Leflix was referring to formal accuracy and then only in a typical sense for centred and upwind schemes that use the same number of grid values. Assuming a solution is obtained, in the presence of significant numerical errors this is not the only property of a numerical scheme that is of relevance to a simulation.

Quote:
Originally Posted by quarkz View Post
Another reason could be turbulence, since my solver is only solving laminar flow.
If you resolve the flow in space and time and use appropriate boundary conditions then what you are doing is fine. It is usually called DNS (Direct Numerical Simulation) in CFD jargon.

If you do not resolve the flow in space and time then what you are doing is almost certain to result in an unreasonable simulation of the flow. The most common approach is to change the form of the equations being solved by introducing some form of averaging (a turbulence model) and then to resolve those equations in space and time.
andy_ 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
2nd order upwind vs 2nd order upwind!!! Far Main CFD Forum 7 March 14, 2013 13:29
Second order upwind is not UPwind!!! Far CFX 9 May 31, 2011 09:21
Wrong fvm::div assembling santiagomarquezd OpenFOAM Bugs 90 December 27, 2010 13:54
Central Differencing Scheme in Fluent alice FLUENT 2 March 21, 2004 08:30
Central Difference vs Upwind Defference S. Balasubramanyam Main CFD Forum 5 January 16, 2002 02:58


All times are GMT -4. The time now is 15:02.