12
votes
How can I write the next step exactly below the previous step in the equation without repeating the L.H.S. of the equation?
The following solution also employs an align* environment (cf @RaffaeleSantoro's solution), but also takes care of several typographical niceties such as using upright lettering for a "math ...
10
votes
Accepted
How can I write the next step exactly below the previous step in the equation without repeating the L.H.S. of the equation?
Try this:
\documentclass[10pt,a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{graphicx}
\begin{document}
\begin{align*}
...
10
votes
How to align text under the brackets
You want to make the formulas to have the same height. Here I use \mathstrut, but in the optional argument you may use any \vphantom.
\documentclass{article}
\usepackage{amsmath}
\newcommand{\...
10
votes
How to align text under the brackets
The reason the middle of the three underbraces isn't aligned vertically with the other two is that the first argument of the associated \underbrace directive doesn't contain material that protrudes ...
9
votes
Accepted
LuaLaTeX - tabularx - Why does this table not fit on the previous page?
LaTeX limits the size of floats on a page. In particular the parameter \textfraction specifies the minimal amount of the page that is reserved for text (and hence, cannot be used by floats). Default ...
8
votes
Align Equations Including `cases`
You could use the nicematrix package as shown in https://tex.stackexchange.com/a/583373/36296
\documentclass{article}
\usepackage{nicematrix}
\begin{document}
\[
\begin{NiceArray}{r@{\;}l}[first-row]
...
8
votes
Accepted
How can I stack these items on top of each others at the bottom of a vertical bar?
I would just use \substack:
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{align*}
y &= y_0 + \sum_{n = 1}^{\infty} \frac{x^n}{n!} \, f_n(x, y) \bigg\vert_{\substack{x =...
7
votes
How to change vertical alignment of a fraction within an equation
You might do it by using gathered around the fraction, but there are much better ways.
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{equation}
\begin{bmatrix}
\...
7
votes
Accepted
Vertical alignment of \underset
(I've edited this answer to mention the \overunderset macro, which has the same issue as a nested combination of \overset and \underset.)
It would appear that \rightleftarrows is programmed to think ...
6
votes
Align top of images using subcaption
Newer solution
For anyone who come across this issue with subcaption package >= v1.2, there is a built-in argument for that:
\begin{subcaptionblock}[⟨outer-pos⟩][⟨height⟩][⟨inner-pos⟩]{⟨width⟩}
......
6
votes
Accepted
Compilation error when using &
This is a bug, fixed for the next release see
https://github.com/latex3/latex2e/issues/901
There is a full patch there or simply guard the & with a \relax before the &.
6
votes
Please make my table perfect with long caption
Some suggestions, in no partiular order: (a) Use a threeparttable environment to encase both the \caption statement and the tabular environment. That way, the width of the caption will be limited to ...
6
votes
equation vertical alignment in tabular, baseline is too low
An answer with easytable:
\documentclass{article}
\usepackage{amsmath}
\usepackage[thinlines]{easytable}
\begin{document}
\begin{center}
\begin{TAB}(r,1cm,2cm)[5pt]{|c|c|}{|c|c|}% (rows,min,max)[...
6
votes
Accepted
equation vertical alignment in tabular, baseline is too low
With tabularray:
\documentclass{article}
\usepackage{tabularray}
\UseTblrLibrary{amsmath}
\begin{document}
\begin{center}
\begin{tblr}{hlines, vlines,
colspec = {Q[c, mode=math] ...
6
votes
equation vertical alignment in tabular, baseline is too low
A solution with the cellspace package, which allows to define a minimal vertical spacing at the top and bottom of cells in columns with specifier prefixed with the letter S (or Cif you load siunitx, ...
6
votes
Accepted
Vertical alignment between numbers and arrows
The tricky part is centering numbers with a sign. The value of \tabcolsep sets (now increases) the distance between columns.
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\newlength\...
6
votes
Align Equations Including `cases`
Adaptations
insert a negative space before the cases environment: \hspace{-.73em}
use relative size em, so it works ok (not perfectly, as there is a small difference for huge) also for other ...
6
votes
Accepted
tabularray - How to center both text and images
You need to move image baseline to its vertical center. For example by use of the adjustbox package:
\documentclass[10pt,a4paper]{scrreprt}
\usepackage{fullpage}
\usepackage[export]{adjustbox}
\...
6
votes
tabularray - How to center both text and images
Here's one possibility using graphbox, which provides the align option to \includegraphics. I also switched to the current syntax of tabularray.
\documentclass[10pt,a4paper]{article}
\usepackage{...
6
votes
Accepted
How can I force 'description' to start on a new line when using 'enumerate'?
One way to get what you want is to simply add a small negative vertical space at the beginning of the embedded enumerate list. We can do this using the before key which can inject code before the list ...
6
votes
Accepted
Need help fixing height discrepancy in LaTeX tables
Something like this:
Your MWE has several issues:
Use of \resizebox. Never do this. Apparently the right table is a little bit wider than the left one, so it is shrunk more. Accordingly, the font ...
5
votes
Accepted
How can I make these numbers center aligned?
You want to remove the [t], but there's a much simpler way to do it with adjustbox.
\documentclass[journal]{IEEEtran}
\usepackage{amsmath,amsfonts}
\usepackage{algorithmic}
\usepackage{algorithm}
\...
5
votes
Please make my table perfect with long caption
Hm, it is still unclear to me what is `perfect table" for you :-(. This is very opinion dependent ...
One possibilities, at least the code is much simpler than yours, is to use the tabularray ...
5
votes
Accepted
Please make my table perfect with long caption
I suggest giving some more air to the table by increasing the intercolumn space, otherwise the very short column headers make for too compact typesetting.
Another improvement is avoiding vertical ...
5
votes
equation vertical alignment in tabular, baseline is too low
arraystretch causes asymmetric stretching. This effect is more visible the higher is its factor. It's better to use struts to add vertical spacing in rows
\documentclass{article}
\usepackage{array,...
5
votes
LuaLaTeX - tabularx - Why does this table not fit on the previous page?
Only a long comment about the philosophy of the solution:
!h or b! is not an option, unfortunately, clear no-no from my tutor.
The reason to float rules is avoid as far as possible bad document ...
5
votes
vertical alignment of sum with substack
I suggest you replace the auto-sizing instructions \left and \right with \Bigl and \Bigr, respectively. Better yet, consider not using curly braces for the expression at hand. "Snugging up" ...
5
votes
Accepted
Minipage environments are misaligned
I would use beamer columns:
% !TeX TS-program = lualatex
\documentclass[14pt]{beamer}
% Presento style file
\usepackage{config/presento}
% custom command and packages
\input{config/custom-command}
...
5
votes
Minipage environments are misaligned
The image you show has the baseline of the first line of text on the left aligned with the basline of the image on the right.
This means that both minipage are top aligned and have text and image as ...
5
votes
Minipage environments are misaligned
The reference point of the minipage on the right is the bottom of the picture.
You can add \vspace*{...} to set a different reference point. In the first minipage it should be 0pt, in the second one ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
vertical-alignment × 3666tables × 896
horizontal-alignment × 468
tikz-pgf × 293
spacing × 250
graphics × 210
align × 196
math-mode × 162
beamer × 157
minipage × 157
equations × 154
floats × 131
tabularx × 131
subfloats × 92
lists × 88
multirow × 88
amsmath × 83
longtable × 78
alignment × 76
boxes × 74
positioning × 70
enumerate × 68
itemize × 67
formatting × 65
multicol × 61