latex comment over equal sign code example
Example 1: tex write above
$\overset{\mathrm{def}}{=}$
Example 2: text over equal latex
\documentclass[preview]{standalone}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\newcommand{\approxtext}[1]{\ensuremath{\stackrel{\text{#1}}{\approx}}}
\begin{document}
$\displaystyle
A \stackrel{\text{text}}{\approx} B
$,
$\displaystyle
A \approxtext{test} B
$
\end{document}