<?xml version="1.0" encoding="UTF-8"?>
<quiz>
  <question type="stack">
    <name>
      <text>16.1.5.3 Terms of series</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<p class="HELM_exercise">Exercise</p>
<p>Write out the first three terms and the last term of the following series, note you do not need to simplify the expressions.&nbsp;</p><br>
<ol class="HELM_parts">
    <li>
        <p>\(\displaystyle \sum_{p~=~{@terms1[1]@}}^{{@terms1[4]@}} {@ser1(p)@}=\) [[input:ans11]] [[validation:ans11]] \(+\) [[input:ans12]] [[validation:ans12]] \(+\) [[input:ans13]] [[validation:ans13]] \(+\ldots +\) [[input:ans14]] [[validation:ans14]] [[feedback:prt1]]</p>
    </li>
    <li>
        <p>\(\displaystyle \sum_{p~=~{@terms2[1]@}}^{{@terms2[4]@}} {@ser2(p)@}=\) [[input:ans21]] [[validation:ans21]] \(+\) [[input:ans22]] [[validation:ans22]] \(+\) [[input:ans23]] [[validation:ans23]] \(+\ldots +\) [[input:ans24]] [[validation:ans24]] [[feedback:prt2]]</p>
    </li>
</ol>]]></text>
    </questiontext>
    <generalfeedback format="html">
      <text><![CDATA[<p>For each term, simply substitute in the value of \(p\). The terms then are:</p>
<ol class="HELM_parts">
    <li>\(\displaystyle {@ta1[1]@}, {@ta1[2]@}, {@ta1[3]@}, \ldots, {@ta1[4]@}\)</li>
    <li>\(\displaystyle {@ta2[1]@}, {@ta2[2]@}, {@ta2[3]@}, \ldots, {@ta2[4]@}\)</li>
</ol>
<p>Note that for part (b), the count starts from \(p~=~{@terms2[1]@}\) for the first term. So for the second term we have \(p~=~{@terms2[2]@}\), and so on.</p>]]></text>
    </generalfeedback>
    <defaultgrade>1</defaultgrade>
    <penalty>0.1</penalty>
    <hidden>0</hidden>
    <idnumber/>
    <stackversion>
      <text>2020120600</text>
    </stackversion>
    <questionvariables>
      <text>/*Randomization constants*/
const1: rand([15,17,19]); /*Series upper bound*/
const2: rand([3,4,5]); /*Lower bound series (b)*/

/*Series (a)*/
ser1: lambda([p], 3^(ev(p-1,simp:true))/(factorial(p)*(ev(const1+1-p,simp:true))));
terms1: [1,2,3,const1];
ta1: map(ser1,terms1);

/*Series (b)*/
ser2: lambda([p], (-p)^(ev(p-1,simp:true))/(p*(ev(p+2,simp:true))));
simp:true;
terms2: [const2,const2+1,const2+2,const1];
simp:false;
ta2: map(ser2,terms2);</text>
    </questionvariables>
    <specificfeedback format="html">
      <text/>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text>\[ \sum_{p~=~{@terms1[1]@}}^{{@terms1[4]@}} {@ser1(p)@}={@ta1[1]@}, {@ta1[2]@}, {@ta1[3]@}, \ldots, {@ta1[4]@}\]
