In step A, you replace all trigonometric functions with their definitions in terms of sine and cosine.
In step B, you add the two together as you add fractions.
In step C, you replace 1 with the sum of the squares of sine and cosine.
In step D, you add the cosine terms together so they disappear.
In step E, finally, you divide numerator and denominator by .