{align} is an environment provided by math packages that permits multiple related equations to be aligned at a common reference point, usually a sign of relation. For general questions about aligning document elements, use {horizontal-alignment} or {vertical-alignment} instead.

learn more… | top users | synonyms

7
votes
2answers
3k views

Spacing of \multline inside align (i.e. \multlined)

Related with How can I use multline within an align environment?. Consider this document: \documentclass{minimal} \usepackage{amsmath,mathtools} \begin{document} \begin{align*} & ...
7
votes
4answers
147 views

Multiple alignments within align environment

My minimum working example: \documentclass{report} \usepackage{amsmath} \begin{document} \begin{align} \dot{x}_2 = \dot{x}_{2,0}&+\frac{\partial f_2(x_1)}{\partial x_1} \bigg|_{x_1=x_{1,0}} ...
7
votes
1answer
1k views

Different space between \align and \equation

Why produce the align and the equation environment different space between the text. And what can I do, that it have the same? \documentclass{article} \usepackage{amsmath} \begin{document} Long ...
7
votes
1answer
65 views

How many times is “align” processed?

Consider the following MWE which writes the word "Cat" to a file. \documentclass{article} \usepackage{amsmath} \begin{document} \newwrite\datei \immediate\openout\datei=Beispiel.txt \begin{align*} ...
7
votes
2answers
266 views

Passing an argument with the alignment operator (&) to a macro within another aligned environment

I am trying to write macros for quickly formatting matrices in math mode. Here is a simple, working example: \documentclass{article} \usepackage{amsmath} ...
7
votes
1answer
140 views

Problem with \index in align enviroment

Please compile the following MWE. As you will then see, the typesetting of $\mu^{\otimes\downarrow n}$ in the index is strange! \documentclass{article} \usepackage{amsmath} \usepackage{imakeidx} ...
7
votes
1answer
1k views

How to remove parenthesis in an equation number created by \tag?

This is probably simple, but I can't figure it out. How can I remove the parentheses around a \tag in an align equation? I would like the second line (and only that) to contain [2] instead of ([2]). A ...
7
votes
1answer
87 views

Switching from equation to align changes horizontal width

I am puzzled by why changing from an equation environment to an align environment should change the horizontal width of my equation. Below I provide an example. Sorry, it is not a minimal working ...
7
votes
1answer
91 views

Automatically reference a set of equations in align

Is there a way to automatically refer to a set of equations in an align environment? E.G. I would like this to read "From Eqs.(1-3), we can clearly see..." \documentclass{article} ...
7
votes
1answer
6k views

Tabbing for math mode?

I'm looking for something synonymous to tabbing, but for math mode. I read that alignat* should do the trick, but this behaves differently it seems. For example: \documentclass{article} ...
7
votes
1answer
951 views

How to get width of equation

If I want to know the width of a text I use \settowidth{\MyLength}{bla}. Is there something similar for equations? More specifically I have \begin{align} a & b & c & d\\ c & d ...
7
votes
1answer
126 views

Box some equations inside align

I'm trying to make something like this: But I have just can't figure out how. I have tried with empheq and tikz, but I can't get it to work with only some boxes inside align. I have also tried with ...
7
votes
2answers
702 views

Centering the align environment on the middle column

I have a set of aligned equations that I would like to provide an \implies for down the left hand side. I used this originally: \begin{align} (x-1)^2 &= -1 \\ x-1 &= \pm i \\ ...
7
votes
1answer
720 views

How can I use cross-references and hyperlinks to parts of an align environment?

I'm writing an exercise book, and in some exercises I'll have several numbered equations in an align environment, e.g., (1) x^2+x+1=0, (2) ax^3+2x=0, (3) x^5=2i, (4) x^4=-i, (5) x-1/x=2, (6) ...
6
votes
3answers
212 views

align* not aligning properly with \sqrt

