I have this equation:
\lim_{d \rightarrow \infty} \left [ \underset{a\leq x\leq b}{\mathrm{max}_p} \left | f(x) - m(x) \right | \right ] = 0
which produces this:
As you can see the max part is not vertically aligned inside the brackets. The lim is also not aligned with the brackets. I want it to look something like this:
As you can see, the lim and max part is now properly aligned. The absolute | | height should also be adjusted to fit the height of the \underset part of max.
Anyone know how to do this?
Best Answer
The names ‘lim’ and ‘max’ should be at the same level as ‘f’; also the absolute value bars should be as high as necessary to cover the material inside them; what's before the opening bar is irrelevant as far as the absolute value is concerned.
This is a case where
\left
and\right
are plainly wrong, because they produce too large delimiters. I don't think the square brackets are necessary, because ‘maxp’ has obvious precedence over ‘lim’.Here are two realizations, with and without the brackets; note the definition of the
\maxp
operator. In the first realization, a thin space\,
has been added in order for the bracket not to clash with the subscript.You may want to look at
\adjustlimits
from themathtools
package:but I'd prefer the former realization.