\stackrel
exploits the same TeX's internal mechanism used for setting limits over \sum
:
\newcommand{\stackrel}[2]{\mathrel{\mathop{#2}\limits^{#1}}
Therefore lowering the "superscript" won't have any effect (raising would). In any case it's better to use \overset
from amsmath
. And, in this particular case, to use the predefined symbol.
How to solve your problem in other situations, without measuring?
Alignments are what we need: but array
would leave too much space and we'd need measuring again. Here's a way out; I'll use the "triangle over equals" just by way of example: always use an already available symbol.
\newcommand{\defeq}{%
\mathrel{\vbox{\offinterlineskip\ialign{%
\hfil##\hfil\cr
$\scriptscriptstyle\triangle$\cr
%\noalign{\kern0ex}
$=$\cr
}}}}
I've left a (commented) line where one could adjust the separation between the two parts; it's better to specify ex
rather than pt
units, so that the symbol can be used in various font sizes.
We say that the symbol is a relation.
We enclose the building into a \vbox
, so that the baseline of the bottom element will be used for the whole thing.
In the \vbox
we suppress the usual interline skip mechanism (\offinterlineskip
).
We start an alignment; \ialign
is just a way to use \halign
with \tabskip
set to zero.
The alignment consists of one column, with centered items (\hfil#\hfil\cr
, the #
needs to be doubled because we're in a definition).
The two rows, possibly adjusting the separation with a positive or negative kern.
Here are some examples
