{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

3
votes
2answers
248 views

Numbering of displayed math without using the equation environment

I know about align and equation environments, and tend to use them most of the time, but sometimes I like to have more flexibility within an array of equations, like better control on justification ...
8
votes
2answers
34k views

Aligning using flushleft and flushright

I am trying to create one column to the left side by side with another column to the right. The column to the left is labeled "Examples of like terms:" and the column to the right is labeled "Examples ...
1
vote
0answers
49 views

Aligning equation with another equation after text [duplicate]

I was just wondering, if it was possible to align equations if there are text between them ? I mean, if you have several equations right after each other you can use the \begin{align} command with ...
5
votes
1answer
365 views

Aligning a split up equation not at equal sign

I currently have the following equation: \begin{align} \begin{split} \left| \Psi \left( t \right) \right\rangle _{I}^{3}&=-\frac{1}{{{\hbar}^{2}}}\int_{0}^{t}{\hat{H}_{1}^{I}\left( t' ...
2
votes
1answer
458 views

Bad formating with align + cases and long equations

This is what I have so far: Formatting in section 1 is a joke. I can't even read the cases. Under section 2 I cheated with a manual line break \\ and a parbox. Still the result disgusts me. ...
3
votes
1answer
524 views

Multiline equation with cases

I am trying to get a system of equations, that will have cases only on some of the equations. I made this: \documentclass[a4paper]{article} \usepackage{amsmath} \usepackage{mathtools} ...
1
vote
0answers
194 views

Name of length for equation number indent if [leqno] is set [closed]

I got a weird phenomenon as shown in the picture below. The equation numbering is indented. I tried the same thing in a fresh document and it produces the result I am looking for. For the other ...
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} ...
9
votes
2answers
415 views

Ignoring specific ampersand formatting on a specific line of an align block

I want to typeset a number of equations with some alignment constraints, but I want to partially ignore them on certain lines. An example formatted text might look like the following when it's ...
3
votes
2answers
182 views

Cross reference to align

What I want to do is to make a cross reference to program (P) and still be able to make cross references to each separate line in the alignment. \begin{align} (P)\quad \min ...
2
votes
1answer
93 views

How to get to use {align} with an unusual document class?

So I'm required to use a particular documentclass, "llncs", which for some reason is preventing me from using {align}. Is there an alternative that I can use? The beginning of my tex file ...
8
votes
2answers
84 views

Horizontal alignment across nested aligned

Is there a way to left align the first 2 rows with the last one? \documentclass{article} \usepackage{amsmath} \begin{equation*} \left\{{\begin{aligned} &\left.{\begin{aligned} &A+B=X\\ ...
2
votes
1answer
938 views

Aligning equality sign with overset text

I'm typing a logic definition within an align environment that uses \overset{def}{=} from the amsmath environment. However, the new sign is aligned vertically based on the equality sign, and not on ...
2
votes
1answer
263 views

Custom glossary environment improvement

This is a followup question about the code provided by Nicola Talbot in this question: Automated generation of equation key TL;DR: Defines new environment alignglos which can be used to wrap ...
4
votes
1answer
117 views

Setting a column of an align environment at a fixed distance from the margin

I'd like to set proofs in the style shown in this answer but with the right column at a constant distance from the left margin, so that the explanations show up consistently located in the many proofs ...
1
vote
1answer
558 views

Two columns of equations, aligned and just one number per column

I'm writing a two-column document, and I want to display two sets of large equations floating at the top. Each equation set should be aligned within the same column, and only the two top equations ...
1
vote
2answers
73 views

Place Image and Break Pages

I want to obtain the following format: Text Text Text Text endofpage image newpage Text Text Text Text I have three pages in total. The image occupies whole page and the text in newpage is ...
0
votes
0answers
53 views

Is it possible to remove chapter number from align environment? [duplicate]

Basically I have written a proof using the align environment in a new .tex file and the numbers in the proof came like this (how I want them): Line1 (1) Line2 (2) Line3 (3) Now I've ...
2
votes
2answers
2k views

Multicolumn/multirow inside align

Is there a way to use \multicolumn or \multirow inside an array environment which is inside align environment? For instance, the following piece of code gives me an error. What is the way around this? ...
10
votes
3answers
867 views

Numbering a set of horizontally distributed equations

Having different horizontally distributed equations inside an align environment, only lines are numbered, but not individual equations. How can the left equations be numbered using subequations? ...
2
votes
1answer
2k views

some \newcommand instructions not working

I have created some new short command using \newcommand in the following example: \documentclass[12pt,twoside,a4paper]{book} \usepackage{enumerate,amsmath} \newcommand{\ba}{\begin{array}} ...
1
vote
1answer
314 views

Prevent multiple equation numbers when using \allowdisplaybreak with align

I have a very long equation of the following format \begingroup \allowdisplaybreaks \begin{align} a &= very long expression here\\ + & another long expression here\\ + & another long ...
4
votes
2answers
194 views

how to align texts in equation cases

I need to make an equation case with text following it. That text should be displayed in the middle of the two cases. This is my code: \begin{eqnarray}\label{eq13} a_k = \begin{cases} 1 & ...
6
votes
3answers
243 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} ...
11
votes
3answers
18k views

aligned environment of amsmath vs array environment

Today I found out the existence of the aligned environment of the amsmath package. However, I can't see the advantage of using it instead of the array environment from the example provided in ...
5
votes
3answers
170 views

Aligning equal signs such that the line is already aligned

I have an align question. Essentially the following code: \begin{align} \nonumber & \exp\left(-\sum_{t=1}^T\lambda_t f_t(x_1)\right)\exp(-\mu-1) + \exp\left(-\sum_{t=1}^T\lambda_t ...
0
votes
0answers
53 views

Is there an opposite to \nonumber? [duplicate]

Usually I set equations using the align environment together with \nonumber for those few lines that shall not have a number, or the align* environment if no equation shall be numbered. But what if ...
2
votes
1answer
129 views

TikZ object misaligned with main document: slightly shifted to the right

The TikZ picture is not aligned with the main content of the document. It slightly shifts to the right. Notice how the words go outside the frame on the right side. Any hints on how to correct this ...
3
votes
2answers
1k views

Unnumbered line inside align

Basically, I have two equations that I wanted to use align to number, but I also wanted to put the word 'and' in between the lines. Here's what I have so far \begin{document} \usepackage{amsmath} ...
3
votes
1answer
347 views

Conflict between \hline and arydshln in aligned environment?

I'm using the following code: \documentclass{article} \usepackage{tikz} \usepackage{amsmath} % \usepackage{arydshln} %code doesn't compile anymore with this package \begin{document} ...
4
votes
1answer
84 views

Specify number of columns in brqalign

Some time ago David Carlisle wrote an awesome brqalign function in this answer: http://tex.stackexchange.com/a/51543/4011. See the cited code below. How to modify the brqalign environment such that ...
11
votes
5answers
7k views

How to align the equal signs in this equation such that the first line and last 2 lines align

so I have an equation below. My latex code for it is: \begin{align*} CoJPoD_{ \{I_1, \cdots, I_{k-1}, I_{k+1}, \cdots, I_{n}\} | I_{k} } = CoJPoD_{ \{system \backslash I_{k}\} | I_k} \\ = ...
1
vote
1answer
379 views

tabbing numbering and alignat numbering

Is there a way for the tabbing environment \begin{tabbing} to number equations and sync up with the align or alignat environments? If I use align or alignat, each successive use is numbered ...
2
votes
2answers
359 views

Split equation with each element being exactly below each other

I have an estimated equation with both coefficients and t-statistics. It's a multiline equation and would like to put the t-statistics right below the coefficient estimates Currently my code looks ...
7
votes
2answers
4k views

Equations and defining equation variables

I have a main equation that should be numbered and now I want to define the variables of the equations which may contain another set of equations. For example please have a look; code: \begin{align} ...
6
votes
3answers
7k views

\underbrace and align environment

I want to typeset a proof and want to emphasize what I do in each step e.g. by underbracing an equal-sign when I substitute a variable. In addition I also want to align equal-signs in every line. ...
5
votes
3answers
4k views

Left-align math with fleqn inside split environment

Below, how would I move the first math-line left so that a^2 left-aligns with where? \documentclass{article} \usepackage[fleqn]{amsmath} \begin{document} \setlength{\parindent}{0pt} Some text ...
10
votes
2answers
3k views

How to format Maxwell equations?

Is there a variant of split environment from amsmath package which would allow for two aligned equations in a row? I want to format two pairs of Maxwell equations in two rows and put single equation ...
6
votes
4answers
193 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} ...
2
votes
1answer
307 views

Which one is recommended to split, continue and align a long equation?

In my investigation, the outputs are identical as follows. Version 1: Using aligned. \begin{align*} \framebox[6cm]{Top LHS}\\ \framebox[5cm]{Middle LHS}\\ \framebox[4cm]{Bottom LHS} &= \! ...
4
votes
2answers
348 views

How to create a beautifully aligned solution for exercises?

Basically, I'm writing solution for the exercises on the textbook. And I want something like this: As you can see, sub-problems are aligned after the problem number and the formulas are aligned ...
10
votes
1answer
439 views

Comment an equation without creating extra space

I try to make a comment on the right (or left) of one line of proof. But the align* environment automatically move the whole equations to the left to leave space for the comment. But I still want the ...
0
votes
1answer
745 views

Issues aligning equations

I thought I was doing everything correctly, but clearly not. I want my equations (all whether I use \begin{flalign} or \begin{equation}) to be aligned each other (have the same indent), and then when ...
3
votes
1answer
255 views

Automatic arrangement of equations with comments

This question led to a new package: conteq I am writing a paper with multiple chains of equations or inequalities, with optional explanations. Depending on the size of the equations, I use one ...
4
votes
1answer
2k views

Remove unnecessary horizontal space from amsmath align between two &

How do you remove unnecessary horizontal space in an amsmath align environment between two &? Consider: \documentclass{article} \usepackage{amsmath} \begin{document} Version 1: \begin{align*} ...
3
votes
1answer
242 views

Tikz Scaling and Positioning

I cannot scale the first picture. scale=0.6 does not work. Also I cannot vertically align the picture. I want top of text and top of figure are same. See figures in the following examples. ...
3
votes
1answer
278 views

Overset placement is uneven

I'm using this code to show that one element of the equation is greater than zero and the second element is less than zero. \begin{align} \overset{+}{\pi_{i}} + \overset{-}{w_{g}(S)} > 0 ...
2
votes
1answer
76 views

Fixing alignment with the rest of the text

The image included above is what I want to replicate - I want the name to appear on the top left, and the address/email-id to appear on the top right, and I want both of them to be aligned with the ...
4
votes
2answers
407 views

Aligning tikz picture within text

I want to align my tikz within a text. A sample can be seen at the second picture in the following link: Image courtesy from http://www.echoecho.com/htmlimages08.htm This is my trial: ...
12
votes
2answers
266 views

Align*, & and \futurelet

can somebody explain futurelet within align-environments? Example: The command \A should give an "A" if the next char is a {, a "B" if it is & and "C" in any other case. ...