I have the following code:
\documentclass{article}
\begin{document}
$
M = \bordermatrix{~ & x & y \cr
A & 1 & 0 \cr
B & 0 & 1 \cr}
$
\end{document}
But this code makes a matrix with ()
and i would like it to be with []
How do i do this?
Best Answer
An almost direct modification of
\bordermatrix
:I acted on
\left(
and\right)
, but also changed the value given to\@tempdima
, smaller because brackets are slimmer than parentheses.If you don't want such a messy code, just do
that does exactly the same changes.
A slightly different version where the border entries are set in
\scriptstyle
.