An Introduction to Arithmetic Coding