Forum archive 2000-2006

Michael Gage - more complicated drawing example

Michael Gage - more complicated drawing example

by Arnold Pizer -
Number of replies: 0
inactiveTopicmore complicated drawing example topic started 3/24/2003; 8:15:03 PM
last post 3/24/2003; 8:15:03 PM
userMichael Gage - more complicated drawing example  blueArrow
3/24/2003; 8:15:03 PM (reads: 698, responses: 0)
More complicated drawing using the Fun.pm commands. These are in the file setGeometry4SubsetsOfR2/ur_geo_4_1.pg



(1 pt) rochesterLibrary/setGeometry4SubsetsOfR2/ur_geo_4_1.pg
For each graph, determine its system of linear inequalities.
1. gage-1234-setMAAtutorialprob1image2.png
A. \left\{ \begin{array}{rcl}  y & \le & x \cr  y & \le & -1   \end{array}\right.
B. \left\{ \begin{array}{rcl}           y & \le & x  - 1 \cr           y & \ge & -1            \end{array}\right.
C. \left\{ \begin{array}{rcl}           x & \le & y  + 1 \cr           y & \ge & -1            \end{array}\right.
D. \left\{ \begin{array}{rcl}           y & \le & x  - 1 \cr           x & \ge & -1            \end{array}\right.
E. \left\{ \begin{array}{rcl}  y & \le & - x  + 1 \cr  y & \le & -1   \end{array}\right.
F. None of the above
2. gage-1234-setMAAtutorialprob1image1.png
A. \left\{ \begin{array}{rcl}              y & \ge & 2 x \cr              x & \le & 4 y               \end{array}\right.
B. \left\{ \begin{array}{rcl}           y & \le & 2 x \cr           x & \ge & 0            \end{array}\right.
C. \left\{ \begin{array}{rcl}  y & \ge & 2 x \cr  x & \ge & 4 y   \end{array}\right.
D. \left\{ \begin{array}{rcl}  y & \ge & 4 x \cr  x & \ge & 2 y   \end{array}\right.
E. \left\{ \begin{array}{rcl}           y & \le & 2 x \cr           x & \le & 4 y            \end{array}\right.
F. None of the above

 

 


WARNINGS
µ¦å{h­
##DESCRIPTION
##KEYWORDS('')
##
##ENDDESCRIPTION

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

loadMacros(
"PG.pl",
"PGbasicmacros.pl",
"PGchoicemacros.pl",
"PGanswermacros.pl",
"PGgraphmacros.pl"
);

TEXT(beginproblem());
$showPartialCorrectAnswers = 1;

$a = random(2,5,1);
$b = random(2,5,1);
while ($a == $b) {$b = random(2,5,1);}

$graph1 = init_graph(-3,-3,6,6, 'axes'=>[0,0],'grid'=>[9,9]);

$f3 = FEQ("x/($a) for x in <0,6> using color:black and weight:2");
$f4 = FEQ("$b * x for x in <0,6> using color:black and weight:2");

($f3Ref,$f4Ref) = plot_functions($graph1,$f3,$f4);

$mc1 = new_multiple_choice();

$graph1->fillRegion([1,1,'yellow']);

$mc1->qa(image(insertGraph($graph1),height=>200,width=>200),
"\( \left\{ \begin{array}{rcl}
y & \le & $b x \cr
x & \le & $a y
\end{array}\right. \)
");

$mc1->extra("\( \left\{ \begin{array}{rcl}
y & \ge & $b x \cr
x & \le & $a y
\end{array}\right. \)
",
"\( \left\{ \begin{array}{rcl}
y & \ge & $b x \cr
x & \ge & $a y
\end{array}\right. \)
",
"\( \left\{ \begin{array}{rcl}
y & \le & $b x \cr
x & \ge & 0
\end{array}\right. \)
",
"\( \left\{ \begin{array}{rcl}
y & \ge & $a x \cr
x & \ge & $b y
\end{array}\right. \)
");

$mc1->makeLast('None of the above');


$c = non_zero_random(-2,2,1);

$graph2 = init_graph(-3,-3,6,6, 'axes'=>[0,0],'grid'=>[9,9]);

$k3 = FEQ("$c for x in <0,6> using color:black and weight:2");
$k4 = FEQ("x+$c for x in <0,6> using color:black and weight:2");

($k3Ref,$k4Ref) = plot_functions($graph2,$k3,$k4);

$fill_point_y = $c + 0.5;

$graph2->fillRegion([1,$fill_point_y,'yellow']);

$mc2 = new_multiple_choice();

$mc2->qa(image(insertGraph($graph2),height=>200,width=>200),
"\( \left\{ \begin{array}{rcl}
y & \le & x + $c \cr
y & \ge & $c
\end{array}\right. \)
");

$mc2->extra("\( \left\{ \begin{array}{rcl}
x & \le & y - $c \cr
y & \ge & $c
\end{array}\right. \)
",
"\( \left\{ \begin{array}{rcl}
y & \le & x \cr
y & \le & $c
\end{array}\right. \)
",
"\( \left\{ \begin{array}{rcl}
y & \le & x + $c \cr
x & \ge & $c
\end{array}\right. \)
",
"\( \left\{ \begin{array}{rcl}
y & \le & - x - $c \cr
y & \le & $c
\end{array}\right. \)
");

$mc2->makeLast('None of the above');

BEGIN_TEXT

For each graph, determine its system of linear inequalities. $BR

1.

\{ $mc2->print_q() \}
\{ $mc2->print_a() \}

END_TEXT

ANS(radio_cmp($mc2->correct_ans));

BEGIN_TEXT

2.

\{ $mc1->print_q() \}
\{ $mc1->print_a() \}

END_TEXT

ANS(radio_cmp($mc1->correct_ans));


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


<| Post or View Comments |>