Updated code to use the new generalized number hirarchy of the boolean package.