Using this, everything is aligned properly: \documentclass{article} \usepackage{amsmath} \begin{document} \begin{align*} 16x^2&=144&\text{| }&\text{sqrt}\\ 4x&=12&\text{| ...
6
votes
3answers
2k views

alignat makes 3 good alignments and 1 bad

I'm having a problem with the alignat environment. This code: \begin{alignat*}{9} &X_{12}&+X_{13}& & & & & & & &=1 ...
6
votes
3answers
252 views

why does something disappear in the aligned environment?

I noticed a strange behaviour with the aligned environment: \begin{equation}\label{eq:direct_limit} \begin{aligned} [x] + [y] & := [\eta_{ik}(x) + \eta_{jk}(y)],\\ [x] \cdot r & := [x \cdot ...
6
votes
4answers
353 views

How can I note transformation step?

I currently have this: with this code: \begin{align} 0 &\stackrel{!}{=} (d_{P,f}^2)'\\ &= -2 x_p + 2x -2y_p f'(x) + \left (f(x)^2 \right )'\\ ...
6
votes
3answers
358 views

How can I align two split environments at the equal signs?

\documentclass{scrartcl} \usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} \usepackage[english]{babel} \usepackage{amsmath, amsthm, amssymb} \usepackage{mathtools} \begin{document} ...
6
votes
4answers
881 views

Alignment in matrix (bmatrix)

Here is a MWE: \documentclass[12pt,a4paper]{article} \usepackage{amsmath} \begin{document} The reparameterisation is \begin{equation} \label{eqn:linear_ssK3} \begin{matrix} s & = ...
6
votes
4answers
796 views

Aligning of equations within derivations

Okay, so I have the following derivation so far in my latex document: \documentclass[a4paper,oneside,11pt]{report} \usepackage[english]{babel} %francais, polish, spanish, ... ...
6
votes
2answers
17k views

Align multiline equation with expression after equal sign

I am trying to align a multiline equation using array within the equation but it turns out it doesn't do very well. The code I am using is as follows: \begin{equation}\ \begin{array}{lcl} ...
6
votes
2answers
164 views

problem with align

i'm trying to typeset someting like this: \begin{align} f_{**p}(X_p,Y_p) = X_p(Y(f)) = \sum_{i,j = 1} ^n \alpha_i \beta_j E_{pi}(E_j(f)) f \end{align} short remark \begin{align} E_{pi}(E_j(f)) ...
6
votes
2answers
2k views

Highlight an equation within an align environment with color option

I'd really like to do exactly what's being asked for in this question: Highlight an equation within an align environment, but with the ability to change the color when I call it, so that I could have ...
6
votes
6answers
2k views

An enumeration of equations with aligned equal signs

I'd like to have something like the following: \begin{enumerate} \item $1 + 1 = 2$ \item $1 = 2 - 1$ \end{enumerate} The thing is, I'd also like the equals signs to be aligned. But I'd like the ...
6
votes
2answers
212 views

Alignment between material inside and outside a cases environment

In the code below, I'd like to make the i=0,\ldots,n. line up, in the output, with the cases in the first part of the definition. Ideally, the full-stop would align with the semicolons and comma. ...
6
votes
1answer
432 views

How to align a set of my equations?

I just wan't to align the equation like this example (Of course, I can't align these equations on the web page): ∵△ABC ≌ △A′B′C′ ∴∠ABC = ∠A′B′C′ ∠ACB = ∠A′C′B′ ∠BAC = ∠B′A′C′ If I use &, ...
6
votes
4answers
123 views

Align multiple equations with parts inside root

I am having trouble aligning the following inequalities in such a way that, on the right hand side, the first bracketed parts within the cube root are aligned below each other. Additionally i would ...
6
votes
2answers
221 views

How to best typeset this long matrix multiplication?

I have a quite large matrix multiplication: \begin{align*} \mathrm{Var}(\alpha)&\approx \begin{pmatrix}\sqrt{1+\pi^{2}}\exp(-\delta^{*}+\zeta^{*}) ...
6
votes
4answers
175 views

How can I nicely align a single split equation?

I'd like to align my equation to that it (and its label) fit on three lines. MWE \documentclass[11pt]{article} \usepackage{amsmath} \usepackage{amssymb} \usepackage{xfrac} \usepackage{transparent} ...
6
votes
2answers
5k views

Argument of align has an extra '}'

Okay, this was compiling just fine yesterday. I've since been making some changes, and now get the following error: ! Argument of \align has an extra }. <inserted text> \par l.85 f(t) = ...
6
votes
1answer
5k views

Different spacing around equation and align

In my document, I use align and equation, depending on the length of the equation. They are spaced differently, as you can see on the picture below. I read that comments in the empty lines would ...
6
votes
3answers
2k views

