I'm attempting to write out the bases of a matrix but I can't seem to get the formatting as I'd like it. I have looked online and I haven't come to an easy solution.

Here is my work around.

\fancyhf{} % sets both header and footer to nothing
\newcommand\descitem[1]{\item{\bfseries #1}\\}

\item Find the change-of-coordinates matrix from $\mathcal{B}$ to the standard basis in $\mathbb{R}^n$.\\
  \mathcal{B} = \Bigg\{\begin{bmatrix} 3 \\ -1 \\ 4 \end{bmatrix},\begin{bmatrix} 2 \\ 0 \\ -5 \end{bmatrix},\begin{bmatrix} 8 \\ -2 \\ 7 \end{bmatrix}\Bigg\}

The desired result looks something like this.

desired result

What I am currently getting.

not pretty

2 Answers 2


A few notes:

  • Only load the packages you are actually using in your document.
  • Load mathtools instead of amsmath to use the bmatrix* environment, which allows right-justification
  • Use \left and \right to size your braces when you need them bigger than \Bigg, but use \Biggl and \Biggr for proper spacing when you do use \Bigg.
  • Don't use \\ at the end of \item
  • \equation* has the same meaning as \[ ... \]

enter image description here


\usepackage{amssymb} % for \mathbb
\usepackage{mathtools} % for bmatrix*
\usepackage{lmodern} % slight shape changes

\item Find the change-of-coordinates matrix from $\mathcal{B}$ to the standard basis in $\mathbb{R}^n$.
  \mathcal{B} = \left\{\begin{bmatrix*}[r] 3 \\ -1 \\ 4 \end{bmatrix*},
  \begin{bmatrix*}[r] 2 \\ 0 \\ -5 \end{bmatrix*},
  \begin{bmatrix*}[r] 8 \\ -2 \\ 7 \end{bmatrix*}\right\}
  • Actually, amsmath recommends using equation* instead of \[...\], for the simple reason that it's easier to remove/insert the * to add/remove the equation number.
    – egreg
    Apr 24, 2022 at 8:35

Commands like \big, \Bigg etc. manually define the size of your braces and delimiters. So you will only ever get one size of a bracket per command. Using \left\{ ... \right\} will dynamically resize the brackets to fit what is inside.

This is what i personally use so that i do not have to guess the correct sizes.

  • In general, always using \left/right is not a good idea as there are many situations where the generated size is inappropriate
    – daleif
    Apr 24, 2022 at 8:58

You must log in to answer this question.

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