24 votes
Accepted

New theorem environment with manual theorem number

Quite easy! ;-) 1 \documentclass{article} \usepackage{amsthm} \newtheorem{manualtheoreminner}{Theorem} \newenvironment{manualtheorem}[1]{% \renewcommand\themanualtheoreminner{#1}% \...
egreg's user avatar
  • 1.1m
8 votes
Accepted

Creating a nice-looking box without using minipage

With tcolorbox and its tcbtheorems is not too difficult. \documentclass{article} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{amsmath,amssymb,amsthm} \usepackage[margin=1cm]{...
Ignasi's user avatar
  • 136k
7 votes
Accepted

How to center in the definition context?

The answer depends importantly on what the centering operation is supposed to span. Do you want to center "A is B" on the remainder part of the line (i.e., after subtracting the space taken ...
Mico's user avatar
  • 496k
6 votes

Creating a nice-looking box without using minipage

Here's a starter with tcolorbox. I do not have your section and subsection styles, so this is with default styles. Please note that the tcolorbox manual is no quick read, it requires some patience. ...
TeXnician's user avatar
  • 33.4k
6 votes

Creating a nice-looking box without using minipage

Quick and dirty implementation of your box without any packages: \documentclass[]{article} \usepackage{duckuments} \newsavebox\customboxbox \newlength\customboxOuterWidth \newlength\...
Skillmon's user avatar
  • 57.8k
6 votes

Need to create an unnumbered 'conclusion' environment

How to create unnumbered theorem-like environments depends strongly on whether your documents loads the amsthm or the ntheorem package (or neither). If you work with the amsthm package, use the \...
Mico's user avatar
  • 496k
6 votes
Accepted

How to make "Theorem 1.1" into "1.1 Theorem"?

The \swapnumbers command in the amsthm package is designed for exactly this task: \documentclass{report} \usepackage[T1]{fontenc} \usepackage{amsthm} \swapnumbers \newtheorem{theorem}{Theorem}[...
hair-splitter's user avatar
6 votes
Accepted

Referring to two or many corollaries in LateX

Just don't use theoremref and rely on cleveref. \documentclass{book} %\usepackage[utf8]{inputenc} \usepackage{amsmath} \usepackage{amsthm} %\usepackage{theoremref} %\usepackage{amsfonts} \usepackage{...
egreg's user avatar
  • 1.1m
5 votes
Accepted

QED symbol after statements without proof

First let me show an example where \null\hfill\qedsymbol doesn't do the right thing. Note that adding \null\hfill\qedsymbol explicitly is the same as doing it with \AtEndEnvironment, with the only ...
egreg's user avatar
  • 1.1m
5 votes
Accepted

Adding Overhang to Theorems

The following code puts both the section number and the labels of theorem environments in the margin by putting them in right-aligned boxes of zero width (and zero depth). \documentclass{article} \...
Circumscribe's user avatar
  • 10.8k
5 votes
Accepted

Writing a theorem inside a theorem

Here's an implementation using enumitem. \documentclass{article} \usepackage{amsmath} \usepackage{amsthm} \usepackage{enumitem} \usepackage{lipsum} \newtheorem{theorem}{Theorem}[section] \...
egreg's user avatar
  • 1.1m
5 votes
Accepted

Theorem and definition name in margin

You can define indirectly the theorem environment: \documentclass{article} \usepackage{amsthm,marginnote,xparse} \newtheorem{theoreminner}{Theorem} \NewDocumentEnvironment{theorem}{o} {\...
egreg's user avatar
  • 1.1m
5 votes
Accepted

Remove numbering from Proofs

Here's a possibility: \documentclass[12pt]{article} \usepackage{hyperref} \usepackage{cleveref} \usepackage{ntheorem} \newtheorem{thm}{Theorem} \newtheorem{lemma}[thm]{Lemma} \newtheorem{...
José Carlos Santos's user avatar
5 votes

Need to create an unnumbered 'conclusion' environment

Mico's answer is quite nice if what you want is a theorem-like environnent. But for a thesis, a conclusion can be an unnumbered section (or subsection, depending of the text), imho. So that I would do ...
Denis's user avatar
  • 5,247
5 votes

How to write a Theorem in 2 different sections with the same numbering?

With this setup, you will state the theorems you want to be repeated in the introduction, without worrying about their number. The theorem body needs to be typed in just once. Of course, you don't ...
egreg's user avatar
  • 1.1m
5 votes
Accepted

How can I achieve this theorem style (a very common one)?

Here's a solution that employs the machinery of the amsthm package to create a new theorem style called (why not?) descrates. \documentclass{article} \usepackage[T1]{fontenc} \setlength\textwidth{...
Mico's user avatar
  • 496k
5 votes

AUTOREF error [italian] with \todonotes

I suggest you load the amsthm, hyperref, and (new) cleveref packages -- in this order -- and only then execute the \theoremstyle and \newtheorem directives. Next, in the body of the document, I'd like ...
Mico's user avatar
  • 496k
5 votes
Accepted

Numbering equations with same counter as theorem environment

You want that theorem and proposition share the equation counter. \documentclass{amsart} \numberwithin{equation}{section} \newtheorem{theorem}[equation]{Theorem} \newtheorem{proposition}[equation]{...
egreg's user avatar
  • 1.1m
5 votes

How to center in the definition context?

If you really want to hinder readability, you can either center in the available space (definition 2) or center absolutely (definition 3). The package zref and \centerref are only needed if you choose ...
egreg's user avatar
  • 1.1m
4 votes
Accepted

\newtheorem with qed-symbol

I suggest to have a theo environment and a theo* environment for theorems which don't need a proof. Using the tombstone for all theorem statements doesn't seem a good idea, because theorem statements, ...
egreg's user avatar
  • 1.1m
4 votes
Accepted

Define new theorem style in beamer

The green color is defined in example text template. Change it to what you want: \documentclass{beamer} \makeatletter \def\th@claim{% \normalfont % body font \setbeamercolor{block title example}{bg=...
Ignasi's user avatar
  • 136k
4 votes

New theorem environment with manual theorem number

First of all, you can't define a theorem-like environment newtheorem as there is alredy the \newtheorem macro that defines those environments simply due to the name clash. Assume we have an ...
Ruben's user avatar
  • 13.4k
4 votes
Accepted

Problem with definition/examples and theorem numbering

You want that the environments share the theo counter: \theoremstyle{definition} \newtheorem{definizione}[theo]{Definizione} \newtheorem{esempio}[theo]{Esempio} \newtheorem{algoritmo}[theo]{Algoritmo}...
egreg's user avatar
  • 1.1m
4 votes
Accepted

Vertical space between theorems from a distant figure

The issue is that \begin{theo} and\end{theo}emit\addvspace{\topsep}`. If you have \end{theo}\begin{theo}, the two \addvspace commands merge the vertical spaces leaving just one. This doesn't happen ...
egreg's user avatar
  • 1.1m
4 votes

Environment formatting: how to display the name of an axiom instead of its counter number

You can do it with amsthm (better than ntheorem, in my opinion). \documentclass[a4paper]{article} \usepackage{amsmath} \usepackage{amsthm} \usepackage{xparse} \usepackage{hyperref} \usepackage{...
egreg's user avatar
  • 1.1m
4 votes
Accepted

How to write to the right of "Definition" and also enumerate within the definition?

The following should be close to what your desired output looks like: \documentclass{article} \usepackage{amsthm} \theoremstyle{definition} \newtheorem{defn}{Definition} \usepackage{enumitem} \begin{...
leandriis's user avatar
  • 62.4k
4 votes

Remove numbering from Proofs

The amsthm package already defines proof environment, so here I call the new proof environment Proof, and the * is for a no-number theorem environment. If you want more custom, you can read texdoc ...
Syvshc's user avatar
  • 1,328
4 votes
Accepted

How to write a Theorem in 2 different sections with the same numbering?

You can create a custom theorem mythm that's manually numbered the way you want. \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{amssymb,amsmath,amsthm} \usepackage[runin]{abstract} \...
AboAmmar's user avatar
  • 46.2k

Only top scored, non community-wiki answers of a minimum length are eligible