# TeX Distribution and Engine

While reading about LaTeX in wikibooks, I stumbled across the terms TeX engine and distribution. One earlier post said the TeX engines are Knuth's TeX, e-TeX, pdfTeX, XeTeX, LuaTeX. And read that TeXLive is a distribution. Could someone explain these terms?

-

TeX started as a single, self-contained program (called TeX, naturally) written by Knuth. That program still exists, but a lot of infrastructure has grown up around it: first, its "environment" has been expanded a lot; and second, the program itself has been modified to various ends.

The expanded environment largely centers around LaTeX, which is a "format" allowing a particular style of TeX programming designed to make it easier to consider the appearance of a document separately from its contents. One of its features is that it supports the inclusion of additional packages extending its capabilities, and these number in the thousands on ctan.org now. These packages make up the majority of a TeX "distribution"; they can be installed at your discretion and sometimes on-demand, depending on the distro (MikTeX does that, for example). Well, them and the huge pile of fonts that TeX needs to make your document have anything in it at all.

The environment also includes a lot of utilities, such as dvipdf(m)(x) (this one has had several incarnations), which converts DVI files, the default output format of the original TeX, into PDF files. These are also part of a TeX distribution.

TeX has also been expanded by being redesigned, producing new "engines": eTeX adds some programming capabilities; XeTeX (as I understand it) is designed to work much better with non-English languages and modern fonts; pdfTeX outputs PDF files directly and supports a lot of stuff that is only possible in them (everyone gives the microtype package as an example, since it was the original motivation; it makes nearly invisible but very attractive changes to the layout of the lines of text); LuaTeX is the next generation of pdfTeX and goes much farther beyond eTeX in providing the programming capabilities of a modern programming language.

So in short: a TeX engine is a program and turns your file into a nice document, and a TeX distribution is the setup that lets it all work.

-
So what engines are used by Texlive? –  tex Jun 29 '11 at 13:28
@user3984: TeXLive provides lots of engines but doesn't have a default; that choice is for the user. However, it is often the case (at least in Linux distributions that install TeX) that the commands called "tex" and "latex" actually run "pdftex" and "pdflatex". If you use an IDE (an editor that understands the compilation process), it will have a default, and that default is probably going to be pdflatex now. –  Ryan Reich Jun 29 '11 at 13:39

TeX is the machine and nearly useless without one of the applications like

(plain)tex
latex
pdftex
pdflatex
xetex
xelatex
luatex
lualatex


You can compare it with the C compiler which is also nearly useless without the additional bibliographies. Knuth himself created the macro package plainTeX to make the basic functions of TeX more useful.

A distribution provides the environment of all these engines: configuration, packages, fonts, additional programs like bibex, biber, makeindex, ...

-