I am typesetting some mathematical equations using \begin{align*}
environment. Hopefully to make the steps clear I am adding text above =, \leq, \geq
but I am having troubles with aligning them e.g.:
\begin{align*}
x_1 + x_2
\overset{\text{some text}}=& 2y^3 \leq\\
\overset{\text{some longer text}}\leq& 3z
\end{align*}
The result is, that the \leq
is not centered with =
sign above. Is there a neat way to solve this? In some different cases I am using this approach:
\begin{align*}
x_1 + x_2
\overset{\text{some text}}=& 2y^3 \leq\\
\overset{\phantom{\text{some text}}}\leq& 3z
\end{align*}
But I don't think that adding some phantom characters to the first example would be a good way how to do it.
\intertext{...}
and its cousin\shortintertext{...}
frommathtools
from def 3.11(ii)
in my language "only"z def 3.11(ii)
, so I might stick to it form time to time. But I guess "long justification" can stand for two and more characters sometimes.align
environment.