I read everywhere that \tiny
, etc. does not work in mathmode. When I use it in my code, I also get a warning Command \tiny invalid in math mode
. But in the output it nevertheless works. At least in some places.
I suppose on other machines this will not work, so I would like to not use these commands in math mode. But, all other commands to make small fonts in mathemode do not work as well as \tiny
does. E.g. in the following MWE
\documentclass{scrbook}
\begin{document}
$M_{\begin{array}{c}2\\2\end{array}2A}$
$M_{\tiny\begin{array}{c}2\\2\end{array}2A}$
$M_{\scriptsize\begin{array}{c}2\\2\end{array}2A}$
$M_{\scriptstyle\begin{array}{c}2\\2\end{array}2A}$
$M_{\scriptscriptstyle\begin{array}{c}2\\2\end{array}2A}$
\end{document}
The output I want, is the second. I have a subscript consisting of an array, and this array shall have small numbers.
But \tiny
is the only command which accomplishes that.
Now to my questions:
- How do I make small subscripts as in the second example without the use of
tiny
. - Why does
tiny
work for the array-subscript, but not for the standard subscript. - Why does
scriptscriptstyle
work for the standard subscript, but not for the array-subscript.
This question is not a duplicate to
Size commands do not work in mathmode
since I am also asking why tiny
works, although it is written everywhere that it is not working (and furthermore, @egreg said it is no duplicate).
Best Answer
Size commands do not work in math mode. However (some) size commands set up math so if you enter a new math expression from text while the size change is in force, you get math of a matching size. Internally array is an
\halign
in which each cell is surrounded by$...$
so in fact usingarray
is like using\mbox{empty text $ matrix cell$}
so the entries pick up the size change more or less by accident.