Solution:
Concept: Perfect squares: A2+2AB+B2=(A+B)2 and A2−2AB+B2=(A−B)2.
Difference of two squares: A2−B2=(A+B)(A−B). Write each term as the square of something, then multiply the sum of the two square roots by their difference.
Step 1 — Group into two perfect squares.
We open the bracket. The terms in c and d make (c+d)2, and the terms in a and b make minus (a−b)2.
2(ab+cd)−a2−b2+c2+d2=(c2+2cd+d2)−(a2−2ab+b2)=(c+d)2−(a−b)2
Step 2 — Use the difference of squares.
With A=c+d and B=a−b, we multiply the sum by the difference.
=[(c+d)+(a−b)][(c+d)−(a−b)]=(c+d+a−b)(c+d−a+b)
Watch out: When B is a bracket, keep it in brackets: A−(B) changes the sign of every term of B.
Therefore, 2(ab+cd)−a2−b2+c2+d2=(c+d+a−b)(c+d−a+b).