User:Rossolson/Math

From DPWiki
Jump to navigation Jump to search

How to handle math-heavy texts

The Perfect Format

Easy to author without extensive knowledge of specialized tooling, easy to publish and maintain using simple pipelines with fewest manual steps, clear and simple accessibility for end users.

The Proposed Baseline

(as of the moment, June 2025)

The Laura Method: Math is put into the HTML as an SVG with data-tex attribute, the tag having been expressed via RP21's m2svg tool. (It is not determined yet if the SVG is inline or external.)

Possible source formats

Rank Base Authored in A11Y Via Errata Steps Example Notes
1 HTML data-tex + SVG alt attributes Edit HTML, LaTeX, and generate SVG via m2svg Example with < 20 images, external Example with >1000 svgs, inline. SVGs are either manually edited or regenerated.
2 HTML Direct MathML Browser reading of MathML? Edit MathML Example Needed Accessibility review needed
3 HTML MathJax (MathML) Aria ignore+alt content Editing of (unpublishable) source + rendering Example Needs pipeline built {*}
4 HTML MathJax (CSS) Aria ignore+alt content Editing of (unpublishable) source + rendering Example Needs pipeline built {*}
5 LaTeX LaTeX ??? Direct editing + PDF generation Example Incompatible with HTML-focused PG maintenance tools; Pipeline could be built c.f. arXiv / Pandoc
6 HTML HTML with simple CSS aria-ignore + long desc? Direct editing only Example e.g. Code Excerpt Limited to simplistic uses?
7 HTML HTML with inline SVG images alt attribute Direct editing only Example Errata friction
8 HTML HTML with MathJax-generated SVG images Aria ignore/alt content Editing of (unpublishable) source + rendering Example Errata nightmare if not generated from source MathJax file.
9 PDF LaTeX ??? Poor support Direct editing only Example Errata nightmare if not generated from source .tex file.

{*} Needs a MathJax processing pipeline created for publishing script-free HTML. Source file could use inline LaTeX or MathML.

Necessary output formats

  • HTML5 with MathML
  • HTML5 with inline SVGs
  • HTML with inline PNGs
  • Plain Text
  • EPUB3 (“X”HTML5 + MathML)
  • EPUB2 (XHTML + inline PNG)
  • PDF

Toolchains

  • Ebookmaker
    • Current version (Jan 2025)
    • Enhancement at later date?
  • Pandoc
  • LaTeX with various output engines

Evaluation Criteria (in order of priority)

  1. Accessibility
    • Elevate and maintain the variety of people that can access the original text.
    • Support for low-vision, multiple screen sizes, text-to-speech.
  2. Maintainability
    • The ability to edit and update books after publishing.
  3. Compatibility
    • Support desktop, mobile, and ebook platforms.
  4. Fidelity
    • Accuracy of reproducing the original work
  5. Longevity and Migratibility
    • Predicted longevity based on the age of the format.
      • "When there are no other evidence, assume that the thing is half way through its lifespan."
    • The ability of the work to be migrated to future formats.
      • (Formats made for long-life rather than for a specific purpose.)

Example Works

 ‹p›Therefore, ‹span class="int"›∫‹/span›‹span class="integral"›‹sup›√‹span class="sqrt3"›1 ‹i›a‹/i›‹sup›2‹/sup›‹/span›‹/sup›(‹i›x − a‹/i›) ‹i›dy‹/i›‹sub›0‹/sub›‹/span›

Research and Discussions