You are on page 1of 209
C.A.J. Fletcher Computational Techniques for Fluid Dynamics 1 Fundamental and General Techniques Second Edition With 138 Figures Springer-Verlag Berlin Heidelberg NewYork London Paris Tokyo Hong Kong Barcelona Springer Series in Computational Physics Editors: R. Glowinski M. Holt P-Hut H.B, Keller J. Killen S.A. Orsay V/V. Resanov ‘A Computational Method in Plasma Physics F Baves, 0. Betancourt, P. Garabedian Implementation of Fate Element Methods for Naver Stokes Equations F Thomaseet, Fite-Ditfrence Techniques for Vctorized Flukd Dynamics Calculations ated by D- Book ‘Unsteady Viscous Flows. D..Telinis Computational Methods for Fluid Flow. R. Peytet,T-D. Taylor ‘Computational Methods in Bifurcation Theory and Dissipative Stroctares, M. Kobicek, M. Marek Optimal Shape Design for Eliptic Systems. 0. Pironneau ‘The Method of Differential Approximation. Yo. Shokin ‘Computational Galerkin Methods. C.J, Fletcher "Namerical Methods for Nonlinear Variational Problems RGlowinski [Numerical Methods in Flsid Dynamis, Second Edition M-Holt Computer Studies of Phase Transitions 0-6: Mouriten Finite Element Methods a Linear Idea! Magnetohydrodynamics Gruber J Rappae [Numerical Simulation of Plasmas. YN. Dnestrvsii,D.P. Kostomarov Compottional Methods for Kinetic Model of Magnetically Confined Plasmas J Killeen, G.D. Kerbel, M-C. McCoy, A.A: Minin, ‘Spectral Methods in Fsid Dynamics. Second Edition €.Canuto, M.¥. Hussain, A" Quarteroni, TA. Zang (Computational Techniques for Fuld Dynamics 1, Second Edition Fundamental and General Techniques. “CAI, Fletcher Computational Techniques for uid Dynamics 2. Second Eiition Specific Techniques for Ditferent Flow Categories. C. A.J Fletcher “Methods forthe Localization of Singularities in Numerical Solutions of| ‘Gas Dynamics Problems. E.V. Vorozhsoy,N.N, Yanenko ‘Ciasical Orthogonal Polynomials ofa Discrete Variable ALE Nikiforov, 8. K. Suslo, VB. Uvarov lox Coordinates and Magnetic Fel Structure: ‘Guide oa Fundamental Too of Plasma Theory W.D.Dhaeseleer, WIN-G, Hitenon, J.D. Calls, JL, Shohet nd Critical Phenomena Dr. Clive A.J. Fletcher Deparment of Mechanical Engintering, The Univer f Syne New South Wales 200, Austra, Ecltors H.B. Keller Brestone Laborory R. Glowinski (Clflori stat Technology fetAutomatgue (INRIA) ‘Domaine de Voluceau 3. Killeen Rocquencout, BP ts Levene Livemere Labortary Poets Le Chesnay, Fane PO Boxats Livermore, CA 885, USA M. Holt S.A. Orseag Colles of Engiaetring and Progam ia Applied Mechanical Expnering fa Computstonsl Mathematics Univer of Cafrma Preston Univesity 218 Fine Hall Berle, CA 4720, USA Peston, NIOSH 100, USA. MV. Rusanov P Hut Kets nse “Te Instn for Advanced Stay Ot Appi Matera School of Natl Senses ‘Entaraya pl Peete, NF OSH, USA SUNTISNG Mosow, USSR. ISBN 3.540-53058-4 2. Auflage. Springer-Verlag Berlin Heidelberg New York ISBN 0-387-53058-4 2nd edition Springer-Verlag New York Betlin Heidelberg ISBN 5-S40-18151-2 1, Aulage SpringerVeriag Bertin Heidelberg New York ISBN 0-357-18151-2 1s edition Springer Verlag New York Berlin Heidelberg Smeets ahr ea Crpen ci e Se cet asta ere eae a aaa a eran acest eerste eee ar ae re ‘nm ln mere ce co te a oc a ie ie na Sacral eee {ts euzent version, anda copyright fee must sluajs be paid. Violations fal under the prosecution act of mSeCmnanie eer eta Teele me deat th tio dn tinh ein sec Springer Series in Computational Physics Editors: R. Glowinski M. Holt P Hut H.B Keller Killeen S.A. Orszag VY, Rusenov Preface to the Second Edition ‘The purpose and organisation of tis book are described inthe preface tothe first dition (1988). In preparing this edition minor changes have been made, par- ticularly 10 Chap. £10 keep it reasonably current. However, the rest of the Book hhas required only minor modification to clarify the presentation and to modify or replace individual problems to make them more effective. The answers to the problems are available in Solutions Manual for Computational Techniques for Fluid Dynamics by C. A.J. Fletcher and K. Srinivas, published by Springer-Veriag, Heidelberg, 1991. The computer programs have also been reviewed and tidied up. ‘These ae available on an IBM-compatible floppy dise direct from the author. Twould ike to take this opportunity o thank the many readers for thelr usually geneous comments about the first edition and particularly those readers who ‘went to the trouble of drawing specific errors to my attention. In this revised ed tion considerable effort has been made to remove a number of minor errors that had found their way into the original. 1 express the hope that no errors remain ‘but welcome communication that will help me improve future editions. In preparing this revised edition I have received considerable help from Dr. K. Srinivas, Nam-Hyo Cho, Zli Zhu and Susan Gonzales at the University of Sydney ‘and from Professor W. Beiglbock and hs colleagues at Springer-Verlag. !am very ‘grateful to all of them, ‘Syiney, November 1990 CAs Fletcher Preface to the First Edition ‘The purpose ofthis two-volume textbook is to provide students of engineering, Science and applied mathematics with the specific techniques, andthe framework to develop sil in using them, that have proven effective in the various branches ‘of computational fluid dynamics (CFD). Volume 1 describes both fundamental and general techniques that are relevant to all branches of fuid flow. Volume 2 brovides specific techniques, applicable to the different categories of engineering flow behaviour, many of which are also appropriate to convective heat transfer ‘An underiying theme ofthe texts thatthe competing formulations which are suitable for computational fluid dynamics, eg. the finite difference, finite ele. ‘ment, finite volume and spectral methods, are closely related and can be inter- preted as part of a unified structure. Classroom experience indicates that this ap- broach assists, considerably, the student in acquiring a deeper understanding of the strengths and weaknesses of the alternative computational methods. ‘Through the provision of 24 computer programs and associated examples and problems, the present text iv also suitable Tor esfalished research workers and Dracttioners who wish to acquire computational skill without the benefit of for- ‘mal instruction. The text includes the most up-to-date techniques and is sup- Ported by more than 300 figures and 500 references. For the conventional student the contents of Vol. 1 are suitable for introduc- tory CFD courses atthe final year undergraduate or beginning graduate level The contents of Vol. 2 are applicable to specialised graduate courses in the engineering CED area, For the established research worker and practitioner itis recommended that Vol. 1 is read and the problems systematically solved before the individual's ‘CFD projects started, if possible The contents of Vol. 2 are of greater value after ‘the individual has gained some CFD experience with his own project, It is assumed that the reader is familiar with basic computational processes such asthe solution of systems of linear algebraic equations, non-linear equations ‘and ordinary differential equations. Such material is provided by Dahlquist, Bjorck and Anderson in Numerical Methods: by Forsythe, Malcolm and Molet in Computer Methods for Mathematical Computation: and by Camnaghan, Lather and Wilkes in Applied Numerical Analysis, I is also assimed that the reader has some knowiedge of fluid dynamics, Such knowledge can be obtained from Fluid Mechanics by Streeter and Wylie; ftom An Indroduction of Fluid Dy namics by Batchelor, or from Incompressible Flow by Panton, amongst other. ‘Computer programs are provided in the present text for guidance and to make it easier for the reader to write his own programs, either by using equivalent con: structions, or by modifying the programs provided. In the sense that the CFD practitioners as likely to inherit an existing code as to write his own from serach, some practice in modifying existing, but simple, programs is desirable. An IBM. ‘compatible floppy disk containing the computer programs may be obtained from the author, ‘The contents of Vol. {are arranged inthe following way. Chapter 1 contains ‘an introduction to computational fluid dynamics, designed to give the reader an appreciation of why CFD is so important, the sort of problems itis capable of solving and an overview of how CFD is implemented. The equations governing fluid flow are usually expressed as partial differential equations. Chapter 2 de- seribes the different classes of partial differential equations and appropriate ‘boundary conditions and briefly reviews traditional methods of solution. Obtaining computational solutions consists of two stages the reduction of the partial differential equations to algebraic equations and the solution of the algebraic equations. The frst stage, called disretisation, is examined in Chap. 3 with special emphasis on the accuracy. Chapter 4 provides sufficient theoretical background to ensure that computational solutions can be related properly to the Usually unknown “exact” solution, Weighted residual methods are introduced in Chap. 5 as a vehicle for investigating and comparing the finite element, finite volume and spectral methods as alternative means of discretisation. Specific tech- niques to solve the algebraic equations resulting from discretisation are described jn Chap. 6. Chapters 3~6 provide essential background information. ‘The one-dimensional diffusion equation, considered in Chap 7, provides the simplest mode fo highly dissipative fuid flows. This equation is used to contrast ‘explicit and implicit methods and to discuss the computational representation of| 0.75, to produce a significant overall speed-up ratio, G. But at this level 0G/2P>0G/2R. ‘Thus modification of the computer program to increase P will provide a much bigger increase in G than modifying the hardware to increase V and hence R. In addition unless a large proportion of the computer program can be written so that vector lengths are significantly greater than N,, the overall speed-up ratio, G, will not be very great 11 Advantages of Compuinions Fiid Dyzsnies 5 P Prom Fie 12 Amdebts Law L foeet-ty ti, ¢ escent ectoried, 11? “The ability to increase the overall execution speed to the limit set by the hardware depends partly on the ability of the operating system and compiler to vectorie the computational algorithm and partly on choosing computational algorithms that are inherently veetorsable (Ortega and Voigt 1985). The struc- turing of computational algorithms to permit vectorisation is an important research topic but is beyond the scope ofthis book (ee Gentzsch and Neves 1988) ‘The long term trend would appear to be towards making the operating system and compiler take care of the vecorisation with less emphasis on the user having to ‘manipulate the basic algorithm. ‘With a pipeline architecture, an efficient vector instruction set and as small a ‘yee time a possible the major means of further increasing the processing speed is to introduce multiple processors operating in parallel, Supercomputers are typ- ically being designed with up to sixteen processors in parallel. Theoretically this should provide up to a factor ofsixten improvement in speed. Experiments by Grassl and Schoarzmeier (1990) with an eight-processor CRAY Y-MP indicate that 84% ofthe theoretical improvement can be achieved for a typical CFD code such as ARC3D (Vol 2, Sect. 184.1). ‘The concept ofan array of processors cach operating on an element ofa vector hhas been an important feature in the development of more efcient computer architecture (Hockney and Jesshope 1981). The Iliac 1V had 64 parallel processors ‘and achieved an overall processing speed comparable to the CRAY-1 and CYBER 205 even though the eycle time was only 80 ns. However Amdahi's law, (1.1), also applies to parallel processors if R is replaced by Np, the number of parallel processors, and P isthe proportion ofthe process that is paallelsable. The relative ‘merits of pipeline and parallel processing are discussed in general terms by Levine (1982), Ortega and Voigt (1985) and in more detail by Hockney and Jesshope (1981) and Geatzsch and Neves (1988), “The development of bigger and cheaper memory modules i bein driven by the substantial commercial interest in data storage and manipulation. For CFD Applications itis important that the complete program, both instructions and Fable storage, should reside in main memory. This is because the speed of data transfer from secondary (dis) storage to main memory is much slower than data transfer rates between the main memory and the processing units In the past the 6 Computational Fait Dames: An Intrusion ‘main memory size has typically limited the complexity ofthe CFD problems under investigation ‘The chronological trend of increasing memory capacity for supercomputers is impressive. The CDC-7600 (1970 technology) had 2 capacity of 4% 10° 64-bit words. The CYBER-205 (1980 technology) has a capacity of 3x 107 64-bit words and the CRAY-2 (1990 technology) has a capacity of 10” 64bit words Significant developments in minicomputers in the 1970s and microcomputers in the 1980s have provided many alternative paths to cost-effective CFD. The felative cheapness of random access memory implies that large problems can be handled efficiently on miero- and minicomputers. The primary diflerence between ‘microcomputers and mainframes is the significantly slower cycle time of a micro- computer and the simpler, les efficient architecture. However the blurring of the distinction between microcomputers and personal workstations, such asthe SUN Sparestation, and the appearance of minisupercomputers has produced a Pree/performance continuum (Gentasch and Neves 1988). ‘The coupling of many, relatively low power, parallel processors is seen asa very ficient way of solving complex CFD problems. Each processor can use fairly standard microcomputer components; hence the potentially low cost. A typical system, QCDPAX, is described by Hoshino (1989). This system has from 100 to 1000 processing units, each based on the L64132 floating point processor. Thus a system of 400 processing units is expected to deliver about 2000 Megaflops when ‘operating on a representative CFD code. ‘To a certain extent the relative slowness of microcomputer-based systems can be compensated for by allowing longer running times. Although 15 mins om a i Scanian “Eee 4 oe & Fig 13, Computer speed and memory requirements for CFD (ter Bley, 1986 eprint with eision of pan Society of Computational Fis Byam) Fg. 14. Suse preire dtriboton op 4 typi mitarysicrat Sutice pressure conous 3E -002 (ater Arlge, 1986 reprinted with permision of Japan Sovety Computational Fi Dyeanis) supercomputer appar tobe the acepted norm (Baiey 1986) or outie design ‘ort running tines of ew Hours ona misrocompster may well be acceptable a the reach and development are. This has the advange of allowing the CFD french worker adequate inet interpret theres and to prepare adional “The future trends fr computer specd and memory capacity are encourasag Preistions by Simon (199) indicate that by 2000 ope may expat sain computer speeds up to 10° Megaflops and main memory capacities of 50000 Memnwords Thi expected tobe adequate (ig. 13) fr predictions of seady ‘eos (turbulent compresblefow around complet aera and oallow global {sion opinion to be considered serious. 1.2 Typical Practical Problems Computational fuid dynamics, particularly in engineering, is sil atthe stage of i {is moving to the right with constant velocity w and that the temperature is constant across the pipe ‘The temperature as a function of x and 1 is governed by the equation or ar_ er. Fut oF F=0 form sxS%q and 120. a2) With a suitable nondimensionalistion, appropriate boundary and initial con- tions are Thy, = Te =O and a3 Ti O)=cosax, —05Ex505 <0, x<-05 and x>05 oo) Equations (12-4) provide a mathematical description of the problem, The term 20°T/dx? is the diffusion term and a is the thermal diflusvity. This term is ‘responsible for the spread ofthe nonzero temperature both tothe right and to the leit; Tis Gall the spread is small- Computational techniques for dealing wit ‘aiations containing such terms are dealt with in Chaps. 7 and 8 The term ud7/éx is the convection term and is responsible forthe temperature ion being swept bodily to the right with the known velocity u. The tof this term and the complete transport equation (1.2) are considered in CChap.9. In more than one dimension convective and difluive terms appear associated with each direction (Sect. 9.) Since wis known, (1.2) is linea in T: However, when solving for the velocity eld itis necessary to consider equations with nonlinear convective terms. A prototype 15 Equation Siete 19 for seh ontnarty is ven by Burger equation (et 101) ou oe a ax at ‘Te noninen convene term, 2u/x pels very step radins into deo Ps kvey sal Step gains tequre fer pido the psec ate “aonlineaity often necessitates an addtional level of iteration in the computational 0 as) algorithm, ‘Some flow and heat transfer problems are governed by Laplace's equation, 26 06 eae im ‘This isthe case fora flow which i inviscid, incompressible and irotational. Ta that ‘ease ¢ isthe velocity potential (Set. 11.3) Laplace’ equation is typical of the type of equation that governs equilibrium or steady problems (Chap.6). Laplace's ‘equation also has the special property of possessing simple exact solutions which ‘an be added together (superposed) since itis linear. These properties are exploited in the techniques described in Sect. 14. For many flow problems more than one dependent variable wll be involved and it is necessary to consider systems of equations. Thus one-dimensional un- steady inviscid compressible flow is governed by (Sect. 10.2) 2e , Hou) (17) amy) (179) where pis the pressure and E is the total energy per unit volume given by +0500, as) and 7 is the ratio of specific heats. Although equatioas (1,7) are nonlinear the Structure is similar to (1.5) without the difusive terms. The broad strategy of the computational techniques developed for scalar equations will also be applicable to systems of equations For flow problems where the average properties ofthe turbulence need to be included the conceptual equation structure could be written as follows tu ae (00 at Moo ay, : as) 1. Computations Fu Dynamics An Intoducton where “a” is now a function ofthe dependent variable u, and $ is a source term containing additional turbulent contributions. However, it should be made clear (Sects 11.42 and 11.52) that turbulent flows are at least two-dimensional and often ‘hree-dimensional and that a system of equations is required to describe the low. 14 Overview of Computational Fluid Dynamics ‘The total process of determining practical information about problems involving fluid motion can be represented schematically as in Fig. 18. ‘The governing equations (Chap. 11) for lows of practical interest are usually so complicated that an exact solution is unavailable and it is necesary to seek a computational solution. Computational techniques replace the governing partial Ailferential equations with sysiems of algebraic equations, so that @ computer can be used to obiain the solution. This book will be concerned with the computational techniques for obtaining and solving the systems of algebraic equations. For local methods, lie the finite difference, finite element and finite volume methods, th algebraic equations link together values of the dependent variables at adjacent grid points. For this situation it is understood that a grid of discrete points is distributed throughout the computational domain, in time and space. Conse- {quently one refers to the process of converting the continuous governing equations FOR EACH ELEMENT OF UID ‘Sowtoon seconde = cee im phe bandon cndion, Woy Dibatons —wtu eet), vant meee) Pro pene) Deny 2} Bhp) Semperntee =) Pie getl ce : See eae oe Fig 18, Oversiw of computations fh namics LA Overs of Computations! Fis Dynamics 15 oa system of algebraic equations as discretisation (Chap. 3). For a global method, like the spectral method, the dependent variables are replaced with amplitudes associated with diferent frequencies, typically. ‘The algebraic equations produced by discretisation could arise as follows. A ‘ypical finite difference representation of (1.2) would be TENAT} They = Thu) _ (TI = 275+ The) TIMAT) WT} es The) _ aT} 1-27} + Thou) at ae as , “ae where x=j 4x and t=n dt Ifthe solution is known at all grid points x, at time level n, (1.10) can be used to provide an algorithm for 73°, ie ever (1t oat ry (Bonn (Blona-aenn aay Repeated use of (111) generates the soltion a all interior grid points, xy at time level n+. Incrementing m and substituting the values T*"* into the right-hand side of (11 allows the discrete solution 1 be marched forward in time For local method, eg the finite diference method, the required number of {rd points for an accurate soltion typically depends on the dimensionality, the {eometric complexity and severity ofthe gradients ofthe dependent variables For theflow about a complet aircraft a grid often milion points might be required. At each rid point cach dependent variable and certain auiliary variables must be Stored. For turbulent compressible three dimensional ow this may require any- where between five and thirty dependent variables per grid point. For efficient computation all of these variables must be stored in main memory Since the governing equations for most classes of uid dynamics are nonlinear the computational solution usually proceeds iteratively. That i, the solution for each dependent variable at each grid point is sequentially corected using the Aiscetised equations. The iterative protess is often equivalent to advancing the solution over a small time step (Chap.6). The number of iterations or time steps right vary from a few hundred to several thousand. “The discretisation proces introduces an eror that canbe reduced, in principle, by reining the grid a8 long asthe discrete equations. (10), are faith rep reseatatons ofthe governing equation (Sect 42) I the numerical algorithm that performs the iteration or advances in time is also stable Sect 43), then the omputatonal solution can be made arbitrarily close to the tue solution ofthe soveming equations, by refining the grid if sufcient computer resources are svalable, Although the solution is often sought in terms of discrete nodal values some rmethods eg, the finite clement and spectral methods, do explicitly introduce a continuous representation forthe computational solution. Where the underlying physical problem is smooth such methods often provide greater accuracy Pet tunknovn in the discretised equations. Such methods are discussed briefly in Chap. 5 16 1, Computational Fld Dynamics: Aa Intodvction 1.5 Further Reading “The purpose of the present text is to provide an introduction to the computational techniques that are appropriate for solving flow problems. More specific infor- ‘mation is available in other books, review articles, journal articles and conference proceedings. ‘Richtmyer and Morton (1967) construct a general theoretical framework for analysing computational techaiques relevant to fluid dynamics and discuss specific Finite diference techniques for inviscid compressible low, Roache (1976) examines viscous separated flow for both incompressible and compressible conditions but concentrates on finite difference techniques. More recently, Peyret and Taylor (1983) have considered computational techniques forthe various branches of fuid dynamics with more emphasis on finite diference and spectral methods. Holt (1984) describes very powerful techniques for boundary layer flow and inviscid ‘compressible flow. Book (1981) considers finite difference techniques for both ‘engineering and geophysical uid dynamics where the dilusive mechanisms are absent or very small “Thomasset (1981), Baker (1983) and Glowinski (1984) examine computational techniques based on the finite element method and Fletcher (1984) provides techniques forthe finite element and spectral methods. Canto etal. (1987) analyse computational techniques based on spectral methods, Hialtiner and Williams (1980) discuss computational techniques for geophysical fluid dynamics. ‘The review articles by Chapman (1975, 1979, 1981), Green (1982), Krause (1985), Kutlr (1985) and Jameson (1989) indicate what engineering CFD is currently capable of and what wil be possible in the future. These articles have a strong aeronautical leaning. A more general review is provided by Turkel (1982). Cullen (1983) and Chervin (1989) review the current status of meteorological CFD. Review papers on specific branches of computational fuid dynamics appear in ‘Annual Reviews of Fluid Dynamics, in the lecture series of the von Karmen Institute and in the monograph series of Pineridge Press, More advanced com- putational techniques which exploit vector and parallel computers will not be ‘covered in this book. However Ortega and Voigt (1985) and Gentasch and Neves (1988) provide a comprehensive survey of this area Relevant journal articles appear in ATA Journal, Journal of Computational Physics, International Journal of Numerical Methods in Fluids, Computer Methods in Applied Mechanics and Engineering, Computers and Fluids, Applied “Mathematical Modelling, Communications in Applied Numerical Methods, The- retical and Computational Fluid Dynamics, Numerical Heat Transfer, Journal of ‘Applied Mechanics and Journal of Fluids Engineering. Important conferences are the International Conference series on Numerical Methods in Fluid Dynamics, International Symposium series on Computational Fluid Dynamics, the AIAA CFD conference series, the GAMM conference series, Finite Elements in Flow Problems conference series, the Numerical Methods in Laminar and Turbulent Flow conference series and many other specialist conferences 2. Partial Differential Equations In this chapter, procedures will be developed for classifying partial differential equations as elliptic, parabolic or hyperbolic. The diferent types of partial Giferental equations wil be examined from both a mathematical and a physical viewpoint to indicate thee key features and the flow categories fr which they occu. ‘The governing equations for fluid dynamics (Vol. 2, Chap. 11) are partial ferential equations containing fist and second derivatives in the spatial co- ‘ordinates and frst derivatives only in time. The time derivatives appear linearly but ‘the spatial derivatives often appear nonlinearly. Also, excep for the special case of potential flow, systems of governing equations occur rather than a single equation, 2.1 Background For linear partial diferential equations of second-order in two independent ~ variables a simple classification (Garabedian 1964, p. 57) i possible, Thus for the partial differential equation (PDE) Bu ou aay vice A tn i, tr pl et ia eA parabolic PDE: B*—44C=0 , (22) 1tisappareatthat the cessication depends only on the highest onder desivaives in toch epennt va For two-dmesional steady compresbe potential fow about sender body the governing equation, sma f0 (11109 2/26 Fd. 1M $ 42820 3 ant tay Ga 182 Paris Dien Equations ‘Applying the eiteria (2.2) indicates that (2. is lip for subsonic ow (8 <1) and hyperbole for supersonic flow (M, >. I the coefficients, 4 to Gin (1), ate functions of x,y. d4/2x or u/2y(2.2)can stil be used if 4, B and C are given a focal interpretation. This implies thatthe Classfcation of the governing equations can change in diferent parts of the computational domain. The governing equation for steady, compressible, potential flow, (1.109) can be writen in two-dimensional natural coordinates as 22,26 (My Se +S F—0, e4 where sand mare parallel and perpendicular othe local streamline direction, and M Js the local Mach number. Applying conditions (22) on a local basis indicates that (24) is elliptic, parabolic or hyperbolic as M<1, M=1 or M>I. A typical listibution of local Mach number, M, forthe flow about an aerofoil or turbine blades shown in Fig 11.15. The feature thatthe governing equation can change its type in different parts of the computational domainis one ofthe major complicating {actors in computing transonic flow (Sec. 143). ‘The introduction of simpler flow categories (Sect. 11.2.6) may introduce achange in the equation type. The governing equations for two-dimensional steady, incompressibi viscous flow, (1.82-84) without the du/ét and Go/ée terms, are elliptic. However, introduction of the boundary layer approximation produces a parabolic system of PDEs, that is (11.60 and 61). For equations that can be cast inthe form of (2.1) the classiication ofthe PDE. can be determined by inspection, using (22). When this snot possible, eg systems of PDEs, it is usually necessary to examine the characteristics (Sect 21.3) to etermine the correct classification ‘The diferent categories of PDEs can be associated, broadly, with diferent types of fow problems. Generally time-dependent problems lead to either parabolic or hyperbolic PDEs. Parabolic PDEs govern lows containing dissipative mechanis ‘8 significant viscous stresses or thermal conduction In this case the solution wi be smooth and gradients wall reduce for increasing time i the boundary conditions are not time-dependent Ifthere are no dissipative mechanisms present, the solution willemain of constant amplitude if the PDE i linear and may even grow ifthe PDE is nonlinear. This solution is typical of flows governed by hyperbolie PDEs. Eliptic PDEs usually govern steady-state or equilibrium problems. However, some steady- state flows lad to parabolic PDEs (steady boundary layer flow) and to hyperbolic PDEs (steady inviscid supersonic flow). 2ALL Nature of a Well Posed Problem Before proceeding further with the formal classification of partial differential equations it is worthwhile embedding the problem formulation and algorithm construction in the framework of a well-posed problem. The governing equations 21 Background 19 and auxiliary initial and boundary conditions ae well-posed mathematically ifthe following three conditions are met: i) the soltion exits the solons uigue, i the solution depends continuously onthe ausiary dt “The quenion of existence doesnot ual creat any dial. An exception cect in nroducig ext solton of Lapice' equation (Sect 13) whee the ‘Sion may ot exit at plated ports Thus doe nat ext athe oan ofthe ‘Stte rar, in 1153) In race this problem is en avoided by placing the ‘Sate sate the computational domain inside the body in Fig 117 “The uu cause of son aniquenes iat to propel atc the ausiary condition tothe pe of governing PDE. For the potential equation goversng {Src rotaonl hows and forthe boundary lye equations, the appropriate Sia and Boundary condiuons are well eablthe. For the Naver Stokes watson the proper boundary cndion ts sold suac are wel known Bat ‘hie some toby tm making the coer choc for freld boundary Consioar In genre! aa underescrption of Boundary conditns leads to non- ‘figuraes and an oveprescrpon to unphysal solutions adjacent to the Boundary in queton Ther aresone ow oben for bch malplessaon may be cx oo yital rounds, These problens woud fal the above eteria of mata Ceporenc Ths stution often ares for fows undergoing tansion fom Itmizartoterbulent motion, Hower the bead understanding of ud dynamics Sil natly dently such cases of flows for whch the computation may be “mpl by concer abou the wel-poednes of he mathematical formulation. "herd tenon above eis thats smallchangein theta or boundary conditions should cause oly small change ia the Solution. The auxin ‘Sains ate olen introdeed approximately in apical computational Sigom, Consequentyithethird condition snot et the eer inthe sua Stal propa ito he interior causing the solution to pow rap, rts for bypesbolic PDEs pe above cetera ae ual atibated to Hadamard (Garabeian 1964, i109) Inadditon we coulé take a smple parallel and equ that ora wel posed Computation: {) the computational solution exists, i) the computational solution is unique, i) the computational solution depends continuously on the approximate auxiliary data, ‘The process of obtaining the computational solution can be represented schematically 8 in Fig.21. Here the specified data are the approximate implementation of the initial and boundary conditions. If boundary conditions are placed on derivatives of u an error will be introduced in approximating the boundary conditions. The computational algorithm is typically constructed from ! 20,2. Paris Dieta Equations ‘pected pager! competetion Gao fib. ‘ston 0 Fig 21, Compuatina procedure the governing PDE (Sect 31) and must be stable (Sect. 43) in order fr the above three conditions to be met. Therefore for a well-posed computation tis necessary that not only should both the underlying PDE and auxiliary conditions be well-posed but that the algorithm should be wel-posed (stable) also. I is implicit here that the approximate solution produced by a well-posed computation will be close, in some sense, to the exact solution of the well: posed problem. This question wil be pursued in Sect. 4.1 2.12 Boundary and Initial Conditions tis clear from the discussion of well-posed problems and well-poted computations in Sect. 2.1.1 thatthe auxiliary data are in a sense, the starting point for obtaining ‘he interior solution, particularly for propagation problems. If we don't distinguish ‘between time and space as independent variables then the auxiliary data specified on R, Fig. 22, is “extrapolated” by the computational algorithm (based on the PDE) to provide the solution in the interior, R. aR Fi. 22, Compationl domain ‘Auxiliary conditions are specified in three ways: ') Dirichlet condition, eg. u=f on &R. iy Neumann (derivative) condition, eg. du/2n=f ot du/s—g on OR, ii) ‘mixed or Robin condition, eg. du/én-+ku=J, k>0 on OR. In auxiliary conditions i) and i), 2/On denotes the outward normal derivative. For most flows, which require the solution of the Navier Stokes equations in primitive variables (up, etc}, at least one velocity component is given on an inflow ‘boundary. This provides a Dirichlet boundary condition on the velocity. For the velocity potential equation governing inviseid compresible flow, the condition that 9/2n=0 at the body surface is a Neumann boundary condition. Mixed conditions are rare in fluid mechanics but occur in convective heat transfer. Computationally, Dirichlet auxiliary conditions can be applied exactly as long as f is analytic. However, errors are introduced in representing Neumann or mixed conditions (Geet. 7.3). 21 Backgoued 21 213 Clasiication by Characteristics For partial differential equations that are function of two independent variables the classification into eliptie, parabolic or hyperbolic type can be achieved by first seeking characteristic directions along which the governing equations only involve total diflerentials. For a single first-order PDE in two independent variables, au, yo 2H 9H 5 Aa Bae mu single real characteristicexsts through every point andthe characteristidirection is defined by (Fig 25) 29 en Equation (2.5) sa hyperbolic PDE and it is possible to integrate (27) as ordinary mdse, do=(L E, +LEs) 225 Expansion of the terms making up (2.26) establishes the relationships LAntbsdnemds, — L:ByutLBn=mdy . LyAgstLaAn=mde, — L,ByrtlsBa=mdy « em ‘liminating m, and m, and rearranging gives (Anndy—B 1d) Und Bods Ls] ° en (Ai2dy—Biadx) (Anady— Binds) Lbs ‘Since this system is homogeneous in 1 itis nevessary that det 4dy— Bae]=0, 22) for nontrivial solution. For the above example, (2.29) takes the form asdanAavdsa (2) aBar Aaa Bisdan 2 + (Bs sBas—BssBi.)—0 2) Equation (2.30) has two solutions and the nature of the solutions depends on the discriminant DIS=(Ai,B32~ An Biat An2Bis~AuaBar) AAs Ana As 4y2)(B Br Basia) + es which also determines the classification of the system (222,23). The diffrent possibilities are indicated in Table 21. ‘On characteristics the derivatives Gu/éx, 2u/2), (0x and do/dy are not defined uniquely. In fact, in erossing the characteristics discontinuities in the normal 1. This isthe same result ‘as was found in considering the compressible potential equation (24). This i to be expected since, although the equations ae different, they govern the same physical situation ‘The construction used to derive (2.28 and 29) can be generalised toa system of n first-order equations (Whitham 1974, p. 116. Equation (228) is replaced by am ‘The character of the system (Hellwig 1964, p. 70) depends on the solution of (2.29) 4) If m real roots are obtained the system is hyperbolic. 4) Iv real roots, 1'vsSn—1, and no complex roots are obtained, the system is parabolic. ii) If no real roots are obtained the system is elliptic For large systems some roots may be complex and some may be real this gives @ mixed system. The most important division is between elliptic and non-lliptic partial differential equations since eliptic partial differential equations preclude time ik behaviour. Therefor the sytem ofeuations willbe asumed to be lite i any complex roots occur. ‘The above classification extends to systems of second-order equations in two independent variables since auxiliary variables can be introduced to generate an ‘even larger system of first-order equations. However, there is risk that both 4 and Bare singular so that it may be necessary to consider combinations of the equations to avoid this degenerate behaviour (Whitham 1974, p. 115). For systems of more than two independent variables (2.29) can be partially seneralised as follows. A system of first-order equations in three independent variables could be written 2 ay a 235) 21 Bactgouns 27 where is the vector ofn dependent variables. Equation 2.35)leads to the nth order characteristic polynomial (Chester 1971, p.272) det Ai, + Bi, + Che] =0 236) where day Ayy Ay define a normal direction to a surfce at (x,y,z) Equation (236) igeneralises (2.29 and gives the condition thatthe surface is a characteristic surface. ‘Greatly for a real characteristic surface (2.36) must have real roots. In eal roots are ‘obtained the system is hyperbolic. ‘tis possible to ask what the character ofthe partial diferentia equation is with respect to particular directions. For example setting 4,= 2,1 and solving for 1, Sndicates that (235) is elliptic with respect o the y direction if any imaginary roots ‘occur. Clealy each direction can be examined in turn, Here we provide a simple example ofa system of equations based on the steady incompressible Navier Stokes equations in two dimensions. In nondimensional form these are 449,20, (237) uy 0+ Be 237) wot 00,40, ste) where us du/éx, ete, Re isthe Reynolds number and u, 0, pare the dependent” variables. Equations (237) are reduoed to a firstorder system by introducing. surilary variables »and T=, Thus (2.37) can be replaced with ate, +8. Beco 23) Sie ~T,[Re +p, =uS—0T , —Ry/Re—S,/Re +p, =uR—0S “The particular choies fr (2.38) are made to avoid the equivalent of 4 and Bin 235) ‘being singular. The character ofthe above set of equations can be determined by replacing 2/éx with A, and 2/2y with 2, and setting the determinant to zero, as in (236) The result is (Ren 3+ 239) Setting A, indicates that 4, i imaginary. Setting 4,=1 indicates that imaginary roots exist for 1, Therefore itis concluded thatthe system (2.37) is elit. 28 2, Pal Dirt Eauations ‘The general problem of clasiying partial diferential equations may be pursued {in Garabedian (1968), Hellwig (1964), Courant and Hilbert (1962) and Chester asm. 215 Classification by Fourier Analysis ‘The classification of partial differential equations by characteristics (Sects. 2.1.3 and 2.14) leads to the interpretation of the roots of a characteristic polynomial, eg. (2.36) The roots determine the characteristic directions (or surfaces in more than two independent variables). However, the same characteristic polynomial can be obtained from a Fourier analysis ofthe partial differential equation. In this case the roots have a different physical interpretation, although the classification of the partial diferential ‘equation in relation to the nature ofthe roots remains the same. The Fourier analysis approach is useful for systems of equations where higher than first-order w/80 ind Sle AS Fig 29, Typ doa for an lite PDE 2.43 Appropriate Boundary Coins The sbi to infene alter oitsin the domain roma tro pontimpies that toundary conditions are uted onal boundaries (Fg 29). The boundary ‘conditions can be any combination of Dirichlet, Neumann or mixed (Sect. 21.2) ai ultons However fs Neumann condition 09/2r=f(h aplieon 382. Part Dirt Eguations allboundaris, where nis the outward normal and sis measured along the boundary contour, cate must be taken that the specification is consistent wih the governing ‘equation. From Green's theorem, §sasm—[v'eay es Cleary, ifthe governing equation isthe Laplace or Poisson equation, (264) implies {additional global constraint on the Neumann boundary condition specification, ‘When (2.62) represents steady, incompressible, potential low and ¢ is the velocity potential, fs just the normal velocity. Thus for steady, incompressible, potential flow, (268) coincides with the conservation of mass, (11.7). The computational implementation of (2.68) i discussed in Seet. 1622. For systems of elliptic PDEs boundary conditions are required on all boundaries for all dependent variables For parabolic and hyperbolic PDEs it is always possible to obtain the local ‘olution immediately adjacent toa boundary by a series expansion. Attempts to do the same with an eliptc PDE typically produce an infinite solution, due tothe fast {hat eliptic PDEs are not well-posed forthe case where boundary conditions are not specified on a closed boundary. 25 Traditional Solution Methods In this section we briefly describe thee techniques that may be considered pre- computer methods, requiring only hand or primitive machine caleulation, These ‘methods work well for simple model problems but arc less efetive forthe mare complicated equations governing fluid ow. However, they are sometimes uefa suggesting a method of solution or obtaining an approximate of local solation, ‘25.1 The Method of Characteristics ‘This method is only applicable to hyperbolic PDEs. It is described here fora second: sgtder PDE in two independent variables, which was considered previously in Soot 213, 265) (266) For two adjacent points on the characteristics defined by (2.66 the compatibility ‘equation 2.15) can be approximated by 125 Trdnsl Soluion Methods 39 Fig 210, Method of characteris b= choroctts een Y sp+cag+Hdy=0 2 ap+cao 11 may be recalled from Sect. 2.3 that P=du/éx and Q'= duly so that, for the same two adjacent points, i du=PAx+Qdy ne non-characterstic P and Q are known along sor a 1 il ter 10) Tilly both the solution and the locations for iter etna (10 aly to hn nm ty ee Fly .) and wowadadern) «hee 269) 27 move Fyn 05(F.tF,) and Gy=05(G,+6,) [Bfectively, the curved lines ad and bd have been replaced by straight lines mine dope atthe end pos. 7 re seat wad be pose to obtain 2, and 0, om 267 the form en) FusFalPs—Pa)+ Ca Qu 00) + Mash e=¥)"9 ha Fubra Pp Pa)+ Cul Qu Q0)+ Halve) = ae were known (268) could be used, as follows, to obtain If P, and Q, were known (2 iM yn my= Plt ¥a)+ Gul YoY) ma In practi (269-7) mus be solved teatvey to btu Ye Pe Quand dF the fist sep of the iteration the following approximations em 6, ete. Fuk, 6 402, Parl Dierenia Egon, “Typically two or three iterations are required as long asdis not to far from aand ‘The method progresses by marching along the grid defined by the local characteristics which are determined as pat ofthe solution, The above formulation is described in a fluid dynamic context by Belotserkovskii and Chusbkia (1965), The method of characteristics has been widely used in one-dimensional unsteady ‘gas dynamics and for steady two-dimensional supersonic inviscid flow. However, the method is rather cumbersome when extended to three or four independent variables, or if internal shocks occur. For supersonic inviscid flow the method of ‘characteristics is useful for determining the number and form of appropriate far- field boundary conditions. 252 Separation of riables ‘This method is applicable to PDEs of any classification, I will beillustrated here for the diffusion equation au_ ou SS e715 in the domain shown in Fig. 2.11. The intial and boundary conditions are also shown in Fig.211. The method introduces a general separable solution os, = XO) 276 Substitution into (2.75) gives ex ieix=0 and en, a Fe itn0, em) ‘where 4s an arbitrary constant. Equation (2.77) hasan infinite numberof solutions ofthe form XG) Ay sin be, 2.75) where 44=K, k= 1,2,3 .. and A, are constants tobe determined by the boundary and initial conditions, Consequently (2.78) also hasan infinite number of solutions viene) ‘mice Fig 211, Aulry conditions foe 28) 25 Twins Sotion Metbode ofthe form T,()=Byexp(-K0 , 280) where By are constants to be determined by the initial and boundary conditions. ‘Substituting (279 and 80) into 2.76) implies the general solution uose)= F Gysinkeerp(-H9 es) Equation (281) satisfies the boundary conditions ofthe problem, The constants Cy ae obtained from satisfying the initial conditions fee =u(x,0)= (0) si 2.82) e(2)frisete any Forthis particular problem the contribution from exp —K*)for large kis very small for 120. Therefore itis usually only necessary to retain 10 or 20 terms in the ‘expansion (281). ‘The separation of variables method relies on the availability of a coordinate system for which OR coincides with coordinate lines. It also implies that the ‘Operators in the PDE will separate. Consequently, although the method i fective ‘on model problems it does not find much direct use forthe rather complicated ‘equations governing fuid motion, often in irregular domains. However, an interesting discussion ofthe method is provided by Gustafson (1980, pp. 115-138) 253 Green's Function Method For a PDE written in the general manner ey a solution ean be constructed, in principle, by “inverting” the operator L. The jution is expressed in integral form as uipl={O(r.a)flady, » ess Where G(p.q) is the Green's function. In general G(p,q) contains information ‘equivalent to the operator L, the boundary conditions and the domain. Conse~ {quently the major dficulty in using the Green's function method is in determining ‘what the Green’ function should be to suit the particular problem. The subsequent evaluation of 2.85) is usualy straightforward, ‘Green's functions can be obtained for relatively simple linear equations like Laplace's equation and the Poisson equation. For example, a point source of unit 422. Para Diterent Egations strength in three dimensions has the Green's function Sieg) Ur, (Fa) =1/4Rr 5 286) verry the dance etme pad 7 ween pand . Thisformilaiseectvely equivalent the two-dimensional velocity potential given by (11.53) with m= at i required difereniation indicates that eee ~V25(0.)=8(P.9) + 287) te (the Dida centeatpand #2 ceeds pandV the Laplacian vaste a Property of the Dirac delta function is that - eee J m(g)d(p. ld¥,=w(p) and (p, 0 it pea 288) In (288) w(q) isan arbitrary smooth function ‘A solution procedure can be established by invoking Green's second identity, forre—ovinars § (ue -0%)as 7 (289) {nthe present staan, in 299) i ientifed wih the sluon of he Poison vA and fou, on aR 20) P= G(p.a)=S(p.9)-+a(F,9) with omO on OR. 21) Consequently (2.89) reduces to fojar=—[uvrear es ‘The unction o(p,q)ischosen so that Vig in Rand G(p.4)Owhengison: 4 resul, (2.88 and 92) give the solution fea depen aan teeta {onary 293) Te rer eon methodist te isinpic inthe pe method. 141 adi almost directly in the boundary element method (Sect. 14.1.3). ; Tor some epic POEs ts pon fo conta seal atonal prs and tea Rah te prec utaon 90 p 1) Ah cigs anlar orstucalapplcaon etn denot ea, the elliptic PDEs that cu in uid dyna the lpi PDEs hat fiuid dynamics do not usually possess an equivalent 27 Protieme 48 2.6 Closure In this chapter we have examined the classification of PDEs into hyperbolic, parabolic and elipic type. All thre types oceus for various simplifications of the Fuld dynamic governing equations (Chap. 11). However, systems of equations may aso be of mixed type. Hyperbolic PDEs are usually associated with propagation problems without dissipation (wavecke motion remains unattenuated) and para Donic PDEs are usually associated with propagation problems with dissipation. In ‘uid dynamies the dissipation usually comes from the viscous or heat conduction terms or eddy-visoosity type turbulence modelling. Eliptic PDEs are associated with steady-state problems. Each type of PDE requires different boundary (and initial) conditions and may Jend themselves to particular solution techniques. For example the method of ‘characteristics ‘natural’ for hyperbolic PDEs in two independent variables. For {he nonlinear equations governing fluid dynamics the classification of the PDE can. ‘change locally. Consequently boundary conditions should be chosen to suit the Classifcation of the PDE adjacent to the boundary. “The changing clssifiation of the governing PDEs in diferent pars of the domain can be illustrated by considering supersonic viscous flow past a two- ‘dimensional wing. For this example the governing equations are the Navier Stokes ‘equations which, due to the appearance ofthe second derivatives, re strictly liptic tahen interpreted according to Sect. 21.2. However, such a classification takes no tovount ofthe magnitude ofthe relevant terms. Infact the viscous tems are only Significant close tothe surface where the streamwise viscous dissipation isan order- ‘of magnitude smaller than the cross-stream viscous dissipation; and the governing, ‘quations are mixed parabolc/hyperbolic. Away from the body all the viscous terms are small and the equation system is effectively hyperbolic. When shock twaves oocur the severe gradients away from the body cause the viscous (and heat Conduction) terms to be significant so that the governing equations are locally Clipe (within the thickness of the shock-wave). This is sufcient to replace the ‘iscontinuous solution (inthe inviscid approximation) with a severe, but continu ous, gradient. “Chearly the strict mathematical classification of the governing PDEs should be tempered by a knowledge ofthe physical processes involved to ensure that correct (uullary conditions are specified and appropriate computational techniques are used. 2.7 Problems Background (Sect. 2.1) 21a) Transform Laplace’s equation, 324j0x2+274/0)?=0, into generalised coordinates €=é(s,)) n=n(sy) and show that the resulting equation is elliptic. 1) Transform the wave equation, 2g/01*—2%pj0x?=0, into generalised coordinates E=étt3), n=n(t3) and show that the resulting equation is hyperbolic. 42 Paria Diterenl Equations 22. Convert the Kortweg-de Vries equation (Jeffrey and Taniuti 1984 and (927), ea, de aa aS into an equivalent system of fistorder equations by introducing ausiliary variables p=du/éx, etc. Deduce that the resulting system of equations is parabolic 23. The nondimensional equations governing steady inviscid incompressible ow Determine the typeof the system of partial differential equations Hyperbolic PDEs (Sect. 22) 24 Show by inspection that the second-order PDE d#u/@xdt=0 is hyperbolic. Consider the equivalent system ype Mono and Es Deduce that this system is hyperbolic and that the and ¢ axes ae Ounces 25 Consider te modifed wave equation a2 a Show, by inspection that this equation is hyperbole Conier terete Syne of enatons au 94 —w=0, % 20_aw. Bae ow : e299) a pe tuo 27 Problems 48 ‘Show that this systems hyperbolic and determine the characteristic directions ‘What is the connection between (2.94) and (2.95)? Does this explain the extra characteristic in (2957? 126 The governing equations for one-dimensional unsteady isentropic inviscid compressible flow are ee. a where P=kot and a?=yp/a. Here a is the speed of sound. Show that this system is hyperbolic and that the characteristics are given by dyfdt=uta. Parabolic PDEs (Sec.23) 27 (a) Convert the equation 24/2¢—20%4/@x?=0 to an equivalent system by introducing an auxiliary variable p= 24/0x.Show that the system is parabolic. () Analyse a6/¢e—a(64p/2x! + 226/0y*)=0 in a similar way and show that it is parabolic 28 Consider the transport equation Ou/0t+ 2cdu/dx—d0°w/0x* conditions u(x, 0)=exp(ex/d) and boundary conditions u(0,1)=exp(—<*t/d) ‘and ul, ¢)= (de) du/éx(1y¢) Show that theequationis parabolic and determine the solution, 7 129. Taeequations governing steady incompressible boundary layer flow over fiat plate can be writen au , my aay au ou 1 Oe Max ay REO Show that this system is parabolic and suggest suitable inital and boundary conditions for wand Eligtic PDEs (Sect. 24 2410 Consider the equations aut ote 296 iy by ox 2 29) ‘Show that this system is elliptic, @) directly, (©) by introducing the variable 6, where w a 4 2, Pana Diteretia Egetons 2.11 Show thatthe expressions x+y), 0 (2+ y?)atea solution of 2.96). 212 Show that the equations form an elliptic system and that they are satisfied by the expressions ~2[ay +ayy+K (explkx—xo)] + expl—Klx—xo)]} cos(ky)ARe D) , 2a, +a,x—kfexp[e(—x)] + exp —Kla—xo)]} sin(ky)AReD) , where Da [ao+a,x+ any +a5xy+ fexp[k(x—xo)] + expl—k(e— xo)]}00s(ky)} and a9, 4,,03,4,, and x are arbitrary constants, ‘Traditional Methods (Sect. 2.5) 213 Consider the solution of 2°7/0<4-+ 27/980 on a unit square, wi boundary conditions a Peer TO)=0, THy=0, T=... Thy t=o Apply the separation of variables technique to obtain Tess) S Asinihsinh ty 10) with _2Toskoil == 1) Ae sink) 214 The equation 24/2t~20*§/0x4=0 isto be solved in the domain 0x1, £50 with boundary conditions 4(0,0)=0, (11) 0 and initial condition ‘#(x,0)=0. Show, via the separation of variables technique, that the solution is dmgene Fetter tetiointn 215 Show that the expression ms (x-yP Jane o( a, isthe Gree’ function othe heat condsction problem consderedin Problem 2.14 by showing that ists (275) with yfned. 3. Preliminary Computational Techniques In this chapter an examination will be made of some ofthe basic computational techniques that are required to solve flow problems. For a specific problem the governing equations (Chap. 1) and the appropriate boundary conditions (Chaps. 11 and 2) willbe known, Computational techniques are used to obtain an approximate solution of the governing equations and boundary conditions. For example, for three-dimensional unsteady incompressible flow, velocity and pressure solutions, u(x, 2.2) % 35% 8 WOE ¥ % 0) and pl, y, 2,0 would be ‘computed. The process of obtaining the computational solution consists of two stages that are shown schematically in Fig.3.1. The first stage converts the ‘continuous partial differential equations and ausiliary (boundary and initial) ‘conditions into a discrete system of algebraic equations. This frst stage is called 204x, the amplitude ofthe first derivative is reduced by a factor between 0984 and 1.000 in using the exntred diffrence approximation, However, when there are less than 4 grid spacings in one wavelength (short wavelengths) the amplitude ofthe derivative is less than 064 of its correct value For a wavelength of 4=204x, the centred diflerence representation of @?7/2x* reduces the amplitude by 0992. However, ata wavelength of 42s the amplitude of the second derivative is reduced by: 0405. As noted in Sect. 34.1, long wave: Jengths are represented more accurately than short wavelengths ‘When the forward difference approximation to [07,¢x}, (3.19), is compared with the exact value ofthe derivative, for 7 given by 3.32} itis found that errors are {introduced in both phase and amplitude. The true amplitude is multiplied by the factor [sin(mdx/2\(m4x/2)] and the phase is decreased by mx/2, whichis equiv ‘alent to a spatial lead of 4/2. For the above examples the amplitude and phase ‘errors disappear as 4x0, ie. the long wavelength limit. 33 Accuracy of Higher-Order Formulae In Sect, 3.42 it was indicated thatthe accuracy of discretisation could be assessed by looking ata progressive wave traveling with constant amplitude and speed, g The exact solution even by (3.32) Here this example wil be sed to see ifhigher- order diference formulae represent waves more acuraely than low-order fr Iola, Specialy, a comparison will be made ofthe symmetric three-point and five-point formulae for 07j¢x and 27/0? piven in Tables 3.1 and 32. Following the same development as fr (336) the amplitude rato for the five- point symmetcic representation for 07j2x (Table 3.1) is ($-Spumae) samt 0% any 373 ‘The long and short wavelength behaviour of (3:9) is shown in Table 35. The ‘Table, Amplitude ratio for a proprsve wave AS Finite Dierece Method 63 ae Seng ae, =A>—— ree ay SOE ore Aono Aapem t Bein || faster Teg natal notes r = rhea Gren 1 ‘Guo rom Us) 1 eleies C ebe] 1 JEVALUATE_ ALGORITHM a rev ome ane | nae = Sensi ome aun ! Devas Stone ——~SCRaguaningh Show seen ! aay rer ! a L oF crs om ows ra sri 0999 ae ‘amplitude ratio for the five-point representation of 0°7/0x? (Table 3.2) is given by ang =$1-035teusmani) ow The long and short wavelength behaviour of (240) is shown in Table 35. The ho bye resus showa in Table 35 indicate that both schemes are moe acest for lore H/o Sect tid mie bel al wavelengths, with the five-point scheme eing partially seurate Howence, © hem mel neither scheme is very accurate for short wavelengths. This result is consistent with the previous comments (Sect. 33) about the relative lack of advantage in using a higher-order scheme on a coarse grid Fora given wave being modelled, refining the grid (je, allowing more points to represent each wavelength) shifts the problem from a short wavelength to slong wavelength problem. Consequently the main conclusion to be drawn from Table 35 is the need to use a sufficiently refined grid to accurately compute wavelike 35 Finite Difference Method ied in Sect. 3.1 the basis forthe finite diference method isthe construction of a discrete grid (Fig. 32), the replacement of the continuous derivatives in the partial differentia equations with equivalent finite difference expressions ‘and the rearrangement of the resulting algebraic equation into an algorithm, asin @.5). In this section the above aspects are linked together and a simple finite difference program is provided, 35.1 Conceptual Implementation ‘The various steps in applying the fnite diference method to a given problem are represented schematically in Fig 3.11. vec ey spin as i i teat eoecion fifsn) problem. An usted rod (8 312) nial bas sete oy bc See a re caer Sore ee sae tone seeamineanse aT 7 initialise the Permneene teee Norra eter salami 2 Orica Senora ee ae Seana ne nd ae HU-20T} 457+ Gan TytesT}, ‘where s= adt/4?, Equation (41) i applied at al internal nodes j=...» JL Ina typical heat conduction problem the boundary values T]°* and 73°! are iven by the boundary condition (3.2) The solution process repeated, advancing 1s ie y until the required final time is reached. ~ 6 3. Preliminary Computations Tesknigues 352 DIFF: Transient Heat Conduction (Diffusion) Problem Jn S31 the ipenaton of te fine ire metod is dense alana here a conesponding commuter program DIFF, proved. applies the FTCS scheme, (3.41), to the transient heat con fusion (difwson) Sone OPTS adem Beat condo (aiesion The listig of rogram DIFF shown iF rameters used by DIFF are described in Table 3.6. Pee eee Fig 313. Lisig of pogram DIFF 45. FineDierene Metiod 67 en : Fig 315. (cont) Ling of program DIFF Program DIFF reads in the various control parameters (line 16), sets Ax and dt ‘and writes out the various parameters. The solution is computed at each time step nel (Fig. 3.11) until either NMAX or TMAX (lines 72,73) are exceeded. Then the ‘exact solution is computed (ines 74-91) from re, ate" [lth ftom neanervens. 0 a=W “This solution is obtained by the separation of variables approach (Sect. 252. Simultaneously the rms error is obtained from © 3. Prtiminey Computation! Tehniues ‘The 36 Parameters wolf progr DIFF a ae ening Sie ede a Eee ALPH ‘Theemal difsivity a 7 fle meal : Soo, . SS tw Tine oe [(Se1-r0) eax sy For the initial conditions T\x,0)=0 and boundar Fr ke 0)=0 and boundary conditions F(,1)= 100 te compute output gece by DIFF, corespondng ob ee, in Fig 3.14 and plotted in Fig. 3.15. seve elt ANE of ied in DIFF to set the tine step the vale of d=01 Reducing» reduoss dt and leads toa smaller ms error in the solution. This i {nparet om he rl shown in Table 7 ih FO,0~ Pl o)= 0 The oul respon +=016 aspect which dca for in Set 1.2 ag Acetone 0 and 31 ef DIF Fi 12 nts tht te ales 0,0) and 7(,0) are averaged between thei values imped by the oa RM Fig 314. Typical cup fom DIFF; 2905 16 Come Fig 318 Solston of 34) with 505; sable behaviour ‘conditions and those implied by the boundary conditions. The effet of setting 7(0,0)= T(1,0)=0, (ie. as given by the intial conditions) is also show in Table 137. Ceatly this leeds to a much larger solution error. IfT(0,0)= TU, 0)= 100 the error is ofa similar magnitude to that for T(0,0)=T(1,0)=0. “Table 17. rs eto f" Fae os 0492 28 03 ous? 4 le te Eo 3.6 Closure Diseretsation is seen to introduce an error that can be asessed by considering the truncation error, atleast for the finite diference method. The truncation error is likely to bea progressively more accurate indicator of the solution error asthe grid is refined (Sect. 41.2). ‘The particular formulae used to epresent derivatives can be chosen by elimin- ating suecessive terms from the truncation error (Sect.32.2). However such an “approach often needs to be modified to choose some ofthe coefficients so that the resulting algorithm is stable (Sect. 43) Tt is apparent from the specific examples considered in Sects, 33 and 3.4 that higherorder formulae are not likely to be significantly more accurate than low order formulae if the exact solution contains discontinuities or severe gradients. In Addition, in representing wave-like motion, short wavelengths are predicted less accurately than long wavelengths "The provision of a simple init difference program, DIFF, permits many ofthe features ofthe finite diference method to be illustrated. By way of example itis shown thatthe accuracy of the finite diference solution ofthe diffusion equator Guite sensitive to the way that the discontinuity in the boundary and inital Condition specification is handled. Computational solutions ofthe diflusion equa- tion for diffrent schemes and boundary conditions are discussed in Chap. 7. 7 3. Preliminary Computational Fechigues 37 Problems Approximation to Derivatives (Sect 32) ‘M_Use the general technique (Sect. 32.2) to determine the coefficients a tod in the formula Pr Prat tet ostate Wha ete rocaion eno of hi oma 42 Alec epic scat of ST a7 02-0 can wen ast narpeusrys rn [ete at tiat Acs nal yg () Expand cach term as a Taylor series to determine the truncation error of the complete equation for arbitrary values of d. (©) Use the general technique to choose dasa function ofs so thatthe seheme is fourth-order accurate in dx. The formulae after (4.11) are useful for this problem, ‘Accuracy of Discretisation (Sect, 3.3) 33. For ysinnx/2 obtain dy/dx at x=05 with 4x=0.1 using Ma Msm¥ ae ae 4 yesny % ax” (9 gM 1 +B Yer a Tax 7 ‘and compare the accuracy ofthe results. 34° Repeat Problem 33 with 4x=005, 0.025, 00125 and determine whether the convergence with 4x is consistent with the leading term ofthe truncation xror Its recommended that a computer program is writen to salve this problem, Double precision may be required to resolve the error associated with scheme (e). 35. For y=sinx/2 obtain d?y/de? at x=05 with using: 1, 005, 0025, 0.0125, fay ©Y «Vins 2vyty. @ eae 37 Protens 7 Py | Ipn2t 16ys- 1 — Wy, + 1GVj64 Iyer Om Tat . and compar th accuracy ofthe rests ad th onnrgece wih he eading tem inte truncation eo Is eommendd hata computer program trent slve ti roles, sing double precon i roqied Wave Representation (Sect. 34) 36. For a progressive wave Tex.) =costm(x—a0)) show thatthe use of 27/01=(73*!—T)/4t is equivalent to (2)snesmaninfes-(1+4) J FGearaales]} “at Se ae ri nn sn a et er er, ‘evaluation of 27Ye¢. Finite Dilference Method (Sect. 2.5) 37 Modify program DIFF to use the following five-point symmetric scheme for interior points: OD Ty sN24 47) 3-257) +40) S—TyaalI2 we at For j=2 use OT MM g/12—ST 340571 +) o3/3—Tes M2 we ax} r. and the equivalent formula for j=JMAX—1. (@) Obtain solutions with 4x=01 for s=03, 02,01. 7 () How does the solution accuracy compare with that ofthe FTCS scheme? 723. Prtininry Computnona Tchiqus 38 Modify program DIFF to introduce Moaity the following scheme, in place of FICS 037 STE a 754275475 are LST} 21 T id g For the fis tine tp ae the foarte Forth fortard tine fouls a/8¢=( 7", (0) Oban slton with sx fors-0.5 03, 01 tnd conjure ak 7 ‘solutions produced by the FTCS scheme. Pee (I the aeurcy behavior wih deeng& what you woud (Hine; Consider the truncation error expression in Problem 32] ia 4, Theoretical Background In practice the algebraic equations that result from the discretisation process, Sect 31, are obtained on a finite grid. It is to be expected, from the truncation ‘errors given in Sects. 32 and 33, that more accurate solutions could be obtained on refined grid These aspets are considered further in Sect. 44, However fora given fequired solution accuracy it may be more economical to solve a higher-order Fite nce scheme on a coarse grid than a low-order scheme on a finer grid, if the exact solution is suficiently smooth. This leads to the concept of computational efficiency which is examined in Sect. 45 "An important question concerning computational solution is what guarantee ‘can be given thatthe computational solution will be close to the exact solution of, the partial diferential equation(s) and under what circumstances the compu- tational solution will coincide with the exact solution. The second part of this {question can be answered (¢uperfically) by requiring thatthe approximate (compu {ational solution should converge tothe exact solution as the grid spacings 4, 4x shrink to zero (Sect. 4.1). However, convergence is very dificult to establish directly ‘0 that an indirect route, as indicated in Fig. 4.1, is usually followed. The indirect ‘Toute requires thatthe system of algebraic equations formed by the discretisation process (Sect. 3.1) should be consistent (Sect. 42) with the governing partial difer- ‘ential equation(s). Consistency implies that the discretisation process can be reversed, through a Taylor series expansion, to recover the governing equation(}. In addition, the algorithm used to solve the algebraic equations to give the approximate solution, T, must be stable (Sect. 4.3). Then the pseudo-equation CONSISTENCY + STABILITY = CONVERGENCE a DIFFERENTIAL EQUATION. ut) 7 Sobity Fig 41. Concept sistonsip betwee coneiteny. stably and comergence 144 Theoret Bstground is invoked to imply converence. The coniton under which (41) cam be made Preise ae given by the Lat equivalence theorem (St 41) Ics vey aifeat to obtain theoreti pldance forthe behaviour of the ston ona gi fie sie Most he ef teal rests sty only apa in he lint tt the grid su sks too. However the Connections that ar esublhed between cometgrns (Sect iy some (Sek 2) and stability (Sec 43 are ao quate) wsetl in asa sop ‘aioe solutions on ante gta 4.1 Convergence A solution ofthe algebraic equations (Fig 41) which approximate a given par {al ferential equation said to be coavergnt ifthe approxinae solvaon speach he at lun of te prt denial equation fr cach ae the Independent variable atthe gid spacing tends to’2et Thus we reqie TT (x,t) as 4x, At-00. Ee The diference betwee the exact soon of the partial diferent equation snd the exact solution of the stem of algebraic equstion i ald the solution treo, denoted bye tats Pep t)-Ty (42) The exact solution ofthe system of algebraic equations isthe approximate soliton ofthe governing partial dierent equation, The enact slution of he sate ot Algebraic equations is obtained when no numerical eros ofany sor, suchas those due to roundoff ae introduce dsing the computation. The magitae of he tor, athe (,n}th node typically depends onthe sie of he gd spacing, nd rand onthe values ofthe highetorder derivatives at hat nde, ated ros the fntedifrence approximations to the dervauves in the pica ifertal eauation Proof that a solution to the sytem of algebraic equations converges tothe Solution ofthe pari diferental equation is general very difieul even fo the silt css. Fr te approximate solos to the iin eatin sig the ‘Very simple FTCS algorithm (3.41), a proof of convergence for s<+ is given Nope Sep 1711). Cooverence very aio show ven he tea partial diterntal equation it more complicated than the ifaion equation the method of discretisation is less direct. 7 = ‘fo flow problems poses nat oun so that fo theses cone fence can be inerred by obtaining computational solutions on prose refined grids (Sect. 4.1.2) " Peers 4.1.1 Lax Equivalence Theorem For a restricted class of problems convergence can be established via the Lax ‘equivalence theorem (Richtmyer and Morton 1967, p.45):"Given a properly posed 44 Gonvegene 75 linear inital value problem and a finite diference approximation to it that satisfies the consistency condition, stability is the necessary and sufficient condition for convergence”. ‘Although the theorem is expressed in terms of finite diference approximation itis applicable to any discretisation procedure that leads to nodsl unknowns, e, the finite element method, The Lax equivalence theorem is of great importance, since it is relatively easy to show stability of an algorithm and its consistency with the original patialdifeential equation, whereas itis usually very difficult to show ‘convergence ofits solution to that ofthe partial diferential equation. “Most “real” flow problems are nonlinear and are boundary or mixed intial) boundary value problems so that the Lax equivalence theorem cannot always be applied rigorously. Consequently the Lax equivalance theorem should be intr- preted a providing necessary, but not always sufficient, conditions. Inthe form of, (4.1) the Lax equivalence “equation” is useful for excluding inconsistent diseretis- ations and unstable algorithms. 41.2. Numerical Convergence For the equations that govern fluid flow, convergence is usually impossible to demonstrate theoretically. However, for problems that possess an exact solution, like the difusion equation, itis possible to obtain numerical solutions on a successively refined grid and compute a solution error. Convergence implies that the solution error should reduce to zero asthe grid spacing i shrunk to zero. For program DIFF (Fig. 313), solutions have been obtained on successively ‘efined spatial grids, 4x =02, 01,005 and 0.025. The corresponding rms errors are shown in Table 4.1 for s=0.50 and 030, It is clear thatthe rms error reduces like ‘4x? approximately. Based on these results it would be a reasonable inference that felining the grid would produce a further reduction in the rms error and, in the limit of 4x for fixed 5) going to zero, the solution ofthe algebraic equations would ‘converge to the exact solution. "The establishment of numerical convergence is rather an expensive process since usually very fine grids are necessary. AS s i kept constant in the above ‘example the timestep is being reduced by a factor of four for each halving of 4x. In ‘Table 4.1 the solution error is computed at = 5000s. Tis implies the finest grid solution at s=0.30 requires 266 time steps before the solution error is computed. For the difusion equation (3.1) with zero boundary values and initial value T(x,0)=sin(ax}, OSxS1, the rms solution error lems i plotted against grid “Tablet Solation ero (ms edn with uid rellewent feu des —dcol Cease am 1s 00 on ‘0 x, 0590 ou oot 012 7% 4 Theoret Background loayo (4x) Fig 42. Numeral convergence orth FICS math BS daz, o spacing 4x in Fig. 42, The increased rate of convergence (fourth-order conver ‘ence for sf, compared with other values of sd (second-order convergence), clearly seen, ie. the convergence rateislike dx* for s=4, and like dx? otherwise AS will be demonstrated in Sect. 42, the superior convergence rate for s=4 is to be ‘expected from a consideration of the leading term in the truncation error. Typi- cally for sufciently small grid spacings 4x, Bt, the solution error will reduce ike the truncation error as 4x, 4¢-+0. 42 Consistency ‘The system of algcbrac equations generated by the discretisation proces isd to te consistent withthe orginal partial diflerenial equation if inthe limit thatthe ‘id spacing tend to zero, the system of algzbrae equations is equivalent to the Partial diferenal equation at each gd point. Clearly, consistency is necessary if the approximate solution is to converge to the solution of the partial diferenial equation under consideration Howores not a suiient condition (Fig 4, for even though the system of agate equations might be equivalent to the partial dieental equation asthe ord Spacing tend to zero, it does not follow tat the solution af the system of algebonte «uation approaches the solution ofthe partial dierental equation For ietanes, choosing s>4 in program DIFF causes the solution wing the FICS slgssing, (21) to diverge rapidly. Thus as indicated by the Lax equivalence theorem Sect 41.2, both consistency and stability ate required for convergence ‘The mechanics of testing for consistency requires the substitution of the exact solution into the algebraic equations resulting rom discretisation, andthe pen, sion of al nodal values as Taylor series about a single point. For consistency the resulting expression shouldbe made up ofthe orginal paral diferential spactien plus a remainder. The structure of the remainder shouldbe such tha i redocce 2ero as the gid is refined. 42 Comiterry 77 In this section the FCS scheme (Sect 421) and the fully implicit scheme (Sect.4.22) will be analysed to see if they are consistent discretisations of the diffusion equation (3.1). 421 FICS Scheme ‘The FTCS scheme (3.41) was used in Sect.3.52 to obtain the solution ofthe one 0 MG>-1, 1-451 Z—1-4s8 of #<05/1-26) ‘These restrictions agree with the result given in Sects, 432 and 7.22. For more complicated equations it may be necessary to establish stability by evaluating the ‘equivalent of (4.40) for a range of values of 8, B and s, etc. This is often done ‘numerically, 84, Taeretcal Rackround For algorithms that couple thee time levels together, eg. Set.7.23, a quad- ‘atic equation in G must be solved to obtain the stability restrictions. For most ‘uid flow problems a system of governing equations is required. The von Neumann stability analysis then leads to an amplification matrix G in place ofthe amplif- cation factor G. The corresponding stability condition is ValS10- for all m an) where Zq are the eigenvalues of In this section itis assumed that the underlying physical problem is stable, However it may happen that one needs to compute flows that are concerned with physical instability; for example transition from laminar to turbulent flow. For Such flows a growing solution with time must be acceptable. This can be allowed for by requiring the magnitude ofthe eigenvalues in the matrix method (Sect. 431) ‘and the amplification factor in the von Neumann method (Sect 44) to be less than 1+0(40) This condition replaces the inequalities (4,20, 36). Ths aspect i iscussed further by Richtmyer and Morton (1967, p. 70). Stability of the dscretised equations is discussed more fully by Mitchell and Grif (1980), Isaacson and Keller (1966) and Richtmyer and Morton (1967). Its ‘generally accepted thatthe matrix method of determining stability s not o reliable 1s the von Neumann method. The reasons for this are discussed ia relation to the ‘one-dimensional transport equation (9.56) by Morton (1980) and Hindmarsh tal (1984) The problem of stability ofthe diseretised equations adjacent to boundaries lies beyond the scope ofthis book (see Sod 1985, Chap. 5) 44 Solution Accuracy Strictly, the previous discussion of convergence, consistency and stability has been concerned with the behaviour of the approximate solution inthe limit 4, 4t-»0. However in practice approximate solutions are obtained on a finite grid and the corresponding accuracy is of considerable importance The determination ofthe consistency, Sect. 42, produces an explicit expression {or the truncation error. For an exact solution ofthe partial diferentil equation it is possible to evaluate the accuracy ofthe representation ofthe individual deriva: tive terms as in Sect.33. Combining the individual terms together gives an indication of how closely the algebraic equation agrees with the partial diferential ‘equation, Asis to be expected from Sect. 33, evaluation ofthe leading term in the truncation error of the complete equation provides a close estimate ofthe error. As indicated in Sect.4.2 the order ofthe truncation error will usually coincide with the order of the solution error ifthe grid spacings are sufficiently small and if the initial and boundary conditions are suficiently smooth, It is common for the implied improvement in accuracy ((rom the truncation error) of higher-order schemes over say a second-order scheme, not to be achieved due to insulfcient smoothness in the initial conditions for the particular grid, Refining the grid will very often produce a superior accuracy forthe higherorder scheme but at an {ool aaray lel hear igh, and bene lar ore expen, than nccesary. Thus an engineering accuracy of 1% in the ms errr ofthe solution might be required. fourth-order scheme may only demonstrat superior accuracy ‘over a second-order scheme when the grid as ben refined tothe point where the ‘ms ertor is perhaps 001%, An example of such an effet of norsmooth initial data on the accuracy is given by Fletcher (983). For problems governed by hyperbole partial diferent equations, discon tikes can form inthe interior ofthe domain, and these fecivel limit the accuracy {hat can be achieved, unless they are soated frm the rest of the domain and local solution sought ‘One way of determining the accuracy of particular algorithm ona it grids to.applyit toa elated but simplified problem, which posesses an exact solution. In this regard Burge’ equation (Sec. 101) isusefl since it models the convective and [APC IV would be (based on Table 4.4) 1FL4=20FX=10R=10L=01M. For lines 48 to 73 of DIFF (Sect. 3.5.2}, and excluding WRITE statements, the ‘Table 44, Relative ection tine for bse operations ioe ——‘Migcompuc ————Sapenico Maatane cn (NECAPC IVY SUN SpuresuP MOF rr a 1 io io a i io a ta i st a ia a a 3 a 0s a 2 os os 2 oe oe oe & ss 32 a » Pry 2 2 to 100 2 te o 3 a a ag EE eo se "Re St ome M4 Thor Baskgroned following operation count is obtained. OPCT = [SFL +6FX + 5R-+4L + (N,—2\SFL+ 10FX+3R)JN, , where N, the number of steps and Nis the numberof estes IEN,= 11 the Sein out pe ine ep OCT =F a Oaing the aor operation count subseipted array hasbeen signed one fae pont operation 0 locate the subscript. 7 ot tLe Operation count estimates are pariculely wf inidentfpng parts ofthe computer program that are expensive anda comparing the ely economy of diferent algorithms pro to coding and testing. Because ofthe vara between dierent computers and the efort required fo obtain pecs resus, operation counts are most ecive when ited to look fr order of magetud dfcrencs in {xecution tine. In addon the operation count procedare needs to be sued shen ed With ear ad para roe comput (entoch ad Nee 46 Closure For the equations that govern Mid motion i is not posible t demonstrate convergence diel. However, i surly saghonvard to show tha the Giscreted form ofthe equations consistent (Sect 42) Tis usualy pose to Show that a “linearised” version ofthe governing equations i stable rt, although ths may require a computer-based computation. Consequently the La uivalence theorem tend to provide a necessary rahe than suficent condition fr coon In acts vieaton of Sy tun egies sel The matrix and yon Neumann mthods fr determing stability are strcty only applicable to linear equation, lthough both methods wil gie some guid, anc ifthe soni osm ely. Analermaine ener metho ca nde some nonlinear equations diel. This method is desorbed by Rice an Morton (1967, p13 Prt I shouldbe sese that rel fw problems are computed on frit sand that theoretical properties, deduced from allowing the ito converge tote sie, may not be realsale ona paral fit grid. This is more lel tobe probe wih higher-order schemes Tee The use of Tajor series expansion to stabish consistency (ert 42)is alo important in providing an expt expression forte truncation cor: Bese of the close corelation between the truncation eror aud the solution eros at east onsfine gi anthing that ean be done to reduce the truncation enor ao aly to reduce the solution error This may entail making a aperfe choi fog 4t/4x°)asin the FICS scheme ort may involve combining sotions so hat the leading term inthe truncation error is eliminated asin Rchardaon extra polation (Set 441) 47 Probiems 95 For steady problems there is another alternative, called the deferred correction ‘method (Smith 1965, p. M0). 1a this method a preliminary solution is computed ‘and used to evaluate the leading term in the truncation error. This term is “added” to the original discretised equation as 2 source term and an improved solution obtained. In principle the improved solution can be used to reevaluate the leading term in the truncation error and the whole process repeated. Usually a singe improved solution is computationally most efficient. Elimination of the leading term in the truncation error can also be used to construct higher-order schemes. After the initial discretisation the leading term in the truncation error is disretsed and “added” tothe original scheme. An example ofthis approach is provided in Sect 93.2. ‘Practical flow problems often require a computational solution in complicated three-dimensional domains, iavolving thousands of nodal unknowns. For such large-scale problems the assessment of the relative computational efficiency of ‘competing numerical schemes is an essential prerequisite to the main body of the ‘computational investigation, Finlayson (1980) provides work estimates and aceu- racy comparitons ofthe finite diference, finite element and orthogonal collocation (Gect..1) methods applied to ordinary diferential equations, and one- and two- tia 4 Ne g foatin 5 Te sas 0.0 0 ° 3s : 52 Finite Volume Method metho is sito the subdomain metho, exept that herein exit sbrducon of on approximate sluion ine (2) Te meted pray tonsarfenly hot drat repent Sex 321) Hsronddraesoor (Sou $29 then sonal ipa requie ‘521 Equation with First Derivatives Only Here the finite volume method will be illustrated forthe gener equation 24 oF 20. a ey : which by appropriate choice of, F and @ represents the various equations of Inoon For svampl =a, Pega and G5 (2) i the twosmensional version of the continuity equation (11.10). first. 62 105 5 Weighed Resa! Matos Appling subdomain metho to (52)fr the fit volum lenis (523)or te ite volume ABCD shown in (aq aF 3G db (GeE +) aay-0, 29 or aplyng Green's theorem, 46, GMaars f waaeo 525 where H=(F, 6). In Cartesian coordinates, Hends=Pdy—Gas 629 (625) is just statement of conervation Foch n(sa5 ion For the part hee 5 (525) coincides wth a ner satement fhe covseraog ‘ats Consent he fine vole method tation oft oven ton in integral form Get 12) in conta othe te dese ‘which is usually applied to the governing equation in differential form. Tt ‘An aproxinate vation of (629) would be te Glan 4y-c4n=0, (2 hee theate ofthe quads, ABCD nF ABCDin Fig $2, an te avrge va 4 over the quadrilateral is associated with q, ,. In (5.27), Prete Aven=Ven Ya Ba Fara O5UFia 1+ Fi) + eX and Gan OSG pa-1+G4a) » Fi S3, Two-dimensional ite volume 52 Fite Volume Method 107 with similar expression fr Aye, et. If is not a function of ime, (5.27) becomes days ldt + O51F 0-1 + FAV an~ 0516 1-1 + a) Son $05(F sat Fes s)dYoe~ O51 .a* Gr )be90 4OSUFs a+ Fyass)AYeo—O5(Gua* Gras Atco 405(F iat Fuald¥o4-O5(Gj-s4+ Gulen4=0 628) te bal i (0) sigur te ie olan equation (528) provides a sicteaaton in Caren coordina without he ef noduc eee Seton (Chap 2) I te eoel Rd aor and cts With eso Constants a8d (528) Beames 4OS(Gu4+ Gpass)4x-O54Fy- rat Fualdy=O 4 ye faetac Fro , Gunes Gias (529) jp Tae aay ‘which coincides with a centred diflerence representation forthe spatial terms in (623, ‘The finite volume method, which has been used for both incompressible and ‘compressible flow, has two major advantages. First it has good conservation (of ‘mas, etc) properties, Second it allows complicated computational domains to be diseretsed in simpler way than ether the isoparametric finite element formulation (Sect. 553) oF generalised coordinates (Sect. 122). ‘52.2 Equations with Second Derivatives In Sect. 521 the finite volume method is applied to (5.23), in which only frst derivatives appear, and produces a relatively straightforward disoetsation for- ‘mula (528) I second derivatives are present in the governing equation the finite volume method requires some modification. This situation is illustrated here by secking solutions of Laplace's equation a 28 (5.30) ata 1085. Weighed Resiual Methods 7 Fig $4. Compuations domain for he wotion of Laplace 4 : in the computational domain shown in Fig. $4 with the following Dirichlet boundary conditions: on WX, F=0 on XY, (631) on ¥2, 6=—— on ZW, With this choice of boundary conditions (5:30) has the exact solution ont, 633 Which permits the accuracy ofthe computational solutions to be assessed directly. If Laplace’s equation (5.30) had been written in polar coordinates the compu {ational domain shown in Fig. 54 would be regular. However, by deliberately solving this problem in Cartesian coordinates the ability of the finite volume method to handle distorted domains is illustrated, while retaining the advantage of an easily computed exact solution. Program FIVOL (Sect. $2.3) is sufficiently general to be epplicabe to other domain shapes once the interior gid points have ‘been determined, eg, using the techniques discussed in Sects. 132-4, ‘The finite volume method proceeds by applying the subdomain method to (530) for the inte volume ABCD shown in Fie. 85, giving Jaca [Hinds 633) 52 Fie Volume Mebod 108 Fg 55. Fite volume fora dtored we Following the same steps as in Sect. 52.1, (533) is evaluated approximately by Tan oe Different techniques for evaluating [26/0], 2 et. are discussed by Peyret ‘and Taylor (1983, p11). Here [26/2x], ais evaluated as the mean value over the area B’BC'D'A4'B' in Fig. 5S. Thus [EL u(r) )er(see) Ses 9 (FL ar(scren) HCG) e--(Seren) ee 9 and 6349 J ddy~ be sAent brdvne+ bidVowt badoe MO, Weighed Resa! Methods and similarly for foe Irthe mesh i nt too distorted, AYaw®— Aveo = Ayan and Aype®—Ayp ye AY-1,4 and a AV 10~ AV an DX (537) “Tereore (535) becomes Sar Sere (#] = Ayal ia-1~ O04 SA 12(9- 90) gag ox Se 638) [2] 2 ela b at aldo) 2 Jina Su 7 Developing equivalent expressions for (64/2), 66 permits (34) to be Qaaldn-1~ 4) + Pasl bn ¥4)4 Oael Bo 14- bua) Paclbe— en) + Qcolbsa+r—dsa)+ Peolbo—Ge)+Qo4l8)-10— Fa) + Pola Oo) » =o . 539) where sai Qaa=(Aedat AvAAV Sen » Pay =(8X aude 204 Manes Sen One=(Axde+ AyicY See + Pre= (Axe 8% 61+ Bye SIj0 1 )Spe Qeo=(Axo+ Sye0NSea » Feo (BxeoA Mesa A¥eoA Yas ASco and ou (xb AYE MS 04» Poa =(BXpb% 1+ AV 04d); WSna « Im (5.39) dX ¥4 ate evaluated as the average of the four surroundiag a 1.6539) bu 48 of the f ding nodal FeO at brat bras tOjad) - Substitution into (5.39) generates the following nine-point discretisation of (5.30) 0.25(Peo~Po)by-1.1+1 + (Qco+025(P5c~Poa)]P:av1 +0.25(Pye— Peo)bi+s.1+1 + (Qo4+025(Peo— Pas) $-1. ~Qu+Orc+Oco+ Ooa)bia+ Dre +0.25(Paa—Peo) Ores. +025(Poa~Pas)y-14-1+[0+0.25(Po4~ Pred} bs4-1 #0.25(Paa~ PreOyesa-1=0 (6.40) 52 Finite Volume Method In (540) Qsp and Pay, et. can be evaluated once and forall when the grid points are determined, Equation (540) is solved conveniently using successive over-relaxation (SOR), Sect. 63. Equation (540) is manipulated to give an estimate of 633, thus fa (0.25(Peo~ Poa) ;-1041+(Qeo+025(Pre—Poall duars +0.25(Pye— Peo); 1.+1+LOo4+025(Peo— Pan] Oj-1.8 ¥1Qsc+025(Pon— Fool 3 +0.25(Pog— Pas) j-14-1# (04s +025(Poa Foe) ,2-1 +0.25(Pay— Pred djes.a-1}"UQaa+Osc+Oco +004) (an) and the improved solution is O58 =Ohat AOR Oa) » (642) ‘where 1 the relaxation parameter (Sect. 6.3). ‘An interesting feature ofthe finite volume method is that Neumann (derivative) ‘boundary conditions can be handled as readily as Dirichlet boundary conditions by direct substitution into (5.34). 523 FIVOL: Finite Volume Method Applied to Laplace's Equation ‘The above method has been incorporated into a computer program, FIVOL, a listing of which is given in Fig. 5.6. The main parameters used in FIVOL are described in Table 5.4 TFIVOL reads in and writes out the control parameters lines 1-25) The grid is solution (for SOR) and the exact solution computed (lines 138-53) Since only the converged solution is of interest, the exact solution is also ‘sed as the initial solution for SOR. This leads to rapid convergence of the SOR scheme, The boundary conditions are set lines $7-64) strictly this part ofthe code isnot necessary since the boundary conditions have been evaluated, implicitly, by Tine 51 ‘The grid related parameters (Qgy, Pan, et) for each side are set lines 68-123). ‘The SOR iterative procedure evaluates (5-1) (lines 135-143), (542) at line 146 ‘computes 16 doe ine 149) and exits the iteration loop (ines 127-151) ifthe tolerance (EPS) it satisfied. The final solution and exact solution are written out (lines 165-167) and 1— Glog, computed and written out (lines 171-172), ‘Typical output for a 66 grid is shown in Fig. 57. By starting from the exact solution itis apparent that convergence of the SOR scheme is rapid. The large Value of 14 —dllme is mainly due tothe large change in the solution close to rz ‘The accuracy increases at the grid is refined (Table 5.5) but more SOR iterations are required to reach convergence. The disretsed equation (540) reduces to the centred finite diference scheme on a uniform rectangular grid tesan2tyyt bys Piri Myr basen ag, 643) 125, Weighed Residual Methods Fig 56. Listing of program FIVOL, segeaaseseseseszazevssseaseere Fig 86 (ont) Listing a progam FIVOL, M45. Weigh Resin! Methods Fig (ont) Listing af progam FIVOL, 52 Fie Vole Method 15 “Table 4, Parameter wed fo progam FIVOL, ax ‘ero points nthe rail detion KMAX Number of points nthe ccumferest iret MAX. Minimum be feat RW rw Fg 58) x rhe 5) Y re 58) mz re 50) THER er Fie $8) THEN ore 34) Es ‘Tolerance for converse of SOR om Betzaton paramter 1 (542) Pat Pane XAYA Dxa Dxk BMS ee B= arace marron oY one yume Aer Fit poy 2ane tame ne 1.010 toe omer arma 3s sare wate .snasons ig. $7. Typical ouput fom FIVOL M64 Weightes Residual Methods Tate $8. Fst volume slain erm wth pi resemeat WemtemObirenty = 18, fy nO, 0p 9113) : ‘No al ieraons ons Noles convergence we tine i mat owt 8 aie 0013 s which has second-order convergence, ie. halving the grid (if fine enough) reduces the error by a factor of (2%), For the non-uniform grid results shown in Table 53 the convergence rate is less than second order. Increasing grid distortion is ‘expected to reduce the convergence rate further (see Problem $4) ‘The finite volume method is widely used for transonic inviscid flow (Sect. 143) and for viscous fow (Sect. 1723. 5.3 Finite Element Method and Interpolation ‘The finite element method was developed intially as an adhoc engineering pro- cedure for constructing matrix solutions to stress and displacement calculations tn ‘ructual analysis. The method was placed on a sound mathematical foundation by considering the potential energy of the system and giving the finite element ‘method a variational interpretation. However, very few fuid dynamic or heat transfer) problems can be expressed in 8 variational form, But for many situations, the Galerkin method is equivalent to the Ritz method for solving variational problems, Consequently most ofthe fnte clement applications in fluid dynamics have used the Galerkin finite element formulation. Here we will focus exclusively on the Galerkin formulation of the finite element method. A traditional engineering interpretation of the finite element method is given by Zienkiewice (1977, A more mathematical perspective ofthe method is provided by Strang and Fix (1973), Oden and Reddy (1976) and Mitchell and Wait (1977, ‘Computational techniques for mainly structural applications ofthe Snite element method can be found in Bathe and Wilson (1976). The application of the traditional Site clement method to uid mechanics is treated by Thomasst (1981) and Baker (1983, In comparison with the (traditional) Galerkin method defined in Sect. 5.1, the Galerkin nite element method has two particularly important features, Firstly the approximate solution (5.2) is written directly in terms of the nodal unknovins, ie T=¥ Tax n9 44) 52 Fine Element Method aed laterplaton 117 tuto (4) cn be nt a elton of hea ol pot SSS Sly th en eto oe ea ‘Slo’ hte cutee sap Ce. a ra soon Sit ay date wo we tay whe ne ier eed SS estate nce of he conn mte a ao Sati te Conn gvemng pra ae et oat Soin a "Repti cing 2h in il ipa thm tue anes e Sri a eer et Th ern ata Spothlg tri we ebor st ede fon loader eee polyoma este oomiguus ments. Ths pros ‘shiny Erste ts thc wih wot ont ean cea tccac ces than dagea fe nat ation, Pas spans be eqns sage (hep. 9) ss pes Ct sree a ans eqeton ol oe mae con ; vor ae ment etd achieves scttston i wo sage, bh of whieh ude tn saya ror Fe cen ess a Ge ka ane come ti oa sono ste Ti aes eile amie nis Te ond ages had an sce starr Tecate seen finginein te ont apd eee unenel a ascopa ropa STURM fe 43) tu Duct Gaia. ‘53.1 Linear Interpolation Linear one-dimensional approximating functions, (x), are shown in Fig. $8. The Sunetion 4,(x) takes the values Fig 88 Osedimenons rear approximating functions HBS Weighed Resiua Methods 4-0 fore exis os 4 for xy.1 $x Sx, (clement 4), (54s) forx=x), On BS for xy SxS xy,, (clement B) , (546) 0 or x> ay. Thus 8 sonar ony forthe range xy << sy. similar manner the approximating function dy is notzero nly betweennodee and 3 For linea approximating fection (4) has the ome Te Tins doi $4) inched, T= Ty0)+ Toro inclement B, ean ie. only two terms contribute in each element due to the local nature of the approximating functions (Fig. 58) Inclement A, ds given by (548) and py by fe (548) In clement B, 4, is given by (546) and 4, by bn (545) ante SbOve constuction wil be used to obtain a linear interpolation of the Ho Leos) + singex) (s50) inthe range 5 x $1, Equation (550s shown in Fig 59. The nodal val blaine fom the exact solution y, jx) In partials cioeene we nt interpolated solution y,, is given by” — sean Pet Sa Yor baul)+¥/H(0) in clement A and Ya = WO Hes 4osC8) in clement B “ Inclement A, 4, and ¢, ae given by (5.48) and (545), and ¢ and (545), respectively. In element B, 6; and). ae given by (546) and (549) : ia ‘The linearly interpolated solution (551) is plotted in Fig. 59, Fora two-element division of the interval 05 x:$11 the interpolated solution is clearly rather inaccurate a the element midpoints, eg at x= 025, 7= 263099, yy, x=075, j= 208079, 3. Fine Element Method and Intepolition 119 30 Fig $9 One-tineasiona it semen itr paston “yr Os 7 te However, the accuracy improves rapidly asthe number of elements subdividing the interval 0 x 5 1 is increased (Table 56). The rms error for linear interpolation, ‘Table 5.6, is reducing ike dx’, where 4x is the span of each element. Tiss typical of linear interpolation. Namterot mae Numeral mae ements eer cement ener i cue a roy 4 come 2 01359 6 cms 5 oats + ome 4 oon [Atthis point the reader seeing this material forthe fst time may prefer to jump over quadratic interpolation and two-dimensional interpolation, and to pursve the discretisation process and equation solution for the Sturm-Liowville equation (ect. 54} 522 Quadratic Interpolation The use of linea interpolation, asin Figs. 5, 9, imposes a constraint on the approximate solution that it must vary linearly betweea the nodal points, We see (Table S46) that this introduces an error on a finite grid. Estimates for such (interpolation erors are given by Mitchell and Wait (1977, p. 119, which are ‘sell when the exact solution isnot available, For the same grid spacing we would expecta smaller interpolation eror if quadratic interpolation is wed ‘As a one-dimensional quadratic approximating function, (Fig 510) takes the values 1205. Weighted Residoal Methods ment amart 8 a ) ersyr sss ment a), O28) “ust) (Sues) Wray S aay (dement 5), sy for x> yea ‘The approximating functions are recognisable as Lagr recognisable as Lagrange interpolation functions. Thus 4, = 1 at node j and g; = Oat nodes j~2,)~1,j+1 and j+2 For quadratic interpolation (5-4) takes the following form in element Tm T-2bs-24 Tis Oia + Ty. 654) and in element B = TiOs+ Ter dios + Teadyea « 655) ie. only thre terms contribute in each element. For the sample problem (5.50) a suitable quadratic interpolation is Yon Yin $1-18)+ Yor 110943902) im clement A , Yon ™ YOM +j01 Oe102)+ Yyeadyea(%) in element B , ha where element A (ios 5.x) + tran(z oon (SES): ed (Se)G32). and simi ily for element B (x) $x $ x;,3) 53 Fite Eemest Method and interpolation 121 ‘The case of single quadratic element spanning the interval 0 $ x $ 1isshown in Fig. $9. The quadratically interpolated solution is clearly more accurate than the linearly interpolated solution withthe same numberof nodes. Te effect of eid refinement (increasing the number of quadratic elements) is to rapidly reduce the sms error (Table 5.6). The rate of reduction shown in Table Ss is like 4x? for ‘quadratic elements. Consequently quadratic interpolation becomes progressively ‘more accurate, compared with linear interpolation, as the grid is refined. In principe, cubic and higher-order interpolation are also available in practice itis unusual to use interpolation that is of higher order than quadratic. Although higher-order interpolation is more accurate it generates systems of equations that have many more non-zero terms than when low-order interpolation is used; ‘consequently higher-order interpolation is computationally mote expensive, part- cularly in two and three dimensions. Achieving the proper balance between accuracy and economy, ie. in choosing methods that are computationally efficient (Geet. 4.5) is one ofthe more interesting strategic considerations in computational ‘uid dynamics. ‘We can expect the finite element method solution error to reduce atthe same rate as the interpolation error, with grid refinement. Generally the solution error willbe larger on a given grid since there is an additional error due to the nodal point solution not coinciding with the exact solution. As a rough guide, the use of linear approximating functions generates solutions of about the same accuracy as produced by second-order finite difference methods and the use of quadratic approximating functions provides about the same accuracy as third-order finite diference methods. $33 Two-Dimensional Interpolation ‘The concept of finite elements, fom which the name of the method is taken, becomes more useful ia more than one dimension. Thus in two dimensions, the local solutions interpolated, separately, in each of the four elements, B,C and D, ‘which surround the (j,k}-th node (Fig. 5.11). The approximate solution, equivalent {0 (544), is expressed conveniently in terms ofan element-based coordinate system (Gsm) For bilinear interpolation the approximate solution can be written r= S rote. 639 where in each element ~1 5 & S 1, ~1 S 9 $1 (Fig S11) From (5.58 four terms contribute in each element. The approximating function 4h(¢,) takes the form 6,1) = 02511 + G)(1 +n) (559) For example, in element C of Fig. 5.15 125 Weigto Resin! Methots re Bl Fe i,t sll ambi ie ty g 4, = 0251-91, = 02591 +9(1—n) $5" 0250+ (1+) , $= 0250-91140), $0 that y= 1 when & =, m=; and gy =0 at all other nodes. For lines of constant ¢ of 1 the approximating functions, gy, demonstrate the same type of ‘ariation as the one-dimensional approximating function (Fig 58, AA three-dimensional view of a bilinear interpolating function centered at the (Usketh node is shown in Fig. 512. An examination of 5.58) and Fig $12 indicates (5.60) AY NY SARS RY para Z sh Kx % Fig S12, Bier iterplatonfnction 5 Fite Element Method and Interpolation 123 that Tis continuous as element boundaries are crossed; however derivatives of are not Just asin one dimension, two-dimensional (b}quadratic interpolating functions say be defined within a particular element (Fig. 5.13). For Lagrange elements the approximate solution, equivalent to (544), takes the form T=Y Tem, 61) where the biquadratic Lagrange approximating functions are given by comer nodes: AG) = 025 &8L+ GEM +e 5 midside nodes (&, 0; (én) = 05(1—@)na(l +n)» midside nodes (n,= 0} (61) = 05(L— mW VEGI+ 68) 5 Aeon) = (1-2) 1?) ‘The quadratic Lagrange approximating functions are interpolatory as before, ie (5.62) internal node: Qt when EG. nem, 4, =0 atall other nodes . ‘The form of the approximating function (5.62) can be visualised by considering constant values of €or m; then the approximating function resembles a one- dimensional approximating function, Fig. 5.10. This follows from the fact that the ‘two-dimensional Lagrange approximating functions are just products ofthe cor- Fig 13, Two-dimensional 125 Weiped Reston! Methots ‘ponding one dimensional Lagrange approximating functions. This has ior {nt ramieations fr interpolation im more than one dimension, paces oo telaon to constucingdinenonaly opt schemes Sr 89) an Siemon interpolation on ite elements wil be illustrated hee for he F=[1—08co40 529 }[c0¥0.5y)) , 60 Which is shown in Fig $.14 for the domain ~1 21 bas 0447x107 ons 8109 «10°» aon 027 10-> ‘542 STURM: Computation ofthe Searm-Liowville Equation In Sect. 5.4.1 the finite element method, with linear interpolation, is applied to the simplifed Sturm-Liouville equation (5.66) with boundary conditions given by (6.67, In tis subsection a computer program, STURM, will be described to obtain finite element solutions to (5.66 and 67) with linear and quadratie interpolation, For quadratic terpolating functions (5.57, the equations, (5.77 and 81) for by and gy have the following form for cornet nodes in the interior: =1_ay ba ae aca ax, . rity By Teas) at Aine» 634) 4 Mes “54, Fine Blmen Method ag he Strm-Liowvile Eguaon 131 (589 ‘The spec form ($84 and 85) results rom th esttionsx-4 = Kxj-24*) Tides = Ost, 45-2) These esredons can be relaxed but this leads fo more compte algebra expressions. "Ath Boundary node m = Jy (377 and 81) take the frm 636) ae ~(43) 24 2B) b +(e 68 For equations obtained using quadratic interpolation but centered at midside nodes, (5.77, 81) have the form (588) Aa, and 16x) (248 589) +S) Geen ‘ “The system of equations (5.76) is tridiagonal if linear interpolation is used ‘and alternating tridiagonal and peatadiagonal if quadratic interpolation is used. ffciet modifications of Gauss elimination are available for solving (5.76) for ‘iter situation and are described in Sects. 62.2 and 6.23. Slate ‘Program STURM applies the Galerkin finite element _met ‘Sturm: Liouville equation (5.66). A Usting of STURM is given in Fig 519, The main ‘parameters used in STURM are described in Table 59. STURM reads in (and writes out) the control parameters (ines 11-21). The x locations, exact solution and nodal values of the right-hand side functions, Fin 12S Weighed Residual Methods Fig S19. Listing of program STURM. (5.66), are set (lines 28-42), The contributions to # and G in (5.76) are evaluated (lines 43-69) and an adjustment made to account forthe boundary conditions, The bended system of equations (5.76) is solved by a call to BANFAC (line 83) to {actorise B into L.U form and a call to BANSOL (line 86) to solve the factorsed system, BANFAC and BANSOL are listed and described in Sect 623, The rns ettor between ¥, the solution returned by BANSOL, and the exact solution is computed and the output generated (lines 87-103), 454, inte Element Metbod ao he Strm Louie Eguation 133 eeseseess. eeseszes Fig 51. (om) Listing of program STURM in Fig 520. output for Hiner interpolation wih 40.25 i shown a Fig ‘Tip auton coponds ote elloving choo cosine in O56 45= 1.000 =100, ay solution error is generally ‘The results shown in Fig. 5.20 indicate that the solut ses smaller close to a Dirichlet boundary condition than close to @ Neumann bound- °° omarion of thems sluton eos fr near and gaara interpolaion with grid refinement is shown in Table 5.10. = 1.000, ay 165, Weighed Reda Matas ‘Tobe. Parameters wed in program STURM EEE EEL Paamaee—Docipion INT ear ineaion =, gaara ea PR 4. ony pt tse Sept non’ x surmise isin he = Secon, sclaig = Dan x = 19 A coefficients, a, in (5.66) mi é eda alec and (36) vex ‘Set tson se) : Facto é Gini) Banrac — Se'screas BaNsoL Se scceas aN tse gS See eee See Ie mise auroras Pig $28 Typ output rom STURM Noteworthy features of Table $.10 are that: 5) Higher-order interpolation (te. quadratic) is only slightly more accurate on very coarse grid than low-order (linear) interpolation. i) The accuracy of higher-order interpolation increases at a faster rate than low- ‘order interpolation as the grid is refine. i) Theoretical rates of convergence are achieved approximately (4x? for linear interpolation; 4x? for quadratic interpolation) ‘Table 10, Solution rors othe Sturm-Liowil role rn eerste eet Grid sis, nr a Lear iteration Quncaie interpolation in ‘0390 ua 0oi6s 6 ‘000504 10 ons S-Furter Appleton ofthe Finite Element Method 135 1 may be recalled that for the finite element method the approximating functions and weight functions are non-zero only in the small region surrounding the particular nde, Consequently the fnite element method isa local method. As with the finite difference method the (algebraic) equations generated by the finite ‘clement method connec together nodal values in small region only. However, the ‘number of connected nodes forthe finite element method in multidimensions is considerably greater than forthe finite diference method (Sect. 83 and Fletcher, 1984 ‘5.5 Further Applications of the Finite Element Method In this section the finite element method is applied to the diffusion equation (Gect. 55.1), the Poisson equation (Sect. 55.2) and Laplace's equation (Sect. 5.53) ‘The ist problem illustrates the usual finite element practice of disreising only the spatial terms. The time derivative term is disretsed as a separate step. The second problem introduces two spatial coordinates and, asa result, a more complicated ‘ructure in the diseretised equations The third problem outlines the isoparametric formulation which is useful ifthe computational domain is irregular. 551 Dilfesion Equation In this subsection the Galerkin fnite element method is applied to the on dimensional diffusion (heat conduction) equation i" aT e lover the interval 05x 1 and £20. Initial conditions ofthe form T(x, 0)=To(s) and boundary conditions 7(0,:)=a and T(t) =b are assumed. Tntroducing the same linear approximating functions (5.70) as used for the ‘turm-Liouville problem and applying the Galerkin finite element method in the same way produces the following result fr internal nodes, on a uniform grid: Yar) ar) Yar] aq aH+ del. ara), a wad For the Dirichlet boundary conditions indicated above no disretised equations are required at the boundary nodes. ‘Since the finite element formulation is applied in space only, the treatment of the term 07/2t in (5.90) isthe same as the treatment of the undiferentiated (in space) term Yin (5.66) Not surprisingly the same (1/6, 2/3, 1/6) weighting occurs in both (91) and in (583). dT dis replaced by 47"*/4¢ and the right-hand side of (591) is evaluated as a weighted average between the nth and the (n+ 1}th time levels, asim (7.28), the result is (590)

You might also like