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

I'm trying to make a PDF manual for matrix multiplication with LaTeX. I'd like to generate a graphic similar to this one (from Wikipedia/Matrix multiplication):

Matrix multiplication

I guess this will be quite a bit of work, but is there another way than using the eepic package? I have read into some examples and the manual, and it seems very complex to generate a graphic like this with that package.

If there is no other way, I'll have to use eepic, but I hope someone here could point me to a package or another way.

share|improve this question
This reminds my on TikZ (finite) grid with character in each cell, but using matrices as Stefan suggested might be better. – Martin Scharrer Apr 18 '11 at 20:22
up vote 13 down vote accepted

I recommend to use TikZ and its matrix library, specifically the matrix of math nodes feature. TikZ offers a great and comprehensive manual.

Have a look at this example and its source code, written by Alain Matthes, in the TikZ example gallery: Matrix multiplication. It deals exactly with your subject.

matrix example

share|improve this answer
Wow. This really is /exactly/ what I'm looking for. I'll translate the few words into German and I'm done. Way prettier than I thought ever possible. Thanks a ton :) – Alexx Hardt Apr 18 '11 at 20:34

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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