Student[Precalculus] - Maple Programming Help

Home : Support : Online Help : Mathematics : Geometry : Student/Precalculus/Slope

Student[Precalculus]

 Slope
 Find the slope of a line

 Calling Sequence Slope(p1, p2) Slope(L, x) Slope(f, x1, x2, x)

Parameters

 p1 - 2-element list or 2-Vector p2 - 2-element list or 2-Vector L - line, as expression or operator x - (optional) variable in L or f f - expression or operator x1 - algebraic x2 - algebraic

Description

 • The command Slope(p1, p2) computes the slope of the line through the points p1 and p2.
 • The command Slope(L) computes the slope of the line defined by L.  If L is given as an expression, it should be a polynomial of degree one in one variable.  If L is given as an operator, it should take a single argument, and evaluation at a symbolic value should produce a polynomial of degree one in that variable.  The command Slope(L, x) computes the slope of the line defined by the algebraic expression L considered as a function of the variable x.
 • The command Slope(f, x1, x2) computes the slope of the secant line joining (x1,f(x1)) and (x2,f(x2)).  The command Slope(f, x1, x2, x) does the same in the case when f is an expression returning the slope of the line between (x1,eval(f,x=x1)) and (x2,eval(f,x=x2)).
 • This command is part of the Student[Precalculus] package, so it can be used in the form Slope(..) only after executing the command with(Student[Precalculus]).  However, it can always be used in the form Student[Precalculus][Slope](..).

Examples

 > $\mathrm{with}\left({\mathrm{Student}}_{\mathrm{Precalculus}}\right):$
 > $\mathrm{Slope}\left(\left[0,0\right],\left[1,2\right]\right)$
 ${2}$ (1)
 > $\mathrm{Slope}\left(⟨0,0⟩,\left[1,2\right]\right)$
 ${2}$ (2)
 > $\mathrm{Slope}\left(⟨0,0⟩,⟨1,2⟩\right)$
 ${2}$ (3)
 > $\mathrm{Slope}\left(1\right)$
 ${0}$ (4)
 > $\mathrm{Slope}\left(3x-4\right)$
 ${3}$ (5)
 > $\mathrm{Slope}\left(mx+b,x\right)$
 ${m}$ (6)
 > $\mathrm{Slope}\left(\mathrm{sin},0,\frac{\mathrm{Pi}}{2}\right)$
 $\frac{{2}}{{\mathrm{\pi }}}$ (7)
 > $\mathrm{Slope}\left({x}^{2}+2x-3,-1,4\right)$
 ${5}$ (8)
 > $\mathrm{Slope}\left(a{x}^{2}+bx+c,0,1,x\right)$
 ${a}{+}{b}$ (9)