# index of a /sqrt is complex and produces error

I want to write in latex and an error occurs, if you could help me please

 $F=\left(\sqrt[\sqrt[\sqrt{7}]{7}]{\sqrt[7]{7}^{7^{\frac{\sqrt{7}}{7}}}}\right)^7$

• Is there any reason, apart from academic interest, to write such an unmathemathical thing? – egreg Oct 3 '20 at 21:12
• @egreg Isn't the $n$-th root usually only defined for natural numbers $n$? – CampanIgnis Oct 4 '20 at 12:43
• @CampanIgnis There is nothing that prevents defining it for any nonzero real, but it is really awful, IMHO. – egreg Oct 4 '20 at 13:01

You need an extra set of braces {..} around the optional argument in the outermost \sqrt command.

\sqrt[{\sqrt[\sqrt{7}]{7}}]{\sqrt[7]{7}^{7^{\frac{\sqrt{7}}{7}}}}

But the spacing looks bad to me, so I would use \Biggl( and \Biggr) instead of \left and \right, and also use \raisebox with a negative argument to lower the expression inside the parentheses.

Also, it looks like you are missing a set of braces after \sqrt[7]{7}^{..} inside the main radical.

 $F=\Biggl( \raisebox{-1.4ex}{\hspace{-.7em}\sqrt[{\sqrt[\sqrt{7}]{7}}]{{{\sqrt[7]{7}}^7}^{\frac{\sqrt{7}}{7}}}} \Biggr)^{\!7}$


But then the last exponent inside the main radical looks low to me, so you could use another \raisebox. Also the 7 outside the main radical looks too small. So...

$F=\Biggl( \raisebox{-1.4ex}{\hspace{-.7em}\sqrt[{\sqrt[\sqrt{7}]{\scriptstyle7}}]{{{\sqrt[7]{7}}^7}^{\raisebox{.7ex}{\scriptscriptstyle\frac{\sqrt{7}}{7}}}}} \Biggr)^{\!7}$


Which will produce the image

Of course you can adjust the spacing however you like.

The amsmath package provides the macros \leftroot and \uproot to fine-tune the position of the optional argument of \sqrt.

\documentclass{article}
\usepackage{amsmath} % for \leftroot and \uproot macros
\usepackage{newtxtext,newtxmath}
\begin{document}
$F=\left(\!\!\! \sqrt[\uproot{-4}{\sqrt[\uproot{4}\leftroot{-1}\sqrt{7}]{7}}] {{{\sqrt[\leftroot{1}\uproot{2}7]{7}}^7}^{\frac{\sqrt{7}}{7}}}\, \right)^{\!7}$
\end{document}


Mostly stealing this, from Mico. The vertical imbalance in the parentheses looks bad, so let's use an array. Usually an array is used for horizontal alignment, but we want its minor feature of vertical centering without forcing the width like a \parbox would. Use @{} entries to adjust horizontal spacing instead of \!\!\!.

\documentclass{article}
\usepackage{amsmath} % for \leftroot and \uproot macros
\usepackage{newtxtext,newtxmath}
\begin{document}
$F=\left( \begin{array}{@{\hspace{-5pt}}l@{\hspace{2pt}}} \sqrt[\uproot{-4}{\sqrt[\uproot{4}\leftroot{-1}\sqrt{7}]{7}}] {{{\sqrt[\leftroot{1}\uproot{2}7]{7}}^7}^{\frac{\sqrt{7}}{7}}} \end{array} \right)^{\!7}$
\end{document}


There is some ambiguity still from the formatting of the root-7 over 7 exponent.

• +1. Much better-looking than my solution is. – Mico Oct 4 '20 at 7:39