PointsInAnswers: Difference between revisions
No edit summary |
No edit summary |
||
(3 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
{{historical}} | |||
<p style="font-size: 120%;font-weight:bold">This problem has been replaced with [https://openwebwork.github.io/pg-docs/sample-problems/Algebra/PointAnswers.html a newer version of this problem]</p> | |||
<h2>Points in Student Answers</h2> | <h2>Points in Student Answers</h2> | ||
Line 107: | Line 112: | ||
<b>Answer Evaluation:</b> | <b>Answer Evaluation:</b> | ||
We can control the hints students receive using <code>cmp(showDimensionHints=>1, showCoordinateHints=>1)</code>. | We can control the hints students receive using <code>cmp(showDimensionHints=>1, showCoordinateHints=>1)</code>. | ||
For all options, see "Flags for Point()->cmp" on [http://webwork.maa.org/ | For all options, see "Flags for Point()->cmp" on [http://webwork.maa.org/pod/pg/doc/MathObjects/MathObjectsAnswerCheckers.html MathObjectsAnswerCheckers.html] | ||
</p> | </p> | ||
</td> | </td> | ||
Line 124: | Line 129: | ||
<ul> | <ul> | ||
<li>POD documentation: [http://webwork.maa.org/ | <li>POD documentation: [http://webwork.maa.org/pod/pg/macros/contextLimitedPoint.pl.html contextLimitedPoint.pl.html]</li> | ||
<li>PG macro: [http:// | <li>PG macro: [http://webwork.maa.org/viewvc/system/trunk/pg/macros/contextLimitedPoint.pl?view=log contextLimitedPoint.pl]</li> | ||
<li>[http://webwork.maa.org/wiki/Specialized_contexts Specialized_contexts]</li> | <li>[http://webwork.maa.org/wiki/Specialized_contexts Specialized_contexts]</li> | ||
</ul> | </ul> | ||
Line 132: | Line 137: | ||
<ul> | <ul> | ||
<li>POD documentation: [http://webwork.maa.org/ | <li>POD documentation: [http://webwork.maa.org/pod/pg/doc/MathObjects/MathObjectsAnswerCheckers.html MathObjectsAnswerCheckers.html]</li> | ||
</ul> | </ul> |
Latest revision as of 16:14, 16 July 2023
This problem has been replaced with a newer version of this problem
Points in Student Answers
This PG code shows how to check student answers that are points.
PG problem file | Explanation |
---|---|
DOCUMENT(); loadMacros( "PGstandard.pl", "contextLimitedPoint.pl", "PGcourse.pl", ); TEXT(beginproblem()); |
Initialization:
We load the Alternatively, instead of loading |
Context("LimitedPoint"); $f = Formula("2-x"); $xint = Point("(2,0)"); $yint = Point("(0,2)"); |
Setup:
Everything is as usual. The
Alternatively, if we had loaded |
Context()->texStrings; BEGIN_TEXT If \( y = f(x) = $f \), find the x- and y-intercepts. Enter your answers as points \( (a,b) \) that include parentheses. $BR x-intercept: \{ ans_rule(15) \} $BR y-intercept: \{ ans_rule(15) \} END_TEXT Context()->normalStrings; |
Main Text: The main text section of the file is as we'd expect. |
ANS( $xint->cmp() ); ANS( $yint->cmp() ); ENDDOCUMENT(); |
Answer Evaluation:
We can control the hints students receive using |
- POD documentation: contextLimitedPoint.pl.html
- PG macro: contextLimitedPoint.pl
- Specialized_contexts
- POD documentation: MathObjectsAnswerCheckers.html