added throw exception if number isNaN...