Let $A, B, C, D$ be four points in space. Prove
$$|AB|^2 + |CD|^2 -|BC|^2 - |AD|^2 = 2\cdot \vec{AC}\cdot \vec{DB}$$
Clearly,
$$AB = B-A$$
$$CD = D-C$$
$$AD = D-A$$
If I directly substitute the values, ignoring the distance operator, I get:
$$|AB|^2 + |CD|^2 -|BC|^2 - |AD|^2=(B-A)^2 + (D-C)^2 - (C-B)^2 - (D-A)^2$$
$$=B^2 + A^2 -2BA + D^2 + C^2 -2DC -C^2 - B^2 + 2CB - D^2 - A^2 + 2DA$$
$$= 2(CB + DA - DC - BA)$$
$$= 2(B-C+A-D-C+D-A+B) = 4(B - C) = 4\vec{AB}$$
But I'm not sure I can ignore the distance operator like that. Specifically, can I state that:
$$|AB|^2 = (B-A)^2$$
can you give reasons?