My document currently uses TeX Gyre Termes as the main text font and Computer Modern for math. I would like to continue using Computer Modern for math mode symbols, operators, and greek, but replace the normal roman and italic alphanumeric characters (a-z A-Z 0-9) with the corresponding ones from the text font.

In short, I would like to go from the above equation to the below equation.

math with text font

The code for the mockup perhaps helps to illustrate the point further:

I would like to go from this,
    2 \, \alpha \, v \begin{pmatrix}
        \cos(t) \\
    \end{pmatrix} \;,
to this,
    \mbox{2} \, \alpha \, \mbox{\textit v} \begin{pmatrix}
        \mbox{cos}(\mbox{\textit t}) \\
        \mbox{sin}(\mbox{\textit t})
As you can see, the number 2, the italic ``\textit{v}'' and ``\textit{t}'', and
the upright ``cos'', ``sin'' are taken from the main text font.

Unfortunately, I do not know the correct terminology to refer to these different types of fonts, which makes searching for a solution that much harder.

  • Welcome to TeX SX! In the opinion of many (including me), mixing Times and Computer Modern is hideous!
    – Bernard
    Jul 12, 2016 at 9:51
  • I do not disagree, @Bernard.
    – user109906
    Jul 12, 2016 at 9:53
  • Why don't you use \usepackage{newtxtext,newtxmath}? It's mainly based on TeX Gyre Termes, and the fonts will be consistent.
    – Bernard
    Jul 12, 2016 at 9:56
  • 1
    Unfortunately, I need to match the style of a prior work, which uses this rather odd combination of symbols. And some symbols in Times, especially the bold greek, stick out as completely different.
    – user109906
    Jul 12, 2016 at 10:03
  • 1
    The operators (sums, integrals) are conspicuously Computer Modern as well, unfortunately. As it is, the difference between what I get and what I try to mimic is much less noticeable then what it would be for newtxmath with CM greek.
    – user109906
    Jul 12, 2016 at 10:12

1 Answer 1


By chance, I found the answer in a comment to an unrelated question.

There is a mathastext package that

uses a text font (usu­ally the doc­u­ment’s text font) for the let­ters of the Latin al­pha­bet needed when type­set­ting math­e­mat­ics. (Op­tion­ally, other char­ac­ters in the font may also be used).

There are a number of examples available in the showcase.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy