I have a generic equation, into which I want to "insert" something so that the reader can see what I inserted into the equation and at which point.
E.g.
\documentclass{plain}
\begin{document}
\[ f = < x | R y > \]
Insert $\int d^3 p |p> <p|$ = 1 before y.
\end{document}
What I imagine is a horizontal curly brace, which extends underneath the equation, and which has its tip touching a spot just slightly to the left of the $y$
, while in the brace there is written $\int d^3 p |p> <p|$
. It would look something like an inverted \underbrace{foo}_{bar}
, but I have no idea how to achieve something like that.
In ASCII art this would maybe look like this:
f = <x | R y > (1)
__|__
____| |____
| Insert here! |
Best Answer
Here's a variant of Gonzalo's code that uses
\mathop{}\limits
instead of\raisebox
. The output is almost the same.If you want something more flexible, use the
\braceinsert
macro from the code below. It takes one optional argument (the amount by which the brace should be lowered, with default0ex
) and one mandatory argument (the stuff you want under the brace). Moreover, it takes care of the case that the\braceinsert
is surrounded by\left...\right
delimiters, like this:To be precise, you'll have to use
\bileft...\biright
instead of\left...\right
(likeb
racei
nsert left and right). After the outermost\biright
, only explicit superscripts will work, so instead of'
you'd have to use^\prime
. (Subscripts won't work properly, but I don't know when one would want one.)(Maybe this is wayyy too complicated?)