Assessment Comparison Methods

The question and assessment framework provides many distinct methods for determining equivalence between submitted answers and the values in an answer key. Depending on the chosen method, comparisons are based on either pattern matching with custom transformations or by comparing specific distance measurements to a tolerance. Comparison methods also determine the default interface type when an assessment function is used in a question object.

Question Framework

AssessmentFunction assessment containing a comparison method and answer key

QuestionObject question with an interface and assessment

Tolerance  ▪  DistanceFunction

Distance-Based Comparisons

"Number" compare based on numeric difference

"String" compare literal strings

"Color" compare based on color distance

"Date" compare based on date difference

"GeoPosition" compare based on geographic distance

"Quantity" compare physical quantities

"Vector" compare vectors based on Euclidean distance

Pattern-Based Comparisons

"Expression" compare by pattern-matching expressions

"HeldExpression" match unevaluated Wolfram Language expressions

"CodeEquivalence" match unevaluated Wolfram Language code

Mathematical Comparisons

"ArithmeticResult" match while only allowing reordering of terms

"PolynomialResult" compare polynomials without expansion or factoring

"CalculusResult" determine equality of answer to a calculus question

"AlgebraicValue" check the answer to an algebraic solving question

"Number" compute the difference of numeric values

"Vector" compare vectors based on Euclidean distance