<?xml version="1.0" encoding="UTF-8"?>
<quiz>
  <question type="stack">
    <name>
      <text>10.3.33 (Differentiate hence integrate)</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<p><b>(a) </b>Differentiate \(\displaystyle{@f@}\) with respect to {@v@}.</p>
<p></p>
[[input:ans1]] [[validation:ans1]][[feedback:prt1]]<br>
<p><b>(b) </b>Hence evaluate \(\displaystyle{@'int(g,v,a,b)@}\).</p>
<p></p>
[[input:ans2]][[validation:ans2]][[feedback:prt2]] 
<p></p>
<p><br></p>]]></text>
    </questiontext>
    <generalfeedback format="html">
      <text><![CDATA[<p><b>(a) </b>\(\displaystyle\frac{d}{d{@v@}}\left({@f@}\right)={@fdash@}\).</p><p><b>(b) </b>From (a) we see that \({@g@}={@(1/c)@}\left({@fdash@}\right)\), so \({@(1/c)@}\left({@f@}\right)={@gint@}\) is an antiderivative of {@g@}. So, using the Evaluation Theorem,</p><p>\[\begin{align*}&nbsp;\int^{@b@}_{@a@}({@g@})\,d{@v@} &amp;= \left[{@gint@}\right]^{@b@}_{@a@} \\ &amp;=&nbsp; \left({@(subst(b,v,gint)),simp=false@}\right) - \left({@subst(a,v,gint),simp=false@}\right) \\&nbsp;&nbsp;&amp;=&nbsp; \left({@(simp:true,subst(b,v,gint))@}\right) - \left({@subst(a,v,gint)@}\right) \\ &amp;=&nbsp;{@(simp:true,subst(b,v,gint)-subst(a,v,gint))@}.\end{align*}\]</p>]]></text>
    </generalfeedback>
    <defaultgrade>1</defaultgrade>
    <penalty>0.1</penalty>
    <hidden>0</hidden>
    <idnumber/>
    <stackversion>
      <text>2022082900</text>
    </stackversion>
    <questionvariables>
      <text>v:t;
