The bm package
Provides \bm, which sets any math symbol in bold and keeps its shape, including Greek letters and operators.
Loading the package
\usepackage{bm}\mathbf switches to an upright bold text font. It changes Latin letters and digits, but \mathbf{\alpha} prints a normal alpha. \bm takes the bold version of the same symbol: \bm{v} is a bold italic v, \bm{\alpha} a bold alpha, \bm{\nabla} a bold nabla.
The usual application is vectors, matrices and tensors. Define one command for them, for example \newcommand{\vect}[1]{\bm{#1}}, so the notation can be changed in one place.
bm also redefines \boldsymbol from amsmath as \bm.
Main commands
\bm{v} | Bold italic letter. |
\bm{\alpha} | Bold Greek letter. |
\bm{\nabla} | Bold operator or symbol. |
\bm{A}_{ij} | Only the argument turns bold; the indices stay normal. |
\newcommand{\vect}[1]{\bm{#1}} | A vector command of your own, built on \bm. |
Complete example
\documentclass{article}
\usepackage{amsmath}
\usepackage{bm}
\newcommand{\vect}[1]{\bm{#1}}
\begin{document}
Newton's second law: $\vect{F} = m \vect{a}$.
\[
\bm{\nabla} \cdot \vect{E} = \frac{\rho}{\varepsilon_0},
\qquad
\bm{\sigma} = \bm{C} \bm{\varepsilon}
\]
Compare $\mathbf{v}$ with $\bm{v}$, and $\mathbf{\alpha}$ with $\bm{\alpha}$.
\end{document}Compiled with pdfLaTeX from TeX Live 2023.
Pitfalls
\bmin a section title together withhyperrefstops the run with "Illegal parameter number in definition of \Hy@tempa". Write\section{The vector \texorpdfstring{$\bm{v}$}{v}}.bmdoes not work withunicode-math. Use\symbfthere.
Related pages
- How-to Bold math symbols in LaTeX
- How-to Vectors in LaTeX
- How-to Math fonts in LaTeX
- Package
amsmath