[system] Repository:
ViewVC logotype

Revision 3257

Jump to revision: Previous Next
Author: dpvc
Date: Thu Jun 2 22:50:24 2005 UTC (14 years, 7 months ago)
Log Message:
Modified the Formula answer checker to allow checking of points where
the functions are undefined (i.e., attempt to check that the domains
agree).  This can be enabled by setting the checkundefinedPoints flag
in the Context(), or in the formula itself.  Test points where the
function is undefined will be retained and the student's answer will
have to be undefined at the same points.  If the points are selected
at random, the points where the function is undefined are kept in
addition to the ones where it is defined, so the required number of
test points where the function IS defined will still need to be
found.  The number of undefined points can be up to the number of
defined points.  This number can be reduced by setting the
max_undefined flag.  If you want to guarantee that a specific
undefined point be tested, you can provide that point using the
test_points field of the formula.  For example:

     $f = Formula("(x^2-1)/(x-1)");
     $f->{test_points} = [[-1],[0],[1],[2]];

will guarantee that the singularity at x=1 is tested, so the answer
x+1 will not be marked as correct.

If an answer matches at all the test points where the functions are
both defined, but some of the undefind points differ between the two
functions, the answer checker will generate an error message
indicating that the domains of the functions don't agree.  (This is
ONLY generated with the functions match except for that.)  This can be
controlled by setting the showDomainErrors flag in the formula's cmp()


The default is to show these errors.

Changed paths:

Path Details
Directorytrunk/pg/lib/Value/AnswerChecker.pm modified , text changed
Directorytrunk/pg/lib/Value/Formula.pm modified , text changed

aubreyja at gmail dot com
ViewVC Help
Powered by ViewVC 1.0.9