New answers tagged

4

As already suggested by @barbarabeeton, you could use an aligned environment inside an equation environment. An additional suggestion: To obtain a bit more horizontal separation between the two groups of three equations, insert \qquad\qquad right before the middle & alignment marker in the first row. \documentclass{article} \usepackage{amsmath} % for '...


2

Maybe something of this kind, but the brace and the main equation number are unnecessary, in my opinion. \documentclass{article} \usepackage{amsmath} \usepackage{hyperref} \usepackage{lipsum} % for mock text \begin{document} \lipsum[2] \begin{subequations}\label{main} \begin{equation} \left. \addtocounter{equation}{-1} \edef\theHparentequation{x.\...


0

The following redefinition of \thethm should meet your requirements. If you want definitions to be numbered in a similar way, and if you have defined for example \newtheorem{definition}{Definition}, then a similar redefinition of \thedefinition should work. \documentclass{book} \usepackage{amsmath,amsthm} \newtheorem{thm}{Theorem} \renewcommand{\thethm}{% ...


1

Except for itemize not being numbered, everything worked fine. No packages needed. \documentclass{article} \makeatletter \@addtoreset{equation}{enumi} \makeatother \renewcommand{\theequation}{\theenumi.\arabic{equation}} \begin{document} \begin{enumerate} \item test \begin{equation} x=a \end{equation} \begin{equation} x=b \end{equation} \item test \begin{...


4

You can use the \numberwithin command from amsmath to number the equation counter within the enumi counter, which is the counter from the items in the enumerate environment. For example, \documentclass{article} \usepackage{amsmath} \usepackage{enumitem} \numberwithin{equation}{enumi} \begin{document} \begin{enumerate}[label={\bfseries\arabic*.}, ref=\arabic*...


1

You only need the command \includegraphics to insert figures. The figure environment will only count the number of "figures" if there is a \caption inside it. The following example shows the concept and some variations you might use. \documentclass{article} \usepackage{graphicx} \usepackage{float} \begin{document} \includegraphics[width=0.2\linewidth]{...


0

The solution is so easy. Just the wiley-article.cls remove from [theorem] from the line \newtheorem{definition}[theorem]{Definition}


-1

Place \renewcommand\theequation{\arabic{equation}} just before your equation. Example: \renewcommand\theequation{\arabic{equation}} \begin{equation} \label{eqn:eq1} X = 1+5 \end{equation}


1

You can redefine \paragraphformat and \subparagraphformat to remove \autodot and insert ): \renewcommand*\paragraphformat{\theparagraph)\enskip} \renewcommand*\subparagraphformat{\thesubparagraph)\enskip} To change the TOC entries you can use \RedeclareSectionCommands[ tocentrynumberformat=\numendsymbol{)} ]{paragraph,subparagraph} \newcommand*{\...


2

To build a numbered tcolorbox you should use a \newtcbolorbox command instead of a \newenvironment. This way you can use a counter within every tcolorbox. Take a look at section "5 Initialization Option Keys" in tcolorbox documentation. Here you have an example with mybox: \documentclass{article} \usepackage[most]{tcolorbox} \newtcolorbox[auto counter, ...


1

The command \chaptername from the titlesec package can be used for that. As an example, the third chapter is produced with the following code. \documentclass{book} \usepackage{titlesec} \renewcommand{\chaptername}{Story} \begin{document} \chapter{} \chapter{} \chapter{Case Study} \end{document}


4

You could just redefine the lemma counter. \documentclass{svjour3} \counterwithin{lemma}{theorem} \begin{document} \begin{theorem} A theorem \end{theorem} \begin{lemma} A lemma \end{lemma} \begin{lemma} Another lemma \end{lemma} \begin{theorem} A theorem \end{theorem} \begin{lemma} A lemma \end{lemma} \begin{lemma} Another lemma \end{lemma} \end{...


3

Ok, if your class doesn't alter amsart too much, you can easily create what you want by redefining \sectionname. If the space between § and the number isn't wanted use \renewcommand*\sectionname{§\ignorespaces} instead. \documentclass[]{amsart} \usepackage{duckuments} \renewcommand*\sectionname{§} \begin{document} \tableofcontents \duckument \end{...


1

This answer really belongs to @Bernard. The chapter number can be added to the output theorem counter without forcing the chapter number to appear as part of the section number by this redefinition: \renewcommand{\thetheorem}{\thechapter.\thesection.\arabic{theorem}}


0

It seems that the package soul \usepackage{soul} and more precisely the command \hl{} was generating an error (somehow) and messing with the chapter numbering in the table of content. Removing the \hl{} where it was employed solved it!


0

I think you are looking for the keyword 'part' (instead of 'section'), which already gives you the wanted renumbering for chapters. In the end you do not need any more modifications (try code below ... mostly a copy of this answer) \documentclass{book} \makeatletter \@addtoreset{chapter}{part} \makeatother \renewcommand*\thechapter{\ifnum\value{chapter}&...


1

Here's a solution using amsthm's environments, but defining other environments from them to adjust the counters when problems and answers are called. \documentclass{article} \usepackage{amsmath,amsthm} \theoremstyle{definition} \newtheorem{prob}{Problem} \newtheorem{ans}{Answer} \numberwithin{prob}{section} \numberwithin{ans}{section} \newenvironment{...


1

You can define two generic environments and assign manually the numbers. \documentclass{article} \usepackage{amsthm} \newtheorem*{innerthm}{\innerthmname} \newcommand{\innerthmname}{}% initialize \newenvironment{statement}[1] {\renewcommand{\innerthmname}{#1}\innerthm} {\endinnerthm} \theoremstyle{definition} \newtheorem*{innerdfn}{\innerthmname} \...


Top 50 recent answers are included