#DESCRIPTION # Calculation of integrals using power series. #ENDDESCRIPTION #KEYWORDS('Taylor Series' , 'Integrals' ) ## tsch tagged and PAID on 3-22-2004 ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('37') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "PG.pl", "PGbasicmacros.pl", "PGchoicemacros.pl", "PGanswermacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; $a = random(0.6,0.8,0.01); $c = random(2,8,1); BEGIN_TEXT Assume that \( \sin(x) \) equals its Maclaurin series for all x. $BR Use the Maclaurin series for \( \sin($c x^2) \) to evaluate the integral \[ \int_0^{$a} \sin($c x^2) \ dx \]. Your answer will be an infinite series. Use the first two terms to estimate its value. \{ans_rule(40)\} END_TEXT $soln1 = "$c * x^3 / 3 - $c^3 * x^7 / 42"; $soln2 = $c * $a**3 / 3 - $c**3 * $a**7 / 42; ANS(num_cmp($soln2, relTol=>1E-7)); ENDDOCUMENT(); # This should be the last executable line in the problem. ________________________________________________________________________________#DESCRIPTION # Calculation of integrals using power series. #ENDDESCRIPTION #KEYWORDS('Taylor Series' , 'Integrals' ) ## tsch tagged and PAID on 3-22-2004 ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('40') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "PG.pl", "PGbasicmacros.pl", "PGchoicemacros.pl", "PGanswermacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; $a = random(0.1,0.2,0.01); $b = non_zero_random(2,5,1); BEGIN_TEXT Assume that \( e^x \) equals its Maclaurin series for all x. $BR Use the Maclaurin series for \( e^{-$b x^4} \) to evaluate the integral \[ \int_0^{$a} e^{-$b x^4} \ dx \] Your answer will be an infinite series. Use the first two terms to estimate its value. \{ans_rule(40)\} END_TEXT $soln1 = "x - $b * x**5 / 5"; $soln2 = $a - $b * $a**5 / 5; ANS(num_cmp($soln2, relTol=>1E-7)); ENDDOCUMENT(); # This should be the last executable line in the problem. ________________________________________________________________________________ #DESCRIPTION #Representation of function as a power series #ENDDESCRIPTION #KEYWORDS('Power Series' ) ## tsch tagged and PAID on 3-22-2004 ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('21') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "PG.pl", "PGbasicmacros.pl", "PGchoicemacros.pl", "PGanswermacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; $a = random(2,10,1); $b = random(2,10,1); $c = random(3,8,1); $b1 = 1/($b); BEGIN_TEXT Find the Maclaurin series of the function \( f(x) = $a \cos ($b x^2) \)$BR \( (f(x) = \displaystyle \sum_{n=0}^\infty c_n x^n ) \) $BR \( c_0 = \) \{ans_rule(20)\} $BR \( c_2 = \) \{ans_rule(20)\} $BR \( c_4 = \) \{ans_rule(20)\} $BR \( c_6 = \) \{ans_rule(20)\} $BR \( c_8 = \) \{ans_rule(20)\} $BR END_TEXT $ans0 = $a ; $ans1 = 0 ; $ans2 = -($a * $b * $b) / 2 ; $ans3 = 0 ; $ans4 = ($a * ($b ** 4)) / 24 ; ANS(num_cmp($ans0)); ANS(num_cmp($ans1)); ANS(num_cmp($ans2)); ANS(num_cmp($ans3)); ANS(num_cmp($ans4)); ENDDOCUMENT(); # This should be the last executable line in the problem. ________________________________________________________________________________ #DESCRIPTION #Taylor_series #ENDDESCRIPTION #KEYWORDS('Taylor Series') ## tsch tagged and PAID on 3-22-2004 ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('55 53 54') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "PG.pl", "PGbasicmacros.pl", "PGchoicemacros.pl", "PGanswermacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 0; $a = random(2,11,1); $b = random(2,11,1); $a1 =2*($a); $questStr1 = EV2( " \( \displaystyle \sum_{n=0}^\infty (-1)^n \frac{x^{2n+1}}{(2n+1)!} \) " ); $ansStr1 =EV2( " \( \sin(x) \) " ); $questStr2 = EV2( " \( \displaystyle \sum_{n=0}^\infty \frac{x^n}{n!} \) " ); $ansStr2 =EV2( " \( e^x \) " ); $questStr3 = EV2( " \( \displaystyle \sum_{n=0}^\infty \frac{(-1)^n x^{2n}}{(2n)!} \) " ); $ansStr3 =EV2( " \( \cos(x) \) " ); $questStr4 = EV2( " \( \displaystyle \sum_{n=0}^\infty \frac{(-1)^n x^{2n+1}}{2n+1} \) " ); $ansStr4 =EV2( " \( \arctan(x) \) " ); @questions =( $questStr1,$questStr2,$questStr3,$questStr4); @answers =( $ansStr1,$ansStr2,$ansStr3,$ansStr4); # Now randomize the questions: @slice = &NchooseK(4,4); @shuffle = &shuffle(scalar(@slice)); TEXT(EV2(<["remove_whitespace","ignore_case"])); ##the correct answers are obtained by applying ##the inverse (adjoint) permutation to the captions. ENDDOCUMENT(); # This should be the last executable line in the problem. ________________________________________________________________________________ #KEYWORDS('Power Series', 'Taylor Series' ) ##DESCRIPTION ##Representation of function as a Taylor series ##ENDDESCRIPTION ## Shotwell cleaned ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('6') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "PGbasicmacros.pl", "PGanswermacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; BEGIN_TEXT The Taylor series for \( f(x) = \ln(\sec(x)) \) at \( a = 0 \) is \( \sum_{n=0}^\infty c_n\, x^n. \) $BR$BR Find the following coefficients. $BR \( c_0 = \) \{ans_rule(20)\} $BR \( c_1 = \) \{ans_rule(20)\} $BR \( c_2 = \) \{ans_rule(20)\} $BR \( c_3 = \) \{ans_rule(20)\} $BR \( c_4 = \) \{ans_rule(20)\} $BR END_TEXT ANS(num_cmp(0 ) ); ANS(num_cmp(0 ) ); ANS(num_cmp(.5 ) ); ANS(num_cmp(0 ) ); ANS(num_cmp("1/12" ) ); ENDDOCUMENT(); # This should be the last executable line in the problem. ________________________________________________________________________________ ##KEYWORDS('Power Series' ) ##DESCRIPTION ##Representation of function as a power series ##ENDDESCRIPTION ## Shotwell cleaned ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('10') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "PGbasicmacros.pl", "PGanswermacros.pl", ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; $a = non_zero_random(-4,4); BEGIN_TEXT The Taylor series for \(f(x) = x^3\) at \(a=$a\) is \(\sum_{n=0}^\infty c_n( x- $a )^n. \) $BR$BR Find the first few coefficients. $BR \( c_0 = \) \{ans_rule(20)\} $BR \( c_1 = \) \{ans_rule(20)\} $BR \( c_2 = \) \{ans_rule(20)\} $BR \( c_3 = \) \{ans_rule(20)\} $BR \( c_4 = \) \{ans_rule(20)\} END_TEXT ANS(num_cmp( "$a^3" ) ); ANS(num_cmp( "3*($a)^2" ) ); ANS(num_cmp( "3*$a" ) ); ANS(num_cmp( 1 ) ); ANS(num_cmp( 0 ) ); ENDDOCUMENT(); # This should be the last executable line in the problem. ________________________________________________________________________________ ##KEYWORDS('Power Series', 'Taylor Series') ##DESCRIPTION ## Determine coefficients in a Taylor series representation ##ENDDESCRIPTION ## Shotwell cleaned ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('12') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "extraAnswerEvaluators.pl", "PGbasicmacros.pl", "PGanswermacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; $a = random(1,10,1); $b = random(2,10,1); $c = random(3,8,1); $b1 = 1/$b; BEGIN_TEXT The Taylor series of function \( f(x)=\ln(x) \) at \( a = $b \) is given by: \[ f(x) =\sum_{n=0}^\infty c_n (x- $b)^n \] $BR Find the following coefficients: $BR \( c_0 = \) \{ans_rule(20)\} $BR \( c_1 = \) \{ans_rule(20)\} $BR \( c_2 = \) \{ans_rule(20)\} $BR \( c_3 = \) \{ans_rule(20)\} $BR \( c_4 = \) \{ans_rule(20)\} $BR$BR END_TEXT $ans0 = "ln($b)" ; $ans1 = $b1 ; $ans2 = "-($b1^2)/2"; $ans3 = "($b1^3)/3"; $ans4 = "-($b1^4)/4"; ANS(num_cmp($ans0) ); ANS(num_cmp($ans1) ); ANS(num_cmp($ans2) ); ANS(num_cmp($ans3) ); ANS(num_cmp($ans4) ); ENDDOCUMENT(); # This should be the last executable line in the problem. ________________________________________________________________________________ ##KEYWORDS('Power Series' ) ##DESCRIPTION ##Representation of function as a power series ##ENDDESCRIPTION ## Shotwell cleaned ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('14') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "extraAnswerEvaluators.pl", "PGbasicmacros.pl", "PGanswermacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; $a = random(1,9,1); $b = random(.2,.9,.1); $c = random(3,8,1); $b1 = 1/$b; BEGIN_TEXT Represent the function \( f(x) = x^{$b} \) as a power series: \[\sum_{n=0}^\infty c_n (x - $a )^n \] $BR Find the following coefficients: $BR \( c_0 = \) \{ans_rule(35)\} $BR \( c_1 = \) \{ans_rule(35)\} $BR \( c_2 = \) \{ans_rule(35)\} $BR \( c_3 = \) \{ans_rule(35)\} $BR$BR END_TEXT $ans0 = "$a^$b" ; $ans1 = "$ans0 * $b / $a"; $ans2 = "$ans1 * ($b -1)/(2*$a)"; $ans3 = "$ans2 * ($b -2)/(3*$a)"; ANS(num_cmp($ans0) ); ANS(num_cmp($ans1) ); ANS(num_cmp($ans2) ); ANS(num_cmp($ans3) ); ENDDOCUMENT(); # This should be the last executable line in the problem. ________________________________________________________________________________ ##KEYWORDS('Power Series' ) ##DESCRIPTION ## Find given coefficients of power series representation ##ENDDESCRIPTION ## Shotwell cleaned ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('15') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "PGbasicmacros.pl", "PGanswermacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; BEGIN_TEXT The Taylor series for \( f(x) = \sin(x) \) at \(a= \frac{\pi}{2} \) is \( \sum_{n=0}^\infty c_n( x- \frac{\pi}{2} )^n. \) $BR$BR Find the first few coefficients. $BR \( c_0 = \) \{ans_rule(20)\} $BR \( c_1 = \) \{ans_rule(20)\} $BR \( c_2 = \) \{ans_rule(20)\} $BR \( c_3 = \) \{ans_rule(20)\} $BR \( c_4 = \) \{ans_rule(20)\} $BR END_TEXT $ans0 = 1 ; $ans1 = 0 ; $ans2 = -0.5 ; $ans3 = 0 ; $ans4 = "1 / 24" ; ANS(num_cmp($ans0 ) ); ANS(num_cmp($ans1 ) ); ANS(num_cmp($ans2 ) ); ANS(num_cmp($ans3 ) ); ANS(num_cmp($ans4 ) ); ENDDOCUMENT(); # This should be the last executable line in the problem. ________________________________________________________________________________ ##KEYWORDS('Taylor Series','cos') ##DESCRIPTION ## Evaluate limit with Taylor series expansion ##ENDDESCRIPTION ## Shotwell cleaned ## DBsubject('Calculus') ## DBchapter('Infinite Sequences and Series') ## DBsection('Taylor and Maclaurin Series') ## Date('6/3/2002') ## Author('') ## Institution('') ## TitleText1('Calculus Early Transcendentals') ## EditionText1('4') ## AuthorText1('Stewart') ## Section1('11.10') ## Problem1('45') DOCUMENT(); # This should be the first executable line in the problem. loadMacros( "PGbasicmacros.pl", "PGanswermacros.pl", "PGauxiliaryFunctions.pl" ); TEXT(beginproblem()); $showPartialCorrectAnswers = 1; $b = random(2,15,1) ; $a = "$b*3"; $c = -1/($a*3); BEGIN_TEXT Evaluate $BR \[ \lim_{x \to 0} \frac{\ln (1-x) + x + \frac{x^2}{2}}{$b x^3} \] $BR $BITALIC Hint: Use power series. $EITALIC $BR $BR Answer: \{ans_rule(30)\} END_TEXT ANS(num_cmp($c)); ENDDOCUMENT(); # This should be the last executable line in the problem.