In: Physics
Single precision checksum is formed by adding the data words and ignoring the overflow.
0111+0001+0110+1000=0110(checksum) (carry is ignored)
The single precision checksum is unable to detect some errors. The received checksum and the checksum of original data are same and so no error is detected.
Original data
0111+0001+0110+1000=1110(checksum)
Received data
1111+1001+1110+1000=1110(checksum of received data).
A double precision checksum is done by adding the data by double precision arithmetic. Here the received checksum and checksum of received data are not equal and hence error is detected.
Original data
0111+0001+0110+0000=0000 | 1110 (checksum)
Received data
1111+1001+1110+1000= 0010 | 1110 (checksum of received data)
Residue checksum
Residue checksums are similar to the single precision checksums except that the most significant bit position is not ignored but is added back to the checksum in an end around carry fashion.
Carry from
addition----
|
Word1+ word2+...+word n= sum of data = checksum
The residue checksum is formed by end around carry addition so that the information in the carry bit is not lost.
00010111
0001
0110
1000