Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ $tf->rf_print_q(~~&pop_up_list_print_q);

# What should the pop-up list contain, and what string should it
# submit for an answer when selected?
# These are specified in the statment below.
# These are specified in the statement below.
# To enter T as an answer choose the list element "True"
# To enter F as an answer choose the list element "False"
# The first choice is a blank to make the students do SOMETHING!!!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ $tf->rf_print_q(~~&pop_up_list_print_q);

# What should the pop-up list contain, and what string should it
# submit for an answer when selected?
# These are specified in the statment below.
# These are specified in the statement below.
# To enter T as an answer choose the list element "True"
# To enter F as an answer choose the list element "False"
# The first choice is a blank to make the students do SOMETHING!!!
Expand Down
11 changes: 5 additions & 6 deletions OpenProblemLibrary/ASU-topics/setRateChange/s1_1_5.pg
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,16 @@ BEGIN_TEXT
If a ball is thrown straight up into the air with an initial
velocity of \( $v0 \) ft/s, its height in feet after \( t \)
second is given by \( y = {$v0}t - 16t^2 \). Find the average
velocity (include units, \{ AnswerFormatHelp("units") \}) for the time period begining when \( t = $t0 \) seconds and lasting
$PAR
velocity (include units, \{ AnswerFormatHelp("units") \}) for the time period beginning when \( t = $t0 \) seconds and lasting
$PAR
(i) \( 0.5 \) seconds $BR
Average velocity:\{ans_rule(35) \}
Average velocity:\{ans_rule(35) \}
$PAR
(ii) \( 0.1 \) seconds $BR
Average velocity:\{ans_rule(35) \}
Average velocity:\{ans_rule(35) \}
$PAR
(iii) \( 0.01 \) seconds $BR
Average velocity: \{ans_rule(35) \}
Average velocity: \{ans_rule(35) \}
$BR $BR
Finally based on the above results, guess what the instantaneous
velocity of the ball is when \( t =$t0 \). $BR
Expand All @@ -63,4 +63,3 @@ $ans4 = NumberWithUnits("$v0-32*$t0 ft/s");
ANS($ans4->cmp);

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

4 changes: 2 additions & 2 deletions OpenProblemLibrary/ASU-topics/setStat/kolossa54.pg
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ $mc -> extra($ans[1-$tag]);

