Solution (source code)

= Solution

The <positive part of a Hermitian operator> and <negative part of a Hermitian operator> are the positive operators
$$
\boxed{X_+=\sum_i\max(\lambda_i,0)|\alpha_i\rangle\langle\alpha_i|,\qquad X_-=\sum_i\max(-\lambda_i,0)|\alpha_i\rangle\langle\alpha_i|.}
$$
Thus $X=X_+-X_-$ and $X_+X_-=0$. In this convention the negative part itself is nonnegative. This is the <positive-negative decomposition> of the <Hermitian operator>.

The <operator absolute value> is defined by the unique <positive operator> square root
$$
|X|=\sqrt{X^\dagger X}=\sqrt{X^2}=\sum_i|\lambda_i|\,|\alpha_i\rangle\langle\alpha_i|.
$$
The scalar identity $|\lambda|=\max(\lambda,0)+\max(-\lambda,0)$ applied in the <spectral decomposition> proves
$$
\boxed{|X|=X_++X_-.}
$$