add
command to
add vectors. In order to use this command, you must have executed the
command with(linalg):
in order to tell Maple about this command.
If you have defined
T:=(s,t)-> [(2+cos(t))*cos(s),(2+cos(t))*sin(s),sin(t)];
then notice that
p := T(0,Pi/2);
q := T(0,3*Pi/2);
returns two vectors (points in 3-space).
One way to parametrize the line segment between any two points p and q is (1-t) p + t q, 0 <= t <= 1. In Maple, we cannot just type in this expression, since p and q are vectors. Instead we would type the command:
S := add(p, q, 1-t, t);
The expression S
(which depends on t)
is now a parametrization of the
line segment from p to q.
You may wish to look at the help page ?add
for
further examples and explanations.