Text FormattingEquation Alignment at equal Signs

Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
Post Reply
chrisr34000
Posts: 10
Joined: Mon Aug 15, 2011 9:40 pm

Equation Alignment at equal Signs

Post by chrisr34000 »

Hi!

I want to align equations by equal signs.

I'm having this code for instance

Code: Select all

\begin{align*}

$\psi(u,\ 1)\ =\ P(R_{1}>u)$


$=\ P(Z_{1}>u)$


$=\ P(e^{\nu Z_{1}}>e^{\nu u})$
\end{align*}
This produces:
current.png
current.png (3.31 KiB) Viewed 3125 times
I want the end result to be:
wanted.png
wanted.png (3.63 KiB) Viewed 3125 times
How can I achieve this?
Last edited by chrisr34000 on Tue Aug 23, 2011 8:14 pm, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Stefan Kottwitz
Site Admin
Posts: 10335
Joined: Mon Mar 10, 2008 9:44 pm

Equation Alignment at equal Signs

Post by Stefan Kottwitz »

Hi,

use align* this way, marking alignment points by &:

Code: Select all

\begin{align*}
  \psi(u,\ 1) &= P(R_{1}>u) \\
  &=\ P(Z_{1} > u) \\
  &=\ P(e^{\nu Z_{1}} > e^{\nu u})
\end{align*}
Stefan
LaTeX.org admin
chrisr34000
Posts: 10
Joined: Mon Aug 15, 2011 9:40 pm

Re: Equation Alignment at equal Signs

Post by chrisr34000 »

Worked great, thanks!
Post Reply