To plot graphs of functions in Maple, one can either identify the function by the expression which defines it, or one can define the function in Maple, and then use the function name in the plot command. For example, if , we can plot it as follows:
Notice that the Maple command ends in a semicolon, as all Maple commands do, and that multiplication is indicated by a star, not simply by juxtaposition. The represents the domain on which we plot the function. Both domains and ranges are indicated to Maple in this manner. Another way to plot this same function on the same domain is to first define a function as follows:
Then one can plot the function as follows.
Notice that you do not tell Maple a variable name in giving the domain, as you need to do when plotting an expression.We can evaluate the function in Maple in a similar manner as evaluating functions in mathematical notation. For example, to compute , we just type in:
If you have a function which is given by an expression, you can evaluate it at a certain input without formally defining a function in Maple as follows:
The reader will note that it is much easier to evaluate functions if they are defined. Maple also has many built in, or predefined functions, like the trigonometric and inverse trigonometric functions. For example,
Notice that in Maple, Pi, represents . If you type in pi, Maple will print it as , but it will not represent the constant .Let us plot both the sine and the arcsin on the same graph.
The plot of the arcsin in green does not look very attractive. By restricting the domain and range, we can get a much nicer picture.
Now you can clearly determine that the graph of the sin function is the one in red, while the graph of the inverse sine function is in blue.
(a) Plot the secant and the arcsecant on the same graph, so that the reader can get a good impression of what each of the graphs looks like, and which graph is which. Then explain what the domain and range of the arcsecant function is, and how you can see that from the graph.
(b) Plot the tangent and arctangent on the same graph, so that the reader can get a good impression of what each of the graphs looks like, and which graph is which. Then explain what the domain and range of the arctangent function is, and how you can see that from the graph .