In order to compute the average of two dyadic digits
it is necessary to compute the value
with the property that (x,y) is a dyadic digit (ie. x is odd or (x,y) = (0,0)).
We examine the powers of the denominators b and d and come up with three different cases.
However as a and c are odd or zero, (a + c) may be even, or (a+c,b+1) may have a zero first element and non-zero second element. Therefore it is necessary to apply the function described in section A.1 to the pair (a+c,b+1).
Using an almost identical approach, it is possible to define similar functions for finding the average of one digit with the negation of another, addition or subtraction of two digits (with the caveat that if the result of the addition or subtraction is not in the range [-1,1], the pair returned will not be a valid dyadic digit), and other combinations such as addition or subtraction of two dyadic digits (a,b) where a pair of digits (x,y) is returned with the property that: