Function: math[diffquot], math[diffquotfn] - determine difference quotient
Calling Sequence:
diffquot(f, x, 'var');
diffquot(f, x=a, 'var');
diffquotfn(f, x, 'var');
diffquotfn(f, x=a, 'var');
Parameters:
f
- an algebraic expression
x
- the name of the indeterminate in f
a
- a point of type algebraic
'var'
- (optional) a name
Description:
diffquot and diffquotfn determine the difference quotient of a function f in one real. The difference quotient (ratio of change) is defined as
.
In the first form the general difference quotient is returned as a term.
In the second form, the difference quotient about a point a is determined.
By default, the null sequence h is returned as the name 'h'. By giving an optional third argument you may choose another name.
diffquotfn works as described before but returns an anonymous function.
This function is part of the math package, and so can be used only after performing the command with(math) or with(math, diffquot) or with(math, diffquotfn).
Examples:
> with(math):
> dq1 := diffquot(x^2, x);
> limit(dq1, h=0);
> dq2 := diffquot(x^2, x=1);
> subs(h=0, dq2);
> f1 := diffquotfn(sqrt(x), x=c, 'p');
> limit(f1(p), h=0);
See Also:
diff , student/slope , math/ex , math/inflection .
Version History:
Version 1.0 - December 14, 1998