MathJax based solution (with jsfiddle ):
<script src= "http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS_HTML"> </script> \[\begin{bmatrix} 1+3\mathrm{i} & 2+\mathrm{i} & 10\\ 4-3\mathrm{i} & 5 & -2 \end{bmatrix}\]
It seems that MathJax is increasingly being used to display mathematical formulas on web pages. The above example uses a version of the LaTeX approach. MathJax is based on client-side JavaScript, but this drawback is probably outweighed by the benefits.
Using \bmatrix creates a matrix with parentheses. The primary entry for matrices, according to ISO 80000-2, uses parentheses; to do this, use \pmatrix instead.
I used \mathrm{i} to create an unialized "i" according to the standard. Many mathematicians still prefer italics here, achievable, using only i instead, since LaTeX highlights identifiers by default. Please note that LaTeX automatically applies the correct distance around the operators and turns the hyphen "-" into a minus sign.
Jukka K. Korpela
source share