GenBoolFromBoolRng

class GenBoolFromBoolRng[A](orig: BoolRng[A]) extends GenBool[A]

Every Boolean rng gives rise to a Boolean algebra without top:

Every Boolean rng gives rise to a Boolean algebra without top:

  • 0 is preserved;
  • ring multiplication (times) corresponds to and;
  • ring addition (plus) corresponds to xor;
  • a or b is then defined as a xor b xor (a and b);
  • relative complement a\b is defined as a xor (a and b).

BoolRng.asBool.asBoolRing gives back the original BoolRng.

See also
trait GenBool[A]
trait Lattice[A]
trait Serializable
class Object
trait Matchable
class Any

Value members

Concrete methods

def and(a: A, b: A): A
override def asBoolRing: BoolRng[A]
Definition Classes
def or(a: A, b: A): A
def without(a: A, b: A): A
def zero: A

Inherited methods

def dual: Lattice[A]

This is the lattice with meet and join swapped

This is the lattice with meet and join swapped

Inherited from
Lattice
def isZero(a: A)(ev: Eq[A]): Boolean
override def join(a: A, b: A): A
Definition Classes
Inherited from
GenBool
def joinPartialOrder(ev: Eq[A]): PartialOrder[A]
Inherited from
JoinSemilattice
override def joinSemilattice: BoundedSemilattice[A]
override def meet(a: A, b: A): A
Definition Classes
Inherited from
GenBool
def meetPartialOrder(ev: Eq[A]): PartialOrder[A]
Inherited from
MeetSemilattice
def meetSemilattice: Semilattice[A]
Inherited from
MeetSemilattice
def xor(a: A, b: A): A

Logical exclusive or, set-theoretic symmetric difference. Defined as a\b ∨ b\a.

Logical exclusive or, set-theoretic symmetric difference. Defined as a\b ∨ b\a.

Inherited from
GenBool