3

I was under the impression that the subdepth package would even out the depth of subscripts, but I just tried the following code in which the subscripts are not "aligned":

\documentclass{article}
\usepackage{amsfonts}                                                           
\usepackage[low-sup]{subdepth}

\begin{document}
  \[
    Z^{\frac12}_{\mathcal{A}} u_{\mathcal{A}}
  \]
\end{document}

Is subdepth not supposed to work with the mathcal font? The subscripts are aligned if I type, e.g., $M_n = M_n^T$.

Werner
  • 603,163
Dominique
  • 1,369

1 Answers1

6

Looking at the package, it sets the parameters to make the default positions of subscripts unchanged by "normal sized" superscripts, however TeX will always move the scripts to avoid clashes, so without doing a scan of the whole expression I don't think you can make them all align for arbitrarily large superscripts.

You can make your case align by putting in an invisible superscript

\documentclass{article}
\usepackage{amsfonts}                                                           
\usepackage[low-sup]{subdepth}

\begin{document}
  \[
    Z^{\frac12}_{\mathcal{A}} u^{\vphantom{\frac12}}_{\mathcal{A}}
  \]
\end{document}
David Carlisle
  • 757,742
  • But you can do the same without subdepth, which is what I used to do. I'm not sure it is the superscript that is at fault because $Z^{T}{\mathcal{A}} u{\mathcal{A}}$ is still not aligned. – Dominique Apr 07 '12 at 18:41
  • yes the package isn't helping at all in this case. Looking at the code it sets things up so a superscript of ^+ doesn't disturb the default settings. If your superscripts are typically deeper than a + it would (probably) be possible to have a variant of the code that set the defaults such that some other (fixed) superscript does not disturb the default, but you'd get very low default subscrupts I assume – David Carlisle Apr 07 '12 at 18:45