Applets:Periodendauer periodischer Signale: Unterschied zwischen den Versionen

Aus LNTwww
Wechseln zu:Navigation, Suche
Zeile 1: Zeile 1:
 +
<p>
 +
{{BlaueBox|TEXT=
 +
<B style="font-size:18px">Funktion:</B>
 +
$$x(t) = A_1\cdot cos\Big(2\pi f_1\cdot t- \frac{2\pi}{360}\cdot \phi_1\Big)+A_2\cdot cos\Big(2\pi f_2\cdot t- \frac{2\pi}{360}\cdot \phi_2\Big)$$
 +
}}
 +
</p>
  
 
<html>
 
<html>
Zeile 25: Zeile 31:
 
</head>
 
</head>
  
<body>
+
<body onload="drawNow()">
 
+
<!-- Resetbutton, Checkbox und Formel -->
 +
<p>
 +
    <input type="checkbox" id="gridbox" onclick="showgrid();" checked> <label for="gridbox">Gitterlinien Zeigen</label>
 +
    <button class="button" onclick="drawNow();">Reset</button>
 +
</p>
 
<div id="cnfBoxHtml" class="jxgbox" style="width:600px; height:150px;  float:top; margin:-10px 20px 100px 0px;"></div>
 
<div id="cnfBoxHtml" class="jxgbox" style="width:600px; height:150px;  float:top; margin:-10px 20px 100px 0px;"></div>
 
<div id="pltBoxHtml" class="jxgbox" style="width:600px; height:600px; border:1px solid black; margin:-100px 20px 10px 0px;"></div>
 
<div id="pltBoxHtml" class="jxgbox" style="width:600px; height:600px; border:1px solid black; margin:-100px 20px 10px 0px;"></div>
  
<!-- Ausgabefelder -->
 
 
<table>
 
    <tr>
 
        <td>$x(t)$= <span id="x(t)"></span>  $\quad$ </td>
 
        <td>$x(t+ T_0)$= <span id="x(t+T_0)"></span>  $\quad$ </td>
 
        <td>$x(t+2T_0)$= <span id="x(t+2T_0)"></span>  $\quad$ </td>
 
        <td>$x_{\text{max}}$= <span id="x_max"></span>  $\quad$ </td>
 
        <td style="color:blue;">$T_0$= <span id="T_0"></span>  $\quad$ </td>
 
    </tr>
 
</table>
 
  
  
 
<script type="text/javascript">
 
<script type="text/javascript">
 
+
function drawNow() {
 
         // Grundeinstellungen der beiden Applets
 
         // Grundeinstellungen der beiden Applets
 
         JXG.Options.text.useMathJax = true;
 
         JXG.Options.text.useMathJax = true;
         var cnfBox = JXG.JSXGraph.initBoard('cnfBoxHtml', {
+
         cnfBox = JXG.JSXGraph.initBoard('cnfBoxHtml', {
 
             showCopyright: false, showNavigation: false, axis: false,
 
             showCopyright: false, showNavigation: false, axis: false,
 
             grid: false, zoom: { enabled: false }, pan: { enabled: false },
 
             grid: false, zoom: { enabled: false }, pan: { enabled: false },
 
             boundingbox: [-1, 2.2, 12.4, -2.2]
 
             boundingbox: [-1, 2.2, 12.4, -2.2]
 
         });
 
         });
         var pltBox = JXG.JSXGraph.initBoard('pltBoxHtml', {
+
         pltBox = JXG.JSXGraph.initBoard('pltBoxHtml', {
 
             showCopyright: false, axis: false,
 
             showCopyright: false, axis: false,
 
             zoom: { factorX: 1.1, factorY: 1.1, wheel: true, needshift: true, eps: 0.1 },
 
             zoom: { factorX: 1.1, factorY: 1.1, wheel: true, needshift: true, eps: 0.1 },
 
             grid: false, boundingbox: [-0.5, 2.2, 12.4, -2.2]
 
             grid: false, boundingbox: [-0.5, 2.2, 12.4, -2.2]
 
         });
 
         });
 
+
        cnfBox.addChild(pltBox);
 
+
 
 +
    };
 +
    // Definition der Funktion zum An- und Ausschalten des Koordinatengitters
 +
    function showgrid() {
 +
        if (gridbox.checked) {
 +
            xaxis = pltBox.create('axis', [ [0, 0], [1, 0] ], {});
 +
            yaxis = pltBox.create('axis', [ [0, 0], [0, 1] ], {});
 +
        } else {
 +
            xaxis.removeTicks(xaxis.defaultTicks);
 +
            yaxis.removeTicks(yaxis.defaultTicks);
 +
        }
 +
        pltBox.fullUpdate();
 +
    };
 
</script>
 
</script>
 
</body>
 
</body>

Version vom 18. September 2017, 23:01 Uhr

Funktion: $$x(t) = A_1\cdot cos\Big(2\pi f_1\cdot t- \frac{2\pi}{360}\cdot \phi_1\Big)+A_2\cdot cos\Big(2\pi f_2\cdot t- \frac{2\pi}{360}\cdot \phi_2\Big)$$