next up previous
Next: About this document ... Up: lab_template Previous: lab_template

Subsections


Maple Reference

Mathematical Operators and Constants

The symbols in the table below are used to create Maple expressions.
Symbol Description Example
+,-,*,/,^ arithmetic operators 2+54/3*5^3;
(,) expression delimiters (2+12/25)*3^(7/3);
Pi $\pi$ 5*Pi;
I imaginary unit, $\sqrt{-1}$ 2+5*I;
infinity positive infinity, $\infty$  
alpha, beta, gamma other constants  

Special Maple Delimiters and Command Terminators

The symbols in the table below are used in Maple to terminate commands, assign results to named labels, and to delimit sets and lists.
Symbol Description Example
; terminate command, get output 2*31^12*Pi;
: terminate command, suppress output 2*31^12*Pi:
= equality, for setting up equation 2*x+3=5
:= assignment of a label to an expression f := 23*x+5*y;
    2*f;
-> function definition g := x -> x^2+2*x;
    g(x);
.. numerical range, mostly used in plot -2..2
    plot(x^2,x=0..5);
[,] delimit a list in Maple [1,2,3,4]
{,} delimit a set in Maple {2,5,x,r}
' ' delay evaluation, often x := 2;
  used to clear out a variable x := 'x';
  given a previous value x;
'' `` used to delimit a character string, plot(x^2,x=-2..2,title =
  for example a plot title ``My First Plot'');

Standard Mathematical Functions

Command function Example
abs absolute value abs(-12/31);
sqrt square root function sqrt(35);
    sqrt(x+1);
exp exponential function exp(2*x);
ln natural logarithm ln(200.4);
sin, cos, tan trig functions cos(Pi);
cot, sec,csc   tan(x);
arccos, arcsin inverse trig arcsin(1/2);
arctan, arccot functions arctan(x);
arcsec, arccsc   arccsc(1);

Essential Maple Commands

The following commands are those used most often in Calculus. Note that each example ends with a semi-colon, which is the signal to Maple to process the command and print its result.
Command Description Example
with load a Maple package with(CalcP7);
subs substitute a value subs(x=2,x*exp(x));
evalf evaluate to a decimal evalf(Pi);
  (floating-point) approximation  
expand expand an expression expand((x+1)^8);
factor factor an expression factor(x^2+x);
simplify simplify and expression simplify((x^2+x)/(x+1));
solve solve an equation analytically solve(2*x+3 = 5,x);
fsolve solve an equation numerically fsolve(x=tan(x),x=Pi/2..3*Pi/2);
D differentiation operator D(g)(x);
  (works only on a function) D(g)(2);
diff differentiation of an diff(x^2,x);
  expression or a function diff(g(x),x,x);
int indefinite or definite int(x^2,x);
  integral int(x^2,x=0..1);
limit limit of an expression limit(sin(x)/x,x=0);
  or a function limit(f(x),x=0);
plot two-dimensional plot plot(x^2,x=-2..2);
  more than one function plot([x^3,2*x],x=-2..2);
plot3d three dimensional plot plot3d(x^2+y^2,x=-1..1,y=-1..1);
map apply a function to a list map(t -> 1/t,[1,2,3,4]);
seq define a sequence seq(i^3,i=1..5);


next up previous
Next: About this document ... Up: lab_template Previous: lab_template
Jane E Bouchard
2011-08-17