% bigdelim.sty 
% version 1.0
% Nov 5, 1999
% Piet van Oostrum <piet@cs.uu.nl>
% From bigbrace.sty : Oct 2, 1994 \Oystein Bache <bache@kjemi.unit.no>
%         from: \dobrace by piet@cs.ruu.nl (Piet van Oostrum): 
%%
%% This file may be distributed under the terms of the LaTeX Project Public
%% License, as described in lppl.txt in the base LaTeX distribution.
%% Either version 1 or, at your option, any later version.
%%
%
% Usage in a tabular or array:
% \usepackage{multirow}
% \usepackage{bigdelim}
% \ldelim({n}{w}[text]
% \rdelim){n}{w}[text]
% Use these commands in a column of a tabular or array. They generate a big
% parenthesis/brace extending over the next n rows (including this one).
% The corresponding entries in the next rows must explicitely be given as
% empty cells. The first parameter must be the delimiter to be used, e.g.
% \{ \} [ ] ( ), in fact any parameter that can be used with \left and
% \right. The text is optional and is set centered to the left of
% \ldelim and to the right of \rdelim.  w must be the width reserved for
% the brace and text.  If you have a recent version of multirow.sty {w} may
% be given as {*}, but this may cause the braces to be too small. Also with
% a recent version of multirow.sty the commands may be used in the last row
% of the extension with a negative n parameter. This is useful in
% combination with the colortbl package (see multirow.sty)
% If there are unusually large rows you may have to enlarge n (you can use
% non-integral values). 
% If you have horizontal lines that interact with the braces you are
% advised to use the hhline package to make the lines.

\def\ldelim#1#2#3{\@ifnextchar[{\@ldelim{#1}{#2}{#3}}{\@ldelim{#1}{#2}{#3}[\null]}}
\def\@ldelim#1#2#3[#4]%
 {\multirow{#2}{#3}{%
   \ensuremath
     {\left.\vcenter{\hsize=0pt\vrule height 
           \ifnum #2<0 -\fi#2\baselineskip width 0pt}%
     \textrm{#4}\right#1}}}
%
\def\rdelim#1#2#3{\@ifnextchar[{\@rdelim{#1}{#2}{#3}}{\@rdelim{#1}{#2}{#3}[\null]}}
\def\@rdelim#1#2#3[#4]%
 {\multirow{#2}{#3}{%
   \ensuremath
     {\left#1\vcenter{\hsize=0pt\vrule height 
           \ifnum #2<0 -\fi#2\baselineskip width 0pt}%
       \textrm{#4}\right.}}}
%
\endinput
%
% Example:
\documentclass{article}
\usepackage{multirow}
\usepackage{bigdelim}
\begin{document}

\begin{equation}
  \begin{array}{ccccccc}
    \ldelim({4}{4mm}& x & x & x & x &\rdelim){4}{4mm}  \\
    & x & x & x & x &  & i\\
    & x & x & x & x &  & j\\
    & x & x & x & x &  \\
    &   & u & v &  & 
  \end{array}
\end{equation}
\end{document}
