Benutzer:Colkalich/mein Tafelwerk

Aus ProgrammingWiki

Wiki-Quelltext dieser Seite.

<language>Javascript</language>
=Formeln=
<ul>
==Mathematik==
===Flächeninhalt eines Würfels===
<math> \cdot a_b_c </math>
===Satz des Pythagoras===
<math>c^2=a^2+b^2</math>
=== Bruchrechnung ===

<code id="58de1517ad8a4" hidden>
function ggT(m, n) {
 if (n == 0)
  return m;
 else
  return ggT(n, m % n);
} 
</code>

==== Addition ====

Rechenregel:

<blockquote><math>\frac{z_1}{n_1}+\frac{z_2}{n_2}=\frac{z_1 \cdot n_2 + z_2 \cdot n_1}{n_1 \cdot n_2}</math></blockquote>

Berechnung:
<code id="58de1517ad90e">
function Addition(z1, n1, z2, n2) {
 var z = z1 * n2 + z2 * n1;
 var n = n1 * n2;
 return (z + "/" + n);
}
</code>
<run id="58de1517ad980">
Addition(1, 2, 1, 3);
</run>

==Physik==
<li>
=== Geschwindigkeit ===
<math>v=\frac{s}{t}</math>
</li>
====Beispiel====
Eingabe des Weges in <math>km</math>; Eingabe der Zeit in <math>h</math>
<code id="58d4e5d03186b">
function Geschwindigkeit(s, t){
var v = s/t;
return v;
return Math.round(1000 * v) / 1000;
}
</code>
Ausgabe der Durschnittsgeschwindigkeit in <math>\frac {km}{h}</math>
<run id="58d4e5d0318dd">
Geschwindigkeit(22, 0.833)
</run>

===Dichte===
<math>\rho=\frac{m}{V}</math>

====Beispiel====
Eingabe der Masse in <math>g</math>; Eingabe des Volumens in <math>cm^3</math>:
<code id="58de07327b4ea">
function Dichte(m, V) {
 var rho = m / V;
 return Math.round(1000 * rho) / 1000;
}
</code>
Ausgabe der Dichte in <math>\frac{g}{cm^3}</math>:
<run id="58de07327b5b3">
Dichte(63, 8.0)
</run>
</li>
</ul>

<ul>