algebraixlib.algebras.couplets module

This module contains the algebra of couplets and related functionality.

class algebraixlib.algebras.couplets.Algebra[source]

Bases: object

Provide the operations and relations that are members of the algebra of couplets.

This class contains only static member functions. Its main purpose is to provide a namespace for and highlight the operations and relations that belong to the algebra of couplets. All member functions are also available at the enclosing module scope.

static transpose(couplet: '(M x M)', _checked=True) → '(M x M)'[source]

Return the transposition of couplet (right and left components swapped).

Returns:The transposition of couplet or Undef() if couplet is not an instance of Couplet.
static compose(couplet1: '(M x M)', couplet2: '(M x M)', _checked=True) → '(M x M)'[source]

Return the composition of couplet1 with couplet2.

Returns:The composition of couplet1 with couplet2 (which may be undefined, in which case the result is Undef()) or Undef() if couplet1 or couplet2 are not instances of Couplet.
algebraixlib.algebras.couplets.transpose(couplet: '(M x M)', _checked=True) → '(M x M)'

Convenience redirection to Algebra.transpose.

algebraixlib.algebras.couplets.compose(couplet1: '(M x M)', couplet2: '(M x M)', _checked=True) → '(M x M)'

Convenience redirection to Algebra.compose.

algebraixlib.algebras.couplets.get_name() → str[source]

Return the name and ground set of this algebra in string form.

algebraixlib.algebras.couplets.get_ground_set() → algebraixlib.structure.Structure[source]

Return the ground set of this algebra.

algebraixlib.algebras.couplets.get_absolute_ground_set() → algebraixlib.structure.Structure[source]

Return the absolute ground set of this algebra.

algebraixlib.algebras.couplets.is_member(obj: algebraixlib.mathobjects.mathobject.MathObject) → bool[source]

Return whether obj is a member of the ground set of this algebra.

Returns:True if obj is a couplet (an instance of Couplet), False if not.
algebraixlib.algebras.couplets.is_absolute_member(obj: algebraixlib.mathobjects.mathobject.MathObject) → bool[source]

Return whether obj is a member of the absolute ground set of this algebra.

Returns:True if obj is an absolute couplet, False if not.
algebraixlib.algebras.couplets.is_reflexive(couplet: '(M x M)', _checked=True) → bool[source]

Return whether couplet is reflexive.

Returns:True if couplet is reflexive, False if it is not, or Undef() if couplet is not a couplet.