I have:
\usepackage{nicefrac }
\begin{align*}
&= \frac{2}{\sqrt{2y+1}\sqrt{2 \pi}} \exp \left( -y-\nicefrac{1}{2} \right) &&\forall y \in [-\frac{1}{2} , \infty) \\
&= \frac{2}{\sqrt{2y+1}\sqrt{2 \pi}} \exp \left( -y-\frac{1}{2} \right) &&\forall y \in [-\nicefrac{1}{2} , \infty)
\end{align*}
Both of these seem somewhat unsatisfactory. Could anyone help me get the best display for the 1/2
after the \exp (
and also after the \in [
Best Answer
Fractions
I'd just use the normal
\frac
or\tfrac
. For display style maths they still look the best. I would use\nicefrac
(or similar) only (if at all) in text maths.Code
Output
\smash
Also, consider using
\sqrt{\smash[b]{2y+1}}\sqrt{\smash[b]{2 \pi}}
in your denominator for better roots.To quote from the
amsmath
documentation:Compare:
Code
Output
The top bar of the root is aligned different and even the lower point is not on equal heights.
LaTeX Companion
The LaTeX Companion has a very elaborated text about
\smash
and its uses. The first two examples (licensed under the LPPL) are shown here. Take a close look at the root's lower end and the top bar.Code
Output