convert equation to Cartesian coordinates