Math & Science ⇒ Equation Number centered with Equation
Equation Number centered with Equation
My University doesn't offer a template for thesis in laTeX, so I'm writing code in LaTeX to create my own. I've used a template by another guy, based on book.cls, and modified it according my University rules. But I run into this problem, which I was unable to solve:
The rules specify that the equations should be centered and the equation number will come immediately at the end of equation (so, would be centered with the equation). I'm using the amsmath package, which only offers the options of putting the equation number on the right or on the left of the page, is there any hack I can make at my class to make my template according to the rules, or another package similar to amsmath that has that option?
Learn LaTeX easily with newest books:
The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis
The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more
LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis
- Stefan Kottwitz
- Site Admin
- Posts: 10359
- Joined: Mon Mar 10, 2008 9:44 pm
Equation Number centered with Equation
in amsmath, the code for placing tags is very extensive. A quick way regarding align environments would be:
Code: Select all
\def\place@tag{\quad\boxz@}
Code: Select all
\documentclass{article}
\usepackage{amsmath}
\makeatletter
\def\place@tag{\quad\boxz@}
\makeatother
\let\equation\align
\let\endequation\endalign
\begin{document}
\begin{equation}
e^{i\pi} + 1 = 0
\end{equation}
\begin{align}
e = \lim_{n\to\infty} \left( 1 + \frac{1}{n} \right)^n
\end{align}
\end{document}