How can I set "Theorem" on the left of content and "number" under "Theorem"?

How can I set "Theorem" on the left of content and "number" under "Theorem"?
I want to set "Theorem" on the left of the content and its "Numbering"(1.4.6 in the image) under it in stead of default putting these things within the content, so that readers could recognise the "Theorem" and "numbering" more easily.

Does anybody know how to achieve this? just like the image uploaded.

Please show me the Tex code about this. Thank you very much!


Here's one attempt at producing the desired output. The main tool used is thmtools together with amsthm. For most of the configuration options you can see the thmtools manual.

\usepackage{amsmath, amssymb, amsthm}

    notebraces={}{. },%
    headformat={\llap{\smash{\parbox[t]{1.3in}{\centering \NAME\\ \NUMBER}}}\NOTE}%
%hack to kill some extra space
\renewcommand\[email protected]{}

\declaretheorem[style=marginheads, numberwithin=section, title=Definition]{defn}
\declaretheorem[style=marginheads, sibling=defn, title=Theorem]{them}

First let us write a paragraph of something or another. 

\begin{defn}[Vector spaces over $\mathbb{R}$]
    A set $S$ equipped with operations addition $+: S\times S\to S$ and scalar multiplication $\cdot: \mathbb{R}\times S \to S$ satisfying the following list of 10 axioms
        \item Something
        \item \ldots
        \item Let's quit

Now we can state a theorem. Just to show it off.

    Suppose that $a$ and $b$ are the lengths of the legs of a right triangle, and $c$ is the length of the hypotenuse, then it is known that $a^2 + b^2 = c^2$.



How can I set "Theorem" on the left of content and "number" under "Theorem"?


The main lifting is done in the setting of the headformat key, which creates a parbox with a certain width (1.3in here) and places the theorem heading and number on two lines, centered. \smash is used to make it take effectively 0 vertical space in the layout (so that the second line of the theorem will not be pushed down). \llap lets the box protrude into the margin.

I had to \renewcommand\[email protected]{} since the code for \NOTE in \thmtools prepends the theorem name with \[email protected] to give a space between the heading and the name. But in our case our heading is set elsewhere and the space creates an unintentional indent if the optional name is given. Similarly postheadspace is set to be zero, and the space needed to separate the name of the theorem from the theorem text is appended in notebraces.

In the above demonstration both named and unnamed theorems are shown.

Category: horizontal alignment Time: 2016-07-28 Views: 1

Related post

iOS development

Android development

Python development

JAVA development

Development language

PHP development

Ruby development


Front-end development


development tools

Open Platform

Javascript development

.NET development

cloud computing


Copyright (C), All Rights Reserved.

processed in 0.132 (s). 12 q(s)