# [Tex/LaTex] Center \leq, \geq, = with different text above

align

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.

This solution proposes use of makebox where adjustment of width is possible for one's need.

Code

\documentclass[12pt]{article}
\usepackage[margin=1cm,paper size={10cm,10cm}]{geometry}
\usepackage{amsmath,amssymb}
\thispagestyle{empty}
\begin{document}

{\bf OP:}

\begin{align*}
x_1 + x_2
\overset{\text{some text}}=& 2y^3 \leq\\
\overset{\text{some longer text}}\leq& 3z
\end{align*}

{\bf Use of makebox:}

\begin{align*}
x_1 + x_2
\makebox[3cm][c]{$\overset{\text{some text}} =$}              &2y^3 \leq\\
\makebox[3cm][c]{$\overset{\text{some longe text}} \leq$}  &   3z
\end{align*}

\end{document}