<?xml version="1.0" encoding="UTF-8"?>
<quiz>
<!-- question: 8382951  -->
  <question type="stack">
    <name>
      <text>Beschriftung von Achsen</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<p>JSXGraph enthält neuerdings eine Option, Achsen zu beschriften. Das funktioniert mit dem folgenden Code (linke Seite). Beachten Sie, dass mit dem Attribut <code>name</code> der Text für die Beschriftung festgelegt wird. Die Platzhalter <code>\<span></span>\<span></span>(...\<span></span>\<span></span>)</code> bewirken, dass der Text als LaTeX-Formel angezeigt wird. In einer solchen Formelumgebung müssen alle <code>\</code>-Zeichen doppelt verwendet werden (z. B. <code>\<span></span>\<span></span>(\\alpha\<span></span>\<span></span>)</code> anstelle von <code>\<span></span>(\alpha\<span></span>)</code>.</p>

<div class="row">
<div class="col">
<p>Der Code:</p>
[[iframe width="80%" height="100%"]]
   [[style href="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/styles/vs2015.css" /]]
   [[script src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/highlight.min.js" /]]
   [[script]]
      document.addEventListener("DOMContentLoaded", e=>{
         hljs.highlightAll()
      });
   [[/script]]

   <pre class="theme-vs2015"><code class="javascript">
var board = JXG.JSXGraph.initBoard(divid, {
  boundingbox: [-5, 5, 5, -5],
  axis: true,
  showCopyright: false,
  showNavigation: true,
  defaultAxes: {
    x: {
      name: "\\(x\\)",
      withLabel: true,
      label: {
        position: 'rt',
        offset: [-5, 15],
        anchorX: 'right'
      }
    },
    y: {
      name: "\\(y\\)",
      withLabel: true,
      label: {
        position: 'rt',
        offset: [15, -5],
        anchorX: 'right'
      }
    }
  }
});
   </code></pre>

[[/iframe]]
</div>
<div class="col">
<p>Die Grafik:</p>

[[jsxgraph width="70%" aspect-ratio="1/1"]]
var board = JXG.JSXGraph.initBoard(divid, {
  boundingbox: [-5, 5, 5, -5],
  axis: true,
  showCopyright: false,
  showNavigation: true,
  defaultAxes: {
    x: {
      name: "\\(x\\)",
      withLabel: true,
      label: {
        position: 'rt',
        offset: [-5, 15],
        anchorX: 'right'
      }
    },
    y: {
      name: "\\(y\\)",
      withLabel: true,
      label: {
        position: 'rt',
        offset: [15, -5],
        anchorX: 'right'
      }
    }
  }
});
[[/jsxgraph]]
</div>
</div>


<p style="display:none">[[input:ans1]] [[validation:ans1]]</p>

<br><br>]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Beschriftung von Achsen“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/</text>
    </questionvariables>
    <specificfeedback format="html">
      <text>[[feedback:prt1]]</text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>1</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>1</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>1</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>1</sans>
        <tans>1</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8382903  -->
  <question type="stack">
    <name>
      <text>Bild in JSXGraph-Board</text>
    </name>
    <questiontext format="moodle_auto_format">
      <text><![CDATA[<p>In diesem Beispiel ist ein Bild, das in Sciebo hochgeladen ist, in das JSXGraph-Board eingebettet. Es sieht zwar ein
    wenig so aus, als wären drei JSXGraph-Funkionsgraphen zu sehen. In Wirklichkeit ist es aber ein Bild.</p>

<p>Mehr zum JSXGraph-Objekttyp <code>image</code> ist in der Dokumentation von JSXGraph zu finden: <a
        href="https://jsxgraph.uni-bayreuth.de/docs/symbols/Image.html"
        target="_blank">https://jsxgraph.uni-bayreuth.de/docs/symbols/Image.html</a></p>

<p>
<details style="border: 1px solid #aaa; border-radius: 4px; padding: 0.5em 0.5em 0;">
    <summary style="font-weight: bold;margin: -0.5em -0.5em 0; padding: 0.5em;">Anleitung: Ein Bild in Sciebo hosten
    </summary>
    <p>Es ist möglich, Sciebo zu nutzen, um Fotos in JSXGraph-Grafiken zu verwenden. Dafür müssen die folgenden Schritte
        befolgt werden:</p>

    <ol>
        <li>Öffnen Sie Sciebo im Browser.</li>
        <li>Navigieren Sie zu dem Foto, das Sie einbinden möchten.</li>
        <li>Klicken Sie auf das „Pfad“-Symbol rechts: <i class="fa fa-share-alt" aria-hidden="true"></i>
        </li>
        <li>Rechts befinden sich nun mehrere Reiter. Klicken Sie dort auf „Öffentliche Links“ und dann auf „Öffentlichen
            Link erstellen“.</li>
        <li>Wählen Sie nun „Herunterladen/Ansehen“ aus und klicken dann auf „Teilen“.</li>
        <li>Nun ist der Link erstellt. Klicken Sie dann in der rechten Leiste auf das linke der vier Symbole: <img
                src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB8AAAAfCAYAAAAfrhY5AAAAxnpUWHRSYXcgcHJvZmlsZSB0eXBlIGV4aWYAAHjabVBBDsQgCLz7in2CAlp8jt3aZH+wz99RaNM2O4kjDGREQv9+9vAaoCRB8qKllhIBqVKpIdBoaJNTlMmW7F5Ldz2cBYLEuNlSLd5/6Ok0sKshyhcjfXthvRequL8+jPwhHhMRgs2NqhsxWSG5QbNvxVJ1uX5h7fEOtRMGvfv0jslfe+ayYHtbhshEnSGDmYsNwONI4DaDwRWNaELMnMHE5JNgIf/2dCD8ANWrWjf3dwJyAAABhWlDQ1BJQ0MgcHJvZmlsZQAAeJx9kT1Iw0AYht+mSlUqDnYQcQhSneyiIuJUqlgEC6Wt0KqDyaV/0KQhSXFxFFwLDv4sVh1cnHV1cBUEwR8QZwcnRRcp8buk0CLGO457eO97X+6+A4RGhalmVxRQNctIxWNiNrcqBl4hoJfmKOYkZuqJ9GIGnuPrHj6+30V4lnfdn6NfyZsM8InEUaYbFvEG8cympXPeJw6xkqQQnxNPGHRB4keuyy6/cS46LPDMkJFJzROHiMViB8sdzEqGSjxNHFZUjfKFrMsK5y3OaqXGWvfkLwzmtZU012mNII4lJJCECBk1lFGBhQjtGikmUnQe8/APO/4kuWRylcHIsYAqVEiOH/wPfvfWLExNuknBGND9YtsfY0BgF2jWbfv72LabJ4D/GbjS2v5qA5j9JL3e1sJHwMA2cHHd1uQ94HIHGHrSJUNyJD8toVAA3s/om3LA4C3Qt+b2rXWO0wcgQ71avgEODoHxImWve7y7p7Nv/9a0+vcD1RpyzlB++lYAAA12aVRYdFhNTDpjb20uYWRvYmUueG1wAAAAAAA8P3hwYWNrZXQgYmVnaW49Iu+7vyIgaWQ9Ilc1TTBNcENlaGlIenJlU3pOVGN6a2M5ZCI/Pgo8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJYTVAgQ29yZSA0LjQuMC1FeGl2MiI+CiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPgogIDxyZGY6RGVzY3JpcHRpb24gcmRmOmFib3V0PSIiCiAgICB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIKICAgIHhtbG5zOnN0RXZ0PSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VFdmVudCMiCiAgICB4bWxuczpkYz0iaHR0cDovL3B1cmwub3JnL2RjL2VsZW1lbnRzLzEuMS8iCiAgICB4bWxuczpHSU1QPSJodHRwOi8vd3d3LmdpbXAub3JnL3htcC8iCiAgICB4bWxuczp0aWZmPSJodHRwOi8vbnMuYWRvYmUuY29tL3RpZmYvMS4wLyIKICAgIHhtbG5zOnhtcD0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLyIKICAgeG1wTU06RG9jdW1lbnRJRD0iZ2ltcDpkb2NpZDpnaW1wOjZhZTliM2Y0LWNjMzctNGIxYS04YjEwLWQ2ZjNmMmI1ZTA0NCIKICAgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDozZjk2OTI2OC00YzU1LTRkMmMtOGVhMC0zNjhjM2JmMzFmN2IiCiAgIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDo3Y2EwN2ViMy05NzQzLTRmMzMtOWZjNi1lNzg5YjBhMjZjNTkiCiAgIGRjOkZvcm1hdD0iaW1hZ2UvcG5nIgogICBHSU1QOkFQST0iMi4wIgogICBHSU1QOlBsYXRmb3JtPSJXaW5kb3dzIgogICBHSU1QOlRpbWVTdGFtcD0iMTcwNzQ3MTMyNDc1NjczNyIKICAgR0lNUDpWZXJzaW9uPSIyLjEwLjM2IgogICB0aWZmOk9yaWVudGF0aW9uPSIxIgogICB4bXA6Q3JlYXRvclRvb2w9IkdJTVAgMi4xMCIKICAgeG1wOk1ldGFkYXRhRGF0ZT0iMjAyNDowMjowOVQxMDozNToyMiswMTowMCIKICAgeG1wOk1vZGlmeURhdGU9IjIwMjQ6MDI6MDlUMTA6MzU6MjIrMDE6MDAiPgogICA8eG1wTU06SGlzdG9yeT4KICAgIDxyZGY6U2VxPgogICAgIDxyZGY6bGkKICAgICAgc3RFdnQ6YWN0aW9uPSJzYXZlZCIKICAgICAgc3RFdnQ6Y2hhbmdlZD0iLyIKICAgICAgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDo5MTM0ODJlYy1jMjM5LTQ1NmItOTA0OC1mNjg3ZDY3ZmExMzQiCiAgICAgIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkdpbXAgMi4xMCAoV2luZG93cykiCiAgICAgIHN0RXZ0OndoZW49IjIwMjQtMDItMDlUMTA6MzU6MjQiLz4KICAgIDwvcmRmOlNlcT4KICAgPC94bXBNTTpIaXN0b3J5PgogIDwvcmRmOkRlc2NyaXB0aW9uPgogPC9yZGY6UkRGPgo8L3g6eG1wbWV0YT4KICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgIAo8P3hwYWNrZXQgZW5kPSJ3Ij8+zhRTOAAAAAZiS0dEAAAAAAAA+UO7fwAAAAlwSFlzAAAOwwAADsMBx2+oZAAAAAd0SU1FB+gCCQkjGJMf+x0AAAJFSURBVEjH5Zch0+IwEIZfbhoBFUS0JogiiigGC6YVGND8Tv4BCDCoCkzLDJgyU0wRQRSYCTN3is6FLy0tH9wnbl0ySd9kd5/tpna9Xn/jh+wXftC0KoujKEIURUiSBJRSMMbgOM7L4rWybg+CAGEYAgBM0wTnHEIItFot9Pv9z91cCIEwDEEIgeu6oJRCCIHZbIY4jsE5B6X0dXEhBKIoghDiy6I0TQEAjLFMhBACy7IQhiE2mw2azaZSwLZtEEKKxVerFZIkyT0lIQTtdluasywLu90OcRwjjuPcPBmNRsXij8KMMXQ6nWxcr9eh67q0Rtd1jMdjnE6nbG673eJwOEheywtLbswHg0GpuBFCYBhGNjYMA/P5HJzzbO52u1VLuOl0+u85N03zbR+/41ha3HXdt4kvl8vCJFa6PU1T7Pf7px83TVOK91uKzOVyQRAETzc7jvN+8WazCc/znm6u1+tSfAkhX3CsLP6IT9m673ne98WPxyMWi4UUW1Uics7h+77EdJXkVYprmiYhp6rbu90OQRBIKOUd4tHuXlWKU0pzT52mKXzfVyK0Xq9LiU8mk/KoNRoNWJaFNE2xXC5xPp8/18k8omaaJizLgq7rcF039+YfQU3TNOlP5rquMua9Xq9SU/EyarZtwzAMKdsppZUQLYVaHnKUUgyHQ6m/U9V2z/OUhyqFWhFyANDtdsEYy22XKt28CLU8+1YDeTeV+161O5J//wOU4rZtZxn8TmOM5dZ76dHAOc/tt161ouyv/bcPxT8P8BFh//6uDAAAAABJRU5ErkJggg=="></img>
            Dann ist der Link bereits in Ihrer Zwischenablage.</li>
        <li>Wenn Sie das Bild nun in der JSXGraph-Grafik verwenden möchten, können Sie den Link an der entsprechenden
            Stelle einfügen (siehe Beispielaufgabe sowie Dokumentation von JSXGraph: <a
                href="https://jsxgraph.uni-bayreuth.de/docs/symbols/"
                target="_blank">https://jsxgraph.uni-bayreuth.de/docs/symbols/Image.html</a>). Sie müssen ihn dann noch
            um den Zusatz <code>/download</code> erweitern (z. B.
            <code>https://hs-rw.sciebo.de/s/wVfula4vf0P10WM/download</code>)</li>
    </ol>
</details>
</p>

[[jsxgraph]]
var board = JXG.JSXGraph.initBoard(divid, {
    boundingbox: [-10, 10, 10, -10],
    axis:true
});

var image = board.create('image',['https://hs-rw.sciebo.de/s/wVfula4vf0P10WM/download', [-10,-10], [20,20]],{
    fixed:true,
    highlight:false
});
[[/jsxgraph]]

<p style="display:none">[[input:ans1]] [[validation:ans1]]</p>]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Bild in JSXGraph-Board“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/</text>
    </questionvariables>
    <specificfeedback format="html">
      <text>[[feedback:prt1]]</text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>1</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>1</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>1</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ans1</sans>
        <tans>1</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8460406  -->
  <question type="stack">
    <name>
      <text>Bild in JSXGraph-Board</text>
    </name>
    <questiontext format="moodle_auto_format">
      <text><![CDATA[<p>In diesem Beispiel ist ein Bild, das in Sciebo hochgeladen ist, in das JSXGraph-Board eingebettet. Es sieht zwar ein wenig so aus, als wären drei JSXGraph-Funkionsgraphen zu sehen. In Wirklichkeit ist es aber ein Bild.</p>

<p>Mehr zum JSXGraph-Objekttyp <code>image</code> ist in der Dokumentation von JSXGraph zu finden: <a href="https://jsxgraph.uni-bayreuth.de/docs/symbols/Image.html" target="_blank">https://jsxgraph.uni-bayreuth.de/docs/symbols/Image.html</a></p>

<p><details style="border: 1px solid #aaa; border-radius: 4px; padding: 0.5em 0.5em 0;">
      <summary style="font-weight: bold;margin: -0.5em -0.5em 0; padding: 0.5em;">Anleitung: Ein Bild in Sciebo hosten</summary>
  <p>Es ist möglich, Sciebo zu nutzen, um Fotos in JSXGraph-Grafiken zu verwenden. Dafür müssen die folgenden Schritte befolgt werden. Beachten Sie aber, dass mit Sciebo gehostete Bilder aktuell aus Sicherheitsgründen nicht im Prüfungsmoodle in den E-Assessment-Räumen geladen werden können.</p>

      <ol>
          <li>Öffnen Sie Sciebo im Browser.</li>
          <li>Navigieren Sie zu dem Foto, das Sie einbinden möchten.</li>
          <li>Klicken Sie auf das „Pfad“-Symbol rechts: <i class="fa fa-share-alt" aria-hidden="true"></i>
</li>
          <li>Rechts befinden sich nun mehrere Reiter. Klicken Sie dort auf „Öffentliche Links“ und dann auf „Öffentlichen Link erstellen“.</li>
          <li>Wählen Sie nun „Herunterladen/Ansehen“ aus und klicken dann auf „Teilen“.</li>
          <li>Nun ist der Link erstellt. Klicken Sie dann in der rechten Leiste auf das linke der vier Symbole: <img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB8AAAAfCAYAAAAfrhY5AAAAxnpUWHRSYXcgcHJvZmlsZSB0eXBlIGV4aWYAAHjabVBBDsQgCLz7in2CAlp8jt3aZH+wz99RaNM2O4kjDGREQv9+9vAaoCRB8qKllhIBqVKpIdBoaJNTlMmW7F5Ldz2cBYLEuNlSLd5/6Ok0sKshyhcjfXthvRequL8+jPwhHhMRgs2NqhsxWSG5QbNvxVJ1uX5h7fEOtRMGvfv0jslfe+ayYHtbhshEnSGDmYsNwONI4DaDwRWNaELMnMHE5JNgIf/2dCD8ANWrWjf3dwJyAAABhWlDQ1BJQ0MgcHJvZmlsZQAAeJx9kT1Iw0AYht+mSlUqDnYQcQhSneyiIuJUqlgEC6Wt0KqDyaV/0KQhSXFxFFwLDv4sVh1cnHV1cBUEwR8QZwcnRRcp8buk0CLGO457eO97X+6+A4RGhalmVxRQNctIxWNiNrcqBl4hoJfmKOYkZuqJ9GIGnuPrHj6+30V4lnfdn6NfyZsM8InEUaYbFvEG8cympXPeJw6xkqQQnxNPGHRB4keuyy6/cS46LPDMkJFJzROHiMViB8sdzEqGSjxNHFZUjfKFrMsK5y3OaqXGWvfkLwzmtZU012mNII4lJJCECBk1lFGBhQjtGikmUnQe8/APO/4kuWRylcHIsYAqVEiOH/wPfvfWLExNuknBGND9YtsfY0BgF2jWbfv72LabJ4D/GbjS2v5qA5j9JL3e1sJHwMA2cHHd1uQ94HIHGHrSJUNyJD8toVAA3s/om3LA4C3Qt+b2rXWO0wcgQ71avgEODoHxImWve7y7p7Nv/9a0+vcD1RpyzlB++lYAAA12aVRYdFhNTDpjb20uYWRvYmUueG1wAAAAAAA8P3hwYWNrZXQgYmVnaW49Iu+7vyIgaWQ9Ilc1TTBNcENlaGlIenJlU3pOVGN6a2M5ZCI/Pgo8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJYTVAgQ29yZSA0LjQuMC1FeGl2MiI+CiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPgogIDxyZGY6RGVzY3JpcHRpb24gcmRmOmFib3V0PSIiCiAgICB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIKICAgIHhtbG5zOnN0RXZ0PSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VFdmVudCMiCiAgICB4bWxuczpkYz0iaHR0cDovL3B1cmwub3JnL2RjL2VsZW1lbnRzLzEuMS8iCiAgICB4bWxuczpHSU1QPSJodHRwOi8vd3d3LmdpbXAub3JnL3htcC8iCiAgICB4bWxuczp0aWZmPSJodHRwOi8vbnMuYWRvYmUuY29tL3RpZmYvMS4wLyIKICAgIHhtbG5zOnhtcD0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLyIKICAgeG1wTU06RG9jdW1lbnRJRD0iZ2ltcDpkb2NpZDpnaW1wOjZhZTliM2Y0LWNjMzctNGIxYS04YjEwLWQ2ZjNmMmI1ZTA0NCIKICAgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDozZjk2OTI2OC00YzU1LTRkMmMtOGVhMC0zNjhjM2JmMzFmN2IiCiAgIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDo3Y2EwN2ViMy05NzQzLTRmMzMtOWZjNi1lNzg5YjBhMjZjNTkiCiAgIGRjOkZvcm1hdD0iaW1hZ2UvcG5nIgogICBHSU1QOkFQST0iMi4wIgogICBHSU1QOlBsYXRmb3JtPSJXaW5kb3dzIgogICBHSU1QOlRpbWVTdGFtcD0iMTcwNzQ3MTMyNDc1NjczNyIKICAgR0lNUDpWZXJzaW9uPSIyLjEwLjM2IgogICB0aWZmOk9yaWVudGF0aW9uPSIxIgogICB4bXA6Q3JlYXRvclRvb2w9IkdJTVAgMi4xMCIKICAgeG1wOk1ldGFkYXRhRGF0ZT0iMjAyNDowMjowOVQxMDozNToyMiswMTowMCIKICAgeG1wOk1vZGlmeURhdGU9IjIwMjQ6MDI6MDlUMTA6MzU6MjIrMDE6MDAiPgogICA8eG1wTU06SGlzdG9yeT4KICAgIDxyZGY6U2VxPgogICAgIDxyZGY6bGkKICAgICAgc3RFdnQ6YWN0aW9uPSJzYXZlZCIKICAgICAgc3RFdnQ6Y2hhbmdlZD0iLyIKICAgICAgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDo5MTM0ODJlYy1jMjM5LTQ1NmItOTA0OC1mNjg3ZDY3ZmExMzQiCiAgICAgIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkdpbXAgMi4xMCAoV2luZG93cykiCiAgICAgIHN0RXZ0OndoZW49IjIwMjQtMDItMDlUMTA6MzU6MjQiLz4KICAgIDwvcmRmOlNlcT4KICAgPC94bXBNTTpIaXN0b3J5PgogIDwvcmRmOkRlc2NyaXB0aW9uPgogPC9yZGY6UkRGPgo8L3g6eG1wbWV0YT4KICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgIAo8P3hwYWNrZXQgZW5kPSJ3Ij8+zhRTOAAAAAZiS0dEAAAAAAAA+UO7fwAAAAlwSFlzAAAOwwAADsMBx2+oZAAAAAd0SU1FB+gCCQkjGJMf+x0AAAJFSURBVEjH5Zch0+IwEIZfbhoBFUS0JogiiigGC6YVGND8Tv4BCDCoCkzLDJgyU0wRQRSYCTN3is6FLy0tH9wnbl0ySd9kd5/tpna9Xn/jh+wXftC0KoujKEIURUiSBJRSMMbgOM7L4rWybg+CAGEYAgBM0wTnHEIItFot9Pv9z91cCIEwDEEIgeu6oJRCCIHZbIY4jsE5B6X0dXEhBKIoghDiy6I0TQEAjLFMhBACy7IQhiE2mw2azaZSwLZtEEKKxVerFZIkyT0lIQTtdluasywLu90OcRwjjuPcPBmNRsXij8KMMXQ6nWxcr9eh67q0Rtd1jMdjnE6nbG673eJwOEheywtLbswHg0GpuBFCYBhGNjYMA/P5HJzzbO52u1VLuOl0+u85N03zbR+/41ha3HXdt4kvl8vCJFa6PU1T7Pf7px83TVOK91uKzOVyQRAETzc7jvN+8WazCc/znm6u1+tSfAkhX3CsLP6IT9m673ne98WPxyMWi4UUW1Uics7h+77EdJXkVYprmiYhp6rbu90OQRBIKOUd4tHuXlWKU0pzT52mKXzfVyK0Xq9LiU8mk/KoNRoNWJaFNE2xXC5xPp8/18k8omaaJizLgq7rcF039+YfQU3TNOlP5rquMua9Xq9SU/EyarZtwzAMKdsppZUQLYVaHnKUUgyHQ6m/U9V2z/OUhyqFWhFyANDtdsEYy22XKt28CLU8+1YDeTeV+161O5J//wOU4rZtZxn8TmOM5dZ76dHAOc/tt161ouyv/bcPxT8P8BFh//6uDAAAAABJRU5ErkJggg=="></img> Dann ist der Link bereits in Ihrer Zwischenablage.</li>
          <li>Wenn Sie das Bild nun in der JSXGraph-Grafik verwenden möchten, können Sie den Link an der entsprechenden Stelle einfügen (siehe Beispielaufgabe sowie Dokumentation von JSXGraph: <a href="https://jsxgraph.uni-bayreuth.de/docs/symbols/" target="_blank">https://jsxgraph.uni-bayreuth.de/docs/symbols/Image.html</a>). Sie müssen ihn dann noch um den Zusatz <code>/download</code> erweitern (z. B. <code>https://hs-rw.sciebo.de/s/wVfula4vf0P10WM/download</code>)</li>
      </ol>
</details></p>

<div class="row">
    <div class="col">
        <p>Der Code:</p>
        [[iframe width="100%" height="100%"]]
            [[style href="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/styles/vs2015.css" /]]
            [[script src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/highlight.min.js" /]]
            [[script]]
                document.addEventListener("DOMContentLoaded", e=>{
                    hljs.highlightAll()
                });
            [[/script]]

            <pre class="theme-vs2015"><code class="javascript">
var board = JXG.JSXGraph.initBoard(divid, {
   boundingbox: [-10, 10, 10, -10],
   axis:true
});

var image = board.create('image',['https://hs-rw.sciebo.de/s/wVfula4vf0P10WM/download',
   [-10,-10], [20,20]
],{
   fixed:true,
   highlight:false
});
            </code></pre>

        [[/iframe]]
    </div>
    <div class="col">
        <p>Die Grafik:</p>

        [[jsxgraph width="70%" aspect-ratio="1/1"]]
         var board = JXG.JSXGraph.initBoard(divid, {
            boundingbox: [-10, 10, 10, -10],
            axis:true
        });
        
        var image = board.create('image',['https://hs-rw.sciebo.de/s/wVfula4vf0P10WM/download', [-10,-10], [20,20]],{
            fixed:true,
            highlight:false
        });
        [[/jsxgraph]]
    </div>
</div>

<p hidden>[[input:ans1]] [[validation:ans1]]</p>]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024072400</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Bild in JSXGraph-Board“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/</text>
    </questionvariables>
    <specificfeedback format="html">
      <text>[[feedback:prt1]]</text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>1</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>1</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>1</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ans1</sans>
        <tans>1</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8243670  -->
  <question type="stack">
    <name>
      <text>Boxplot (ab STACK v4.4.3)</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<style>
    .buttonweiter {
        border: 1px solid black;
        background-color: #a9f5bc;
    }

    .buttonweiter:hover {
        background-color: #e0f8e6;
    }

    .buttonzurueck {
        border: 1px solid black;
        background-color: #dcb25e;
    }

    .buttonzurueck:hover {
        background-color: #e7d2a7;
    }

    .popover_erklaerung {
        color: #0f6fc5;
    }

    .popover_erklaerung:hover {
        color: #0a477e;
        text-decoration: underline;
    }

    .copytoclipboard {
        cursor: copy;
    }
</style>

<div id="oer-aufgabe-23_aufgabe1">
    <p>
        In der Abbildung sehen Sie einen Boxplot. <br />
        Bitte geben Sie eine Liste von mindestens acht unterschiedlichen reellen
        Zahlen an, sodass der Boxplot diesen Datensatz beschreibt. Klicken Sie
        dann auf "Prüfen".
    </p>
    <p>
        <i> Wenn Sie mit der Maus über die einzelnen Kennwerte des Boxplots
            fahren, werden deren Werte eingeblendet. Auf Touch-Screens müssen
            die Kennwerte angetippt werden.
        </i>
    </p>

    [[jsxgraph height='200px']]
        const boxplotColor = {#boxplot_aufgabenstellung#}; //Farbe des Boxplots
        const boxplot_height = 1.6; // Höhe des Boxplots
        const antennen_height = 0.8; // Höhe der Antennen des Boxplots

        const board = JXG.JSXGraph.initBoard(divid, {
            axis:true,
            boundingbox: [{#mini-0.2*ampl#}, 2, {#maxi+0.2*ampl#}, -2],
            showCopyright:false,
            showNavigation:false,
            zoom:{enabled:false},
            pan:{enabled:false},
            defaultAxes:{
                x:{lastArrow:false,
                    ticks:{drawZero:true}
                },
                y:{lastArrow:false,
                    visible:false,
                    ticks:{drawLabels:false, drawZero:true}
                }
            }
        });
        // Setze Hintergrundfarbe auf weiß:
        board.renderer.container.style.backgroundColor = '#fff';

        // Punkte zur Konstruktion der Box:
        const pol = board.create('point',[{#uquantil#},()=>boxplot_height/2],{
            visible:false,
            fixed:true
        });
        const pul = board.create('point',[{#uquantil#},()=>0-boxplot_height/2],{
            visible:false,
            fixed:true
        });
        const por = board.create('point',[{#oquantil#},()=>boxplot_height/2],{
            visible:false,
            fixed:true
        });
        const pur = board.create('point',[{#oquantil#},()=>0-boxplot_height/2],{
            visible:false,
            fixed:true
        });

        // === Linke Antenne ===
        const grenze_links_text = board.create('text',[
            {#antenne_links-1#},
            ()=>0+boxplot_height/2+0.4,
            ()=>'Linke Antenne = '+{#antenne_links#}
        ],{
            visible:false,
            fixed:true,
            color:boxplotColor
        });
        const grenze_links = board.create('segment',[
            [{#antenne_links#},()=>0-antennen_height/2],
            [{#antenne_links#},()=>0+antennen_height/2]
        ],{
            fixed:true,
            strokeWidth:3,
            strokeColor:boxplotColor
        });
            
        // Eventlistener für Maus-Hovering
        grenze_links.on('over', function(e){
            grenze_links_text.setAttribute({visible:true});
        });
        grenze_links.on('out', function(e){
            grenze_links_text.setAttribute({visible:false});
        });
        // Eventlistener für Touch
        let grenze_linksActive = false;
        grenze_links.on('down', function(e){
            if(grenze_linksActive){
                grenze_links_text.setAttribute({visible:false});
            } else{
                grenze_links_text.setAttribute({visible:true});
            }
            grenze_linksActive = !grenze_linksActive;
        });

        // === Rechte Antenne ===
        const grenze_rechts_text = board.create('text',[
            {#antenne_rechts-1#},
            ()=>0+boxplot_height/2+0.4,
            ()=>'Rechte Antenne = '+{#antenne_rechts#}
        ],{
            visible:false,
            fixed:true,
            color:boxplotColor
        });
        const grenze_rechts = board.create('segment',[
            [{#antenne_rechts#},()=>0-antennen_height/2],
            [{#antenne_rechts#},()=>0+antennen_height/2]
        ],{
            fixed:true,
            strokeWidth:3,
            strokeColor:boxplotColor
        });
        // Eventlistener für Maus-Hovering
        grenze_rechts.on('over', function(e){
            grenze_rechts_text.setAttribute({visible:true});
        });
        grenze_rechts.on('out', function(e){
            grenze_rechts_text.setAttribute({visible:false});
        });
        // Eventlistener für Touch
        const grenze_rechtsActive = false;
        grenze_rechts.on('down', function(e){
            if(grenze_rechtsActive){
                grenze_rechts_text.setAttribute({visible:false});
            } else{
                grenze_rechts_text.setAttribute({visible:true});
            }
            grenze_rechtsActive = !grenze_rechtsActive;
        });

        // === Grundlinien ===
        const grundlinie_links = board.create('segment',[
            [{#antenne_links#},0],
            [{#uquantil#},0]
        ],{
            fixed:true,
            strokeColor:boxplotColor,
            highlight:false
        });
        const grundlinie_rechts = board.create('segment',[
            [{#oquantil#},0],
            [{#antenne_rechts#},0]
        ],{
            fixed:true,
            strokeColor:boxplotColor,
            highlight:false
        });

        // === Median ===
        const median_text = board.create('text',[
            {#med-1#},
            ()=>0+boxplot_height/2+0.4,
            ()=>'Median ='+{#med#}
        ],{
            visible:false,
            fixed:true,
            color:boxplotColor
        });
        const median = board.create('segment',[
            [{#med#},()=>0-boxplot_height/2],
            [{#med#},()=>0+boxplot_height/2]
        ],{
            fixed:true,
            strokeColor:boxplotColor
        });
        // Eventlistener für Maus-Hovering
        median.on('over', function(e){
            median_text.setAttribute({visible:true});
        });
        median.on('out', function(e){
            median_text.setAttribute({visible:false});
        });
        // Eventlistener für Touch
        let medianActive = false;
        median.on('down', function(e){
            if(medianActive){
                median_text.setAttribute({visible:false});
            } else{
                median_text.setAttribute({visible:true});
            }
            medianActive = !medianActive;
        });

        // === Box ===
        const uquantil_text = board.create('text',[
            {#uquantil-1#},
            ()=>0+boxplot_height/2+0.4,
            ()=>'Unteres Quartil = '+{#uquantil#}
        ],{
            visible:false,
            fixed:true,
            color:boxplotColor
        });
        const oquantil_text = board.create('text',[
            {#oquantil-1#},
            ()=>0+boxplot_height/2+0.4,
            ()=>'Oberes Quartil = '+{#oquantil#}
        ],{
            visible:false,
            fixed:true,
            color:boxplotColor
        });
        const box = board.create('polygon',[pol,por,pur,pul],{
                fillColor:boxplotColor,
                highlight:false,
                borders:{strokeWidth:2, highlightStrokeColor:'grey', strokeColor:boxplotColor}
        });
        box.borders[2].setAttribute({highlight:false});
        box.borders[0].setAttribute({highlight:false});
        // Eventlistener für Mouse-Hovering
        box.borders[3].on('over', function(e){
            uquantil_text.setAttribute({visible:true});
        });
        box.borders[3].on('out', function(e){
            uquantil_text.setAttribute({visible:false});
        });
        // Eventlistener für Touch
        let uquantilActive = false;
        box.borders[3].on('down', function(e){
            if(uquantilActive){
                uquantil_text.setAttribute({visible:false});
            } else{
                uquantil_text.setAttribute({visible:true});
            }
            uquantilActive = !uquantilActive;
        });
        // Eventlistener für Mouse-Hovering
        box.borders[1].on('over', function(e){
            oquantil_text.setAttribute({visible:true});
        });
        box.borders[1].on('out', function(e){
            oquantil_text.setAttribute({visible:false});
        });
        // Eventlistener für Touch
        let oquantilActive = false;
        box.borders[1].on('down', function(e){
            if(oquantilActive){
                oquantil_text.setAttribute({visible:false});
            } else{
                oquantil_text.setAttribute({visible:true});
            }
            oquantilActive = !oquantilActive;
        });
    [[/jsxgraph]]

    <p>Antwort:</p>
    <div id="oer-aufgabe-23_stack_input1">
        [[input:ans1]] [[validation:ans1]]
    </div>

    <!-- Kopie der ersten Antwort -->
    <div id="oer-aufgabe-23_stack_input1_copy" style="display: none">
        [[input:ans1_copy]] [[validation:ans1_copy]]
    </div>

    <p>
        <i>Hinweis: Bitte geben Sie die Liste mit eckigen Klammern an, z. B.</i>
        <code>[1,2,3]</code>
    </p>
</div>

<div id="oer-aufgabe-23_aufgabe1_prt">[[feedback:prt1]]</div>

<div id="oer-aufgabe-23_weiterfuehrende_aufgabe" style="display: none">
    <br />
    <br />
    <p>
        Oben sehen Sie, welche Kennwerte des
        <span class="oer-aufgabe-23_farbe_oben">Boxplots aus Ihrem Datensatz</span>
        nicht mit denen des
        <span class="oer-aufgabe-23_farbe_unten">Boxplots aus der Aufgabenstellung</span>
        übereinstimmen.
    </p>
    <p>
        Lesen Sie nun in der Grafik die Werte beider Boxplots ab, die nicht
        übereinstimmen. Füllen Sie dann die folgende Tabelle aus:
    </p>

    <div id="oer-aufgabe-23_tabelle_vergleich">
        <div style="overflow-x: auto">
            <table class="table table-primary" style="width: auto">
                <thead>
                    <tr>
                        <th scope="col">Kennziffer</th>
                        <th scope="col">Boxplot aus Ihrem Datensatz</th>
                        <th scope="col">Boxplot aus der Aufgabenstellung</th>
                    </tr>
                </thead>
                <tr id="oer-aufgabe-23_zeile_antenne_links">
                    <th>Linke Antenne</th>
                    <td>
                        <span id="oer-aufgabe-23_antenne_links_antwort">[[input:ans3]]</span>
                        [[validation:ans3]]
                    </td>
                    <td>
                        <span id="oer-aufgabe-23_antenne_links_aufgabe">[[input:ans2]]</span>
                        [[validation:ans2]]
                    </td>
                </tr>
                <tr id="oer-aufgabe-23_zeile_uquartil">
                    <th>Unteres Quartil</th>
                    <td>
                        <span id="oer-aufgabe-23_uquartil_antwort">[[input:ans5]]</span>
                        [[validation:ans5]]
                    </td>
                    <td>
                        <span id="oer-aufgabe-23_uquartil_aufgabe">[[input:ans4]]</span>
                        [[validation:ans4]]
                    </td>
                </tr>
                <tr id="oer-aufgabe-23_zeile_median">
                    <th>Median</th>
                    <td>
                        <span id="oer-aufgabe-23_median_antwort">[[input:ans7]]</span>
                        [[validation:ans7]]
                    </td>
                    <td>
                        <span id="oer-aufgabe-23_median_aufgabe">[[input:ans6]]</span>
                        [[validation:ans6]]
                    </td>
                </tr>
                <tr id="oer-aufgabe-23_zeile_oquartil">
                    <th>Oberes Quartil</th>
                    <td>
                        <span id="oer-aufgabe-23_oquartil_antwort">[[input:ans9]]</span>
                        [[validation:ans9]]
                    </td>
                    <td>
                        <span id="oer-aufgabe-23_oquartil_aufgabe">[[input:ans8]]</span>
                        [[validation:ans8]]
                    </td>
                </tr>
                <tr id="oer-aufgabe-23_zeile_antenne_rechts">
                    <th>Rechte Antenne</th>
                    <td>
                        <span id="oer-aufgabe-23_antenne_rechts_antwort">[[input:ans11]]</span>
                        [[validation:ans11]]
                    </td>
                    <td>
                        <span id="oer-aufgabe-23_antenne_rechts_aufgabe">[[input:ans10]]</span>
                        [[validation:ans10]]
                    </td>
                </tr>
            </table>
        </div>
        <p>Bitte klicken Sie nach dem Ausfüllen auf "Prüfen".</p>
    </div>
    <div id="oer-aufgabe-23_prt_vergleichen">[[feedback:prt_vergleichen]]</div>
</div>

<div id="oer-aufgabe-23_neuer_versuch" style="display: none">
    <p>
        Bitte versuchen Sie nun erneut, einen Datensatz anzugeben, der zu dem
        gegebenen Boxplot passt. Klicken Sie dann auf "Prüfen".
    </p>
    <p>
        Sie können als Ausgangspunkt Ihren ursprünglichen Datensatz nutzen.
        Schauen Sie auch in die Grafik, in der der Boxplot aus der
        Aufgabenstellung und der Boxplot aus Ihrer ersten Antwort zu sehen sind.
    </p>

    <p>Antwort:</p>
    <div id="oer-aufgabe-23_stack_input1_neu">
        [[input:ans1_neu]] [[validation:ans1_neu]]
    </div>
    <p>
        <i>Hinweis: Bitte geben Sie die Liste mit eckigen Klammern an, z. B. </i
        ><code>[1,2,3]</code>
    </p>
    [[feedback:prt1_neu]]
</div>

<script>
    /* Event-Listener: Antwort aus Eingabefeld ans1 wird autoamtisch in Eingabefeld ans1_copy übertragen */
    document
        .querySelector("#oer-aufgabe-23_stack_input1_neu > input")
        .addEventListener("input", (event) => {
            document.querySelector(
                "#oer-aufgabe-23_stack_input1 > input"
            ).value = document.querySelector(
                "#oer-aufgabe-23_stack_input1_neu > input"
            ).value;
        });

    document
        .querySelector("#oer-aufgabe-23_stack_input1 > input")
        .addEventListener("input", (event) => {
            document.querySelector(
                "#oer-aufgabe-23_stack_input1_copy > input"
            ).value = document.querySelector(
                "#oer-aufgabe-23_stack_input1 > input"
            ).value;
        });

    // Funktion, um einen String in die Zwischenablage zu kopieren
    function copyToClipboard(text) {
        let textArea;
        try {
            // Try using the Asynchronous Clipboard API
            navigator.clipboard.writeText(text);
        } catch (err) {
            // Fallback to the document.execCommand method
            textArea = document.createElement("textarea");
            textArea.value = text;
            document.body.appendChild(textArea);
            textArea.focus();
            textArea.select();
            document.execCommand("copy");
            document.body.removeChild(textArea);
        }
    }
</script>
<script src="https://www.rub.de/ak-mathe-digital/stackselbstlern.js"></script>]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2023060500</text>
    </stackversion>
    <questionvariables>
      <text><![CDATA[/*
  Boxplot

  wurde entwickelt von
  
    Jonas Lache <jonas.lache[at]ruhr-uni-bochum.de>

  an der Ruhr-Universität Bochum.

  Dieses Werk ist lizenziert unter einer Creative Commons
  Namensnennung-Weitergabe unter gleichen Bedingungen 4.0 International
  Lizenz. Um eine Kopie der Lizenz zu erhalten, besuchen Sie
  http://creativecommons.org/licenses/by-sa/4.0/.

  SPDX-License-Identifier: CC-BY-SA-4.0

  Technische Informationen:

  Diese Aufgabe bindet das Skript ‘stackselbstlern.js’ von Michael
  Kallweit für die Aufgabennavigation ein.

  Diese Aufgabe ist ursprünglich im Landesportal ORCA.nrw
  erschienen:
  https://www.twillo.de/edu-sharing/components/render/e80c5ca0-c53d-45fc-b2c2-4e34b85f2e0e

  Bei der vorliegenden Version handelt es sich um eine von Jonas Lache
  an der Hochschule Ruhr West bearbeitete Version (letzte Änderung: 01.02.2024).
*/

/*Global festgelegte Farben für die Grafiken. Sie können bei Bedarf hier geändert werden:*/
boxplot_aufgabenstellung: "rgb(0, 0, 187)"; /*dunkelblau*/
boxplot_antwort_1: "rgb(93, 51, 13)"; /*braun*/
boxplot_antwort_2: "rgb(173, 109, 235)"; /*lila*/
datenpunkte: "red";
label_background: "white";

/*Funktion für die Berechnung des Medians.*/
median1(L):=if oddp(length(L)) then L[(length(L)+1)/2] else (L[length(L)/2]+L[length(L)/2+1])/2;

/*Funktion für die Berechnung von p-Quantilen. Bitte ggf. durch die Definition ersetzen, die Ihre Studierenden kennen. */
pquantil(L,p):=if integerp(p*length(L)) then 1/2*(L[length(L)*p]+L[length(L)*p+1]) else L[floor(length(L)*p+1)]; 

/*Funktion für die Erzeugung einer Liste ohne doppelte Werte:*/
unique_list(min,max,anzahl):= block([L],
    L:[],
    for i:1 thru anzahl do(
        L: cons(rand_with_prohib(min,max,L),L)
    ),
    return(L)
);

/*Gibt true zurück, wenn in der Liste "L" ein Ausreißer enthalten ist.*/
ausreisserp(L):= is(length(sublist(L,lambda([x],x<pquantil(L,1/4)-3/2*(pquantil(L,3/4)-pquantil(L,1/4)))))>0) or is(length(sublist(L,lambda([x],x>pquantil(L,3/4)+3/2*(pquantil(L,3/4)-pquantil(L,1/4)))))>0); 

/*Sortierte eindeutige Liste ohne Ausreißer*/
L1: block(
     [L,uquantil,oquantil,IQR,ausreisser_unten,ausreisser_oben],
     L: sort(unique_list(1,30,10)),
     while(ausreisserp(L)) do L: sort(unique_list(1,30,10)),
     return(L)
);

/*Wandelt die Punkte aus L1 in Punkte um (für die Grafik)*/
Lpunkte: makelist([L1[k],0],k,1,length(L1));

/*Kennwerte:*/
med: median1(L1);
uquantil: pquantil(L1,1/4);
oquantil: pquantil(L1,3/4);
IQR: oquantil-uquantil;
mini: lmin(L1);
maxi: lmax(L1);

/* Antennen des Boxplots (da keine Ausreißer existieren): */
antenne_rechts: maxi;
antenne_links: mini;

/*Arithmetisches Mittel der Liste L1:*/
arit_ans: apply("+",L1)/length(L1);

/*Spannweite/Amplitude von L1:*/
ampl: maxi-mini;

/*Liste mit den Kennwerten:*/
list_indicators: [antenne_links, uquantil, med, oquantil, antenne_rechts];]]></text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text>Kenngrößen = {@[antenne_links,uquantil,med,oquantil,antenne_rechts]@}</text>
    </questionnote>
    <questiondescription format="html">
      <text></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> Richtige Antwort, gut gemacht!]]></text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text><![CDATA[<span style="font-size: 1.5em; color:orange;"><i class="fa fa-adjust"></i></span> Ihre Antwort ist teilweise korrekt.]]></text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text><![CDATA[<span style="font-size: 1.5em; color:red;"><i class="fa fa-times"></i></span> Falsche Antwort.]]></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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>L1</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>1</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>1</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans10</name>
      <type>algebraic</type>
      <tans>maxi</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans11</name>
      <type>algebraic</type>
      <tans>maxi</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans1_copy</name>
      <type>algebraic</type>
      <tans>L1</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>0</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans1_neu</name>
      <type>algebraic</type>
      <tans>L1</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>1</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>1</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans2</name>
      <type>algebraic</type>
      <tans>mini</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans3</name>
      <type>algebraic</type>
      <tans>mini</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans4</name>
      <type>algebraic</type>
      <tans>uquantil</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans5</name>
      <type>algebraic</type>
      <tans>uquantil</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans6</name>
      <type>algebraic</type>
      <tans>med</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans7</name>
      <type>algebraic</type>
      <tans>med</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans8</name>
      <type>algebraic</type>
      <tans>oquantil</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <input>
      <name>ans9</name>
      <type>algebraic</type>
      <tans>oquantil</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>3</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text><![CDATA[/*
=== Bedeutung der Knoten: ===
1. Ist die Antwort eine Liste?
2. Sind die angegebenen Werte alle unterschiedlich?
3. Sind nur Zahlen dabei, mit denen JSXGraph was anfangen kann? (kein pi, e, sqrt(),...)
4. Wurde eine Liste mit den Kenngrößen eingegeben?
5. Ist die Länge der Liste in Ordnung? (Und Wiederholung des Datensatzes aus ans1)
6. Ist die gesamte Aufgabe richtig? (Für grafisches Feedback)
7. Stimmt die linke Antenne?
8. Stimmt das untere Quartil?
9. Stimmt der Median?
    10. Falls nein: Stimmt vielleicht das arithmetische Mittel von ans1 mit dem Median des gegebenen Box-Plots überein?
11. Stimmt das obere Quartil?
12. Stimmt die rechte Antenne?
13. Ist die Anzahl der oberen Ausreißer gleich null?
    14: Falls 13=false: Entspricht der obere Ausreißer denn der rechten Antenne des Boxplots aus der Aufgabenstellung?
15. Ist die Anzahl der unteren Ausreißer gleich null?
    16: Falls 15=false: Entspricht der untere Ausreißer denn der linken Antenne des Boxplots aus der Aufgabenstellung?
17. Für "Weiter"-Button
*/

/*Sortierte Liste mit den Datenwerten aus der Antwort:*/
L2: sort(float(map(fullratsimp,ans1))); 

/*Datenwerte als Punkte:*/
anspunkte: makelist([L2[k],3],k,1,length(L2)); 

/*Kennwerte aus der Antwort:*/
mini_ans: lmin(L2); /*Minimum des Boxplots aus der Antwort*/
maxi_ans: lmax(L2); /*Maximum des Boxplots aus der Antwort*/
med_ans: median1(L2); /*Median des Boxplots aus der Antwort*/
arit_ans: apply("+",L2)/length(L2); /*arithmetisches Mittel des Boxplots aus der Antwort*/
ampl_ans: maxi_ans-mini_ans; /*Spannweite des Boxplots aus der Antwort*/
uquantil_ans: pquantil(L2,1/4); /*Unteres Quartil des Boxplots aus der Antwort*/
oquantil_ans: pquantil(L2,3/4); /*Oberes Quartil des Boxplots aus der Antwort*/
IQR_ans: oquantil_ans-uquantil_ans; /*IQR des Boxplots aus der Antwort*/

/*Untere und obere Ausreißer des Boxplots aus der Antwort:*/
ausreisser_unten_liste_ans: sublist(L2,lambda([x],x<uquantil_ans-3/2*IQR_ans)); 
ausreisser_oben_liste_ans: sublist(L2,lambda([x],x>oquantil_ans+3/2*IQR_ans));

/*Ausreißer des Boxplots aus der Antwort oben und unten (Punkte)*/
ausreisser_punkte_ans: block([L], 
  L:[],
  if not(ausreisser_oben_liste_ans=[]) then L:cons([last(L2),3],L), /*fügt L oberen Ausreißer hinzu, wenn es einen gibt*/
  if not(ausreisser_unten_liste_ans=[]) then L:cons([first(L2),3],L), /*fügt L unteren Ausreißer hinzu, wenn es einen gibt*/
    return(L)
);

/*Nur die x-Werte der Punkte:*/
ausreisser_punkte_x_ans: makelist(ausreisser_punkte_ans[k][1],k,1,length(ausreisser_punkte_ans));

/* Bestimmt, ob es einen oberen/unteren Ausreißer gibt und legt dadurch fest,
was die obere/untere Antenne des Boxplots aus der Antwort ist: */
antenne_rechts_ans: if ausreisser_oben_liste_ans=[] then last(L2) else lmax(sublist(L2, lambda([x],x<=oquantil_ans+3/2*IQR_ans)));
antenne_links_ans: if ausreisser_unten_liste_ans=[] then first(L2) else lmin(sublist(L2, lambda([x],x>=uquantil_ans-3/2*IQR_ans)));

/*Globales Minimum, Maximum und globale Spannweite für die Bondingbox des Boards*/
mini_global: min(mini,mini_ans);
maxi_global: max(maxi,maxi_ans);
ampl_global: max(ampl,ampl_ans);

/*Strings für den Feedbacktext zu Ausreißern in der Antwort*/
ausreisser_oben_wert_ans: if length(ausreisser_oben_liste_ans)>0 then last(ausreisser_oben_liste_ans) else "keiner";
ausreisser_unten_wert_ans: if length(ausreisser_unten_liste_ans)>0 then first(ausreisser_unten_liste_ans) else "keiner";

/*Liste mit Werten, die Studierende genannt haben, die keine reellen Zahlen sind.*/
enthaltene_strings: sublist(L2,lambda([x], stringp(x)));
L2_ohne_strings: sublist(L2,lambda([y],not(stringp(y))));
sonstige_verbotene_zahlen: sublist(L2_ohne_strings,lambda([x],
        not(constantp(x)) or imagpart(x)#0 or setp(x) or listp(x)
    )
);
verboteneZahlen: append(enthaltene_strings,sonstige_verbotene_zahlen);

/*Überprüfen, ob die extremsten Ausreißer mit der Antenne des Boxplots aus der Aufgabenmstellung übereinstimmt (orangene Hilfslinien)*/
ausreisser_oben_orange: if is(ausreisser_oben_wert_ans="keiner") then false else is(abs(ausreisser_oben_wert_ans-antenne_rechts)<0.00001);
ausreisser_unten_orange: if is(ausreisser_unten_wert_ans="keiner") then false else is(abs(ausreisser_unten_wert_ans-antenne_links)<0.00001);]]></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>listp(ans1)</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>=</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Ihre eingegebene Antwort ist keine Liste in der Form <code>[a,b,c,...]</code></p>
<p>Bitte geben Sie eine Liste an und klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>1</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(ans1)</sans>
        <tans>length(unique(ans1))</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>2</truenextnode>
        <trueanswernote>prt1-2-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-2-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Ihre Liste sollte nur unterschiedliche Werte enthalten</p>
<p>Bitte geben Sie eine Liste unterschiedlicher Werte an und klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>10</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>oquantil_ans</sans>
        <tans>oquantil</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2</truescore>
        <truepenalty></truepenalty>
        <truenextnode>11</truenextnode>
        <trueanswernote>prt1-11-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Das <b>obere Quartil</b> ist derjenige Wert aus dem Datensatz, für den gilt, dass 75 % aller Werte kleiner als dieser oder gleich diesem sind. Analog zum Median kann auch hier eine Mittelwertbildung stattfinden.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Oberes Quartil</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>11</falsenextnode>
        <falseanswernote>prt1-11-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Das <b>obere Quartil</b> ist derjenige Wert aus dem Datensatz, für den gilt, dass 75 % aller Werte kleiner als dieser oder gleich diesem sind. Analog zum Median kann auch hier eine Mittelwertbildung stattfinden.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Oberes Quartil</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
</div>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>11</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>antenne_rechts_ans</sans>
        <tans>antenne_rechts</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2</truescore>
        <truepenalty></truepenalty>
        <truenextnode>12</truenextnode>
        <trueanswernote>prt1-12-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Die <b>rechte Antenne</b> erstreckt sich nach rechts zum größten Wert des Datensatzes, der höchstens 1,5 Interquartilsabstände vom Kasten entfernt ist.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Rechte Antenne</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>12</falsenextnode>
        <falseanswernote>prt1-12-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Die <b>rechte Antenne</b> erstreckt sich nach rechts zum größten Wert des Datensatzes, der höchstens 1,5 Interquartilsabstände vom Kasten entfernt ist.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Rechte Antenne</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
</div>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>12</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(ausreisser_oben_liste_ans)</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>14</truenextnode>
        <trueanswernote>prt1-13-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.1</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>13</falsenextnode>
        <falseanswernote>prt1-13-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<br>
<p><span style="font-size: 1em; color:red;"><i class="fa fa-exclamation"></i></span> Im Boxplot aus der Aufgabenstellung ist kein maximaler Wert als Ausreißer eingezeichnet. Der Boxplot, der sich aus Ihren Daten ergibt, hat aber einen solchen Wert.</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>13</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ausreisser_oben_orange</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>14</truenextnode>
        <trueanswernote>prt1-14-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Der obere Ausreißer aus Ihrem Datensatz stammt aber mit der rechten Antenne des Boxplots aus der Aufgabenstellung überein (in der Grafik durch <span style="color:orange">gelbe</span> durchgezogene Hilfslinien dargestellt).</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>14</falsenextnode>
        <falseanswernote>prt1-14-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>14</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(ausreisser_unten_liste_ans)</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>16</truenextnode>
        <trueanswernote>prt1-15-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.1</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>15</falsenextnode>
        <falseanswernote>prt1-15-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p><span style="font-size: 1em; color:red;"><i class="fa fa-exclamation"></i></span> Im Boxplot aus der Aufgabenstellung ist kein minimaler Wert als Ausreißer eingezeichnet. Der Boxplot, der sich aus Ihren Daten ergibt, hat aber einen solchen Wert.</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>15</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ausreisser_unten_orange</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>16</truenextnode>
        <trueanswernote>prt1-16-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Der untere Ausreißer aus Ihrem Datensatz stammt aber mit der linken Antenne des Boxplots aus der Aufgabenstellung überein (in der Grafik durch <span style="color:orange">gelbe</span> durchgezogene Hilfslinien dargestellt).</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>16</falsenextnode>
        <falseanswernote>prt1-16-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>16</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>[antenne_links_ans, antenne_rechts_ans, med_ans, uquantil_ans, oquantil_ans]</sans>
        <tans>[antenne_links, antenne_rechts, med, uquantil, oquantil]</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-17-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[[[ if test='is(length(ausreisser_unten_liste_ans)#0 or length(ausreisser_oben_liste_ans)#0)' ]]


<div id="oer-aufgabe-23_weiter">
    <hr>
    <p>Bitte klicken Sie auf den folgenden Button um fortzufahren: <button type="button" class="buttonweiter" onclick="show('oer-aufgabe-23_neuer_versuch');hide('oer-aufgabe-23_weiter');">Weiter</button></p>
</div>
[[ else ]]
<hr>
<p>Herzlichen Glückwunsch, Sie sind am Ende der Aufgabe angelangt! Jetzt sollten Sie zu einem gegebenen Boxplot einen passenden Datensatz finden können.</p>
[[/ if ]]]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-17-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div id="oer-aufgabe-23_weiter">
    <hr>
    <p>Bitte klicken Sie auf den folgenden Button um fortzufahren: <button type="button" class="buttonweiter" onclick="show('oer-aufgabe-23_weiterfuehrende_aufgabe');hide('oer-aufgabe-23_weiter');">Weiter</button></p>
</div>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>2</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(verboteneZahlen)</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>3</truenextnode>
        <trueanswernote>prt1-3-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-3-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Ihr Datensatz enthält folgende Werte, die nicht ausgewertet werden konnten:</p>
\[ {@sequenceify(verboteneZahlen)@} \]
<p>Bitte geben Sie eine Liste reeller Zahlen an und klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>3</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>L2</sans>
        <tans>list_indicators</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-4-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Es sieht so aus, als hätten Sie die Kenngrößen bestimmt.</p>
<p>Bitte geben einen Datensatz an, der zu dem gegebenen Boxplot passt. Klicken Sie dann wieder auf "Prüfen".</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>4</falsenextnode>
        <falseanswernote>prt1-4-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>4</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans><![CDATA[is(length(ans1)>=8)]]></sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>5</truenextnode>
        <trueanswernote>prt1-5-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p><b>Sie haben folgenden Datensatz angegeben:</b> {@sequenceify(ans1)@} <button type="button" class="btn btn-link" style="padding:0" onclick="copyToClipboard('['+{#ans1#}+']')"><i class="icon fa fa-solid fa-clipboard fa-fw copytoclipboard" data-toggle="tooltip" data-placement="top" title="In die Zwischenablage kopieren"></i></button></p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-5-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Ihre Liste enthält weniger als acht Werte.</p>
<p>Bitte geben Sie eine Liste mit mindestens acht unterschiedlichen Werten an und klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>5</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>[mini_ans, maxi_ans, med_ans, uquantil_ans, oquantil_ans]</sans>
        <tans>[mini, maxi, med, uquantil, oquantil]</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>6</truenextnode>
        <trueanswernote>prt1-6-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<hr>
<p>In der folgenden Abbildung sehen Sie unten den <span style="color:{@boxplot_aufgabenstellung@}">in der Aufgabe gegebenen Boxplot</span>. Darüber sehen Sie die von Ihnen angegebenen Daten inkl. des <span style="color:{@boxplot_antwort_1@}">sich daraus ergebenen Boxplots</span> – wie Sie sehen stimmen die beiden überein.</p>

[[jsxgraph]]
JXG.Options.line.strokeWidth = 2;
JXG.Options.line.dash = 1;
JXG.Options.line.straightFirst = false;
JXG.Options.segment.dash = 0;

// Verwendete Farben:
const upperColor = {#boxplot_antwort_1#}; // Farbe des Boxplots aus der ersten Antwort
const lowerColor = {#boxplot_aufgabenstellung#}; //Farbe des unteren Boxplots aus der Aufgabenstellung
const datenpunkte_farbe = {#datenpunkte#}; // Farbe Datenpunkte erste Antwort
const labelBackgroundColor2 = {#label_background#};

// Ändert Schriftfarbe der "Legende"
document.querySelectorAll('.oer-aufgabe-23_farbe_oben').forEach(el=>el.style.color=upperColor);
document.querySelectorAll('.oer-aufgabe-23_farbe_unten').forEach(el=>el.style.color=lowerColor);

const boxplot_height = 1.2; // Höhe des Boxplots aus der Aufgabenstellung
const antennen_height = 0.6; // Höhe der Antennen des Boxplots aus der Aufgabenstellung

const achse2_y = 2; // y-Position der zweiten x-Achse (für den Boxplot aus der Antwort)
const boxplot_height_ans = 1.2; // Höhe des Boxplots aus der Antwort
const antennen_height_ans = 0.6; // Höhe der Antennen des Boxplots aus der Antwort

const datapoints_y = 2; // y-Position der Datenpunkte

const ende_hilfslinien = -1.3; // Unteres Ende der Hilfslinien

const highest_position = Math.max(achse2_y+0.5*boxplot_height+0.4, datapoints_y+0.4);

const mini_global = {#float(mini_global)#};
const ampl_global = {#float(ampl_global)#};
const maxi_global = {#float(maxi_global)#};
const uquantil_ans = {#float(uquantil_ans)#};
const oquantil_ans = {#float(oquantil_ans)#};
const antenne_links_ans = {#float(antenne_links_ans)#};
const antenne_rechts_ans = {#float(antenne_rechts_ans)#};
const med_ans = {#float(med_ans)#};
const ausreisser_x_array = {#float(ausreisser_punkte_x_ans)#};
const datapoints_x_array = {#float(L2)#};
const uquantil = {#float(uquantil)#};
const oquantil = {#float(oquantil)#};
const antenne_links = {#float(antenne_links)#};
const antenne_rechts = {#float(antenne_rechts)#};
const med = {#float(med)#}
const ausreisser_oben_wert_ans = {#float(ausreisser_oben_wert_ans)#};
const ausreisser_unten_wert_ans = {#float(ausreisser_unten_wert_ans)#}; 

const board = JXG.JSXGraph.initBoard(divid, {
    axis:true,
    boundingbox: [mini_global-0.25*ampl_global, highest_position+0.5, maxi_global+0.2*ampl_global, -2],
    showCopyright:false,
	showNavigation:false,
    defaultAxes:{
         x:{lastArrow:false,
             ticks:{drawZero:true}
         },
         y:{lastArrow:false,
             visible:false,
             ticks:{drawLabels:false, drawZero:true}
         }
     }
});
// Setze Hintergrundfarbe auf weiß:
board.renderer.container.style.backgroundColor = '#fff';

// === Anstatt der automatisch angezeigten Koordinaten für Punkte soll das Label in der Form "Wert = X" erscheinen ===
board.highlightInfobox = function(x,y,el) {
    this.infobox.setText('Wert = ' + x);
    this.infobox.rendNode.style.color = 'black';
    this.infobox.rendNode.style.padding = '5px';
    this.infobox.rendNode.style.backgroundColor = 'white';
};

// === Checkboxes ===
const checkbox = board.create('checkbox',[mini_global,-1.5, 'Zeige/verberge Datenpunkte'],{
   checked:true,
   fixed:true
});
const checkbox_Linien = board.create('checkbox',[mini_global,-1.8, 'Zeige/verberge Hilfslinien'],{
   checked:false,
   fixed:true
});

// ====================================================
// ================ Boxplot aus der Antwort ===========
// ====================================================
// === Beschriftung oberer Boxplot ===
const beschriftung_ans = board.create('text',[
   board.getBoundingBox()[0],
   achse2_y,
   'Boxplot<br>aus Ihrer<br>Antwort'
],{
   fixed:true,
   color:upperColor,
   highlight:false
});
beschriftung_ans.rendNode.style.background=labelBackgroundColor2;
beschriftung_ans.rendNode.style.padding="3px";

// === Obere Achse ===
const achse2 = board.create('axis', [[0, achse2_y], [1, achse2_y]],{ticks:{drawLabels:false}, lastArrow:false});

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const polans = board.create('point',[
   uquantil_ans,
   ()=>achse2_y+boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const pulans = board.create('point',[
   uquantil_ans,
   ()=>achse2_y-boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const porans = board.create('point',[
   oquantil_ans,
   ()=>achse2_y+boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const purans = board.create('point',[
   oquantil_ans,
   ()=>achse2_y-boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_ans_text = board.create('text',[
   antenne_links_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Linke Antenne = '+antenne_links_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_links_ans = board.create('segment',[
   [antenne_links_ans, ()=>achse2_y-antennen_height_ans/2],
   [antenne_links_ans, ()=>achse2_y+antennen_height_ans/2]
],{
    fixed:true,
    strokeWidth:3,
    strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_links_ans.on('over', function(e){
    grenze_links_ans_text.setAttribute({visible:true});
});
grenze_links_ans.on('out', function(e){
    grenze_links_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_links_ansActive = false;
grenze_links_ans.on('down', function(e){
    if(grenze_links_ansActive){
        grenze_links_ans_text.setAttribute({visible:false});
    } else{
        grenze_links_ans_text.setAttribute({visible:true});
    }
    grenze_links_ansActive = !grenze_links_ansActive;
});

// === Rechte Antenne ===
const grenze_rechts_ans_text = board.create('text',[
   antenne_rechts_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_rechts_ans = board.create('segment',[
   [antenne_rechts_ans, ()=>achse2_y-antennen_height_ans/2],
   [antenne_rechts_ans, ()=>achse2_y+antennen_height_ans/2]
],{
    fixed:true,
    strokeWidth:3,
    strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts_ans.on('over', function(e){
    grenze_rechts_ans_text.setAttribute({visible:true});
});
grenze_rechts_ans.on('out', function(e){
    grenze_rechts_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechts_ansActive = false;
grenze_rechts_ans.on('down', function(e){
    if(grenze_rechts_ansActive){
        grenze_rechts_ans_text.setAttribute({visible:false});
    } else{
        grenze_rechts_ans_text.setAttribute({visible:true});
    }
    grenze_rechts_ansActive = !grenze_rechts_ansActive;
});

// === Grundlinien ===
const grundlinie_links_ans = board.create('segment',[
   [antenne_links_ans,achse2_y],
   [uquantil_ans,achse2_y]
],{
   fixed:true,
   strokeColor:upperColor,
   highlight:false
});
const grundlinie_rechts_ans = board.create('segment',[
   [oquantil_ans,achse2_y],
   [antenne_rechts_ans,achse2_y]
],{
   fixed:true,
   strokeColor:upperColor,
   highlight:false
});

// === Median ===
const median_ans_text = board.create('text',[
   med_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Median = '+med_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
var median_ans = board.create('segment',[
   [med_ans, ()=>achse2_y-boxplot_height_ans/2],
   [med_ans, ()=>achse2_y+boxplot_height_ans/2]
],{
   fixed:true,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
median_ans.on('over', function(e){
    median_ans_text.setAttribute({visible:true});
});
median_ans.on('out', function(e){
    median_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let median_ansActive = false;
median_ans.on('down', function(e){
    if(median_ansActive){
        median_ans_text.setAttribute({visible:false});
    } else{
        median_ans_text.setAttribute({visible:true});
    }
    median_ansActive = !median_ansActive;
});

// === Box ===
const uquantil_ans_text = board.create('text',[
   uquantil_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Unteres Quartil = '+uquantil_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const oquantil_ans_text = board.create('text',[
   oquantil_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Oberes Quartil = '+oquantil_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const box_ans = board.create('polygon',[polans,porans,purans,pulans],{
   fillColor:upperColor,
   highlight:false,
   borders:{strokeWidth:2, strokeColor:upperColor, highlightStrokeColor:'grey'}
});
box_ans.borders[2].setAttribute({highlight:false});
box_ans.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box_ans.borders[3].on('over', function(e){
    uquantil_ans_text.setAttribute({visible:true});
});
box_ans.borders[3].on('out', function(e){
    uquantil_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantil_ansActive = false;
box_ans.borders[3].on('down', function(e){
    if(uquantil_ansActive){
        uquantil_ans_text.setAttribute({visible:false});
    } else{
        uquantil_ans_text.setAttribute({visible:true});
    }
    uquantil_ansActive = !uquantil_ansActive;
});
// Eventlistener für Mouse-Hovering
box_ans.borders[1].on('over', function(e){
    oquantil_ans_text.setAttribute({visible:true});
});
box_ans.borders[1].on('out', function(e){
    oquantil_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantil_ansActive = false;
box_ans.borders[1].on('down', function(e){
    if(oquantil_ansActive){
        oquantil_ans_text.setAttribute({visible:false});
    } else{
        oquantil_ans_text.setAttribute({visible:true});
    }
    oquantil_ansActive = !oquantil_ansActive;
});

// === Ausreißer-Punkte ===
for(let j of ausreisser_x_array){
   board.create('point',[j,achse2_y],{
    fixed:true,
    withLabel:false,
    color:upperColor,
    showInfobox:false
   })
};

// === Datenpunkte ===
for(let j of datapoints_x_array){board.create('point',[j, datapoints_y],{
   withLabel:false,
   fixed:true,
   face:'x',
   visible:function(){return checkbox.Value()},
   color:datenpunkte_farbe
}) };

// ====================================================
// ============= Boxplot aus der Aufgabenstellung =============
// ====================================================

// === Beschriftung unterer Boxplot ===
const beschriftung_aufg = board.create('text',[
   board.getBoundingBox()[0],
   0,
   'Boxplot<br>aus der<br>Aufgaben-<br>stellung'
],{
   fixed:true,
   color:lowerColor,
   highlight:false
});
beschriftung_aufg.rendNode.style.background=labelBackgroundColor2;
beschriftung_aufg.rendNode.style.padding="3px";

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const pol = board.create('point',[
   uquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pul = board.create('point',[
   uquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});
const por = board.create('point',[
   oquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pur = board.create('point',[
   oquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_text = board.create('text',[
   antenne_links-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Linke Antenne = '+antenne_links
],{
   visible:false,
   fixed:true,
   color:lowerColor});
const grenze_links = board.create('segment',[
   [antenne_links, ()=>0-antennen_height/2],
   [antenne_links, ()=>0+antennen_height/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_links.on('over', function(e){
    grenze_links_text.setAttribute({visible:true});
});
grenze_links.on('out', function(e){
    grenze_links_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_linksActive = false;
grenze_links.on('down', function(e){
    if(grenze_linksActive){
        grenze_links_text.setAttribute({visible:false});
    } else{
        grenze_links_text.setAttribute({visible:true});
    }
    grenze_linksActive = !grenze_linksActive;
});

// === Rechte Antenne ===
const grenze_rechts_text = board.create('text',[
   antenne_rechts-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const grenze_rechts = board.create('segment',[
   [antenne_rechts, ()=>0-antennen_height/2],
   [antenne_rechts, ()=>0+antennen_height/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts.on('over', function(e){
    grenze_rechts_text.setAttribute({visible:true});
});
grenze_rechts.on('out', function(e){
    grenze_rechts_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechtsActive = false;
grenze_rechts.on('down', function(e){
    if(grenze_rechtsActive){
        grenze_rechts_text.setAttribute({visible:false});
    } else{
        grenze_rechts_text.setAttribute({visible:true});
    }
    grenze_rechtsActive = !grenze_rechtsActive;
});

// === Grundlinien ===
const grundlinie_links = board.create('segment',[
   [antenne_links,0],
   [uquantil,0]
],{
   fixed:true,
   strokeColor:lowerColor,
   highlight:false
});
const grundlinie_rechts = board.create('segment',[
  [oquantil,0],
  [antenne_rechts,0
]],{
   fixed:true,
   strokeColor:lowerColor,
   highlight:false
});

// === Median ===
const median_text = board.create('text',[
   med-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Median ='+med
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const median = board.create('segment',[
   [med, ()=>0-boxplot_height/2],
   [med, ()=>0+boxplot_height/2]
],{
   fixed:true,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
median.on('over', function(e){
    median_text.setAttribute({visible:true});
});
median.on('out', function(e){
    median_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let medianActive = false;
median.on('down', function(e){
    if(medianActive){
        median_text.setAttribute({visible:false});
    } else{
        median_text.setAttribute({visible:true});
    }
    medianActive = !medianActive;
});

// === Box ===
const uquantil_text = board.create('text',[
   uquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Unteres Quartil = '+uquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const oquantil_text = board.create('text',[
   oquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Oberes Quartil = '+oquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
var box = board.create('polygon',[pol,por,pur,pul],{
    fillColor:lowerColor,
    highlight:false,
    borders:{strokeWidth:2, highlightStrokeColor:'grey', strokeColor:lowerColor}
});
box.borders[2].setAttribute({highlight:false});
box.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box.borders[3].on('over', function(e){
    uquantil_text.setAttribute({visible:true});
});
box.borders[3].on('out', function(e){
    uquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantilActive = false;
box.borders[3].on('down', function(e){
    if(uquantilActive){
        uquantil_text.setAttribute({visible:false});
    } else{
        uquantil_text.setAttribute({visible:true});
    }
    uquantilActive = !uquantilActive;
});
// Eventlistener für Mouse-Hovering
box.borders[1].on('over', function(e){
    oquantil_text.setAttribute({visible:true});
});
box.borders[1].on('out', function(e){
    oquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantilActive = false;
box.borders[1].on('down', function(e){
    if(oquantilActive){
        oquantil_text.setAttribute({visible:false});
    } else{
        oquantil_text.setAttribute({visible:true});
    }
    oquantilActive = !oquantilActive;
});

// ===================================================
// ===================== Hilfslinien: =====================
// ===================================================
const grenze_links_ans_linie = board.create('segment',[
   [antenne_links_ans,ende_hilfslinien],
   [antenne_links_ans, ()=>achse2_y-antennen_height/2]
],{
   fixed:true,
   color:()=>(antenne_links_ans==antenne_links) ? 'green' : ({#ausreisser_unten_orange and ausreisser_unten_wert_ans="keiner"#}) ? 'orange' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=>(antenne_links_ans==antenne_links) ? 2 : 1
});

const uquartil_linie = board.create('segment',[pulans,[uquantil_ans, ende_hilfslinien]],{
    fixed:true,
    color:()=> (polans.X()==pol.X()) ? 'green' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> (polans.X()==pol.X()) ? 2 : 1
});

const median_ans_linie = board.create('segment',[
   [med_ans, ()=>achse2_y-boxplot_height/2],
   [med_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>(med_ans==med) ? 'green' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (med_ans==med) ? 2 : 1
});

const oquartil_linie = board.create('segment',[
   purans,
   [oquantil_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=> (porans.X()==por.X()) ? 'green' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (porans.X()==por.X()) ? 2 : 1
});

const grenze_rechts_ans_linie = board.create('segment',[
   [antenne_rechts_ans,function(){return achse2_y-antennen_height/2}],
   [antenne_rechts_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>(antenne_rechts_ans==antenne_rechts) ? 'green' : ({#ausreisser_oben_orange and ausreisser_oben_wert_ans="keiner"#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (antenne_rechts_ans==antenne_rechts) ? 2 : 1
});

const ausreisser_rechts_linie = board.create('segment',[
   [ausreisser_oben_wert_ans,achse2_y],
   [ausreisser_oben_wert_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>({#ausreisser_oben_orange#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> ({#ausreisser_oben_orange#}) ? 0 : 1
});

const ausreisser_links_linie = board.create('segment',[
   [ausreisser_unten_wert_ans,achse2_y],
   [ausreisser_unten_wert_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>({#ausreisser_unten_orange#}) ? 'orange' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> ({#ausreisser_unten_orange#}) ? 0 : 1
});
[[/jsxgraph]]

<p><i>Wenn Sie mit der Maus über die einzelnen Kennwerte der beiden Boxplots fahren, werden deren Werte eingeblendet. Auf Touch-Screens müssen die Kennwerte angetippt werden.</i></p>

<p>Die <span style="color:green">grünen</span> gestrichelten Hilfslinien, die Sie mithilfe der Checkbox aktivieren können, zeigen Ihnen, dass die Kennwerte jeweils übereinstimmen.</p>
<hr>
<p>Die folgende Checkliste ist eine Übersicht über die Kennziffern der Boxplots. Die grünen Haken kennzeichnen, dass die jeweiligen Werte beider Boxplots übereinstimmen. Wenn Sie auf die Kenngrößen klicken, wird Ihnen eine Erklärung angezeigt.</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>6</falsenextnode>
        <falseanswernote>prt1-6-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<!-- HIER DIE GRAFIK -->
<hr>
<p>
In der folgenden Abbildung sehen Sie unten den <span style="color:{@boxplot_aufgabenstellung@}">in der Aufgabe gegebenen Boxplot</span>. Darüber sehen Sie die von Ihnen angegebenen Daten inkl. des <span style="color:{@boxplot_antwort_1@}">sich daraus ergebenen Boxplots</span>.

[[jsxgraph]]
JXG.Options.line.strokeWidth = 2;
JXG.Options.line.dash = 1;
JXG.Options.line.straightFirst = false;
JXG.Options.segment.dash = 0;

// Verwendete Farben:
const upperColor = {#boxplot_antwort_1#}; // Farbe des Boxplots aus der ersten Antwort
const lowerColor = {#boxplot_aufgabenstellung#}; //Farbe des unteren Boxplots aus der Aufgabenstellung
const datenpunkte_farbe = {#datenpunkte#}; // Farbe Datenpunkte erste Antwort
const labelBackgroundColor2 = {#label_background#};

// Ändert Schriftfarbe der "Legende"
document.querySelectorAll('.oer-aufgabe-23_farbe_oben').forEach(el=>el.style.color=upperColor);
document.querySelectorAll('.oer-aufgabe-23_farbe_unten').forEach(el=>el.style.color=lowerColor);

const boxplot_height = 1.2; // Höhe des Boxplots aus der Aufgabenstellung
const antennen_height = 0.6; // Höhe der Antennen des Boxplots aus der Aufgabenstellung

const achse2_y = 2; // y-Position der zweiten x-Achse (für den Boxplot aus der Antwort)
const boxplot_height_ans = 1.2; // Höhe des Boxplots aus der Antwort
const antennen_height_ans = 0.6; // Höhe der Antennen des Boxplots aus der Antwort

const datapoints_y = 2; // y-Position der Datenpunkte

const ende_hilfslinien = -1.3; // Unteres Ende der Hilfslinien

const highest_position = Math.max(achse2_y+0.5*boxplot_height+0.4, datapoints_y+0.4);

const mini_global = {#float(mini_global)#};
const ampl_global = {#float(ampl_global)#};
const maxi_global = {#float(maxi_global)#};
const uquantil_ans = {#float(uquantil_ans)#};
const oquantil_ans = {#float(oquantil_ans)#};
const antenne_links_ans = {#float(antenne_links_ans)#};
const antenne_rechts_ans = {#float(antenne_rechts_ans)#};
const med_ans = {#float(med_ans)#};
const ausreisser_x_array = {#float(ausreisser_punkte_x_ans)#};
const datapoints_x_array = {#float(L2)#};
const uquantil = {#float(uquantil)#};
const oquantil = {#float(oquantil)#};
const antenne_links = {#float(antenne_links)#};
const antenne_rechts = {#float(antenne_rechts)#};
const med = {#float(med)#}
const ausreisser_oben_wert_ans = {#float(ausreisser_oben_wert_ans)#};
const ausreisser_unten_wert_ans = {#float(ausreisser_unten_wert_ans)#}; 

const board = JXG.JSXGraph.initBoard(divid, {
    axis:true,
    boundingbox: [mini_global-0.25*ampl_global, highest_position+0.5, maxi_global+0.2*ampl_global, -2],
    showCopyright:false,
	showNavigation:false,
    defaultAxes:{
         x:{lastArrow:false,
             ticks:{drawZero:true}
         },
         y:{lastArrow:false,
             visible:false,
             ticks:{drawLabels:false, drawZero:true}
         }
     }
});
// Setze Hintergrundfarbe auf weiß:
board.renderer.container.style.backgroundColor = '#fff';

// === Anstatt der automatisch angezeigten Koordinaten für Punkte soll das Label in der Form "Wert = X" erscheinen ===
board.highlightInfobox = function(x,y,el) {
    this.infobox.setText('Wert = ' + x);
    this.infobox.rendNode.style.color = 'black';
    this.infobox.rendNode.style.padding = '5px';
    this.infobox.rendNode.style.backgroundColor = 'white';
};

// === Checkboxes ===
const checkbox = board.create('checkbox',[mini_global,-1.5, 'Zeige/verberge Datenpunkte'],{
   checked:true,
   fixed:true
});
const checkbox_Linien = board.create('checkbox',[mini_global,-1.8, 'Zeige/verberge Hilfslinien'],{
   checked:false,
   fixed:true
});

// ====================================================
// ================ Boxplot aus der Antwort ===========
// ====================================================
// === Beschriftung oberer Boxplot ===
const beschriftung_ans = board.create('text',[
   board.getBoundingBox()[0],
   achse2_y,
   'Boxplot<br>aus Ihrer<br>Antwort'
],{
   fixed:true,
   color:upperColor,
   highlight:false
});
beschriftung_ans.rendNode.style.background=labelBackgroundColor2;
beschriftung_ans.rendNode.style.padding="3px";

// === Obere Achse ===
const achse2 = board.create('axis', [[0, achse2_y], [1, achse2_y]],{ticks:{drawLabels:false}, lastArrow:false});

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const polans = board.create('point',[
   uquantil_ans,
   ()=>achse2_y+boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const pulans = board.create('point',[
   uquantil_ans,
   ()=>achse2_y-boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const porans = board.create('point',[
   oquantil_ans,
   ()=>achse2_y+boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const purans = board.create('point',[
   oquantil_ans,
   ()=>achse2_y-boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_ans_text = board.create('text',[
   antenne_links_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Linke Antenne = '+antenne_links_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_links_ans = board.create('segment',[
   [antenne_links_ans, ()=>achse2_y-antennen_height_ans/2],
   [antenne_links_ans, ()=>achse2_y+antennen_height_ans/2]
],{
    fixed:true,
    strokeWidth:3,
    strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_links_ans.on('over', function(e){
    grenze_links_ans_text.setAttribute({visible:true});
});
grenze_links_ans.on('out', function(e){
    grenze_links_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_links_ansActive = false;
grenze_links_ans.on('down', function(e){
    if(grenze_links_ansActive){
        grenze_links_ans_text.setAttribute({visible:false});
    } else{
        grenze_links_ans_text.setAttribute({visible:true});
    }
    grenze_links_ansActive = !grenze_links_ansActive;
});

// === Rechte Antenne ===
const grenze_rechts_ans_text = board.create('text',[
   antenne_rechts_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_rechts_ans = board.create('segment',[
   [antenne_rechts_ans, ()=>achse2_y-antennen_height_ans/2],
   [antenne_rechts_ans, ()=>achse2_y+antennen_height_ans/2]
],{
    fixed:true,
    strokeWidth:3,
    strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts_ans.on('over', function(e){
    grenze_rechts_ans_text.setAttribute({visible:true});
});
grenze_rechts_ans.on('out', function(e){
    grenze_rechts_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechts_ansActive = false;
grenze_rechts_ans.on('down', function(e){
    if(grenze_rechts_ansActive){
        grenze_rechts_ans_text.setAttribute({visible:false});
    } else{
        grenze_rechts_ans_text.setAttribute({visible:true});
    }
    grenze_rechts_ansActive = !grenze_rechts_ansActive;
});

// === Grundlinien ===
const grundlinie_links_ans = board.create('segment',[
   [antenne_links_ans,achse2_y],
   [uquantil_ans,achse2_y]
],{
   fixed:true,
   strokeColor:upperColor,
   highlight:false
});
const grundlinie_rechts_ans = board.create('segment',[
   [oquantil_ans,achse2_y],
   [antenne_rechts_ans,achse2_y]
],{
   fixed:true,
   strokeColor:upperColor,
   highlight:false
});

// === Median ===
const median_ans_text = board.create('text',[
   med_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Median = '+med_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
var median_ans = board.create('segment',[
   [med_ans, ()=>achse2_y-boxplot_height_ans/2],
   [med_ans, ()=>achse2_y+boxplot_height_ans/2]
],{
   fixed:true,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
median_ans.on('over', function(e){
    median_ans_text.setAttribute({visible:true});
});
median_ans.on('out', function(e){
    median_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let median_ansActive = false;
median_ans.on('down', function(e){
    if(median_ansActive){
        median_ans_text.setAttribute({visible:false});
    } else{
        median_ans_text.setAttribute({visible:true});
    }
    median_ansActive = !median_ansActive;
});

// === Box ===
const uquantil_ans_text = board.create('text',[
   uquantil_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Unteres Quartil = '+uquantil_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const oquantil_ans_text = board.create('text',[
   oquantil_ans-1,
   ()=>achse2_y+boxplot_height_ans/2+0.4,
   ()=>'Oberes Quartil = '+oquantil_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const box_ans = board.create('polygon',[polans,porans,purans,pulans],{
   fillColor:upperColor,
   highlight:false,
   borders:{strokeWidth:2, strokeColor:upperColor, highlightStrokeColor:'grey'}
});
box_ans.borders[2].setAttribute({highlight:false});
box_ans.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box_ans.borders[3].on('over', function(e){
    uquantil_ans_text.setAttribute({visible:true});
});
box_ans.borders[3].on('out', function(e){
    uquantil_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantil_ansActive = false;
box_ans.borders[3].on('down', function(e){
    if(uquantil_ansActive){
        uquantil_ans_text.setAttribute({visible:false});
    } else{
        uquantil_ans_text.setAttribute({visible:true});
    }
    uquantil_ansActive = !uquantil_ansActive;
});
// Eventlistener für Mouse-Hovering
box_ans.borders[1].on('over', function(e){
    oquantil_ans_text.setAttribute({visible:true});
});
box_ans.borders[1].on('out', function(e){
    oquantil_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantil_ansActive = false;
box_ans.borders[1].on('down', function(e){
    if(oquantil_ansActive){
        oquantil_ans_text.setAttribute({visible:false});
    } else{
        oquantil_ans_text.setAttribute({visible:true});
    }
    oquantil_ansActive = !oquantil_ansActive;
});

// === Ausreißer-Punkte ===
for(let j of ausreisser_x_array){
   board.create('point',[j,achse2_y],{
    fixed:true,
    withLabel:false,
    color:upperColor,
    showInfobox:false
   })
};

// === Datenpunkte ===
for(let j of datapoints_x_array){board.create('point',[j, datapoints_y],{
   withLabel:false,
   fixed:true,
   face:'x',
   visible:function(){return checkbox.Value()},
   color:datenpunkte_farbe
}) };

// ====================================================
// ============= Boxplot aus der Aufgabenstellung =============
// ====================================================

// === Beschriftung unterer Boxplot ===
const beschriftung_aufg = board.create('text',[
   board.getBoundingBox()[0],
   0,
   'Boxplot<br>aus der<br>Aufgaben-<br>stellung'
],{
   fixed:true,
   color:lowerColor,
   highlight:false
});
beschriftung_aufg.rendNode.style.background=labelBackgroundColor2;
beschriftung_aufg.rendNode.style.padding="3px";

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const pol = board.create('point',[
   uquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pul = board.create('point',[
   uquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});
const por = board.create('point',[
   oquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pur = board.create('point',[
   oquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_text = board.create('text',[
   antenne_links-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Linke Antenne = '+antenne_links
],{
   visible:false,
   fixed:true,
   color:lowerColor});
const grenze_links = board.create('segment',[
   [antenne_links, ()=>0-antennen_height/2],
   [antenne_links, ()=>0+antennen_height/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_links.on('over', function(e){
    grenze_links_text.setAttribute({visible:true});
});
grenze_links.on('out', function(e){
    grenze_links_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_linksActive = false;
grenze_links.on('down', function(e){
    if(grenze_linksActive){
        grenze_links_text.setAttribute({visible:false});
    } else{
        grenze_links_text.setAttribute({visible:true});
    }
    grenze_linksActive = !grenze_linksActive;
});

// === Rechte Antenne ===
const grenze_rechts_text = board.create('text',[
   antenne_rechts-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const grenze_rechts = board.create('segment',[
   [antenne_rechts, ()=>0-antennen_height/2],
   [antenne_rechts, ()=>0+antennen_height/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts.on('over', function(e){
    grenze_rechts_text.setAttribute({visible:true});
});
grenze_rechts.on('out', function(e){
    grenze_rechts_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechtsActive = false;
grenze_rechts.on('down', function(e){
    if(grenze_rechtsActive){
        grenze_rechts_text.setAttribute({visible:false});
    } else{
        grenze_rechts_text.setAttribute({visible:true});
    }
    grenze_rechtsActive = !grenze_rechtsActive;
});

// === Grundlinien ===
const grundlinie_links = board.create('segment',[
   [antenne_links,0],
   [uquantil,0]
],{
   fixed:true,
   strokeColor:lowerColor,
   highlight:false
});
const grundlinie_rechts = board.create('segment',[
  [oquantil,0],
  [antenne_rechts,0
]],{
   fixed:true,
   strokeColor:lowerColor,
   highlight:false
});

// === Median ===
const median_text = board.create('text',[
   med-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Median ='+med
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const median = board.create('segment',[
   [med, ()=>0-boxplot_height/2],
   [med, ()=>0+boxplot_height/2]
],{
   fixed:true,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
median.on('over', function(e){
    median_text.setAttribute({visible:true});
});
median.on('out', function(e){
    median_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let medianActive = false;
median.on('down', function(e){
    if(medianActive){
        median_text.setAttribute({visible:false});
    } else{
        median_text.setAttribute({visible:true});
    }
    medianActive = !medianActive;
});

// === Box ===
const uquantil_text = board.create('text',[
   uquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Unteres Quartil = '+uquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const oquantil_text = board.create('text',[
   oquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Oberes Quartil = '+oquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
var box = board.create('polygon',[pol,por,pur,pul],{
    fillColor:lowerColor,
    highlight:false,
    borders:{strokeWidth:2, highlightStrokeColor:'grey', strokeColor:lowerColor}
});
box.borders[2].setAttribute({highlight:false});
box.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box.borders[3].on('over', function(e){
    uquantil_text.setAttribute({visible:true});
});
box.borders[3].on('out', function(e){
    uquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantilActive = false;
box.borders[3].on('down', function(e){
    if(uquantilActive){
        uquantil_text.setAttribute({visible:false});
    } else{
        uquantil_text.setAttribute({visible:true});
    }
    uquantilActive = !uquantilActive;
});
// Eventlistener für Mouse-Hovering
box.borders[1].on('over', function(e){
    oquantil_text.setAttribute({visible:true});
});
box.borders[1].on('out', function(e){
    oquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantilActive = false;
box.borders[1].on('down', function(e){
    if(oquantilActive){
        oquantil_text.setAttribute({visible:false});
    } else{
        oquantil_text.setAttribute({visible:true});
    }
    oquantilActive = !oquantilActive;
});

// ===================================================
// ===================== Hilfslinien: =====================
// ===================================================
const grenze_links_ans_linie = board.create('segment',[
   [antenne_links_ans,ende_hilfslinien],
   [antenne_links_ans, ()=>achse2_y-antennen_height/2]
],{
   fixed:true,
   color:()=>(antenne_links_ans==antenne_links) ? 'green' : ({#ausreisser_unten_orange and ausreisser_unten_wert_ans="keiner"#}) ? 'orange' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=>(antenne_links_ans==antenne_links) ? 2 : 1
});

const uquartil_linie = board.create('segment',[pulans,[uquantil_ans, ende_hilfslinien]],{
    fixed:true,
    color:()=> (polans.X()==pol.X()) ? 'green' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> (polans.X()==pol.X()) ? 2 : 1
});

const median_ans_linie = board.create('segment',[
   [med_ans, ()=>achse2_y-boxplot_height/2],
   [med_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>(med_ans==med) ? 'green' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (med_ans==med) ? 2 : 1
});

const oquartil_linie = board.create('segment',[
   purans,
   [oquantil_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=> (porans.X()==por.X()) ? 'green' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (porans.X()==por.X()) ? 2 : 1
});

const grenze_rechts_ans_linie = board.create('segment',[
   [antenne_rechts_ans,function(){return achse2_y-antennen_height/2}],
   [antenne_rechts_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>(antenne_rechts_ans==antenne_rechts) ? 'green' : ({#ausreisser_oben_orange and ausreisser_oben_wert_ans="keiner"#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (antenne_rechts_ans==antenne_rechts) ? 2 : 1
});

const ausreisser_rechts_linie = board.create('segment',[
   [ausreisser_oben_wert_ans,achse2_y],
   [ausreisser_oben_wert_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>({#ausreisser_oben_orange#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> ({#ausreisser_oben_orange#}) ? 0 : 1
});

const ausreisser_links_linie = board.create('segment',[
   [ausreisser_unten_wert_ans,achse2_y],
   [ausreisser_unten_wert_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>({#ausreisser_unten_orange#}) ? 'orange' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> ({#ausreisser_unten_orange#}) ? 0 : 1
});
[[/jsxgraph]]

<script>
// ====================================================
// === Die Tabellenzeilen ausblenden, wo die Werte übereinstimmen ===
// ====================================================
document.addEventListener('DOMContentLoaded', function() {
    if({#antenne_links_ans#}=={#antenne_links#}){
        document.getElementById('oer-aufgabe-23_zeile_antenne_links').style.display="none";
        document.getElementById('oer-aufgabe-23_antenne_links_aufgabe').childNodes[0].value="{#antenne_links#}";
        document.getElementById('oer-aufgabe-23_antenne_links_antwort').childNodes[0].value="{#antenne_links#}";
    };
    if({#uquantil_ans#}=={#uquantil#}){
        document.getElementById('oer-aufgabe-23_zeile_uquartil').style.display="none";
        document.getElementById('oer-aufgabe-23_uquartil_aufgabe').childNodes[0].value="{#uquantil#}";
        document.getElementById('oer-aufgabe-23_uquartil_antwort').childNodes[0].value="{#uquantil#}";
    };
    if({#med_ans#}=={#med#}){
        document.getElementById('oer-aufgabe-23_zeile_median').style.display="none";
        document.getElementById('oer-aufgabe-23_median_aufgabe').childNodes[0].value="{#med#}";
        document.getElementById('oer-aufgabe-23_median_antwort').childNodes[0].value="{#med#}";
    };
    if({#oquantil_ans#}=={#oquantil#}){
        document.getElementById('oer-aufgabe-23_zeile_oquartil').style.display="none";
        document.getElementById('oer-aufgabe-23_oquartil_aufgabe').childNodes[0].value="{#oquantil#}";
        document.getElementById('oer-aufgabe-23_oquartil_antwort').childNodes[0].value="{#oquantil#}";
    };
    if({#antenne_rechts_ans#}=={#antenne_rechts#}){
        document.getElementById('oer-aufgabe-23_zeile_antenne_rechts').style.display="none";
        document.getElementById('oer-aufgabe-23_antenne_rechts_antwort').childNodes[0].value="{#antenne_rechts#}";
        document.getElementById('oer-aufgabe-23_antenne_rechts_aufgabe').childNodes[0].value="{#antenne_rechts#}";
    };

    // === Erste Aufgabe ausblenden ===
    hide('oer-aufgabe-23_aufgabe1');
  });
</script>

<p><i>Wenn Sie mit der Maus über die einzelnen Kennwerte der beiden Boxplots fahren, werden deren Werte eingeblendet. Auf Touch-Screens müssen die Kennwerte angetippt werden.</i></p>
<p>Die Hilfslinien, die Sie mithilfe der Checkbox aktivieren können, zeigen Ihnen, welche Kennwerte übereinstimmen (<span style="color:green">grüne</span> gestrichelte Hilfslinien) und welche nicht (<span style="color:red">rote</span> gepunktete Hilfslinien).</p>
<hr>
<p>In der folgenden Checkliste können Sie sehen, welche der Kennziffern übereinstimmen. Wenn Sie auf die Kenngrößen klicken, wird Ihnen eine Erklärung angezeigt.</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>6</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>antenne_links_ans</sans>
        <tans>antenne_links</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2</truescore>
        <truepenalty></truepenalty>
        <truenextnode>7</truenextnode>
        <trueanswernote>prt1-7-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Die <b>linke Antenne</b> erstreckt sich nach links zum kleinsten Wert des Datensatzes, der höchstens 1,5 Interquartilsabstände vom Kasten entfernt ist.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Linke Antenne</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>7</falsenextnode>
        <falseanswernote>prt1-7-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Die <b>linke Antenne</b> erstreckt sich nach links zum kleinsten Wert des Datensatzes, der höchstens 1,5 Interquartilsabstände vom Kasten entfernt ist.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Linke Antenne</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
</div>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>7</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>uquantil_ans</sans>
        <tans>uquantil</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2</truescore>
        <truepenalty></truepenalty>
        <truenextnode>8</truenextnode>
        <trueanswernote>prt1-8-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Das <b>untere Quartil</b> ist derjenige Wert aus dem Datensatz, für den gilt, dass 25 % aller Werte kleiner als dieser oder gleich diesem sind. Analog zum Median kann auch hier eine Mittelwertbildung stattfinden.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Unteres Quartil</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>8</falsenextnode>
        <falseanswernote>prt1-8-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Das <b>untere Quartil</b> ist derjenige Wert aus dem Datensatz, für den gilt, dass 25 % aller Werte kleiner als dieser oder gleich diesem sind. Analog zum Median kann auch hier eine Mittelwertbildung stattfinden.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Unteres Quartil</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i>
	</a></span>
</div>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>8</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>med_ans</sans>
        <tans>med</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.2</truescore>
        <truepenalty></truepenalty>
        <truenextnode>10</truenextnode>
        <trueanswernote>prt1-9-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Der <b>Median</b> ist derjenige Wert, der in der geordneten Liste genau in der Mitte liegt bzw. das arithmetische Mittel aus den beiden in der Mitte liegenden Werten (falls die Anzahl der Werte gerade ist).</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Median</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>9</falsenextnode>
        <falseanswernote>prt1-9-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>9</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>arit_ans</sans>
        <tans>med</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>10</truenextnode>
        <trueanswernote>prt1-10-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Der <b>Median</b> ist derjenige Wert, der in der geordneten Liste genau in der Mitte liegt bzw. das arithmetische Mittel aus den beiden in der Mitte liegenden Werten (falls die Anzahl der Werte gerade ist).</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Median</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
	<br>
	<i>Stattdessen stimmt das <i>arithmetische Mittel</i> Ihrer Daten aber mit dem im gegebenen Boxplot eingezeichneten Median überein. Kann es sein, dass Sie die beiden verwechselt haben?</i>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>10</falsenextnode>
        <falseanswernote>prt1-10-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Der <b>Median</b> ist derjenige Wert, der in der geordneten Liste genau in der Mitte liegt bzw. das arithmetische Mittel aus den beiden in der Mitte liegenden Werten (falls die Anzahl der Werte gerade ist).</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Median</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
</div>]]></text>
        </falsefeedback>
      </node>
    </prt>
    <prt>
      <name>prt1_neu</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>0</feedbackstyle>
      <feedbackvariables>
        <text><![CDATA[/*
=== Bedeutung der Knoten: ===
1. Ist die Antwort eine Liste?
2. Sind die angegebenen Werte alle unterschiedlich?
3. Sind nur Zahlen dabei, mit denen JSXGraph was anfangen kann? (kein pi, e, sqrt(),...)
4. Wurde eine Liste mit den Kenngrößen angegeben?
5. Ist die Länge der Liste in Ordnung? (Und Wiederholung des Datensatzes aus ans1_neu)
6. Ist die gesamte Aufgabe richtig? (Für grafisches Feedback)
7. Stimmt die linke Antenne?
8 Stimmt das untere Quartil?
9. Stimmt der Median?
    10. Falls 9 = falsch: Stimmt vielleicht das arithmetische Mittel von ans1_neu mit dem Median des gegebenen Box-Plots überein?
11. Stimmt das obere Quartil?
12. Stimmt die rechte Antenne?
13. Ist die Anzahl der oberen Ausreißer gleich null?
    14: Falls 13=false: Entspricht der obere Ausreißer denn der rechten Antenne des Boxplots aus der Aufgabenstellung?
15. Ist die Anzahl der unteren Ausreißer gleich null?
    16: Falls 15=false: Entspricht der untere Ausreißer denn der linken Antenne des Boxplots aus der Aufgabenstellung?
17. Benachrichtigung über das Erreichen des Endes der Aufgabe
18. Nochmal Grafik mit den ersten beiden Boxplots (wenn STOP bei Knoten 1-5)
*/

/* ===========================
Für letzte Antwort (ans1_neu)
============================== */

/* Sortierte Liste mit den Datenpunkten:*/
L2: sort(float(map(fullratsimp,ans1_neu)));
anspunkte: makelist([L2[k],3],k,1,length(L2)); /*Datenpunkte*/

/*Kennwerte:*/
mini_ans: lmin(L2); /*Minimum des Boxplots aus der Antwort*/
maxi_ans: lmax(L2); /*Maximum des Boxplots aus der Antwort*/
med_ans: median1(L2); /*Median des Boxplots aus der Antwort*/
arit_ans: apply("+",L2)/length(L2); /*arithmetisches Mittel des Boxplots aus der Antwort*/
ampl_ans: maxi_ans-mini_ans; /*Spannweite des Boxplots aus der Antwort*/
uquantil_ans: pquantil(L2,1/4); /*Unteres Quartil des Boxplots aus der Antwort*/
oquantil_ans: pquantil(L2,3/4); /*Oberes Quartil des Boxplots aus der Antwort*/
IQR_ans: oquantil_ans-uquantil_ans; /*IQR des Boxplots aus der Antwort*/

/*Ausreißer:*/
ausreisser_unten_ans: sublist(L2,lambda([x],x<uquantil_ans-3/2*IQR_ans)); /*Untere Ausreißer des Boxplots aus der Antwort*/
ausreisser_oben_ans: sublist(L2,lambda([x],x>oquantil_ans+3/2*IQR_ans)); /*Obere Ausreißer des Boxplots aus der Antwort*/
ausreisser_punkte_ans: block([L], /*Ausreißer des Boxplots aus der Antwort oben und unten (Punkte)*/
  L:[],
  if not(ausreisser_oben_ans=[]) then L:cons([last(L2),3],L), /*fügt L oberen Ausreißer hinzu, wenn es einen gibt*/
  if not(ausreisser_unten_ans=[]) then L:cons([first(L2),3],L), /*fügt L unteren Ausreißer hinzu, wenn es einen gibt*/
    return(L)
);
ausreisser_punkte_x_ans: makelist(ausreisser_punkte_ans[k][1],k,1,length(ausreisser_punkte_ans));

/* Bestimmt, ob es einen oberen/unteren Ausreißer gibt und legt dadurch fest,
was die obere/untere Antenne des Boxplots aus der Antwort ist: */
antenne_rechts_ans: if ausreisser_oben_ans=[] then last(L2) else lmax(sublist(L2, lambda([x],x<=oquantil_ans+3/2*IQR_ans)));
antenne_links_ans: if ausreisser_unten_ans=[] then first(L2) else lmin(sublist(L2, lambda([x],x>=uquantil_ans-3/2*IQR_ans)));

/* ===========================
Für erste Antwort (ans1_copy)
============================== */

/* Sortierte Liste mit den Datenpunkten*/
L2_1: sort(float(map(fullratsimp,ans1_copy))); 
anspunkte_1: makelist([L2_1[k],3],k,1,length(L2_1)); /*Datenpunkte*/

/*Kennwerte:*/
mini_ans_1: lmin(L2_1); /*Minimum des Boxplots aus der Antwort*/
maxi_ans_1: lmax(L2_1); /*Maximum des Boxplots aus der Antwort*/
med_ans_1: median1(L2_1); /*Median des Boxplots aus der Antwort*/
arit_ans_1: apply("+",L2_1)/length(L2_1); /*arithmetisches Mittel des Boxplots aus der Antwort*/
ampl_ans_1: maxi_ans_1-mini_ans_1; /*Spannweite des Boxplots aus der Antwort*/
uquantil_ans_1: pquantil(L2_1,1/4); /*Unteres Quartil des Boxplots aus der Antwort*/
oquantil_ans_1: pquantil(L2_1,3/4); /*Oberes Quartil des Boxplots aus der Antwort*/
IQR_ans_1: oquantil_ans_1-uquantil_ans_1; /*IQR des Boxplots aus der Antwort*/

/*Ausreißer:*/
ausreisser_unten_ans_1: sublist(L2_1,lambda([x],x<uquantil_ans_1-3/2*IQR_ans_1)); /*Untere Ausreißer des Boxplots aus der Antwort*/
ausreisser_oben_ans_1: sublist(L2_1,lambda([x],x>oquantil_ans_1+3/2*IQR_ans_1)); /*Obere Ausreißer des Boxplots aus der Antwort*/
ausreisser_punkte_ans_1: block([L], /*Ausreißer des Boxplots aus der Antwort oben und unten (Punkte)*/
  L:[],
  if not(ausreisser_oben_ans_1=[]) then L:cons([last(L2_1),3],L), /*fügt L oberen Ausreißer hinzu, wenn es einen gibt*/
  if not(ausreisser_unten_ans_1=[]) then L:cons([first(L2_1),3],L), /*fügt L unteren Ausreißer hinzu, wenn es einen gibt*/
    return(L)
);
ausreisser_punkte_x_ans_1: makelist(ausreisser_punkte_ans_1[k][1],k,1,length(ausreisser_punkte_ans_1));

/* Bestimmt, ob es einen oberen/unteren Ausreißer gibt und legt dadurch fest,
was die obere/untere Antenne des Boxplots aus der Antwort ist: */
antenne_rechts_ans_1: if ausreisser_oben_ans_1=[] then last(L2_1) else lmax(sublist(L2_1, lambda([x],x<=oquantil_ans_1+3/2*IQR_ans_1)));
antenne_links_ans_1: if ausreisser_unten_ans_1=[] then first(L2_1) else lmin(sublist(L2_1, lambda([x],x>=uquantil_ans_1-3/2*IQR_ans_1)));

/* ================================
Für sonstige Elemente in der Grafik
=================================== */

/*Globales Minimum, Maximum und globale Spannweite für die "boundingbox" des Boards in der Grafik:*/
mini_global: min(mini,mini_ans);
maxi_global: max(maxi,maxi_ans);
ampl_global: max(ampl, ampl_ans);
mini_global_1: min(mini,mini_ans,mini_ans_1);
maxi_global_1: max(maxi,maxi_ans,maxi_ans_1);
ampl_global_1: max(ampl, ampl_ans, ampl_ans_1);

/*Minimum und Maximum ohne Berücksichtigung der aktuellen Antwort (für Wiederholungsknoten)*/
mini_global_w: min(mini,mini_ans_1);
maxi_global_w: max(maxi,maxi_ans_1);
ampl_global_w: max(ampl, ampl_ans_1);

/*Für Ausreißer in der Grafik:*/
ausreisser_oben_wert_ans: if length(ausreisser_oben_ans)>0 then last(ausreisser_oben_ans) else "keiner";
ausreisser_unten_wert_ans: if length(ausreisser_unten_ans)>0 then first(ausreisser_unten_ans) else "keiner";

/*Liste mit Werten, die Studierende genannt haben, die keine reellen Zahlen sind.*/
enthaltene_strings: sublist(L2,lambda([x], stringp(x)));
L2_ohne_strings: sublist(L2,lambda([y],not(stringp(y))));
sonstige_verbotene_zahlen: sublist(L2_ohne_strings,lambda([x],
        not(constantp(x)) or imagpart(x)#0 or setp(x) or listp(x)
    )
);
verboteneZahlen: append(enthaltene_strings,sonstige_verbotene_zahlen);

/*Überprüfen, ob die extremsten Ausreißer mit der Antenne des Boxplots aus der Aufgabenmstellung übereinstimmt (orangene Hilfslinien)*/
ausreisser_oben_orange: if is(ausreisser_oben_wert_ans="keiner") then false else is(abs(ausreisser_oben_wert_ans-antenne_rechts)<0.00001);
ausreisser_unten_orange: if is(ausreisser_unten_wert_ans="keiner") then false else is(abs(ausreisser_unten_wert_ans-antenne_links)<0.00001);


/*Überprüfen, ob die extremsten Ausreißer mit der Antenne des Boxplots aus der Aufgabenmstellung übereinstimmt (orangene Hilfslinien)
  für Knoten 18 */
ausreisser_oben_wert_ans_1: if length(ausreisser_oben_ans_1)>0 then last(ausreisser_oben_ans_1) else "keiner";
ausreisser_unten_wert_ans_1: if length(ausreisser_unten_ans_1)>0 then first(ausreisser_unten_ans_1) else "keiner";
ausreisser_oben_orange_1: if is(ausreisser_oben_wert_ans_1="keiner") then false else is(abs(ausreisser_oben_wert_ans_1-antenne_rechts)<0.00001);
ausreisser_unten_orange_1: if is(ausreisser_unten_wert_ans_1="keiner") then false else is(abs(ausreisser_unten_wert_ans_1-antenne_links)<0.00001);]]></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>listp(ans1_neu)</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>=</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>1</truenextnode>
        <trueanswernote>prt1_neu-1-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<script>
window.addEventListener('load', function (){
    hide('oer-aufgabe-23_aufgabe1_prt');
});
</script>]]></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>17</falsenextnode>
        <falseanswernote>prt1_neu-1-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p class="incorrect"><span style="font-size: 1.5em; color:red;"><i class="fa fa-times"></i></span> Falsche Antwort.</p>

<p>Ihre eingegebene Antwort ist keine Liste in der Form <code>[a,b,c,...]</code></p>
<p>Bitte geben Sie eine Liste an und klicken Sie dann erneut auf "Prüfen".</p>

<script>
window.addEventListener('load', function (){
    hide('oer-aufgabe-23_aufgabe1_prt');
});
</script>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>1</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(ans1_neu)</sans>
        <tans>length(unique(ans1_neu))</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>2</truenextnode>
        <trueanswernote>prt1_neu-2-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>17</falsenextnode>
        <falseanswernote>prt1_neu-2-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p class="incorrect"><span style="font-size: 1.5em; color:red;"><i class="fa fa-times"></i></span> Falsche Antwort.</p>

<p>Ihre Liste sollte nur unterschiedliche Werte enthalten</p>
<p>Bitte geben Sie eine Liste unterschiedlicher Werte an und klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>10</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>oquantil_ans</sans>
        <tans>oquantil</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>11</truenextnode>
        <trueanswernote>prt1_neu-11-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Das <b>obere Quartil</b> ist derjenige Wert aus dem Datensatz, für den gilt, dass 75 % aller Werte kleiner als dieser oder gleich diesem sind. Analog zum Median kann auch hier eine Mittelwertbildung stattfinden.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Oberes Quartil</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>11</falsenextnode>
        <falseanswernote>prt1_neu-11-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Das <b>obere Quartil</b> ist derjenige Wert aus dem Datensatz, für den gilt, dass 75 % aller Werte kleiner als dieser oder gleich diesem sind. Analog zum Median kann auch hier eine Mittelwertbildung stattfinden.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Oberes Quartil</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
</div>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>11</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>antenne_rechts_ans</sans>
        <tans>antenne_rechts</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>12</truenextnode>
        <trueanswernote>prt1_neu-12-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Die <b>rechte Antenne</b> erstreckt sich nach rechts zum größten Wert des Datensatzes, der höchstens 1,5 Interquartilsabstände vom Kasten entfernt ist.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Rechte Antenne</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>12</falsenextnode>
        <falseanswernote>prt1_neu-12-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Die <b>rechte Antenne</b> erstreckt sich nach rechts zum größten Wert des Datensatzes, der höchstens 1,5 Interquartilsabstände vom Kasten entfernt ist.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Rechte Antenne</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
</div>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>12</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(ausreisser_oben_ans)</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>14</truenextnode>
        <trueanswernote>prt1_neu-13-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.1</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>13</falsenextnode>
        <falseanswernote>prt1_neu-13-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<br>
<p><span style="font-size: 1em; color:red;"><i class="fa fa-exclamation"></i></span> Im Boxplot aus der Aufgabenstellung ist kein maximaler Wert als Ausreißer eingezeichnet. Der Boxplot, der sich aus Ihren Daten ergibt, hat aber einen solchen Wert. </p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>13</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ausreisser_oben_orange</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>14</truenextnode>
        <trueanswernote>prt1_neu-14-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Der obere Ausreißer aus Ihrem Datensatz stammt aber mit der rechten Antenne des Boxplots aus der Aufgabenstellung überein (in der Grafik durch <span style="color:orange">gelbe</span> durchgezogene Hilfslinien dargestellt).</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>14</falsenextnode>
        <falseanswernote>prt1_neu-14-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>14</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(ausreisser_unten_ans)</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>16</truenextnode>
        <trueanswernote>prt1_neu-15-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0.1</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>15</falsenextnode>
        <falseanswernote>prt1_neu-15-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p><span style="font-size: 1em; color:red;"><i class="fa fa-exclamation"></i></span> Im Boxplot aus der Aufgabenstellung ist kein minimaler Wert als Ausreißer eingezeichnet. Der Boxplot, der sich aus Ihren Daten ergibt, hat aber einen solchen Wert.</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>15</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ausreisser_unten_orange</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>16</truenextnode>
        <trueanswernote>prt1_neu-16-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Der untere Ausreißer aus Ihrem Datensatz stammt aber mit der linken Antenne des Boxplots aus der Aufgabenstellung überein (in der Grafik durch <span style="color:orange">gelbe</span> durchgezogene Hilfslinien dargestellt).</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>16</falsenextnode>
        <falseanswernote>prt1_neu-16-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>16</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>[antenne_links_ans, antenne_rechts_ans, med_ans, uquantil_ans, oquantil_ans]</sans>
        <tans>[antenne_links, antenne_rechts, med, uquantil, oquantil]</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1_neu-17-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[[[ if test='is(length(ausreisser_unten_ans)#0 or length(ausreisser_oben_ans)#0)' ]]
<hr>
<p>Bitte korrigieren Sie Ihre Eingabe und klicken Sie dann erneut auf "Prüfen".</p>
[[ else ]]
<hr>
<p>Herzlichen Glückwunsch, Sie sind am Ende der Aufgabe angelangt! Jetzt sollten Sie zu einem gegebenen Boxplot einen passenden Datensatz finden können.</p>
[[/ if ]]]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1_neu-17-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<hr>
<p>Bitte korrigieren Sie Ihre Eingabe und klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>17</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>1</sans>
        <tans>1</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1_neu-18-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<hr>
<p>Zur Erinnerung sehen Sie hier noch einmal die Werte und den <span style="color:{@boxplot_antwort_1@}">Boxplot zu Ihrer allerersten Antwort {@ans1_copy@}</span> <button type="button" class="btn btn-link" style="padding:0;margin-right: -0.5%;" onclick="copyToClipboard('['+{#ans1_copy#}+']')"><i class="icon fa fa-solid fa-clipboard fa-fw copytoclipboard" data-toggle="tooltip" data-placement="top" title="In die Zwischenablage kopieren"></i></button>. Darunter sehen Sie den <span style="color:{@boxplot_aufgabenstellung@}">Boxplot aus der Aufgabenstellung</span>.</p>

[[jsxgraph]]
JXG.Options.line.strokeWidth = 2;
JXG.Options.line.dash = 1;
JXG.Options.line.straightFirst = false;
JXG.Options.segment.dash = 0;

// Verwendete Farben:
const upperColor = {#boxplot_antwort_1#}; // Farbe des Boxplots aus der ersten Antwort
const lowerColor = {#boxplot_aufgabenstellung#}; //Farbe des unteren Boxplots aus der Aufgabenstellung
const datenpunkte_farbe_1 = {#datenpunkte#}; // Farbe Datenpunkte erste Antwort
const labelBackgroundColor2 = {#label_background#};

// Ändert Schriftfarbe der "Legende"
document.querySelectorAll('.oer-aufgabe-23_farbe_oben_2').forEach(el=>el.style.color=upperColor);
document.querySelectorAll('.oer-aufgabe-23_farbe_unten_2').forEach(el=>el.style.color=lowerColor);

const boxplot_height = 1.2; // Höhe des Boxplots aus der Aufgabenstellung
const antennen_height = 0.6; // Höhe der Antennen des Boxplots aus der Aufgabenstellung

const achse2_y = 2; // y-Position der zweiten x-Achse (für den Boxplot aus der ersten Antwort)
const boxplot_height_ans_1 = 1.2; // Höhe des Boxplots aus der ersten Antwort
const antennen_height_ans_1 = 0.6; // Höhe der Antennen des Boxplots aus der ersten Antwort

const datapoints2_y_1 = 2; // y-Position der Datenpunkte aus der ersten Antwort

const ende_hilfslinien = -1.3; // Unteres Ende der Hilfslinien

const highest_position = Math.max(achse2_y+0.5*boxplot_height+0.4, datapoints2_y_1+0.4,achse2_y+0.5*boxplot_height+0.4, datapoints2_y_1+0.4);

const mini_global_w = {#float(mini_global_w)#};
const ampl_global_w = {#float(ampl_global_w)#};
const maxi_global_w = {#float(maxi_global_w)#};
const mini_global = {#float(mini_global)#};
const uquantil_ans_1 = {#float(uquantil_ans_1)#};
const oquantil_ans_1 = {#float(oquantil_ans_1)#};
const antenne_links_ans_1 = {#float(antenne_links_ans_1)#};
const antenne_rechts_ans_1 = {#float(antenne_rechts_ans_1)#};
const med_ans_1 = {#float(med_ans_1)#};
const ausreisser_x_array_1 = {#ausreisser_punkte_x_ans_1#};
const datapoints_x_array_1 = {#L2_1#}; 
const uquantil = {#float(uquantil)#};
const oquantil = {#float(oquantil)#};
const antenne_links = {#float(antenne_links)#};
const antenne_rechts = {#float(antenne_rechts)#};
const med = {#float(med)#}
const ausreisser_oben_wert_ans = {#float(ausreisser_oben_wert_ans)#};
const ausreisser_unten_wert_ans = {#float(ausreisser_unten_wert_ans)#}; 

const board = JXG.JSXGraph.initBoard(divid, {
    axis:true,
    boundingbox: [mini_global_w-0.2*ampl_global_w, highest_position+0.5, maxi_global_w+0.2*ampl_global_w, -2],
    showCopyright:false,
	showNavigation:false,
    defaultAxes:{
        x:{lastArrow:false,
            ticks:{drawZero:true}
        },
         y:{lastArrow:false,
            visible:false,
            ticks:{drawLabels:false, drawZero:true}
        }
    }
});
// Setze Hintergrundfarbe auf weiß:
board.renderer.container.style.backgroundColor = '#fff';

// === Anstatt der automatisch angezeigten Koordinaten für Punkte soll das Label in der Form "Wert = X" erscheinen ===
board.highlightInfobox = function(x,y,el) {
    this.infobox.setText('Wert = ' + x);
    this.infobox.rendNode.style.color = 'black';
    this.infobox.rendNode.style.padding = '5px';
    this.infobox.rendNode.style.backgroundColor = 'white';
};

// === Checkboxes ===
const checkbox = board.create('checkbox',[
   mini_global,
   -1.5,
   'Zeige/verberge Datenpunkte'
],{
   checked:true,
   fixed:true
});
const checkbox_Linien = board.create('checkbox',[
   mini_global,
   -1.8,
   'Zeige/verberge Hilfslinien'
],{
   checked:false,
   fixed:true
});

// ===========================================================
// ================ Boxplot aus der ersten Antwort ===========
// ===========================================================

// === Beschriftung mittlerer Boxplot ===
const beschriftung_ans = board.create('text',[
   board.getBoundingBox()[0],
   achse2_y,
   'Boxplot<br>aus Ihrer<br>ersten<br>Antwort'
],{
   fixed:true,
   color:upperColor,
   highlight:false
});
beschriftung_ans.rendNode.style.background=labelBackgroundColor2;
beschriftung_ans.rendNode.style.padding="3px";

// === Obere Achse ===
const achse2 = board.create('axis', [
   [0, achse2_y],
   [1, achse2_y]
],{
   ticks:{drawLabels:false},
   lastArrow:false
});

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const polans_1 = board.create('point',[
   uquantil_ans_1,
   ()=>achse2_y+boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});
const pulans_1 = board.create('point',[
   uquantil_ans_1,
   ()=>achse2_y-boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});
const porans_1 = board.create('point',[
   oquantil_ans_1,
   ()=>achse2_y+boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});
const purans_1 = board.create('point',[
   oquantil_ans_1,
   ()=>achse2_y-boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_ans_text_1 = board.create('text',[
   antenne_links_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Linke Antenne = '+antenne_links_ans_1
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_links_ans_1 = board.create('segment',[
   [antenne_links_ans_1, ()=>achse2_y-antennen_height_ans_1/2],
   [antenne_links_ans_1, ()=>achse2_y+antennen_height_ans_1/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_links_ans_1.on('over', function(e){
    grenze_links_ans_text_1.setAttribute({visible:true});
});
grenze_links_ans_1.on('out', function(e){
    grenze_links_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_links_ansActive_1 = false;
grenze_links_ans_1.on('down', function(e){
    if(grenze_links_ansActive_1){
        grenze_links_ans_text_1.setAttribute({visible:false});
    } else{
        grenze_links_ans_text_1.setAttribute({visible:true});
    }
    grenze_links_ansActive_1 = !grenze_links_ansActive_1;
});

// === Rechte Antenne ===
const grenze_rechts_ans_text_1 = board.create('text',[
   antenne_rechts_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts_ans_1
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_rechts_ans_1 = board.create('segment',[
   [antenne_rechts_ans_1, ()=>achse2_y-antennen_height_ans_1/2],
   [antenne_rechts_ans_1, ()=>achse2_y+antennen_height_ans_1/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts_ans_1.on('over', function(e){
    grenze_rechts_ans_text_1.setAttribute({visible:true});
});
grenze_rechts_ans_1.on('out', function(e){
    grenze_rechts_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechts_ansActive_1 = false;
grenze_rechts_ans_1.on('down', function(e){
    if(grenze_rechts_ansActive_1){
        grenze_rechts_ans_text_1.setAttribute({visible:false});
    } else{
        grenze_rechts_ans_text_1.setAttribute({visible:true});
    }
    grenze_rechts_ansActive_1 = !grenze_rechts_ansActive_1;
});

// === Grundlinien ===
const grundlinie_links_ans_1 = board.create('segment',[
   [antenne_links_ans_1,achse2_y],
   [uquantil_ans_1,achse2_y]
],{
   fixed:true,
   strokeColor:upperColor,
   highlight:false
});
const grundlinie_rechts_ans_1 = board.create('segment',[
   [oquantil_ans_1,achse2_y],
   [antenne_rechts_ans_1,achse2_y]
],{
   fixed:true,
   strokeColor:upperColor,
   highlight:false
});

// === Median ===
const median_ans_text_1 = board.create('text',[
   med_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Median = '+med_ans_1
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const median_ans_1 = board.create('segment',[
   [med_ans_1, ()=>achse2_y-boxplot_height_ans_1/2],
   [med_ans_1, ()=>achse2_y+boxplot_height_ans_1/2]
],{
   fixed:true,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
median_ans_1.on('over', function(e){
    median_ans_text_1.setAttribute({visible:true});
});
median_ans_1.on('out', function(e){
    median_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let median_ansActive_1 = false;
median_ans_1.on('down', function(e){
    if(median_ansActive_1){
        median_ans_text_1.setAttribute({visible:false});
    } else{
        median_ans_text_1.setAttribute({visible:true});
    }
    median_ansActive_1 = !median_ansActive_1;
});

// === Box ===
const uquantil_ans_text_1 = board.create('text',[
   uquantil_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Unteres Quartil = '+uquantil_ans_1
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const oquantil_ans_text_1 = board.create('text',[
   oquantil_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Oberes Quartil = '+oquantil_ans_1
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const box_ans_1 = board.create('polygon',[polans_1,porans_1,purans_1,pulans_1],{
    fillColor:upperColor,
    highlight:false,
    borders:{strokeWidth:2, strokeColor:upperColor, highlightStrokeColor:'grey'}
});
box_ans_1.borders[2].setAttribute({highlight:false});
box_ans_1.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box_ans_1.borders[3].on('over', function(e){
    uquantil_ans_text_1.setAttribute({visible:true});
});
box_ans_1.borders[3].on('out', function(e){
    uquantil_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantil_ansActive_1 = false;
box_ans_1.borders[3].on('down', function(e){
    if(uquantil_ansActive_1){
        uquantil_ans_text_1.setAttribute({visible:false});
    } else{
        uquantil_ans_text_1.setAttribute({visible:true});
    }
    uquantil_ansActive_1 = !uquantil_ansActive_1;
});

// Eventlistener für Mouse-Hovering
box_ans_1.borders[1].on('over', function(e){
    oquantil_ans_text_1.setAttribute({visible:true});
});
box_ans_1.borders[1].on('out', function(e){
    oquantil_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantil_ansActive_1 = false;
box_ans_1.borders[1].on('down', function(e){
    if(oquantil_ansActive_1){
        oquantil_ans_text_1.setAttribute({visible:false});
    } else{
        oquantil_ans_text_1.setAttribute({visible:true});
    }
    oquantil_ansActive_1 = !oquantil_ansActive_1;
});

// === Ausreißer-Punkte ===
for(let j of ausreisser_x_array_1){
   board.create('point',[j,achse2_y],{
      fixed:true,
      withLabel:false,
      color:upperColor,
      showInfobox:false
   })
};

// === Datenpunkte ===
for(let j of datapoints_x_array_1){
   board.create('point',[j, datapoints2_y_1],{
      withLabel:false,
      fixed:true,
      face:'x',
      visible:()=>checkbox.Value(),
      color:datenpunkte_farbe_1
   })
};


// ===========================================================
// ============= Boxplot aus der Aufgabenstellung ============
// ===========================================================

// === Beschriftung unterer Boxplot ===
const beschriftung_aufg = board.create('text',[
   board.getBoundingBox()[0],
   0,
   'Boxplot<br>aus der<br>Aufgaben-<br>stellung'
],{
   fixed:true,
   color:lowerColor,
   highlight:false
});
beschriftung_aufg.rendNode.style.background=labelBackgroundColor2;
beschriftung_aufg.rendNode.style.padding="3px";

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const pol = board.create('point',[
   uquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pul = board.create('point',[
   uquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});
const por = board.create('point',[
   oquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pur = board.create('point',[
   oquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_text = board.create('text',[
   antenne_links-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Linke Antenne = '+antenne_links
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const grenze_links = board.create('segment',[
   [antenne_links, ()=>0-antennen_height/2],
   [antenne_links, ()=>0+antennen_height/2]
],{
    fixed:true,
    strokeWidth:3,
    strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_links.on('over', function(e){
    grenze_links_text.setAttribute({visible:true});
});
grenze_links.on('out', function(e){
    grenze_links_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_linksActive = false;
grenze_links.on('down', function(e){
    if(grenze_linksActive){
        grenze_links_text.setAttribute({visible:false});
    } else{
        grenze_links_text.setAttribute({visible:true});
    }
    grenze_linksActive = !grenze_linksActive;
});

// === Rechte Antenne ===
const grenze_rechts_text = board.create('text',[
   antenne_rechts-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const grenze_rechts = board.create('segment',[
   [antenne_rechts, ()=>0-antennen_height/2],
   [antenne_rechts, ()=>0+antennen_height/2]
],{
    fixed:true,
    strokeWidth:3,
    strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts.on('over', function(e){
    grenze_rechts_text.setAttribute({visible:true});
});
grenze_rechts.on('out', function(e){
    grenze_rechts_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechtsActive = false;
grenze_rechts.on('down', function(e){
    if(grenze_rechtsActive){
        grenze_rechts_text.setAttribute({visible:false});
    } else{
        grenze_rechts_text.setAttribute({visible:true});
    }
    grenze_rechtsActive = !grenze_rechtsActive;
});

// === Grundlinien ===
const grundlinie_links = board.create('segment',[
   [antenne_links,0],
   [uquantil,0]
],{
    fixed:true,
    strokeColor:lowerColor,
    highlight:false
});
const grundlinie_rechts = board.create('segment',[
   [oquantil,0],
   [antenne_rechts,0]
],{
    fixed:true,
    strokeColor:lowerColor,
    highlight:false
});

// === Median ===
const median_text = board.create('text',[
   med-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Median ='+med
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const median = board.create('segment',[
   [med, ()=>0-boxplot_height/2],
   [med, ()=>0+boxplot_height/2]
],{
    fixed:true,
    strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
median.on('over', function(e){
    median_text.setAttribute({visible:true});
});
median.on('out', function(e){
    median_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let medianActive = false;
median.on('down', function(e){
    if(medianActive){
        median_text.setAttribute({visible:false});
    } else{
        median_text.setAttribute({visible:true});
    }
    medianActive = !medianActive;
});

// === Box ===
const uquantil_text = board.create('text',[
   uquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Unteres Quartil = '+uquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const oquantil_text = board.create('text',[
   oquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Oberes Quartil = '+oquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const box = board.create('polygon',[pol,por,pur,pul],{
    fillColor:lowerColor,
    highlight:false,
    borders:{strokeWidth:2, highlightStrokeColor:'grey', strokeColor:lowerColor}
});
box.borders[2].setAttribute({highlight:false});
box.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box.borders[3].on('over', function(e){
    uquantil_text.setAttribute({visible:true});
});
box.borders[3].on('out', function(e){
    uquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantilActive = false;
box.borders[3].on('down', function(e){
    if(uquantilActive){
        uquantil_text.setAttribute({visible:false});
    } else{
        uquantil_text.setAttribute({visible:true});
    }
    uquantilActive = !uquantilActive;
});

// Eventlistener für Mouse-Hovering
box.borders[1].on('over', function(e){
    oquantil_text.setAttribute({visible:true});
});
box.borders[1].on('out', function(e){
    oquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantilActive = false;
box.borders[1].on('down', function(e){
    if(oquantilActive){
        oquantil_text.setAttribute({visible:false});
    } else{
        oquantil_text.setAttribute({visible:true});
    }
    oquantilActive = !oquantilActive;
});

// ===================================================
// ===================== Hilfslinien: =====================
// ===================================================
const grenze_links_ans_linie = board.create('segment',[
   [antenne_links_ans_1,ende_hilfslinien],
   [antenne_links_ans_1, ()=>achse2_y-antennen_height/2]
],{
   fixed:true,
   color:()=> (antenne_links_ans_1==antenne_links) ? 'green' : ({#ausreisser_unten_orange and ausreisser_unten_wert_ans="keiner"#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (antenne_links_ans_1==antenne_links) ? 2 : 1
});

const uquartil_linie = board.create('segment',[
   pulans_1,
   [uquantil_ans_1, ende_hilfslinien]
],{
   fixed:true,
   color:()=>(polans_1.X()==pol.X()) ? 'green' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (polans_1.X()==pol.X()) ? 2 : 1
});

const median_ans_linie = board.create('segment',[
   [med_ans_1, ()=>achse2_y-boxplot_height/2],
   [med_ans_1,ende_hilfslinien]
],{
    fixed:true,
    color:()=> (med_ans_1==med) ? 'green' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> (med_ans_1==med) ? 2 : 1
});

const oquartil_linie = board.create('segment',[
   purans_1,
   [oquantil_ans_1,ende_hilfslinien]
],{
   fixed:true,
   color:()=>(porans_1.X()==por.X()) ? 'green' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (porans_1.X()==por.X()) ? 2 : 1
});

const grenze_rechts_ans_linie = board.create('segment',[
   [antenne_rechts_ans_1, ()=>achse2_y-antennen_height/2],
   [antenne_rechts_ans_1,ende_hilfslinien]
],{
   fixed:true,
   color:()=>(antenne_rechts_ans_1==antenne_rechts) ? 'green' : ({#ausreisser_oben_orange and ausreisser_oben_wert_ans="keiner"#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (antenne_rechts_ans_1==antenne_rechts) ? 2 : 1
});

const ausreisser_rechts_linie = board.create('segment',[
   [ausreisser_oben_wert_ans_1,achse2_y],
   [ausreisser_oben_wert_ans_1,ende_hilfslinien]
],{
   fixed:true,
   color:()=> ({#ausreisser_oben_orange_1#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> ({#ausreisser_oben_orange_1#}) ? 0 : 1
});

const ausreisser_links_linie = board.create('segment',[
   [ausreisser_unten_wert_ans_1,achse2_y],
   [ausreisser_unten_wert_ans_1,ende_hilfslinien]
],{
   fixed:true,
   color:()=> ({#ausreisser_unten_orange_1#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> ({#ausreisser_unten_orange_1#}) ? 0 : 1
});
[[/jsxgraph]]]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1_neu-18-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>2</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(verboteneZahlen)</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>3</truenextnode>
        <trueanswernote>prt1_neu-3-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>17</falsenextnode>
        <falseanswernote>prt1_neu-3-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p class="incorrect"><span style="font-size: 1.5em; color:red;"><i class="fa fa-times"></i></span> Falsche Antwort.</p>

<p>Ihr Datensatz enthält folgende Werte, die nicht ausgewertet werden konnten:</p>
\[ {@sequenceify(verboteneZahlen)@} \]
<p>Bitte geben Sie eine Liste reeller Zahlen an und klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>3</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>L2</sans>
        <tans>list_indicators</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>17</truenextnode>
        <trueanswernote>prt1_neu-4-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Es sieht so aus, als hätten Sie die Kenngrößen bestimmt.</p>
<p>Bitte geben einen Datensatz an, der zu dem gegebenen Boxplot passt. Klicken Sie dann wieder auf "Prüfen".</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>4</falsenextnode>
        <falseanswernote>prt1_neu-4-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>4</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans><![CDATA[is(length(ans1_neu)>=8)]]></sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>5</truenextnode>
        <trueanswernote>prt1_neu-5-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>17</falsenextnode>
        <falseanswernote>prt1_neu-5-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p class="incorrect"><span style="font-size: 1.5em; color:red;"><i class="fa fa-times"></i></span> Falsche Antwort.</p>

<p>Ihre Liste enthält weniger als acht Werte.</p>
<p>Bitte geben Sie eine Liste mit mindestens acht unterschiedlichen Werten an und klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>5</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>[antenne_links_ans, antenne_rechts_ans, med_ans, uquantil_ans, oquantil_ans]</sans>
        <tans>[antenne_links, antenne_rechts, med, uquantil, oquantil]</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.5</truescore>
        <truepenalty></truepenalty>
        <truenextnode>6</truenextnode>
        <trueanswernote>prt1_neu-6-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[[[ if test='is(length(ausreisser_unten_ans)=0 and length(ausreisser_oben_ans)=0)' ]]
<p class="correct"><span style="font-size: 1.5em; color:green;"><i class="fa fa-check"></i></span> Richtige Antwort, gut gemacht!</p>
[[ else ]]
<p class="partiallycorrect"><span style="font-size: 1.5em; color:orange;"><i class="fa fa-adjust"></i></span> Ihre Antwort ist teilweise korrekt.</p>
[[/ if ]]

<p>In der folgenden Abbildung sehen Sie oben die von Ihnen angegebenen Daten und den zugehörigen <span style="color:{@boxplot_antwort_1@}"> Boxplot aus Ihrer ersten Antwort {@ans1_copy@}</span>. In der Mitte sehen Sie die Daten  und den <span style="color:{@boxplot_antwort_2@}">Boxplot aus Ihrer letzten Antwort {@ans1_neu@}</span>. Ganz unten sehen Sie den <span style="color:{@boxplot_aufgabenstellung@}">Boxplot aus der Aufgabenstellung</span>.</p>

[[jsxgraph]]
JXG.Options.line.strokeWidth = 2;
JXG.Options.line.dash = 1;
JXG.Options.line.straightFirst = false;
JXG.Options.segment.dash = 0;

// Verwendete Farben:
const upperColor = {#boxplot_antwort_2#}; // Farbe des Boxplots aus der zweiten Antwort
const middleColor = {#boxplot_antwort_1#}; // Farbe des Boxplots aus der ersten Antwort
const lowerColor = {#boxplot_aufgabenstellung#}; //Farbe des unteren Boxplots aus der Aufgabenstellung
const datenpunkte_farbe = {#datenpunkte#};  // Farbe Datenpunkte letzte Antwort
const datenpunkte_farbe_1 = {#datenpunkte#}; // Farbe Datenpunkte erste Antwort
const labelBackgroundColor2 = {#label_background#};


// Ändert Schriftfarbe der "Legende"
document.querySelectorAll('.oer-aufgabe-23_farbe_oben_2').forEach(el=>el.style.color=upperColor);
document.querySelectorAll('.oer-aufgabe-23_farbe_mitte_2').forEach(el=>el.style.color=middleColor);
document.querySelectorAll('.oer-aufgabe-23_farbe_unten_2').forEach(el=>el.style.color=lowerColor);

const boxplot_height = 1.2; // Höhe des Boxplots aus der Aufgabenstellung
const antennen_height = 0.6; // Höhe der Antennen des Boxplots aus der Aufgabenstellung

const achse2_y = 4; // y-Position der zweiten x-Achse (für den Boxplot aus der ersten Antwort)
const achse3_y = 2; // y-Position der zweiten x-Achse (für den Boxplot aus letzten Antwort)
const boxplot_height_ans = 1.2; // Höhe des Boxplots aus der letzten Antwort
const boxplot_height_ans_1 = 1.2; // Höhe des Boxplots aus der ersten Antwort
const antennen_height_ans = 0.6; // Höhe der Antennen des Boxplots aus der letzten Antwort
const antennen_height_ans_1 = 0.6; // Höhe der Antennen des Boxplots aus der ersten Antwort

const datapoints2_y = 2; // y-Position der Datenpunkte aus der letzten Antwort
const datapoints2_y_1 = 4; // y-Position der Datenpunkte aus der ersten Antwort

const ende_hilfslinien = -1.3; // Unteres Ende der Hilfslinien

const highest_position = Math.max(
   achse3_y+0.5*boxplot_height+0.4,
   datapoints2_y_1+0.4,
   achse2_y+0.5*boxplot_height+0.4,
   datapoints2_y+0.4
);

const mini_global_1 = {#float(mini_global_1)#};
const ampl_global_1 = {#float(ampl_global_1)#};
const maxi_global_1 = {#float(maxi_global_1)#};
const mini_global = {#float(mini_global)#};
const uquantil_ans = {#float(uquantil_ans)#};
const oquantil_ans = {#float(oquantil_ans)#};
const antenne_links_ans = {#float(antenne_links_ans)#};
const antenne_rechts_ans = {#float(antenne_rechts_ans)#};
const med_ans = {#float(med_ans)#};
const ausreisser_x_array = {#float(ausreisser_punkte_x_ans)#};
const datapoints_x_array = {#float(L2)#};
const uquantil_ans_1 = {#float(uquantil_ans_1)#};
const oquantil_ans_1 = {#float(oquantil_ans_1)#};
const antenne_links_ans_1 = {#float(antenne_links_ans_1)#};
const antenne_rechts_ans_1 = {#float(antenne_rechts_ans_1)#};
const med_ans_1 = {#float(med_ans_1)#};
const ausreisser_x_array_1 = {#ausreisser_punkte_x_ans_1#};
const datapoints_x_array_1 = {#L2_1#}; 
const uquantil = {#float(uquantil)#};
const oquantil = {#float(oquantil)#};
const antenne_links = {#float(antenne_links)#};
const antenne_rechts = {#float(antenne_rechts)#};
const med = {#float(med)#}
const ausreisser_oben_wert_ans = {#float(ausreisser_oben_wert_ans)#};
const ausreisser_unten_wert_ans = {#float(ausreisser_unten_wert_ans)#}; 

const board = JXG.JSXGraph.initBoard(divid, {
    axis:true,
    boundingbox: [mini_global_1-0.2*ampl_global_1, highest_position+0.5, maxi_global_1+0.2*ampl_global_1, -2],
    showCopyright:false,
	showNavigation:false,
    defaultAxes:{
        x:{lastArrow:false,
            ticks:{drawZero:true}
        },
        y:{lastArrow:false,
            visible:false,
            ticks:{drawLabels:false, drawZero:true}
        }
    }
});
// Setze Hintergrundfarbe auf weiß:
board.renderer.container.style.backgroundColor = '#fff';

// === Anstatt der automatisch angezeigten Koordinaten für Punkte soll das Label in der Form "Wert = X" erscheinen ===
board.highlightInfobox = function(x,y,el) {
    this.infobox.setText('Wert = ' + x);
    this.infobox.rendNode.style.color = 'black';
    this.infobox.rendNode.style.padding = '5px';
    this.infobox.rendNode.style.backgroundColor = 'white';
};

// === Checkboxes ===
const checkbox = board.create('checkbox',[
   mini_global,
   -1.5,
   'Zeige/verberge Datenpunkte'
],{
   checked:true,
   fixed:true
});
const checkbox_Linien = board.create('checkbox',[
   mini_global,
   -1.8,
   'Zeige/verberge Hilfslinien'
],{
   checked:false,
   fixed:true
});

// ===========================================================
// ================ Boxplot aus der letzten Antwort ==========
// ===========================================================

// === Beschriftung oberer Boxplot ===
const beschriftung_ans = board.create('text',[
   board.getBoundingBox()[0],
   achse3_y,
   'Boxplot<br>aus Ihrer<br>letzten<br>Antwort'
],{
   fixed:true,
   color:upperColor,
   highlight:false
});
beschriftung_ans.rendNode.style.background=labelBackgroundColor2;
beschriftung_ans.rendNode.style.padding="3px";

// === Obere Achse ===
const achse3 = board.create('axis', [
   [0, achse3_y],
   [1, achse3_y]
],{
   ticks:{drawLabels:false},
   lastArrow:false
});

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const polans = board.create('point',[
   uquantil_ans,
   ()=>achse3_y+boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const pulans = board.create('point',[
   uquantil_ans,
   ()=>achse3_y-boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const porans = board.create('point',[
   oquantil_ans,
   ()=>achse3_y+boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const purans = board.create('point',[
   oquantil_ans,
   ()=>achse3_y-boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_ans_text = board.create('text',[
   antenne_links_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Linke Antenne = '+antenne_links_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_links_ans = board.create('segment',[
   [antenne_links_ans, ()=>achse3_y-antennen_height_ans/2],
   [antenne_links_ans, ()=>achse3_y+antennen_height_ans/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_links_ans.on('over', function(e){
    grenze_links_ans_text.setAttribute({visible:true});
});
grenze_links_ans.on('out', function(e){
    grenze_links_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_links_ansActive = false;
grenze_links_ans.on('down', function(e){
    if(grenze_links_ansActive){
        grenze_links_ans_text.setAttribute({visible:false});
    } else{
        grenze_links_ans_text.setAttribute({visible:true});
    }
    grenze_links_ansActive = !grenze_links_ansActive;
});

// === Rechte Antenne ===
const grenze_rechts_ans_text = board.create('text',[
   antenne_rechts_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_rechts_ans = board.create('segment',[
   [antenne_rechts_ans, ()=>achse3_y-antennen_height_ans/2],
   [antenne_rechts_ans, ()=>achse3_y+antennen_height_ans/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts_ans.on('over', function(e){
    grenze_rechts_ans_text.setAttribute({visible:true});
});
grenze_rechts_ans.on('out', function(e){
    grenze_rechts_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechts_ansActive = false;
grenze_rechts_ans.on('down', function(e){
    if(grenze_rechts_ansActive){
        grenze_rechts_ans_text.setAttribute({visible:false});
    } else{
        grenze_rechts_ans_text.setAttribute({visible:true});
    }
    grenze_rechts_ansActive = !grenze_rechts_ansActive;
});

// === Grundlinien ===
const grundlinie_links_ans = board.create('segment',[
   [antenne_links_ans,achse3_y],
   [uquantil_ans,achse3_y]
],{
    fixed:true,
   strokeColor:upperColor,
   highlight:false
});
const grundlinie_rechts_ans = board.create('segment',[
   [oquantil_ans,achse3_y],
   [antenne_rechts_ans,achse3_y]
],{
   fixed:true,
   strokeColor:upperColor,
   highlight:false
});

// === Median ===
const median_ans_text = board.create('text',[
   med_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Median = '+med_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const median_ans = board.create('segment',[
   [med_ans, ()=>achse3_y-boxplot_height_ans/2],
   [med_ans, ()=>achse3_y+boxplot_height_ans/2]
],{
   fixed:true,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
median_ans.on('over', function(e){
    median_ans_text.setAttribute({visible:true});
});
median_ans.on('out', function(e){
    median_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let median_ansActive = false;
median_ans.on('down', function(e){
    if(median_ansActive){
        median_ans_text.setAttribute({visible:false});
    } else{
        median_ans_text.setAttribute({visible:true});
    }
    median_ansActive = !median_ansActive;
});

// === Box ===
const uquantil_ans_text = board.create('text',[
   uquantil_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Unteres Quartil = '+uquantil_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const oquantil_ans_text = board.create('text',[
   oquantil_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Oberes Quartil = '+oquantil_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const box_ans = board.create('polygon',[polans,porans,purans,pulans],{
    fillColor:upperColor,
    highlight:false,
    borders:{strokeWidth:2, strokeColor:upperColor, highlightStrokeColor:'grey'}
});
box_ans.borders[2].setAttribute({highlight:false});
box_ans.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box_ans.borders[3].on('over', function(e){
    uquantil_ans_text.setAttribute({visible:true});
});
box_ans.borders[3].on('out', function(e){
    uquantil_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantil_ansActive = false;
box_ans.borders[3].on('down', function(e){
    if(uquantil_ansActive){
        uquantil_ans_text.setAttribute({visible:false});
    } else{
        uquantil_ans_text.setAttribute({visible:true});
    }
    uquantil_ansActive = !uquantil_ansActive;
});

// Eventlistener für Mouse-Hovering
box_ans.borders[1].on('over', function(e){
    oquantil_ans_text.setAttribute({visible:true});
});
box_ans.borders[1].on('out', function(e){
    oquantil_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantil_ansActive = false;
box_ans.borders[1].on('down', function(e){
    if(oquantil_ansActive){
        oquantil_ans_text.setAttribute({visible:false});
    } else{
        oquantil_ans_text.setAttribute({visible:true});
    }
    oquantil_ansActive = !oquantil_ansActive;
});

// === Ausreißer-Punkte ===
for(let j of ausreisser_x_array){
   board.create('point',[j,achse3_y],{
    fixed:true,
    withLabel:false,
    color:upperColor,
    showInfobox:false
   })
};

// === Datenpunkte ===
for(let j of datapoints_x_array){board.create('point',[j, datapoints2_y],{
   withLabel:false,
   fixed:true,
   face:'x',
   visible:function(){return checkbox.Value()},
   color:datenpunkte_farbe
}) };


// ========================================================
// ================ Boxplot aus der ersten Antwort ========
// ========================================================

// === Beschriftung mittlerer Boxplot ===
const beschriftung_ans_1 = board.create('text',[
   board.getBoundingBox()[0],
   achse2_y,'Boxplot<br>aus Ihrer<br>ersten<br>Antwort'
],{
   fixed:true,
   color:middleColor,
   highlight:false
});
beschriftung_ans_1.rendNode.style.background=labelBackgroundColor2;
beschriftung_ans_1.rendNode.style.padding="3px";

// === Obere Achse ===
const achse2 = board.create('axis', [
   [0, achse2_y],
   [1, achse2_y]
],{
   ticks:{drawLabels:false},
   lastArrow:false
});

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const polans_1 = board.create('point',[
   uquantil_ans_1,
   ()=>achse2_y+boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});
const pulans_1 = board.create('point',[
   uquantil_ans_1,
   ()=>achse2_y-boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});
const porans_1 = board.create('point',[
   oquantil_ans_1,
   ()=>achse2_y+boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});
const purans_1 = board.create('point',[
   oquantil_ans_1,
   ()=>achse2_y-boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_ans_text_1 = board.create('text',[
   antenne_links_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Linke Antenne = '+antenne_links_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const grenze_links_ans_1 = board.create('segment',[
   [antenne_links_ans_1, ()=>achse2_y-antennen_height_ans_1/2],
   [antenne_links_ans_1, ()=>achse2_y+antennen_height_ans_1/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:middleColor
});
// Eventlistener für Mouse-Hovering
grenze_links_ans_1.on('over', function(e){
    grenze_links_ans_text_1.setAttribute({visible:true});
});
grenze_links_ans_1.on('out', function(e){
    grenze_links_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_links_ansActive_1 = false;
grenze_links_ans_1.on('down', function(e){
    if(grenze_links_ansActive_1){
        grenze_links_ans_text_1.setAttribute({visible:false});
    } else{
        grenze_links_ans_text_1.setAttribute({visible:true});
    }
    grenze_links_ansActive_1 = !grenze_links_ansActive_1;
});

// === Rechte Antenne ===
const grenze_rechts_ans_text_1 = board.create('text',[
   antenne_rechts_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const grenze_rechts_ans_1 = board.create('segment',[
   [antenne_rechts_ans_1, ()=>achse2_y-antennen_height_ans_1/2],
   [antenne_rechts_ans_1, ()=>achse2_y+antennen_height_ans_1/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:middleColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts_ans_1.on('over', function(e){
    grenze_rechts_ans_text_1.setAttribute({visible:true});
});
grenze_rechts_ans_1.on('out', function(e){
    grenze_rechts_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechts_ansActive_1 = false;
grenze_rechts_ans_1.on('down', function(e){
    if(grenze_rechts_ansActive_1){
        grenze_rechts_ans_text_1.setAttribute({visible:false});
    } else{
        grenze_rechts_ans_text_1.setAttribute({visible:true});
    }
    grenze_rechts_ansActive_1 = !grenze_rechts_ansActive_1;
});

// === Grundlinien ===
const grundlinie_links_ans_1 = board.create('segment',[
   [antenne_links_ans_1,achse2_y],
   [uquantil_ans_1,achse2_y]
],{
   fixed:true,
   strokeColor:middleColor,
   highlight:false
});
const grundlinie_rechts_ans_1 = board.create('segment',[
   [oquantil_ans_1,achse2_y],
   [antenne_rechts_ans_1,achse2_y]
],{
   fixed:true,
   strokeColor:middleColor,
   highlight:false
});

// === Median ===
const median_ans_text_1 = board.create('text',[
   med_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Median = '+med_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const median_ans_1 = board.create('segment',[
   [med_ans_1, ()=>achse2_y-boxplot_height_ans_1/2],
   [med_ans_1, ()=>achse2_y+boxplot_height_ans_1/2]
],{
   fixed:true,
   strokeColor:middleColor
});
// Eventlistener für Mouse-Hovering
median_ans_1.on('over', function(e){
    median_ans_text_1.setAttribute({visible:true});
});
median_ans_1.on('out', function(e){
    median_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let median_ansActive_1 = false;
median_ans_1.on('down', function(e){
    if(median_ansActive_1){
        median_ans_text_1.setAttribute({visible:false});
    } else{
        median_ans_text_1.setAttribute({visible:true});
    }
    median_ansActive_1 = !median_ansActive_1;
});

// === Box ===
const uquantil_ans_text_1 = board.create('text',[
   uquantil_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Unteres Quartil = '+uquantil_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const oquantil_ans_text_1 = board.create('text',[
   oquantil_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Oberes Quartil = '+oquantil_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const box_ans_1 = board.create('polygon',[polans_1,porans_1,purans_1,pulans_1],{
    fillColor:middleColor,
    highlight:false,
    borders:{strokeWidth:2, strokeColor:middleColor, highlightStrokeColor:'grey'}
});
box_ans_1.borders[2].setAttribute({highlight:false});
box_ans_1.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box_ans_1.borders[3].on('over', function(e){
    uquantil_ans_text_1.setAttribute({visible:true});
});
box_ans_1.borders[3].on('out', function(e){
    uquantil_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantil_ansActive_1 = false;
box_ans_1.borders[3].on('down', function(e){
    if(uquantil_ansActive_1){
        uquantil_ans_text_1.setAttribute({visible:false});
    } else{
        uquantil_ans_text_1.setAttribute({visible:true});
    }
    uquantil_ansActive_1 = !uquantil_ansActive_1;
});

// Eventlistener für Mouse-Hovering
box_ans_1.borders[1].on('over', function(e){
    oquantil_ans_text_1.setAttribute({visible:true});
});
box_ans_1.borders[1].on('out', function(e){
    oquantil_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantil_ansActive_1 = false;
box_ans_1.borders[1].on('down', function(e){
    if(oquantil_ansActive_1){
        oquantil_ans_text_1.setAttribute({visible:false});
    } else{
        oquantil_ans_text_1.setAttribute({visible:true});
    }
    oquantil_ansActive_1 = !oquantil_ansActive_1;
});

// === Ausreißer-Punkte ===
for(let j of ausreisser_x_array_1){
   board.create('point',[j,achse2_y],{
      fixed:true,
      withLabel:false,
      color:middleColor,
      showInfobox:false
   }
)};

// === Datenpunkte ===
for(let j of datapoints_x_array_1){
   board.create('point',[j, datapoints2_y_1],{
      withLabel:false,
      fixed:true,
      face:'x',
      visible:function(){return checkbox.Value()},
      color:datenpunkte_farbe
   }
)};


// ====================================================
// ============= Boxplot aus der Aufgabenstellung =============
// ====================================================

// === Beschriftung unterer Boxplot ===
const beschriftung_aufg = board.create('text',[
   board.getBoundingBox()[0],
   0,
   'Boxplot<br>aus der<br>Aufgaben-<br>stellung'
],{
   fixed:true,
   color:lowerColor,
   highlight:false
});
beschriftung_aufg.rendNode.style.background=labelBackgroundColor2;
beschriftung_aufg.rendNode.style.padding="3px";

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const pol = board.create('point',[
   uquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pul = board.create('point',[
   uquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});
const por = board.create('point',[
   oquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pur = board.create('point',[
   oquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_text = board.create('text',[
   antenne_links-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Linke Antenne = '+antenne_links
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const grenze_links = board.create('segment',[
   [antenne_links, ()=>0-antennen_height/2],
   [antenne_links, ()=>0+antennen_height/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_links.on('over', function(e){
    grenze_links_text.setAttribute({visible:true});
});
grenze_links.on('out', function(e){
    grenze_links_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_linksActive = false;
grenze_links.on('down', function(e){
    if(grenze_linksActive){
        grenze_links_text.setAttribute({visible:false});
    } else{
        grenze_links_text.setAttribute({visible:true});
    }
    grenze_linksActive = !grenze_linksActive;
});

// === Rechte Antenne ===
const grenze_rechts_text = board.create('text',[
   antenne_rechts-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const grenze_rechts = board.create('segment',[
   [antenne_rechts, ()=>0-antennen_height/2],
   [antenne_rechts, ()=>0+antennen_height/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts.on('over', function(e){
    grenze_rechts_text.setAttribute({visible:true});
});
grenze_rechts.on('out', function(e){
    grenze_rechts_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechtsActive = false;
grenze_rechts.on('down', function(e){
    if(grenze_rechtsActive){
        grenze_rechts_text.setAttribute({visible:false});
    } else{
        grenze_rechts_text.setAttribute({visible:true});
    }
    grenze_rechtsActive = !grenze_rechtsActive;
});

// === Grundlinien ===
const grundlinie_links = board.create('segment',[
   [antenne_links,0],
   [uquantil,0]
],{
   fixed:true,
   strokeColor:lowerColor,
   highlight:false
});
const grundlinie_rechts = board.create('segment',[
   [oquantil,0],
   [antenne_rechts,0]
],{
   fixed:true,
   strokeColor:lowerColor,
   highlight:false
});

// === Median ===
const median_text = board.create('text',[
   med-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Median ='+med
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const median = board.create('segment',[
   [med, ()=>0-boxplot_height/2],
   [med, ()=>0+boxplot_height/2]
],{
   fixed:true,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
median.on('over', function(e){
    median_text.setAttribute({visible:true});
});
median.on('out', function(e){
    median_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let medianActive = false;
median.on('down', function(e){
    if(medianActive){
        median_text.setAttribute({visible:false});
    } else{
        median_text.setAttribute({visible:true});
    }
    medianActive = !medianActive;
});

// === Box ===
const uquantil_text = board.create('text',[
   uquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Unteres Quartil = '+uquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const oquantil_text = board.create('text',[
   oquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Oberes Quartil = '+oquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const box = board.create('polygon',[pol,por,pur,pul],{
    fillColor:lowerColor,
    highlight:false,
    borders:{strokeWidth:2, highlightStrokeColor:'grey', strokeColor:lowerColor}
});
box.borders[2].setAttribute({highlight:false});
box.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box.borders[3].on('over', function(e){
    uquantil_text.setAttribute({visible:true});
});
box.borders[3].on('out', function(e){
    uquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantilActive = false;
box.borders[3].on('down', function(e){
    if(uquantilActive){
        uquantil_text.setAttribute({visible:false});
    } else{
        uquantil_text.setAttribute({visible:true});
    }
    uquantilActive = !uquantilActive;
});

// Eventlistener für Mouse-Hovering
box.borders[1].on('over', function(e){
    oquantil_text.setAttribute({visible:true});
});
box.borders[1].on('out', function(e){
    oquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantilActive = false;
box.borders[1].on('down', function(e){
    if(oquantilActive){
        oquantil_text.setAttribute({visible:false});
    } else{
        oquantil_text.setAttribute({visible:true});
    }
    oquantilActive = !oquantilActive;
});

// ===================================================
// ===================== Hilfslinien: ================
// ===================================================
const grenze_links_ans_linie = board.create('segment',[
   [antenne_links_ans,ende_hilfslinien],
   [antenne_links_ans, ()=>achse3_y-antennen_height/2]
],{
   fixed:true,
   color:()=> (antenne_links_ans==antenne_links) ? 'green' : ({#ausreisser_unten_orange and ausreisser_unten_wert_ans="keiner"#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (antenne_links_ans==antenne_links) ? 2 : 1
});

const uquartil_linie = board.create('segment',[
   pulans,
   [uquantil_ans, ende_hilfslinien]
],{
    fixed:true,
    color: ()=> (polans.X()==pol.X()) ? 'green' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> (polans.X()==pol.X()) ? 2 : 1
});

const median_ans_linie = board.create('segment',[
   [med_ans, ()=>achse3_y-boxplot_height/2],
   [med_ans,ende_hilfslinien]
],{
    fixed:true,
    color:()=> (med_ans==med) ? 'green' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> (med_ans==med) ? 2 : 1
});

const oquartil_linie = board.create('segment',[
   purans,
   [oquantil_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=> (porans.X()==por.X()) ? 'green' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (porans.X()==por.X()) ? 2 : 1
});

const grenze_rechts_ans_linie = board.create('segment',[
   [antenne_rechts_ans, ()=>achse3_y-antennen_height/2],
   [antenne_rechts_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=> (antenne_rechts_ans==antenne_rechts) ? 'green' : ({#ausreisser_oben_orange and ausreisser_oben_wert_ans="keiner"#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (antenne_rechts_ans==antenne_rechts) ? 2 : 1
});

const ausreisser_rechts_linie = board.create('segment',[
   [ausreisser_oben_wert_ans,achse3_y],
   [ausreisser_oben_wert_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>({#ausreisser_oben_orange#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:() => ({#ausreisser_oben_orange#}) ? 0 : 1
});

const ausreisser_links_linie = board.create('segment',[
   [ausreisser_unten_wert_ans,achse3_y],
   [ausreisser_unten_wert_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=> ({#ausreisser_unten_orange#}) ? 'orange' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> ({#ausreisser_unten_orange#}) ? 0 : 1
});
[[/jsxgraph]]

<p><i>Wenn Sie mit der Maus über die einzelnen Kennwerte der beiden Boxplots fahren, werden deren Werte eingeblendet. Auf Touch-Screens müssen die Kennwerte angetippt werden.</i></p>

<p>Die <span style="color:green">grünen</span> gestrichelten Hilfslinien, die Sie mithilfe der Checkbox aktivieren können, zeigen Ihnen, dass die Kennwerte jeweils übereinstimmen.</p>
<hr>
<p>Die folgende Checkliste ist eine Übersicht über die Kennziffern der Boxplots. Die grünen Haken kennzeichnen, dass die jeweiligen Werte beider Boxplots übereinstimmen. Wenn Sie auf die Kenngrößen klicken, wird Ihnen eine Erklärung angezeigt.</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>6</falsenextnode>
        <falseanswernote>prt1_neu-6-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p class="incorrect"><span style="font-size: 1.5em; color:red;"><i class="fa fa-times"></i></span> Falsche Antwort.</p>
<hr>

<p>In der folgenden Abbildung sehen Sie oben die von Ihnen angegebenen Daten und den zugehörigen <span style="color:{@boxplot_antwort_1@}"> Boxplot aus Ihrer ersten Antwort {@ans1_copy@}</span>. In der Mitte sehen Sie die Daten  und den <span style="color:{@boxplot_antwort_2@}">Boxplot aus Ihrer letzten Antwort {@ans1_neu@}</span>. Ganz unten sehen Sie den <span style="color:{@boxplot_aufgabenstellung@}">Boxplot aus der Aufgabenstellung</span>.</p>

[[jsxgraph]]
JXG.Options.line.strokeWidth = 2;
JXG.Options.line.dash = 1;
JXG.Options.line.straightFirst = false;
JXG.Options.segment.dash = 0;

// Verwendete Farben:
const upperColor = {#boxplot_antwort_2#}; // Farbe des Boxplots aus der zweiten Antwort
const middleColor = {#boxplot_antwort_1#}; // Farbe des Boxplots aus der ersten Antwort
const lowerColor = {#boxplot_aufgabenstellung#}; //Farbe des unteren Boxplots aus der Aufgabenstellung
const datenpunkte_farbe = {#datenpunkte#};  // Farbe Datenpunkte letzte Antwort
const datenpunkte_farbe_1 = {#datenpunkte#}; // Farbe Datenpunkte erste Antwort
const labelBackgroundColor2 = {#label_background#};


// Ändert Schriftfarbe der "Legende"
document.querySelectorAll('.oer-aufgabe-23_farbe_oben_2').forEach(el=>el.style.color=upperColor);
document.querySelectorAll('.oer-aufgabe-23_farbe_mitte_2').forEach(el=>el.style.color=middleColor);
document.querySelectorAll('.oer-aufgabe-23_farbe_unten_2').forEach(el=>el.style.color=lowerColor);

const boxplot_height = 1.2; // Höhe des Boxplots aus der Aufgabenstellung
const antennen_height = 0.6; // Höhe der Antennen des Boxplots aus der Aufgabenstellung

const achse2_y = 4; // y-Position der zweiten x-Achse (für den Boxplot aus der ersten Antwort)
const achse3_y = 2; // y-Position der zweiten x-Achse (für den Boxplot aus letzten Antwort)
const boxplot_height_ans = 1.2; // Höhe des Boxplots aus der letzten Antwort
const boxplot_height_ans_1 = 1.2; // Höhe des Boxplots aus der ersten Antwort
const antennen_height_ans = 0.6; // Höhe der Antennen des Boxplots aus der letzten Antwort
const antennen_height_ans_1 = 0.6; // Höhe der Antennen des Boxplots aus der ersten Antwort

const datapoints2_y = 2; // y-Position der Datenpunkte aus der letzten Antwort
const datapoints2_y_1 = 4; // y-Position der Datenpunkte aus der ersten Antwort

const ende_hilfslinien = -1.3; // Unteres Ende der Hilfslinien

const highest_position = Math.max(
   achse3_y+0.5*boxplot_height+0.4,
   datapoints2_y_1+0.4,
   achse2_y+0.5*boxplot_height+0.4,
   datapoints2_y+0.4
);

const mini_global_1 = {#float(mini_global_1)#};
const ampl_global_1 = {#float(ampl_global_1)#};
const maxi_global_1 = {#float(maxi_global_1)#};
const mini_global = {#float(mini_global)#};
const uquantil_ans = {#float(uquantil_ans)#};
const oquantil_ans = {#float(oquantil_ans)#};
const antenne_links_ans = {#float(antenne_links_ans)#};
const antenne_rechts_ans = {#float(antenne_rechts_ans)#};
const med_ans = {#float(med_ans)#};
const ausreisser_x_array = {#float(ausreisser_punkte_x_ans)#};
const datapoints_x_array = {#float(L2)#};
const uquantil_ans_1 = {#float(uquantil_ans_1)#};
const oquantil_ans_1 = {#float(oquantil_ans_1)#};
const antenne_links_ans_1 = {#float(antenne_links_ans_1)#};
const antenne_rechts_ans_1 = {#float(antenne_rechts_ans_1)#};
const med_ans_1 = {#float(med_ans_1)#};
const ausreisser_x_array_1 = {#ausreisser_punkte_x_ans_1#};
const datapoints_x_array_1 = {#L2_1#}; 
const uquantil = {#float(uquantil)#};
const oquantil = {#float(oquantil)#};
const antenne_links = {#float(antenne_links)#};
const antenne_rechts = {#float(antenne_rechts)#};
const med = {#float(med)#}
const ausreisser_oben_wert_ans = {#float(ausreisser_oben_wert_ans)#};
const ausreisser_unten_wert_ans = {#float(ausreisser_unten_wert_ans)#}; 

const board = JXG.JSXGraph.initBoard(divid, {
    axis:true,
    boundingbox: [mini_global_1-0.2*ampl_global_1, highest_position+0.5, maxi_global_1+0.2*ampl_global_1, -2],
    showCopyright:false,
	showNavigation:false,
    defaultAxes:{
        x:{lastArrow:false,
            ticks:{drawZero:true}
        },
        y:{lastArrow:false,
            visible:false,
            ticks:{drawLabels:false, drawZero:true}
        }
    }
});
// Setze Hintergrundfarbe auf weiß:
board.renderer.container.style.backgroundColor = '#fff';

// === Anstatt der automatisch angezeigten Koordinaten für Punkte soll das Label in der Form "Wert = X" erscheinen ===
board.highlightInfobox = function(x,y,el) {
    this.infobox.setText('Wert = ' + x);
    this.infobox.rendNode.style.color = 'black';
    this.infobox.rendNode.style.padding = '5px';
    this.infobox.rendNode.style.backgroundColor = 'white';
};

// === Checkboxes ===
const checkbox = board.create('checkbox',[
   mini_global,
   -1.5,
   'Zeige/verberge Datenpunkte'
],{
   checked:true,
   fixed:true
});
const checkbox_Linien = board.create('checkbox',[
   mini_global,
   -1.8,
   'Zeige/verberge Hilfslinien'
],{
   checked:false,
   fixed:true
});

// ===========================================================
// ================ Boxplot aus der letzten Antwort ==========
// ===========================================================

// === Beschriftung oberer Boxplot ===
const beschriftung_ans = board.create('text',[
   board.getBoundingBox()[0],
   achse3_y,
   'Boxplot<br>aus Ihrer<br>letzten<br>Antwort'
],{
   fixed:true,
   color:upperColor,
   highlight:false
});
beschriftung_ans.rendNode.style.background=labelBackgroundColor2;
beschriftung_ans.rendNode.style.padding="3px";

// === Obere Achse ===
const achse3 = board.create('axis', [
   [0, achse3_y],
   [1, achse3_y]
],{
   ticks:{drawLabels:false},
   lastArrow:false
});

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const polans = board.create('point',[
   uquantil_ans,
   ()=>achse3_y+boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const pulans = board.create('point',[
   uquantil_ans,
   ()=>achse3_y-boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const porans = board.create('point',[
   oquantil_ans,
   ()=>achse3_y+boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});
const purans = board.create('point',[
   oquantil_ans,
   ()=>achse3_y-boxplot_height_ans/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_ans_text = board.create('text',[
   antenne_links_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Linke Antenne = '+antenne_links_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_links_ans = board.create('segment',[
   [antenne_links_ans, ()=>achse3_y-antennen_height_ans/2],
   [antenne_links_ans, ()=>achse3_y+antennen_height_ans/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_links_ans.on('over', function(e){
    grenze_links_ans_text.setAttribute({visible:true});
});
grenze_links_ans.on('out', function(e){
    grenze_links_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_links_ansActive = false;
grenze_links_ans.on('down', function(e){
    if(grenze_links_ansActive){
        grenze_links_ans_text.setAttribute({visible:false});
    } else{
        grenze_links_ans_text.setAttribute({visible:true});
    }
    grenze_links_ansActive = !grenze_links_ansActive;
});

// === Rechte Antenne ===
const grenze_rechts_ans_text = board.create('text',[
   antenne_rechts_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const grenze_rechts_ans = board.create('segment',[
   [antenne_rechts_ans, ()=>achse3_y-antennen_height_ans/2],
   [antenne_rechts_ans, ()=>achse3_y+antennen_height_ans/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts_ans.on('over', function(e){
    grenze_rechts_ans_text.setAttribute({visible:true});
});
grenze_rechts_ans.on('out', function(e){
    grenze_rechts_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechts_ansActive = false;
grenze_rechts_ans.on('down', function(e){
    if(grenze_rechts_ansActive){
        grenze_rechts_ans_text.setAttribute({visible:false});
    } else{
        grenze_rechts_ans_text.setAttribute({visible:true});
    }
    grenze_rechts_ansActive = !grenze_rechts_ansActive;
});

// === Grundlinien ===
const grundlinie_links_ans = board.create('segment',[
   [antenne_links_ans,achse3_y],
   [uquantil_ans,achse3_y]
],{
    fixed:true,
   strokeColor:upperColor,
   highlight:false
});
const grundlinie_rechts_ans = board.create('segment',[
   [oquantil_ans,achse3_y],
   [antenne_rechts_ans,achse3_y]
],{
   fixed:true,
   strokeColor:upperColor,
   highlight:false
});

// === Median ===
const median_ans_text = board.create('text',[
   med_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Median = '+med_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const median_ans = board.create('segment',[
   [med_ans, ()=>achse3_y-boxplot_height_ans/2],
   [med_ans, ()=>achse3_y+boxplot_height_ans/2]
],{
   fixed:true,
   strokeColor:upperColor
});
// Eventlistener für Mouse-Hovering
median_ans.on('over', function(e){
    median_ans_text.setAttribute({visible:true});
});
median_ans.on('out', function(e){
    median_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let median_ansActive = false;
median_ans.on('down', function(e){
    if(median_ansActive){
        median_ans_text.setAttribute({visible:false});
    } else{
        median_ans_text.setAttribute({visible:true});
    }
    median_ansActive = !median_ansActive;
});

// === Box ===
const uquantil_ans_text = board.create('text',[
   uquantil_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Unteres Quartil = '+uquantil_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const oquantil_ans_text = board.create('text',[
   oquantil_ans-1,
   ()=>achse3_y+boxplot_height_ans/2+0.4,
   ()=>'Oberes Quartil = '+oquantil_ans
],{
   visible:false,
   fixed:true,
   color:upperColor
});
const box_ans = board.create('polygon',[polans,porans,purans,pulans],{
    fillColor:upperColor,
    highlight:false,
    borders:{strokeWidth:2, strokeColor:upperColor, highlightStrokeColor:'grey'}
});
box_ans.borders[2].setAttribute({highlight:false});
box_ans.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box_ans.borders[3].on('over', function(e){
    uquantil_ans_text.setAttribute({visible:true});
});
box_ans.borders[3].on('out', function(e){
    uquantil_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantil_ansActive = false;
box_ans.borders[3].on('down', function(e){
    if(uquantil_ansActive){
        uquantil_ans_text.setAttribute({visible:false});
    } else{
        uquantil_ans_text.setAttribute({visible:true});
    }
    uquantil_ansActive = !uquantil_ansActive;
});

// Eventlistener für Mouse-Hovering
box_ans.borders[1].on('over', function(e){
    oquantil_ans_text.setAttribute({visible:true});
});
box_ans.borders[1].on('out', function(e){
    oquantil_ans_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantil_ansActive = false;
box_ans.borders[1].on('down', function(e){
    if(oquantil_ansActive){
        oquantil_ans_text.setAttribute({visible:false});
    } else{
        oquantil_ans_text.setAttribute({visible:true});
    }
    oquantil_ansActive = !oquantil_ansActive;
});

// === Ausreißer-Punkte ===
for(let j of ausreisser_x_array){
   board.create('point',[j,achse3_y],{
    fixed:true,
    withLabel:false,
    color:upperColor,
    showInfobox:false
   })
};

// === Datenpunkte ===
for(let j of datapoints_x_array){board.create('point',[j, datapoints2_y],{
   withLabel:false,
   fixed:true,
   face:'x',
   visible:function(){return checkbox.Value()},
   color:datenpunkte_farbe
}) };


// ========================================================
// ================ Boxplot aus der ersten Antwort ========
// ========================================================

// === Beschriftung mittlerer Boxplot ===
const beschriftung_ans_1 = board.create('text',[
   board.getBoundingBox()[0],
   achse2_y,'Boxplot<br>aus Ihrer<br>ersten<br>Antwort'
],{
   fixed:true,
   color:middleColor,
   highlight:false
});
beschriftung_ans_1.rendNode.style.background=labelBackgroundColor2;
beschriftung_ans_1.rendNode.style.padding="3px";

// === Obere Achse ===
const achse2 = board.create('axis', [
   [0, achse2_y],
   [1, achse2_y]
],{
   ticks:{drawLabels:false},
   lastArrow:false
});

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const polans_1 = board.create('point',[
   uquantil_ans_1,
   ()=>achse2_y+boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});
const pulans_1 = board.create('point',[
   uquantil_ans_1,
   ()=>achse2_y-boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});
const porans_1 = board.create('point',[
   oquantil_ans_1,
   ()=>achse2_y+boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});
const purans_1 = board.create('point',[
   oquantil_ans_1,
   ()=>achse2_y-boxplot_height_ans_1/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_ans_text_1 = board.create('text',[
   antenne_links_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Linke Antenne = '+antenne_links_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const grenze_links_ans_1 = board.create('segment',[
   [antenne_links_ans_1, ()=>achse2_y-antennen_height_ans_1/2],
   [antenne_links_ans_1, ()=>achse2_y+antennen_height_ans_1/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:middleColor
});
// Eventlistener für Mouse-Hovering
grenze_links_ans_1.on('over', function(e){
    grenze_links_ans_text_1.setAttribute({visible:true});
});
grenze_links_ans_1.on('out', function(e){
    grenze_links_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_links_ansActive_1 = false;
grenze_links_ans_1.on('down', function(e){
    if(grenze_links_ansActive_1){
        grenze_links_ans_text_1.setAttribute({visible:false});
    } else{
        grenze_links_ans_text_1.setAttribute({visible:true});
    }
    grenze_links_ansActive_1 = !grenze_links_ansActive_1;
});

// === Rechte Antenne ===
const grenze_rechts_ans_text_1 = board.create('text',[
   antenne_rechts_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const grenze_rechts_ans_1 = board.create('segment',[
   [antenne_rechts_ans_1, ()=>achse2_y-antennen_height_ans_1/2],
   [antenne_rechts_ans_1, ()=>achse2_y+antennen_height_ans_1/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:middleColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts_ans_1.on('over', function(e){
    grenze_rechts_ans_text_1.setAttribute({visible:true});
});
grenze_rechts_ans_1.on('out', function(e){
    grenze_rechts_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechts_ansActive_1 = false;
grenze_rechts_ans_1.on('down', function(e){
    if(grenze_rechts_ansActive_1){
        grenze_rechts_ans_text_1.setAttribute({visible:false});
    } else{
        grenze_rechts_ans_text_1.setAttribute({visible:true});
    }
    grenze_rechts_ansActive_1 = !grenze_rechts_ansActive_1;
});

// === Grundlinien ===
const grundlinie_links_ans_1 = board.create('segment',[
   [antenne_links_ans_1,achse2_y],
   [uquantil_ans_1,achse2_y]
],{
   fixed:true,
   strokeColor:middleColor,
   highlight:false
});
const grundlinie_rechts_ans_1 = board.create('segment',[
   [oquantil_ans_1,achse2_y],
   [antenne_rechts_ans_1,achse2_y]
],{
   fixed:true,
   strokeColor:middleColor,
   highlight:false
});

// === Median ===
const median_ans_text_1 = board.create('text',[
   med_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Median = '+med_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const median_ans_1 = board.create('segment',[
   [med_ans_1, ()=>achse2_y-boxplot_height_ans_1/2],
   [med_ans_1, ()=>achse2_y+boxplot_height_ans_1/2]
],{
   fixed:true,
   strokeColor:middleColor
});
// Eventlistener für Mouse-Hovering
median_ans_1.on('over', function(e){
    median_ans_text_1.setAttribute({visible:true});
});
median_ans_1.on('out', function(e){
    median_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let median_ansActive_1 = false;
median_ans_1.on('down', function(e){
    if(median_ansActive_1){
        median_ans_text_1.setAttribute({visible:false});
    } else{
        median_ans_text_1.setAttribute({visible:true});
    }
    median_ansActive_1 = !median_ansActive_1;
});

// === Box ===
const uquantil_ans_text_1 = board.create('text',[
   uquantil_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Unteres Quartil = '+uquantil_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const oquantil_ans_text_1 = board.create('text',[
   oquantil_ans_1-1,
   ()=>achse2_y+boxplot_height_ans_1/2+0.4,
   ()=>'Oberes Quartil = '+oquantil_ans_1
],{
   visible:false,
   fixed:true,
   color:middleColor
});
const box_ans_1 = board.create('polygon',[polans_1,porans_1,purans_1,pulans_1],{
    fillColor:middleColor,
    highlight:false,
    borders:{strokeWidth:2, strokeColor:middleColor, highlightStrokeColor:'grey'}
});
box_ans_1.borders[2].setAttribute({highlight:false});
box_ans_1.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box_ans_1.borders[3].on('over', function(e){
    uquantil_ans_text_1.setAttribute({visible:true});
});
box_ans_1.borders[3].on('out', function(e){
    uquantil_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantil_ansActive_1 = false;
box_ans_1.borders[3].on('down', function(e){
    if(uquantil_ansActive_1){
        uquantil_ans_text_1.setAttribute({visible:false});
    } else{
        uquantil_ans_text_1.setAttribute({visible:true});
    }
    uquantil_ansActive_1 = !uquantil_ansActive_1;
});

// Eventlistener für Mouse-Hovering
box_ans_1.borders[1].on('over', function(e){
    oquantil_ans_text_1.setAttribute({visible:true});
});
box_ans_1.borders[1].on('out', function(e){
    oquantil_ans_text_1.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantil_ansActive_1 = false;
box_ans_1.borders[1].on('down', function(e){
    if(oquantil_ansActive_1){
        oquantil_ans_text_1.setAttribute({visible:false});
    } else{
        oquantil_ans_text_1.setAttribute({visible:true});
    }
    oquantil_ansActive_1 = !oquantil_ansActive_1;
});

// === Ausreißer-Punkte ===
for(let j of ausreisser_x_array_1){
   board.create('point',[j,achse2_y],{
      fixed:true,
      withLabel:false,
      color:middleColor,
      showInfobox:false
   }
)};

// === Datenpunkte ===
for(let j of datapoints_x_array_1){
   board.create('point',[j, datapoints2_y_1],{
      withLabel:false,
      fixed:true,
      face:'x',
      visible:function(){return checkbox.Value()},
      color:datenpunkte_farbe
   }
)};


// ====================================================
// ============= Boxplot aus der Aufgabenstellung =============
// ====================================================

// === Beschriftung unterer Boxplot ===
const beschriftung_aufg = board.create('text',[
   board.getBoundingBox()[0],
   0,
   'Boxplot<br>aus der<br>Aufgaben-<br>stellung'
],{
   fixed:true,
   color:lowerColor,
   highlight:false
});
beschriftung_aufg.rendNode.style.background=labelBackgroundColor2;
beschriftung_aufg.rendNode.style.padding="3px";

// ==== Unsichtbare Punkte zur Konstruktion der Box ====
const pol = board.create('point',[
   uquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pul = board.create('point',[
   uquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});
const por = board.create('point',[
   oquantil,
   ()=>boxplot_height/2
],{
   visible:false,
   fixed:true
});
const pur = board.create('point',[
   oquantil,
   ()=>0-boxplot_height/2
],{
   visible:false,
   fixed:true
});

// === Linke Antenne ===
const grenze_links_text = board.create('text',[
   antenne_links-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Linke Antenne = '+antenne_links
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const grenze_links = board.create('segment',[
   [antenne_links, ()=>0-antennen_height/2],
   [antenne_links, ()=>0+antennen_height/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_links.on('over', function(e){
    grenze_links_text.setAttribute({visible:true});
});
grenze_links.on('out', function(e){
    grenze_links_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_linksActive = false;
grenze_links.on('down', function(e){
    if(grenze_linksActive){
        grenze_links_text.setAttribute({visible:false});
    } else{
        grenze_links_text.setAttribute({visible:true});
    }
    grenze_linksActive = !grenze_linksActive;
});

// === Rechte Antenne ===
const grenze_rechts_text = board.create('text',[
   antenne_rechts-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Rechte Antenne = '+antenne_rechts
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const grenze_rechts = board.create('segment',[
   [antenne_rechts, ()=>0-antennen_height/2],
   [antenne_rechts, ()=>0+antennen_height/2]
],{
   fixed:true,
   strokeWidth:3,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
grenze_rechts.on('over', function(e){
    grenze_rechts_text.setAttribute({visible:true});
});
grenze_rechts.on('out', function(e){
    grenze_rechts_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let grenze_rechtsActive = false;
grenze_rechts.on('down', function(e){
    if(grenze_rechtsActive){
        grenze_rechts_text.setAttribute({visible:false});
    } else{
        grenze_rechts_text.setAttribute({visible:true});
    }
    grenze_rechtsActive = !grenze_rechtsActive;
});

// === Grundlinien ===
const grundlinie_links = board.create('segment',[
   [antenne_links,0],
   [uquantil,0]
],{
   fixed:true,
   strokeColor:lowerColor,
   highlight:false
});
const grundlinie_rechts = board.create('segment',[
   [oquantil,0],
   [antenne_rechts,0]
],{
   fixed:true,
   strokeColor:lowerColor,
   highlight:false
});

// === Median ===
const median_text = board.create('text',[
   med-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Median ='+med
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const median = board.create('segment',[
   [med, ()=>0-boxplot_height/2],
   [med, ()=>0+boxplot_height/2]
],{
   fixed:true,
   strokeColor:lowerColor
});
// Eventlistener für Mouse-Hovering
median.on('over', function(e){
    median_text.setAttribute({visible:true});
});
median.on('out', function(e){
    median_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let medianActive = false;
median.on('down', function(e){
    if(medianActive){
        median_text.setAttribute({visible:false});
    } else{
        median_text.setAttribute({visible:true});
    }
    medianActive = !medianActive;
});

// === Box ===
const uquantil_text = board.create('text',[
   uquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Unteres Quartil = '+uquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const oquantil_text = board.create('text',[
   oquantil-1,
   ()=>0+boxplot_height/2+0.4,
   ()=>'Oberes Quartil = '+oquantil
],{
   visible:false,
   fixed:true,
   color:lowerColor
});
const box = board.create('polygon',[pol,por,pur,pul],{
    fillColor:lowerColor,
    highlight:false,
    borders:{strokeWidth:2, highlightStrokeColor:'grey', strokeColor:lowerColor}
});
box.borders[2].setAttribute({highlight:false});
box.borders[0].setAttribute({highlight:false});
// Eventlistener für Mouse-Hovering
box.borders[3].on('over', function(e){
    uquantil_text.setAttribute({visible:true});
});
box.borders[3].on('out', function(e){
    uquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let uquantilActive = false;
box.borders[3].on('down', function(e){
    if(uquantilActive){
        uquantil_text.setAttribute({visible:false});
    } else{
        uquantil_text.setAttribute({visible:true});
    }
    uquantilActive = !uquantilActive;
});

// Eventlistener für Mouse-Hovering
box.borders[1].on('over', function(e){
    oquantil_text.setAttribute({visible:true});
});
box.borders[1].on('out', function(e){
    oquantil_text.setAttribute({visible:false});
});
// Eventlistener für Touch
let oquantilActive = false;
box.borders[1].on('down', function(e){
    if(oquantilActive){
        oquantil_text.setAttribute({visible:false});
    } else{
        oquantil_text.setAttribute({visible:true});
    }
    oquantilActive = !oquantilActive;
});

// ===================================================
// ===================== Hilfslinien: ================
// ===================================================
const grenze_links_ans_linie = board.create('segment',[
   [antenne_links_ans,ende_hilfslinien],
   [antenne_links_ans, ()=>achse3_y-antennen_height/2]
],{
   fixed:true,
   color:()=> (antenne_links_ans==antenne_links) ? 'green' : ({#ausreisser_unten_orange and ausreisser_unten_wert_ans="keiner"#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (antenne_links_ans==antenne_links) ? 2 : 1
});

const uquartil_linie = board.create('segment',[
   pulans,
   [uquantil_ans, ende_hilfslinien]
],{
    fixed:true,
    color: ()=> (polans.X()==pol.X()) ? 'green' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> (polans.X()==pol.X()) ? 2 : 1
});

const median_ans_linie = board.create('segment',[
   [med_ans, ()=>achse3_y-boxplot_height/2],
   [med_ans,ende_hilfslinien]
],{
    fixed:true,
    color:()=> (med_ans==med) ? 'green' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> (med_ans==med) ? 2 : 1
});

const oquartil_linie = board.create('segment',[
   purans,
   [oquantil_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=> (porans.X()==por.X()) ? 'green' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (porans.X()==por.X()) ? 2 : 1
});

const grenze_rechts_ans_linie = board.create('segment',[
   [antenne_rechts_ans, ()=>achse3_y-antennen_height/2],
   [antenne_rechts_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=> (antenne_rechts_ans==antenne_rechts) ? 'green' : ({#ausreisser_oben_orange and ausreisser_oben_wert_ans="keiner"#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:()=> (antenne_rechts_ans==antenne_rechts) ? 2 : 1
});

const ausreisser_rechts_linie = board.create('segment',[
   [ausreisser_oben_wert_ans,achse3_y],
   [ausreisser_oben_wert_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=>({#ausreisser_oben_orange#}) ? 'orange' : 'red',
   visible:()=>checkbox_Linien.Value(),
   highlight:false,
   dash:() => ({#ausreisser_oben_orange#}) ? 0 : 1
});

const ausreisser_links_linie = board.create('segment',[
   [ausreisser_unten_wert_ans,achse3_y],
   [ausreisser_unten_wert_ans,ende_hilfslinien]
],{
   fixed:true,
   color:()=> ({#ausreisser_unten_orange#}) ? 'orange' : 'red',
    visible:()=>checkbox_Linien.Value(),
    highlight:false,
    dash:()=> ({#ausreisser_unten_orange#}) ? 0 : 1
});
[[/jsxgraph]]

<p><i>Wenn Sie mit der Maus über die einzelnen Kennwerte der beiden Boxplots fahren, werden deren Werte eingeblendet. Auf Touch-Screens müssen die Kennwerte angetippt werden.</i></p>

<p> Die Hilfslinien, die Sie mithilfe der Checkbox aktivieren können, zeigen Ihnen, welche Kennwerte übereinstimmen (<span style="color:green">grüne</span> gestrichelte Hilfslinien) und welche nicht (<span style="color:red">rote</span> gepunktete Hilfslinien).
</p>

<hr>

<p>In der folgenden Checkliste können Sie sehen, welche der Kennziffern übereinstimmen. Wenn Sie auf die Kenngrößen klicken, wird Ihnen eine Erklärung angezeigt.</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>6</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>antenne_links_ans</sans>
        <tans>antenne_links</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>7</truenextnode>
        <trueanswernote>prt1_neu-7-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Die <b>linke Antenne</b> erstreckt sich nach links zum kleinsten Wert des Datensatzes, der höchstens 1,5 Interquartilsabstände vom Kasten entfernt ist.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Linke Antenne</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>7</falsenextnode>
        <falseanswernote>prt1_neu-7-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Die <b>linke Antenne</b> erstreckt sich nach links zum kleinsten Wert des Datensatzes, der höchstens 1,5 Interquartilsabstände vom Kasten entfernt ist.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Linke Antenne</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
</div>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>7</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>uquantil_ans</sans>
        <tans>uquantil</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>8</truenextnode>
        <trueanswernote>prt1_neu-8-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Das <b>untere Quartil</b> ist derjenige Wert aus dem Datensatz, für den gilt, dass 25 % aller Werte kleiner als dieser oder gleich diesem sind. Analog zum Median kann auch hier eine Mittelwertbildung stattfinden.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Unteres Quartil</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>8</falsenextnode>
        <falseanswernote>prt1_neu-8-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Das <b>untere Quartil</b> ist derjenige Wert aus dem Datensatz, für den gilt, dass 25 % aller Werte kleiner als dieser oder gleich diesem sind. Analog zum Median kann auch hier eine Mittelwertbildung stattfinden.</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Unteres Quartil</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
</div>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>8</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>med_ans</sans>
        <tans>med</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>10</truenextnode>
        <trueanswernote>prt1_neu-9-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Der <b>Median</b> ist derjenige Wert, der in der geordneten Liste genau in der Mitte liegt bzw. das arithmetische Mittel aus den beiden in der Mitte liegenden Werten (falls die Anzahl der Werte gerade ist).</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Median</span> <span style="font-size: 1em; color:green;"><i class="fa fa-check"></i></span>
	</a>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>9</falsenextnode>
        <falseanswernote>prt1_neu-9-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>9</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>arit_ans</sans>
        <tans>med</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>10</truenextnode>
        <trueanswernote>prt1_neu-10-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Der <b>Median</b> ist derjenige Wert, der in der geordneten Liste genau in der Mitte liegt bzw. das arithmetische Mittel aus den beiden in der Mitte liegenden Werten (falls die Anzahl der Werte gerade ist).</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Median</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
	<br>
	<i>Stattdessen stimmt das <i>arithmetische Mittel</i> Ihrer Daten aber mit dem im gegebenen Boxplot eingezeichneten Median überein. Kann es sein, dass Sie die beiden verwechselt haben?</i>
</div>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>10</falsenextnode>
        <falseanswernote>prt1_neu-10-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<div class="collapsibleregioncaption">
	<a class="btn btn-link p-0" role="button" data-container="body" data-toggle="popover" data-placement="right" data-content="<div class=&quot;no-overflow&quot;>
			<p>Der <b>Median</b> ist derjenige Wert, der in der geordneten Liste genau in der Mitte liegt bzw. das arithmetische Mittel aus den beiden in der Mitte liegenden Werten (falls die Anzahl der Werte gerade ist).</p>
			</div>" data-html="true" tabindex="0" data-trigger="focus" data-original-title="" title="">
	  <span class="popover_erklaerung">Median</span> <span style="font-size: 1em; color:red;"><i class="fa fa-times"></i></span>
	</a>
</div>]]></text>
        </falsefeedback>
      </node>
    </prt>
    <prt>
      <name>prt_vergleichen</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>0</feedbackstyle>
      <feedbackvariables>
        <text><![CDATA[/*Sortierte Liste mit den Datenwerten aus der ersten Antwort:*/
L2: sort(float(map(fullratsimp,ans1)));
anspunkte: makelist([L2[k],0],k,1,length(L2));

/*Kennwerte des Datensatzes aus der ersten Antwort:*/
mini_ans: lmin(L2);
maxi_ans: lmax(L2);
med_ans: median1(L2);
arit_ans: apply("+",L2)/length(L2);
ampl_ans: maxi_ans-mini_ans;
uquantil_ans: pquantil(L2,1/4);
oquantil_ans: pquantil(L2,3/4);
IQR_ans: oquantil_ans-uquantil_ans;

/*Ausreißer aus der ersten Antwort:*/
ausreisser_unten_ans: sublist(L2,lambda([x],x<uquantil_ans-3/2*IQR_ans));
ausreisser_oben_ans: sublist(L2,lambda([x],x>oquantil_ans+3/2*IQR_ans));
ausreisser_punkte_ans: block([L],
  L:[],
  if not(ausreisser_oben_ans=[]) then L:cons([last(L2),0],L),
  if not(ausreisser_unten_ans=[]) then L:cons([first(L2),0],L),
    return(L)
);

/* Bestimmt, ob es einen oberen/unteren Ausreißer gibt und legt dadurch fest,
was die obere/untere Antenne des Boxplots aus der Antwort ist: */
antenne_rechts_ans: if ausreisser_oben_ans=[] then last(L2) else lmax(sublist(L2, lambda([x],x<=oquantil_ans+3/2*IQR_ans)));
antenne_links_ans: if ausreisser_unten_ans=[] then first(L2) else lmin(sublist(L2, lambda([x],x>=uquantil_ans-3/2*IQR_ans)));

/*Listen mit allen Antworten und den korrekten Lösungen für die Tabellenaufgabe:*/
Teil2_SAns: [ans2,ans3,ans4,ans5,ans6,ans7,ans8,ans9,ans10,ans11];
Teil2_TAns: [antenne_links, antenne_links_ans, uquantil, uquantil_ans, med, med_ans, oquantil, oquantil_ans, antenne_rechts, antenne_rechts_ans];

/*In den Feedbacktext eingefügte FA-Symbole (Antenne links):*/
untere_grenze_TAns_symbol: if is(abs(float(ans2)-float(antenne_links))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";
untere_grenze_SAns_symbol: if is(abs(float(ans3)-float(antenne_links_ans))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";

/*In den Feedbacktext eingefügte FA-Symbole (Unteres Quartil):*/
unteres_quartil_TAns_symbol: if is(abs(float(ans4)-float(uquantil))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";
unteres_quartil_SAns_symbol: if is(abs(float(ans5)-float(uquantil_ans))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";

/*In den Feedbacktext eingefügte FA-Symbole (Median):*/
median_TAns_symbol: if is(abs(float(ans6)-float(med))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";
median_SAns_symbol: if is(abs(float(ans7)-float(med_ans))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";

/*In den Feedbacktext eingefügte FA-Symbole (Oberes Quartil):*/
oberes_quartil_TAns_symbol: if is(abs(float(ans8)-float(oquantil))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";
oberes_quartil_SAns_symbol: if is(abs(float(ans9)-float(oquantil_ans))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";

/*In den Feedbacktext eingefügte FA-Symbole (Antenne rechts):*/
obere_grenze_TAns_symbol: if is(abs(float(ans10)-float(antenne_rechts))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";
obere_grenze_SAns_symbol: if is(abs(float(ans11)-float(antenne_rechts_ans))<=0.05) then "<span style='font-size: 1em; color:green;'><i class='fa fa-check'></i></span> " else "<span style='font-size: 1em; color:red;'><i class='fa fa-times'></i></span>";]]></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>NumAbsolute</answertest>
        <sans>Teil2_SAns</sans>
        <tans>Teil2_TAns</tans>
        <testoptions>0.05</testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt_vergleichen-11-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p class="correct"><span style="font-size: 1.5em; color:green;"><i class="fa fa-check"></i></span> Richtige Antwort, gut gemacht!</p>

<br>

<!-- PRT -->
<div style="overflow-x:auto;">
	<table class="table table-primary" style="width:auto">
		<tr>
			<th>Kennziffer</th>
			<th>Boxplot aus Ihrem Datensatz</th>
			<th>Boxplot aus der Aufgabenstellung</th>
		</tr>
		<tr id="oer-aufgabe-23_zeile_untere_grenze_prt">
			<th>Linke Antenne</th>
			<td><input type="textfield" id="oer-aufgabe-23_untere_grenze_SAns_input"> {@untere_grenze_SAns_symbol@}</td>
			<td><input type="textfield" id="oer-aufgabe-23_untere_grenze_TAns_input"> {@untere_grenze_TAns_symbol@}</td>
		</tr>
		<tr id="oer-aufgabe-23_zeile_unteres_quartil_prt">
			<th>Unteres Quartil</th>
			<td><input type="textfield" id="oer-aufgabe-23_unteres_quartil_SAns_input"> {@unteres_quartil_SAns_symbol@}</td>
			<td><input type="textfield" id="oer-aufgabe-23_unteres_quartil_TAns_input"> {@unteres_quartil_TAns_symbol@}</td>
		</tr>
		<tr id="oer-aufgabe-23_zeile_median_prt">
			<th>Median</th>
			<td><input type="textfield" id="oer-aufgabe-23_median_SAns_input"> {@median_SAns_symbol@}</td>
			<td><input type="textfield" id="oer-aufgabe-23_median_TAns_input"> {@median_TAns_symbol@}</td>
		</tr>
		<tr id="oer-aufgabe-23_zeile_oberes_quartil_prt">
			<th>Oberes Quartil</th>
			<td><input type="textfield" id="oer-aufgabe-23_oberes_quartil_SAns_input"> {@oberes_quartil_SAns_symbol@}</td>
			<td><input type="textfield" id="oer-aufgabe-23_oberes_quartil_TAns_input"> {@oberes_quartil_TAns_symbol@}</td>
		</tr>
		<tr id="oer-aufgabe-23_zeile_obere_grenze_prt">
			<th>Rechte Antenne</th>
			<td><input type="textfield" id="oer-aufgabe-23_obere_grenze_SAns_input"> {@obere_grenze_SAns_symbol@}</td>
			<td><input type="textfield" id="oer-aufgabe-23_obere_grenze_TAns_input"> {@obere_grenze_TAns_symbol@}</td>
		</tr>
	</table>
</div>

<hr>
<p>Klicken Sie auf den folgenden Button, um die ursprüngliche Aufgabenstellung erneut zu bearbeiten: <button type="button"  class="buttonweiter" onclick="
   hide('oer-aufgabe-23_weiterfuehrende_aufgabe');
   show('oer-aufgabe-23_neuer_versuch');
 ">Weiter</button></p>

<script>
//Tabelle aus dem Fragetext ausblenden:
window.onload = function(){
   hide('oer-aufgabe-23_tabelle_vergleich');
};


// ==========================================================================
//Ausblenden aller Feedbacktexte, die sich auf Werte beziehen, die zuvor gar nicht eingegeben wurden:
// ==========================================================================

function knotenAusblenden(id) {
  if(document.getElementById(id)!==null){
      document.getElementById(id).style.display="none";
  };
};


if({#antenne_links_ans#}=={#antenne_links#}){
   knotenAusblenden('oer-aufgabe-23_prt2_1w');
   knotenAusblenden('oer-aufgabe-23_prt2_1f');
   knotenAusblenden('oer-aufgabe-23_prt2_2w');
   knotenAusblenden('oer-aufgabe-23_prt2_2f');
};

if({#uquantil_ans#}=={#uquantil#}){
   knotenAusblenden('oer-aufgabe-23_prt2_3w');
   knotenAusblenden('oer-aufgabe-23_prt2_3f');
   knotenAusblenden('oer-aufgabe-23_prt2_4w');
   knotenAusblenden('oer-aufgabe-23_prt2_4f');
};

if({#med_ans#}=={#med#}){
   knotenAusblenden('oer-aufgabe-23_prt2_5w');
   knotenAusblenden('oer-aufgabe-23_prt2_5f');
   knotenAusblenden('oer-aufgabe-23_prt2_6w');
   knotenAusblenden('oer-aufgabe-23_prt2_6f');
};

if({#oquantil_ans#}=={#oquantil#}){
   knotenAusblenden('oer-aufgabe-23_prt2_7w');
   knotenAusblenden('oer-aufgabe-23_prt2_7f');
   knotenAusblenden('oer-aufgabe-23_prt2_8w');
   knotenAusblenden('oer-aufgabe-23_prt2_8f');
};

if({#antenne_rechts_ans#}=={#antenne_rechts#}){
   knotenAusblenden('oer-aufgabe-23_prt2_9w');
   knotenAusblenden('oer-aufgabe-23_prt2_9f');
   knotenAusblenden('oer-aufgabe-23_prt2_10w');
   knotenAusblenden('oer-aufgabe-23_prt2_10f');
};


// ====================================================
// === Die Tabellenzeilen ausblenden, wo die Werte übereinstimmen ===
// ====================================================

//Linke Antenne:
if({#antenne_links_ans#}=={#antenne_links#}){
   document.getElementById('oer-aufgabe-23_zeile_untere_grenze_prt').style.display="none";
};
   document.getElementById('oer-aufgabe-23_untere_grenze_TAns_input').value="{#ans2#}";
   document.getElementById('oer-aufgabe-23_untere_grenze_TAns_input').disabled=true;
   document.getElementById('oer-aufgabe-23_untere_grenze_SAns_input').value="{#ans3#}";
   document.getElementById('oer-aufgabe-23_untere_grenze_SAns_input').disabled=true;

//Unteres Quartil:
if({#uquantil_ans#}=={#uquantil#}){
   document.getElementById('oer-aufgabe-23_zeile_unteres_quartil_prt').style.display="none";
};
   document.getElementById('oer-aufgabe-23_unteres_quartil_TAns_input').value="{#ans4#}";
   document.getElementById('oer-aufgabe-23_unteres_quartil_TAns_input').disabled=true;
   document.getElementById('oer-aufgabe-23_unteres_quartil_SAns_input').value="{#ans5#}";
   document.getElementById('oer-aufgabe-23_unteres_quartil_SAns_input').disabled=true;

//Median:
if({#med_ans#}=={#med#}){
   document.getElementById('oer-aufgabe-23_zeile_median_prt').style.display="none";
};
   document.getElementById('oer-aufgabe-23_median_TAns_input').value="{#ans6#}";
   document.getElementById('oer-aufgabe-23_median_TAns_input').disabled=true;
   document.getElementById('oer-aufgabe-23_median_SAns_input').value="{#ans7#}";
   document.getElementById('oer-aufgabe-23_median_SAns_input').disabled=true;

//Oberes Quartil:
if({#oquantil_ans#}=={#oquantil#}){
   document.getElementById('oer-aufgabe-23_zeile_oberes_quartil_prt').style.display="none";
};
   document.getElementById('oer-aufgabe-23_oberes_quartil_TAns_input').value="{#ans8#}";
   document.getElementById('oer-aufgabe-23_oberes_quartil_TAns_input').disabled=true;
   document.getElementById('oer-aufgabe-23_oberes_quartil_SAns_input').value="{#ans9#}";
   document.getElementById('oer-aufgabe-23_oberes_quartil_SAns_input').disabled=true;

//Rechte Antenne:
if({#antenne_rechts_ans#}=={#antenne_rechts#}){
   document.getElementById('oer-aufgabe-23_zeile_obere_grenze_prt').style.display="none";
};
   document.getElementById('oer-aufgabe-23_obere_grenze_TAns_input').value="{#ans10#}";
   document.getElementById('oer-aufgabe-23_obere_grenze_TAns_input').disabled=true;
   document.getElementById('oer-aufgabe-23_obere_grenze_SAns_input').value="{#ans11#}";
   document.getElementById('oer-aufgabe-23_obere_grenze_SAns_input').disabled=true;

</script>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt_vergleichen-11-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p class="correct"><span style="font-size: 1.5em; color:red;"><i class="fa fa-times"></i></span> Falsche Antwort.</p>

<p>Bitte versuchen Sie es erneut und klicken Sie dann auf "Prüfen".</p>

<script>
if( {#ans2#}=={#antenne_links#} ){
	document.getElementById('oer-aufgabe-23_antenne_links_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_antenne_links_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>";
} else{
	document.getElementById('oer-aufgabe-23_antenne_links_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_antenne_links_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
}; 

if( {#ans3#}=={#antenne_links_ans#} ){
	document.getElementById('oer-aufgabe-23_antenne_links_antwort').innerHTML=document.getElementById('oer-aufgabe-23_antenne_links_antwort').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>";
} else{
	document.getElementById('oer-aufgabe-23_antenne_links_antwort').innerHTML=document.getElementById('oer-aufgabe-23_antenne_links_antwort').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
};

if( {#ans4#}=={#uquantil#} ){
	document.getElementById('oer-aufgabe-23_uquartil_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_uquartil_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>";
} else{
	document.getElementById('oer-aufgabe-23_uquartil_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_uquartil_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
}; 

if( {#ans5#}=={#uquantil_ans#} ){
	document.getElementById('oer-aufgabe-23_uquartil_antwort').innerHTML=document.getElementById('oer-aufgabe-23_uquartil_antwort').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>";
} else{
	document.getElementById('oer-aufgabe-23_uquartil_antwort').innerHTML=document.getElementById('oer-aufgabe-23_uquartil_antwort').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
};

if( {#ans6#}=={#med#} ){
	document.getElementById('oer-aufgabe-23_median_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_median_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>";
} else{
	document.getElementById('oer-aufgabe-23_median_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_median_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
}; 

if( {#ans7#}=={#med_ans#} ){
	document.getElementById('oer-aufgabe-23_median_antwort').innerHTML=document.getElementById('oer-aufgabe-23_median_antwort').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>";
} else{
	document.getElementById('oer-aufgabe-23_median_antwort').innerHTML=document.getElementById('oer-aufgabe-23_median_antwort').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
};

if( {#ans8#}=={#oquantil#} ){
	document.getElementById('oer-aufgabe-23_oquartil_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_oquartil_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>";
} else{
	document.getElementById('oer-aufgabe-23_oquartil_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_oquartil_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
}; 

if( {#ans9#}=={#oquantil_ans#} ){
	document.getElementById('oer-aufgabe-23_oquartil_antwort').innerHTML=document.getElementById('oer-aufgabe-23_oquartil_antwort').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>";
} else{
	document.getElementById('oer-aufgabe-23_oquartil_antwort').innerHTML=document.getElementById('oer-aufgabe-23_oquartil_antwort').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
};

if( {#ans10#}=={#antenne_rechts#} ){ //wenn die Werte übereinstimmen
	document.getElementById('oer-aufgabe-23_antenne_rechts_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_antenne_rechts_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>"; //Füge Checkmark ein
} else{ //wenn die Werte nicht übereinstimmen
	document.getElementById('oer-aufgabe-23_antenne_rechts_aufgabe').innerHTML=document.getElementById('oer-aufgabe-23_antenne_rechts_aufgabe').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
}; //Füge Cross ein

if( {#ans11#}=={#antenne_rechts_ans#} ){
	document.getElementById('oer-aufgabe-23_antenne_rechts_antwort').innerHTML=document.getElementById('oer-aufgabe-23_antenne_rechts_antwort').innerHTML+"<span style='font-size: 1.5em; color:green;''><i class='fa fa-check'></i></span>";
} else{
	document.getElementById('oer-aufgabe-23_antenne_rechts_antwort').innerHTML=document.getElementById('oer-aufgabe-23_antenne_rechts_antwort').innerHTML+"<span style='font-size: 1.5em; color:red;'><i class='fa fa-times'></i></span>";
}; 
</script>]]></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8382952  -->
  <question type="stack">
    <name>
      <text>Funktionenplotter</text>
    </name>
    <questiontext format="moodle_auto_format">
      <text><![CDATA[<p>Diese Aufgabe ist ein Beispiel für einen Funktionenplotter. Wird ein Ausdruck in das Eingabefeld eingegeben, wird er als Funktion nach \(x\) interpretiert und der Funktionsgraph dieser Funktion wird gezeichnet. Dieser Ansatz eignet sich für Aufgaben, in denen die Studierenden eine Funktion angeben müssen und dabei die Möglichkeit haben sollen, ihre Antwort vor der Abgabe der Aufgabe grafisch zu validieren.</p>

<div class="row">
    <div class="col">
        <p>Der Code:</p>
        [[iframe width="100%" height="100%"]]
            [[style href="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/styles/vs2015.css" /]]
            [[script src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/highlight.min.js" /]]
            [[script]]
                document.addEventListener("DOMContentLoaded", e=>{
                    hljs.highlightAll()
                });
            [[/script]]

            <pre class="theme-vs2015"><code class="javascript">
const board = JXG.JSXGraph.initBoard(divid, {
   boundingbox:[-10,10,10,-10],
   axis:true,
   showCopyright:false
});

/* Wenn die Seite komplett geladen ist soll ein bestimmter Code ausgeführt werden: */
document.addEventListener("DOMContentLoaded", e=>{
   /* Im Folgenden werden Funktionen aus der STACK-eigenen Bibliothek STACK-JS genutzt.
       Die Funktion bittet STACK um Zugriff auf das Eingabefeld ans1. */
   var promiseforaninput = stack_js.request_access_to_input("ans1", true);
   /* Wenn der Zugriff gewährt wird, soll ein bestimmter Code ausgeführt werden: */
   promiseforaninput.then((id) => {
      /* "input" ist das Eingabefeld. */
      let input = document.getElementById(id);
      /* Die Variablen "liste" und "f" sind eine leere Liste bzw. noch ohne Wert. */
      let liste = [];
      var f;
      /* Wenn der Wert des Eingabefeldes ans1 geändert wird, führe einen
         bestimmten Code aus: */
      input.addEventListener("change", e=>{
         /* Die Variable "value" ist der Wert des Eingabefeldes nach der Änderung. */
         let value = input.value;
         /* Es wird versucht, den Wert des Eingabefeldes in eine JS-Funktion
             zu übersetzen, die bisherige Funktion im Board zu entfernen und die neue
             Funktion zu plotten. */
         try {
            f = board.jc.snippet(value, true, 'x', true);
            liste.forEach(obj=>{
               board.removeObject(obj);
            });
            liste = [];
            liste.push(board.create('functiongraph', [f]));
         } catch{
            /* Wenn der Wert des Eingabefeldes nicht in eine JS-Funktion übersetzt
                 werden kann, dann führt JS diesen Code hier aus. Hier steht aber
                 nichts, da JS in diesem Fall nichts tun soll. */
         };
      });
   });
});
            </code></pre>

        [[/iframe]]
    </div>
    <div class="col">
        <p>Die Grafik:</p>

        [[jsxgraph width="70%" aspect-ratio="1/1"]]
        const board = JXG.JSXGraph.initBoard(divid, {
           boundingbox:[-10,10,10,-10],
           axis:true,
           showCopyright:false
        });

        /* Wenn die Seite komplett geladen ist soll ein bestimmter Code ausgeführt werden: */
        document.addEventListener("DOMContentLoaded", e=>{
        /* Im Folgenden werden Funktionen aus der STACK-eigenen Bibliothek STACK-JS genutzt.
            Die Funktion bittet STACK um Zugriff auf das Eingabefeld ans1. */
        var promiseforaninput = stack_js.request_access_to_input("ans1", true);
        /* Wenn der Zugriff gewährt wird, soll ein bestimmter Code ausgeführt werden: */
        promiseforaninput.then((id) => {
            /* "input" ist das Eingabefeld. */
            let input = document.getElementById(id);
            /* Die Variablen "liste" und "f" sind eine leere Liste bzw. noch ohne Wert. */
            let liste = [];
            var f;
            /* Wenn der Wert des Eingabefeldes ans1 geändert wird, führe einen bestimmten Code aus: */
            input.addEventListener("change", e=>{
                /* Die Variable "value" ist der Wert des Eingabefeldes nach der Änderung. */
                let value = input.value;
                /* Es wird versucht, den Wert des Eingabefeldes in eine JS-Funktion zu übersetzen,
                    die bisherige Funktion im Board zu entfernen und die neue Funktion zu plotten. */
                try {
                    f = board.jc.snippet(value, true, 'x', true);
                    liste.forEach(obj=>{
                    board.removeObject(obj);
                    });
                    liste = [];
                    liste.push(board.create('functiongraph', [f]));
                } catch{
                    /* Wenn der Wert des Eingabefeldes nicht in eine JS-Funktion übersetzt werden kann, dann
                        führt JS diesen Code hier aus. Hier steht aber nichts, da JS in diesem Fall nichts tun soll. */
                };
            });
        });
        });
        [[/jsxgraph]]
    </div>
</div>

<br><br>

<p>\(f(x)=\) [[input:ans1]] [[validation:ans1]]</p>]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Funktionenplotter“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/</text>
    </questionvariables>
    <specificfeedback format="html">
      <text>[[feedback:prt1]]</text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>1</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>1</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>1</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>1</sans>
        <tans>1</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8382954  -->
  <question type="stack">
    <name>
      <text>Logarithmische Skala</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<p>Die folgende Grafik ist ein Beispiel für eine logarithmische Achse. Standardmäßig sind diese in JSXGraph nicht verfügbar, aber es ist ein Workaround möglich.</p>

<div class="row">
    <div class="col">
        <p>Der Code:</p>
        [[iframe width="100%" height="100%"]]
            [[style href="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/styles/vs2015.css" /]]
            [[script src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/highlight.min.js" /]]
            [[script]]
                document.addEventListener("DOMContentLoaded", e=>{
                    hljs.highlightAll()
                });
            [[/script]]

            <pre class="theme-vs2015"><code class="javascript">
/*
This JSXGraph code is based on an example by The Center of Mobile Learning with
Digital Technology which is licensed under a Creative Commons Attribution ShareAlike
4.0 International License. https://creativecommons.org/licenses/by-sa/4.0/
*/

const board = JXG.JSXGraph.initBoard(divid, {
    boundingbox: [-5, 6, 5, -4],
    axis: false,    // Turn off default axes
    showCopyright:false
});

/* === Horizontale Achse mit linearer Skalierung und gleichem Aussehen wie die
    Standardachse === */
/* Dictionary mit allen Attributen der Standard-Achsen: */
var attr = JXG.Options.board.defaultAxes.x; 
/* Verhindern, dass bei der horitonalen Achse die 0 angezeigt/beschriftet wird */
attr.ticks.drawZero = false;
/* Erstelle neue horizontale Achse mit diesen Attributen: */
var xAxis = board.create('axis', [[0, 0], [1, 0]], attr);

/* === Vertikale Achse mit logarithmischer Skalierung und gleichem Aussehen wie
   die Standardachse === */
/* Auch hier wird wieder eine Standard-Liste mit Attributen genommen und leicht
   abgeändert: */
attr = JXG.Options.axis;
attr.fixed = true;
/* Erstelle neue vertikale Achse mit diesen Attributen: */
var yAxis = board.create('line', [[0, 0], [0, 1]], attr);

/* === Ticks für die logariothmische vertikale Achse erstellen: === */
/* Auch hier wird wieder eine Standard-Liste mit Attributen genommen und leicht
   abgeändert: */
attr = JXG.Options.board.defaultAxes.y.ticks,
attr.insertTicks = true;
attr.drawLabels = true;
attr.drawZero = false;
attr.generateLabelText = function(tick, zero) {
    var value = Math.pow(10, Math.round(tick.usrCoords[2] - zero.usrCoords[2]));
    return this.formatLabelText(value);
};
/* Erstellen der Ticks: */
var ticksY = board.create('ticks', [yAxis, 1], attr);

/* === Zwei Funktionen auf der logarithmischen Skala plotten: === */
/* Folgende Funktion muss auf die zu plottenden Funktionen f1 und f2 angewendet
  werden */
var post = (x) => JXG.Math.log10(x);
/* Die zu plottenden Funktionen: */
var f1 = (x) => x * x;
var f2 = (x) => Math.exp(x);
/* Graphen der Funktionen: */
board.create('functiongraph', [(x) => post(f1(x))], {
    name: 'x^2',
    withLabel: true
});
board.create('functiongraph', [(x) => post(f2(x))], {
    name: 'e^x',
    withLabel: true,
    strokeColor: 'red'
});
            </code></pre>

        [[/iframe]]
    </div>
    <div class="col">
        <p>Die Grafik:</p>

        [[jsxgraph width="70%" aspect-ratio="1/1"]]
        /*
        This JSXGraph code is based on an example by The Center of Mobile Learning with Digital Technology
        which is licensed under a Creative Commons Attribution ShareAlike 4.0 International License.
        https://creativecommons.org/licenses/by-sa/4.0/
        */

        const board = JXG.JSXGraph.initBoard(divid, {
            boundingbox: [-5, 6, 5, -4],
            axis: false,    // Turn off default axes
            showCopyright: false
        });

        /* === Horizontale Achse mit linearer Skalierung und gleichem Aussehen wie die Standardachse === */
        /* Dictionary mit allen Attributen der Standard-Achsen: */
        var attr = JXG.Options.board.defaultAxes.x; 
        /* Verhindern, dass bei der horitonalen Achse die 0 angezeigt/beschriftet wird */
        attr.ticks.drawZero = false;
        /* Erstelle neue horizontale Achse mit diesen Attributen: */
        var xAxis = board.create('axis', [[0, 0], [1, 0]], attr);

        /* === Vertikale Achse mit logarithmischer Skalierung und gleichem Aussehen wie die Standardachse === */
        /* Auch hier wird wieder eine Standard-Liste mit Attributen genommen und leicht abgeändert: */
        attr = JXG.Options.axis;
        attr.fixed = true;
        /* Erstelle neue vertikale Achse mit diesen Attributen: */
        var yAxis = board.create('line', [[0, 0], [0, 1]], attr);

        /* === Ticks für die logariothmische vertikale Achse erstellen: === */
        /* Auch hier wird wieder eine Standard-Liste mit Attributen genommen und leicht abgeändert: */
        attr = JXG.Options.board.defaultAxes.y.ticks,
        attr.insertTicks = true;
        attr.drawLabels = true;
        attr.drawZero = false;
        attr.generateLabelText = function(tick, zero) {
            var value = Math.pow(10, Math.round(tick.usrCoords[2] - zero.usrCoords[2]));
            return this.formatLabelText(value);
        };
        /* Erstellen der Ticks: */
        var ticksY = board.create('ticks', [yAxis, 1], attr);

        /* === Zwei Funktionen auf der logarithmischen Skala plotten: === */
        /* Folgende Funktion muss auf die zu plottenden Funktionen f1 und f2 angewendet werden */
        var post = (x) => JXG.Math.log10(x);
        /* Die zu plottenden Funktionen: */
        var f1 = (x) => x * x;
        var f2 = (x) => Math.exp(x);
        /* Graphen der Funktionen: */
        board.create('functiongraph', [(x) => post(f1(x))], {
            name: 'x^2',
            withLabel: true
        });
        board.create('functiongraph', [(x) => post(f2(x))], {
            name: 'e^x',
            withLabel: true,
            strokeColor: 'red'
        });
        [[/jsxgraph]]
    </div>
</div>

<br><br>

<p>Geben Sie nun selbst eine Funktion ein. Im Feedback wird sie auf eine logarithmische Skala geplottet:</p>
<p>\(f(x)=\) [[input:ans1]] [[validation:ans1]]</p>


[[feedback:prt1]]]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text><![CDATA[/*
Autor der Aufgabe: Jonas Lache, Hochschule Ruhr West <jonas.lache[at]hs-ruhrwest.de>
Lizenz: CC BY-SA 4.0 <https://creativecommons.org/licenses/by-sa/4.0/deed.de>
Der JSXGraph-Code basiert auf einem Beispiel <https://jsxgraph.org/share/example/axis-logarithmic-scale"> des Center of Mobile Learning with Digital Technology <https://mobiles-lernen.uni-bayreuth.de/>, das unter CC BY-SA 4.0 lizenziert ist.
*/]]></text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="moodle_auto_format">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>1</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>1</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>1</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>1</sans>
        <tans>1</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[[[jsxgraph]]
/*
This JSXGraph application is based on an example by The Center of Mobile Learning with Digital Technology
and is licensed under a Creative Commons Attribution ShareAlike 4.0 International License.
https://creativecommons.org/licenses/by-sa/4.0/
*/

const board = JXG.JSXGraph.initBoard(divid, {
    boundingbox: [-5, 6, 5, -4],
    axis: false    // Turn off default axes
});
// Horizontal axis with linear scale and same look
// as default axes
var attr = JXG.Options.board.defaultAxes.x;
attr.ticks.drawZero = false;
var xAxis = board.create('axis', [[0, 0], [1, 0]], attr);

// Vertical axis with logarithmic scale and same look
// as default axes.
attr = JXG.Options.axis;
attr.fixed = true;
var yAxis = board.create('line', [[0, 0], [0, 1]], attr);

attr = JXG.Options.board.defaultAxes.y.ticks,
attr.insertTicks = true;
attr.drawLabels = true;
attr.drawZero = false;
attr.generateLabelText = function(tick, zero) {
    var value = Math.pow(10, Math.round(tick.usrCoords[2] - zero.usrCoords[2]));
    return this.formatLabelText(value);
};

var ticksY = board.create('ticks', [yAxis, 1], attr);



// Plot two functions in logarithmic scale
var post = (x) => JXG.Math.log10(x);
/*
var f1 = (x) => x * x;
var f2 = (x) => Math.exp(x);

board.create('functiongraph', [(x) => post(f1(x))], {
    name: 'x^2',
    withLabel: true
});

board.create('functiongraph', [(x) => post(f2(x))], {
    name: 'e^x',
    withLabel: true,
    strokeColor: 'red'
});
*/

var f = board.jc.snippet('{#ans1#}', true, 'x', true);
var f2 = function(x){
        return post(f(x));
      };
var curve = board.create('functiongraph', [f2,-10,10], {strokeWidth:2});

[[/jsxgraph]]]]></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8382941  -->
  <question type="stack">
    <name>
      <text>Orthogonale Vektoren</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<p>Platzieren Sie die beiden Vektoren so, dass ihr Skalarprodukt \(0\) beträgt.</p>

[[jsxgraph input-ref-ans1="storeRef"]]

const board = JXG.JSXGraph.initBoard(divid,{
   boundingbox:[-5,5,5,-5],
   axis:true,
   showCopyright:false
});

var p = board.create('point',[0,0],{
   visible:false,
   fixed:true
});

var p1 = board.create('point',[3,2],{
   withLabel:false,
   snapToGrid:true,
   snapSizeX:0.1,
   snapSizeY:0.1
});

var p2 = board.create('point',[1,3],{
   withLabel:false,
   snapToGrid:true,
   snapSizeX:0.1,
   snapSizeY:0.1
});

var v1 = board.create('arrow',[p,p1]);
var v2 = board.create('arrow',[p,p2]);

stack_jxg.bind_point_dual(storeRef,p1,p2);

[[/jsxgraph]]

<p style="display:none">[[input:ans1]] [[validation:ans1]]</p>]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Orthogonale Vektoren“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/

ta: [[1,0],[0,1]];</text>
    </questionvariables>
    <specificfeedback format="html">
      <text>[[feedback:prt1]]</text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>ta</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>0</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text>sp: ans1[1].ans1[2];
nullvektorp: member([0,0],set(ans1[1],ans1[2]));</text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description>Ist mindestens einer der Vektoren der Nuzllvektor?</description>
        <answertest>AlgEquiv</answertest>
        <sans>nullvektorp</sans>
        <tans>false</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Sie haben eine triviale Lösung angegeben, denn mindestens einer Ihrer angegebenen Vektoren ist der Nullvektor. Bitte geben Sie eine Lösung an, bei der beider Vektoren vom Nullvektor verschieden sind.</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>1</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>sp</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-2-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-2-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Das Skalarprodukt der Vektoren beträgt nicht \(0\), sondern {@sp@}.</p>]]></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8382924  -->
  <question type="stack">
    <name>
      <text>Punkte und Integral</text>
    </name>
    <questiontext format="moodle_auto_format">
      <text><![CDATA[<p>In der folgenden Grafik sehen Sie drei Punkte \(P_1(x_1|y_1),P_2(x_2|y_2)\) und \(P_3(x_3|y_3)\) und den Graph einer Funktion \(f\colon \mathbb{R}\to\mathbb{R}\).</p>
<p>Verschieben Sie die drei roten Punkte so, dass \(\int_{x_1}^{x_2}f(x)\,dx + \int_{x_2}^{x_3}f(x)\,dx < 0\) gilt.</p>

[[jsxgraph input-ref-ans1="ans1ref"]]
JXG.Options.text.useMathJax = true;
const board = JXG.JSXGraph.initBoard(divid, {
  axis: true,
  boundingbox: [-5,5,5,-5],
  showCopyright: false,
  showNavigation: false,
  pan: { enabled: false },
  zoom: { enabled: false },
});

const opts = {
  withLabel:true,
  snapToGrid:true,
  snapSizeX:0.1
};

function make_names(){
  let tmp = points.sort((p1,p2)=>p1.X()-p2.X());
  tmp[0].setAttribute({name:"P1"});
  tmp[1].setAttribute({name:"P2"});
  tmp[2].setAttribute({name:"P3"});
};

var points = [
  board.create('glider',[-3,0,board.defaultAxes.x],opts),
  board.create('glider',[1,0,board.defaultAxes.x],opts),
  board.create('glider',[2.5,0,board.defaultAxes.x],opts)
];
make_names();

for(let p of points){
  p.on("drag",(e,i)=>make_names())
};

function f(x){
  return 1/3*(x-points[0].X())*(x-points[1].X())*(x-points[2].X())
};
const graph = board.create('functiongraph',[f]);

var int1 = board.create('integral',[[
  function(){return points[0].X()},
  function(){return points[1].X()}
],graph],{
  withLabel:false,
  highlight:false,
  fillColor:"plum"
});

var int2 = board.create('integral',[[
  function(){return points[1].X()},
  function(){return points[2].X()}
],graph],{
  withLabel:false,
  highlight:false,
  fillColor:"lightgreen"
});

stack_jxg.bind_list_of(ans1ref, points);
[[/jsxgraph]]

<p style="display:none">[[input:ans1]] [[validation:ans1]]</p>

[[feedback:prt1]]]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Punkte und Integral“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/

/* Ein Beispiel für eine korrekte Antwort: */
ta: [[-1,0],[0,0],[2,0]];</text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>ta</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>0</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text>/* Alle Zahlen auf eine Nachkommastelle runden: */
SAns1: map(lambda([x],decimalplaces(x,1)),ans1);

/* Liste mit den x-Werten der drei Punkte: */
SAns1_x: map(lambda([x],x[1]),SAns1);

/* Gleichung der Funktion, die sich durch die verschobenen Punkte ergibt: */
f1: 1/3*(x-SAns1_x[1])*(x-SAns1_x[2])*(x-SAns1_x[3]);

/* Integral von x1 bis x2: */
int1: int(f1,x,SAns1_x[1],SAns1_x[2]);


/* Integral von x2 bis x3: */
int2: int(f1,x,SAns1_x[2],SAns1_x[3]);</text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>GT</answertest>
        <sans>0</sans>
        <tans>int1+int2</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Sie haben die Punkte so verschoben, dass \(\int_{x_1}^{x_2}f(x)\,dx \approx {@decimalplaces(int1,2)@}\) sowie \(\int_{x_2}^{x_3}f(x)\,dx \approx {@decimalplaces(int2,2)@}\) gilt. Insgesamt gilt dann \(\int_{x_1}^{x_2}f(x)\,dx + \int_{x_2}^{x_3}f(x)\,dx = {@decimalplaces(int1+int2,2)@} < 0\)</p>]]></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Sie haben die Punkte so verschoben, dass \(\int_{x_1}^{x_2}f(x)\,dx \approx {@decimalplaces(int1,2)@}\) sowie \(\int_{x_2}^{x_3}f(x)\,dx \approx {@decimalplaces(int2,2)@}\) gilt. Insgesamt gilt dann \(\int_{x_1}^{x_2}f(x)\,dx + \int_{x_2}^{x_3}f(x)\,dx = {@decimalplaces(int1+int2,2)@} \ge 0\)</p>]]></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8381491  -->
  <question type="stack">
    <name>
      <text>Stetig, aber nicht diffbar</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<p>Geben Sie eine Funktion an, die in \(x_0={@x0@}\) stetig, aber nicht differenzierbar ist.</p>

<p>Antwort: \(f(x)=\) [[input:ans1]] [[validation:ans1]]</p>


[[feedback:prt1]]]]></text>
    </questiontext>
    <generalfeedback format="html">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text><![CDATA[/*
Die Aufgabe „Stetig, aber nicht diffbar“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/

x0: rand_with_step(2,6,1);

validate_variables(ex):=block([],
   if length(delete(x,listofvars(ex)))=0 then ""
   else return(castext("Bitte verwenden Sie keine anderen Variablen als <i>x</i>."))
);

ta: abs(x-x0);]]></text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text>{@x0@}</text>
    </questionnote>
    <questiondescription format="moodle_auto_format">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>ta</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords>sum, product, diff, int, !</forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>1</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>1</showvalidation>
      <options>validator:validate_variables</options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text>y0: subst(x0,x,ans1);</text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>continuousp(ans1,x,x0)</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>=</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Sehr gut! Ihre Funktion \(f(x)={@ans1@}\) ist stetig in \(x_0={@x0@}\).</p>]]></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Ihre Funktion \(f(x)={@ans1@}\) ist nicht stetig in \(x_0={@x0@}\). Das sollte sie aber sein.></p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>1</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>diffp(ans1,x,x0)</sans>
        <tans>false</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>2</truenextnode>
        <trueanswernote>prt1-2-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Sehr gut! Ihre Funktion \(f(x)={@ans1@}\) ist nicht differenzierbar in \(x_0={@x0@}\).</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>2</falsenextnode>
        <falseanswernote>prt1-2-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Ihre Funktion \(f(x)={@ans1@}\) ist differenzierbar in \(x_0={@x0@}\). Das sollte sie aber nicht sein.</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>2</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>[continuousp(ans1,x,x0),diffp(ans1,x,x0)]</sans>
        <tans>[true,false]</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-3-T</trueanswernote>
        <truefeedback format="html">
          <text>[[jsxgraph]]
JXG.Options.text.useMathJax = true;
const board = JXG.JSXGraph.initBoard(divid, { 
    boundingbox: [-5, 5, 5, -5], axis:true
});

var f = board.jc.snippet('{#float(ans1)#}', true, 'x', true);
var graph = board.create('functiongraph',f);
[[/jsxgraph]]</text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-3-F</falseanswernote>
        <falsefeedback format="html">
          <text>[[jsxgraph]]
JXG.Options.text.useMathJax = true;
const board = JXG.JSXGraph.initBoard(divid, { 
    boundingbox: [-5, 5, 5, -5], axis:true
});

var f = board.jc.snippet('{#float(ans1)#}', true, 'x', true);
var graph = board.create('functiongraph',f);
[[/jsxgraph]]</text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8381514  -->
  <question type="stack">
    <name>
      <text>Streng monoton wachsende/fallende Folge</text>
    </name>
    <questiontext format="moodle_auto_format">
      <text><![CDATA[<p>Verschieben Sie die Punkte so, dass sie die Folgenglieder einer streng monoton {@modus@}en Folge ergeben.</p>

[[jsxgraph input-ref-ans1="storeRef"]]

const board = JXG.JSXGraph.initBoard(divid,{
   boundingbox:[-1,5,5,-5],
   axis:true,
   showCopyright:false
});

var points = [];
for(let i=0;i<5;i++){
   let glider = board.create('segment',[[i,-5],[i,5]],{
      fixed:true,
      visible:false
   });
   points.push(
      board.create('glider',[2,0,glider],{
          size:4,
          withLabel:false,
          snapToGrid:true,
          snapSizeX:0.1,
          snapSizeY:0.1
      })
   );
};

stack_jxg.bind_list_of(storeRef,points);

[[/jsxgraph]]

<div style="display:none">[[input:ans1]] [[validation:ans1]]</div>

[[feedback:prt1]]]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text><![CDATA[/*
Die Aufgabe „Streng monoton wachsende/fallende Folge“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/

/* Funktionen zum Prüfen, ob die Werte einer Liste (streng) monoton steigend/fallend sind. */
steigendp(l):=is(float(l)=sort(float(l),"<"));
fallendp(l):=is(float(l)=sort(float(l),">"));
streng_steigendp(l):=is(float(l)=sort(unique(float(l)),"<"));
streng_fallendp(l):=is(float(l)=sort(unique(float(l)),">"));

modus: rand(["wachsend","fallend"]);
modus_gegenteil: if is(modus="wachsend") then "fallend" else "wachsend";

/* Beispiellösung: */
muster: if is(modus="wachsend") then makelist([k,decimalplaces(k/2,2)],k,0,4) else makelist([k,4-decimalplaces(k/2,2)],k,0,4);]]></text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text>{@modus@}</text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>muster</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>0</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text><![CDATA[y_werte: makelist(ans1[k][2],k,1,length(ans1));

ist_korrekt: if is(modus="wachsend") then streng_steigendp(y_werte) else streng_fallendp(y_werte);
nicht_streng: if is(modus="wachsend") then steigendp(y_werte) else fallendp(y_werte);
falsche_richtung: if is(modus="fallend") then streng_steigendp(y_werte) else streng_fallendp(y_werte);]]></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description>Strenge Monotonie</description>
        <answertest>AlgEquiv</answertest>
        <sans>ist_korrekt</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Sie haben die Grafik so verändert, dass in der Tat eine streng monoton {@modus@}e Folge herauskommt.</p>]]></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>1</name>
        <description>Einfache Monotonie</description>
        <answertest>AlgEquiv</answertest>
        <sans>nicht_streng</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-2-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Die Folge, die sich durch Ihre Punkte ergibt, ist zwar monoton {@modus@}, aber nicht <b>streng</b> monoton {@modus@}.</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>2</falsenextnode>
        <falseanswernote>prt1-2-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>2</name>
        <description>Strenge Monotonie in falsche Richtung</description>
        <answertest>AlgEquiv</answertest>
        <sans>falsche_richtung</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-3-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Die Folge, die sich durch Ihre Punkte ergibt, ist streng monoton {@modus_gegenteil@}, sie sollte aber streng monoton <b>{@modus@}</b> sein.</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-3-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Die Folge, die sich durch Ihre Punkte ergibt, ist <b>nicht</b> streng monoton {@modus@}.</p>]]></text>
        </falsefeedback>
      </node>
    </prt>
    <deployedseed>1878687347</deployedseed>
    <deployedseed>578649440</deployedseed>
  </question>

<!-- question: 8381515  -->
  <question type="stack">
    <name>
      <text>Stromkreis</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<p>Bitte verändern Sie die Zeichnung des Stromkreises so, dass der Stromkreis geschlossen ist und die Glühlampe leuchtet.</p>

[[jsxgraph width="400px" aspect-ratio="8/7" input-ref-ans1="ans1Ref"]]
      JXG.Options.text.useMathJax = true;
      const board = JXG.JSXGraph.initBoard(divid, {
        axis: false,
        boundingbox: [-4, 4, 4, -3],
        showCopyright: false,
        showNavigation: false,
        pan: { enabled: false },
        zoom: { enabled: false },
      });

      // Liste mit Attributen für alle Linien in der Grafik: 
      var curve_attr = {
        highlight: false,
        strokeColor: "black",
        strokeWidth: 2,
        fixed: true
      };

      // Linien außen:
      var y_pos_luecke = 2;
      var laenge_luecke = 0.15;
      var curve1 = board.create("curve", [
        [3, 3, 1.5],
        [1, 3, 3]
      ], curve_attr);
      var curve2 = board.create("curve", [
        [.5, -3, -3],
        [3, 3, y_pos_luecke]
      ], curve_attr);
      var curve3 = board.create("curve", [
        [-3, -3, -0.5],
        [y_pos_luecke - laenge_luecke, -2, -2]
      ], curve_attr);
      var curve4 = board.create("curve", [
        [0, 3, 3],
        [-2, -2, 0]
      ], curve_attr);

      // Stromquelle:
      var breite_oben = 0.6;
      var breite_unten = 0.3;
      var sq1 = board.create("segment", [
        [-3 - breite_oben / 2, y_pos_luecke],
        [-3 + breite_oben / 2, y_pos_luecke]
      ], curve_attr);
      var sq2 = board.create("segment", [
        [-3 - breite_unten / 2, y_pos_luecke - laenge_luecke],
        [-3 + breite_unten / 2, y_pos_luecke - laenge_luecke]
      ], curve_attr);

      // Schalter rechts:
      var schalter_hp_unten_r = board.create("point", [3, 0], {
        visible: false
      });
      var schalter_hp_oben_r = board.create("point", [3, 1], {
        visible: false
      });
      var schalter_kreis_r = board.create("circle",
        [schalter_hp_unten_r, 1], {
        visible: false
      });
      var schalter_punkt_r = board.create("glider", [
        2.5, 0.8, schalter_kreis_r
      ], {
        withLabel: false,
        attractors: [schalter_hp_oben_r],
        attractorDistance: 0.2,
        snatchDistance: 0.1,
        showInfobox: false
      });
      var schalter_r = board.create("segment", [
        schalter_hp_unten_r,
        schalter_punkt_r
      ], curve_attr);

      // Schalter oben:
      var schalter_hp_unten_o = board.create("point", [1.5, 3], {
        visible: false
      });
      var schalter_hp_oben_o = board.create("point", [0.5, 3], {
        visible: false
      });
      var schalter_kreis_o = board.create("circle",
        [schalter_hp_unten_o, 1], {
        visible: false
      });
      var schalter_punkt_o = board.create("glider", [
        0.7, 2.4, schalter_kreis_o
      ], {
        withLabel: false,
        attractors: [schalter_hp_oben_o],
        attractorDistance: 0.2,
        snatchDistance: 0.1,
        showInfobox: false
      });
      var schalter_o = board.create("segment", [
        schalter_hp_unten_o,
        schalter_punkt_o
      ], curve_attr);

      // Glühlampe:
      var kreis = board.create("circle", [[-0.25, -2], 0.25], {
        highlight: false,
        strokeColor: "black",
        strokeWidth: 2,
        fixed: true,
        fillColor: function () {
          if (schalter_punkt_r.X() == schalter_hp_oben_r.X()
            && schalter_punkt_o.X() == schalter_hp_oben_o.X()) {
            return "gold"
          } else {
            return "white"
          }
        }
      });
      var cross1 = board.create("segment", [
        [-0.25 + 0.25 * Math.sin(5 * Math.PI / 4), -2 + 0.25 * Math.cos(5 * Math.PI / 4)],
        [-0.25 + 0.25 * Math.sin(Math.PI / 4), -2 + 0.25 * Math.cos(Math.PI / 4)]
      ], curve_attr);
      var cross1 = board.create("segment", [
        [-0.25 + 0.25 * Math.sin(-5 * Math.PI / 4), -2 + 0.25 * Math.cos(-5 * Math.PI / 4)],
        [-0.25 + 0.25 * Math.sin(-Math.PI / 4), -2 + 0.25 * Math.cos(-Math.PI / 4)]
      ], curve_attr);

      // Binde Punkte an Eingabefeld:
      var points = [schalter_punkt_r, schalter_punkt_o];
      stack_jxg.bind_list_of(ans1Ref, points);
[[/jsxgraph]]

<p style="display:none">[[input:ans1]] [[validation:ans1]]</p>

[[feedback:prt1]]]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>6.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Stromkreis“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/

ta: [[3,1],[0.5,3]];</text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>ta</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>0</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ans1</sans>
        <tans>ta</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Sie haben beide Schalter geschlossen, sodass der Stromkreis geschlossen ist und die Glühlampe leuchtet.</p>]]></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>1</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ans1[1]</sans>
        <tans>ta[1]</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-2-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Sie haben den Schalter auf der rechten Seite geschlossen, aber den auf der oberen Seite nicht. Daher ist der Stromkreis nicht geschlossen und die Glühlampe leuchtet nicht.</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>2</falsenextnode>
        <falseanswernote>prt1-2-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>2</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ans1[2]</sans>
        <tans>ta[2]</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-3-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Sie haben den Schalter auf der oberen Seite geschlossen, aber den auf der rechten Seite nicht. Daher ist der Stromkreis nicht geschlossen und die Glühlampe leuchtet nicht.</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-3-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Sie haben keinen der beiden Schalter geschlossen. Daher ist der Stromkreis nicht geschlossen und die Glühlampe leuchtet nicht.</p>]]></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8572363  -->
  <question type="stack">
    <name>
      <text>Tangente mit positiver Steigung</text>
    </name>
    <questiontext format="moodle_auto_format">
      <text><![CDATA[<p>Verschieben Sie den Punkt \(A\) so, dass die Tangente an \(f\) in \(A\) eine positive Steigung hat.</p>

[[jsxgraph input-ref-ans1="ans1Ref"]]
JXG.Options.text.useMathJax = true;
var board = JXG.JSXGraph.initBoard(divid,{
   boundingbox:[-10,10,10,-10],
   axis:true,
   showCopyright:false
});

var f = board.jc.snippet('{#fx#}', true, 'x', true);

var graph = board.create('functiongraph',[f],{
   strokeWidth:3,
   strokeColor:'darkgreen',
   strokeOpacity:0.6,
   dash:2,
   /*shadow:true, //Schatten funktioniert aktuell nicht*/
   highlight:true,
   highlightStrokeColor:'lightgreen',
   highlightStrokeOpacity:0.3,
   visible:true,
   withLabel:true,
   name:'\\(f\\)',
   label:{
      color:'blue',
      fontSize:16,
      fixed:false
   }
});

var glider = board.create('glider',[0,0,graph]);
stack_jxg.bind_point(ans1Ref,glider);

var tangente = board.create('tangent',[graph,glider]);
[[/jsxgraph]]

<p style="display:none">[[input:ans1]] [[validation:ans1]]</p>

[[feedback:prt1]]]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024072400</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Tangente mit positiver Steigung“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/

fx: expand((x+4)*(x-3)*x/3);
dfx: diff(fx,x);
ta: [3,subst(x=3,fx)];</text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>ta</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>0</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text>px: ans1[1];
stg: subst(x=px,dfx);</text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>GT</answertest>
        <sans>stg</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8382942  -->
  <question type="stack">
    <name>
      <text>Visualisierung Integral</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<p>Berechnen Sie die Größe der Fläche, die der Funktionsgraph von \(f(x)={@fx@}\) und der von \(g(x)={@gx@}\) einschließen.</p>

<p>Die folgende Grafik veranschaulicht das Problem:</p>

[[jsxgraph]]
const board = JXG.JSXGraph.initBoard(divid, {
  axis: true,
  boundingbox: [-5, 5, 5, -5],
  showCopyright: false,
  showNavigation: false,
  pan: { enabled: false },
  zoom: { enabled: false },
});

/* Funktion f: */
var f = board.jc.snippet('{#fx#}', true, 'x', true);

/* Graph der Funktion f: */
var graph_f = board.create("functiongraph", [f],{
  strokeColor:'blue',
  fixed:true
});

/* Funktion g: */
var g = board.jc.snippet('{#gx#}', true, 'x', true);

/* Graph der Funktion g: */
var graph_g = board.create("functiongraph", [g],{
  strokeColor:'green',
  fixed:true
});

/* "Ungleichheit", auf deren Basis die Fläche zwischen den Funktionsgraphen eingefärbt wird: */
var ineq = board.create('inequality', [graph_f, graph_g],{
  visible:false
});

/* Fläche zwischen den Funktionen, nämlich der Schnitt zwischen dem GFraphen von g und der o.g. "Ungleichheit": */
var clip = board.create('curveintersection',
  [ineq, graph_g], {
    fillColor: 'deeppink',
    fillOpacity: 0.2
});
[[/jsxgraph]]

<p>Antwort: Die Flächengröße beträgt [[input:ans1]] Flächeneinheiten. [[validation:ans1]]</p>

[[feedback:prt1]]]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Visualisierung Integral“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/

fx: x + 1;
gx: 2*x^2;

sp: solve(gx-fx,x);
sp: map(rhs,sp);
sp1: sp[1];
sp2: sp[2];

ta: int(gx-fx,x,sp1,sp2);</text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>ta</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>1</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>1</mustverify>
      <showvalidation>1</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ans1</sans>
        <tans>ta</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8382947  -->
  <question type="description">
    <name>
      <text>Hinweis (Codebeispiele)</text>
    </name>
    <questiontext format="moodle_auto_format">
      <text><![CDATA[<h5>Hinweis</h5>

<p>Die folgenden Aufgaben sind nur zur Demonstration technischer Möglichkeiten und nicht für den Einsatz in der Lehre gedeacht. Sie enthalten jeweils einen Code-Block, aus dem Sie den Quellcode der Applikationen kopieren können.</p>]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>0.0000000</defaultgrade>
    <penalty>0.0000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
  </question>

<!-- question: 8243671  -->
  <question type="stack">
    <name>
      <text>Empirische Verteilungsfunktion zeichnen (ab STACK v4.4.3)</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<style>
    .data-table {
        border-collapse: collapse;
        margin: 25px 0;
        font-size: 0.9em;
        min-width: 400px;
        border-radius: 5px 5px 0 0;
        overflow: hidden;
        box-shadow: 0 0 20px rgba(0, 0, 0, 0.15);
        background-color: #ffffff;
        color: #17365c;
    }

    .data-table thead tr {
        background-color: #17365c;
        color: #ffffff;
        text-align: left;
        font-weight: bold;
    }

    .data-table th,
    .data-table td {
        padding: 12px 15px;
    }

    .data-table tbody tr {
        border-bottom: 1px solid #e7e7e7;
    }

    .data-table tbody tr:nth-of-type(even) {
        background-color: #f3f3f3;
    }

    .data-table tbody tr:last-of-type {
        border-bottom: 2px solid #17365c;
    }

    .data-table tbody tr.active-row {
        font-weight: bold;
        color: #17365c;
    }
</style>

<p>Eine Klimastation führt eine Statistik über die Jahresmitteltemperatur der Stadt. Die Jahresmitteltemperatur in den Jahren {#Jahre[1]#} bis {#Jahre[10]#} ist wie folgt verteilt:</p>

<div style="overflow-x:auto;">
	<table class="data-table">
		<thead>
		<tr>
			<th>Jahr</th>
			<td>{#Jahre[1]#}</td>
			<td>{#Jahre[2]#}</td>
			<td>{#Jahre[3]#}</td>
			<td>{#Jahre[4]#}</td>
			<td>{#Jahre[5]#}</td>
			<td>{#Jahre[6]#}</td>
			<td>{#Jahre[7]#}</td>
			<td>{#Jahre[8]#}</td>
			<td>{#Jahre[9]#}</td>
			<td>{#Jahre[10]#}</td>
		</tr>
		</thead>
		<tbody>
		<tr>
			<th>Temperatur [°C]</th>
			<td>{#a1#}</td>
			<td>{#a2#}</td>
			<td>{#a3#}</td>
			<td>{#a4#}</td>
			<td>{#a5#}</td>
			<td>{#a6#}</td>
			<td>{#a7#}</td>
			<td>{#a8#}</td>
			<td>{#a9#}</td>
			<td>{#a10#}</td>
		</tr>
		</tbody>
	</table>
</div>

 <br>

<p>Zeichnen Sie die empirische Verteilungsfunktion dieser Datenpunkte, indem Sie an den Sprungstellen der Funktion per Mausklick Punkte zum Koordinatensystem hinzufügen. Sie können einen bereits hinzugefügten Punkt entfernen, indem Sie auf ihn klicken.</p>

[[jsxgraph input-ref-jsxvar="jsxvarRef"]]
    [[style]]
    .jxgbox  {
        border-style:none;
        background: none;
    }
    [[/style]]

Array.prototype.remove = function ( index ) {
    return this.filter(item => item !== value);
};  

Array.prototype.insert = function ( index, item ) {
    this.splice( index, 0, item );
};        

Array.prototype.insertPos = function ( item ) {
    let pos=this.findIndex(function(number) {
            return number > item;
        });
    if(pos>-1) return pos; else return this.length;
};

JXG.Options.point.snapToGrid = true;
JXG.Options.point.snapSizeX = 0.1;
JXG.Options.point.snapSizeY = 0.1;
JXG.Options.point.withLabel = false;

const board = JXG.JSXGraph.initBoard(divid, {
    showCopyright: false,
    boundingbox: [7.5,1.09,11,-0.1],
    axis: true,
    showNavigation:false,
    pan:{enabled:false},
    zoom:{enabled:false}
});

board.defaultAxes.y.setAttribute({visible:'false'});
board.defaultAxes.x.setAttribute({visible:'false'});

var newXAxis = board.create('axis',[[0,0],[1,0]],{
    ticks:{
        drawZero:true,
        label: {offset: [0,-3], anchorX: 'middle', anchorY: 'top'}
    }
});

var newYAxis = board.create('axis',[[8,0],[8,1]],{
    ticks:{
        label: {offset: [-3,0], anchorX: 'right', anchorY: 'middle'}
    }
});

function unpack_input(value){
    var liste = [];
    var tmp = JSON.parse(value);
    var num_points = tmp.length;
    for (let i=0; i < num_points; i++) {
        let p_temp = [tmp[i].x, tmp[i].y];
        liste.push(p_temp);
    };
    return liste;
};

var linienende = 1000;

var jsxvar_inputfield = document.getElementById(jsxvarRef);
var listeP = [];
var liste_temp = (jsxvar_inputfield.value  == "") ? [] : unpack_input(jsxvar_inputfield.value);
var listeX = (jsxvar_inputfield.value  == "") ? [-1000.1] : liste_temp.map((point)=>point[0]);
var listeY = (jsxvar_inputfield.value  == "") ? [0] : liste_temp.map((point)=>point[1]);
var listeS = [];

for (let i=0;i<listeX.length;i++) {
    var X=JXG._round10(listeX[i],-1);
    var Y=JXG._round10(listeY[i],-1);
    var nextX=0;
    const p=board.create('point', [X, Y]);
    listeP.push(p);
    if(i<listeX.length-1){
        nextX=listeX[i+1];
    } else {
        nextX=linienende;
    };
    const s = board.create('segment', [[X,Y],[nextX, Y]],{
        highlight:false
    });
    listeS.push(s);
};

function getMouseCoords (e, i) {
    var cPos = board.getCoordsTopLeftCorner(e, i),
        absPos = JXG.getPosition(e, i),
        dx = absPos[0]-cPos[0],
        dy = absPos[1]-cPos[1];
    return new JXG.Coords(JXG.COORDS_BY_SCREEN, [dx, dy], board);
};

function down(e) {
    let canCreate = true, i, coords, el;
    if (e[JXG.touchProperty]) {
        // index of the finger that is used to extract the coordinates
        i = 0;
    }
    coords = getMouseCoords(e, i);
    for (let el in board.objects) {
        if(JXG.isPoint(board.objects[el]) && board.objects[el].hasPoint(coords.scrCoords[1], coords.scrCoords[2])) {
            i = listeX.indexOf(board.objects[el].X());
            if(i>-1){
                canCreate = false;
                board.removeObject(listeP[i]);
                board.removeObject(listeS[i]);
                if(i>0){
                    board.removeObject(listeS[i-1]);
                    if(i<listeX.length-1){
                        nextX = listeX[i+1];
                    } else {
                        nextX = linienende;
                    }
                    const s = board.create('segment', [[listeX[i-1],listeY[i-1]],[nextX, listeY[i-1]]],{
                        highlight:false
                    });
                    listeS[i-1]=s;
                };
                listeX.splice(i,1);
                listeY.splice(i,1);
                listeP.splice(i,1);
                listeS.splice(i,1);
            break;
        };
    };
};

if(canCreate && coords.usrCoords[2]>=0 && coords.usrCoords[2]<=1){
    const p = board.create('point', [coords.usrCoords[1], coords.usrCoords[2]]);
    if(listeX.indexOf(p.X())==-1) {
        i = listeX.insertPos(p.X())
            if(i>0){
                board.removeObject(listeS[i-1]);
                const s = board.create('segment',[
                    [listeX[i-1],listeY[i-1]],
                    [p.X(), listeY[i-1]]
                ],{
                        highlight:false
                });
                listeS[i-1] = s;
            };  

            listeX.insert(i,p.X());
            listeY.insert(i,p.Y());
            listeP.insert(i,p);
            stack_jxg.register_object(jsxvarRef, p, serializer);
            if(i<listeX.length-1){
                nextX=listeX[i+1];
            } else {
                nextX=linienende;
            };
            const s = board.create('segment', [[p.X(),p.Y()],[nextX, p.Y()]],{
                highlight:false
            });
            listeS.insert(i,s);
        } else {
            i = listeX.indexOf(p.X());
            board.removeObject(listeP[i]);
            board.removeObject(listeS[i]);
            if(i<listeX.length-1){
                nextX=listeX[i+1];
            } else {
                nextX=linienende;
            };
            const s = board.create('segment', [[p.X(),p.Y()],[nextX, p.Y()]]);
            listeS[i]=s;
            listeY[i]=p.Y();
            listeP[i]=p;
            stack_jxg.register_object(jsxvarRef, p, serializer);
        };
    };
};

board.on('down', down);

function serializer(){
    var r = [];
    for (let i=0; i < listeP.length; i++) {
        r.push({x:listeP[i].X(),y:listeP[i].Y()});
    };
    return JSON.stringify(r);
}; 

function deserializer(value){};

stack_jxg.custom_bind(jsxvarRef, serializer, deserializer, listeP);
[[/jsxgraph]]

<p>Bitte klicken Sie nach dem Zeichnen auf "Prüfen".</p>

<div id="stackinput" style="display:none;">
    [[input:jsxvar]] [[validation:jsxvar]]
</div>

[[feedback:prt1]]]]></text>
    </questiontext>
    <generalfeedback format="html">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2023060500</text>
    </stackversion>
    <questionvariables>
      <text><![CDATA[/*
  Empirische Verteilungsfunktion zeichnen

  wurde entwickelt von
  
    Jonas Lache <jonas.lache[at]ruhr-uni-bochum.de>
    Michael Kallweit <michael.kallweit[at]ruhr-uni-bochum.de>

  unter Mithilfe von

    Daniel Meißner <daniel.meissner-i4k[at]ruhr-uni-bochum.de>

  an der Ruhr-Universität Bochum.

  Dieses Werk ist lizenziert unter einer Creative Commons
  Namensnennung-Weitergabe unter gleichen Bedingungen 4.0 International
  Lizenz. Um eine Kopie der Lizenz zu erhalten, besuchen Sie
  http://creativecommons.org/licenses/by-sa/4.0/.

  SPDX-License-Identifier: CC-BY-SA-4.0

  Technische Informationen:
  
  Der Fragetext dieser Aufgabe enthält Jahreszahlen. Es empfiehlt sich,
  die entsprechende Maxima-Variable `Jahre` zu aktualisieren, damit die
  Jahreszahlen nicht veraltet wirken.

  Die interaktive Grafik enthält Teile des Codes der Universität Bayreuth, siehe 
  https://jsxgraph.uni-bayreuth.de/wiki/index.php?title=Browser_event_and_coordinates

  Diese Aufgabe ist ursprünglich im Landesportal ORCA.nrw
  erschienen:
  https://www.twillo.de/edu-sharing/components/render/e80c5ca0-c53d-45fc-b2c2-4e34b85f2e0e

  Bei der vorliegenden Version handelt es sich um eine von Jonas Lache
  an der Hochschule Ruhr West bearbeitete Version (letzte Änderung: 30.01.2024).
*/

/*ALLGEMEINE FUNKTIONEN/EINSTELLUNGEN:*/
fpprintprec: 4; /*Anzahl der gedruckten Stellen*/
summe(L):=sum(L[k],k,1,length(L)); /*Funktion für Summe der Elemente der Liste "L"*/
dp(x):=decimalplaces(x,2);
dpM(M):=setify(map(dp, listify(M)));
/*Überprüft, ob eine Antwort mit Sprungstellen in der Liste L monoton steigend ist:*/
monotonp(L):=is(sort(makelist((sort(L))[k][2],k,1,length(sort(L))))=makelist((sort(L))[k][2],k,1,length(sort(L))));
/*Häufigkeit von x in der Liste L:*/
haeuf(L,x):=length(sublist(L,lambda([z],z=x)));

unpack_coordinates(m) := block([],
 if not ev(listp(m) and is(unique(map(is_stackmap,m))=[true]), simp) then return(und), 
 if is(map(lambda([x],listp(x) and is(length(x)=3)),m)=[false]) then return(und),
 return(makelist([m[i][2][2],m[i][3][2]],i,1,length(m)))
);

/*AUFGABENSTELLUNG:*/
/*Folgende Variable ggf. aktualisieren, damit die Daten nicht veraltet wirken*/
Jahre: makelist(2013+i,i,0,9);
/*Eindeutige Datenwerte:*/
wert1: rand_with_step(85,105,1); /*Ein Wert kommt dreimal vor*/
wert2: rand_with_prohib(85,105,[wert1]); /*Ein Wert kommt zweimal vor*/
wert3: rand_with_prohib(85,105,[wert1,wert2]); /*Auch dieser Wert kommt zweimal vor*/
wert4: rand_with_prohib(85,105,[wert1,wert2,wert3]); /*usw.*/
wert5: rand_with_prohib(85,105,[wert1,wert2,wert3,wert4]);
wert6: rand_with_prohib(85,105,[wert1,wert2,wert3,wert4,wert5]);
/*Die endgültigen Datenwerte (doppelt möglich):*/
AListe:decimalplaces([wert1,wert1,wert1,wert2,wert2,wert3,wert3,wert4,wert5,wert6]/10,2);
AListe: random_permutation(AListe);
a1: AListe[1]; /*Wert Jahr 1*/
a2: AListe[2]; /*Wert Jahr 2*/
a3: AListe[3]; /*Wert Jahr 3*/
a4: AListe[4]; /*Wert Jahr 4*/
a5: AListe[5]; /*Wert Jahr 5*/
a6: AListe[6]; /*Wert Jahr 6*/
a7: AListe[7]; /*Wert Jahr 7*/
a8: AListe[8]; /*Wert Jahr 8*/
a9: AListe[9]; /*Wert Jahr 9*/
a10: AListe[10]; /*Wert Jahr 10*/
A: summe(AListe); /*Summe*/

/*BERECHNUNG DER KORREKTEN FUNKTION*/

/* Liste mit Listen [i, f(i)], wobei i alle Zahlen vom kleinsten bis zum größten Datenwert in 0.1-Schritten sind. f(i) ist die absolute Häufigkeit dieser Zahlen im Datensatz. */
Ahaeuf1: makelist(
    [k/10, haeuf(AListe,k/10)],
    k,
    10*lmin(AListe),
    10*lmax(AListe)
);

/* Aus Ahaeuf1 werden alle Elemente [i,f(i)] entfernt, bei denen f(i)=0 ist */
Ahaeuf2: sort(
    sublist(Ahaeuf1,lambda([L],is(L[2]#0)))
);

/* Ahaeuf2 wird so umgewandelt, dass die Liste nun Elemente [i,p(i)] enthält, wobei p(i) relative Häufigkeiten sind */
Ahaeuf3: makelist([Ahaeuf2[k][1], float(Ahaeuf2[k][2]/length(AListe))],k,1,length(Ahaeuf2));

/* Ahaeuf3 wird so umgewandelt, dass die Liste nun Elemente [i,P(i)] enthält, wobei P(i) kumulierte relative Häufigkeiten sind */
Ahaeuf4: makelist([Ahaeuf3[k][1], sum(Ahaeuf3[i][2],i,1,k)],k,1,length(Ahaeuf3));

/* Es wird noch eine Rundungsfunktion angewendet, damit es keine Probleme mit FLießkommazahlen gibt */
empVert:map(lambda([x],decimalplaces(x,2)),Ahaeuf4);

/* Unwandeln in eine Menge: */
TAns1: setify( map(lambda([x], decimalplaces(x,2)), empVert));

/* String für die Musterlösung: */
empVert_var:cons([-1000.0,0],empVert);
TAns1_string: makelist(sconcat("{\"x\":",  empVert_var[i][1],  ",",  "\"y\":",  empVert_var[i][2],  "},"),i,1,length(empVert_var)-1);
TAns1_string: endcons(sconcat("{\"x\":",  last(empVert_var)[1],  ",",  "\"y\":",  last(empVert_var)[2],  "}"),TAns1_string);
TAns1_string: apply(sconcat,TAns1_string);
TAns1_string: sconcat("[",  TAns1_string,  "]");]]></text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text>{#AListe#}</text>
    </questionnote>
    <questiondescription format="html">
      <text></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> Richtige Antwort, gut gemacht!]]></text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text><![CDATA[<span style="font-size: 1.5em; color:orange;"><i class="fa fa-adjust"></i></span> Ihre Antwort ist teilweise korrekt.]]></text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text><![CDATA[<span style="font-size: 1.5em; color:red;"><i class="fa fa-times"></i></span> Falsche Antwort.]]></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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>jsxvar</name>
      <type>string</type>
      <tans>TAns1_string</tans>
      <boxsize>40</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>1</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text><![CDATA[/* === Erklärung der Knoten ====
Knoten 1: Wurde mindestens ein Punkt gezeichnet?
Knoten 2: Ist die empirische Verteilungsfunktion komplett richtig?
Knoten 3: Sind alle Punkte richtig, aber noch überflüssige hinzugefügt?
Knoten 4: Ist die Funktion monoton wachsend?
Knoten 5: Erreicht die Funktion die 1?
Knoten 6: Ist die Anzahl der Datenwerte, für die es keinen Punkt gibt, =0?
Knoten 7: Sind Punkte dabei, deren x-Koordinate keinem Datenwert entspricht?
Knoten 8: Entsprechen die y-Werte den relativen Häufigkeiten?
*/

/* String parsen und in eine Liste mit Punkten umwandeln: */
parsed_ans: stackjson_parse(jsxvar);
jsxvar_liste: unpack_coordinates(parsed_ans);

/* Umwandlung der Antwort in Dezimalzahlen, dann alle Punkte mit x-Koordinate < 7.5 aus der Liste löschen: */
SAns: decimalplaces(jsxvar_liste,2);
SAns: sublist(SAns,lambda([l],l[1]>=7.5));

/*Unwandeln der Antwort in eine Menge*/
SAns1: setify( map(lambda([x], decimalplaces(x,2)), SAns));

/*Liste, in denen nur die y-Werte der Punkte vorhanden sind:*/
SAns1_y: makelist(sort(listify(SAns1))[k][2],k,1,length(SAns1));

/* Überprüfen, ob die Funktion im Limes 1 erreicht: */
erreicht_eins: is(last(SAns1_y)=1.0);

/* ============================
Analyse der Antwort der Studierenden:
 ============================ */

/* ==== TEIL 1: Angegebene Punkte, die nicht in empVert vorkommen ==== */
/*Punkte, deren x-Werte nicht in AListe vorkommen*/
SAnsFalscherXWert: sublist(SAns,lambda([L],not member(L[1],AListe)));

/*Gibt den eigentlich korrekten y-Wert für den gegebenen x-Wert zurück*/
korr_y(pkt):=block([L,el],
	/*Liste aller korrekten Punkte, deren x-Wert
	kleiner als der angegebene Punkt p sind:*/
	L: sublist(empVert,lambda([L],L[1]<pkt[1])),
	/*Wenn Liste nicht leer, dann gib den y-Wert
	dieses Punkts zurück (sonst 0):*/
	el: if L#[] then last(sort(L))[2] else 0,
	return(el)
);

/*Alle überflüssigen Punkte (d. h. alle, deren y-Wert mit dem des korrekten Punkts übereinstimmt, dessen x-Wert der nächstkleinere aus der Liste der korrekten Antworten ist):*/
ueberfluessige_Punkte: sublist(SAnsFalscherXWert, lambda([L],decimalplaces(korr_y(L),2)=L[2]));

/* Punke, deren x-Wert nicht im Datensatz enthalten ist: */
Punkte_falscher_x_Wert: sublist(SAnsFalscherXWert, lambda([L], not member(L, ueberfluessige_Punkte)));

/* ==== TEIL 2: Punkte, die in empVert vorkommen, aber in SAns fehlen ==== */
/*Alle richtig genannten Punkte:*/
richtige_Punkte: sublist(SAns, lambda([L], member(L, empVert)));
richtige_Punkte: decimalplaces(richtige_Punkte,2);

/*Datenpunkte, die evtl. nicht als x-Werte vorkommen:*/
evtl_fehlende_Datenwerte: sublist(unique(AListe), lambda([el], length(sublist(richtige_Punkte, lambda([L],L[1]=el)))=0));

/*x-Wert aus den Daten, aber falscher y-Wert:*/
Punkte_falscher_y_Wert: sublist(SAns, lambda([L], member(L[1], evtl_fehlende_Datenwerte)));

/*Datenwert, für den gar kein Punkt angegeben wurde:*/
tatsaechlich_fehlende_Datenwerte: block([L, L2],
    L: evtl_fehlende_Datenwerte,
    L2: makelist(Punkte_falscher_y_Wert[i][1],i,1,length(Punkte_falscher_y_Wert)),
    for i:1 thru length(L2) do L: delete(L2[i], L),
    return(L)
);

/*String für den Feedbacktext:*/
string_punkte_ueberfluessig: if length(ueberfluessige_Punkte)>1 then "die Punkte" else "den Punkt";]]></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans><![CDATA[is(length(SAns1)>0)]]></sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>=</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>1</truenextnode>
        <trueanswernote>jsxgraph-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>jsxgraph-1-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[[[ comment ]] Es wurden keine Punkte platziert, [[/ comment ]]
<p>Bitte zeichnen Sie Punkte ein, indem Sie per Mausklick Punkte zum Koordinatensystem hinzufügen. Klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>1</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>SAns1</sans>
        <tans>TAns1</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>jsxgraph-2-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[[[ comment ]] Funktion ist korrekt. [[/ comment ]]
<p>Hier ist noch einmal Ihre Funktion – sie ist korrekt.</p>
[[jsxgraph]]
    [[style]]
    .jxgbox  {
        border-style:none;
        background: none;
    }
    [[/style]]

JXG.Options.point.withLabel = false;

const board = JXG.JSXGraph.initBoard(divid, {
    showCopyright: false,
    boundingbox: [7.5,1.09,11,-0.1],
    axis: true,
    showNavigation:false,
    pan:{enabled:false},
    zoom:{enabled:false}
});

board.defaultAxes.y.setAttribute({visible:'false'});
board.defaultAxes.x.setAttribute({visible:'false'});

var newXAxis = board.create('axis',[[0,0],[1,0]],{
    ticks:{
        drawZero:true,
        label: {offset: [0,-3], anchorX: 'middle', anchorY: 'top'}
    }
});

var newYAxis = board.create('axis',[[8,0],[8,1]],{
    ticks:{
        label: {offset: [-3,0], anchorX: 'right', anchorY: 'middle'}
    }
});

var ans = {#SAns#};

var punkte = [];
var strecken = [];

//Punkte hinzufügen:
for(let p of ans){
    punkte.push(
        board.create('point',p,{
            fixed:true,
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        [-1000,0],
        [punkte[0].X(), 0]
    ],{
        fixed:true,
        highlight:false
    })
);

for(let i=1; i<punkte.length; i++){
    strecken.push(
        board.create('segment', [
            punkte[i-1],
            [punkte[i].X(), punkte[i-1].Y()]
        ],{
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        punkte[punkte.length-1],
        [1000, punkte[punkte.length-1].Y()]
    ],{
        highlight:false
    })
);
[[/jsxgraph]]

<hr>

<p>Herzlichen Glückwunsch, Sie sind am Ende der Aufgabe angelangt! Sie sollten nun eine empirische Verteilungsfunktion aus einem gegebenen Datensatz zeichnen können.</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>2</falsenextnode>
        <falseanswernote>jsxgraph-2-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>2</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>setdifference(SAns1, setify(ueberfluessige_Punkte))</sans>
        <tans>TAns1</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0.5</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>jsxgraph-3-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[[[ comment ]] Funktion ist richtig bis auf "unnötige" Punkte außerhalb der Sprungstellen. [[/ comment ]]
<p>Ihre Funktion ist grundsätzlich richtig, aber enthält mindestens einen Punkt, ohne den die Funktion ebenfalls richtig gewesen wäre:</p>

<p>Wenn Sie {@string_punkte_ueberfluessig@} {@sequenceify(ueberfluessige_Punkte)@} weglassen, ändert sich die Funktion nicht. In der folgenden Grafik sind diese Punkte mit einer schwarzen Box umrandet.</p>

[[jsxgraph]]
    [[style]]
    .jxgbox  {
        border-style:none;
        background: none;
    }
    [[/style]]

JXG.Options.point.withLabel = false;

const board = JXG.JSXGraph.initBoard(divid, {
    showCopyright: false,
    boundingbox: [7.5,1.09,11,-0.1],
    axis: true,
    showNavigation:false,
    pan:{enabled:false},
    zoom:{enabled:false}
});

board.defaultAxes.y.setAttribute({visible:'false'});
board.defaultAxes.x.setAttribute({visible:'false'});

var newXAxis = board.create('axis',[[0,0],[1,0]],{
    ticks:{
        drawZero:true,
        label: {offset: [0,-3], anchorX: 'middle', anchorY: 'top'}
    }
});

var newYAxis = board.create('axis',[[8,0],[8,1]],{
    ticks:{
        label: {offset: [-3,0], anchorX: 'right', anchorY: 'middle'}
    }
});

var ans = {#empVert#};
var ueberfluessig = {#ueberfluessige_Punkte#};

var punkte = [];
var ueberfluessige_punkte = [];
var strecken = [];

//Punkte hinzufügen:
for(let p of ans){
    punkte.push(
        board.create('point',p,{
            fixed:true,
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        [-1000,0],
        [punkte[0].X(), 0]
    ],{
        fixed:true,
        highlight:false
    })
);

for(let i=1; i<punkte.length; i++){
    strecken.push(
        board.create('segment', [
            punkte[i-1],
            [punkte[i].X(), punkte[i-1].Y()]
        ],{
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        punkte[punkte.length-1],
        [1000, punkte[punkte.length-1].Y()]
    ],{
        highlight:false
    })
);

//Überflüssige Punkte hinzufügen:
for(let p of ueberfluessig){
    ueberfluessige_punkte.push(
        board.create('point',p,{
            fixed:true,
            highlight:false
        })
    );
    board.create('point',p,{
        fixed:true,
        face:'[]',
        fillColor:'transparent',
        strokeColor:'black',
        highlight:false,
        size:7
    });
};
[[/jsxgraph]]

<p>Bitte entfernen Sie die überflüssigen Punkte in der Grafik im Fragetext und klicken Sie dann erneut auf "Prüfen".</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>3</falsenextnode>
        <falseanswernote>jsxgraph-3-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
      <node>
        <name>3</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>monotonp(jsxvar_liste)</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>4</truenextnode>
        <trueanswernote>jsxgraph-4-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>4</falsenextnode>
        <falseanswernote>jsxgraph-4-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[[[ comment ]] Funktion ist nicht monoton wachsend. [[/ comment ]]
<p>Ihre Funktion ist nicht monoton wachsend. Eine empirische Verteilungsfunktion muss aber immer monoton wachsend sein.</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>4</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>erreicht_eins</sans>
        <tans>true</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>5</truenextnode>
        <trueanswernote>jsxgraph-5-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>5</falsenextnode>
        <falseanswernote>jsxgraph-5-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[[[ comment ]] Funktion erreicht nicht die 1. [[/ comment ]]

[[ if test='is(monotonp(jsxvar_liste))']]
<p>Ihre Funktion erfüllt nicht die Eigenschaft, dass sie für \(x\rightarrow\infty\) den Wert 1 annimmt. Eine empirische Verteilungsfunktion muss sich im Limes aber immer 1 annähern.</p>
[[ else ]]
<p>Zudem erfüllt sie nicht die Eigenschaft, dass sie für \(x\rightarrow\infty\) den Wert 1 annimmt. Eine empirische Verteilungsfunktion muss sich im Limes aber immer 1 annähern.</p>
[[/ if ]]]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>5</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(tatsaechlich_fehlende_Datenwerte)</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>6</truenextnode>
        <trueanswernote>jsxgraph-6-T</trueanswernote>
        <truefeedback format="html">
          <text>[[ comment ]] D. h. für jeden der Datenwerte gibt es einen Punkt [[/ comment ]]</text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>jsxgraph-6-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[[[ comment ]] D. h. es gibt mindestens einen Datenwert ohne Punkt [[/ comment ]]

<p>Wenn eine empirische Verteilungsfunktion gezeichnet wird, dann muss für jeden Wert \(x_i\), der in den zugrundeliegenden Daten vorhanden ist, ein Punkt \([x_i, y_i]\) gezeichnet werden. </p>

<p>Allerdings gibt es mindestens einen Datenwert, für den Sie einen solchen Punkt nicht eingezeichnet haben.<!--, nämlich die folgenden: {@sequenceify(tatsaechlich_fehlende_Datenwerte)@}-->
</p>

<p>In der folgenden Grafik sehen Sie noch einmal Ihre empirische Verteilungsfunktion.<br>
Die x-Stellen, an denen ein Datenwert liegt, Sie aber keinen Punkt gezeichnet haben, sind durch gestrichelte vertikale Linien markiert.</p>

[[jsxgraph]]
    [[style]]
    .jxgbox  {
        border-style:none;
        background: none;
    }
    [[/style]]

JXG.Options.point.withLabel = false;

const board = JXG.JSXGraph.initBoard(divid, {
    showCopyright: false,
    boundingbox: [7.5,1.09,11,-0.1],
    axis: true,
    showNavigation:false,
    pan:{enabled:false},
    zoom:{enabled:false}
});

board.defaultAxes.y.setAttribute({visible:'false'});
board.defaultAxes.x.setAttribute({visible:'false'});

var newXAxis = board.create('axis',[[0,0],[1,0]],{
    ticks:{
        drawZero:true,
        label: {offset: [0,-3], anchorX: 'middle', anchorY: 'top'}
    }
});

var newYAxis = board.create('axis',[[8,0],[8,1]],{
    ticks:{
        label: {offset: [-3,0], anchorX: 'right', anchorY: 'middle'}
    }
});

var ans = {#SAns#};

var punkte = [];
var strecken = [];

//Punkte hinzufügen:
for(let p of ans){
    punkte.push(
        board.create('point',p,{
            fixed:true,
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        [-1000,0],
        [punkte[0].X(), 0]
    ],{
        fixed:true,
        highlight:false
    })
);

for(let i=1; i<punkte.length; i++){
    strecken.push(
        board.create('segment', [
            punkte[i-1],
            [punkte[i].X(), punkte[i-1].Y()]
        ],{
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        punkte[punkte.length-1],
        [1000, punkte[punkte.length-1].Y()]
    ],{
        highlight:false
    })
);

//Stellen Werten, wo keine Punkte sind, obwohl Datenwert dort existiert
var fehlendeDatenwerte = {#tatsaechlich_fehlende_Datenwerte#};
for(let x of fehlendeDatenwerte){
	board.create('line',[[x,-1],[x,1]],{
		dash:2,
		highlight:false,
		color:'black',
		fixed:true,
                strokeWidth:1
	})
};
[[/jsxgraph]]

<p>Bitte korrigieren Sie Ihre Lösung in der Grafik im Fragetext und klicken Sie dann noch einmal auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>6</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>length(SAnsFalscherXWert)</sans>
        <tans>0</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>7</truenextnode>
        <trueanswernote>jsxgraph-7-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>jsxgraph-7-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[[[ comment ]] Es gibt mindestens einen Punkt, dessen x-Koordinate keinem Datenwert entspricht [[/ comment ]]

<p>Ihre Funktion enthält mindestens einen Punkt, dessen x-Koordinate nicht mit einem Wert aus dem Datensatz übereinstimmt.</p>

<p>In der folgenden Grafik sehen Sie noch einmal Ihre empirische Verteilungsfunktion.<br>
Die Punkte, die an x-Stellen liegen, die keinem Datenwert entsprechen, sind mit einer schwarzen Box umrandet.</p>

[[jsxgraph]]
    [[style]]
    .jxgbox  {
        border-style:none;
        background: none;
    }
    [[/style]]

JXG.Options.point.withLabel = false;

const board = JXG.JSXGraph.initBoard(divid, {
    showCopyright: false,
    boundingbox: [7.5,1.09,11,-0.1],
    axis: true,
    showNavigation:false,
    pan:{enabled:false},
    zoom:{enabled:false}
});

board.defaultAxes.y.setAttribute({visible:'false'});
board.defaultAxes.x.setAttribute({visible:'false'});

var newXAxis = board.create('axis',[[0,0],[1,0]],{
    ticks:{
        drawZero:true,
        label: {offset: [0,-3], anchorX: 'middle', anchorY: 'top'}
    }
});

var newYAxis = board.create('axis',[[8,0],[8,1]],{
    ticks:{
        label: {offset: [-3,0], anchorX: 'right', anchorY: 'middle'}
    }
});

var ans = {#SAns#};

var punkte = [];
var strecken = [];

//Punkte hinzufügen:
for(let p of ans){
	punkte.push(
        board.create('point',p,{
            fixed:true,
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        [-1000,0],
        [punkte[0].X(), 0]
    ],{
        fixed:true,
        highlight:false
    })
);

for(let i=1; i<punkte.length; i++){
    strecken.push(
        board.create('segment', [
            punkte[i-1],
            [punkte[i].X(), punkte[i-1].Y()]
        ],{
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        punkte[punkte.length-1],
        [1000, punkte[punkte.length-1].Y()]
    ],{
        highlight:false
    })
);

//Punkte markieren, an denen kein Datenwert liegt:
var PunkteKeinDatenwert = {#SAnsFalscherXWert#};
for(let p of PunkteKeinDatenwert){
    board.create('point',p,{
        fixed:true,
        face:'[]',
        fillColor:'transparent',
        strokeColor:'black',
        highlight:false,
        size:7
    });
};
[[/jsxgraph]]

<p>Bitte korrigieren Sie Ihre Lösung in der Grafik im Fragetext und klicken Sie dann noch einmal auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
      <node>
        <name>7</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>SAns1</sans>
        <tans>setify(Ahaeuf3)</tans>
        <testoptions></testoptions>
        <quiet>1</quiet>
        <truescoremode>+</truescoremode>
        <truescore>0</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>jsxgraph-8-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[[[ comment ]] x-Stellen der Punkte sind korrekt, aber scheinbar entsprechen die y-Werte den relativen Häufigkeiten [[/ comment ]]


<p>Ihre Funktion enthält Punkte an allen Stellen, die Werten im gegebenen Datensatz entsprechen. Allerdings gibt es mindestens einen Punkt, der eine falsche y-Koordinate besitzt.</p>

<p>Kann es sein, dass Sie als y-Koordinaten die relative Häufigkeit des jeweilgen Datenwertes verwendet haben? Bei einer empirischen Verteilungsfunktion müssen allerdings die <em>kumulierten</em> relativen Häufigkeiten verwendet werden, d. h. die Summe der relativen Häufigkeiten aller Werte, die kleiner als der betrachtete Wert oder gleich ihm sind.</p>

<p>In der folgenden Grafik sehen Sie noch einmal Ihre empirische Verteilungsfunktion. Die Punkte, die an einem korrekten Datenwert liegen, aber einen falschen y-Wert haben, sind schwarz umkreist.
</p>

[[jsxgraph]]
    [[style]]
    .jxgbox  {
        border-style:none;
        background: none;
    }
    [[/style]]

JXG.Options.point.withLabel = false;

const board = JXG.JSXGraph.initBoard(divid, {
    showCopyright: false,
    boundingbox: [7.5,1.09,11,-0.1],
    axis: true,
    showNavigation:false,
    pan:{enabled:false},
    zoom:{enabled:false}
});

board.defaultAxes.y.setAttribute({visible:'false'});
board.defaultAxes.x.setAttribute({visible:'false'});

var newXAxis = board.create('axis',[[0,0],[1,0]],{
    ticks:{
        drawZero:true,
        label: {offset: [0,-3], anchorX: 'middle', anchorY: 'top'}
    }
});

var newYAxis = board.create('axis',[[8,0],[8,1]],{
    ticks:{
        label: {offset: [-3,0], anchorX: 'right', anchorY: 'middle'}
    }
});

var ans = {#SAns#};

var punkte = [];
var strecken = [];

//Punkte hinzufügen:
for(let p of ans){
    punkte.push(
        board.create('point',p,{
            fixed:true,
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        [-1000,0],
        [punkte[0].X(), 0]
    ],{
        fixed:true,
        highlight:false
    })
);

for(let i=1; i<punkte.length; i++){
    strecken.push(
        board.create('segment', [
            punkte[i-1],
            [punkte[i].X(), punkte[i-1].Y()]
        ],{
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        punkte[punkte.length-1],
        [1000, punkte[punkte.length-1].Y()]
    ],{
        highlight:false
    })
);

//Stellen Werten, wo keine Punkte sind, obwohl Datenwert dort existiert
/*var fehlendeDatenwerte = {#tatsaechlich_fehlende_Datenwerte#};
for(let x of fehlendeDatenwerte){
	board.create('line',[[x,-1],[x,1]],{
		dash:2,
		highlight:false,
		color:'black',
		fixed:true,
		strokeWidth:1
	})
};*/

//Punkte markieren, bei denen der y-Wert falsch ist:
var PunkteFalscherXWert = {#Punkte_falscher_y_Wert#};
for(let p of PunkteFalscherXWert){
    board.create('point',p,{
        fixed:true,
        face:'o',
        strokeColor:'black',
        fillColor:'transparent',
        highlight:false,
        size:7
    });
};
[[/jsxgraph]]

<p>Bitte korrigieren Sie Ihre Lösung in der Grafik im Fragetext und klicken Sie dann noch einmal auf "Prüfen".</p>]]></text>
        </truefeedback>
        <falsescoremode>-</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>jsxgraph-8-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[[[ comment ]] x-Stellen der Punkte sind korrekt, aber mindestens ein falscher y-Wert [[/ comment ]]

<p>Ihre Funktion enthält Punkte an allen Stellen, die Werten im gegebenen Datensatz entsprechen. Allerdings gibt es mindestens einen Punkt, der eine falsche y-Koordinate besitzt.</p>

<p>In der folgenden Grafik sehen Sie noch einmal Ihre empirische Verteilungsfunktion. Die Punkte, die an einem korrekten Datenwert liegen, aber einen falschen y-Wert haben, sind schwarz umkreist.
</p>

[[jsxgraph]]
    [[style]]
    .jxgbox  {
        border-style:none;
        background: none;
    }
    [[/style]]

JXG.Options.point.withLabel = false;

const board = JXG.JSXGraph.initBoard(divid, {
    showCopyright: false,
    boundingbox: [7.5,1.09,11,-0.1],
    axis: true,
    showNavigation:false,
    pan:{enabled:false},
    zoom:{enabled:false}
});

board.defaultAxes.y.setAttribute({visible:'false'});
board.defaultAxes.x.setAttribute({visible:'false'});

var newXAxis = board.create('axis',[[0,0],[1,0]],{
    ticks:{
        drawZero:true,
        label: {offset: [0,-3], anchorX: 'middle', anchorY: 'top'}
    }
});

var newYAxis = board.create('axis',[[8,0],[8,1]],{
    ticks:{
        label: {offset: [-3,0], anchorX: 'right', anchorY: 'middle'}
    }
});

var ans = {#SAns#};

var punkte = [];
var strecken = [];

//Punkte hinzufügen:
for(let p of ans){
    punkte.push(
        board.create('point',p,{
            fixed:true,
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        [-1000,0],
        [punkte[0].X(), 0]
    ],{
        fixed:true,
        highlight:false
    })
);

for(let i=1; i<punkte.length; i++){
    strecken.push(
        board.create('segment', [
            punkte[i-1],
            [punkte[i].X(), punkte[i-1].Y()]
        ],{
            highlight:false
        })
    );
};

strecken.push(
    board.create('segment',[
        punkte[punkte.length-1],
        [1000, punkte[punkte.length-1].Y()]
    ],{
        highlight:false
    })
);

//Stellen Werten, wo keine Punkte sind, obwohl Datenwert dort existiert
/*var fehlendeDatenwerte = {#tatsaechlich_fehlende_Datenwerte#};
for(let x of fehlendeDatenwerte){
	board.create('line',[[x,-1],[x,1]],{
		dash:2,
		highlight:false,
		color:'black',
		fixed:true,
		strokeWidth:1
	})
};*/

//Punkte markieren, bei denen der y-Wert falsch ist:
var PunkteFalscherXWert = {#Punkte_falscher_y_Wert#};
for(let p of PunkteFalscherXWert){
    board.create('point',p,{
        fixed:true,
        face:'o',
        strokeColor:'black',
        fillColor:'transparent',
        highlight:false,
        size:7
    });
};
[[/jsxgraph]]

<p>Bitte korrigieren Sie Ihre Lösung in der Grafik im Fragetext und klicken Sie dann noch einmal auf "Prüfen".</p>]]></text>
        </falsefeedback>
      </node>
    </prt>
    <deployedseed>2113543810</deployedseed>
    <deployedseed>518728290</deployedseed>
    <deployedseed>977686642</deployedseed>
    <deployedseed>625392613</deployedseed>
    <deployedseed>419613540</deployedseed>
    <deployedseed>546541248</deployedseed>
    <deployedseed>901152908</deployedseed>
    <deployedseed>2114373628</deployedseed>
    <deployedseed>473415785</deployedseed>
    <deployedseed>1319798863</deployedseed>
    <deployedseed>1827996118</deployedseed>
    <deployedseed>1377738284</deployedseed>
    <deployedseed>1146938707</deployedseed>
    <deployedseed>1649252600</deployedseed>
    <deployedseed>1340042614</deployedseed>
    <deployedseed>1806623013</deployedseed>
    <deployedseed>175594256</deployedseed>
    <deployedseed>1935287162</deployedseed>
    <deployedseed>1232219398</deployedseed>
    <deployedseed>632400565</deployedseed>
    <deployedseed>1887803909</deployedseed>
    <deployedseed>922667474</deployedseed>
    <deployedseed>127099428</deployedseed>
    <deployedseed>1888683775</deployedseed>
    <deployedseed>559817050</deployedseed>
    <deployedseed>221847889</deployedseed>
    <deployedseed>149940121</deployedseed>
    <deployedseed>156905201</deployedseed>
    <deployedseed>710540382</deployedseed>
    <deployedseed>800091485</deployedseed>
    <deployedseed>1526168687</deployedseed>
    <deployedseed>557180573</deployedseed>
    <deployedseed>1642629653</deployedseed>
    <deployedseed>594727517</deployedseed>
    <deployedseed>1606422572</deployedseed>
    <deployedseed>864119331</deployedseed>
    <deployedseed>1780065340</deployedseed>
    <deployedseed>842347566</deployedseed>
    <deployedseed>1172114908</deployedseed>
    <deployedseed>459727824</deployedseed>
    <deployedseed>140001064</deployedseed>
    <deployedseed>261129400</deployedseed>
    <deployedseed>1248514742</deployedseed>
    <deployedseed>2110534384</deployedseed>
    <deployedseed>2064177855</deployedseed>
    <deployedseed>98547081</deployedseed>
    <deployedseed>18662775</deployedseed>
    <deployedseed>402877091</deployedseed>
    <deployedseed>2143584712</deployedseed>
    <deployedseed>1438659174</deployedseed>
    <deployedseed>332256278</deployedseed>
    <deployedseed>823811409</deployedseed>
    <deployedseed>2048176229</deployedseed>
    <deployedseed>752099367</deployedseed>
    <deployedseed>1041438219</deployedseed>
    <deployedseed>968141737</deployedseed>
    <deployedseed>1956112194</deployedseed>
    <deployedseed>1838836537</deployedseed>
    <deployedseed>1320409124</deployedseed>
    <deployedseed>138669644</deployedseed>
    <deployedseed>288815200</deployedseed>
    <deployedseed>607887934</deployedseed>
    <deployedseed>1448362307</deployedseed>
    <deployedseed>2137251412</deployedseed>
    <deployedseed>840792350</deployedseed>
    <deployedseed>1338370660</deployedseed>
    <deployedseed>1800316761</deployedseed>
    <deployedseed>1509530448</deployedseed>
    <deployedseed>1895991643</deployedseed>
    <deployedseed>1564636420</deployedseed>
    <deployedseed>1169742506</deployedseed>
    <deployedseed>1354145323</deployedseed>
    <qtest>
      <testcase>1</testcase>
      <description></description>
      <testinput>
        <name>jsxvar</name>
        <value>empVert</value>
      </testinput>
      <expected>
        <name>prt1</name>
        <expectedscore>1.0000000</expectedscore>
        <expectedpenalty>0.0000000</expectedpenalty>
        <expectedanswernote>jsxgraph-2-T</expectedanswernote>
      </expected>
    </qtest>
  </question>

<!-- question: 8381487  -->
  <question type="stack">
    <name>
      <text>Parabel mit Nullstellen (Schieberegler)</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<p>In der Grafik sehen Sie den Graphen der Funktion \(f(x)=(a-x)(b-x)\), wobei \(a\) und \(b\) von den Schiebereglern abhängen. Verändern Sie die Schieberegler so, dass die Funktion achsensymmetrisch zur \(y\)-Achse ist.</p>

[[jsxgraph input-ref-ans1="ans1Ref"]]

var board = JXG.JSXGraph.initBoard(divid,{
   boundingbox:[-5,17,5,-17],
   axis:true,
   showCopyright:false
});

var a = board.create('slider',[[0.5,-12],[3.5,-12],[-4,-1,4]],{
   name:'a',
   snapWidth:0.1
});

var b = board.create('slider',[[0.5,-14],[3.5,-14],[-4,4,4]],{
   name:'b',
   snapWidth:0.1
});

stack_jxg.bind_list_of(ans1Ref, [a,b]);

var f = function(x){
   return (x-a.Value())*(x-b.Value());
}

var graph = board.create('functiongraph', [f],{
   strokeColor:'green',
   strokeWidth:3
});

[[/jsxgraph]]

<p style="display:none">[[input:ans1]] [[validation:ans1]]</p>]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Parabel mit Nullstellen (Schieberegler)“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/

ta: [1,-1];</text>
    </questionvariables>
    <specificfeedback format="html">
      <text>[[feedback:prt1]]</text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>ta</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>0</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>AlgEquiv</answertest>
        <sans>ans1[1]</sans>
        <tans>-ans1[2]</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8381488  -->
  <question type="stack">
    <name>
      <text>Punkte und Integral</text>
    </name>
    <questiontext format="moodle_auto_format">
      <text><![CDATA[<p>In der folgenden Grafik sehen Sie drei Punkte \(P_1(x_1|y_1),P_2(x_2|y_2)\) und \(P_3(x_3|y_3)\) und den Graph einer Funktion \(f\colon \mathbb{R}\to\mathbb{R}\).</p>
<p>Verschieben Sie die drei roten Punkte so, dass \(\int_{x_1}^{x_2}f(x)\,dx + \int_{x_2}^{x_3}f(x)\,dx < 0\) gilt.</p>

[[jsxgraph input-ref-ans1="ans1ref"]]
JXG.Options.text.useMathJax = true;
const board = JXG.JSXGraph.initBoard(divid, {
  axis: true,
  boundingbox: [-5,5,5,-5],
  showCopyright: false,
  showNavigation: false,
  pan: { enabled: false },
  zoom: { enabled: false },
});

const opts = {
  withLabel:true,
  snapToGrid:true,
  snapSizeX:0.1
};

function make_names(){
  let tmp = points.sort((p1,p2)=>p1.X()-p2.X());
  tmp[0].setAttribute({name:"P1"});
  tmp[1].setAttribute({name:"P2"});
  tmp[2].setAttribute({name:"P3"});
};

var points = [
  board.create('glider',[-3,0,board.defaultAxes.x],opts),
  board.create('glider',[1,0,board.defaultAxes.x],opts),
  board.create('glider',[2.5,0,board.defaultAxes.x],opts)
];
make_names();

for(let p of points){
  p.on("drag",(e,i)=>make_names())
};

function f(x){
  return 1/3*(x-points[0].X())*(x-points[1].X())*(x-points[2].X())
};
const graph = board.create('functiongraph',[f]);

var int1 = board.create('integral',[[
  function(){return points[0].X()},
  function(){return points[1].X()}
],graph],{
  withLabel:false,
  highlight:false,
  fillColor:"plum"
});

var int2 = board.create('integral',[[
  function(){return points[1].X()},
  function(){return points[2].X()}
],graph],{
  withLabel:false,
  highlight:false,
  fillColor:"lightgreen"
});

stack_jxg.bind_list_of(ans1ref, points);
[[/jsxgraph]]

<p style="display:none">[[input:ans1]] [[validation:ans1]]</p>

[[feedback:prt1]]]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
Die Aufgabe „Punkte und Integral“, Team E-Learning@Hochschule Ruhr West von Jonas Lache ist lizenziert unter einer CC BY-SA 4.0 International Lizenz (https://creativecommons.org/licenses/by-sa/4.0/).
*/

ta: [[-3,0],[-1,0],[2,0]];</text>
    </questionvariables>
    <specificfeedback format="html">
      <text></text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>ta</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>0</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text>SAns1: map(lambda([x],decimalplaces(x,1)),ans1);
SAns1_x: map(lambda([x],x[1]),SAns1);
f1: 1/3*(x-SAns1_x[1])*(x-SAns1_x[2])*(x-SAns1_x[3]);
int1: int(f1,x,SAns1_x[1],SAns1_x[2]);
int2: int(f1,x,SAns1_x[2],SAns1_x[3]);</text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>GT</answertest>
        <sans>0</sans>
        <tans>int1+int2</tans>
        <testoptions></testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text><![CDATA[<p>Sie haben die Punkte so verschoben, dass \(\int_{x_1}^{x_2}f(x)\,dx \approx {@decimalplaces(int1,2)@}\) sowie \(\int_{x_2}^{x_3}f(x)\,dx \approx {@decimalplaces(int2,2)@}\) gilt. Insgesamt gilt dann \(\int_{x_1}^{x_2}f(x)\,dx + \int_{x_2}^{x_3}f(x)\,dx = {@decimalplaces(int1+int2,2)@} < 0\)</p>]]></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text><![CDATA[<p>Sie haben die Punkte so verschoben, dass \(\int_{x_1}^{x_2}f(x)\,dx \approx {@decimalplaces(int1,2)@}\) sowie \(\int_{x_2}^{x_3}f(x)\,dx \approx {@decimalplaces(int2,2)@}\) gilt. Insgesamt gilt dann \(\int_{x_1}^{x_2}f(x)\,dx + \int_{x_2}^{x_3}f(x)\,dx = {@decimalplaces(int1+int2,2)@} \ge 0\)</p>]]></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

<!-- question: 8243660  -->
  <question type="stack">
    <name>
      <text>Sinusfunktion mit Schieberegler</text>
    </name>
    <questiontext format="moodle_auto_format">
      <text><![CDATA[<p>Verändern Sie den Schieberegler auf einen Wert, sodass die angezeigte Funktion genau für alle Zahlen \(x\in\mathbb{Z}\) eine Nullstelle hat.</p>

[[jsxgraph input-ref-ans1="ans1Ref"]]
const board = JXG.JSXGraph.initBoard(divid,{
   boundingbox:[-5,5,5,-5],
   axis:true,
   showCopyright:false
});

var slider = board.create('slider',[[1,-4],[4,-4],[1,1,4]]);

stack_jxg.bind_slider(ans1Ref,slider);

var f = function(x){
    return Math.sin(slider.Value()*x);
};

var graph = board.create('functiongraph',[f]);

var text = board.create('text',[1,4,
   ()=>"Der Wert des Sliders ist "+JXG._round10(slider.Value(),-2)
]);

[[/jsxgraph]]

<p style="display:none">[[input:ans1]] [[validation:ans1]]</p>]]></text>
    </questiontext>
    <generalfeedback format="moodle_auto_format">
      <text></text>
    </generalfeedback>
    <defaultgrade>1.0000000</defaultgrade>
    <penalty>0.1000000</penalty>
    <hidden>0</hidden>
    <idnumber></idnumber>
    <stackversion>
      <text>2024012900</text>
    </stackversion>
    <questionvariables>
      <text>/*
  === Hinweis zur Lizenz: ===
  Diese Aufgabe steht unter der CC BY-SA 4.0-Lizenz. Der Name der Urheber:innen
  soll bei einer Weiterverwendung wie folgt genannt werden: Jonas Lache,
  Hochschule Ruhr West.
*/</text>
    </questionvariables>
    <specificfeedback format="html">
      <text>[[feedback:prt1]]</text>
    </specificfeedback>
    <questionnote format="moodle_auto_format">
      <text></text>
    </questionnote>
    <questiondescription format="html">
      <text></text>
    </questiondescription>
    <questionsimplify>1</questionsimplify>
    <assumepositive>0</assumepositive>
    <assumereal>0</assumereal>
    <prtcorrect format="html">
      <text>Richtige Antwort, gut gemacht!</text>
    </prtcorrect>
    <prtpartiallycorrect format="html">
      <text>Ihre Antwort ist teilweise korrekt.</text>
    </prtpartiallycorrect>
    <prtincorrect format="html">
      <text>Falsche Antwort.</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>
    <variantsselectionseed></variantsselectionseed>
    <input>
      <name>ans1</name>
      <type>algebraic</type>
      <tans>pi</tans>
      <boxsize>15</boxsize>
      <strictsyntax>1</strictsyntax>
      <insertstars>0</insertstars>
      <syntaxhint></syntaxhint>
      <syntaxattribute>0</syntaxattribute>
      <forbidwords></forbidwords>
      <allowwords></allowwords>
      <forbidfloat>0</forbidfloat>
      <requirelowestterms>0</requirelowestterms>
      <checkanswertype>0</checkanswertype>
      <mustverify>0</mustverify>
      <showvalidation>0</showvalidation>
      <options></options>
    </input>
    <prt>
      <name>prt1</name>
      <value>1.0000000</value>
      <autosimplify>1</autosimplify>
      <feedbackstyle>1</feedbackstyle>
      <feedbackvariables>
        <text></text>
      </feedbackvariables>
      <node>
        <name>0</name>
        <description></description>
        <answertest>NumAbsolute</answertest>
        <sans>ans1</sans>
        <tans>pi</tans>
        <testoptions>0.02</testoptions>
        <quiet>0</quiet>
        <truescoremode>=</truescoremode>
        <truescore>1</truescore>
        <truepenalty></truepenalty>
        <truenextnode>-1</truenextnode>
        <trueanswernote>prt1-1-T</trueanswernote>
        <truefeedback format="html">
          <text></text>
        </truefeedback>
        <falsescoremode>=</falsescoremode>
        <falsescore>0</falsescore>
        <falsepenalty></falsepenalty>
        <falsenextnode>-1</falsenextnode>
        <falseanswernote>prt1-1-F</falseanswernote>
        <falsefeedback format="html">
          <text></text>
        </falsefeedback>
      </node>
    </prt>
  </question>

</quiz>