BEGIN_TEXT
According to a recent marketing campaign, \($n\) drinkers of either Diet Coke or Diet Pepsi participated in a
blind taste test to see which of the drinks was their favorite. In one Pepsi television commercial, an
anouncer states that "in recent blind taste tests, more than one half
blind taste test to see which of the drinks was their favorite. In one Pepsi television commercial, an
announcer states that "in recent blind taste tests, more than one half
of the surveyed preferred Diet Pepsi over Diet Coke." Suppose that out of those \($n\), \($n1\)
preferred Diet Pepsi. Test the hypothesis, using \(\alpha = $a\) that more than half of all participants will select Diet Pepsi
in a blind taste test by giving the following: $BR
Expand Down
38 changes: 19 additions & 19 deletions OpenProblemLibrary/AlfredUniv/diffeq/separablePDE/separate3.pg
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ $multiansEqual = MultiAnswer($Xequal,$Tequal,$uequal)->with(
my $T1 = $Tstu->substitute(C=>1,D=>0);
my $T2 = $Tstu->substitute(C=>0,D=>1);
my $Tscore = 1;
# check diff. eq.
# check diff. eq.
if (!($T1->D('t','t')==Formula(0))){ $Tscore = 0; }
if (!($T2->D('t','t')==Formula(0))){ $Tscore = 0; }
# check wronskiian
Expand Down Expand Up @@ -107,8 +107,8 @@ $multiansLess = MultiAnswer($Xless,$Tless,$uless)->with(
my $X2 = $Xstu->substitute(A=>0,B=>1);
my $Xscore = 1; #optimistic!
# check diff. eq. for X
my $dX1 = $X1->D('x');
my $dX2 = $X2->D('x');
my $dX1 = $X1->D('x');
my $dX2 = $X2->D('x');
my $ddX1 = $dX1->D('x');
my $ddX2 = $dX2->D('x');
if ( !($ddX1 == $w**2*$X1)){ $Xscore = 0; }
Expand All @@ -123,9 +123,9 @@ $multiansLess = MultiAnswer($Xless,$Tless,$uless)->with(
my $T1 = $Tstu->substitute(C=>1,D=>0);
my $T2 = $Tstu->substitute(C=>0,D=>1);
my $Tscore = 1;
# check diff. eq.
my $dT1 = $T1->D('t');
my $dT2 = $T2->D('t');
# check diff. eq.
my $dT1 = $T1->D('t');
my $dT2 = $T2->D('t');
my $ddT1 = $dT1->D('t');
my $ddT2 = $dT2->D('t');
if ( !($ddT1 == $k**2*$w**2*$T1)){ $Tscore = 0; }
Expand Down Expand Up @@ -157,8 +157,8 @@ $multiansGreater = MultiAnswer($Xgreater,$Tgreater,$ugreater)->with(
my $X2 = $Xstu->substitute(A=>0,B=>1);
my $Xscore = 1; #optimistic!
# check diff. eq. for X
my $dX1 = $X1->D('x');
my $dX2 = $X2->D('x');
my $dX1 = $X1->D('x');
my $dX2 = $X2->D('x');
my $ddX1 = $dX1->D('x');
my $ddX2 = $dX2->D('x');
if ( !($ddX1 == -$w**2*$X1)){ $Xscore = 0; }
Expand All @@ -173,9 +173,9 @@ $multiansGreater = MultiAnswer($Xgreater,$Tgreater,$ugreater)->with(
my $T1 = $Tstu->substitute(C=>1,D=>0);
my $T2 = $Tstu->substitute(C=>0,D=>1);
my $Tscore = 1;
# check diff. eq.
my $dT1 = $T1->D('t');
my $dT2 = $T2->D('t');
# check diff. eq.
my $dT1 = $T1->D('t');
my $dT2 = $T2->D('t');
my $ddT1 = $dT1->D('t');
my $ddT2 = $dT2->D('t');
if ( !($ddT1 == -$k**2*$w**2*$T1)){ $Tscore = 0; }
Expand All @@ -198,27 +198,27 @@ Context()->texStrings;
BEGIN_TEXT
$PAR
The PDE \[k^2\frac{\partial^2 u}{\partial x^2}=\frac{\partial^2 u}{\partial t^2}\]
is separable, so we'll look for solutions of the form
\[u(x,t) = X(x)T(t).\]
is separable, so we'll look for solutions of the form
\[u(x,t) = X(x)T(t).\]
This leads us to a Sturm-Liouville problem.
$PAR Plug the formula for \(u\) into the PDE, then separate the variables.
$PAR Plug the formula for \(u\) into the PDE, then separate the variables.
$BR $BBOLD Note: $EBOLD In your answer, put all the \(X\)'s on the left answer blank. Put all the \(T\)'s and the constant \(k\) in the right answer blank. Use the prime notation for derivatives, so the derivative of \(X\) is written as \(X^\prime\). Do NOT use \(X^\prime(x)\)
$BR The result is
$BR The result is
$BR
\{ans_rule\} = \{ans_rule\} = \(-L\)
$BR
where \(L\) is a constant.
$BR
$PAR
This separates into two independent ordinary differential equations, which can be solved separately
This separates into two independent ordinary differential equations, which can be solved separately
$BR
DE in X: \{ans_rule\} \( = 0\)
$BR
DE in T: \{ans_rule\} \( = 0\)
$PAR

$PAR Find the general solutions for the these these ODEs, and use them to find the solution \(u(x,t)\). $BR Use \(A\) and \(B\) for arbitrary constants in the general solution for \(X\).
$BR Use \(C\) and \(D\) for arbitary constants in the general solution for \(T\).
$BR Use \(C\) and \(D\) for arbitrary constants in the general solution for \(T\).
$BR There are three cases:
$BR
$BBOLD Case 1: $EBOLD \(L = 0\)
Expand All @@ -229,7 +229,7 @@ $BR
$BR
\(u = \) \{$multiansEqual->ans_rule(60)\}
$BR
$BBOLD Case 2: $EBOLD \(L = -w^2\) where \(w\) is some positive number.
$BBOLD Case 2: $EBOLD \(L = -w^2\) where \(w\) is some positive number.
$BR
\(X(x) = \) \{$multiansLess->ans_rule(40)\} (A,B are constants.)
$BR
Expand Down
18 changes: 9 additions & 9 deletions OpenProblemLibrary/LoyolaChicago/Precalc/Chap1Sec3/Q24.pg
Original file line number Diff line number Diff line change
Expand Up @@ -64,24 +64,24 @@ $extra = 1000;
$more_units = $extra*$m;

$checkbox_mc = new_checkbox_multiple_choice();
$checkbox_mc -> qa('Which of the following statements CORRECTLY explains the
meaning of the slope? (select all as there may be more
than one correct statment)',
'If the company spends an additional ${DOLLAR}$extra on advertising, it
will increases the number of units it sells by $more_units .',
'In order to sell one more unit, the company would need to increase the
$checkbox_mc -> qa('Which of the following statements CORRECTLY explains the
meaning of the slope? (select all as there may be more
than one correct statement)',
'If the company spends an additional ${DOLLAR}$extra on advertising, it
will increases the number of units it sells by $more_units .',
'In order to sell one more unit, the company would need to increase the
amount it spends on advertising by ${DOLLAR}$n .');

$checkbox_mc -> extra('If the company spends an additional ${DOLLAR}$m on
$checkbox_mc -> extra('If the company spends an additional ${DOLLAR}$m on
advertising, it will sell one more additional unit.',
'If the company increases the amount of money it spends on advertising
'If the company increases the amount of money it spends on advertising
by ${DOLLAR}$b, it will double the number of units it sells.');

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

BEGIN_TEXT

A company finds that there is a linear relationship between the amount of money that it spends on advertising and the number of units it sells. If it spends no money on advertising it sells $b units. For each additional ${DOLLAR}$dx spent, an additional $dy units are sold.
A company finds that there is a linear relationship between the amount of money that it spends on advertising and the number of units it sells. If it spends no money on advertising it sells $b units. For each additional ${DOLLAR}$dx spent, an additional $dy units are sold.
$PAR
a) If \(x\) is the amount of money that the company spends on advertising, find a formula for \(y\), the number of units sold as a function of \(x\). (Do not use commas in your formula.)
$BR
Expand Down
2 changes: 1 addition & 1 deletion OpenProblemLibrary/LoyolaChicago/Precalc/Chap1Sec4/Q42.pg
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ a) Find a formula for the velocity of the bottle as a function of the time since
$BR
\( v = \) \{ ans_rule(30) \}
$PAR
b) For each feature of the graph listed below, match one of the statments A-G which best explains its practical meaning.
b) For each feature of the graph listed below, match one of the statements A-G which best explains its practical meaning.
\{ $ml -> print_q \}
\{$ml -> print_a \}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

########################################################################

DOCUMENT();
DOCUMENT();

loadMacros(
"PGstandard.pl",
Expand Down Expand Up @@ -92,7 +92,7 @@ $popup[$r[0]] = PopUp(["Choose Property?", "$IPA", "$IPM", "$CPA", "$CPM", "$APA
Context()->texStrings;

BEGIN_TEXT
Identify the appropriate property demonstrated in the following statments:
Identify the appropriate property demonstrated in the following statements:
$PAR
$BCENTER

Expand Down Expand Up @@ -126,4 +126,4 @@ ANS( $popup[3]->cmp() );
ANS( $popup[4]->cmp() );
ANS( $popup[5]->cmp() );

ENDDOCUMENT();
ENDDOCUMENT();
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

########################################################################

DOCUMENT();
DOCUMENT();

loadMacros(
"PGstandard.pl",
Expand Down Expand Up @@ -108,32 +108,32 @@ $popup2[$r[0]] = PopUp(["?", "$op1", "$op2", "$op3"], $op2);
Context()->texStrings;

BEGIN_TEXT
Identify the appropriate property demonstrated in the following statments:
Identify the appropriate property demonstrated in the following statements:
$PAR

1. $exp1[0] \{ $popup2[0]->menu() \} $exp2[0]
$BR
\{ $popup1[0]->menu() \}
\{ $popup1[0]->menu() \}
$PAR
2. $exp1[1] \{ $popup2[1]->menu() \} $exp2[1]
$BR
\{ $popup1[1]->menu() \}
\{ $popup1[1]->menu() \}
$PAR
3. $exp1[2] \{ $popup2[2]->menu() \} $exp2[2]
$BR
\{ $popup1[2]->menu() \}
\{ $popup1[2]->menu() \}
$PAR
4. $exp1[3] \{ $popup2[3]->menu() \} $exp2[3]
$BR
\{ $popup1[3]->menu() \}
\{ $popup1[3]->menu() \}
$PAR
5. $exp1[4] \{ $popup2[4]->menu() \} $exp2[4]
$BR
\{ $popup1[4]->menu() \}
\{ $popup1[4]->menu() \}
$PAR
6. $exp1[5] \{ $popup2[5]->menu() \} $exp2[5]
$BR
\{ $popup1[5]->menu() \}
\{ $popup1[5]->menu() \}

END_TEXT
Context()->normalStrings;
Expand All @@ -157,4 +157,4 @@ ANS( $popup1[4]->cmp() );
ANS( $popup2[5]->cmp() );
ANS( $popup1[5]->cmp() );

ENDDOCUMENT();
ENDDOCUMENT();
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# Location: Northern Arizona University
# Course:Quantitative Reasoning

DOCUMENT();
DOCUMENT();
loadMacros(
"PGstandard.pl",
"PGcourse.pl"
Expand All @@ -25,7 +25,7 @@ loadMacros(
TEXT( beginproblem ( ) );
$showPartialCorrectAnswers = 1;

$total1 = random( 1000, 10000, 1 );
$total1 = random( 1000, 10000, 1 );

$rate = random( 3, 10, .1 );

Expand All @@ -40,7 +40,7 @@ $ans1 = $total1 * ( 1 + $rate/100 ) ** $n1;
do{ $total2 = random( 1000000, 25000000, 1 );
} until( $total2 > $ans1 );

$n2 = ln( $total2 / $total1 ) / ln( 1 + $rate / 100 );
$n2 = ln( $total2 / $total1 ) / ln( 1 + $rate / 100 );
$ans2 = $year1 + int( $n2 );

if( $total1 < 10 ** 6 ){ $th1 = int( $total1 / 1000 );
Expand All @@ -64,7 +64,7 @@ if( $total2 < 10 ** 9 ){ $m = int( $total2 / 10 ** 6 );

BEGIN_TEXT

A city had a population of $pop1 at the begining of $year1 and has been growing at
A city had a population of $pop1 at the beginning of $year1 and has been growing at
$rate$PERCENT per year since then.$PAR
(a) Find the size of the city at the beginning of $year2.
$BR
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,14 @@ $showPartialCorrectAnswers = 1;
# Make a new select list

$tf = new_match_list();
# $tf now "contains" the select list object.
# $tf now "contains" the select list object.


# use pop-up list instead of an answer rule.


# What should the pop-up list say, and what should it submit for an answer when selected?
# These are specified in the statment below.
# These are specified in the statement below.
# To enter T as an answer choose the list element "True"
# To enter F as an answer choose the list element "False"
# The first choice is a blank to make the students do SOMETHING!!!
Expand All @@ -72,10 +72,10 @@ $tf ->choose(3);
BEGIN_TEXT

$BR
Match the following equations with their direction field.
Match the following equations with their direction field.
Clicking on each picture will give you an
enlarged view. While you can probably solve this problem by guessing, it is useful
to try to predict characteristics of the direction field and then match them to the picture.
to try to predict characteristics of the direction field and then match them to the picture.
Here are some handy characteristics to start with -- you will develop more as you practice.
$BR
\{OL(
Expand All @@ -87,16 +87,16 @@ $BR
constant. These are called isoclines, and can be used to construct the direction field picture
by hand."
)\}
$BR Go to
$BR Go to
\{htmlLink(alias("${htmlDirectory}phaseplaneplotters/index.html"), " this page ")\}
to launch the phase plane plotter to check your answers.
(Choose the "integral curves utility" from the applet menu, enter \(dx/dt=1\) to identify the variables
\(x\) and \(t\) and then enter the function you want for \(dy/dx = dy/dt = \ldots \) ).
$BR
$BR
\{ $tf->print_q \}
$BR
\{ imageRow( $tf->{selected_a}, ["A","B", "C"], height => 200, width => 200, tex_size=> 300 ) \}


END_TEXT

Expand All @@ -105,9 +105,8 @@ ANS(str_cmp( $tf->ra_correct_ans ) ) ;



#########################################################
#########################################################



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

Loading