let (u, n) = splitUnit r in r == u * n && fst (splitUnit n) == one && isUnit u
This condition is too weak and can be always be satsified by splitUnit r = (one,r). EuclideanDomain should inherit from DecidableAssociates and, letting (u',n') = splitUnit r', the specification should require that n == n' <-> isAssociate r r'.
splitUnit
is currently specified as follows:This condition is too weak and can be always be satsified by
splitUnit r = (one,r)
.EuclideanDomain
should inherit fromDecidableAssociates
and, letting(u',n') = splitUnit r'
, the specification should require thatn == n' <-> isAssociate r r'
.