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

Boundary Conditions

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 6, 1999, 07:19
Default Boundary Conditions
  #1
Jan Ramboer
Guest
 
Posts: n/a
Hello,

I am researching the influence of boundary conditions on a turbulent bfs with compressible NS-solver.

1) In the literature I can only find BC for incompressible cases. Can I just take them over for my compressible calculations or do I have to adapt them or can i not use them at all.

2)Boundary conditions used in laminar cases, are they also suited for turbulent cases? What in particular should I be aware of for turbulent cases?

3)Most of the cases I have read about where 2D, can I just extend the BC to 3D?

4)If I go over to LES can I just maintain my BC?

Lots of questions as you see. Any answer on one of these questions is more than welcome.

Greetings,

Jan Ramboer
  Reply With Quote

Old   August 6, 1999, 11:09
Default Re: Boundary Conditions
  #2
Patrick Godon
Guest
 
Posts: n/a
Hi Jan,

Before I try to answer the questions you mentioned, let me first try to make a few things clear. There are, if I might say, several 'levels' of implementing boundary conditions on the Navier-Stokes equations, in that sens that there are several ways of doing it - starting from the completely wrong approach and ending with the exact mathematical approach.

So let's first try to make things clear (assume one dimension only, to make things simple).

Any partial differential equation (mass equation, momentum equation, energy equation) has a degree, which means the order of the derivative. First derivative in space = first degree, etc.. For each degree one needs to specify on condition at ONE boundary only. First degree equations have only advective terms (first derivatives) while second degree equations have also diffusive terms (second derivatives, for example due to the viscous terms, etc..). so:

first degree equations (density equation, momentum equation without viscosity, energy without radiation) need only one condition at ONE boundary.

second degree equations (momentum - or if you prefer velocity - equations with viscous terms, energy equation with radiation in the diffusion approximation, etc..) need two conditions - one at each boundary.

So if you add a density equation (compressible flow) then you need to implement this equation by prescribing the boundary condition at one boundary only.

While for the viscous velocity equations you need to prescribe the boundary conditions at both boundaries.

Now to PRESCRIBE means that there you must have a value for the variable (density, velocity, pressure) defined with some physical meanings. That means that you must know how look the flow outside your domain (at the boundary). Which is a bit tricky since it is what you actually meant to solve for. So what you do: you find an approximation for these values, for example a steady state solution of the simplified problem, that you already know from some analytical treatments. Say P0, rho0 and v0 denote pressure, density and velocity given outside at all the boundaries.

Once you have a prescription for the variables at the boundary you have to decide how to IMPOSE the boundary condition on the variables. Most of the people would just impose the prescribed boundary conditions on the primitive variables directly, just like that (that's the wrong way of doing it)

P=P0

rho=rho0

v=v0

and in addition they would do that at both boundaries without even checking which equation is of first degree and which one of second degree. And they would have good results, because they use low order accuracy method that can smooth out all the errors they are doing (which is OK in some sens). The problems start when you do that and you have either shocks in the flow, or you use a higher order accuracy method, or are interested in the fine structure of the flow when studying turbulence for example. Then you don't want to smooth out the fluctuations of the turbulence, because you'll get a funny laminar flow.

So the way of imposing the boundary condition is by using the characteristics of the flow. The characteristics of the flow are new variables (you make a transformation of the equations until you get new variables) which are actually the physical quantities that propagate through the flow, and therefore through the boundaries themselves. So in order to be exact and avoid errors and oscillations (and reflected waves) at the boundaries, you need to imposed the boundary conditions on the characteristics of the flow, rather than on the primitive variables.

Now, I am not going to go through all that again, because it will be like writting a paper. So look for example at :

Givoli, 1991, J. Comput. Phys. 94, 1 (review paper)

Abarbanel et al. 1991 J.Fluid Mech. 225, 557

Gottlieb, Gunzburger, Turkel, 1982, SIAM J. Numer. Anal. 19, 671

Or have a look at this postscript paper, pages 6-7 postscript paper .

And also have a look at the books:

Canuto et al. 1988, SPectral Methods in Fluid Dyanmics, Springer Verlag, Berlin (section on the treatment of the boundary conditions).

Landau, Lifshitz, 1987, Fluid MEchanics (translation from the Russian Gidrodinamika or whatsoever), Oxford, Pergamon Press. The sections on the Rieman invariants and characteristics of the flow.

So now to go back to you questions:

-1) compressible are different from incompressible and you cannot use the BC from incompressible for compressible.

-2) For turbulent case I use the method of characteristics (above) where I prescribe a steady state. And the turbulent solution can propagate through the boundary without being reflected. But in your case you might be interested in something different where you introduce turbulent fluctuation in the flow through the boundaries, that 's another story I guess (kind of driven turbulence).

