This appendix develops primitive operations on the dyadic digits defined in chapter 3, and used extensively in chapter 4. The algorithms assume a representation of dyadic digits as pairs of integers (see section 6.2.5). Other representations will require different algorithms.
We show how to convert a dyadic rational into its lowest terms, perform primitive operations, and perform equality and other relational tests on pairs of dyadic digits. Division is not closed over the dyadic digits (unlike dyadic rationals), and is not required as a primitive operation.