TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What do \m@ne‎ and \@M do in the definition of \@makechapterhead in book class?
I took a quick look at latex.ltx and couldn't find any explanation.

share|improve this question
\m@ne is the constant -1, while \@M stands for 10000. – egreg Dec 26 '11 at 23:18
up vote 10 down vote accepted

\m@ne stands for minus one, i.e. is a count register with a fixed value of -1, which is used for efficiency reasons over a literal -1.

\@M is defined using \mathchardef and equal to \mathchar"2710, i.e. 10000, and is used for the same reasons like above.

See the question \@ne \tw@ \thr@@ for more details on the reasons. See also Documentation reference for LaTeX internal commands? for a list of further similar macros. I also can recommend you latexdef (or texdef -t latex) to test for the definitions of such macros, e.g. latexdef m@ne @M will give you the definition and numerical values of these two macros.

share|improve this answer
Why doesn't one use the same -1 instead of \m@ne? Isn't \m@ne confusing? – Vahid Damanafshan Dec 26 '11 at 23:27
It's used mainly for efficience (one token instead of two), but also because it avoids possible premature expansion of tokens after it. – egreg Dec 26 '11 at 23:29

The file latex.ltx is the correct one.

At line 316 you find \m@ne:

\countdef\m@ne=22 \m@ne=-1

At line 300 you find \@M:

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.