\documentclass,
\begin{document}, \end{document}) and adds
things. First to add is a paragraph or so around the actual point
where the problem occurs. (It may prove difficult to find the actual
line that’s provoking the problem. If the original problem is an
error, reviewing
“the structure of TeX errors”
may help.)
Note that there are things that can go wrong in one part of the
document as a result of something in another part: the commonest is
problems in the table of contents (from something in a section title,
or whatever), or the list of <something> (from something in a
\caption). In such a case, include the section title or caption
(the caption probably needs the figure or
table environment around it, but it doesn’t need
the figure or table itself).
If this file you’ve built up shows the problem already, then you’re done.
Otherwise, try adding packages; the optimum is a file with only one
package in it, but you may find that the guilty package won’t even load
properly unless another package has been loaded. (Another common case
is that package A only fails when package B has been
loaded.)
Hacking down starts
with your entire document, and
removes bits until the file no longer fails (and then of course
restores the last thing removed). Don’t forget to hack out any
unnecessary packages, but mostly, the difficulty is choosing what to
hack out of the body of the document; this is the mirror of the
problem above, in the “building up” route.
If you’ve added a package (or more than one), add \listfiles to
the preamble too: that way, LaTeX will produce a list of the
packages you’ve used and their version numbers. This information may
be useful evidence for people trying to help you.
The process of ‘building up’, and to some extent that of ‘hacking
down’, can be helped by stuff available on CTAN:
This answer last edited: 2013-01-09
Go to previous question, or next question
Go to FAQ home.
URL for this question: http://www.tex.ac.uk/cgi-bin/texfaq2html?label=minxampl
Comments, suggestions, or error reports? - see “how to improve the FAQ”.
This is FAQ version 3.27, released on 2013-06-07.