Module
Test.QuickCheck.Laws.Data.EuclideanRing
- Package
- purescript-quickcheck-laws
- Repository
- purescript-contrib/purescript-quickcheck-laws
#checkEuclideanRing Source
checkEuclideanRing :: forall a. EuclideanRing a => Arbitrary a => Eq a => Proxy a -> Effect Unit
- Integral domain:
one /= zero
, and ifa
andb
are both nonzero then so is their producta * b
- Euclidean function
degree
:- Nonnegativity: For all nonzero
a
,degree a >= 0
- Quotient/remainder: For all
a
andb
, whereb
is nonzero, letq = a / b
andr = a `mod` b
; thena = q*b + r
, and also eitherr = zero
ordegree r < degree b
- Nonnegativity: For all nonzero
- Submultiplicative euclidean function:
- For all nonzero
a
andb
,degree a <= degree (a * b)
- For all nonzero
#checkEuclideanRingGen Source
checkEuclideanRingGen :: forall a. EuclideanRing a => Eq a => Gen a -> Effect Unit
- Modules
- Test.
QuickCheck. Laws - Test.
QuickCheck. Laws. Control - Test.
QuickCheck. Laws. Control. Alt - Test.
QuickCheck. Laws. Control. Alternative - Test.
QuickCheck. Laws. Control. Applicative - Test.
QuickCheck. Laws. Control. Apply - Test.
QuickCheck. Laws. Control. Bind - Test.
QuickCheck. Laws. Control. Category - Test.
QuickCheck. Laws. Control. Comonad - Test.
QuickCheck. Laws. Control. Extend - Test.
QuickCheck. Laws. Control. Monad - Test.
QuickCheck. Laws. Control. MonadPlus - Test.
QuickCheck. Laws. Control. Plus - Test.
QuickCheck. Laws. Control. Semigroupoid - Test.
QuickCheck. Laws. Data - Test.
QuickCheck. Laws. Data. BooleanAlgebra - Test.
QuickCheck. Laws. Data. Bounded - Test.
QuickCheck. Laws. Data. BoundedEnum - Test.
QuickCheck. Laws. Data. CommutativeRing - Test.
QuickCheck. Laws. Data. DivisionRing - Test.
QuickCheck. Laws. Data. Enum - Test.
QuickCheck. Laws. Data. Eq - Test.
QuickCheck. Laws. Data. EuclideanRing - Test.
QuickCheck. Laws. Data. Field - Test.
QuickCheck. Laws. Data. Foldable - Test.
QuickCheck. Laws. Data. Functor - Test.
QuickCheck. Laws. Data. FunctorWithIndex - Test.
QuickCheck. Laws. Data. HeytingAlgebra - Test.
QuickCheck. Laws. Data. Monoid - Test.
QuickCheck. Laws. Data. Ord - Test.
QuickCheck. Laws. Data. Ring - Test.
QuickCheck. Laws. Data. Semigroup - Test.
QuickCheck. Laws. Data. Semiring