![下付きイコール記号](https://rvso.com/image/305903/%E4%B8%8B%E4%BB%98%E3%81%8D%E3%82%A4%E3%82%B3%E3%83%BC%E3%83%AB%E8%A8%98%E5%8F%B7.png)
条件/スコープをその下に記述した単純な = 記号を実装する、クレイジーでない方法はありますか? 特に、(expr1) = (x->a) (expr2)
は、(x->a)
等号の下に制限のように記述されますか?
答え1
このような?
\documentclass{article}
\newcommand\underrel[2]{\mathrel{\mathop{#2}\limits_{#1}}}
\begin{document}
$x \underrel{x\to a}{=} a$
\end{document}
オプションの引数を追加して、アンダーセットのコンテンツを左右に流し込むこともできます。
\documentclass{article}
\usepackage{mathtools}
\newcommand\underrel[3][]{\mathrel{\mathop{#3}\limits_{%
\ifx c#1\relax\mathclap{#2}\else#2\fi}}}
\begin{document}
$
x \underrel{x\to a}{=} a
\quad
x \underrel[c]{x\to a}{=} a
$
\end{document}