\[ \sum_{p~=~{@terms2[1]@}}^{{@terms2[4]@}} {@ser2(p)@}= {@ta2[1]@}, {@ta2[2]@}, {@ta2[3]@}, \ldots, {@ta2[4]@} \]</text>
    </questionnote>
    <questiondescription format="moodle_auto_format">
      <text/>
    </questiondescription>
    <questionsimplify>0</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> Your answer is partially correct.</span>]]></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>ans11</name>
      <type>algebraic</type>
      <tans>ta1[1]</tans>
      <boxsize>8</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</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>ans12</name>
      <type>algebraic</type>
      <tans>ta1[2]</tans>
      <boxsize>8</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</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>ans13</name>
      <type>algebraic</type>
      <tans>ta1[3]</tans>
      <boxsize>8</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</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>ans14</name>
      <type>algebraic</type>
      <tans>ta1[4]</tans>
      <boxsize>8</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</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>ans21</name>
      <type>algebraic</type>
      <tans>ta2[1]</tans>
      <boxsize>8</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</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>ans22</name>
      <type>algebraic</type>
      <tans>ta2[2]</tans>
      <boxsize>8</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</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>ans23</name>
      <type>algebraic</type>
      <tans>ta2[3]</tans>
      <boxsize>8</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</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>ans24</name>
      <type>algebraic</type>
      <tans>ta2[4]</tans>
      <boxsize>8</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</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>simp:true;</text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description/>
        <answertest>AlgEquiv</answertest>
        <sans>ans11</sans>
        <tans>ta1[1]</tans>
        <testoptions/>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>0.2500000</truescore>
        <truepenalty/>
        <truenextnode>1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0.0000000</falsescore>
        <falsepenalty/>
        <falsenextnode>1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
      <node>
        <name>1</name>
        <description/>
        <answertest>AlgEquiv</answertest>
        <sans>ans12</sans>
        <tans>ta1[2]</tans>
        <testoptions/>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2500000</truescore>
        <truepenalty/>
        <truenextnode>2</truenextnode>
        <trueanswernote>prt1-2-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.0000000</falsescore>
        <falsepenalty/>
        <falsenextnode>2</falsenextnode>
        <falseanswernote>prt1-2-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
      <node>
        <name>2</name>
        <description/>
        <answertest>AlgEquiv</answertest>
        <sans>ans13</sans>
        <tans>ta1[3]</tans>
        <testoptions/>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2500000</truescore>
        <truepenalty/>
        <truenextnode>3</truenextnode>
        <trueanswernote>prt1-3-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.0000000</falsescore>
        <falsepenalty/>
        <falsenextnode>3</falsenextnode>
        <falseanswernote>prt1-3-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
      <node>
        <name>3</name>
        <description/>
        <answertest>AlgEquiv</answertest>
        <sans>ans14</sans>
        <tans>ta1[4]</tans>
        <testoptions/>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2500000</truescore>
        <truepenalty/>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-4-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.0000000</falsescore>
        <falsepenalty/>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-4-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
    </prt>
    <prt>
      <name>prt2</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text>simp:true;</text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description/>
        <answertest>AlgEquiv</answertest>
        <sans>ans21</sans>
        <tans>ta2[1]</tans>
        <testoptions/>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>0.2500000</truescore>
        <truepenalty/>
        <truenextnode>1</truenextnode>
        <trueanswernote>prt2-1-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0.0000000</falsescore>
        <falsepenalty/>
        <falsenextnode>1</falsenextnode>
        <falseanswernote>prt2-1-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
      <node>
        <name>1</name>
        <description/>
        <answertest>AlgEquiv</answertest>
        <sans>ans22</sans>
        <tans>ta2[2]</tans>
        <testoptions/>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2500000</truescore>
        <truepenalty/>
        <truenextnode>2</truenextnode>
        <trueanswernote>prt2-2-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.0000000</falsescore>
        <falsepenalty/>
        <falsenextnode>2</falsenextnode>
        <falseanswernote>prt2-2-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
      <node>
        <name>2</name>
        <description/>
        <answertest>AlgEquiv</answertest>
        <sans>ans23</sans>
        <tans>ta2[3]</tans>
        <testoptions/>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2500000</truescore>
        <truepenalty/>
        <truenextnode>3</truenextnode>
        <trueanswernote>prt2-3-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.0000000</falsescore>
        <falsepenalty/>
        <falsenextnode>3</falsenextnode>
        <falseanswernote>prt2-3-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
      <node>
        <name>3</name>
        <description/>
        <answertest>AlgEquiv</answertest>
        <sans>ans24</sans>
        <tans>ta2[4]</tans>
        <testoptions/>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2500000</truescore>
        <truepenalty/>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt2-4-T</trueanswernote>
        <truefeedback format="html">
          <text/>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.0000000</falsescore>
        <falsepenalty/>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt2-4-F</falseanswernote>
        <falsefeedback format="html">
          <text/>
        </falsefeedback>
      </node>
    </prt>
    <deployedseed>349573332</deployedseed>
    <deployedseed>405953827</deployedseed>
    <deployedseed>1038419227</deployedseed>
    <deployedseed>1342906930</deployedseed>
    <deployedseed>2129252967</deployedseed>
    <deployedseed>310608243</deployedseed>
    <deployedseed>1121528385</deployedseed>
    <deployedseed>639449472</deployedseed>
    <deployedseed>913697674</deployedseed>
    <qtest>
      <testcase>1</testcase>
      <description/>
      <testinput>
        <name>ans11</name>
        <value>ta1[1]</value>
      </testinput>
      <testinput>
        <name>ans12</name>
        <value>ta1[2]</value>
      </testinput>
      <testinput>
        <name>ans13</name>
        <value>ta1[3]</value>
      </testinput>
      <testinput>
        <name>ans14</name>
        <value>ta1[4]</value>
      </testinput>
      <testinput>
        <name>ans21</name>
        <value>ta2[1]</value>
      </testinput>
      <testinput>
        <name>ans22</name>
        <value>ta2[2]</value>
      </testinput>
      <testinput>
        <name>ans23</name>
        <value>ta2[3]</value>
      </testinput>
      <testinput>
        <name>ans24</name>
        <value>ta2[4]</value>
      </testinput>
      <expected>
        <name>prt1</name>
        <expectedscore>1.0000000</expectedscore>
        <expectedpenalty>0.0000000</expectedpenalty>
        <expectedanswernote>prt1-4-T</expectedanswernote>
      </expected>
      <expected>
        <name>prt2</name>
        <expectedscore>1.0000000</expectedscore>
        <expectedpenalty>0.0000000</expectedpenalty>
        <expectedanswernote>prt2-4-T</expectedanswernote>
      </expected>
    </qtest>
    <qtest>
      <testcase>2</testcase>
      <description/>
      <testinput>
        <name>ans11</name>
        <value>ta1[1]</value>
      </testinput>
      <testinput>
        <name>ans12</name>
        <value/>
      </testinput>
      <testinput>
        <name>ans13</name>
        <value/>
      </testinput>
      <testinput>
        <name>ans14</name>
        <value/>
      </testinput>
      <testinput>
        <name>ans21</name>
        <value>ta2[1]</value>
      </testinput>
      <testinput>
        <name>ans22</name>
        <value>ta2[2]</value>
      </testinput>
      <testinput>
        <name>ans23</name>
        <value/>
      </testinput>
      <testinput>
        <name>ans24</name>
        <value/>
      </testinput>
      <expected>
        <name>prt1</name>
        <expectedscore/>
        <expectedpenalty/>
        <expectedanswernote>NULL</expectedanswernote>
      </expected>
      <expected>
        <name>prt2</name>
        <expectedscore/>
        <expectedpenalty/>
        <expectedanswernote>NULL</expectedanswernote>
      </expected>
    </qtest>
    <qtest>
      <testcase>3</testcase>
      <description/>
      <testinput>
        <name>ans11</name>
        <value>ta1[1]</value>
      </testinput>
      <testinput>
        <name>ans12</name>
        <value>ta1[2]</value>
      </testinput>
      <testinput>
        <name>ans13</name>
        <value>ta1[2]</value>
      </testinput>
      <testinput>
        <name>ans14</name>
        <value>ta1[3]</value>
      </testinput>
      <testinput>
        <name>ans21</name>
        <value>ta2[1]</value>
      </testinput>
      <testinput>
        <name>ans22</name>
        <value>ta2[2]</value>
      </testinput>
      <testinput>
        <name>ans23</name>
        <value>ta2[3]</value>
      </testinput>
      <testinput>
        <name>ans24</name>
        <value/>
      </testinput>
      <expected>
        <name>prt1</name>
        <expectedscore>0.5000000</expectedscore>
        <expectedpenalty/>
        <expectedanswernote>prt1-4-F</expectedanswernote>
      </expected>
      <expected>
        <name>prt2</name>
        <expectedscore/>
        <expectedpenalty/>
        <expectedanswernote>NULL</expectedanswernote>
      </expected>
    </qtest>
    <qtest>
      <testcase>4</testcase>
      <description/>
      <testinput>
        <name>ans11</name>
        <value>ev(ta1[1],simp:true)</value>
      </testinput>
      <testinput>
        <name>ans12</name>
        <value>ev(ta1[2],simp:true)</value>
      </testinput>
      <testinput>
        <name>ans13</name>
        <value>ev(ta1[3],simp:true)</value>
      </testinput>
      <testinput>
        <name>ans14</name>
        <value>ev(ta1[4],simp:true)</value>
      </testinput>
      <testinput>
        <name>ans21</name>
        <value>ev(ta2[1],simp:true)</value>
      </testinput>
      <testinput>
        <name>ans22</name>
        <value>ev(ta2[2],simp:true)</value>
      </testinput>
      <testinput>
        <name>ans23</name>
        <value>ev(ta2[3],simp:true)</value>
      </testinput>
      <testinput>
        <name>ans24</name>
        <value>ev(ta2[4],simp:true)</value>
      </testinput>
      <expected>
        <name>prt1</name>
        <expectedscore>1.0000000</expectedscore>
        <expectedpenalty>0.0000000</expectedpenalty>
        <expectedanswernote>prt1-4-T</expectedanswernote>
      </expected>
      <expected>
        <name>prt2</name>
        <expectedscore>1.0000000</expectedscore>
        <expectedpenalty>0.0000000</expectedpenalty>
        <expectedanswernote>prt2-4-T</expectedanswernote>
      </expected>
    </qtest>
  </question>
</quiz>