-3) In theory if you make a correct treatment of a 2D boundary conditions you can extand it to 3D easily.

-4) don't know, I am not using LES.

I wrote a long message, cause not too many people do care about the right way of imposing boundary conditions, though it is important.

Patrick
  Reply With Quote

Old   August 12, 1999, 11:03
Default Re: Boundary Conditions
  #3
Jan Ramboer
Guest
 
Posts: n/a
Thank you for writing the long respons. However one more question about it. You write that the way to impose b.c. when wanting to study the fine structures of the flow is to use the characteristic variables. Do you mean hereby the Rieman variables? If so, isn't this only applyable to inviscid flows?

Greetings,

Jan
  Reply With Quote

Old   August 12, 1999, 15:32
Default Re: Boundary Conditions
  #4
Patrick Godon
Guest
 
Posts: n/a
Hi Jan,

In one dimension the chracteristics of the flow are the Rieman Invariants. However, in several dimensions one has to make some assumptions. As to the viscous side of the flow, let me explain a bit more of all that.

The treatment of the boundary conditions is needed usually at an open or free boundary (not a wall), though it can also be applied (somehow) to the wall problem.

Now consider a multidimensional viscous flow with on one side a wall and on the other an open free boundary, and say for simplicity that the other 4 surfaces (in 3D we have a box in cartesian coordinates) are say periodic, or just let say that we do not consider them right now. So what I will do will be concerning only one direction: the one where at one end we have a wall and at the other an open boundary. After that the same can be applied to the other two directions with whatever boundary conditions you want (wall or/and free). I take an example of a wall and an open boundary so that you can see the difference between them, but two walls or two open boundaries would be fine too.

At the wall the viscous effects are dominant (because of the shear and friction) and one has to consider the viscous equations of the flow (full Navier-Stokes systems). At the wall one can impose the boundary conditions (BC) directly on the primitive variables without fear of numerical instability, because the viscosity should help to damp it (execpt of course for realy physical instability where the viscosity is the source of the instability).

At the open boundary the assumption is that the viscous effects are less important and accordingly one make the following (this is one way of doing it, there are other ways too):

- drop all the viscous term and consider only the (compressible) inviscid Euler equations.

- Consider the flow only NORMAL to the open boundary, since only the NORMAL velocity (say v, for short) will decide whether the flow will flow inside or outside the boundary. This means that one has to drop all the two other dimensions (directions), this is done by dropping all the derivatives in these 2 other dimensions.

Eventually one is therefore left with a one-dimensional problem, inviscid.

- The next step is to consider only the homogeneous system, i.e. to drop all the source terms (if any) in the one-dimensional systems of equations obtained above.

In each equations so obtained, one is left with a time derivative term and several space derivative terms, all the rest has been dropped. In order to solve the system one usually make a linearization of the equations. In matrix form, the system is then transformed to find the eigenvectors and the eigenvalues of the systems. The eigenvectors are actually the characteristics of the flow and the eigenvalues are the speed of propagation of the characteristics (usually v, c+v and c-v are the three eigenvalues, where c is the sound speed). Then one has to check (according to the values of the eigenvalues - positive or negative and the location of the boundary) which characteristic is outgoing and which one is incoming. On the outgoing characteristics one has to imposed the value from the flow computed inside the domain (or an extrapolation of these values), on the incoming characteristics one has to impose the values prescribed at the boundary (the physical values which are given at the boundary, say p=p0, rho=rho0 and v=v0 or whatever you choose; derivatives are also OK). At this stage what is left is to solve back for the primitive variables using the values imposed on the characteristics of the flow.

All this is treated in more details in the postscript paper I refered too in my previous posting.

There are other ways of doing that and one of them is to solve directly the characteristics equations numerically (integrating them, not solving them analytically like here). Some of them are just refered to as MOC, method of characterics, they are all the same in principle, but different in the details. In addition for simple flow (e.g. polytropic flow, where the pressure = the density to some power greater than one), one can solve analytically the Rieman invariants (without linearization). See the reference I gave you on Landau and Lifshitz, or again the postscript paper.

When you want to study the fine structure of the flow then you use a high order accuracy method or something equivalent, where you have little numerical diffusion, so that you will not smooth out all the little details of the flow. IN this case there will probably not be enough numerical dissipation to smooth out numerical oscillations that originate at the boundary (due to the imposition of the BC on the primitive variables). If this is the case and you get oscillations emanating from the boundary then you want to consider imposing the BC on the characterics. The flow might be just fine untill for example you get a shock in the flow. When the shock is going to reach the boundary it will be reflected inwards into the computational domain, then you know for sure that you need to use the characteristics.

