While writing a thesis, there are statements like Corollary.5, Theorem.23, etc. I refer these and sometimes, I am adding some extra statements between these referred ones so that the Corollary.5 becomes Corollary.6. How to avoid these kind of problems?
\begin{theorem}...\end{theorem}
and similar environments to typeset theorems and the like. These environments can be set up to perform the numbering automatically. Then it is just a matter of setting a\label
and referencing it later with\ref
. See en.wikibooks.org/wiki/LaTeX/Labels_and_Cross-referencing and en.wikibooks.org/wiki/LaTeX/Theorems (there are various packages for theorem labelling, butamsthm
is one of the popular ones). There are fancy crossref packages such ascleveref
that can automate this further.