[Next] [Contents]

## `Cat::AlgebraWithBasis` -- the category of associative algebras with a distinguished basis

#### Introduction

``Cat::AlgebraWithBasis`(R)` represents the category of associative `R`-algebras with a distinguished basis.

#### Generating the category

`Cat::AlgebraWithBasis(R)`

#### Parameters

`R` | - | A domain which must be from the category `Cat::Ring`.

#### Categories

`Cat::Algebra(R)`, `Cat::ModuleWithBasis(R)`

#### Details

- An ``Cat::AlgebraWithBasis`(R)` is an `R`-algebra with a distinguished basis. The multiplication is typically implemented by extending by linearity its definition on the basis elements.

- By default, the method `"_mult"` is set to `operators::_mult`, which in turn uses `operators::mult2`. Furthermore, the later is overloaded with the following signatures and associated implementations:
  - [dom, dom] : `"mult2"`
  - [dom, R] : `"multcoeffs"`
  - [R, dom] : `"multcoeffsLeft"`
  In other words, a `Cat::AlgebraWithBasis` just has to implement `"mult2"`, `"multcoeffs"`, and `"multcoeffsLeft"`. Then, `"_mult"` will be implemented appropriately to handle all the possible ways it can be called in (binary and n-ary internal multiplications of elements, left and right multiplications by scalar, ...). This differs from the plain `Cat::Algebra` category for which the domain has to provide this `"_mult"` method. In a future version, this feature will be extended to `Cat::Algebra`.

#### Basic Entries

oneBasis

If the unit of the algebra is a basis element, the index of this basis element can be provided here, instead of defining `"one"`.

#### Method fromCoeffRing: natural embedding of the coefficient ring

- `fromCoeffRing( <dom::coeffRing c>)`

- Returns the natural embedding `c*dom::one` of the coefficient `c` as an element of this ring.

#### Method ground: ground coefficient

- `ground( <dom x>)`

- Returns the ground coefficient of x, that is the coefficient of `x` on the unit of the algebra.
- This only makes sense if the unit of the algebra is a basis element, so this method is optional. A default implementation is provided when `"oneBasis"` is defined.

#### Method mult2Basis: binary multiplication of basis elements

- `mult2Basis(dom::basisIndices x, dom::basisIndices y)`

- Returns the product of the basis elements indexed by `x` and `y`.
- The default implementation is `"multBasis"`; so, the domain may define either one of them, or both, at the programmers convenience.

#### Method mult2: binary multiplication

- `mult2(dom x, dom y)`

- Returns the product of `x` by `y`.
- `x` and `y` are required to be of this domain; no coercion is attempted.
- The default implementation extends `"mult2Basis"` by bilinearity.

#### Method multBasis: n-ary multiplication of basis elements

- `multBasis( <dom::basisIndices x, ...>)`

- Returns the product of the basis elements indexed by the arguments.

#### Method mult: n-ary multiplication

- `mult( <dom x, ...>)`

- Returns the product of the arguments. If no argument is provided, returns the unit of the algebra (`"("`one))
.
- The arguments are required to be of this domain; no coercion is attempted.
- The default implementation extends `"mult2"` by associativity. Sometime in the future, it may instead extend `"multBasis"` by multilinearity.

#### Changes

- `Cat::AlgebraWithBasis` is a new category

[Next] [Contents]

MuPAD Combinat, an open source algebraic combinatorics package