Intertext vertical spacing
The mathtools package provides the command \shortintertext
, which has less vertical space than the standard \intertext
.
Below the upper part of the formula comes a vertical space with the height \belowdisplayskip
. Afterwards comes the text by \intertext
. Before the rest of the formula, a vertical space with a height of \abovedisplayskip
will be inserted.
These are usual spaces before and after displayed math environments and surrounding text. So, it's the same for inserted texts. \abovedisplayshortskip
and \belowdisplayshortskip
are further such skips; these short skips would be used if the line before the display ends before the formula begins, for the visual appearance.
You could change those lengths. If you need it just at a certain place, you could modify the lengths there and limit this effect by grouping with braces or \begingroup
, \endgroup
:
{%
\setlength{\belowdisplayskip}{0pt}%
\setlength{\abovedisplayskip}{0pt}%
\begin{align}
...
\intertext{some text}
...
\end{align}%
}
Instead of 0 pt you could insert any other value. If you need it several times, you could consider to create a macro or to modify the behavior of \intertext
.
It is possible to exploit \flalign
to get better control of the vertical spacing.
The {\LaTeX} \verb|\intertext| command is generally unsatisfactory.
\begin{flalign*}
&& L_1 &= R_1 && \\
\intertext{Who needs this?}
&& L_2 &= R_2 && \\
&\text{Whatever needs to be said should be said here.}\hidewidth\\
&& L_3 &= R_3 &&
\end{flalign*}
We should get good alignment this way.