Fix division-by-zero bug
Clean up division by zero fix
Merge pull request #1 from yang/div-by-zero

Fix division-by-zero bug