Questions tagged [theorems]
{theorems} are environments which are commonly numbered. They are extensively used in math texts. Examples of such environments are theorems, corollaries, lemmas, propositions, remarks and definitions. Popular packages are {amsthm}, {ntheorem}, and {thmtools}. Covers discussion on proofs too.
1,669
questions
2
votes
1
answer
31
views
Number a theorem with subsection-number. thm-number, without chapter number
I wish to number theorem in a report with x.y if the theorem is the y-th number in section x (of some chapter), without chapter number.
In other words, I want the theorem be numbered like \newtheorem{...
0
votes
2
answers
51
views
How to get 1.1 Definition of X
\documentclass[12pt]{article}
\usepackage[T1]{fontenc}
\usepackage[left=2.50cm, right=2.54cm, top=2.54cm, bottom=2.54cm]{geometry}
\usepackage{amsthm}
\usepackage{xpatch}%To add . to Def with ...
1
vote
1
answer
16
views
Change reference style to include title
\documentclass[a4paper]{scrartcl}
\usepackage{amsthm}
\usepackage[pdftex,svgnames,hyperref]{xcolor}
\usepackage{thmtools}
\usepackage{hyperref}
\newtheorem{defi}{Definition}[subsection]
\newtheorem{...
0
votes
0
answers
17
views
How to make the font of theorem number independent of the theorem head font
When using amsthm with the elsarticle class, font of the number after theorem head depends on its font. Here is an example:
\documentclass{elsarticle}
\usepackage{amsthm}
\theoremstyle{remark}
\...
0
votes
1
answer
31
views
Get Name of Theorem Environment From Label
I'm trying to create a command, say envName, with the following behaviour (where theorem and lemma are AMS Theorem environments):
\begin{theorem}\label{myThm}
Lorem ipsum...
\end{theorem}
\begin{...
0
votes
1
answer
49
views
How to get the colour box with theorem title
I try to do the following style of my theorem in latex:
But in my code:
\documentclass[a4paper, 14pt, extrafontsizes, oneside, openany, x11names]{article}
\usepackage{amsmath, amsthm, amssymb, ...
0
votes
0
answers
38
views
Move title box to the right side of tcbtheorem
I have the following document but would like the title ('c' is a placeholder) to be on the right hand side of the tcbtheorem only (NOT also next to the Example 1.2:). I'd also like the c on the right ...
0
votes
0
answers
28
views
Printing counter options [duplicate]
I want to use \Alph{mycounter} to have my theorems labelled by capital roman letters and a short search led me to conclude that all I need to write is
\newcounter{mycounter}
\Alph{mycounter}
\...
0
votes
1
answer
40
views
Restatable theorem with difference in line breaks
I have a theorem written using restatable. However, in one part of the text I am using a two-column format requiring a linebreak in the theorem. When I restate the theorem in the single column part I ...
1
vote
1
answer
72
views
ntheorem with thmmarks causes strange vertical spacing with amsmath equation*
I experience a strange spacing before \begin{equation*} when using amsmath and ntheorem with the thmmarks option. It is associated with using leqno and fleqn together as general setting.
How do I fix ...
0
votes
0
answers
33
views
Theorem environment to start on the same line as itemize symbol [duplicate]
In my document, I want to have an itemize environment. Within this environment I want to give a definition (which was previously defined). Consider the following MWE:
\documentclass[a4paper]{scrartcl}
...
0
votes
1
answer
40
views
Missing { inserted. \end{align*}
I have checked the other questions related to this topic, however I haven't gotten any smarter in my case. The error still seems to appear even though I've tried around to get it to work.
I have this ...
5
votes
2
answers
414
views
How to add a "qed square" at the end of a definition?
I'm using the acmart documentclass for a conference paper submission. I've provided a simple example (code below) which currently renders to the following output:
Questions:
How can I change the &...
2
votes
1
answer
83
views
Too much space between the math expression and the symbol at the end of a statment of theorem, remark etc
I've added a diamond symbol to the end of my theorem (and other) environments:
However, when I use any display math at the end of the theorem, the diamond gets set too low:
Is there some way to get ...
4
votes
2
answers
170
views
Remove the dot after a specific theorem environment
The following code can remove the trailing dot from all theorem environments.
\makeatletter
\xpatchcmd{\@thm}{\thm@headpunct{.}}{\thm@headpunct{}}{}{}
\makeatother
See Remove dot after theorem with ...
0
votes
0
answers
46
views
Weird numbering system for theorems, definitions, propositions, etc
I am using many packages in my .tex file, I believe it is because of the abntex2 package that I am using for compliance with Brazilian ABNT standards that this problem is ocurring, not that as far as ...
3
votes
1
answer
104
views
\newcommand with tcolorbox, with 3 arguments
I want to use many examples that I had already written them in several files looking like
\begin{ejemplo}
{\label{ex:0xx}}
{Pregunta}
{Respuesta}
\end{ejemplo}
with tcolorbox to obtain the ...
2
votes
2
answers
55
views
Definition content first characters skipping to numbering box
I have the following issue of first sentence characters skipping to numbering box :
Like the O in Defintion 1.6.2
The text start with : " On appelle " which explains the origin of displayed ...
3
votes
2
answers
74
views
Appropriate parenthesizing of theorem title
Is there a way to ensure that we may use \label{key}[Theoremtitle] while avoiding getting "[Theoremtitle]" and instead getting "(Theoremtitle)" - as with [Theoremtitle]\label{key} ...
4
votes
1
answer
36
views
I cannot \pause in Beamer after defining a \newtheorem
I am using a new command to give theorems the name that I want in Beamer, but it won't let me use \pause. The following code works without the \pause, but this error with \pause:
! LaTeX Error: ...
0
votes
1
answer
50
views
Correct way to remove spaces when adding hooks to environment
Please see addendum before reading the question. I have not deleted or made major edits to it so as not to invalidate @cfr's answer.
I'm trying to add some hooks to a theorem environment, and I ...
1
vote
2
answers
53
views
Framing theorem and proof together
What I want to do
I'm trying to frame a theorem and its proof like this:
How I currently do it
The image above was produced by the code below:
\documentclass[a4paper, 12pt]{article}
\usepackage[...
0
votes
1
answer
28
views
Setting up a paired counter for exercise / solution theorems [closed]
I am trying to use two theorem environments, one for exercises and another for their solutions. The counter for the solution should be the same as the counter for the associated exercise.
An example:
...
2
votes
3
answers
143
views
Count theorems like Theorem part.chapter.number
I'm using the scrreprt documentclass, which provides parts and chapters. While I found solutions to enumerate theorems like Theorem chapter.section.number, I did not manage to obtain Theorem part....
0
votes
0
answers
36
views
Theorem styles not working in Frontiers journal template
I am trying this template:
https://www.overleaf.com/latex/templates/template-for-frontiers-journal/myxxkvjwqhrv
Which package should be added so that Theorem will start in bold and the qed symbol will ...
0
votes
1
answer
19
views
Theorem numbering after redefining sections
I counter this problem when I try to establish a simple
template for my numerical report.
The demo codes are below:
\documentclass{article}
\usepackage{titlesec}
\renewcommand{\thesection}{\Roman{...
1
vote
0
answers
60
views
\autoref{claim} broken LNCS template
Please help \autoref{claim} gives weird references in LNCS template
% This is samplepaper.tex, a sample chapter demonstrating the
% LLNCS macro package for Springer Computer Science proceedings;
...
0
votes
1
answer
36
views
Label multiply defined warning but I only have one label LNCS template
Not a huge deal but I'm getting a strange warning Label `PolyApx' multiply defined. even though I only have one label in my entire document.
\documentclass[runningheads]{llncs}
\usepackage{hyperref}...
0
votes
1
answer
65
views
Environment prop undefined and also already defined LNCS template
Trying to put my paper into LNCS format and I'm having a weird error if I comment out the line \newtheorem{prop}[theorem]{Proposition} it tells me prop is undefined but if I uncomment the line it ...
4
votes
1
answer
231
views
LNCS proceedings template Command \proof already defined
Trying to put my paper into LNCS format and I don't know what the source of the error here is
\documentclass[runningheads]{llncs}
\usepackage{amsmath,amsthm,amssymb}
\usepackage[algosection,ruled,...
2
votes
1
answer
30
views
Counter of corollary updated both after theorems and lemmas
I have the following definitions:
\newtheorem{theorem}{Theorem}
\newtheorem{lemma}{Lemma}
Now I want to define corollaries so that their counter is updated both after theorems and lemmas in the ...
0
votes
0
answers
21
views
Change mytheorem-environment style
In my code I create mytheorem-environment, but I'd like to improve and edit mytheorem so that the output of
\begin{mytheorem}{Pitagora}{Pitagora}
Statement of Pitagorean Theorem, \ldots
\end{mytheorem}...
2
votes
1
answer
58
views
Removing Unnecessary Space from Equations within Custom Environments in thmtools
I'm facing an issue while writing my thesis. Whenever a theorem ends with an equation, an additional line is added. I have to use thmtools, and I'm unsure whether I should remove this space from the ...
0
votes
0
answers
43
views
The name of my Theorem is not bold when I use default amsthm package settings [duplicate]
here is what I have done. I am only doing this minimal example just to make sure that I have not done any customization to override the default setting. However, in the output I get the name of the ...
1
vote
1
answer
38
views
\begin{note} in beamer does not work
Here is a sample code. In frame 1, we used \begin{note} . \end{note} command. I expect to see a block like theorem environment. I am using XeLaTeX Engine.
\documentclass[aspectratio=1610]{beamer} % ...
1
vote
2
answers
43
views
Redefining theorem breaks nameref
I'd like to define a command \keyifythm{<envname>} which redefines an amsthm theorem environment to take a key-value optional argument. My approach below works, but for reasons I don't ...
1
vote
1
answer
78
views
How do we get Theorem environments without dot after the number?
The standard Theorem environments under amsthm has Theorem n. How can we have simply Theorem n and so no punctuation after n?
2
votes
2
answers
59
views
Long url doesn’t break in theorem optional argument (under amsthm, hyperref, xurl)
In most situations, the xurl package (presented here) ensures that long urls break across lines appropriately. However, inside the optional “caption” argument of a theorem, long urls stay unbroken, as ...
1
vote
3
answers
56
views
Expansion in stored csname of restatable theorem
Thinking about this question, I'd like to use thmtools' restatable environment to store theorems with a number in the csname. That way one can loop through them at the end of the document to restate ...
2
votes
1
answer
125
views
Restate all theorems & definitions?
I am new to this community, and unfamiliar with advanced latex use (e.g. creating packages, custom build scripts, post-processing scripts) so I apologize if my question seems unusual or overly simple.
...
0
votes
1
answer
45
views
Alternative numbering for AMS "Theorem" environment
I am currently writing a LyX document using the extended AMS package. My document consists of theorems of two types. So far, I used the standard Theorem environment (the one with numbering) for the ...
2
votes
0
answers
26
views
How to restate some theorems in the preface of a thesis? [duplicate]
In a PhD thesis we have to write a preface wherein some significant theorems from the main body of the thesis are needed to be restated. The amstools or thm-restate package does not help me in this ...
0
votes
1
answer
58
views
Different numeration for Theorems
\documentclass{article}
%\documentclass[16pt]{report}
\usepackage[a4paper,text={16.5cm,25.2cm},centering]{geometry}
\usepackage[utf8]{inputenc}
\usepackage{amsfonts}
\usepackage{hyperref}
\usepackage{...
0
votes
1
answer
24
views
Error using bracket argument of \cite within theorem titles
This error shows up only in Overleaf (plain online version), so either my local editor (TeXstudio) does not report it, or it is related to the editor. I have a fix to share if anyone encounters the ...
1
vote
2
answers
288
views
Good practice with \DeclareKeys
I'm trying to make a "one-off" theorem environment for theorems with custom names that shouldn't be numbered at all. The goal is to copy the behavior of thmtools
\declaretheorem[thmbox=M]{...
1
vote
2
answers
60
views
Why are my theorems not numbered by letters?
I'm trying to enumerate the main theorems from my paper using letters instead of numbers. I've tried using the following code but it's not working (at least the counter is!)
\documentclass[11pt]{...
1
vote
2
answers
42
views
How to use a variable in a thmnote
I'd like to have the "theorem name" of a theorem be populated using a variable. It isn't working as I had hoped, see below. I'm especially confused because I can successfully get the "...
1
vote
1
answer
43
views
Force indenting at beginning of theorem environment
When I do my math homework, I use a theorem environment with custom theorem style via the amsthm package to enumerate my problems. I would like the first paragraph inside the theorem environment to be ...
1
vote
1
answer
65
views
No indent inside tcb theorem
How would I disable the indents inside my theorem and example boxes which are made by tcbtheorem? Any help would be greatly appreciated.
\documentclass{book}
\RequirePackage[dvipsnames]{xcolor}
\...
1
vote
1
answer
95
views
\newtcbtheorem Automatically put Theorem Title in the Index
I had frozen my LaTex in April, 2020, since I always seemed to be in the middle of projects. With a bit of a break, I just updated my setup, installing Tex Live 2023.
So far, I have only found one ...