Symmetric and antisymmetric parts of a matrix (source code)

= Symmetric and antisymmetric parts of a matrix

Over a <field> of <characteristic> different from two, every square <matrix> decomposes uniquely as
$$
A=S+K,\qquad S=\frac{A+A^T}{2},\quad K=\frac{A-A^T}{2}.
$$
Here $S$ is a <symmetric matrix> and $K$ is a <skew-symmetric matrix>. Transposing proves those properties. For uniqueness, a <matrix> in both classes satisfies $M=M^T=-M$, hence $2M=0$ and $M=0$. This is a <direct sum> decomposition of the <vector space> of square <matrices>. In <characteristic two>, division by two is unavailable and the two classes coincide, so the same decomposition statement fails.