# Improper display of parentheses in fraction of fraction

The following code:

$\dfrac{\left( \dfrac{\left( \dfrac{1}{2}\right) }{2}\right) }{2}$


gives a nasty output:

It seems that the $\left( \right)$ command doesn't do the job.

Any idea how to solve this in general?

• Stacking fractions is never the best thing to do. – egreg Sep 3 '13 at 14:22

Another option is to use the \raisebox command to move down the upper part of your fraction

\documentclass{article}
\usepackage{amsmath}

\begin{document}

$\dfrac{\left(\raisebox{-1.5ex}{$\displaystyle\dfrac{\left( \dfrac{1}{2}\right) }{2}$}\right) }{2}$

\end{document}


for this output:

NOTE \raisebox{<length>}{<text>} is expecting some text so you need to enter in math-mode in the raisebox.

Please always post complete documents showing all packages used.

You can re-align the upper fraction using \vcenter (but it still doesn't look very nice).

\documentclass{article}
\usepackage{amsmath}
\begin{document}

$\dfrac{\left( \vcenter{\hbox{$\dfrac{\left( \dfrac{1}{2}\right) }{2}$}}\right) }{2}$

\end{document}


The \scaleleftright{}{}{} macro of the scalerel package doesn't suffer this problem.

\documentclass{article}
\usepackage{amsmath}
\usepackage{scalerel}
\begin{document}
$\dfrac{\scaleleftright[2ex]{(}{\dfrac{\left( \dfrac{1}{2}\right) }{2}}{)}}{2}$
\end{document}