normalize NaN after division that may generate NaN; fix #1712