Writing Trig Functions as Algebraic Expressions