View Single Post
Old 03-01-2022, 09:49 AM   #46
salamanderjuice
Guru
salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.salamanderjuice ought to be getting tired of karma fortunes by now.
 
Posts: 933
Karma: 13014268
Join Date: Jul 2017
Device: Boox Nova 2
Quote:
Originally Posted by Turtle91 View Post
I’ve only played with MathML a little bit…

How does it compare to the equivalent svg- as in file size???
Considerably smaller. Let's use the Taylor series expansion as an example.

In LaTeX this can be written as:
Code:
f(x)=\sum_{k=0}^\infty f^{(k)}(a)\frac{(x-a)^k}{k!}
This is 51 characters total. The MathML version is a little more verbose at 867 characters:
Code:
<math display="block" xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><mi>f</mi><mrow><mo stretchy="true" form="prefix">(</mo><mi>x</mi><mo stretchy="true" form="postfix">)</mo></mrow><mo>=</mo><munderover><mo>∑</mo><mrow><mi>k</mi><mo>=</mo><mn>0</mn></mrow><mo accent="false">∞</mo></munderover><msup><mi>f</mi><mrow><mo stretchy="true" form="prefix">(</mo><mi>k</mi><mo stretchy="true" form="postfix">)</mo></mrow></msup><mrow><mo stretchy="true" form="prefix">(</mo><mi>a</mi><mo stretchy="true" form="postfix">)</mo></mrow><mfrac><msup><mrow><mo stretchy="true" form="prefix">(</mo><mi>x</mi><mo>−</mo><mi>a</mi><mo stretchy="true" form="postfix">)</mo></mrow><mi>k</mi></msup><mrow><mi>k</mi><mi>!</mi></mrow></mfrac></mrow><annotation encoding="application/x-tex">f(x)=\sum_{k=0}^\infty f^{(k)}(a)\frac{(x-a)^k}{k!}</annotation></semantics></math><
But it's trying to be unambiguous. The SVG version is 28621 characters which I'm not going to put here.

Assuming 1 character is 1 byte which isn't quite accurate the LaTeX version 0.05KB, the MathML version is 0.85KB and the SVG version is 27.95KB. And the PNG version I made that's tolerable is 1.3KB.
salamanderjuice is offline   Reply With Quote