# LaTeX How to bold in latex

Tags:
1. Apr 2, 2014

### joshmccraney

hi pf!

can someone help me bold in latex. for some reason if i use \textbf{pi} if get $\textbf {pi}$ but if i use \textbf {\pi} i do not get a bold $\pi$ but only an error. i have also tried \bfseries and no luck.

2. Apr 2, 2014

### AlephZero

\pi only works in math node, e.g. $\pi$. \textbf only works in text mode (as you might guess from the name).

But "standard" LaTeX doesn't have bold lower case Greek letters anyway, so you have to do something like

Code (Text):

\usepackage{bm}
...
$\bm{\pi}$

or if you are using the AMS math package,
Code (Text):

\usepackage{amsbsy}
...
$\boldsymbol{\pi}$

3. Apr 2, 2014

### joshmccraney

thanks a ton!

4. Apr 3, 2014

### Staff: Mentor

That's actually incorrect. All math symbols can be set in bold in LaTeX, but in very contrived way. You have to activate \boldmath, but then all math will be typeset in bold! The way around that is something like
Code (Text):
\mbox{\boldmath $\pi$}
such that the \boldmath will only affect equations inside the mbox. If you want just one bold symbol in an equation, you have to use the awful construct
Code (Text):
$2 \alpha \mbox{\boldmath$\beta$}$
LaTeX being so well thought out from a typographical point of view, I don't know why they messed up with bold.

Anyway, the conclusion is that it is better to use the additional packages you suggested.

5. Apr 3, 2014

### AlephZero

After a bit of research, I agree with you. There are plenty of statements on (usually reputable) websites that \boldmath is "part of plain TeX". But it's not in the index of Knuth's TeXBook, and those statements seem to be wrong.

It is defined in the "base" TeX code of LaTeX. It's not quite obvious how it's defined but it looks like it redefines all the math font names to bold versions. That may not work with all math fonts, or with newer versions of TeX that handle fonts in a completely different way (e.g. direct access to Unicode and/or the internals of Open Type fonts).

And as you say, \boldmath is not nice to use, if you want to mix bold and non-bold characters in the same math formula.

It was very well thought out, and forward looking, when it was first released. But that was 36 years ago. With hindsight, too many implementation-specific details were hard-wired into it - like the fact that it was designed to run on 16-bit computer hardware, not 64-bit.

Last edited: Apr 3, 2014