Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
84 views

Notes For Maple Math1131

The document provides an overview of key concepts for using Maple including: 1) Different brackets have specific uses such as parentheses for expressions, braces for sets, and brackets for lists. 2) Constants like pi, i, and e can be used and functions are defined using commands like diff and int. 3) Variables are assigned using : = and functions take an input to return an output.

Uploaded by

facosot521
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
84 views

Notes For Maple Math1131

The document provides an overview of key concepts for using Maple including: 1) Different brackets have specific uses such as parentheses for expressions, braces for sets, and brackets for lists. 2) Constants like pi, i, and e can be used and functions are defined using commands like diff and int. 3) Variables are assigned using : = and functions take an input to return an output.

Uploaded by

facosot521
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

Notes for Maple

The Basics

The different brackets are not interchangeable:


 ( ) = used in mathematical expressions
 { } = contains elements of a set
 [ ] = contain elements of a list
 < > = used to enter in vectors and matrices.

Constants
 π = Pi
 I = i (sqrt(-1))
 Infinity
 e^x = exp(x)

Assigning Variables

You can assign any Maple expression to a variable for future use.
To assign a variable you must you ‘:=’, with there being no spaces between : and =.

E.g. f:= sin(x), f is assigned the value of sin(x).

Unassigning Variables

To unassign a variable, use the command unassign (‘variable1’, ‘variable2’)

To unassign all variables at once, use the restart command.

Expressions vs Functions

Functions take an input from its domain and returns an output in its range.
g: = x-> x^2-x
g is assigned to be the rule that takes x as input and returns x^2-x as output.
Packages
To load a package, use with(name of package).

Evaluating a function
If a function f is defined, you can use the usual notation f(x) for the value of f at x.

Substituting an expression

Subs
If a function has been assigned, the command Subs (x=value, function) can be used to find f at the
value of x.

Piecewise-Defined functions

Use the function piecewise() to enter a piecewise function.


Simplifying Expressions
 Factor = factorises the polynomial
 Normal = Tries simplifying expressions involving rational functions.

Limits
Can be used to find the limit as an expression approaches a finite value or infinity’ and left hand and
right-hand limits.

Limit(expression, variable = values)

Derivatives

First derivatives

Differentiating an expression

Diff(expression, variable)
Variable = variable that you are differentiating with respect to.

Subs(x=number, Diff(expression, variable))  gives you the derivative of the expression at number

Differentiating a function

D(function)  will give you the first derivative of the function.

D(function)(number)  will give you the value of the first derivative at number.

Higher order derivatives

Expressions

Diff(expression,x,x,x,x,x,x,x)  differentiates the expression 7 times

Diff(expression, x$7)  Differentiates the expression 7 times

Functions

D[1$6](f)  Differentiates f, 6 times and finds its value at 1.

Implicit Differentiation

Implicitdiff(equation, variable1, variable 2)


Will find the derivative of variable 1 with respect to variable2 given that equation holds true.

Use subs(variable1=number, variable2 = number, %)  finds the derivative at certain points.

Maxima and Minima

Use maximize(equation)  to give the global maximum


Use minimize(equation)  to give the global minimum

Minimize(equation,x=interval) gives the local minimum on the interval.

Maximize(equation,x=interval) gives the local maximum on the interval.

Integration

Indefinite Integration

Int(expression, variable)  expression is integrated with respect to variable.


Note that maple does not show +C in these integrals.

Definite Integrals

Int(expression, variable=a..b)
If Maple cannot find an indefinite integral symbolically, it will return it unevaluated.
But, evalf(%) can be used to find a numerical approximation to the definite integral.

Collections of Expressions

Maple Sequences

A list of things separated by commas.

Construct a sequence in Maple by:


 Typing the terms separated by commas
o S1:= 1,1,1,1;
 Using $
o S1:= 1$4;
 Using seq.
o Seq (1,k=1..6);

Sets vs Lists

Sets
 enclosed in a { } bracket.
 Maple doesn’t remember the order of the terms
 Repetitions are removed

Lists
 enclosed in a [ ] bracket
 Maple remembers the order of the terms
 Repetitions are not removed.

Sums and Products

Maple can add or multiply the terms in a Maple sequence, set or list using “add” and “mul”.

‘sum’ and ‘product’ can also be used, but they require the seq syntax to be used.
Manipulating structures

Nops(set) gives you the number of terms in the set/list/sequence

Op(set)  lets you recover the sequence of terms inside a list

Subs(variable=number, to apply over)  replaces a variable with an expression in a list.

Map(variable, what to apply over)  applies a function to each element in a list

Complex Numbers

Evalc(variable/equation)  force maple to give answers in Cartesian form

Re(equation)  gives you the real part of a complex number

Im(equation)  gives you the imaginary part of a complex number

argument(equation)  gives the principal argument of a complex number

abs(equation)  gives the modulus of a complex number

conjugate(equation)  gives the conjugate of a complex number

You might also like