maeyler / Sunumlar

Presentations
https://maeyler.github.io/Sunumlar/
0 stars 1 forks source link

Rendering math formulas #1

Open maeyler opened 1 year ago

maeyler commented 1 year ago

Which one is better? LaTex or MML?

maeyler commented 1 year ago

Try this page: https://maeyler.github.io/Sunumlar/math/sample

See the codes using the context menu LaTeX is clearly the winner:

x = {-b \pm \sqrt{b^2-4ac} \over 2a} versus

<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
  <mi>x</mi>
  <mo>=</mo>
  <mrow data-mjx-texclass="ORD">
    <mfrac>
      <mrow>
        <mo>&#x2212;</mo>
        <mi>b</mi>
        <mo>&#xB1;</mo>
        <msqrt>
          <msup>
            <mi>b</mi>
            <mn>2</mn>
          </msup>
          <mo>&#x2212;</mo>
          <mn>4</mn>
          <mi>a</mi>
          <mi>c</mi>
        </msqrt>
      </mrow>
      <mrow>
        <mn>2</mn>
        <mi>a</mi>
      </mrow>
    </mfrac>
  </mrow>
</math>
maeyler commented 1 year ago

Comparison of LaTeX vs ordinary text

Yani $21^2+22^2+23^2+\textbf{24}^2 = 25^2+26^2+27^2$ olmalı. Neredeyse hiç aritmetik yapmadan cevabı bulduk!

Verilen $n$ değeri için genelleştirelim: $(x-n)^2+...+(x-1)^2+x^2 = (x+1)^2+...+(x+n)^2$ olsun. Kareli ve sabit terimleri sadeleştirince, $x^2 = 4(1+...+n)x$ ve buradan $x = 2n(n+1)$ bulunur.

image