GeneralEquations and columns with correct spacing

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
reed
Posts: 1
Joined: Wed Sep 10, 2008 10:32 pm

Equations and columns with correct spacing

Post by reed »

Hi,

I'm trying make a system of equations look like this:

Code: Select all

a				= 	 b
1	+	2	 =     3
where a and 1 are in one column, b and 3 in one, as well as the equal signs.

I tried the built-in commands as well as amsmath and I'm open to any solution.

(1)

Code: Select all

\begin{align*}
a=b \tag{1} \\
1+2=3
\end{align*}
(2)

Code: Select all

\begin{align*}
&a&=&b \tag{2} \\
&1+2&=&3
\end{align*}
Image

(1) is what I start with (without tabs), but why isn't (2) looking the way it should be (like described in the first code box)?

Recommended reading 2024:

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

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

User avatar
Stefan Kottwitz
Site Admin
Posts: 10360
Joined: Mon Mar 10, 2008 9:44 pm

Equations and columns with correct spacing

Post by Stefan Kottwitz »

Hi,

you could use the alignat environment instead:

Code: Select all

\begin{alignat*}{2}
a&&&=b \tag{2} \\
1&&+2&=3
\end{alignat*}
Stefan
LaTeX.org admin
Post Reply