Methods isId, isZero, isOne for Monoid, AdditiveMonoid and MultiplicativeMonoid respectively, using generalized type constraints.