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

I'd like to be able to write a LaTex document with numbered theorems and equations, but I would like not to have them numbered automatically, but rather put in by hand. Ideally, I'd like to be able to write something like

The number $\pi$ is rational.

As a consequence,
e^{\pi i} = -1.003+0.014 i.

and so produce "Theorem 3.1416", and an equation numbered "(2.718)".

(I can create a new theorem type for each numbered theorem (\newtheorem{thm-3.1416}...), but I've got a lot of them. I can handcraft a "thm-handnumbered" command, but it looks ugly...)

share|improve this question
Why would you want to do this? – Seamus Sep 6 '10 at 9:44
It's useful for refereeing papers, where one wants to quote a few equations with the original numbering. – Chris Johnson Sep 7 '10 at 7:57
It's also useful for students like me. I use a theorem environment for typing up exercises in my homework, and so I need the flexibility to manually fill in the appropriate exercise numbers. – bcat May 11 '11 at 2:53
up vote 14 down vote accepted

And here's a solution for hand-numbered theorems.




Some text.

share|improve this answer
Looks good, thank you! (Took a few minutes to get thmtools installed correctly ... after you run "latex thmtools.ins", you need copy all the *.sty files into the texmf tree, not just the ones it tells you to copy ...) – Charles Rezk Sep 5 '10 at 20:54
Thanks for accepting my answer - but don't forget that frabjous provided the solution for equations. (There's this button for useful answers.) – lockstep Sep 5 '10 at 21:03
I don't see a useful answer button ... or do you mean upvoting? (I don't have rep to do that yet.) – Charles Rezk Sep 5 '10 at 21:15
Yes, I meant upvoting. I forgot its reputation requirement. – lockstep Sep 5 '10 at 21:22

For the second one, you could use \tag from the amsmath package:

e^{\pi i} = -1.003+0.014 i.

For the first, I'd use ntheorem with a no-number style and then use the optional name:


And in the body:

     This result is interesting.

See the ntheorem documentation for more info.

share|improve this answer
Good point! That'll handle equations. So what about theorems? – Charles Rezk Sep 5 '10 at 20:28
I added to the answer later; but lockstep's answer may be better. Haven't tried it. – frabjous Sep 5 '10 at 20:30
The main difference to your answer is that I avoid braces around the "manual" number. – lockstep Sep 5 '10 at 20:35

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.