Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Hypothesis 1A and 1B

2,115 views
Skip to first unread message

rbu...@hbs.edu

unread,
Feb 28, 2012, 4:30:57 PM2/28/12
to
I'm curious to know how to alter the hypothesis numbering in LaTeX to
present a multi-part hypothesis as Hypothesis 1A, and Hypothesis 1B.
Right now, I'm using the following syntax:

\begin{hypothesis}
This is the first part of my hypothesis.
\end{hypothesis}

\begin{hypothesis}
This is the second part of my hypothesis.
\end{hypothesis}

This strategy is resulting in something that looks like this when I
typeset it:

HYPOTHESIS 1. This is the first part of my hypothesis.
HYPOTHESIS 2. This is the second part of my hypothesis.

However, I'd really like something that looks like this:

HYPOTHESIS 1A. This is the first part of my hypothesis.
HYPOTHESIS 1B. This is the second part of my hypothesis.

Do you have any suggestions? Thanks very much for your help!

Ryan

Lars Madsen

unread,
Feb 28, 2012, 4:37:40 PM2/28/12
to
Assuming you are using theorems

\newtheorem{hypothesis}{Hypothesis}

This also create the counter hypothesis, thus

\renewcommand\thehypothesis{1\Alph{hypothesis}}

Should do the trick

(bit anoying if you have many of them...)



--
/daleif

DK-TUG president
memoir and mh bundle maintainer

rbu...@hbs.edu

unread,
Mar 21, 2012, 10:42:44 PM3/21/12
to
Thanks! This is great! One quick follow-up. If I have Hypothesis 1
followed by Hypotheses 2A and 2B, how do I make 2A and 2B not come out
as 2B and 2 C? Right now, I have the following:

\begin{hypothesis}
\label{Hypothesis 1}
This is one thing I think is true.
\end{hypothesis}

\renewcommand\thehypothesis{2\Alph{hypothesis}}

\begin{hypothesis}\label{Hypothesis 2A}
This is the first part of the second thing I think is true, and;
\end{hypothesis}

\begin{hypothesis}\label{Hypothesis 2B}
This is the second part of the second thing.
\end{hypothesis}

When I typeset this though, the hypotheses come out numbered: H1, H2B,
H2C. Any suggestions? I'm sure there's a simple command to add a break
between the hypotheses, so that H2 has parts A and B.

Thanks again!

Ryan

rzu...@gmail.com

unread,
Nov 21, 2012, 7:58:43 AM11/21/12
to
The answer here helped me solve a similar problem, so I'm posting a bit of code I prepared to take care of similar situations. If you put it in your preamble, you can use \subhyp and \normhyp before and after your multi-part hypothesis:

\newtheorem{hyp}{Hypothesis}

\newcommand{\subhyp}{
\newcounter{subhyp}
\renewcommand\thehyp{\protect\stepcounter{subhyp}%
\arabic{hyp}\alph{subhyp}\protect\addtocounter{hyp}{-1}}
}

\newcommand{\normhyp}{
\renewcommand\thehyp{\arabic{hyp}}
\stepcounter{hyp}
}

Ro'i

rzu...@gmail.com

unread,
Nov 21, 2012, 8:34:15 AM11/21/12
to
I now realized that the code fails when more than one multi-part hypothesis is needed. Here's a corrected code:

\newtheorem{hyp}{Hypothesis}

\newcounter{subhyp}
\newcommand{\subhyp}{
\setcounter{subhyp}{0}
\renewcommand\thehyp{\protect\stepcounter{subhyp}%
\arabic{hyp}\alph{subhyp}\protect\addtocounter{hyp}{-1}}
}

\newcommand{\normhyp}{
\renewcommand\thehyp{\arabic{hyp}}
\stepcounter{hyp}
}

0 new messages