What good math typesetting in a PDF actually requires
Most "Markdown to PDF" tools pass math to a browser, take whatever the browser draws, and print it. The result is readable but not typeset: superscripts sit too high, fraction bars are a pixel too thick on one line and invisible on the next, and a matrix in a sentence pushes the lines above and below apart. This page explains the four things MDtoDOCX does differently for math and why each one matters on paper. If you want the list of supported LaTeX commands and the overall pipeline, that lives on Markdown to PDF with LaTeX; this page is about spacing, baselines, fonts and print quality.
Spacing follows TeX's atom classes, not the font's advance widths
TeX does not put a fixed gap between symbols. It classifies each symbol as an ordinary atom, a binary operator, a relation, an opening or closing delimiter, punctuation or an inner formula, and then looks up the gap for each pair of classes in a table: a thin space (3 mu) between an ordinary atom and a large operator, a medium space (4 mu) around binary operators like + and −, a thick space (5 mu) around relations like = and ≤, and no space at all between an ordinary atom and its subscript. One mu is one eighteenth of an em, so the gaps scale with the font size. MDtoDOCX implements this table, which is why a+b=c comes out with the visibly wider gap around the equals sign that you see in any physics textbook, and why f(x) has no gap before the parenthesis. In script style, inside a superscript or the numerator of an inline fraction, the medium and thick spaces are dropped, again exactly as TeX does, so x^{n+1} stays compact.
Baselines: the math axis, fractions and inline height
Every math font defines an axis height, the vertical position of the minus sign and the fraction bar, roughly a quarter of the x-height above the baseline. MDtoDOCX centres fraction bars, matrix brackets, stretched parentheses and binary operators on that axis, so a fraction next to an equals sign lines up with it instead of floating. Inline fractions use TeX's text-style shifts: the numerator moves up by a smaller amount than in display style and the digits are set at 70 % size, so $\frac{1}{2}$ inside a sentence adds at most 2 pt of extra height and the paragraph keeps an even leading. Display equations use the full shifts, full-size numerators and a 12 pt gap above and below. Subscripts drop to a fixed depth and superscripts rise to a fixed height that depends on whether the base is cramped, which is how x_i^2 and x^2_i both put the 2 and the i at the same positions and prevent them from colliding when the base is a tall bracket.
Matrices and delimiters that stretch correctly
A bmatrix is laid out as a table with a 1 em column gap and rows aligned on their baselines, then wrapped in square brackets built from the font's extensible glyph pieces rather than scaled from a single bracket. Scaling a normal bracket makes its strokes thicker; assembling one from the top, extender and bottom pieces keeps the stroke weight identical to the surrounding text. The same assembly applies to \left( … \right), braces in cases and the radical sign in \sqrt, whose overline is drawn at the font's rule thickness and extends over the whole radicand. Matrices are never split across a page; a display equation that does not fit at the bottom of a page moves whole to the next one.
Font embedding: OpenType MATH tables and subsetting
Correct math layout depends on metrics that only a true math font carries: the axis height, the sub- and superscript shifts, the fraction rule thickness, the sizes of extensible pieces. These live in the OpenType MATH table. MDtoDOCX ships Latin Modern Math by default and lets you pick STIX Two Math for a Times-like look or Cambria Math to match a Calibri body; all three are real math fonts with a MATH table. The chosen font is subset to the glyphs the document uses and embedded in the PDF, so a problem set with a hundred equations adds around 70 KB and renders identically on every viewer and printer. No system font substitution ever happens, which is the usual cause of integral signs turning into boxes on a colleague's machine.
Print clarity: hairlines, small sizes and high resolution
Math has more thin strokes than prose: fraction bars, the overline of a root, the arrows of vectors, second-level superscripts at 50 % size. All of these are emitted as vector paths, never as bitmaps, so a laser printer at 600 or 1200 dpi renders them at its full resolution. Rules are drawn at the font's specified thickness, 0.4 pt for Latin Modern, and MDtoDOCX enforces a floor of 0.3 pt so that a fraction bar in a second-level subscript does not disappear when printed. Glyphs remain selectable and searchable text, so a reader can copy ψ₀(x) out of the PDF as Unicode.
Free preview, Pro download
Typesetting runs in your browser and the preview is free, including every spacing and baseline rule described above. Downloading a PDF with typeset math is a Pro feature; on the free tier the math is exported as its LaTeX source in a monospace span, so nothing is lost. The same expressions become native Word equations on Markdown to Word with math. For plans see Pricing; the 7-Day Pass at $4.9 covers a single deadline.