Category: MathObject Context
|Description||Allow only entry of polynomials|
Purpose of this Macro
LimitedPolynomial context, WeBWorK will require all student answers to be (expanded) polynomials (i.e., sums of multiples of powers of x). This context allows also requiring that there be only one term with each power of x.
LimitedPolynomial context in
loadMacros( "contextLimitedPolynomial.pl", #Automatically loads MathObjects.pl );
Select the context using:
If you set the ``singlePowers flag, then only one monomial of each degree can be included in the polynomial:
There is also a strict limited context that does not allow operations even within the coefficients. Select it using:
In addition to disallowing operations within the coefficients, this context does not reduce constant operations (since they are not allowed), and sets the singlePowers flag automatically. In addition, it disables all the functions, though they can be re-enabled, if needed.