I would like to use the "\mathcal symbols" from txfonts, but otherwise use the standard symbols. Including the package txfonts changes all fonts, which I would like to avoid. The command


uses all math symbols from txfonts, but I think that they are too thick (and the quantors look ugly), especially compared to the usual text font computer modern. Probably


should work, where TX has to be replaced by the correct family name of txfonts. Which is the correct one? I've already tried some names, but so far none has worked.


2 Answers 2


It's as easy as this:


\DeclareMathAlphabet{\mathcal}{OMS}{ntxsy}{m}{n}   % or txsy
\SetMathAlphabet{\mathcal}{bold}{OMS}{ntxsy}{b}{n} % or txsy



enter image description here

Explanation. The TX/NewTX packages do no change to the basic math font setup, where \mathcal is defined by


in order not to waste a math group. For your purpose a new math group is obviously necessary, so we just need to look in newtxmath.sty what's the definition of the symbols math symbol font and we find

178 \DeclareSymbolFont{symbols}{OMS}{ntxsy}{m}{n}
179 \SetSymbolFont{symbols}{bold}{OMS}{ntxsy}{b}{n}

(line numbers added for reference). So it's sufficient to change \DeclareSymbolFont{symbols} with \DeclareMathAlphabet{\mathcal} and \SetSymbolFont{symbols} with \SetMathAlphabet{\mathcal}.

It's better to use the fonts provided by NewTX that have refined metrics with respect to the older TX package and also is actively maintained, contrary to the old package.

  • So for this solution one needs newtx? I've already tried to install this before, but failed. Mar 6, 2015 at 0:20
  • @MartinBrandenburg You can use txsy, if you want, but my advice is to install a complete recent TeX distribution that has NewTX out of the box. Installing font packages over an old TeX distribution is always a PITA.
    – egreg
    Mar 6, 2015 at 0:21
  • Ok. I had already tried to use "txsy", but just the encoding was wrong ... Mar 6, 2015 at 0:23
  • Out of curiosity: Is it possible to use single symbols from txfont, for example, say, $\otimes$? Mar 6, 2015 at 0:28
  • 1
    @MartinBrandenburg Yes, of course. Not really easy, but this question has the needed answers: Importing a Single Symbol From a Different Font. In case \otimes belongs to the symbols math group, the approach with \DeclareSymbolFont and \DeclareSymbolFontAlphabet will become necessary in order not to waste math groups.
    – egreg
    Mar 6, 2015 at 0:30

The standard definition of \mathcal is in fontmath.ltx:

\DeclareSymbolFontAlphabet{\mathcal}   {symbols}

So, to use a different font, we need to do two things:

  • define a new symbol font, with a distinct name (because we don't want everything else to come from the txfonts symbol font);
  • redefine \mathcal so that it uses the new font.

So, let's use symbolstx for the new font. Looking for the definition of symbols in txfonts.sty, we find:


So, we just need to adapt these lines to specify symbolstx rather than symbols:


Then we can define \mathcal accordingly:


Putting it altogether:







modified calligraphic maths

  • Three lines instead of just two. ;-). But it's better to use ntxsy, which has better metrics.
    – egreg
    Mar 6, 2015 at 0:19
  • @egreg But is not what the OP asked for ;). Not that it isn't true....
    – cfr
    Mar 6, 2015 at 0:22

You must log in to answer this question.

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