ebook img

Computer Algebra Recipes: An Advanced Guide to Scientific Modeling PDF

381 Pages·2007·4.72 MB·English
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview Computer Algebra Recipes: An Advanced Guide to Scientific Modeling

Computer Algebra Recipes An Advanced Guide to Scientific Modeling Richard H. Enns George C. McGuire Computer Algebra Recipes An Advanced Guide to Scientific Modeling RichardH.Enns GeorgeC.McGuire SimonFraserUniversity UniversityCollegeofFraserValley DepartmentofPhysics DepartmentofPhysics Burnaby,B.C.V5A1S6 Abbotsford,BCV2S7M9 Canada Canada [email protected] [email protected] CoverdesignbyMaryBurgess. LibraryofCongressControlNumber:2006936017 ISBN-10:0-387-25768-3 e-ISBN-10:0-387-49333-6 ISBN-13:978-387-25768-6 e-ISBN-13:978-0-387-49333-6 Printedonacid-freepaper. (cid:2)c2007SpringerScience+BusinessMedia,LLC Allrightsreserved.Thisworkmaynotbetranslatedorcopiedinwholeorinpartwithoutthewritten permissionofthepublisher(SpringerScience+BusinessMediaLLC,233SpringStreet,NewYork, NY10013,USA)andtheauthor,exceptforbriefexcerptsinconnectionwithreviewsorscholarly analysis.Useinconnectionwithanyformofinformationstorageandretrieval,electronicadaptation, computersoftware,orbysimilarordissimilarmethodologynowknownorhereafterdevelopedis forbidden. Theuseinthispublicationoftradenames,trademarks,servicemarksandsimilarterms,evenifthey arenotidentifiedassuch,isnottobetakenasanexpressionofopinionastowhetherornottheyare subjecttoproprietaryrights. 9 8 7 6 5 4 3 2 1 springer.com (EB) PREFACE A computer algebra system (CAS) not only has the number \crunching" and plotting capability of traditional computing languages such as Fortran and C, but also allows one to perform the symbolic manipulations and derivations required in most mathematically based science and engineering courses. To introduce students in these disciplines to CAS-based mathematical modeling and computation, the authors have previously developed and classroom tested the text Computer Algebra Recipes: A Gourmet's Guide to the Mathematical Models of Science [EM01] based on the Maple CAS. Judging by course evalua- tions and reader feedback, the response to this book and the computer algebra approach to modeling has been very favorable. With the release of several new versions of Maple since this text was published and the authors' accumulation of many insightful comments and helpful suggestions, a second up-dated edi- tion seemed expedient. However, incorporating all the changes would make an already lengthy book even longer. So the topics of the Gourmet's Guide have been reorganized into two new stand-alone volumes, an already-published Introductory Guide [EM06] and this Advanced Guide. In this book, we explore mathematical models involving linear and nonlin- earordinaryandpartialdi®erentialequations(ODEsandPDEs). Thisvolume, which may be used either as a course text or for self-study, features an eclectic collectionofMaplecomputeralgebraworksheets,or\recipes,"thataresystem- atically organized to illustrate graphical, analytical, and numerical techniques applied to ODE/PDE-based scienti¯c modeling. No prior knowledge of Maple is assumed, the early recipes introducing the reader to the basic Maple syntax, the subsequent recipes introducing further Maple commands and structure on a need-to-know basis. The recipes are fully annotated in the text and in most cases presented as \stories" or in a historical context. Each recipe typically takes the reader from the analytic formulation of an interesting mathematical model to its analytic or numerical solution and ¯nally to either a static or animated graphical visu- alization of the answer. Every recipe is followed by a set of problems that can be used to check one's understanding or develop the topic further. For your convenience, the recipes are included on a CD located in the inside back cover. v Contents PREFACE v INTRODUCTION 1 A. Computer Algebra Systems . . . . . . . . . . . . . . . . . . . . . . 1 B. Computer Algebra Recipes . . . . . . . . . . . . . . . . . . . . . . . 2 C. Introductory Recipe: Boys Will Be Boys . . . . . . . . . . . . . . . 3 D. Maple Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 E. How to Use This Text . . . . . . . . . . . . . . . . . . . . . . . . . 9 I THE APPETIZERS 11 1 Phase-Plane Portraits 13 1.1 Phase-Plane Portraits . . . . . . . . . . . . . . . . . . . . . . . . 13 1.1.1 Romeo and Juliet. . . . . . . . . . . . . . . . . . . . . . . 18 1.1.2 There's No Damping Vectoria's Romantic Heart . . . . . 23 1.1.3 Van der Pol's Limit Cycle . . . . . . . . . . . . . . . . . . 28 1.2 Three-Dimensional Autonomous Systems . . . . . . . . . . . . . 32 1.2.1 The Period-Doubling Route to Chaos . . . . . . . . . . . 33 1.2.2 The Oregonator . . . . . . . . . . . . . . . . . . . . . . . 40 1.2.3 RoÄssler's Strange Attractor . . . . . . . . . . . . . . . . . 44 2 Phase-Plane Analysis 47 2.1 Phase-Plane Analysis. . . . . . . . . . . . . . . . . . . . . . . . . 47 2.1.1 Foxes Munch Rabbits . . . . . . . . . . . . . . . . . . . . 51 2.1.2 The Mona Lisa of Nonlinear Science . . . . . . . . . . . . 58 2.1.3 Mike Creates a Higher-Order Fixed Point . . . . . . . . . 67 2.1.4 The Gnus and Sung of Erehwon . . . . . . . . . . . . . . 73 2.1.5 A Plethora of Points . . . . . . . . . . . . . . . . . . . . . 78 2.2 Three-Dimensional Autonomous Systems . . . . . . . . . . . . . 82 2.2.1 Lorenz's Butter°y . . . . . . . . . . . . . . . . . . . . . . 82 2.3 Numerical Solution of ODEs. . . . . . . . . . . . . . . . . . . . . 88 vii viii CONTENTS 2.3.1 Finite Di®erence Approximations . . . . . . . . . . . . . . 89 2.3.2 Rabbits and Foxes: The Sequel . . . . . . . . . . . . . . . 91 2.3.3 Glycolytic Oscillator . . . . . . . . . . . . . . . . . . . . . 96 2.3.4 Fox Rabies Epidemic . . . . . . . . . . . . . . . . . . . . . 101 II THE ENTREES 107 3 Linear ODE Models 109 3.1 First-Order Models . . . . . . . . . . . . . . . . . . . . . . . . . . 110 3.1.1 How's Your Blood Pressure? . . . . . . . . . . . . . . . . 110 3.1.2 Greg Arious Nerd's Problem . . . . . . . . . . . . . . . . 115 3.2 Second-Order Models. . . . . . . . . . . . . . . . . . . . . . . . . 118 3.2.1 Daniel Encounters Resistance . . . . . . . . . . . . . . . . 118 3.2.2 Meet Mr. Laplace . . . . . . . . . . . . . . . . . . . . . . 121 3.2.3 Jennifer's Formidable Series . . . . . . . . . . . . . . . . . 126 3.3 Special Function Models . . . . . . . . . . . . . . . . . . . . . . . 130 3.3.1 Jennifer Introduces a Special Family . . . . . . . . . . . . 131 3.3.2 The Vibrating Bungee Cord . . . . . . . . . . . . . . . . . 137 3.3.3 Mathieu's Spring . . . . . . . . . . . . . . . . . . . . . . . 142 3.3.4 Quantum-Mechanical Tunneling . . . . . . . . . . . . . . 144 4 Nonlinear ODE Models 149 4.1 First-Order Models . . . . . . . . . . . . . . . . . . . . . . . . . . 150 4.1.1 An Irreversible Reaction . . . . . . . . . . . . . . . . . . . 150 4.1.2 The Struggle for Existence . . . . . . . . . . . . . . . . . 152 4.1.3 The Bad Bird Equation . . . . . . . . . . . . . . . . . . . 161 4.2 Second-Order Models. . . . . . . . . . . . . . . . . . . . . . . . . 164 4.2.1 Patches Gives Chase . . . . . . . . . . . . . . . . . . . . . 164 4.2.2 Oh What Sounds We Hear! . . . . . . . . . . . . . . . . . 168 4.2.3 Vectoria Feels the Force and Hits the Bottle . . . . . . . . 175 4.2.4 Golf Is Such an \Uplifting" Experience . . . . . . . . . . 179 4.3 Variational Calculus Models . . . . . . . . . . . . . . . . . . . . . 185 4.3.1 Dress Design, the Erehwonese Way . . . . . . . . . . . . . 185 4.3.2 Queen Dido Wasn't a Dodo . . . . . . . . . . . . . . . . . 191 4.3.3 The Human Fly Plans His Escape Route. . . . . . . . . . 195 4.3.4 This Would Be a Great Amusement Park Ride . . . . . . 201 5 Linear PDE Models. Part 1 207 5.1 Checking Solutions . . . . . . . . . . . . . . . . . . . . . . . . . . 207 5.1.1 The Palace of the Governors . . . . . . . . . . . . . . . . 207 5.1.2 Play It, Sam . . . . . . . . . . . . . . . . . . . . . . . . . 211 5.1.3 Three Easy Pieces . . . . . . . . . . . . . . . . . . . . . . 215 5.1.4 Complex, Yet Simple . . . . . . . . . . . . . . . . . . . . . 220 5.2 Di®usion and Laplace's Equation Models. . . . . . . . . . . . . . 223 CONTENTS ix 5.2.1 Freeing Excalibur . . . . . . . . . . . . . . . . . . . . . . . 223 5.2.2 Aussie Barbecue . . . . . . . . . . . . . . . . . . . . . . . 227 5.2.3 Benny's Solution . . . . . . . . . . . . . . . . . . . . . . . 231 5.2.4 Hugo and the Atomic Bomb . . . . . . . . . . . . . . . . . 236 5.2.5 Hugo Prepares for His Job Interview . . . . . . . . . . . . 241 6 Linear PDE Models. Part 2 247 6.1 Wave Equation Models . . . . . . . . . . . . . . . . . . . . . . . . 247 6.1.1 Vectoria Encounters Simon Legree . . . . . . . . . . . . . 247 6.1.2 Homer's Jiggle Test . . . . . . . . . . . . . . . . . . . . . 251 6.1.3 Vectoria's Second Problem . . . . . . . . . . . . . . . . . 254 6.1.4 Sound of Music? . . . . . . . . . . . . . . . . . . . . . . . 257 6.2 Semi-in¯nite and In¯nite Domains . . . . . . . . . . . . . . . . . 261 6.2.1 Vectoria's Fourth Problem . . . . . . . . . . . . . . . . . . 261 6.2.2 Assignment Complete! . . . . . . . . . . . . . . . . . . . . 263 6.2.3 Radioactive Contamination . . . . . . . . . . . . . . . . . 266 6.2.4 \Play It, Sam" Revisited . . . . . . . . . . . . . . . . . . 270 6.3 Numerical Simulation of PDEs . . . . . . . . . . . . . . . . . . . 274 6.3.1 Freeing Excalibur the Numerical Way . . . . . . . . . . . 275 6.3.2 Enjoy the Klein{Gordon Vibes . . . . . . . . . . . . . . . 278 6.3.3 Vectoria's Secret . . . . . . . . . . . . . . . . . . . . . . . 281 III THE DESSERTS 285 7 The Hunt for Solitons 287 7.1 The Graphical Hunt for Solitons . . . . . . . . . . . . . . . . . . 290 7.1.1 Of Kinks and Antikinks . . . . . . . . . . . . . . . . . . . 290 7.1.2 In Search of Bright Solitons . . . . . . . . . . . . . . . . . 293 7.1.3 Can Three Solitons Live Together? . . . . . . . . . . . . . 296 7.2 Analytic Soliton Solutions . . . . . . . . . . . . . . . . . . . . . . 299 7.2.1 Follow That Wave! . . . . . . . . . . . . . . . . . . . . . . 300 7.2.2 Looking for a Kinky Solution . . . . . . . . . . . . . . . . 304 7.2.3 We Have Solitons! . . . . . . . . . . . . . . . . . . . . . . 306 7.3 Simulating Soliton Collisions . . . . . . . . . . . . . . . . . . . . 308 7.3.1 To Be or Not to Be a Soliton . . . . . . . . . . . . . . . . 308 7.3.2 Are Diamonds a Kink's Best Friend? . . . . . . . . . . . . 312 8 Nonlinear Diagnostic Tools 319 8.1 The Poincar¶e Section . . . . . . . . . . . . . . . . . . . . . . . . . 319 8.1.1 A Rattler Signals Chaos . . . . . . . . . . . . . . . . . . . 320 8.1.2 Hamiltonian Chaos . . . . . . . . . . . . . . . . . . . . . . 323 8.2 The Power Spectrum . . . . . . . . . . . . . . . . . . . . . . . . . 329 8.2.1 Frank N. Stein's Heartbeat . . . . . . . . . . . . . . . . . 332 8.2.2 The Rattler Returns . . . . . . . . . . . . . . . . . . . . . 334 x CONTENTS 8.3 The Bifurcation Diagram . . . . . . . . . . . . . . . . . . . . . . 337 8.3.1 Pitchforks and Other Bifurcations . . . . . . . . . . . . . 338 8.4 The Lyapunov Exponent . . . . . . . . . . . . . . . . . . . . . . . 342 8.4.1 Mr. Lyapunov Agrees . . . . . . . . . . . . . . . . . . . . 343 8.5 Reconstructing an Attractor . . . . . . . . . . . . . . . . . . . . . 345 8.5.1 Putting Humpty Dumpty Together Again . . . . . . . . . 346 8.5.2 Random Is Random . . . . . . . . . . . . . . . . . . . . . 349 8.5.3 Butter°y Reconstruction. . . . . . . . . . . . . . . . . . . 351 Epilogue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 353 Bibliography 355 Index 361 INTRODUCTION A. Computer Algebra Systems Man is still the most extraordinary computer of all. John F. Kennedy, former American president. Speech, 21 May 1963. Unlike traditional programming languages such as Fortran and C, a computer algebra language such as Maple allows one to compute not only with num- bers, but also with symbols, formulas, equations, and so on. Using a computer algebrasystem(CAS),symboliccomputationcan bedoneonthecomputer, re- placing the traditional pen-and-paper approach with the keyboard/mouse and computer display. By entering short, simple, transparent commands on the computer keyboard (which will be referred to as the \classic" approach), or by selecting mathematical symbols from a palette with the mouse, the CAS user can quickly and accurately generate symbolic input and output on the com- puter screen. Mathematical operations such as di®erentiation, integration, and series expansion of functions can be done analytically on the computer. Because it also has numerical capability, a CAS allows the student or the researchertotackleallaspectsofmathematicalmodeling,fromanalyticderiva- tion and manipulation of the model equations to the analytic or numerical solution of those equations, to the plotting or animation of the results. One of the most powerful computer algebra systems currently available is Maple 10, which will be used in this text. Useful reference books to this CAS are the Maple user manual [Map05] and the introductory and advanced programming guides [MGH+05]. In the two volumes of Computer Algebra Recipes, we present classic Maple worksheets, or \recipes," that demonstrate how a CAS can serve as a valu- ableadjuncttoolin easilyderiving, solving, plotting, andexploringinteresting, modernscienti¯c models chosen from awide variety of disciplinesrangingfrom the physical and biological sciences to the social sciences and engineering. The present book is the second volume and concentrates on mathematically more advanced models involving linear and nonlinear ordinary and partial di®eren- tialequations(ODEsandPDEs). TheclassicMapleworksheetinterface,which requires less computer memory than the standard interface, isused togenerate all the mathematical and graphical output shown in this text. 1

Description:
Modern computer algebra systems are revolutionizing the teaching and learning of mathematically intensive subjects in science and engineering, enabling students to explore increasingly complex and computationally intensive models that provide analytic solutions, animated numerical solutions, and com
See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.