Xmaple Setup
The preferred programming setup is WORKSHEET, not DOCUMENT. In
WORKSHEET mode, what you type will be echoed in RED. The response
bythe MapleEngine is in BLUE.
Extra things on the screen are called DOCKS. To remove or restore them:
VIEW ==> PALETTES ==> EXPAND DOCKS / COLLAPSE DOCKS.
Setup of Xmaple starts with TOOLS ==> OPTIONS. There are three sub-screens to set,
then APPLY GLOBALLY for them to take effect on next startup.
1. Main Xmaple Window, TOOLS located on the top menu bar Main Window
2. Options-->General: Photo of General options
3. Options-->Display: Photo of Display options
4. Options-->Interface: Photo of Interface options
5. Options-->Apply Globally: Photo of General tab
First Maple Lab
A sample first maple lab should address first use, then hand calculator functions.
Most first labs explore features suited for the math course involved. A first lab suited
for differential equations, linear algebra and partial differential equations can be found here:
A First Maple Lab Sample.
Troubleshooting
Maple's error message are irritating at first. Experience changes that.
Common Maple Coding Errors.
1. Do statements end with a semicolon or a colon?
2. Are parentheses, braces, brackets, etc., balanced? Code like
{ x,y } is good, but x,y} will cause trouble.
3. Are you trying to use something as a variable to which you have
already assigned a value? To "clear" a variable x , issue maple
command unassign('x'). You can clear many variables at once, e.g.,
unassign( 'x', 'y' ). You will not have to reload any packages after
using the unassign command. A variable that has a value assigned
becomes a constant. To display the value of an ordinary variable,
type its name, followed by a semicolon, e.g., x;
4. Symbols false gamma infinity true Catalan FAIL Pi are
pre-defined maple constants.
A common error is using pi (lowercase) or PI (uppercase) instead
of Pi (CamelCase) for the constant 3.1415927. Symbols pi and PI
are variables, not constants.
5. Are you using a function when an expression is called for, or vice
versa? Syntax g := x^2 + y^2; defines an expression while f := (x,y)
-> x^2 + y^2; defines a function. It makes good sense to code
f(1,3); but not so much sense to code g(1,2);
6. Are you using = when := is called for? The first tests for equality
(like double-equal in C++) while the second assigns a value to a
variable (like single-equal in C++).
7. Are you distinguishing between the three kinds of quotes? They are:
" the double quote, ' the single quote, and ` the left single quote.
The left single quote is basically used for nothing by rookies. When
used, it is in expressions like
`"two" "three"`; "two" "three"; `two''and"""three`;
`two` `three`; `two``three`; `two"``"three`;
To see the difference, execute the expressions. The single back
quote is not a duplicate double quote. Single quotes change a name
or constant into a symbol. For example, print(Digits) and
print('Digits') have two different outputs (one is 10, the other
symbol 'Digits'). Settle issues by reading maple help: ?quotes
8. If you use a function in a package, load the package first. To use
Determinant, load LinearAlgebra. To use display, load plots. To load
package LinearAlgebra
with(LinearAlgebra):
Determinant(A); # Load a package once per session.
LinearAlgebra[Determinant](A);
# Bulletproof code, no package load needed.
9. Use the shortcut ? to inquire about the details of a Maple
function, e.g., ?plot for information about plot or just ? for
general information.
10. If things seem hopelessly messed up, issue the command restart; You
will have to reload any needed packages after this.
11. If all of the licenses for the current version of Maple are being
used, you can use a different version by calling it up by name,
i.e. by typing xmapleV12 or xmapleV18 in a terminal window.
References.
The WWW has many examples of Maple code. Use a search engine to find
code that fits your application. Ask in the LCB Math Center Computer Lab
for textbooks to check out.