[Tex/LaTex] Fast shortcut/way to matrices

environmentsmath-modematrices

I started to TeX my lectures instead of writing them on a paper, usually this is not a big problem. I can handle most of the formulas in little time.

The only problem I have is to write down matrices.
Time spent by the docent to write down a matrix is nearly nil compared to the time I spent typing in: \begin{p + Tab + Enter .

If it would be one or two matrices I could keep up easily.

But the problem with studying mathematics is that if there is one matrix, there are usually a bunch of them following it.

I could try to learn enough TeX Syntax to build this command myself, but as the docent needs nil time writing down a matrix, my free-time as a math-student in the 4th semester is convergent to the same value.


For the tl;dr part of the community

Could somebody help me out building a new shorter command for matrices in a math-environment.

If somebody finds the time to help out.
Thanks

Best Answer

Any editor ought to be able to be customised to add any text such \begin{pmatrix} \end{pmatrix} as a single keystroke, but if you want to do it in tex then

\newcommand\m[1]{\begin{pmatrix}#1\end{pmatrix}} 

then

\m{a&b&c\\x&y&z}

will make a 2 row, 3 column matrix (2,3).