Maple 9 Learning Guide
Total Page:16
File Type:pdf, Size:1020Kb
Maple 9 Learning Guide Based in part on the work of B. W. Char c Maplesoft, a division of Waterloo Maple Inc. 2003 ii ¯ Maplesoft, Maple, Maple Application Center, Maple Student Center, and Maplet are all trademarks of Waterloo Maple Inc. c Maplesoft, a division of Waterloo Maple Inc. 2003. All rights re- served. The electronic version (PDF) of this book may be downloaded and printed for personal use or stored as a copy on a personal machine. The electronic version (PDF) of this book may not be distributed. Information in this document is subject to change without notice and does not repre- sent a commitment on the part of the vendor. The software described in this document is furnished under a license agreement and may be used or copied only in accordance with the agreement. It is against the law to copy software on any medium except as specifically allowed in the agreement. Windows is a registered trademark of Microsoft Corporation. Java and all Java based marks are trademarks or registered trade- marks of Sun Microsystems, Inc. in the United States and other countries. Maplesoft is independent of Sun Microsystems, Inc. All other trademarks are the property of their respective owners. This document was produced using a special version of Maple that reads and updates LATEX files. Printed in Canada ISBN 1-894511-42-5 Contents Preface 1 Audience . 1 Manual Set . 1 Conventions . 2 Customer Feedback . 2 1 Introduction to Maple 3 Worksheet Graphical Interface . 3 Modes . 3 2 Mathematics with Maple: The Basics 5 In This Chapter . 5 Maple Help System . 5 2.1 Introduction . 5 Exact Expressions . 6 2.2 Numerical Computations . 7 Integer Computations . 7 Commands for Working With Integers . 9 Exact Arithmetic—Rationals, Irrationals, and Constants . 10 Floating-Point Approximations . 12 Arithmetic with Special Numbers . 14 Mathematical Functions . 15 2.3 Basic Symbolic Computations . 16 2.4 Assigning Expressions to Names . 18 Syntax for Naming an Object . 18 Guidelines for Maple Names . 19 Maple Arrow Notation in Defining Functions . 19 The Assignment Operator . 20 Predefined and Reserved Names . 20 2.5 Basic Types of Maple Objects . 21 iii iv Contents ¯ Expression Sequences . 21 Lists . 23 Sets . 24 Operations on Sets and Lists . 25 Arrays . 27 Tables . 31 Strings . 32 2.6 Expression Manipulation . 33 The simplify Command . 33 The factor Command . 34 The expand Command . 35 The convert Command . 36 The normal Command . 36 The combine Command . 37 The map Command . 38 The lhs and rhs Commands . 39 The numer and denom Commands . 39 The nops and op Commands . 40 Common Questions about Expression Manipulation . 41 2.7 Conclusion . 42 3 Finding Solutions 43 In This Chapter . 43 3.1 The Maple solve Command . 43 Examples Using the solve Command . 43 Verifying Solutions . 45 Restricting Solutions . 47 Exploring Solutions . 48 The unapply Command . 49 The assign Command . 51 The RootOf Command . 53 3.2 Solving Numerically Using the fsolve Command . 54 Limitations on solve ..................... 55 3.3 Other Solvers . 58 Finding Integer Solutions . 58 Finding Solutions Modulo m . 58 Solving Recurrence Relations . 59 3.4 Polynomials . 59 Sorting and Collecting . 60 Mathematical Operations . 61 Coeácients and Degrees . 62 Contents v ¯ Root Finding and Factorization . 63 3.5 Calculus . 65 3.6 Solving Differential Equations Using the dsolve Command 71 3.7 Conclusion . 77 4 Maple Organization 79 In This Chapter . 79 4.1 The Organization of Maple . 79 The Maple Library . 80 4.2 The Maple Packages . 82 List of Packages . 82 Example Packages . 87 The Student Package . 87 Worksheet Examples . 88 The LinearAlgebra Package . 94 The Matlab Package . 96 The Statistics Package . 98 The simplex Linear Optimization Package . 101 4.3 Conclusion . 102 5 Plotting 103 In This Chapter . 103 Plotting Commands in Main Maple Library . 103 Plotting Commands in Packages . 103 Publishing Material with Plots . 104 5.1 Graphing in Two Dimensions . 104 Parametric Plots . 106 Polar Coordinates . 108 Functions with Discontinuities . 111 Functions with Singularities . 112 Multiple Functions . 114 Plotting Data Points . 116 Refining Plots . 118 5.2 Graphing in Three Dimensions . 119 Parametric Plots . 121 Spherical Coordinates . 121 Cylindrical Coordinates . 124 Refining Plots . 125 Shading and Lighting Schemes . 126 5.3 Animation . 127 Animation in Two Dimensions . 128 vi Contents ¯ Animation in Three Dimensions . 130 5.4 Annotating Plots . 132 Labeling a Plot . 133 5.5 Composite Plots . 134 Placing Text in Plots . 136 5.6 Special Types of Plots . 137 Visualization Component of the Student Package . 143 5.7 Manipulating Graphical Objects . 144 Using the display Command . 144 5.8 Code for Color Plates . 149 5.9 Interactive Plot Builder . 152 5.10 Conclusion . 153 6 Evaluation and Simplification 155 Working with Expressions in Maple . 155 In This Chapter . 155 6.1 Mathematical Manipulations . 156 Expanding Polynomials as Sums . 156 Collecting the Coeácients of Like Powers . 158 Factoring Polynomials and Rational Functions . 161 Removing Rational Exponents . 163 Combining Terms . 164 Factored Normal Form . 165 Simplifying Expressions . 168 Simplification with Assumptions . 169 Simplification with Side Relations . 169 Sorting Algebraic Expressions . 171 Converting Between Equivalent Forms . 172 6.2 Assumptions . 174 The assume Facility . 174 The assuming Command . 178 6.3 Structural Manipulations . 180 Mapping a Function onto a List or Set . 180 Choosing Elements from a List or Set . 182 Merging Two Lists . 184 Sorting Lists . 185 The Parts of an Expression . 188 Substitution . 196 Changing the Type of an Expression . 200 6.4 Evaluation Rules . 202 Levels of Evaluation . 202 Contents vii ¯ Last-Name Evaluation . 203 One-Level Evaluation . 205 Commands with Special Evaluation Rules . 206 Quotation and Unevaluation . 207 Using Quoted Variables as Function Arguments . 210 Concatenation of Names . ..