a:rand_with_prohib(-3,2,[0]);
b:rand_with_prohib(a+1,4,[0]);
m:rand_range(1,4);
n:rand_with_prohib(1,4,[m,4*(m-1)]); /* 4*(m-1) prevents n=2m when m=2 */
[p1,p2]:rand([[3,2],[4,2],[4,3],[3,1],[4,1]]);
g:m*v^p1+n*v^p2;
c:rand_range(2,3);
fdash:expand(c*g);
f:int(fdash,v);
gint:expand(f/c);
ta1:fdash;
ta2:int(g,v,a,b);</text>
    </questionvariables>
    <specificfeedback format="html">
      <text/>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text>\(\frac{d}{d{@v@}}{@f@}={@ta1@}\) so {@'int(g,v,a,b)=ta2@}</text>
    </questionnote>
    <questiondescription format="moodle_auto_format">
      <text/>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text><![CDATA[<span style="font-size: 1.5em; color:green;"><i class="fa fa-check"></i></span> Correct answer, well done.]]></text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text><![CDATA[<span style="font-size: 1.5em; color:orange;"><i class="fa fa-adjust"></i></span> Your answer is partially correct.]]></text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text><![CDATA[<span style="font-size: 1.5em; color:red;"><i class="fa fa-times"></i></span> Incorrect answer.]]></text>
    </prtincorrect>
    <decimals>.</decimals>
    <scientificnotation>*10</scientificnotation>
    <multiplicationsign>dot</multiplicationsign>
    <sqrtsign>1</sqrtsign>
    <complexno>i</complexno>
    <inversetrig>cos-1</inversetrig>
    <logicsymbol>lang</logicsymbol>
    <matrixparens>[</matrixparens>
    <isbroken>0</isbroken>
    <variantsselectionseed/>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>ta1</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>1</insertstars>
      <syntaxhint/>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords/>
      <allowwords/>
      <forbidfloat>1</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>3</showvalidation>
      <options/>
    </input>
    <input>
      <name>ans2</name>
      <type>numerical</type>
      <tans>ta2</tans>
      <boxsize>7</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>1</insertstars>
      <syntaxhint/>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords/>
      <allowwords/>
      <forbidfloat>1</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>3</showvalidation>
      <options/>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text/>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description/>
        <answertest>Diff</answertest>
        <sans>ans1</sans>
        <tans>ta1</tans>
        <testoptions>v</testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty/>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty/>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
    </prt>
    <prt>
      <name>prt2</name>
      <value>3.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text/>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description/>
        <answertest>AlgEquiv</answertest>
        <sans>ans2</sans>
        <tans>ta2</tans>
        <testoptions/>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty/>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt2-1-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty/>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt2-1-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
    </prt>
    <deployedseed>2068084330</deployedseed>
    <deployedseed>1750942838</deployedseed>
    <deployedseed>906910132</deployedseed>
    <deployedseed>949078977</deployedseed>
    <deployedseed>298693844</deployedseed>
    <deployedseed>932033793</deployedseed>
    <deployedseed>946222153</deployedseed>
    <deployedseed>446498709</deployedseed>
    <deployedseed>555834061</deployedseed>
    <deployedseed>1532619962</deployedseed>
    <deployedseed>1267888114</deployedseed>
    <deployedseed>1002823138</deployedseed>
    <deployedseed>1230199245</deployedseed>
    <deployedseed>547385773</deployedseed>
    <deployedseed>764936474</deployedseed>
    <deployedseed>536271589</deployedseed>
    <deployedseed>175594715</deployedseed>
    <deployedseed>1370740190</deployedseed>
    <deployedseed>1854709429</deployedseed>
    <deployedseed>848273522</deployedseed>
    <qtest>
      <testcase>1</testcase>
      <description/>
      <testinput>
        <name>ans1</name>
        <value>ta1</value>
      </testinput>
      <testinput>
        <name>ans2</name>
        <value>ta2</value>
      </testinput>
      <expected>
        <name>prt1</name>
        <expectedscore>1.0000000</expectedscore>
        <expectedpenalty>0.0000000</expectedpenalty>
        <expectedanswernote>prt1-1-T</expectedanswernote>
      </expected>
      <expected>
        <name>prt2</name>
        <expectedscore>1.0000000</expectedscore>
        <expectedpenalty>0.0000000</expectedpenalty>
        <expectedanswernote>prt2-1-T</expectedanswernote>
      </expected>
    </qtest>
    <qtest>
      <testcase>2</testcase>
      <description/>
      <testinput>
        <name>ans1</name>
        <value>int(f,v)</value>
      </testinput>
      <testinput>
        <name>ans2</name>
        <value>int(g,v)</value>
      </testinput>
      <expected>
        <name>prt1</name>
        <expectedscore>0.0000000</expectedscore>
        <expectedpenalty>0.1000000</expectedpenalty>
        <expectedanswernote>prt1-1-F</expectedanswernote>
      </expected>
      <expected>
        <name>prt2</name>
        <expectedscore/>
        <expectedpenalty/>
        <expectedanswernote>NULL</expectedanswernote>
      </expected>
    </qtest>
    <qtest>
      <testcase>3</testcase>
      <description/>
      <testinput>
        <name>ans1</name>
        <value>ta1+C</value>
      </testinput>
      <testinput>
        <name>ans2</name>
        <value/>
      </testinput>
      <expected>
        <name>prt1</name>
        <expectedscore>0.0000000</expectedscore>
        <expectedpenalty>0.1000000</expectedpenalty>
        <expectedanswernote>prt1-1-F</expectedanswernote>
      </expected>
      <expected>
        <name>prt2</name>
        <expectedscore/>
        <expectedpenalty/>
        <expectedanswernote>NULL</expectedanswernote>
      </expected>
    </qtest>
  </question>
</quiz>