By the way, I know that LES means Large Eddy simulations, but does it refer to a specific method or just to any method solving turbulence on the large scales? Are you interested in solving only for the largest Eddies (largest vortices)? Then you would not need to resolve the fine structure of the flow and in this regime the BC on the primitive variables might be enough.

Cheers, Patrick
  Reply With Quote

Old   August 13, 1999, 05:12
Default Re: Boundary Conditions
  #5
Jan Ramboer
Guest
 
Posts: n/a
Hi Patrick,

Thanks alot again for the explanation. It seems that I am learning fast from the discussion on this forum. Concerning your assumptions, another question. You assume that the viscous effects are neglectable at the open boundary. OK so far, lets say my open boundary is y=constant and my wall boundary is x=constand. Than there is in the corner a connection between the open boundary and the wall boundary. Since close to the wall we have a boundary layer, which is viscous, is the inviscid assumption for the open boundary still valid overthere? Or can you neglect the error resulting from that? Large Eddy Simulation is a procedure where you solve the NS-equations for a certain length-scale (by means of filtering), the turbulent energy for the lower scales is modelled. It is something in between DNS and RANS. For certain cases you might be interested in the fine structure of the flow (computational aeroaccoustics for example), for other not.
  Reply With Quote

Old   August 13, 1999, 10:24
Default Re: Boundary Conditions
  #6
Patrick Godon
Guest
 
Posts: n/a
Hi Jan,

Coner points are always more difficult to treat than the rest and can always be a source of problems. In some cases the corner point will actually be solved twice (e.g. if there are two free boundaries meeting there). Once there is only one free boundary and a wall, then of course you can assume the velocity at the corner to be zero in both directions (that of the wall and perpandicular to it). Then you can impose zero velocity directly on the primitive variable for the direction perpandicular to the wall and zero through the characteristics parallel to the wall.

Here you must remember the following, the treatment is first of all an approximation (as is the whole process of solving for the flow) and each problem in particular might need a different approach. Sometimes, one needs to carry out different BC to check what works the best.

Another important details: when you impose the BC on the characteristics of the flow, you actually allow for any fluctuation to propagate through the boundary. Therefore, the effect of the viscosity, which are 'felt' in the vicinity of the wall do propagate through the open boundary, and you can obtain there a velocity which is different (in this case smaller) than the velocity given there (since the velocity is imposed through the value taken by the characteristics - again see that postscript paper and the references I gave you). As a specific example, if at the open boundary you decide that the velocity prescribed is say v0, and you impose it through the characteristics, then at this boundary the value actually taken by v will not be v0. It can fluctuate (time dependent problem) and can vary substantially from v0. Only if the flow becomes steady and stable then v can approach v0 (assuming of course that v0 is the steady state solution). If v0 was a 'wrong' guess of the value expected outside, then you might well be left with v different than v0, eventhough you reached steady state (e.g. this would mean that the flow inside the domain is still affecting the flow outside the domain, i.e. the boundary has not been placed far enough, etc..).

Bak to LES. I understand that LES is therefore getting rid of the smallest scale (using a filter) and you are left with the large scale. Then of course you the fine structure of the flow is affected (I do not know what are DNS and RANS). Is there any hyperviscosity in these modeling? I am myself just using a spectral method with some (hyper)viscosity and weak spectral filtering to model 2D decaying turbulence in rotating flows. Whether I resolve the small scales or not depends on the resolution and the viscosity (the filer is just for numerical stability to get rid of the aliasing errors). The same is done for example for the modeling of turbulence in planetary atmosphere (Shallow Water Equations), but these are never refered to as LES, RANS neither DNS. So what is the difference between all of these and the method I use?

Cheers, Patrick
  Reply With Quote

Old   August 13, 1999, 11:07
Default Re: Boundary Conditions
  #7
Jan Ramboer
Guest
 
Posts: n/a
Hi Patrick,

I am not really familiear (yet) with spectral methods since I just started my phd. RANS= Reynolds Averaged Navier Stokes, which is used most of the time, no? DNS= Direct Numerical Simulation which means no averaging or modelling, straight calculation. But requires a really fine mesh, thus lots of cpu-time. With LES, if you use a simple modelling you can just use your solver for RANS, only you add a turbulent viscosity which is modeled based on your filter width etc... If you want to know more, let me know than I'll look up some references.

Greetings,

Jan
  Reply With Quote

Old   August 13, 1999, 11:26
Default Re: Boundary Conditions
  #8
Patrick Godon
Guest
 
Posts: n/a
Hi Jan,

Thanks for the details. Then I guess what I am doing is DNS. Spectral methods are high order accuracy methods and therefore you need less grid points to get the same accuracy as a low order method (e.g. finite differences). Spectral methods consists in expanding the functions (density, velocities, etc..) as series of polynomials (e.g. Fourier, exp-ikx). Then the spatial derivaties is approximated by differentiating the polynomials (e.g. by multiplying by -ik for the Fourier series, etc..).

