omputtionl Fluid Dynmics Lecture 6 Spce differencing errors. ψ ψ + = 0 Seek trveling wve solutions. e ( t) ik k is wve number nd is frequency. =k is dispersion reltion. where is phse speed. =, true solution is non dipersive for constnt. k note tht the group velocity,, the speed of energy propgtion is defined s g = nd order sptil differences. g = g, in this cse φ j φj+ φj + = 0 seek discrete solutions. e ( t) ikj () t ik ik e e ie + e k = φ ( ) ( ) ik ik e e = i = sin ( k) = sin k = k sin k = k j ikj t ikj t Note tht this is the sin c ( ) sin sin function,, which hs the nice property s 0.
Which is function of k, dispensive unlike solutions to the true dvection eqution. For good resolution k nd Tylor series sin 6 ( k) 6 Phse speed error is time lgging nd second order. Phse error lrger for lrger π π k =, λ, k = λ π sin = = 0 π k, worst cse is: The phse speed of the wve is zero. Noise doesn t propgte t ll. Since is rel, there is no chnge in wve mplitude with time, nd no mplitude error. The group velocity of wves = cos kis pproimte correct for smll k. π But for poorly resolved wves, lrger k, 0< k < = cosπ = nd the energy propgtion for poorly resolved wves is = The energy propgtes bckwrds! Fourth Order Accurcy φ 4 φ φ φ φ + 4 4 4 = sin k sin k 6 j j+ j j+ j. No mplitude error. - rel. Wves re dispersive.
. Phse speed of wve is 0. ( k) 4 4 4 = k 0 hs smller phse speed errors tht * for smll k. 4 4 = cos k cos k for λ = 4 =, even lrger error. Evidently schemes hve indequte performnce for poorly resolved flow fetures.
All finite difference schemes re unble to propgte the wve, higher order schemes hve better properties for better resolved wve lengths. One-sided differences hve similr (worse) problems. onsider φ ( φj φj ) j + = 0 ik e i e + e ik f = ( e ) = i f = sin k + i( cos k ) ( ) ( ) ikj t ikj t rel prt is sme s for = 0 but now there is n imginry prt lso, so tht there is n mplitude ( ) cos k t error (growth or decy) e for > 0 the solution dmps (stble). For < 0, flow unstble; domin of dependence is not cptured. Lrgest wve numbers get dmped the most. (This is good) A third order upstrem difference. φ j + 6 gives f ( φj+ + φj 6φj + φj ) 4 i = sin k sin k cos k 6 ( ) 4
rel prt is identicl to 4 th order scheme, but the imginry prt shows tht it is mplifying for < 0 nd dmping for > 0. The dmping is much smller for rd order thn st order. Dissiption, Dispersion nd the Finite Difference Eqution onsider first order sptil difference uj u u u u 6 j = + + σ nd order sptil difference u u u u 6 j+ j 4 = + + σ rd order ( ) ( ) u + u 6u + u u u u 6 0 ( ) 4 4 j+ j j j 6 = + + σ 4 th 4 order 4 u u u u u u 4 0 4 j+ j j+ j 6 = + σ ( ) If ny of these formuls re used in dvection eqution, we relly get modified eqution. u u u u + = + b + m+ m+ m+ m+ + m+ m m ( ) ( ) σ ( ) when pproimted with scheme tht is of order ( ) m. So s 0 we get good representtion of desired PDE, but it pproches the modified eqution more rpidly thn the PDE. Qulittive response of the leding error terms Suppose. m u u = m If the leding error term is even (m) s occurs for upwinding, nd then dditionl diffusion or dissiption is the leding order behvior of the differencing scheme. Shorter wvelengths decy more rpidly thn longer modes.
This is desirble nd referred to s numericl dissiption, in the pproimte solution of the dvection eqution. Solutions re of the form (, ) u t m ik k t = e e If the odd-order derivtive terms (m + ) re the leding order trunction error, s in the cse of centrl differences, it hs effect like m+ u u = m+ which hs solution (, ) u t = e ( t) ik ( ) where = m k m+ ( ( )) for m> 0 these re dispersive wves. f k So this would yield numericl dispersion (undesirble). 4 u entered differences (most common) hve, i.e. ( ) type errors s leding order. entered sptil differences do not produce numericl dissiption becuse there re no even derivtives in trunction errors. There is numericl dissiption in one-sided, upwind, differences, nd lso numericl dispersion. Note tht one-sided schemes hve the sme dispersion errors s the higher order centered scheme, but they dd dissiption lso. The net behvior is different; dispersion is diffused in upwind schemes. Net Topic: Eploiting trunction errors to our dvntge. 6
Emple for HW # M= = 0 b c = 0 u + = n 0 b c n n n µ u + + u + + µ u + = u b c n n n 4 n n µ u + u + µ u = u µ u + u + µ u = u u n+ n+ n+ n+ n 4 4 = 0 [ ] n+ n A u = u = 0 b = c = 0 = µ b = c = µ = µ b = c = µ = µ b = c = µ 4 4 4 = b = c 0 = 0 N = ( bcu f N) ll tridg,,,,, 7