I am trying to change the equation number style in classicthesis package. I followed the answers given in here but it does not affect the equation style. I want to include the chapter number in the equation number. Could someone help me?
Asked
Active
Viewed 3.0k times
12
shashashamti2008
- 5,380
2 Answers
18
You could load the amsmath package and use its \numberwithin command to achieve your objective:

\documentclass{report}
\usepackage{classicthesis}
\usepackage{amsmath}
\numberwithin{equation}{chapter}
\begin{document}
\chapter{First chapter}
\begin{equation} \label{eq:pyth}
a^2+b^2=c^2
\end{equation}
Here's a cross-reference to equation \eqref{eq:pyth}.
\end{document}
Addendum: If you want to have the equation numbers look like (1--1) rather than like (1.1), the \theequation macro needs to modified as well:

\documentclass{report}
\usepackage{classicthesis}
\usepackage{amsmath}
\numberwithin{equation}{chapter}
\renewcommand{\theequation}{\thechapter--\arabic{equation}}
\begin{document}
\setcounter{chapter}{2}
\chapter{Third chapter}
\begin{equation} \label{eq:albert}
E=mc^2
\end{equation}
Here's a cross-reference to equation \eqref{eq:albert}.
\end{document}
Mico
- 506,678
-
1
-
1Isn't
\renewcommand{\theequation}{\thechapter--\arabic{equation}}after\numberwithin{equation}{chapter}simpler than redefining\numberwithin? – egreg Apr 04 '13 at 22:28 -
-
If you are using the LyX version, it is enough to add the
\numberwithincommand in theDocument>Settings>LaTeX Preamblemenu path – georgebrindeiro Feb 21 '14 at 20:36
0
add “floatperchapter” at the option of \documentclass[]{}
Lei
- 11
-
Welcome to TeX.SE. Please be a bit more specific as to whether your proposed method works for arbitrary document classes or only specific ones. – Mico Jul 07 '15 at 09:43
-
2Welcome to TeX.SX! This doesn't affect the equations though, does it? – Torbjørn T. Jul 07 '15 at 09:43
-
2@Mico I guess it should rather be an option to
classicthesis, it is listed in the manual at least. – Torbjørn T. Jul 07 '15 at 09:44
\renewcommand\theequation{\thechapter.\arabic{equation}}– David Carlisle Apr 04 '13 at 21:43\makeatletter \renewcommand{\theequation}{\thechapter.\arabic{equation}} \@addtoreset{equation}{chapter} \makeatother– Gonzalo Medina Apr 04 '13 at 21:44\usepackage{classicthesis}in the fileclassicthesis-config.tex. With this in mind, changing the style works just great. – shashashamti2008 Apr 04 '13 at 22:01