Apply pythagorean identity.

Reorder and .

Factor out of .

Rewrite as .

Factor out of .

Apply pythagorean identity.

Rewrite using the commutative property of multiplication.

Rewrite in terms of sines and cosines.

Apply the product rule to .

Factor out of .

Cancel the common factor.

Rewrite the expression.

Simplify (1-sin(x)^2)(1-sec(x)^2)