Posts

Showing posts with the label latex

Latex memo

Image
Numbering equations in align environment In align environment, all equations are numbered by default, use \nonumber to make equation on the same line not numbered. Example: Code: \documentclass{article} \usepackage{amsmath} \begin{document} \begin{align} \frac{w^* +\delta V_u^1}{r + \delta} &= V_u^{0} \nonumber \\ w^* &= r V_u^1 - \frac{b(r + \delta)}{1 + r} \end{align} \end{document} Result: In align* environment, all equations are not numbered by default, how about we want to make one equation numbered? Is there any analog of \nonumber? From Ian Thompson at https://tex.stackexchange.com/questions/42726/align-but-show-one-equation-number-at-the-end , we can add the following command before the document begins: \newcommand\numberthis{\addtocounter{equation}{1}\tag{\theequation}} % From Ian Thompson at https://tex.stackexchange.com/questions/42726/align-but-show-one-equation-number-at-the-end Then, we can use \numberthis to make equation on the same line numbered in ...