# Numbering assumptions in amsthm by hand and referencing them

I have a situation where there are two alternative assumptions that can hold in order for some estimate to be correct. I would like to number them 2.a and 2.b and refer to them in the text (an assumption 1 already exists). So far I do the following, which gives assumption numbers 2 and 3:

\documentclass[11pt,a4paper]{article}
\usepackage{amsmath,amsfonts,amssymb,amsthm}

\theoremstyle{plain}
\newtheorem{assumption}{Assumption}

\begin{document}

\begin{assumption}[Comparability]\label{as:comparability} Individuals with the same $x_{it}$ vector are \textit{comparable} over time.\end{assumption}

\begin{assumption}[Comparability in differences; replacing Assumption \ref{as:comparability}]\label{as:comparabilityDiff} Differences between individuals $i$ and $j$ with the vectors $x_{it}$ and $x_{jt}$ are \textit{comparable} over time.\end{assumption}

What Assumption \ref{as:comparabilityDiff} implies economically can best be explained using an example…


Is there a way to do this in with the amsthm package? I have seen this post (link), but don’t know how to reference the theorem in this case.

• Welcome to TeX.SX! See the package chngcntr and the \numberwithin command. – user31729 Sep 13 '15 at 17:17
• – egreg Sep 13 '15 at 19:10

Something like this? Not the best solution, I assume, I'll try to improve it later on.

\documentclass[11pt,a4paper]{article}
\usepackage{amsmath,amsfonts,amssymb,amsthm}

\usepackage{chngcntr}

\theoremstyle{plain}
\newtheorem{assumption}{Assumption}

\let\origtheassumption\theassumption

\begin{document}

\begin{assumption}[Comparability]\label{as:comparability} Individuals with the same $x_{it}$ vector are \textit{comparable} over time.\end{assumption}

\edef\oldassumption{\the\numexpr\value{assumption}+1}

\setcounter{assumption}{0}
\renewcommand{\theassumption}{\oldassumption.\alph{assumption}}
\begin{assumption}[Comparability in differences; replacing Assumption \ref{as:comparability}]\label{as:comparabilityDiff}
Differences between individuals $i$ and $j$ with the vectors $x_{it}$ and $x_{jt}$ are \textit{comparable} over time.
\end{assumption}

\begin{assumption}[Comparability in differences; replacing Assumption \ref{as:comparability}]\label{as:comparabilityDiffother}
Differences between individuals $i$ and $j$ with the vectors $x_{it}$ and $x_{jt}$ are \textit{comparable} over time.
\end{assumption}

\let\theassumption\origtheassumption

What Assumption \ref{as:comparabilityDiff} implies economically can best be explained using an example… and \ref{as:comparabilityDiffother}

\begin{assumption}{Foo}
bar
\end{assumption}

\end{document}


• Great, this does the trick. Thanks very much! – Mike Sep 13 '15 at 20:05
• This only works specifically when you're trying to use this for assumption 2- since you reset the assumption counter, the next assumption gets labelled 3. Easy fix is to use another counter to hold over the original assumption numbering. – A Simmons Sep 6 '16 at 10:30