fixed some div-by-zeros