# Is it safe to “renewcommand” \SS? (Which packages use \SS command?)

I've tried to set

\newcommand{\SS}{\mathcal{S}}


in the preamble but I've discovered that this command is already defined.

So, I tried native command on my code and I've found that it is a "simple" double S.

Now, I can fix my problem using

\renewcommand{\SS}{\mathcal{S}}


but I'm not sure it is safe (I don't know if \SS is used by LaTeX only to draw a (simple or special) double S, or for something else too).

Does someone know if it is safe (or when it isn't safe) to do a “renewcommand” of \SS?

• \SS is used for the uppercase version of the German symbol ß, usually rendered as "SS". – Andrew Swann Jul 15 '14 at 10:57
• And what about the name \cS, as calligraphic S? In standard LaTeX it is not defined. – Przemysław Scherwentke Jul 15 '14 at 11:03
• thank you @PrzemysławScherwentke for suggest! You are right! :-) – Corrado Jul 15 '14 at 11:05
• Not really safe: your bibliographic data might contain a ß that in turn might be capitalized: the final result would be at least puzzling. – egreg Jul 15 '14 at 11:41
• Thank you @egreg, that is a danger I didn't mind! I definitely choose \cS command, as suggested by PrzemysławScherwentke – Corrado Jul 15 '14 at 13:20

If you want to see, what a command is used for, you can use the \show macro:

% arara: pdflatex

\documentclass{article}

\begin{document}
%\show\cS
\show\SS
\end{document}


This will show:

\SS=macro:
->\T1-cmd \SS \T1\SS .
l.7 \show\SS


Ok, this information is not so cool, but you can see that is has something to do with the T1 encoding and you see that it is used as a macro. Googling the same macro will easily result in the definition (the German upper-case sz-letter). The command \cS as recommended in the comments results in:

\cS=undefined.
l.6 \show\cS


and thus is safe to be used.

• You can do \expandafter\show\csname T1\string\SS\endcsname or also texdef -t latex -p[T1]fontenc T1\\SS from the command line, which would reveal that \SS ultimately does \char"DF (slot "DF=223 in the T1 encoded fonts indeed contains an “SS” glyph). – egreg Jul 15 '14 at 11:40
• Thanks, you may add that to my answer if you want. Still, this is kind of easier... ;-) – LaRiFaRi Jul 15 '14 at 11:49

Concerning the safety of re-defining command \SS (which is the capital of "ß") in order to shorten the command \mathcal{S}, @egreg said:

"Not really safe: your bibliographic data might contain a ß that in turn might be capitalized: the final result would be at least puzzling."

That is definitely true, so I've decided to follow the suggestion given by @PrzemysławScherwentke:

"And what about the name \cS, as calligraphic S? In standard LaTeX it is not defined."

In fact \cS command, as is shown by @LaRiFaRi (and by \show\cS), is safe:

\cS=undefined.
l.6 \show\cS



• \mathcal{S} surely has some specific meaning in you document? Maybe a macro name reflecting that meaning would be the best choice altogether... – cgnieder Jul 15 '14 at 13:51