8

I would like to use bold symbols in superscript equations. To do so, I use \displaystyle as in

\documentclass{standalone}
\usepackage{amsmath}
\begin{document}
    $e^{\mathbf{A}t}=e^{\displaystyle \mathbf{A}t}=e^{{\displaystyle \mathbf{A}}t}$
\end{document}

The corresponding output is:

good output with cmroman

The first exponential is exactly what I'm looking for.

Now, if I add the cmbright package, the corresponding code

\documentclass{standalone}
\usepackage{amsmath}
\usepackage{cmbright}
\begin{document}
    $e^{\mathbf{A}t}=e^{\displaystyle \mathbf{A}t}=e^{{\displaystyle \mathbf{A}}t}$
\end{document}

yields:

image showing problem with cmbright

As one can see, in the left exponential the A symbol is not bold, and the other symbols are larger (as expected with \displaystyle).

I guess there is a pretty simple explanation about cmbright but I am not aware of it. Any clues to get the bold symbol AND the normal size with cmbright?

1
  • Try \mathbold{}.
    – Sigur
    Commented Jul 30, 2014 at 22:25

2 Answers 2

8

For mysterious reasons, the .fd file for the OT1 encoding defines a substitution rule for the bold font at sizes less than 9pt and chooses a non bold font, instead of scaling the only available font (at 10pt).

Cure it by redefining the font shapes.

\documentclass[border=3pt]{standalone}
\usepackage{amsmath}
\usepackage{cmbright}

\DeclareFontFamily{OT1}{cmbr}{\hyphenchar\font45 }
\DeclareFontShape{OT1}{cmbr}{m}{n}{%
  <-9>cmbr8
  <9-10>cmbr9
  <10-17>cmbr10
  <17->cmbr17
}{}
\DeclareFontShape{OT1}{cmbr}{m}{sl}{%
  <-9>cmbrsl8
  <9-10>cmbrsl9
  <10-17>cmbrsl10
  <17->cmbrsl17
}{}
\DeclareFontShape{OT1}{cmbr}{m}{it}{%
  <->ssub*cmbr/m/sl
}{}
\DeclareFontShape{OT1}{cmbr}{b}{n}{%
  <->ssub*cmbr/bx/n
}{}
\DeclareFontShape{OT1}{cmbr}{bx}{n}{%
  <->cmbrbx10
}{}


\begin{document}

$\mathbf{A}\mapsto e^{\mathbf{A}t}$

\end{document}

enter image description here

2
  • This answers my question even more accurately than Sigur's, but I already accepted Sigur answer... Thank you
    – anderstood
    Commented Jul 30, 2014 at 22:44
  • @anderstood, it is up to you. Feel free. We all learn a lot with egreg's posts.
    – Sigur
    Commented Jul 30, 2014 at 22:57
6

From the documentation cmbright package you can use the \mathbold{} command.

But the A is in italic shape.

enter image description here

5
  • The fact that A becomes italic seems more logical to me :) Is there any drawbacks to replace all \mathbf commands with \mathbold?
    – anderstood
    Commented Jul 30, 2014 at 22:38
  • 1
    You can try \renewcommand{\mathbf}[1]{\mathbold{#1}}
    – Sigur
    Commented Jul 30, 2014 at 22:45
  • I did so and did not see any drawbacks in my present document, but maybe you knew some which could cause me trouble in the future, if I stopped using \mathbf.
    – anderstood
    Commented Jul 30, 2014 at 22:52
  • 1
    If you stop using cmbright package the command \mathbold would not be defined anymore and then you simply comment that line with %.
    – Sigur
    Commented Jul 30, 2014 at 22:56
  • Thanks for making me be aware of the \mathbold command. I got used to it, but never understood why bold symbols became non-italic! Now I'll try to get used to this more logical typo.
    – anderstood
    Commented Jul 30, 2014 at 22:59

You must log in to answer this question.

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