Some Basics of Maple
Equations, etc. must be terminated with an ":" or an";". The former suppresses Maple output for that line whereas the latter does not.
Maple uses the same kind of mathematical syntax as most spreadsheets and programming languages. Each line that you type in (Maple commands) must end with either a semicolon (if you want to see Maple's interpretation of it, i.e., the output) or a colon (to suppress the output). Expressions can be given names using ":=", but a few terms are reserved (e.g., Pi).
Note that Maple outputs the ratio as a fraction. To see it in decimal form, use the evalf Maple function. note also the use of the "%" sign to indicate to Maple to use the result of the previous calculation. This feature can save you some typing! To access the output from two lines before, use "%%" as the input. Many standard functions are part of the Maple library, such as sine, cosine, tangent, exponential, logarithms, etc. Use Maple's extensive Help system to check on the syntax of each and/or use the pull-down View menu and go to View > Palettes > Expression to access a great shortcut toolbar (there is a similar one for symbols). Keep in mind that Maple assumes all angles are in radians, just like spreadsheets.
You can also name equations, which can come in real handy when dealing with systems of equations:
You can assign functions of whatever variables you like and then use them do do all sorts of things:
To plot a function of one variable, use the "plot" command. To do so, you specify the function AND the range of the dependent varaible.
> plot(f(r), r=-10...10);
To do a quick plot with labels, type the equation directly into the plot command and follow this format (also, note the difference between using axes=boxed and the default axes in the previous example):
> plot(5+4*t+7*t^2, t=-2...4, title= "x vs. t", labels=["time (s)", "dist. (m)"], axes=boxed);
To do more than one plot on the same graph, put the list of functions to plot in square brackets, separated by commas:
To do logarithmic plots (or semilog plots) use loglogplot (or logplot or semilogplot - type ?logplot for details). You must type with(plots): first in order to use this function.
Calculus is pretty easy to do. To take a derivative, for example, use the "diff" function" (you must specify the variable that you are differentiting with respect to). Integrals work in a similar way.
The next step : Defining a function of one (or two!) variable(s):
Now we can evaluate (or plot) these: