5

I'd like to use mathdesign but I still want regular old mathcal. In this question it was suggested to use

\let\mathcal\undefined
\DeclareMathAlphabet{\mathcal}{OMS}{cmsy}{m}{n} 

which works fine with \documentclass{amsart}. But I want to use svjour . I get an error message not when I first use \mathcal but when I use it, have a section break, and then use it again. Here is a minimal working example:

\documentclass [invmat]{svjour} 
\usepackage[garamond]{mathdesign}
\let\mathcal\undefined
\DeclareMathAlphabet{\mathcal}{OMS}{cmsy}{m}{n} 
\begin{document}
$\mathcal{R}$
\section{New Section}
$\mathcal{S}$
\end{document}

The error I get is

Use of \reserved@a doesn't match its definition. [$\mathcal{S}]
Undefined control sequence. [$\mathcal{S}]

repeated several times and then

LaTeX Error: Too many math alphabets used in version normal. [$\mathcal{S}]
3
  • Where do we get this svjour?
    – LaRiFaRi
    Mar 31 '15 at 15:30
  • 1
    Curious interaction between svjour and mathdesign; it works if you use a different name, say \DeclareMathAlphabet{\mcal}{OMS}{cmsy}{m}{n}
    – egreg
    Mar 31 '15 at 15:31
  • @LaRiFaRi, I added a link. Mar 31 '15 at 15:35
4

There is a strange interaction between svjour and mathdesign: they fight each other over \mathcal and you lose.

Use a different name:

\DeclareMathAlphabet{\mcal}{OMS}{cmsy}{m}{n}
\SetMathAlphabet{\mcal}{bold}{OMS}{cmsy}{b}{n}

Example (with svjour3, but it should be the same):

\documentclass{svjour3}
\usepackage[garamond]{mathdesign}

\DeclareMathAlphabet{\mcal}{OMS}{cmsy}{m}{n}
\SetMathAlphabet{\mcal}{bold}{OMS}{cmsy}{b}{n}

\begin{document}
$\mcal{R}$
\section{New Section $\mcal{X}$}
$\mcal{S}$
\end{document}

enter image description here

Actually it's not a specific problem with svjour; the following example shows the same issue:

\documentclass{article}
\usepackage[garamond]{mathdesign}

\let\mathcal\relax
\DeclareMathAlphabet{\mathcal}{OMS}{cmsy}{m}{n}

\begin{document}

$\mathcal{R}${\boldmath}$\mathcal{T}$
\end{document}

The declaration \boldmath is automatically issued by \section in the svjour class, and it's the cause of the problem. The culprit is apparently mathdesign


Update

The mathdesign package has a peculiar strategy for defining \mathcal: it defines it with \DeclareSymbolFont and \DeclareSymbolFontAlphabet. This is obviously wrong, as the mathgroup associated to it is wasted even if \mathcal is never used in the document.

In your case it makes no difference, as you do use \mathcal.

\documentclass{svjour3}
\usepackage[garamond]{mathdesign}

\DeclareSymbolFont{cmcal}{OMS}{cmsy}{m}{n}
\SetSymbolFont{cmcal}{bold}{OMS}{cmsy}{b}{n}
\DeclareSymbolFontAlphabet{\mathcal}{cmcal}

\begin{document}

$\mathcal{R}$
\section{New Section $\mathcal{X}$}
$\mathcal{T}$

\end{document}

This produces the same output as above.

4
  • Any insight as to why this happens? Mar 31 '15 at 15:47
  • @GabrielC.Drummond-Cole Not yet. I'll try again, but I don't think it's worthy a thorough effort: svjour should only be used for submissions to Springer and I don't think they will like you using mathdesign with Garamond.
    – egreg
    Mar 31 '15 at 15:50
  • I agree, but I'm editing this document for someone else who has his own idiosyncrasies, including this unorthodox preference. Mar 31 '15 at 15:53
  • 1
    @GabrielC.Drummond-Cole Found! :-D
    – egreg
    Mar 31 '15 at 16:17

This site is temporarily in read only mode and not accepting new answers.

Not the answer you're looking for? Browse other questions tagged .