MATH 676 – Finite element methods in scientific computing Wolfgang Bangerth, Texas A&M University http://www.dealii.org/ Wolfgang Bangerth Lecture 33.25: Which element to use Part 2: Saddle point problems http://www.dealii.org/ Wolfgang Bangerth Stokes Consider the stationary Stokes equations: −Δ u+∇ p = f ∇⋅u = 0 This can equivalently be considered as a minimization problem: minu ∈H (Ω) 1 1 2 ∥∇ u∥ −(f , u) 2 ∇⋅u = 0 d such that Let us consider the constraint in variational form: minu ∈V =H (Ω) 1 such that http://www.dealii.org/ d 1 2 ∥∇ u∥ −(f ,u) 2 2 (q , ∇⋅u) = 0 ∀ q ∈Q=L Wolfgang Bangerth Stokes Consider the stationary Stokes equations: −Δ u+∇ p = f ∇⋅u = 0 The discrete formulation for this seeks uh ∈V h ⊂V , p h ∈Q h⊂Q : (∇ v h , ∇ u h )−( ∇⋅v h , ph )−(q h , ∇⋅uh ) = (v h , f ) ∀ v h ∈V h , q h ∈Q h This corresponds to the finite dimensional minimization problem minu ∈V h h such that http://www.dealii.org/ 1 2 ∥∇ uh∥ −( f ,u h ) 2 (q h , ∇⋅u h ) = 0 ∀ q h ∈Q h Wolfgang Bangerth Stokes Consider the discrete Stokes equations: minu ∈V h h such that 1 2 ∥∇ uh∥ −( f ,u h ) 2 (q h , ∇⋅u h ) = 0 ∀ q h ∈Q h Here, we have dim Qh constraints on the velocity uh. Intuitively, if (asymptotically) Qh is “too large” compared to Vh, then: ● we have too many constraints on the velocity ● the velocity does not have enough degrees of freedom. In this case the discrete solution may not converge. http://www.dealii.org/ Wolfgang Bangerth Stokes Consider the discrete Stokes equations: We only get convergence of discrete solutions of (∇ v h , ∇ uh )−( ∇⋅v h , ph )−(q h , ∇⋅u h ) = (v h , f ) or equivalently minu ∈V h h such that ∀ v h ∈V h , qh ∈Qh 1 2 ∥∇ uh∥ −( f ,u h ) 2 (q h , ∇⋅u h ) = 0 ∀ q h ∈Q h if the inf-sup/Babuska-Brezzi/LBB condition is satisfied: There exists a constant c independent of h so that sup v ∈V h h (∇⋅v h , q h ) ≥ c∥qh∥Q ∥v h∥V ∀ q h ∈Q h Note: V=H1, Q=L2. http://www.dealii.org/ Wolfgang Bangerth Stokes The inf-sup condition: We can write the condition either as: There exists a constant c independent of h so that sup v ∈V h h (∇⋅v h , q h ) ≥ c∥qh∥Q ∥v h∥V ∀ q h ∈Q h Or as: There exists a constant c independent of h so that inf q ∈Q sup v ∈V h http://www.dealii.org/ h h h (∇⋅v h , q h ) ≥ c ∥v h∥V ∥q h∥Q Wolfgang Bangerth Stokes The inf-sup condition: The condition... There exists a constant c independent of h so that sup v ∈V h h (∇⋅v h , q h ) ≥ c∥qh∥Q ∥v h∥V ∀ q h ∈Q h ...can be satisfied by making ● the velocity space Vh large enough ● the pressure space Qh small enough Typical choices (the “Taylor-Hood element”): ● Vh = Pk+1 , Qh = Pk on triangles/tetrahedra ● Vh = Qk+1 , Qh = Qk http://www.dealii.org/ on quadrilaterals/hexahedra Wolfgang Bangerth Stokes Why Taylor-Hood (Pk+1/Pk or Qk+1/Qk): ● Pk/Pk or Qk/Qk is not stable: – the constant c goes to zero as h→0 – the matrix has a near-nullspace – the pressure develops a “checkerboard pattern”: (using step-22 with equal order elements) Consequence: We need to make the velocity space larger or the pressure space smaller! http://www.dealii.org/ Wolfgang Bangerth Stokes Why Taylor-Hood (Pk+1/Pk or Qk+1/Qk): ● Pk+1/Pk or Qk+1/Qk is stable: – there is a constant c>0 – the matrix remains regular – the pressure is stable (using step-22 with non-equal order elements) Consequence: This works! http://www.dealii.org/ Wolfgang Bangerth Stokes Why Taylor-Hood (Pk+1/Pk or Qk+1/Qk): ● Pk+2/Pk or Qk+2/Qk is stable: – there is a constant c>0 – the matrix remains regular – the pressure is stable (using step-22 with non-equal order elements) – accuracy is now limited by the low-order pressure Consequence: This choice is wasteful! http://www.dealii.org/ Wolfgang Bangerth Stokes Why Taylor-Hood (Pk+1/Pk or Qk+1/Qk): ● Pk/Pk or Qk/Qk doesn't work ● Pk+1/Pk or Qk+1/Qk works ● Can we find something in between? Option 1: With a slightly smaller velocity space. ● ● We can't take away shape functions without either – violating unisolvency – making the shape functions discontinuous (which would make the element non-conforming) This option doesn't work http://www.dealii.org/ Wolfgang Bangerth Stokes Why Taylor-Hood (Pk+1/Pk or Qk+1/Qk): ● Pk/Pk or Qk/Qk doesn't work ● Pk+1/Pk or Qk+1/Qk works ● Can we find something in between? Option 2a: With a slightly larger pressure space. ● Recall the bilinear form: (∇ v h , ∇ u h )−( ∇⋅v h , ph )−(q h , ∇⋅uh ) = (v h , f ) ● ● ● We don't actually need continuity of the pressure We could try Qk+1/Qk+DGQ0 This actually works! http://www.dealii.org/ Wolfgang Bangerth Stokes Why Taylor-Hood (Pk+1/Pk or Qk+1/Qk): ● Pk/Pk or Qk/Qk doesn't work ● Pk+1/Pk or Qk+1/Qk works ● Can we find something in between? Option 2b: With an even larger pressure space. ● Recall the bilinear form: (∇ v h , ∇ u h )−( ∇⋅v h , ph )−(q h , ∇⋅uh ) = (v h , f ) ● ● ● We don't actually need continuity of the pressure We could try Qk+1/DGQk This doesn't work, too many pressure degrees of freedom http://www.dealii.org/ Wolfgang Bangerth Stokes Choosing a polynomial degree: We could choose either ● Pk+1/Pk or Qk+1/Qk ● Qk+1/Qk+DGQ0 In practice one typically chooses k=1: ● There are 2*32+22=22 (3*33+23=89) degrees of freedom per cell in 2d (3d) ● On a uniform mesh, matrix rows may have up to – 2*52+32 = 59 – 3*53+33 = 402 entries ● k>1 yields better accuracy, but matrix starts to get full http://www.dealii.org/ Wolfgang Bangerth Mixed Laplace Consider the mixed Laplace equations: u+ ∇ p = 0 ∇⋅u = f This can equivalently be considered as a minimization problem: minu ∈H (Ω) 1 1 2 ∥u∥ 2 ∇⋅u = f d such that Let us consider the constraint in variational form: minu ∈V =H (Ω) 1 such that http://www.dealii.org/ d 1 2 ∥u∥ 2 (q , ∇⋅u) = (q , f ) ∀ q ∈Q=L 2 Wolfgang Bangerth Mixed Laplace Consider the mixed Laplace equations: u+ ∇ p = 0 ∇⋅u = f The discrete formulation for this seeks uh ∈V h ⊂V , p h ∈Q h⊂Q : (v h ,uh )−( ∇⋅v h , p h )−(q h , ∇⋅u h ) = −(q h , f ) ∀ v h ∈V h , qh ∈Qh This corresponds to the finite dimensional minimization problem minu ∈V h h such that http://www.dealii.org/ 1 2 ∥u h∥ 2 (q h , ∇⋅u h ) = (q h , f ) ∀ q h ∈Q h Wolfgang Bangerth Mixed Laplace Consider the discrete mixed Laplace equations: We only get convergence of discrete solutions of (v h ,uh )−( ∇⋅v h , p h )−(q h , ∇⋅u h ) = −(q h , f ) ∀ v h ∈V h , qh ∈Qh or equivalently minu ∈V h 1 2 ∥u h∥ 2 (q h , ∇⋅u h ) = (q h , f ) h such that ∀ q h ∈Q h if the inf-sup/Babuska-Brezzi/LBB condition is satisfied: There exists a constant c independent of h so that sup v ∈V h h (∇⋅v h , q h ) ≥ c∥qh∥Q ∥v h∥V ∀ q h ∈Q h Note: V=H(div), Q=L2. http://www.dealii.org/ Wolfgang Bangerth Mixed Laplace We have the same situation as before: The condition... There exists a constant c independent of h so that sup v ∈V h h (∇⋅v h , q h ) ≥ c∥qh∥Q ∥v h∥V ∀ q h ∈Q h ...can be satisfied by making ● the velocity space Vh large enough ● the pressure space Qh small enough http://www.dealii.org/ Wolfgang Bangerth Mixed Laplace One common choice: ● Vh = Pk+1 , Qh = Pk on triangles/tetrahedra ● Vh = Qk+1 , Qh = Qk on quadrilaterals/hexahedra This is again the Taylor-Hood element. It is stable We can play the same game: ● ● Can we make the velocity space smaller? (Less numerical effort with essentially same accuracy.) Can we make the pressure space larger? (Better accuracy with only slightly more work.) http://www.dealii.org/ Wolfgang Bangerth Mixed Laplace Option 1: Make velocity space smaller. ● Vh = Qk+1 , Qh = Qk works ● Vh consists of continuous functions so that we can take the (weak) gradient, which we needed for Stokes: (∇ v h , ∇ uh )−( ∇⋅v h , ph )−(q h , ∇⋅u h ) = (v h , f ) ● But we don't need this for mixed Laplace: (v h ,u h )−( ∇⋅v h , p h )−(q h , ∇⋅uh ) = −(q h , f ) ● ∀ v h ∈V h , qh ∈Qh ∀ v h ∈V h , q h ∈Q h All we need is that the divergence is defined. http://www.dealii.org/ Wolfgang Bangerth Mixed Laplace Option 1: Make velocity space smaller. We need: An element with continuous normal vector component but possibly discontinuous tangential component. This is the Raviart-Thomas element. This works: Replace ● Vh = Qk+1 , Qh = Qk by ● Vh = Raviart-Thomas(k), Qh = Qk if k>0 ● Vh = Raviart-Thomas(0), Qh = DGQ0 if k=0 http://www.dealii.org/ Wolfgang Bangerth Mixed Laplace Option 2: Make pressure space larger. Recall the bilinear form: (v h ,u h )−( ∇⋅v h , p h )−(q h , ∇⋅uh ) = −(q h , f ) ∀ v h ∈V h , q h ∈Q h We don't need a continuous pressure. This works: Replace ● Vh = Raviart-Thomas(k), Qh = Qk if k>0 ● Vh = Raviart-Thomas(0), Qh = DGQ0 if k=0 Vh = Raviart-Thomas(k), Qh = DGQk (see step-20) by ● http://www.dealii.org/ Wolfgang Bangerth Mixed Laplace Option 3: Alternatives There are any number of alternatives to the Raviart-Thomas element: ● Brezzi-Douglas-Marini (BDM) ● Arnold-Falk-Winther ● … ● ● ● ● Most of these use piecewise constant pressures at lowest order This leads to very slow convergence (O(h)) For practical applications: use higher orders Elements are relatively “sparse”, i.e., not too many DoFs http://www.dealii.org/ Wolfgang Bangerth MATH 676 – Finite element methods in scientific computing Wolfgang Bangerth, Texas A&M University http://www.dealii.org/ Wolfgang Bangerth