Math & ScienceVertical Spacing between equations

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
Post Reply
bpetersen
Posts: 11
Joined: Mon Sep 13, 2010 9:55 pm

Vertical Spacing between equations

Post by bpetersen »

I am using AMSmath package. When I have code like:

Code: Select all

Code, edit and compile here:
\begin{align*}
y = & \frac{1}{x}\\
x = & 2z\\
z = & 10
\end{align*}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
It gives the y equation a little bit more vertical space then the x and z equation. How do I get all of the equations to have the same amount of vertical space?

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

paul
Posts: 49
Joined: Thu Apr 08, 2010 5:56 am

Vertical Spacing between equations

Post by paul »

bpetersen wrote:I am using AMSmath package. When I have code like:

Code: Select all

Code, edit and compile here:
\begin{align*}
y = & \frac{1}{x}\\
x = & 2z\\
z = & 10
\end{align*}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
It gives the y equation a little bit more vertical space then the x and z equation. How do I get all of the equations to have the same amount of vertical space?
Either smash the height of the "\frac" (in which case it may overlap the other lines) or add something like "\vphantom{\frac{1}{x}}" to the other lines, to force the height.

You should also put the "&" before the "=", BTW.
Post Reply