Matrix multiplication with LaTeX
Alexx Hardt asked on TeX.SX:
How can I draw a diagram for matrix multiplication with LaTeX?
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):
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.
Answer:
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.