Skip to content

Commit f723c83

Browse files
committed
Fix bug 4692
1 parent 1840bed commit f723c83

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

OpenProblemLibrary/UCSB/Stewart5_5_3/Stewart5_5_3_6.pg

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
## DBsection(Fundamental theorem of calculus)
44
## Institution(UCSB)
55
## Level(2)
6+
## MO(1)
67
## TitleText1('Calculus: Early Transcendentals')
78
## AuthorText1('Stewart')
89
## EditionText1('5')
@@ -15,15 +16,23 @@ DOCUMENT();
1516

1617
loadMacros(
1718
"PGstandard.pl",
18-
"PGchoicemacros.pl",
19+
"MathObjects.pl",
1920
"PGcourse.pl"
2021
);
2122

2223
TEXT(&beginproblem);
24+
25+
Context("Numeric");
26+
Context()->variables->set(x=>{limits=>[.1,10]});
27+
2328
$showPartialCorrectAnswers = 1;
24-
$a=random(1,10,1)*random(-1,1,2);
29+
$a=random(1,10,1);
2530
$b=random(1,10,1)*random(-1,1,2);
26-
$c=random(1,10,1)*random(-1,1,2);
31+
32+
33+
$ans = Compute("$b+sqrt(x)");
34+
35+
2736

2837
BEGIN_TEXT
2938

@@ -35,6 +44,6 @@ $PAR
3544

3645
END_TEXT
3746

38-
ANS(fun_cmp("$b+sqrt(x)", var=>["x","t"]));
47+
ANS($ans->cmp());
3948

4049
ENDDOCUMENT();

0 commit comments

Comments
 (0)