I have been also modeling flows where the turbulent stress is introduced in the equations (Reynolds stress tensor), in the Boussinesq approximation. There I solve for a flow that looks like laminar, but the viscosity is due to the turbulence that exists in the real flow. So the modeling is done for the averaged flow indeed. I gues this is close to RANS.

Cheers, Patrick
  Reply With Quote

Old   August 13, 1999, 11:54
Default Re: Boundary Conditions
  #9
Jan Ramboer
Guest
 
Posts: n/a
Hello Patrick,

Your method is not really DNS. I think that spectral methods are a class on its own. In DNS you really discretize the NS-equations as they are.

Greetings,

Jan
  Reply With Quote

Old   August 13, 1999, 12:24
Default Re: Boundary Conditions
  #10
Patrick Godon
Guest
 
Posts: n/a
HI Jan,

Here it seems I lost you somewhere. With the spectral code I do solve the full Navier-Stokes equations as they are on a grid of points. The spatial derivaties are evaluated using the polynomial expansion and the time using a usual scheme like 4th Runge-Kutta or other. In what would DNS be different from that? What do you mean by discretize? I am working with discrete Fourier transforms, not continue transforms. I am not sure I follow you. WOuld be nice if you could clarify that for me. Thanks.

Cheers, Patrick
  Reply With Quote

Old   August 16, 1999, 06:20
Default Re: Boundary Conditions
  #11
Anders Ostman
Guest
 
Posts: n/a
I have followed your discusion about BC, and found it interesting, now I can try to contribute to the DNS discusion. It is not the field I'm specialized in but, here is the way I understand it.

If you want to solve NS by means of DNS, the grid size has to be smaler than the smallest vortex, or length scale of the turbulence. I.e smaler than the length scale assosiated with the viscous dissipation (the Kolmogorov length scale). And the grid cells has to be of this size in the WHOLE computational domain. The small grid cells lead to small time steps. This type of computations are therefor extreamly CPU demanding. Furthermore, you are intrested in the mean values of the flow, and has therefor to compute for a long time to be able to calculate statistics of the flow.

This holds for a computation by means of a finite volume, or finite differance method. I don't know if you can have larger grid sizes if you use specral metods where you approximate series of polynomials. But I guess that you can not resolve smaler wave lengthes than the distance between two neighbouring node points with that metod either.

Greetings,

Anders

  Reply With Quote

Old   August 16, 1999, 09:59
Default Re: Boundary Conditions
  #12
Patrick Godon
Guest
 
Posts: n/a
Hi Anders,

Thanks for adding some details. Yes of course if you simulate turbulence you need to be able to resolve two ranges of scales. One which is usually refered to as the inertial range where the direct (in 3D) cascade of energy takes place the and spectrum is Kolmogorov. The other scale is smaller and is where the energy is dissipated due to the viscous effect. There the slope of the spectrum is larger than for the Kolmogorov. This is what I usually do: I check the turbulent spectrum of the kinetic energy of the flow and make sure I have the two slope in the spectrum. Since I am dealing with a two-dimensional flow that is compressible, instead of having a Kolmogorov 'slope' I have a flat slope in the largest scales, while I make sure that the smallest scale are damped by the viscosity (there I have a slope of -3, -4).

This was the only way I knew to simulate turbulence and according to what I understood it is the Direc Numerical Simulations (DNS). Spectral method are actually ideal for that since they are extremely accurate and do not affect the slope of the spectrum (little or no numerical diffusion). Now the more grid points you take, the lower the viscosity you can put in your model, and therefore the smallest the scale of the Eddy you can resolve. The viscosity I refer to is the hyperviscosity, i.e. introduced to dissipate the energy in the smallest wavelenght. I am running my code for weeks and even months, on many dynamical timescale, with resolution of up to 256 points (in each direction), which is equivalent to a finite difference of about 1000 points.

PG
  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
Impinging Jet Boundary Conditions Anindya Main CFD Forum 25 February 27, 2016 13:58
symmetry boundary conditions in cfx lost.identity CFX 41 May 22, 2013 08:21
OpenFOAM Variable Velocity Boundary Conditions NickolasPl OpenFOAM Programming & Development 2 May 19, 2011 06:37
[Netgen] boundary conditions and mesh exporting vaina74 OpenFOAM Meshing & Mesh Conversion 2 May 27, 2010 10:38
[Commercial meshers] Trimmed cell and embedded refinement mesh conversion issues michele OpenFOAM Meshing & Mesh Conversion 2 July 15, 2005 05:15


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