# Controlling sqrts (mathptmx)

Consider this MWE

\documentclass[border=10mm,varwidth=true]{standalone}
\usepackage[T1]{fontenc}
\usepackage{amsmath,amssymb}
%\usepackage{mathptmx}
\begin{document}
$\sqrt{n+1}\sqrt{2+(n+2)^2}$
\end{document}


As it stands with CM fonts we get

Adding mathptmx we get

Which is really horrible, especially it it scales like that in the text.

Any ideas on how to better control \sqrt with mathptmx (and no we cannot change the font package, it is what the publisher is using). Note that I'd like to not have to deal with a lot of messing with phantoms.

• well, that's a bummer. it looks to me like the font size used for superscripts with times is just a tad larger than the computer modern setting, with the result that a superscript digit kicks the total height above the \sqrt-sizing threshold. try using (top) \smash on the superscript. (haven't tried it myself, so don't know if there will be side effects.) – barbara beeton Jun 28 '16 at 13:59
• well, i did just try it; running under tex live 2012. and that doesn't happen -- the radical is the same relative size as for cm. likewise for tex live 2015. (we don't have 2016 installed yet.) – barbara beeton Jun 28 '16 at 14:09

The superscript to the parenthesis triggers using the second “next larger” character for the square root, not the first one like with CM. I guess it has to do with the height+depth of the parentheses.

You can smash the superscript.

\documentclass[border=10mm,varwidth=true]{standalone}
\usepackage[T1]{fontenc}
\usepackage{amsmath,amssymb}
\usepackage{mathptmx}
\begin{document}
$\sqrt{n+1}\sqrt{2+(n+2)^{\smash{2}}}$
\end{document}


The problem is the same with NewTX, I'm afraid; with MTPro2 it comes out right without smashing.

You can also trick sqrt by making the argument smaller and the entire square root bigger. This has the advantage of not having to adjust individual equations.

\documentclass[border=10mm,varwidth=true]{standalone}
\usepackage[T1]{fontenc}
\usepackage{amsmath,amssymb}
\usepackage{mathptmx}
\usepackage{relsize}
\newcommand{\sqroot}[1]{\mathlarger{\mathlarger{\sqrt{\mathsmaller{\mathsmaller{#1}}}}}}
\begin{document}
Original:
$\sqrt{n+1}\sqrt{2+(n+2)^2}$

New:
$\sqroot{n+1}\sqroot{2+(n+2)^2}$

\end{document}


Result: