[rochester] / trunk / rochester_problib / setIntegrals23Work / eva6_1.pg Repository: Repository Listing bbplugincoursesdistsnplrochestersystemwww

# View of /trunk/rochester_problib/setIntegrals23Work/eva6_1.pg

Mon Jun 25 19:20:51 2001 UTC (11 years, 11 months ago) by sam
File size: 1288 byte(s)
added problem library as webwork/ww_prob_lib with revision tag prob-lib-2

1 #DESCRIPTION
2 #  Integration
3 #  Application-based
4 #  Physics--Work.
5 #ENDDESCRIPTION
6
7 #KEYWORDS('Integration', 'Physics', 'Applications')
8
9 DOCUMENT();        # This should be the first executable line in the problem.
10
12 "PG.pl",
13 "PGbasicmacros.pl",
14 "PGchoicemacros.pl",
16 "PGauxiliaryFunctions.pl"
17 );
18
19 TEXT(&beginproblem);
20 $showPartialCorrectAnswers = 1; 21 22 #Here we ensure that the height of the tank is always greater than the depth of 23 #the water 24$c1 = random(5,12,1);
25 $c2 =$c1 ;
26 while ($c1==$c2) {
27     $c2 = random(1,11,1); 28 } 29 @cs =($c1,$c2); 30 @sortedcs = num_sort(@cs); 31$C = $sortedcs[0]; 32$A = $sortedcs[1]; 33$b = random(3,20,1) ;
34 $D = random(1450,1550,10); 35$pi = 4*arctan(1);
36
37 BEGIN_TEXT
38 A tank in the shape of an inverted right circular cone has height $$A$$ meters and
39 radius $$b$$ meters. It is filled with $$C$$ meters of hot chocolate. $BR 40 Find the work required to empty the tank by pumping the hot chocolate over the 41 top of the tank. Note: the density of hot chocolate is 42 $$\delta = D kg/m^3$$ 43$BR
44 \{ans_rule(45)\}
45 END_TEXT
46
47 $answer = 9.8*$D*$pi*($b/$A)**2*( ($A**4)/12 - .5*$A**2*($A-$C)**2 + (2/3)*$A*($A-$C)**3 -.25*($A-$C)**4)  ;