Using the trig identities for substituting a Pythagorean looking expression.