modify divide by function