Using tables to typeset proof - how to align equal signs?

I'm a student teaching myself to use LaTeX (and related tools) to type up my homework. It's going great, and I'm already very happy with what I've been able to do so far. Though, I have questions. ...
6
votes
2answers
199 views

Align the n's in the equation

In the following code, how do I align the n's? Here is the MWE: \documentclass[12pt]{article} \usepackage{amsmath} \begin{document} \begin{align} n \propto exp(-U/kT) \notag \\ \Rightarrow \quad n ...
6
votes
2answers
1k views

Why does aligning equations not work here?

\documentclass{minimal} \usepackage{amsmath} \newcommand*{\op}[1]{\operatorname{#1}} \begin{document} \begin{align*} \noalign{$\quad \op{f} * \op{r} = \op{c}_{\op{f}*\op{r}} (x_1,...,x_k) = ...
6
votes
4answers
1k views

Resetting alignment in the align environment

I have a few aligned lists of coefficients. One set of coefficients has three columns and the other has four. At the moment I display them with two align environments: \begin{align} \gamma_1 ...
6
votes
2answers
172 views

Align equations over multiple sections

Is there a way to make the math mode "align" work over multiple sections? Here is the code example: section*{Polynomials} Do the following polynomial devisions \begin{align} &(x^7 - x^4 - 21x^2 + ...
6
votes
3answers
215 views

How to align 'parts' of these equations?

I have a set of equations given by the following code: \begin{equation} \label{eqn:eraserStart} \max \, d \end{equation} \begin{equation} a_t \in \{0,1\} \, \forall t \in T \end{equation} ...
6
votes
3answers
205 views

Specify alignment per column in align equation

Using the following mwe i have not yet found a way to align the formulas correctly. \documentclass{article} \usepackage{mathtools} % extends amsmath and fixes some of its quirks ...
6
votes
1answer
497 views

Footnote from intertext

I want to be able to send footnotes from intertexts I use within align. Is there an easy way to accomplish this (say using a package)? For example, I am a little teapot \begin{align} this ...
6
votes
3answers
124 views

Double align in equation environment

I have four lines inside an equation environment, and I'd like to align the first with the third and the second with the fourth. This is what I got so far: \documentclass{article} ...
6
votes
2answers
75 views

align: using aligned within align troubles

I would like the first two pieces in align look as though they are the only two items in the align environment and the rest to align at the equals signs and separated by some space for the different ...
6
votes
2answers
211 views

Multiple \cline{x-y} in align environment for subtracting equations

I'm trying to make a solution sheet for a student of mine and want to write it in a similar way as I would do when writing per hand. In this case I wanted to have 4 columns of equations (I know that ...
6
votes
2answers
1k views

Subequation aligning using matrix

When I use multiple matrix equations in subequation, I am doing it as in the code snippet. However, when I want to align the equations with respect to equal sign, = (commented in the code), I am ...
6
votes
2answers
98 views

Is there a more idiomatic way of achieving this?

I've recently decided to use LaTeX as my primary document processor, I want to know can I achieve the effect of this more idiomatically: \documentclass{article} \usepackage{amsthm} ...
6
votes
3answers
1k views

Left-align all equations in a block

align environment without any explicit alignments points (given by &) right justifies the equations in the block. They can be left justified by putting & at the beginning of each equation. Is ...
6
votes
2answers
159 views

Formatting inside a table

\documentclass{article} \usepackage{float} \usepackage{mathtools} \newcommand{\unit}[1]{\hat{\mathbf{#1}}} \begin{document} \begin{table}[H] \centering \begin{alignat*}{4} ...
6
votes
2answers
182 views

Conditional linebreak in align environment

I have a large document to typeset in two different page formats. Some of the equation lines are too long in the small format so I wanted to break some equation lines conditioned on whether the macro ...
6
votes
2answers
2k views

How to edit the length of a color box?

I've typed my Resume and Im using a color box, with a line underneath it. However the grey colored box doesn't reach the full length of the page width. \documentclass[letterpaper,11pt]{article} ...
6
votes
3answers
18k views

Left-align math

I'm trying to left-align some math, like here (the center block with the arrows): I've tried the following: \begin{flalign*} (0, (2, q_1), (0, q_1)) \rightarrow (0, (0, q_1), (1, q_2)) \rightarrow ...