<!DOCTYPE html> 9 Time-dependent Viscous Flows‣ Notes on the Finite Element Method
Notes on the Finite Element Method

Chapter 9 Time-dependent Viscous Flows

9.1 Equations and Boundary Condition.

𝒖t=-p+ν2𝒖. (9.1)

where ν represents the kinematic viscosity. For incompressible flow, the mass conservation equation is:

𝒖=0, (9.2)

9.1.1 Analytic Solution

Consider the channel illustrated in figure LABEL:Fi:C6S1ShowPoseuille. Initially, for t0, the velocities are everywhere zero. At t=0 the pressure difference across the channel is set equal to one. How does the velocity change? The solution to the steady flow problem has been described in Chapter 6, where the axial velocity u is show to vary parabolically across the width of the channel (equation 6.5)

Batchelor, Chap 4, pp 193-194, shows that equation 9.1 can be made homogeneous by introducing a new dependent variable:

u=u+12νpx(1-y2) (9.3)

Look for a solution where v is everywhere zero, so that u is independent of x, the equation for u is:

ut=ν2uy2;u(-1,t)=u(1,t)=0,u(x,y,0)=12νpx(1-y2). (9.4)

Solutions of the form

u=Ancosnπy2e-λn2νt,n=1,3,5 (9.5)

exist so long as:

λn=±nπ2 (9.6)

The constants An are determined by the initial condition:

An=16νn3π3pxsinnπ2. (9.7)

The analytic solution is then:

u(x,y,t)=-12νpx[(1-y2)+16n3π3nsinnπ2cosnπy2e-λn2νt],n=1,3,5 (9.8)

This solution is illustrated in figure 9.1.

Poiseuille flow initiated by a suddenly imposed pressure
gradient,

Figure 9.1: Poiseuille flow initiated by a suddenly imposed pressure gradient, p/x=-2, with kinematic viscosity ν=1. The analytic solution (black) is indistinguishable from the FEM solution (red). The mesh is 3×3.

9.2 Finite Element Method

The weak form of equations 9.1 through 9.2 can be written

ut+ν𝒦u=-𝒢xp (9.9)
vt+ν𝒦v=-𝒢yp (9.10)
𝒟xu+𝒟yv=0 (9.11)

The system of constrained global equations can be written as:

9.2.1 Open BC in terms of pressure.

Weak Form

For linear TF, the stiffness matrix is given by equation 6.16. In this case the gradient matrices are the same: 𝒟x=𝒢x and 𝒟x=𝒢x.

Assembly

Since the pressure is specified at the boundaries, there is no ambiguity regarding the mean presseure nor any need for imposing a constraint. In matrix form equations 6.10 through  6.12 are

[0000000]𝒔t+[ν𝒦0𝒟x0ν𝒦𝒟y𝒟x𝒟y00010]𝒔=𝒫𝒔t+𝒔=0 (9.12)

where is the usual mass matrix. The zero in the lower right corner of the left lost matrix remains a concern, notably when the transient problem is forced by velocity.

The trapezoidal is adopted as a scheme to step the equations forward in time.

Consider the grid illustrated in figure LABEL:Fi:C4S2simplegrid. The grid has 9 nodes; there are three variables: u,v and p. the total number of variabless is 27 of which 18 are prescribed at the boundaries (six BC on both u and v and six more on p) and 9 variables are unknown. The problem for the unknown variables is then:

The solution is compared with the analytical solution on figure  9.1. The agreement is excelent.

9.2.2 Open BC in terms of velocity.

If the preceeding scheme were applied to the situation where pressure is unknown everywhere, but the velocity is given on three of the four boundaries, there would be four unknown velocities (two u and two v) and nine unknown p. Just as was found in chapter 6, it is possible to show that if the number of unknown pressure values exceeds the total number of unknown velocities, the matrix L~ is singular. The accepted solution is to use different order polynomials for velocity ϕn (e.g. quadratic polynomials) and for pressure ϕnp (linear polynomials). In this case the matrix form is:

[00000000000000]𝒔t+[ν𝒦0𝒢x00ν𝒦𝒢y0𝒟x𝒟y010010]𝒔=𝒫𝒔t+𝒔=0 (9.13)

where now the 𝒢s and 𝒟s are no longer the same, and a constraint is included on the mean pressure.

Assembly

Consider now the reverse of the problem described in 9.2.1: Poiseuille flow is built up by increasing the velocity at the x=-1 boundary according to equation 9.8. The computed pressure constant shoul be constant in time.

Just refer to Chap 6 figure2.

Poiseuille in a simple grid consisting of two elements each
oulined by black lines. Black squares and numbers identify nodes
where the pressure is evaluated, Velovity is evaluated at all
notes (black and red). Velocity is prescribed at all nodes except
6 and 9.

Figure 9.2: Poiseuille in a simple grid consisting of two elements each oulined by black lines. Black squares and numbers identify nodes where the pressure is evaluated, Velovity is evaluated at all notes (black and red). Velocity is prescribed at all nodes except 6 and 9.

Any element has three vertices, where pressure is evaluared and a total of six nodes where the velocity is evaluated: the three vertices supplemented by three mid-point along the element boundaries.

Even with this scheme in place, the pressure is only determined to within a constant which would still cause the matrix to be singular. This problem has been encountered in Chapter 4. It can be dealt with by adding a Lagrange multiplier to the problem, as discussed in Chapter 4, section 4.3.1. The global problem can now be written

[𝒦0𝒢x00𝒦𝒢y0𝒟x𝒟y010010][uvpλ]=𝒔=0,where𝒔=[uvpλ] (9.14)

9.2.3 Discretization in Time.

Equation LABEL:sec:C9S2:DBC is discretized through the trapezoidal rule:

(𝒫~+δt2~)𝒔~t+1=(𝒫~-δt2~)𝒔~t-δt(𝒫^𝒔^t+^𝒔^), (9.15)

9.2.4 Assembly

[𝒟x𝒟y0t+𝒦0𝒢x0t+𝒦𝒢y][uvp]=0 (9.16)

9.3 Transient Poiseuille Flow

Define response time.This response time determined by speed of sound.

9.3.1 Stiff Problems

Read: https://en.wikipedia.org/wiki/Stiff_equation

Consider a damped spring-mass system:

md2ydt2+rdydt+ky=0y(0)=0,dydt(0)=0 (9.17)

where the spring constant k=101 and the damping coefficient r=100 are lage and nearly equal. Maxima gives the solution as:

100e-t99-e-100t99 (9.18)

To step equation 9.17, rewrite it as a system of two first order ODE’s:

ddt𝒔=[-101-10010]𝒔=𝒦𝒔where𝒔=[gy] (9.19)

If the trapezoidal rule is used to discretize in time, The system of equations is

(-δt2𝒦)𝒔t+1=(+δt2𝒦)𝒔t (9.20)

The result is illustrated id figure xx (blue line). The time step, δt=0.1 is selcted on the basis that except for a very small time initially, the solution is expected to decay as exp(-t). The initial large oscillations of the derivative g=dy/dt are sometimes referred to as ringing. This behavior is symtomatic of stiff11 1 no relation to the stiffness matris described elsewhere problems. To understand what is happening, consider the one step growth factor called 𝑮 in Strang’s book. Need 𝑮<1 For Trapezoidal, if du/dt=au

𝑮=1+aδt/21-aδt/2 (9.21)