Definition contraction a b k := k *: (b - a) + a.

Lemma vector2_neq0 (v : 'rV[R]_(2)) : (v != 0) = (v 0 0 != 0) || (v 0 1 != 0).
Definition sqr_L2_norm_2D a b :=
(b 0 0 - a 0 0) ^+ 2 + (b 0 1 - a 0 1) ^+ 2.