Fix sin/cos output range to -1..1