Design of a discrete cosine transform circuit using the residue number system