I'm using a slightly modified version of contextInequalities. I've used this version for 3 terms now and it seems to be working OK.

However, I updated the pg directory at the end of Dec or so and this term I'm getting an error. The error that is being produced seems to happen when a student accidently enters something that WeBWorK isn't expecting -- like a "?" or if they enter a variable which is not defined for the problem. Sometimes the "correct" error warning is given to the student and sometimes the page goes into "error" mode. Sometimes after one of these errors, the next problem the student moves to has the page in "error" mode. We can sometimes get the problem to reset by reloading the page, but sometimes the student has to shut down the window and then relogin in. However, the problem works just fine after this.

I am sending a copy of the "error" page with this note (it's kind of long). Note that I also tried this using the plain old version of contextInequalities and got similar results.

Thanks for your help -- rac

----------------Error follows------------------------------

18 DOCUMENT(); # This should be the first executable line in the problem.

19

20 loadMacros(

21 "PGstandard.pl",

22 "MathObjects.pl",

23 "contextInequalitiesAllowStrings.pl"

24 );

25

26 TEXT(&beginproblem);

27

28 ######################################

29 # Setup

30

31 @alphabet = ("a","m","n","r","t","x","y","z");

32 $choose = random(0,7,1);

33 $var = $alphabet[ $choose ];

34

35 $c2 = non_zero_random(2,4,1);

36 do {$m = list_random(-2,2,-3,3,-4,4,-5,5);} while ($c2**2==$m**2);

37 $a = $m/$c2;

38 do {$b = non_zero_random(-5,5,1);} while ($b>=$a || $b==-1*$a);

39 $c1 = $m + $c2*$b; #(c2x+m)(x+b)

40 $c0 = $m * $b;

41 $n = random(0,1,1);

42 $poly = nicestring([$c2,$c1,$c0],["$var^2","$var",""]);

43 @display = ("$poly < 0","$poly \le 0");

44 $na = -1*$a;

45 $nb = -1*$b;

46 @interval = ("($na,$nb)","[$na,$nb]");

47

48 ######################################

49 # Main text

50

51 BEGIN_TEXT

52 Solve the quadratic inequality:

53 \[ $display[$n] \]

54 $BR $BR

55 Answer: \{ans_rule(35) \}

56 END_TEXT

57

58 ######################################

59 # Answers

60

61 Context("Inequalities-AllowStrings");

62 Context()->strings->add("No solution"=>{});

63 Context()->variables->are($var=>'Real');

64

65 $answer = "$interval[$n]";

66 ANS(Compute($answer)->cmp);

67

68 $showPartialCorrectAnswers = 1;

69

70 ######################################

71

72 ENDDOCUMENT(); # This should be the last executable line in the problem.;