Macaulay2 » Documentation
Packages » MonomialAlgebras :: codimMA
next | previous | forward | backward | up | index | toc

# codimMA -- Codimension of a monomial algebra.

- Usage:
    `codimMA R`
    `codimMA B`
    `codimMA M`
- Inputs:
  - R, a polynomial ring, with B = degrees R and K = coefficientRing R, or
  - B, a list, with the generators of an affine semigroup in \mathbb{N}^d.
  - M, a MonomialAlgebra,
- Outputs:
  - an integer,

## Description

Compute the codimension of the homogeneous monomial algebra K[B].

As the result is independent of K it is possible to specify just B.

    i1 : B={{2, 2, 1}, {1, 1, 3}, {1, 2, 2}, {2, 0, 3}, {1, 4, 0}, {2, 3, 0}, {1, 3, 1}}

    o1 = {{2, 2, 1}, {1, 1, 3}, {1, 2, 2}, {2, 0, 3}, {1, 4, 0}, {2, 3, 0}, {1,
         ------------------------------------------------------------------------
         3, 1}}

    o1 : List

    i2 : codimMA B

    o2 = 4

    i3 : B={{2, 2, 1}, {1, 1, 3}, {1, 2, 2}, {2, 0, 3}, {1, 4, 0}, {2, 3, 0}, {1, 3, 1}}

    o3 = {{2, 2, 1}, {1, 1, 3}, {1, 2, 2}, {2, 0, 3}, {1, 4, 0}, {2, 3, 0}, {1,
         ------------------------------------------------------------------------
         3, 1}}

    o3 : List

    i4 : M=monomialAlgebra B

          ZZ
    o4 = ---[x ..x ]
         101  0   6

    o4 : MonomialAlgebra generated by {{2, 2, 1}, {1, 1, 3}, {1, 2, 2}, {2, 0, 3}, {1, 4, 0}, {2, 3, 0}, {1, 3, 1}}

    i5 : codimMA M

    o5 = 4

## Ways to use codimMA:

- `codimMA(List)`
- `codimMA(MonomialAlgebra)`
- `codimMA(PolynomialRing)`

## For the programmer

The object codimMA is a method function.

The source of this document is in /build/macaulay2-88fgJW/macaulay2-1.25.11+ds/M2/Macaulay2/packages/MonomialAlgebras.m2:2274:0.