Unix Support

How Computers Handle Numbers

This could be called "Computer Arithmetic Uncovered". It will describe how computers store and process integers and floating point numbers, and also the exceptions that might arise and what they mean. The intent is to explain how modern computers handle numbers, and how to get reliable answers for a reasonable amount of effort.

The presentation and notes for the basic course:

People should read these before looking at any of the other references.


Notes, intended for reading

The four-lecture course on floating-point computation currently given by Prof. A. Mycroft to computer scientists:

Floating Point Computation

Copies of the (unmaintained) numerical analysis course given for many years by Dr. M.R. O'Donohoe to computer scientists:

Basic numerical analysis course notes

Advanced numerical analysis course notes

Extra presentation foils, giving some of the sordid details, an example of using C99's error handling portably, and a test program that shows one problem with Annex G:

Most people should NOT read these, as the course describes how to avoid getting caught up in these messes.

Extra presentation foils

How to handle numeric errors in C99

A test program to show Annex G's problems

The title of this document is: How Computers Handle Numbers
URL: http://www-uxsup.csx.cam.ac.uk/courses/moved.Arithmetic/index.html