Skip to content
Open
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
1 change: 0 additions & 1 deletion examples/sample-article/gen/stack/stack-integration.ptx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<stack-static>

<statement><p>Find <me> \int {{\left(x-3\right)}^6} d{x}</me> <fillin characters="20" name="ans1"/> </p></statement>
<solution><p>We can either do this question by inspection (i.e. spot the answer) or in a more formal manner by using the substitution <me> u = ({x}-{3}).</me> Then, since <m>\frac{d}{d{x}}u=1</m> we have <me> \int {{\left(x-3\right)}^6} d{x} = \int u^{6} du = \frac{u^{7}}{7}+c = {\frac{{\left(x-3\right)}^7}{7}}+c.</me></p></solution>
<answer><p><m>\frac{{\left(x-3\right)}^7}{7}+c</m></p></answer>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- (2025-12-19) We want this question files to not require any -->
<!-- additional preparation, specifically this namespace declaration -->
<!-- should not be here. Removing it will lead to many errors, so we -->
<!-- are working on a better solution. -->
<quiz xmlns="http://stack-assessment.org/2025/moodle-question">
<quiz>
<!-- question: 17332 -->
<question type="stack">
<name>
Expand Down
278 changes: 278 additions & 0 deletions examples/sample-article/media/stack/Adding-vectors-in-triangles.xml

Large diffs are not rendered by default.

142 changes: 142 additions & 0 deletions examples/sample-article/media/stack/Checkbox.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,142 @@
<?xml version="1.0" encoding="UTF-8"?>
<quiz>
<question type="stack">
<name>
<text>Checkbox</text>
</name>
<questiontext format="html">
<text><![CDATA[<p>Differentiate {@p@} with respect to \(x\).</p><p>[[input:ans1]]</p><div>[[validation:ans1]]</div>]]></text>
</questiontext>
<generalfeedback format="html">
<text/>
</generalfeedback>
<defaultgrade>1</defaultgrade>
<penalty>0.1</penalty>
<hidden>0</hidden>
<idnumber/>
<stackversion>
<text>2018080600</text>
</stackversion>
<questionvariables>
<text><![CDATA[/* Create a list of potential answers. */
p:sin(2*x);
ta:[[diff(p,x),true],[p,false],[int(p,x),false],[cos(2*x)+c,false]];
/* The actual correct answer. */
tac:diff(p,x)
/* Add in a "None of these" to the end of the list. The Maxima value is the atom null. */
tao:[null, false, "None of these"];
ta:append(ta,[tao]);]]></text>
</questionvariables>
<specificfeedback format="html">
<text>[[feedback:prt1]]</text>
</specificfeedback>
<questionnote format="html">
<text/>
</questionnote>
<questiondescription format="html">
<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>checkbox</type>
<tans>ta</tans>
<boxsize>15</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>2</showvalidation>
<options/>
</input>
<prt>
<name>prt1</name>
<value>1.0000000</value>
<autosimplify>1</autosimplify>
<feedbackstyle>1</feedbackstyle>
<feedbackvariables>
<text><![CDATA[ansmod:apply("and",maplist(lambda([ex],second(ATDiff(ex,diff(p,x),x))),ans1));]]></text>
</feedbackvariables>
<node>
<name>0</name>
<description/>
<answertest>AlgEquiv</answertest>
<sans>ansmod</sans>
<tans>true</tans>
<testoptions/>
<quiet>0</quiet>
<truescoremode>=</truescoremode>
<truescore>1.0000000</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>
</prt>
<qtest>
<testcase>1</testcase>
<description/>
<testinput>
<name>ans1</name>
<value>[2*cos(2*x)]</value>
</testinput>
<expected>
<name>prt1</name>
<expectedscore>1.0000000</expectedscore>
<expectedpenalty>0.0000000</expectedpenalty>
<expectedanswernote>prt1-1-T</expectedanswernote>
</expected>
</qtest>
<qtest>
<testcase>2</testcase>
<description/>
<testinput>
<name>ans1</name>
<value>[first(ta[1]),first(ta[3])]</value>
</testinput>
<expected>
<name>prt1</name>
<expectedscore>0.0000000</expectedscore>
<expectedpenalty>0.1000000</expectedpenalty>
<expectedanswernote>prt1-1-F</expectedanswernote>
</expected>
</qtest>
</question>
</quiz>
135 changes: 135 additions & 0 deletions examples/sample-article/media/stack/Matrix.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,135 @@
<?xml version="1.0" encoding="UTF-8"?>
<quiz>
<question type="stack">
<name>
<text>Matrix</text>
</name>
<questiontext format="html">
<text><![CDATA[<p>Type in {@M@}<br></p><p>[[input:ans1]]</p><div>[[validation:ans1]]</div>]]></text>
</questiontext>
<generalfeedback format="html">
<text/>
</generalfeedback>
<defaultgrade>1</defaultgrade>
<penalty>0.1</penalty>
<hidden>0</hidden>
<idnumber/>
<stackversion>
<text>2018080600</text>
</stackversion>
<questionvariables>
<text>M:matrix([1,2],[3,4])</text>
</questionvariables>
<specificfeedback format="html">
<text>[[feedback:prt1]]</text>
</specificfeedback>
<questionnote format="html">
<text/>
</questionnote>
<questiondescription format="html">
<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>matrix</type>
<tans>M</tans>
<boxsize>15</boxsize>
<strictsyntax>1</strictsyntax>
<insertstars>0</insertstars>
<syntaxhint/>
<syntaxattribute>0</syntaxattribute>
<forbidwords/>
<allowwords/>
<forbidfloat>1</forbidfloat>
<requirelowestterms>0</requirelowestterms>
<checkanswertype>1</checkanswertype>
<mustverify>1</mustverify>
<showvalidation>1</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>AlgEquiv</answertest>
<sans>ans1</sans>
<tans>M</tans>
<testoptions/>
<quiet>0</quiet>
<truescoremode>=</truescoremode>
<truescore>1.0000000</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>
</prt>
<qtest>
<testcase>1</testcase>
<description/>
<testinput>
<name>ans1</name>
<value>M</value>
</testinput>
<expected>
<name>prt1</name>
<expectedscore>1.0000000</expectedscore>
<expectedpenalty>0.0000000</expectedpenalty>
<expectedanswernote>prt1-1-T</expectedanswernote>
</expected>
</qtest>
<qtest>
<testcase>2</testcase>
<description/>
<testinput>
<name>ans1</name>
<value>ev(2*M,simp)</value>
</testinput>
<expected>
<name>prt1</name>
<expectedscore>0.0000000</expectedscore>
<expectedpenalty>0.1000000</expectedpenalty>
<expectedanswernote>prt1-1-F</expectedanswernote>
</expected>
</qtest>
</question>
</quiz>
Loading