improve numeric precision of sigmoid