Update Math.
Fixed some errors.