TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Possible Duplicate:
bordermatrix with blocks

I need to put a vertical line between two columns of a matrix in \bordermatrix. I know how to do it in the array environment, but \bordermatrix isn't the same. Does anyone know how?

share|improve this question

marked as duplicate by egreg, Werner, Joseph Wright Dec 19 '11 at 19:21

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

Welcome to TeX.sx! Usually, we don't put a greeting or a "thank you" in our posts. While this might seem strange at first, it is not a sign of lack of politeness, but rather part of our trying to keep everything very concise. Upvoting is the preferred way here to say "thank you" to users who helped you. – Torbjørn T. Dec 14 '11 at 8:28
\def\VR{\kern-\arraycolsep\strut\vrule &\kern-\arraycolsep}
\def\vr{\kern-\arraycolsep & \kern-\arraycolsep}

   & 0 & 1 & 2 \cr
 0 & A & B & C \cr
 1 & d & e & f \cr
 2 & 1 & 2 & 3 }$
   & 0 & \vr 1 & 2 \cr
 0 & A & \VR B & C \cr
 1 & d & \VR e & f \cr
 2 & 1 & \VR 2 & 3 }$


enter image description here

share|improve this answer

You can use the package kbordermatrix. You need to install manually because this package is not in TL or CTAN. The documentation is inside the package.

enter image description here

Complete code



enter image description here

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.