# Thread: Latex: Determinant

1. ## Latex: Determinant

Hi

I'm trying to add some braces above/below and left/right of a Determinant to describe how many Columns and Rows certain ranges of the matrix has.
For example I have a 2 by 2 Block-matrix. I want a brace over the first and the one over the second column telling me how large each blockdeterminant is.

I hope someone knows a solution to this problem.

2. Plain TeX has a macro called \bordermatrix that lets you put labels above the columns and to the left of the rows. It can give you things like this:

$M = \bordermatrix{&\overbrace{}^{\textstyle m}&\overbrace{}^{\textstyle n}\cr p\{&A&B\cr q\{&C&D\cr}$

Code:
 M = \bordermatrix{&\overbrace{}^{\textstyle m}
&\overbrace{}^{\textstyle n}\cr
p\{ &A&B\cr q\{ &C&D\cr}
As far as I know, there is no LaTeX version of this, so you have to use the plain TeX syntax, with for example \cr instead of \\ for the carriage returns.

3. OPALG, Thank you for your help, but I think that \bracematrix use just for matrix and I want to use for a determinant.

4. Ahem, yes. You'd think I might have noticed that very conspicuous bolded word Determinant

So, the best I can do is a really ugly kludge that produces $\begin{array} {r|@{\hspace{9pt}}c@{\hspace{12pt}}c@{\hspace{9pt} }|} \multicolumn{3}{r@{\hspace{1pt}}}{\overbrace{}^{\t extstyle m} \overbrace{}^{\textstyle n}} \\ p\,\{&A&B\\ q\,\{&C&D \end{array}
$
.

Code:
\begin{array}
{r|@{\hspace{9pt}}c@{\hspace{12pt}}c@{\hspace{9pt}}|}
\multicolumn{3}{r@{\hspace{1pt}}}{\overbrace{}^{\textstyle m}
\overbrace{}^{\textstyle n}} \\  p\,\{&A&B\\ q\,\{&C&D \end{array}
This has the drawback that it isn't well aligned vertically. If you want to put it in a formula like $M = \begin{array} {r|@{\hspace{9pt}}c@{\hspace{12pt}}c@{\hspace{9pt} }|} \multicolumn{3}{r@{\hspace{1pt}}}{\overbrace{}^{\t extstyle m} \overbrace{}^{\textstyle n}} \\ p\,\{&A&B\\ q\,\{&C&D \end{array}$ then you'll want to raise it by putting it into an \hbox along with a \raise command, as in
$M = \raise2ex\hbox{\begin{array}{r|@{\hspace{9pt}}c@{ \hspace{12pt}}c@{\hspace{9pt}}|}\multicolumn{3}{r@ {\hspace{1pt}}}{\overbrace{}^{\textstyle m} \overbrace{}^{\textstyle n}} \\ p\,\{&A&B\\ q\,\{&C&D \end{array}}$.