This is LieTypes.info, produced by Macaulay2, version 1.25.05

LieTypes -- Common types for Lie groups and Lie algebras
********************************************************

Description
===========

This package defines types used by the ConformalBlocks package and may someday
be used by other packages as well.  If you would like to see a type or function
added to this package (or better yet, if you would like to write types or
functions for this package), please contact Dan Grayson, Mike Stillman, or Dave
Swinarski.

Authors
=======

  * Dave Swinarski <dswinarski@fordham.edu>
  * Paul Zinn-Justin (see http://blogs.unimelb.edu.au/paul-zinn-justin/ )
    <pzinn@unimelb.edu.au>

Certification a gold star
=========================

Version 0.5 of this package was accepted for publication in volume 8 (see
https://msp.org/jsag/2018/8-1/ ) of The Journal of Software for Algebra and
Geometry (see https://msp.org/jsag/ ) on 2 August 2018, in the article Software
for computing conformal block divisors on bar M_0,n (see
https://msp.org/jsag/2018/8-1/p08.xhtml ) (DOI: 10.2140/jsag.2018.8.81 (see
https://doi.org/10.2140/jsag.2018.8.81 )). That version can be obtained from
the journal (see https://msp.org/jsag/2018/8-1/jsag-v8-n1-x08-LieTypes.m2 ).

Version
=======

This documentation describes version 0.9 of LieTypes.

Citation
========

If you have used this package in your research, please cite it as follows:

+-----------------------------------------------------------------------------+
|@misc{LieTypesSource,                                                        |
|  title = {{LieTypes: common types and methods for Lie groups and            |
|  author = {Dave Swinarski and Paul Zinn-Justin},                            |
|  howpublished = {A \emph{Macaulay2} package available at                    |
|    \url{https://github.com/Macaulay2/M2/tree/master/M2/Macaulay2/           |
|}                                                                            |
|                                                                             |
|@article{LieTypesArticle,                                                    |
|  title = {{Software for computing conformal block divisors on bar           |
|  author = {Dave Swinarski and Paul Zinn-Justin},                            |
|  journal = {The Journal of Software for Algebra and Geometry},              |
|  volume = {8},                                                              |
|  year = {2018},                                                             |
|}                                                                            |
|-----------------------------------------------------------------------------|
|Lie algebras. Version~0.9}},                                                 |
|                                                                             |
|                                                                             |
|packages}}                                                                   |
|                                                                             |
|                                                                             |
|                                                                             |
| M_0,n}},                                                                    |
+-----------------------------------------------------------------------------+

Exports
=======

  * Types
      * LieAlgebra -- class for Lie algebras
      * LieAlgebraModule -- class for Lie algebra
        modules
  * Functions and commands
      * adams -- Computes the action of the nth Adams operator on
        a Lie algebra module
      * adjointModule -- The adjoint module of a Lie
        algebra
      * branchingRule -- A Lie algebra module viewed as a
        module over a Lie subalgebra
      * cartanMatrix -- Provide the Cartan matrix of a
        simple Lie algebra
      * casimirScalar -- computes the scalar by which the
        Casimir operator acts on an irreducible Lie algebra module
      * character -- Computes the character of a Lie algebra
        module
      * dualCoxeterNumber -- returns the dual Coxeter
        number of a simple Lie algebra
      * dynkinDiagram -- Provide the Dynkin diagram of a
        simple Lie algebra
      * embedding -- gives the embedding of Cartan
        subalgebras of one Lie algebra into another
      * fusionCoefficient -- computes the
        multiplicity of W in the fusion product of U and V
      * fusionProduct -- computes the multiplicities of
        irreducibles in the decomposition of the fusion product of U and V
      * highestRoot -- returns the highest root of a simple
        Lie algebra
      * irreducibleLieAlgebraModule, --
        construct the irreducible Lie algebra module with given highest weight
      * isIrreducible -- Whether a Lie algebra module is
        irreducible or not
      * killingForm -- computes the scaled Killing form
        applied to two weights
      * LieAlgebraModuleFromWeights, --
        finds a Lie algebra module based on its weights
      * "positiveCoroots" -- see positiveRoots, -- returns
        the positive (co)roots of a simple Lie algebra
      * positiveRoots -- returns the positive (co)roots
        of a simple Lie algebra
      * qdim -- Compute principal specialization of character or
        quantum dimension
      * simpleLieAlgebra -- construct a simple Lie
        algebra
      * simpleRoots -- returns the simple roots of a simple
        Lie algebra
      * starInvolution -- computes w* for a weight w
      * subLieAlgebra -- Define a sub-Lie algebra of an
        existing one
      * tensorCoefficient -- computes the
        multiplicity of W in U tensor V
      * trivialModule -- The trivial module of a Lie
        algebra
      * weightDiagram -- computes the weights in a Lie
        algebra module and their multiplicities
      * weylAlcove -- the dominant integral weights of level
        less than or equal to l
      * zeroModule -- The zero module of a Lie algebra
  * Methods
      * "adams(ZZ,LieAlgebraModule)" -- see adams, -- Computes the
        action of the nth Adams operator on a Lie algebra module
      * "adjointModule(LieAlgebra)" -- see adjointModule,
        -- The adjoint module of a Lie algebra
      * "branchingRule(LieAlgebraModule,LieAlgebra)" -- see
        branchingRule, -- A Lie algebra module viewed as a
        module over a Lie subalgebra
      * "branchingRule(LieAlgebraModule,List)" -- see branchingRule,
        -- A Lie algebra module viewed as a module over a Lie
        subalgebra
      * "branchingRule(LieAlgebraModule,Matrix)" -- see branchingRule,
        -- A Lie algebra module viewed as a module over a Lie
        subalgebra
      * "cartanMatrix(LieAlgebra)" -- see cartanMatrix, --
        Provide the Cartan matrix of a simple Lie algebra
      * "casimirScalar(LieAlgebraModule)" -- see casimirScalar,
        -- computes the scalar by which the Casimir operator
        acts on an irreducible Lie algebra module
      * casimirScalar(LieAlgebra,List) (missing documentation)
      * "character(LieAlgebra,List)" -- see character, --
        Computes the character of a Lie algebra module
      * "character(LieAlgebra,Vector)" -- see character, --
        Computes the character of a Lie algebra module
      * "character(LieAlgebraModule)" -- see character, --
        Computes the character of a Lie algebra module
      * dim(LieAlgebraModule) -- computes the
        dimension of a Lie algebra module as a vector space over the ground
        field
      * "dualCoxeterNumber(LieAlgebra)" -- see dualCoxeterNumber,
        -- returns the dual Coxeter number of a simple Lie
        algebra
      * "dualCoxeterNumber(String,ZZ)" -- see dualCoxeterNumber,
        -- returns the dual Coxeter number of a simple Lie
        algebra
      * "dynkinDiagram(LieAlgebra)" -- see dynkinDiagram,
        -- Provide the Dynkin diagram of a simple Lie algebra
      * "embedding(LieAlgebra,LieAlgebra)" -- see embedding,
        -- gives the embedding of Cartan subalgebras of one Lie algebra into
        another
      * "fusionCoefficient(LieAlgebraModule,LieAlgebraModule,LieAlgebraModule,
        ZZ)" -- see fusionCoefficient, -- computes the
        multiplicity of W in the fusion product of U and V
      * "fusionProduct(LieAlgebraModule,LieAlgebraModule,ZZ)" -- see
        fusionProduct, -- computes the multiplicities of
        irreducibles in the decomposition of the fusion product of U and V
      * "highestRoot(LieAlgebra)" -- see highestRoot, --
        returns the highest root of a simple Lie algebra
      * "irreducibleLieAlgebraModule(LieAlgebra,List)" -- see
        irreducibleLieAlgebraModule, -- construct
        the irreducible Lie algebra module with given highest weight
      * "irreducibleLieAlgebraModule(LieAlgebra,Vector)" -- see
        irreducibleLieAlgebraModule, -- construct
        the irreducible Lie algebra module with given highest weight
      * "isIrreducible(LieAlgebraModule)" -- see isIrreducible,
        -- Whether a Lie algebra module is irreducible or not
      * "isIsomorphic(LieAlgebra,LieAlgebra)" -- see isIsomorphic,
        -- tests whether two Lie algebra are isomorphic
      * isIsomorphic(LieAlgebraModule,LieAlgebraModule) (missing documentation)
      * "killingForm(LieAlgebra,List,List)" -- see killingForm,
        -- computes the scaled Killing form applied to two weights
      * "killingForm(LieAlgebra,Vector,Vector)" -- see killingForm,
        -- computes the scaled Killing form applied to two weights
      * "directSum(LieAlgebra)" -- see LieAlgebra ++ LieAlgebra,
        -- Take the direct sum of Lie algebras
      * LieAlgebra ++ LieAlgebra -- Take the
        direct sum of Lie algebras
      * LieAlgebra == LieAlgebra -- tests
        equality of LieAlgebra
      * LieAlgebra _ ZZ -- selects one summand of a
        semi-simple Lie Algebra
      * LieAlgebra _* -- gives the list of summands
        of a semi-simple Lie Algebra
      * LieAlgebraModule ** LieAlgebraModule
        -- tensor product of LieAlgebraModules
      * "directSum(LieAlgebraModule)" -- see LieAlgebraModule ++ LieAlgebraModule,
        -- direct sum
        of LieAlgebraModules
      * LieAlgebraModule ++ LieAlgebraModule
        -- direct sum of LieAlgebraModules
      * LieAlgebraModule @ LieAlgebraModule
        -- Take the tensor product of modules over different
        Lie algebras
      * LieAlgebraModule ^ ZZ (missing documentation)
      * LieAlgebraModule ^** ZZ -- Computes
        the nth tensor power of a Lie algebra module
      * "LieAlgebraModule _ LieAlgebraModule" -- see LieAlgebraModule _ ZZ,
        -- Pick out one irreducible submodule of a
        Lie algebra module
      * "LieAlgebraModule _ List" -- see LieAlgebraModule _ ZZ,
        -- Pick out one irreducible submodule of a Lie
        algebra module
      * "LieAlgebraModule _ Vector" -- see LieAlgebraModule _ ZZ,
        -- Pick out one irreducible submodule of a Lie
        algebra module
      * LieAlgebraModule _ ZZ -- Pick out one
        irreducible submodule of a Lie algebra module
      * LieAlgebraModule _* -- List irreducible
        submodules of a Lie algebra module
      * "LieAlgebraModuleFromWeights(RingElement,LieAlgebra)" -- see
        LieAlgebraModuleFromWeights, -- finds a
        Lie algebra module based on its weights
      * "LieAlgebraModuleFromWeights(VirtualTally,LieAlgebra)" -- see
        LieAlgebraModuleFromWeights, -- finds a
        Lie algebra module based on its weights
      * new LieAlgebra from Matrix -- Define
        a Lie algebra from its Cartan matrix
      * new LieAlgebra from Sequence (missing documentation)
      * "positiveCoroots(LieAlgebra)" -- see positiveRoots,
        -- returns the positive (co)roots of a simple Lie
        algebra
      * "positiveRoots(LieAlgebra)" -- see positiveRoots,
        -- returns the positive (co)roots of a simple Lie algebra
      * "qdim(LieAlgebraModule)" -- see qdim, -- Compute principal
        specialization of character or quantum dimension
      * "qdim(LieAlgebraModule,ZZ)" -- see qdim, -- Compute
        principal specialization of character or quantum dimension
      * "simpleLieAlgebra(String,ZZ)" -- see simpleLieAlgebra,
        -- construct a simple Lie algebra
      * "simpleRoots(LieAlgebra)" -- see simpleRoots, --
        returns the simple roots of a simple Lie algebra
      * "simpleRoots(String,ZZ)" -- see simpleRoots, --
        returns the simple roots of a simple Lie algebra
      * "dual(LieAlgebraModule)" -- see starInvolution,
        -- computes w* for a weight w
      * "starInvolution(LieAlgebraModule)" -- see starInvolution,
        -- computes w* for a weight w
      * "subLieAlgebra(LieAlgebra,List)" -- see subLieAlgebra,
        -- Define a sub-Lie algebra of an existing one
      * "subLieAlgebra(LieAlgebra,Matrix)" -- see subLieAlgebra,
        -- Define a sub-Lie algebra of an existing one
      * "subLieAlgebra(LieAlgebra,String)" -- see subLieAlgebra,
        -- Define a sub-Lie algebra of an existing one
      * "exteriorPower(ZZ,LieAlgebraModule)" -- see
        symmetricPower(ZZ,LieAlgebraModule),
        -- Computes the nth
        symmetric / exterior tensor power of a Lie algebra module
      * symmetricPower(ZZ,LieAlgebraModule)
        -- Computes the nth
        symmetric / exterior tensor power of a Lie algebra module
      * "tensorCoefficient(LieAlgebraModule,LieAlgebraModule,LieAlgebraModule)"
        -- see tensorCoefficient, -- computes the
        multiplicity of W in U tensor V
      * toExternalString(LieAlgebra) (missing documentation)
      * toExternalString(LieAlgebraModule) (missing documentation)
      * toString(LieAlgebra) (missing documentation)
      * toString(LieAlgebraModule) (missing documentation)
      * "trivialModule(LieAlgebra)" -- see trivialModule,
        -- The trivial module of a Lie algebra
      * "weightDiagram(LieAlgebra,List)" -- see weightDiagram,
        -- computes the weights in a Lie algebra module and
        their multiplicities
      * "weightDiagram(LieAlgebra,Vector)" -- see weightDiagram,
        -- computes the weights in a Lie algebra module and
        their multiplicities
      * "weightDiagram(LieAlgebraModule)" -- see weightDiagram,
        -- computes the weights in a Lie algebra module and
        their multiplicities
      * "weylAlcove(LieAlgebra,ZZ)" -- see weylAlcove, -- the
        dominant integral weights of level less than or equal to l
      * "weylAlcove(String,ZZ,ZZ)" -- see weylAlcove, -- the
        dominant integral weights of level less than or equal to l
      * "weylAlcove(ZZ,LieAlgebra)" -- see weylAlcove, -- the
        dominant integral weights of level less than or equal to l
      * "zeroModule(LieAlgebra)" -- see zeroModule, -- The
        zero module of a Lie algebra
  * Other things
      * ω -- construct the irreducible Lie
        algebra module with given highest weight
      * 𝔞 (missing documentation)
      * 𝔟 (missing documentation)
      * 𝔠 (missing documentation)
      * 𝔡 (missing documentation)
      * 𝔢 (missing documentation)
      * 𝔣 (missing documentation)
      * 𝔤 (missing documentation)
      * LL -- construct the irreducible Lie
        algebra module with given highest weight

For the programmer
==================

The object LieTypes, is a package (Macaulay2Doc),
defined in LieTypes.m2.

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1498:0.

adams -- Computes the action of the nth Adams operator on a Lie algebra module
******************************************************************************

  * Usage:
        adams(n,M)
  * Inputs:
      * n, an integer (Macaulay2Doc),
      * M, an instance of the type LieAlgebraModule,
  * Outputs:
      * M', an instance of the type LieAlgebraModule,

Ways to use adams:
==================

  * "adams(ZZ,LieAlgebraModule)"

For the programmer
==================

The object adams, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2380:0.

adjointModule -- The adjoint module of a Lie algebra
****************************************************

Description
===========

Returns the module corresponding to the adjoint representation of a Lie
algebra.

+-----------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)                 |
|                                               |
|o1 = g                                         |
|                                               |
|o1 : simple LieAlgebra                         |
+-----------------------------------------------+
|i2 : adjointModule g                           |
|                                               |
|o2 = LL   (g)                                  |
|       1,1                                     |
|                                               |
|o2 : irreducible LieAlgebraModule over g       |
+-----------------------------------------------+
|i3 : adjointModule (g++g)                      |
|                                               |
|o3 = LL       (𝔞  ++ 𝔞 ) ++ LL       (𝔞  ++ 𝔞 )|
|       0,0,1,1  2     2       1,1,0,0  2     2 |
|                                               |
|o3 : LieAlgebraModule over 𝔞  ++ 𝔞             |
|                            2     2            |
+-----------------------------------------------+

Ways to use adjointModule:
==========================

  * "adjointModule(LieAlgebra)"

For the programmer
==================

The object adjointModule, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2357:0.

branchingRule -- A Lie algebra module viewed as a module over a Lie subalgebra
******************************************************************************

  * Usage:
        branchingRule(V,S)
  * Inputs:
      * V, an instance of the type LieAlgebraModule,
      * S, a list (Macaulay2Doc), a matrix (Macaulay2Doc),
        or an instance of the type LieAlgebra,
  * Outputs:
      * V', an instance of the type LieAlgebraModule,

Description
===========

S must be a subset of vertices of the Dynkin diagram of the Lie algebra of V,
or a matrix, see subLieAlgebra,; or a sub-Lie algebra.
Returns V viewed as a module over the Lie subalgebra determined by S.

+-------------------------------------------------+
|i1 : g=simpleLieAlgebra("D",4);                  |
+-------------------------------------------------+
|i2 : M=adjointModule g;                          |
+-------------------------------------------------+
|i3 : branchingRule(M,{1,2,3})                    |
|                                                 |
|                                 2               |
|o3 = LL     (𝔞 ) ++ (LL     (𝔞 ))  ++ LL     (𝔞 )|
|       0,0,0  3        0,1,0  3         1,0,1  3 |
|                                                 |
|o3 : LieAlgebraModule over 𝔞                     |
|                            3                    |
+-------------------------------------------------+

Ways to use branchingRule:
==========================

  * "branchingRule(LieAlgebraModule,LieAlgebra)"
  * "branchingRule(LieAlgebraModule,List)"
  * "branchingRule(LieAlgebraModule,Matrix)"

For the programmer
==================

The object branchingRule, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2573:0.

cartanMatrix -- Provide the Cartan matrix of a simple Lie algebra
*****************************************************************

Description
===========

+------------------------------+
|i1 : g=simpleLieAlgebra("G",2)|
|                              |
|o1 = g                        |
|                              |
|o1 : simple LieAlgebra        |
+------------------------------+
|i2 : cartanMatrix g           |
|                              |
|o2 = | 2  -1 |                |
|     | -3 2  |                |
|                              |
|              2       2       |
|o2 : Matrix ZZ  <-- ZZ        |
+------------------------------+

Ways to use cartanMatrix:
=========================

  * "cartanMatrix(LieAlgebra)"

For the programmer
==================

The object cartanMatrix, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2487:0.

casimirScalar -- computes the scalar by which the Casimir operator acts on an irreducible Lie algebra module
************************************************************************************************************

  * Usage:
        casimirScalar(V)
  * Inputs:
      * V, an instance of the type LieAlgebraModule,
  * Outputs:
      * k, a rational number (Macaulay2Doc),

Description
===========

The Casimir operator is an element of the universal enveloping algebra that
acts by a scalar on each irreducible Lie algebra module.  One has $c(\mu) =
(\mu,\mu) + 2(\mu,\rho)$, where $\rho$ is half the sum of the positive weights
and (,) is the Killing form scaled so that $(\theta,\theta)=2$, where $\theta$
is the highest root.  See Di Francesco, Mathieu, and Senechal, Conformal Field
Theory, Springer Graduate Texts in Theoretical Physics, (13.127) p. 512, and
(13.46) p. 499.

In the example below, we see that the Casimir operator acts as multiplication
by 8/3 on the standard representation of $sl_3$.

+-------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)             |
|                                           |
|o1 = g                                     |
|                                           |
|o1 : simple LieAlgebra                     |
+-------------------------------------------+
|i2 : V=irreducibleLieAlgebraModule({1,0},g)|
|                                           |
|o2 = V                                     |
|                                           |
|o2 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i3 : casimirScalar(V)                      |
|                                           |
|     8                                     |
|o3 = -                                     |
|     3                                     |
|                                           |
|o3 : QQ                                    |
+-------------------------------------------+

Ways to use casimirScalar:
==========================

  * "casimirScalar(LieAlgebraModule)"
  * casimirScalar(LieAlgebra,List) (missing documentation)

For the programmer
==================

The object casimirScalar, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2227:0.

character -- Computes the character of a Lie algebra module
***********************************************************

  * Usage:
        character V
  * Inputs:
      * V, an instance of the type LieAlgebraModule,
  * Optional inputs (Macaulay2Doc),:
      * Strategy => ..., default value null
  * Outputs:
      * C, a ring element (Macaulay2Doc),

Description
===========

An optional argument "Strategy" allows to specify which algorithm to use:
"Freudenthal" for Freudenthal's recursive algorithm; see Humphreys,
Introduction to Lie Algebras and Representation Theory, Section 22.3. "Weyl"
for Weyl's character formula (in classical types). "JacobiTrudi" and
"JacobiTrudi'" for Jacobi-Trudi and dual Jacobi-Trudi formulae (in type A).

See also
========

  * weightDiagram -- computes the weights in a Lie
    algebra module and their multiplicities

Ways to use character:
======================

  * "character(LieAlgebra,List)"
  * "character(LieAlgebra,Vector)"
  * "character(LieAlgebraModule)"

For the programmer
==================

The object character, is a method function with options (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2293:0.

dim(LieAlgebraModule) -- computes the dimension of a Lie algebra module as a vector space over the ground field
***************************************************************************************************************

  * Function: dim (Macaulay2Doc),
  * Usage:
        dim(V)
  * Inputs:
      * V, an instance of the type LieAlgebraModule,
  * Outputs:
      * k, an integer (Macaulay2Doc),

Description
===========

+-------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)             |
|                                           |
|o1 = g                                     |
|                                           |
|o1 : simple LieAlgebra                     |
+-------------------------------------------+
|i2 : V=irreducibleLieAlgebraModule({1,0},g)|
|                                           |
|o2 = V                                     |
|                                           |
|o2 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i3 : dim(V)                                |
|                                           |
|o3 = 3                                     |
+-------------------------------------------+

Ways to use this method:
========================

  * dim(LieAlgebraModule) -- computes the
    dimension of a Lie algebra module as a vector space over the ground field
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1963:0.

dualCoxeterNumber -- returns the dual Coxeter number of a simple Lie algebra
****************************************************************************

  * Usage:
        dualCoxeterNumber(g)
  * Inputs:
      * g, an instance of the type LieAlgebra, a simple Lie
        algebra
  * Outputs:
      * n, an integer (Macaulay2Doc), the dual Coxeter number of g

Description
===========

The dual Coxeter number is defined as the sum of the comarks plus 1.  See Di
Francesco, Mathieu, and Senechal, Conformal Field Theory, Springer Graduate
Texts in Theoretical Physics, Formula (13.35) and Appendix A.

+------------------------------+
|i1 : dualCoxeterNumber("A",2) |
|                              |
|o1 = 3                        |
+------------------------------+
|i2 : g=simpleLieAlgebra("A",2)|
|                              |
|o2 = g                        |
|                              |
|o2 : simple LieAlgebra        |
+------------------------------+
|i3 : dualCoxeterNumber(g)     |
|                              |
|o3 = 3                        |
+------------------------------+

Ways to use dualCoxeterNumber:
==============================

  * "dualCoxeterNumber(LieAlgebra)"
  * "dualCoxeterNumber(String,ZZ)"

For the programmer
==================

The object dualCoxeterNumber, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1677:0.

dynkinDiagram -- Provide the Dynkin diagram of a simple Lie algebra
*******************************************************************

Description
===========

+------------------------------+
|i1 : g=simpleLieAlgebra("F",4)|
|                              |
|o1 = g                        |
|                              |
|o1 : simple LieAlgebra        |
+------------------------------+
|i2 : dynkinDiagram g          |
|                              |
|o2 = o---o=>=o---o            |
|     1   2   3   4            |
+------------------------------+

Ways to use dynkinDiagram:
==========================

  * "dynkinDiagram(LieAlgebra)"

For the programmer
==================

The object dynkinDiagram, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2475:0.

embedding -- gives the embedding of Cartan subalgebras of one Lie algebra into another
**************************************************************************************

  * Usage:
        embedding(g,h)
  * Inputs:
      * g, an instance of the type LieAlgebra,
      * h, an instance of the type LieAlgebra,

Description
===========

+----------------------------------------------+
|i1 : h=simpleLieAlgebra("F",4)                |
|                                              |
|o1 = h                                        |
|                                              |
|o1 : simple LieAlgebra                        |
+----------------------------------------------+
|i2 : g=subLieAlgebra(h,{0,1}); describe g     |
|                                              |
|o3 = 𝔞                                        |
|      2                                       |
+----------------------------------------------+
|i4 : embedding(g,h)                           |
|                                              |
|o4 = | -2 1 |                                 |
|     | -3 0 |                                 |
|     | -2 0 |                                 |
|     | -1 0 |                                 |
|                                              |
|              4       2                       |
|o4 : Matrix ZZ  <-- ZZ                        |
+----------------------------------------------+
|i5 : embedding(subLieAlgebra(h,"principal"),h)|
|                                              |
|o5 = | 22 |                                   |
|     | 42 |                                   |
|     | 30 |                                   |
|     | 16 |                                   |
|                                              |
|              4       1                       |
|o5 : Matrix ZZ  <-- ZZ                        |
+----------------------------------------------+

Ways to use embedding:
======================

  * "embedding(LieAlgebra,LieAlgebra)"

For the programmer
==================

The object embedding, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1648:0.

fusionCoefficient -- computes the multiplicity of W in the fusion product of U and V
************************************************************************************

  * Usage:
        fusionCoefficient(U,V,W,l)
  * Inputs:
      * U, an instance of the type LieAlgebraModule,
      * V, an instance of the type LieAlgebraModule,
      * W, an instance of the type LieAlgebraModule,
      * l, an integer (Macaulay2Doc),

Description
===========

This function implements the Kac-Walton algorithm; see Di Francesco, Mathieu,
and Senechal, Conformal Field Theory, Springer Graduate Texts in Theoretical
Physics, Section 16.2.2.

Given three irreducible Lie algebra modules $U$, $V$, and $W$, the function
returns the multiplicity of $W$ in the fusion product of $U$ and $V$ at level
$l$.  (We are abusing notation and terminology a little here; the fusion
product is really a product for modules over an affine Lie algebra.  However,
since the Kac-Walton algorithm is defined entirely using the combinatorics of
the root system of the underlying finite-dimensional Lie algebra, we may
therefore use the Kac-Walton algorithm to define a product on Lie algebra
modules as well.)

The example below shows that for $g=sl_3$ and $\lambda=2 \omega_1 + \omega_2$,
$\mu= \omega_1 + 2 \omega_2$, and $\nu= \omega_1 +  \omega_2$, the level 3
fusion product  $V_{\lambda} \otimes_3  V_{\mu}$ contains one copy of
$V_{\nu}$.

+--------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2);             |
+--------------------------------------------+
|i2 : U=irreducibleLieAlgebraModule({2,1},g);|
+--------------------------------------------+
|i3 : V=irreducibleLieAlgebraModule({1,2},g);|
+--------------------------------------------+
|i4 : W=irreducibleLieAlgebraModule({1,1},g);|
+--------------------------------------------+
|i5 : fusionCoefficient(U,V,W,3)             |
|                                            |
|o5 = 1                                      |
+--------------------------------------------+

Ways to use fusionCoefficient:
==============================

  * "fusionCoefficient(LieAlgebraModule,LieAlgebraModule,LieAlgebraModule,ZZ)"

For the programmer
==================

The object fusionCoefficient, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2141:0.

fusionProduct -- computes the multiplicities of irreducibles in the decomposition of the fusion product of U and V
******************************************************************************************************************

  * Usage:
        fusionProduct(U,V,l)
  * Inputs:
      * U, an instance of the type LieAlgebraModule,
      * V, an instance of the type LieAlgebraModule,
      * l, an integer (Macaulay2Doc),

Description
===========

This function implements the Kac-Walton algorithm; see Di Francesco, Mathieu,
and Senechal, Conformal Field Theory, Springer Graduate Texts in Theoretical
Physics, Section 16.2.2.

Given two irreducible Lie algebra modules $U$ and $V$, the function returns the
fusion product of $U$ and $V$ at level $l$.  (We are abusing notation and
terminology a little here; the fusion product is really a product for modules
over an affine Lie algebra.  However, since the Kac-Walton algorithm is defined
entirely using the combinatorics of the root system of the underlying
finite-dimensional Lie algebra, we may therefore use the Kac-Walton algorithm
to define a product on Lie algebra modules as well.)

The example below shows that for $g=sl_3$ and $\lambda=2 \omega_1 + \omega_2 =
(2,1)$, $\mu= \omega_1 + 2 \omega_2 = (1,2)$, the level 3 fusion product
$V_{(2,1)} \otimes_3  V_{(1,2)}$ contains one copy of $V_{(0,0)}$ and one copy
of $V_{(1,1)}$.

+--------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2);             |
+--------------------------------------------+
|i2 : U=irreducibleLieAlgebraModule({2,1},g);|
+--------------------------------------------+
|i3 : V=irreducibleLieAlgebraModule({1,2},g);|
+--------------------------------------------+
|i4 : fusionProduct(U,V,3)                   |
|                                            |
|o4 = LL   (g) ++ LL   (g)                   |
|       0,0         1,1                      |
|                                            |
|o4 : LieAlgebraModule over g                |
+--------------------------------------------+

Ways to use fusionProduct:
==========================

  * "fusionProduct(LieAlgebraModule,LieAlgebraModule,ZZ)"

For the programmer
==================

The object fusionProduct, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2191:0.

highestRoot -- returns the highest root of a simple Lie algebra
***************************************************************

  * Usage:
        highestRoot(g), highestRoot("A",2)
  * Inputs:
      * g, an instance of the type LieAlgebra,
  * Outputs:
      * t, a list (Macaulay2Doc),

Description
===========

Let R be an irreducible root system of rank m, and choose a base of simple
roots $\Delta = \{\alpha_1,...,\alpha_m\}$.  Then there is a unique root
$\theta$ such that when $\theta$ is expanded in terms of the simple roots, i.e.
$\theta= \sum c_i \alpha_i$, the sum $\sum c_i$ is maximized.  The formulas
implemented here are taken from the tables following Bourbaki's Lie Groups and
Lie Algebras Chapter 6.

In the example below, we see that for $sl_3$, the highest root $\theta$ is
$\omega_1+ \omega_2$, where $\omega_1$ and $\omega_2$ are the fundamental
dominant weights.

+-----------------------+
|i1 : highestRoot("A",2)|
|                       |
|o1 = {1, 1}            |
|                       |
|o1 : List              |
+-----------------------+

Ways to use highestRoot:
========================

  * "highestRoot(LieAlgebra)"

For the programmer
==================

The object highestRoot, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1704:0.

irreducibleLieAlgebraModule -- construct the irreducible Lie algebra module with given highest weight
*****************************************************************************************************

  * Usage:
        irreducibleLieAlgebraModule(w,g)
        irreducibleLieAlgebraModule(g,w)
  * Inputs:
      * w, a list (Macaulay2Doc), the highest weight of the desired
        module
      * g, an instance of the type LieAlgebra,
  * Outputs:
      * M, an instance of the type LieAlgebraModule,

Description
===========

This function creates the irreducible Lie algebra module with a given highest
weight.

+-----------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)           |
|                                         |
|o1 = g                                   |
|                                         |
|o1 : simple LieAlgebra                   |
+-----------------------------------------+
|i2 : irreducibleLieAlgebraModule(g,{1,1})|
|                                         |
|o2 = LL   (g)                            |
|       1,1                               |
|                                         |
|o2 : irreducible LieAlgebraModule over g |
+-----------------------------------------+

One can also use the shorthand LL:

+----------------------------------------+
|i3 : LL_(1,1) (g)                       |
|                                        |
|o3 = LL   (g)                           |
|       1,1                              |
|                                        |
|o3 : irreducible LieAlgebraModule over g|
+----------------------------------------+

as well as the shorthand ω: LL_(ω_2) (g)

Ways to use irreducibleLieAlgebraModule:
========================================

  * "irreducibleLieAlgebraModule(LieAlgebra,List)"
  * "irreducibleLieAlgebraModule(LieAlgebra,Vector)"

For the programmer
==================

The object irreducibleLieAlgebraModule, is a
method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1911:0.

isIrreducible -- Whether a Lie algebra module is irreducible or not
*******************************************************************

Description
===========

+-------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)             |
|                                           |
|o1 = g                                     |
|                                           |
|o1 : simple LieAlgebra                     |
+-------------------------------------------+
|i2 : M=irreducibleLieAlgebraModule({2,1},g)|
|                                           |
|o2 = M                                     |
|                                           |
|o2 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i3 : isIrreducible M                       |
|                                           |
|o3 = true                                  |
+-------------------------------------------+
|i4 : isIrreducible(M++M)                   |
|                                           |
|o4 = false                                 |
+-------------------------------------------+
|i5 : isIrreducible(M**M)                   |
|                                           |
|o5 = false                                 |
+-------------------------------------------+

Ways to use isIrreducible:
==========================

  * "isIrreducible(LieAlgebraModule)"

For the programmer
==================

The object isIrreducible, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2315:0.

isIsomorphic -- tests whether two Lie algebra are isomorphic
************************************************************

  * Usage:
        isIsomorphic(g,h)
  * Inputs:
      * g, an instance of the type LieAlgebra,
      * h, an instance of the type LieAlgebra,
  * Optional inputs (Macaulay2Doc),:
      * Homogeneous (Isomorphism), => ..., default value
        true,
      * Strategy (Isomorphism), => ..., default value null,
      * Strict (Isomorphism), => ..., default value false,
      * Tries (Isomorphism), => ..., default value null,
      * Verbose (Isomorphism), => ..., default value false,
  * Outputs:
      * b, a Boolean value (Macaulay2Doc),

Description
===========

+--------------------------------------------+
|i1 : g=simpleLieAlgebra("D",4)              |
|                                            |
|o1 = g                                      |
|                                            |
|o1 : simple LieAlgebra                      |
+--------------------------------------------+
|i2 : h=subLieAlgebra(g,{2,{1,0,1,1}})       |
|                                            |
|o2 = h                                      |
|                                            |
|o2 : simple LieAlgebra, subalgebra of g     |
+--------------------------------------------+
|i3 : isIsomorphic(h,simpleLieAlgebra("G",2))|
|                                            |
|o3 = true                                   |
+--------------------------------------------+

Ways to use isIsomorphic:
=========================

  * "isIsomorphic(LieAlgebra,LieAlgebra)"
  * "isIsomorphic(Matrix,Matrix)" -- see isIsomorphic (Isomorphism),
    -- probabilistic test for isomorphism of modules
  * "isIsomorphic(Module,Module)" -- see isIsomorphic (Isomorphism),
    -- probabilistic test for isomorphism of modules
  * isIsomorphic(LieAlgebraModule,LieAlgebraModule) (missing documentation)

For the programmer
==================

The object isIsomorphic (Isomorphism), is a method function with options (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2253:0.

killingForm -- computes the scaled Killing form applied to two weights
**********************************************************************

  * Usage:
        killingForm(g,v,w)
  * Inputs:
      * g, an instance of the type LieAlgebra,
      * v, a list (Macaulay2Doc),
      * w, a list (Macaulay2Doc),

Description
===========

Let $\mathbf{g}$ be a Lie algebra.  The Killing form on $\mathbf{g}$ is the
symmetric bilinear form given by $(x,y) = Tr(\mathrm{ad}_x \mathrm{ad}_y)$.  It
can restricted to a Cartan subalgebra $\mathbf{h}$ and transferred to
$\mathbf{h}^*$, yielding a symmetric bilinear form on weights.  One popular
convention is to scale the Killing form so that $(\theta,\theta) =2$, where
$\theta$ is the highest root.

+-------------------------------+
|i1 : g=simpleLieAlgebra("A",2) |
|                               |
|o1 = g                         |
|                               |
|o1 : simple LieAlgebra         |
+-------------------------------+
|i2 : killingForm(g,{1,0},{0,1})|
|                               |
|     1                         |
|o2 = -                         |
|     3                         |
|                               |
|o2 : QQ                        |
+-------------------------------+

Ways to use killingForm:
========================

  * "killingForm(LieAlgebra,List,List)"
  * "killingForm(LieAlgebra,Vector,Vector)"

For the programmer
==================

The object killingForm, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1820:0.

LieAlgebra -- class for Lie algebras
************************************

Description
===========

This class represents Lie algebras.  Currently only semi-simple Lie algebras
over the complex numbers are supported. An object of type LieAlgebra is a hash
table whose keys record the rank of the Lie algebra and the type of the root
system.

+------------------------------+
|i1 : g=simpleLieAlgebra("A",1)|
|                              |
|o1 = g                        |
|                              |
|o1 : simple LieAlgebra        |
+------------------------------+
|i2 : h=simpleLieAlgebra("E",6)|
|                              |
|o2 = h                        |
|                              |
|o2 : simple LieAlgebra        |
+------------------------------+
|i3 : g++h                     |
|                              |
|o3 = 𝔞  ++ 𝔢                  |
|      1     6                 |
|                              |
|o3 : LieAlgebra               |
+------------------------------+

If you have access to unicode fraktur, you can use the shorthand

+----------------------+
|i4 : 𝔣_4              |
|                      |
|o4 = 𝔣                |
|      4               |
|                      |
|o4 : simple LieAlgebra|
+----------------------+

See also new LieAlgebra from Matrix.

Functions and methods returning an object of class LieAlgebra:
==============================================================

  * simpleLieAlgebra -- construct a simple Lie algebra
  * subLieAlgebra -- Define a sub-Lie algebra of an
    existing one

Methods that use an object of class LieAlgebra:
===============================================

  * "adjointModule(LieAlgebra)" -- see adjointModule, --
    The adjoint module of a Lie algebra
  * "branchingRule(LieAlgebraModule,LieAlgebra)" -- see branchingRule,
    -- A Lie algebra module viewed as a module over a Lie
    subalgebra
  * "cartanMatrix(LieAlgebra)" -- see cartanMatrix, --
    Provide the Cartan matrix of a simple Lie algebra
  * casimirScalar(LieAlgebra,List) (missing documentation)
  * "character(LieAlgebra,List)" -- see character, -- Computes
    the character of a Lie algebra module
  * "character(LieAlgebra,Vector)" -- see character, --
    Computes the character of a Lie algebra module
  * "dualCoxeterNumber(LieAlgebra)" -- see dualCoxeterNumber,
    -- returns the dual Coxeter number of a simple Lie
    algebra
  * "dynkinDiagram(LieAlgebra)" -- see dynkinDiagram, --
    Provide the Dynkin diagram of a simple Lie algebra
  * "embedding(LieAlgebra,LieAlgebra)" -- see embedding, --
    gives the embedding of Cartan subalgebras of one Lie algebra into another
  * "highestRoot(LieAlgebra)" -- see highestRoot, -- returns
    the highest root of a simple Lie algebra
  * "irreducibleLieAlgebraModule(LieAlgebra,List)" -- see
    irreducibleLieAlgebraModule, -- construct the
    irreducible Lie algebra module with given highest weight
  * "irreducibleLieAlgebraModule(LieAlgebra,Vector)" -- see
    irreducibleLieAlgebraModule, -- construct the
    irreducible Lie algebra module with given highest weight
  * "isIsomorphic(LieAlgebra,LieAlgebra)" -- see isIsomorphic,
    -- tests whether two Lie algebra are isomorphic
  * "killingForm(LieAlgebra,List,List)" -- see killingForm,
    -- computes the scaled Killing form applied to two weights
  * "killingForm(LieAlgebra,Vector,Vector)" -- see killingForm,
    -- computes the scaled Killing form applied to two weights
  * "directSum(LieAlgebra)" -- see LieAlgebra ++ LieAlgebra,
    -- Take the direct sum of Lie algebras
  * LieAlgebra ++ LieAlgebra -- Take the
    direct sum of Lie algebras
  * LieAlgebra == LieAlgebra -- tests equality
    of LieAlgebra
  * LieAlgebra _ ZZ -- selects one summand of a
    semi-simple Lie Algebra
  * LieAlgebra _* -- gives the list of summands of a
    semi-simple Lie Algebra
  * "LieAlgebraModuleFromWeights(RingElement,LieAlgebra)" -- see
    LieAlgebraModuleFromWeights, -- finds a Lie
    algebra module based on its weights
  * "LieAlgebraModuleFromWeights(VirtualTally,LieAlgebra)" -- see
    LieAlgebraModuleFromWeights, -- finds a Lie
    algebra module based on its weights
  * new LieAlgebra from Matrix -- Define a
    Lie algebra from its Cartan matrix
  * new LieAlgebra from Sequence (missing documentation)
  * "positiveCoroots(LieAlgebra)" -- see positiveRoots, --
    returns the positive (co)roots of a simple Lie algebra
  * "positiveRoots(LieAlgebra)" -- see positiveRoots, --
    returns the positive (co)roots of a simple Lie algebra
  * "simpleRoots(LieAlgebra)" -- see simpleRoots, -- returns
    the simple roots of a simple Lie algebra
  * "subLieAlgebra(LieAlgebra,List)" -- see subLieAlgebra,
    -- Define a sub-Lie algebra of an existing one
  * "subLieAlgebra(LieAlgebra,Matrix)" -- see subLieAlgebra,
    -- Define a sub-Lie algebra of an existing one
  * "subLieAlgebra(LieAlgebra,String)" -- see subLieAlgebra,
    -- Define a sub-Lie algebra of an existing one
  * toExternalString(LieAlgebra) (missing documentation)
  * toString(LieAlgebra) (missing documentation)
  * "trivialModule(LieAlgebra)" -- see trivialModule, --
    The trivial module of a Lie algebra
  * "weightDiagram(LieAlgebra,List)" -- see weightDiagram,
    -- computes the weights in a Lie algebra module and their multiplicities
  * "weightDiagram(LieAlgebra,Vector)" -- see weightDiagram,
    -- computes the weights in a Lie algebra module and their
    multiplicities
  * "weylAlcove(LieAlgebra,ZZ)" -- see weylAlcove, -- the
    dominant integral weights of level less than or equal to l
  * "weylAlcove(ZZ,LieAlgebra)" -- see weylAlcove, -- the
    dominant integral weights of level less than or equal to l
  * "zeroModule(LieAlgebra)" -- see zeroModule, -- The zero
    module of a Lie algebra

For the programmer
==================

The object LieAlgebra, is a type (Macaulay2Doc),
with ancestor classes HashTable (Macaulay2Doc), < Thing (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1519:0.

LieAlgebra ++ LieAlgebra -- Take the direct sum of Lie algebras
***************************************************************

  * Operator: ++ (Macaulay2Doc),

Description
===========

Starting from simple Lie algebras, one can take direct sums and produce
semi-simple ones:

+-------------------------------+
|i1 : g=simpleLieAlgebra("D",4);|
+-------------------------------+
|i2 : h=simpleLieAlgebra("G",2);|
+-------------------------------+
|i3 : g++h                      |
|                               |
|o3 = 𝔡  ++ 𝔤                   |
|      4     2                  |
|                               |
|o3 : LieAlgebra                |
+-------------------------------+
|i4 : directSum(g,g,h)          |
|                               |
|o4 = 𝔡  ++ 𝔡  ++ 𝔤             |
|      4     4     2            |
|                               |
|o4 : LieAlgebra                |
+-------------------------------+

Note that this is external direct sum, so if $g_i$ is a sub-Lie algebra of
$h_i$, $i=1,2$, then $g_1\oplus g_2$ is a sub-Lie algebra of $h_1\oplus h_2$.

Ways to use this method:
========================

  * LieAlgebra ++ LieAlgebra -- Take the
    direct sum of Lie algebras
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2600:0.

LieAlgebra == LieAlgebra -- tests equality of LieAlgebra
********************************************************

  * Operator: == (Macaulay2Doc),
  * Usage:
        g == h
  * Inputs:
      * g, an instance of the type LieAlgebra,
      * h, an instance of the type LieAlgebra,
  * Outputs:
      * b, a Boolean value (Macaulay2Doc),

Description
===========

+------------------------------+
|i1 : g=simpleLieAlgebra("A",2)|
|                              |
|o1 = g                        |
|                              |
|o1 : simple LieAlgebra        |
+------------------------------+
|i2 : h=simpleLieAlgebra("A",2)|
|                              |
|o2 = g                        |
|                              |
|o2 : simple LieAlgebra        |
+------------------------------+
|i3 : g==h                     |
|                              |
|o3 = true                     |
+------------------------------+

When dealing with subalgebras, Lie algebras can be isomorphic but different:

+-----------------------------------------+
|i4 : g1=subLieAlgebra(g,{1}); describe g1|
|                                         |
|o5 = 𝔞                                   |
|      1                                  |
+-----------------------------------------+
|i6 : g2=subLieAlgebra(g,{2}); describe g2|
|                                         |
|o7 = 𝔞                                   |
|      1                                  |
+-----------------------------------------+
|i8 : g1==g2 -- false!                    |
|                                         |
|o8 = false                               |
+-----------------------------------------+

Ways to use this method:
========================

  * LieAlgebra == LieAlgebra -- tests equality
    of LieAlgebra
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1578:0.

LieAlgebra _ ZZ -- selects one summand of a semi-simple Lie Algebra
*******************************************************************

  * Operator: _ (Macaulay2Doc),
  * Usage:
        g_n
  * Inputs:
      * g, an instance of the type LieAlgebra,
      * n, an integer (Macaulay2Doc),
  * Outputs:
      * h, an instance of the type LieAlgebra,

Description
===========

+---------------------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2) ++ simpleLieAlgebra("A",2)|
|                                                         |
|o1 = g                                                   |
|                                                         |
|o1 : LieAlgebra                                          |
+---------------------------------------------------------+
|i2 : g_0                                                 |
|                                                         |
|o2 = 𝔞                                                   |
|      2                                                  |
|                                                         |
|o2 : simple LieAlgebra, subalgebra of g                  |
+---------------------------------------------------------+

Note that the same result can be obtained by using subLieAlgebra,:

+----------------------------------+
|i3 : dynkinDiagram g              |
|                                  |
|o3 = o---o   o---o                |
|     1   2   3   4                |
+----------------------------------+
|i4 : g_0 == subLieAlgebra(g,{1,2})|
|                                  |
|o4 = true                         |
+----------------------------------+
|i5 : g_1 == subLieAlgebra(g,{3,4})|
|                                  |
|o5 = true                         |
+----------------------------------+

Ways to use this method:
========================

  * LieAlgebra _ ZZ -- selects one summand of a
    semi-simple Lie Algebra
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1607:0.

LieAlgebra _* -- gives the list of summands of a semi-simple Lie Algebra
************************************************************************

  * Operator: _* (Macaulay2Doc),
  * Usage:
        g_*
  * Inputs:
      * g, an instance of the type LieAlgebra,

Description
===========

+---------------------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2) ++ simpleLieAlgebra("A",3)|
|                                                         |
|o1 = g                                                   |
|                                                         |
|o1 : LieAlgebra                                          |
+---------------------------------------------------------+
|i2 : g_*                                                 |
|                                                         |
|o2 = {𝔞 , 𝔞 }                                            |
|       2   3                                             |
|                                                         |
|o2 : List                                                |
+---------------------------------------------------------+

Ways to use this method:
========================

  * LieAlgebra _* -- gives the list of summands of a
    semi-simple Lie Algebra
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1629:0.

LieAlgebraModule -- class for Lie algebra modules
*************************************************

Description
===========

This class represents Lie algebra modules.  Currently only modules over
semi-simple Lie algebras over the complex numbers are supported. An object of
type LieAlgebraModule is a hash table recording the Lie algebra and the
decomposition of the module into irreducible Lie algebra modules, which are
indexed by their highest weights.

+-------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)             |
|                                           |
|o1 = g                                     |
|                                           |
|o1 : simple LieAlgebra                     |
+-------------------------------------------+
|i2 : M=irreducibleLieAlgebraModule(g,{1,1})|
|                                           |
|o2 = M                                     |
|                                           |
|o2 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+

Functions and methods returning an object of class LieAlgebraModule:
====================================================================

  * adams -- Computes the action of the nth Adams operator on a
    Lie algebra module
  * adjointModule -- The adjoint module of a Lie algebra
  * branchingRule -- A Lie algebra module viewed as a
    module over a Lie subalgebra
  * fusionProduct -- computes the multiplicities of
    irreducibles in the decomposition of the fusion product of U and V
  * irreducibleLieAlgebraModule, --
    construct the irreducible Lie algebra module with given highest weight
  * LieAlgebraModuleFromWeights -- finds a
    Lie algebra module based on its weights
  * trivialModule -- The trivial module of a Lie algebra
  * zeroModule -- The zero module of a Lie algebra

Methods that use an object of class LieAlgebraModule:
=====================================================

  * "adams(ZZ,LieAlgebraModule)" -- see adams, -- Computes the
    action of the nth Adams operator on a Lie algebra module
  * "branchingRule(LieAlgebraModule,LieAlgebra)" -- see branchingRule,
    -- A Lie algebra module viewed as a module over a Lie
    subalgebra
  * "branchingRule(LieAlgebraModule,List)" -- see branchingRule,
    -- A Lie algebra module viewed as a module over a Lie
    subalgebra
  * "branchingRule(LieAlgebraModule,Matrix)" -- see branchingRule,
    -- A Lie algebra module viewed as a module over a Lie
    subalgebra
  * "casimirScalar(LieAlgebraModule)" -- see casimirScalar,
    -- computes the scalar by which the Casimir operator acts on
    an irreducible Lie algebra module
  * "character(LieAlgebraModule)" -- see character, --
    Computes the character of a Lie algebra module
  * dim(LieAlgebraModule) -- computes the
    dimension of a Lie algebra module as a vector space over the ground field
  * "fusionCoefficient(LieAlgebraModule,LieAlgebraModule,LieAlgebraModule,ZZ)"
    -- see fusionCoefficient, -- computes the
    multiplicity of W in the fusion product of U and V
  * "fusionProduct(LieAlgebraModule,LieAlgebraModule,ZZ)" -- see
    fusionProduct, -- computes the multiplicities of
    irreducibles in the decomposition of the fusion product of U and V
  * "isIrreducible(LieAlgebraModule)" -- see isIrreducible,
    -- Whether a Lie algebra module is irreducible or not
  * isIsomorphic(LieAlgebraModule,LieAlgebraModule) (missing documentation)
  * LieAlgebraModule ** LieAlgebraModule
    -- tensor product of LieAlgebraModules
  * "directSum(LieAlgebraModule)" -- see LieAlgebraModule ++ LieAlgebraModule,
    -- direct sum of
    LieAlgebraModules
  * LieAlgebraModule ++ LieAlgebraModule
    -- direct sum of LieAlgebraModules
  * LieAlgebraModule @ LieAlgebraModule
    -- Take the tensor product of modules over different Lie
    algebras
  * LieAlgebraModule ^ ZZ (missing documentation)
  * LieAlgebraModule ^** ZZ -- Computes the
    nth tensor power of a Lie algebra module
  * "LieAlgebraModule _ LieAlgebraModule" -- see LieAlgebraModule _ ZZ,
    -- Pick out one irreducible submodule of a Lie
    algebra module
  * "LieAlgebraModule _ List" -- see LieAlgebraModule _ ZZ,
    -- Pick out one irreducible submodule of a Lie
    algebra module
  * "LieAlgebraModule _ Vector" -- see LieAlgebraModule _ ZZ,
    -- Pick out one irreducible submodule of a Lie
    algebra module
  * LieAlgebraModule _ ZZ -- Pick out one
    irreducible submodule of a Lie algebra module
  * LieAlgebraModule _* -- List irreducible
    submodules of a Lie algebra module
  * "qdim(LieAlgebraModule)" -- see qdim, -- Compute principal
    specialization of character or quantum dimension
  * "qdim(LieAlgebraModule,ZZ)" -- see qdim, -- Compute principal
    specialization of character or quantum dimension
  * "dual(LieAlgebraModule)" -- see starInvolution, --
    computes w* for a weight w
  * "starInvolution(LieAlgebraModule)" -- see starInvolution,
    -- computes w* for a weight w
  * "exteriorPower(ZZ,LieAlgebraModule)" -- see
    symmetricPower(ZZ,LieAlgebraModule),
    -- Computes the nth symmetric /
    exterior tensor power of a Lie algebra module
  * symmetricPower(ZZ,LieAlgebraModule)
    -- Computes the nth symmetric /
    exterior tensor power of a Lie algebra module
  * "tensorCoefficient(LieAlgebraModule,LieAlgebraModule,LieAlgebraModule)" --
    see tensorCoefficient, -- computes the
    multiplicity of W in U tensor V
  * toExternalString(LieAlgebraModule) (missing documentation)
  * toString(LieAlgebraModule) (missing documentation)
  * "weightDiagram(LieAlgebraModule)" -- see weightDiagram,
    -- computes the weights in a Lie algebra module and their
    multiplicities

For the programmer
==================

The object LieAlgebraModule, is a type (Macaulay2Doc),
with ancestor classes HashTable (Macaulay2Doc),
< Thing (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1878:0.

LieAlgebraModule ** LieAlgebraModule -- tensor product of LieAlgebraModules
***************************************************************************

  * Operator: ** (Macaulay2Doc),
  * Usage:
        U ** V
  * Inputs:
      * U, an instance of the type LieAlgebraModule,
      * V, an instance of the type LieAlgebraModule,
  * Outputs:
      * W, an instance of the type LieAlgebraModule,

Description
===========

Computes the tensor product of two Lie algebra modules.

+-----------------------------------------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)                                               |
|                                                                             |
|o1 = g                                                                       |
|                                                                             |
|o1 : simple LieAlgebra                                                       |
+-----------------------------------------------------------------------------+
|i2 : U=irreducibleLieAlgebraModule({4,2},g)                                  |
|                                                                             |
|o2 = U                                                                       |
|                                                                             |
|o2 : irreducible LieAlgebraModule over g                                     |
+-----------------------------------------------------------------------------+
|i3 : V=irreducibleLieAlgebraModule({3,1},g)                                  |
|                                                                             |
|o3 = V                                                                       |
|                                                                             |
|o3 : irreducible LieAlgebraModule over g                                     |
+-----------------------------------------------------------------------------+
|i4 : U**V                                                                    |
|                                                                             |
|                                                               2             |
|o4 = LL   (g) ++ LL   (g) ++ LL   (g) ++ LL   (g) ++ (LL   (g))  ++          |
|       0,5         1,3         1,6         2,1          2,4                  |
|                                                                             |
|o4 : LieAlgebraModule over g                                                 |
|-----------------------------------------------------------------------------|
|          2                                      2              2            |
|(LL   (g))  ++ LL   (g) ++ LL   (g) ++ (LL   (g))  ++ (LL   (g))  ++ LL   (g)|
|   3,2           3,5         4,0          4,3            5,1           5,4   |
|-----------------------------------------------------------------------------|
|             2                                                               |
|++ (LL   (g))  ++ LL   (g) ++ LL   (g) ++ LL   (g)                           |
|      6,2           7,0         7,3         8,1                              |
+-----------------------------------------------------------------------------+

See also
========

  * tensorCoefficient -- computes the multiplicity of
    W in U tensor V

Ways to use this method:
========================

  * LieAlgebraModule ** LieAlgebraModule
    -- tensor product of LieAlgebraModules
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2032:0.

LieAlgebraModule ++ LieAlgebraModule -- direct sum of LieAlgebraModules
***********************************************************************

  * Operator: ++ (Macaulay2Doc),
  * Usage:
        U ++ V
  * Inputs:
      * U, an instance of the type LieAlgebraModule,
      * V, an instance of the type LieAlgebraModule,
  * Outputs:
      * W, an instance of the type LieAlgebraModule,

Description
===========

Computes the direct sum of two Lie algebra modules.

+-------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)             |
|                                           |
|o1 = g                                     |
|                                           |
|o1 : simple LieAlgebra                     |
+-------------------------------------------+
|i2 : U=irreducibleLieAlgebraModule({4,2},g)|
|                                           |
|o2 = U                                     |
|                                           |
|o2 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i3 : V=irreducibleLieAlgebraModule({3,1},g)|
|                                           |
|o3 = V                                     |
|                                           |
|o3 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i4 : U++V                                  |
|                                           |
|o4 = LL   (g) ++ LL   (g)                  |
|       3,1         4,2                     |
|                                           |
|o4 : LieAlgebraModule over g               |
+-------------------------------------------+

Ways to use this method:
========================

  * LieAlgebraModule ++ LieAlgebraModule
    -- direct sum of LieAlgebraModules
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2060:0.

LieAlgebraModule @ LieAlgebraModule -- Take the tensor product of modules over different Lie algebras
*****************************************************************************************************

  * Operator: @ (Macaulay2Doc),

Description
===========

Produces a module over the direct sum of the Lie algebras of the two modules.

+-----------------------------------------------------------------------------+
|i1 : LL_(1,2,3,4) (simpleLieAlgebra("D",4)) @ LL_(5,6)                       |
|                                                                             |
|o1 = LL           (𝔡  ++ 𝔤 )                                                 |
|       1,2,3,4,5,6  4     2                                                  |
|                                                                             |
|o1 : irreducible LieAlgebraModule over 𝔡  ++ 𝔤                               |
|                                        4     2                              |
|-----------------------------------------------------------------------------|
|(simpleLieAlgebra("G",2))                                                    |
+-----------------------------------------------------------------------------+

A complicated way to define usual tensor product LieAlgebraModule ** LieAlgebraModule,
would be using the
diagonal embedding:

+-----------------------------------------------+
|i2 : g := simpleLieAlgebra("A",1)              |
|                                               |
|o2 = 𝔞                                         |
|      1                                        |
|                                               |
|o2 : simple LieAlgebra                         |
+-----------------------------------------------+
|i3 : h := g ++ g                               |
|                                               |
|o3 = 𝔞  ++ 𝔞                                   |
|      1     1                                  |
|                                               |
|o3 : LieAlgebra                                |
+-----------------------------------------------+
|i4 : gdiag := subLieAlgebra(h,matrix {{1},{1}})|
|                                               |
|o4 = 𝔞                                         |
|      1                                        |
|                                               |
|o4 : simple LieAlgebra, subalgebra of 𝔞  ++ 𝔞  |
|                                       1     1 |
+-----------------------------------------------+
|i5 : M = LL_5 (g); M' = LL_2 (g);              |
+-----------------------------------------------+
|i7 : M @ M'                                    |
|                                               |
|o7 = LL   (𝔞  ++ 𝔞 )                           |
|       5,2  1     1                            |
|                                               |
|o7 : irreducible LieAlgebraModule over 𝔞  ++ 𝔞 |
|                                        1     1|
+-----------------------------------------------+
|i8 : branchingRule(oo,gdiag)                   |
|                                               |
|o8 = LL (𝔞 ) ++ LL (𝔞 ) ++ LL (𝔞 )             |
|       3  1       5  1       7  1              |
|                                               |
|o8 : LieAlgebraModule over 𝔞                   |
|                            1                  |
+-----------------------------------------------+
|i9 : M ** M'                                   |
|                                               |
|o9 = LL (𝔞 ) ++ LL (𝔞 ) ++ LL (𝔞 )             |
|       3  1       5  1       7  1              |
|                                               |
|o9 : LieAlgebraModule over 𝔞                   |
|                            1                  |
+-----------------------------------------------+

Ways to use this method:
========================

  * LieAlgebraModule @ LieAlgebraModule
    -- Take the tensor product of modules over different Lie
    algebras
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2622:0.

LieAlgebraModule ^** ZZ -- Computes the nth tensor power of a Lie algebra module
********************************************************************************

  * Operator: ^** (Macaulay2Doc),
  * Usage:
        M^**n
  * Inputs:
      * M, an instance of the type LieAlgebraModule,
      * n, an integer (Macaulay2Doc),
  * Outputs:
      * M', an instance of the type LieAlgebraModule,

Ways to use this method:
========================

  * LieAlgebraModule ^** ZZ -- Computes the
    nth tensor power of a Lie algebra module
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2418:0.

LieAlgebraModule _ ZZ -- Pick out one irreducible submodule of a Lie algebra module
***********************************************************************************

  * Operator: _ (Macaulay2Doc),

Description
===========

If a number is given, the ordering is the same as when the module is displayed:

+-----------------------------------------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2);                                              |
+-----------------------------------------------------------------------------+
|i2 : (adjointModule g)^**3                                                   |
|                                                                             |
|               2              4              8              2              6 |
|o2 = (LL   (g))  ++ (LL   (g))  ++ (LL   (g))  ++ (LL   (g))  ++ (LL   (g))  |
|        0,0            0,3            1,1            1,4            2,2      |
|                                                                             |
|o2 : LieAlgebraModule over g                                                 |
|-----------------------------------------------------------------------------|
|             4                          2                                    |
|++ (LL   (g))  ++ LL   (g) ++ (LL   (g))                                     |
|      3,0           3,3          4,1                                         |
+-----------------------------------------------------------------------------+
|i3 : oo_2                                                                    |
|                                                                             |
|o3 = LL   (g)                                                                |
|       1,1                                                                   |
|                                                                             |
|o3 : irreducible LieAlgebraModule over g                                     |
+-----------------------------------------------------------------------------+

Instead one can simply use a weight or irreducible module as subscript:

+-----------------------------------------------------------------------------+
|i4 : g=simpleLieAlgebra("A",3);                                              |
+-----------------------------------------------------------------------------+
|i5 : M=(adjointModule g)^**2                                                 |
|                                                                             |
|o5 = M                                                                       |
|                                                                             |
|o5 : LieAlgebraModule over g                                                 |
+-----------------------------------------------------------------------------+
|i6 : describe M                                                              |
|                                                                             |
|                                                           2                 |
|o6 = LL     (g) ++ LL     (g) ++ LL     (g) ++ (LL     (g))  ++ LL     (g) ++|
|       0,0,0         0,1,2         0,2,0          1,0,1           2,0,2      |
|-----------------------------------------------------------------------------|
|LL     (g)                                                                   |
|  2,1,0                                                                      |
+-----------------------------------------------------------------------------+
|i7 : M_{1,0,1}                                                               |
|                                                                             |
|o7 = 2                                                                       |
+-----------------------------------------------------------------------------+
|i8 : M_(trivialModule g)                                                     |
|                                                                             |
|o8 = 1                                                                       |
+-----------------------------------------------------------------------------+

Ways to use this method:
========================

  * "LieAlgebraModule _ LieAlgebraModule"
  * "LieAlgebraModule _ List"
  * "LieAlgebraModule _ Vector"
  * LieAlgebraModule _ ZZ -- Pick out one
    irreducible submodule of a Lie algebra module
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2675:0.

LieAlgebraModule _* -- List irreducible submodules of a Lie algebra module
**************************************************************************

  * Operator: _* (Macaulay2Doc),

Description
===========

Gives a list of nonisomorphic irreducible submodules:

+-----------------------------------------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2);                                              |
+-----------------------------------------------------------------------------+
|i2 : (adjointModule g)^**3                                                   |
|                                                                             |
|               2              4              8              2              6 |
|o2 = (LL   (g))  ++ (LL   (g))  ++ (LL   (g))  ++ (LL   (g))  ++ (LL   (g))  |
|        0,0            0,3            1,1            1,4            2,2      |
|                                                                             |
|o2 : LieAlgebraModule over g                                                 |
|-----------------------------------------------------------------------------|
|             4                          2                                    |
|++ (LL   (g))  ++ LL   (g) ++ (LL   (g))                                     |
|      3,0           3,3          4,1                                         |
+-----------------------------------------------------------------------------+
|i3 : oo_*                                                                    |
|                                                                             |
|o3 = {LL   (g), LL   (g), LL   (g), LL   (g), LL   (g), LL   (g), LL   (g),  |
|        0,0       0,3       1,1       1,4       2,2       3,0       3,3      |
|     ------------------------------------------------------------------------|
|     LL   (g)}                                                               |
|       4,1                                                                   |
|                                                                             |
|o3 : List                                                                    |
+-----------------------------------------------------------------------------+

Ways to use this method:
========================

  * LieAlgebraModule _* -- List irreducible
    submodules of a Lie algebra module
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2689:0.

LieAlgebraModuleFromWeights -- finds a Lie algebra module based on its weights
******************************************************************************

  * Usage:
        LieAlgebraModuleFromWeights(T,g)
  * Inputs:
      * T, a tally (Macaulay2Doc),
      * g, an instance of the type LieAlgebra,

Description
===========

+--------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2);             |
+--------------------------------------------+
|i2 : U=irreducibleLieAlgebraModule({1,1},g);|
+--------------------------------------------+
|i3 : M=U**U                                 |
|                                            |
|o3 = M                                      |
|                                            |
|o3 : LieAlgebraModule over g                |
+--------------------------------------------+
|i4 : T=weightDiagram M                      |
|                                            |
|o4 = VirtualTally{{-1, -1} => 6}            |
|                  {-1, 2} => 6              |
|                  {-2, -2} => 1             |
|                  {-2, 1} => 6              |
|                  {-2, 4} => 1              |
|                  {-3, 0} => 2              |
|                  {-3, 3} => 2              |
|                  {-4, 2} => 1              |
|                  {0, -3} => 2              |
|                  {0, 0} => 10              |
|                  {0, 3} => 2               |
|                  {1, -2} => 6              |
|                  {1, 1} => 6               |
|                  {2, -1} => 6              |
|                  {2, -4} => 1              |
|                  {2, 2} => 1               |
|                  {3, -3} => 2              |
|                  {3, 0} => 2               |
|                  {4, -2} => 1              |
|                                            |
|o4 : VirtualTally                           |
+--------------------------------------------+
|i5 : LieAlgebraModuleFromWeights(T,g)       |
|                                            |
|o5 = M                                      |
|                                            |
|o5 : LieAlgebraModule over g                |
+--------------------------------------------+

Ways to use LieAlgebraModuleFromWeights:
========================================

  * "LieAlgebraModuleFromWeights(RingElement,LieAlgebra)"
  * "LieAlgebraModuleFromWeights(VirtualTally,LieAlgebra)"

For the programmer
==================

The object LieAlgebraModuleFromWeights, is a
method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2162:0.

multiplicity(List,LieAlgebraModule) -- compute the multiplicity of a weight in a Lie algebra module
***************************************************************************************************

  * Function: multiplicity (ReesAlgebra),
  * Usage:
        multiplicity(v,M)
  * Inputs:
      * v, a list (Macaulay2Doc),
      * M, an instance of the type LieAlgebraModule,
  * Optional inputs (Macaulay2Doc),:
      * BasisElementLimit (missing documentation) => ..., default value
        infinity,
      * DegreeLimit (missing documentation) => ..., default value {},
      * MinimalGenerators (missing documentation) => ..., default value true,
      * PairLimit (missing documentation) => ..., default value infinity,
      * Strategy (missing documentation) => ..., default value null,
      * Variable (missing documentation) => ..., default value "w",
  * Outputs:
      * k, an integer (Macaulay2Doc),

Description
===========

The example below shows that the $sl_3$ module with highest weight $(2,1)$
contains the weight $(-1,1)$ with multiplicity 2.

+-------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)             |
|                                           |
|o1 = g                                     |
|                                           |
|o1 : simple LieAlgebra                     |
+-------------------------------------------+
|i2 : V=irreducibleLieAlgebraModule({2,1},g)|
|                                           |
|o2 = V                                     |
|                                           |
|o2 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i3 : multiplicity({-1,1},V)                |
|                                           |
|o3 = 2                                     |
+-------------------------------------------+

See also
========

  * weightDiagram -- computes the weights in a Lie
    algebra module and their multiplicities
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1941:0.

new LieAlgebra from Matrix -- Define a Lie algebra from its Cartan matrix
*************************************************************************

Description
===========

new LieAlgebra from M

If M is a valid Cartan matrix, it will reorder if needed the rows/columns of M
to a standard form and then output the corresponding Lie algebra g.

+----------------------------------------------------------------------------+
|i1 : M = matrix {{2, 0, -3, 0}, {0, 2, 0, -1}, {-1, 0, 2, 0}, {0, -1, 0, 2}}|
|                                                                            |
|o1 = | 2  0  -3 0  |                                                        |
|     | 0  2  0  -1 |                                                        |
|     | -1 0  2  0  |                                                        |
|     | 0  -1 0  2  |                                                        |
|                                                                            |
|              4       4                                                     |
|o1 : Matrix ZZ  <-- ZZ                                                      |
+----------------------------------------------------------------------------+
|i2 : h := new LieAlgebra from M                                             |
|                                                                            |
|o2 = 𝔤  ++ 𝔞                                                                |
|      2     2                                                               |
|                                                                            |
|o2 : LieAlgebra                                                             |
+----------------------------------------------------------------------------+
|i3 : cartanMatrix h                                                         |
|                                                                            |
|o3 = | 2  -1 0  0  |                                                        |
|     | -3 2  0  0  |                                                        |
|     | 0  0  2  -1 |                                                        |
|     | 0  0  -1 2  |                                                        |
|                                                                            |
|              4       4                                                     |
|o3 : Matrix ZZ  <-- ZZ                                                      |
+----------------------------------------------------------------------------+

Ways to use this method:
========================

  * new LieAlgebra from Matrix -- Define a
    Lie algebra from its Cartan matrix
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2650:0.

positiveRoots -- returns the positive (co)roots of a simple Lie algebra
***********************************************************************

  * Usage:
        positiveRoots(g), positiveCoroots(g)
  * Inputs:
      * g, an instance of the type LieAlgebra,
  * Outputs:
      * t, a list (Macaulay2Doc),

Description
===========

Let R be an irreducible root system of rank m, and choose a base of simple
roots $\Delta = \{\alpha_1,...,\alpha_m\}$. This function returns all the roots
that are nonnegative linear combinations of the simple roots (expressed in the
basis of fundamental weights). The formulas implemented here are taken from the
tables following Bourbaki's Lie Groups and Lie Algebras Chapter 6.

In the example below, we see that for $sl_3$, the positive roots are
$\alpha_1$, $\alpha_2$, and $\alpha_1+\alpha_2$.

+--------------------------------+
|i1 : sl3=simpleLieAlgebra("A",2)|
|                                |
|o1 = sl3                        |
|                                |
|o1 : simple LieAlgebra          |
+--------------------------------+
|i2 : positiveRoots(sl3)         |
|                                |
|o2 = {{2, -1}, {1, 1}, {-1, 2}} |
|                                |
|o2 : List                       |
+--------------------------------+

Ways to use positiveRoots:
==========================

  * "positiveRoots(LieAlgebra)"

For the programmer
==================

The object positiveRoots, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1736:0.

qdim -- Compute principal specialization of character or quantum dimension
**************************************************************************

  * Usage:
        qdim M
        qdim(M,l)
  * Inputs:
      * M, an instance of the type LieAlgebraModule,
      * l, an integer (Macaulay2Doc),
  * Outputs:
      * P, a ring element (Macaulay2Doc),

Description
===========

qdim M computes the principal specialization of the character of M. qdim (M,l)
evaluates it modulo the appropriate cyclotomic polynomial, so that upon
specialization of the variable $q$ to be the corresponding root of unity of
smallest positive argument, it provides the quantum dimension of M.

+-----------------------------------------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)                                               |
|                                                                             |
|o1 = g                                                                       |
|                                                                             |
|o1 : simple LieAlgebra                                                       |
+-----------------------------------------------------------------------------+
|i2 : W=weylAlcove(g,3)                                                       |
|                                                                             |
|o2 = {{0, 0}, {0, 1}, {0, 2}, {0, 3}, {1, 0}, {1, 1}, {1, 2}, {2, 0}, {2, 1},|
|     ------------------------------------------------------------------------|
|     {3, 0}}                                                                 |
|                                                                             |
|o2 : List                                                                    |
+-----------------------------------------------------------------------------+
|i3 : L=LL_(1,1) (g)                                                          |
|                                                                             |
|o3 = L                                                                       |
|                                                                             |
|o3 : irreducible LieAlgebraModule over g                                     |
+-----------------------------------------------------------------------------+
|i4 : M=matrix table(W,W,(v,w)->fusionCoefficient(L,LL_v g,LL_w g,3))         |
|                                                                             |
|o4 = | 0 0 0 0 0 1 0 0 0 0 |                                                 |
|     | 0 1 0 0 0 0 1 1 0 0 |                                                 |
|     | 0 0 1 0 1 0 0 0 1 0 |                                                 |
|     | 0 0 0 0 0 1 0 0 0 0 |                                                 |
|     | 0 0 1 0 1 0 0 0 1 0 |                                                 |
|     | 1 0 0 1 0 2 0 0 0 1 |                                                 |
|     | 0 1 0 0 0 0 1 1 0 0 |                                                 |
|     | 0 1 0 0 0 0 1 1 0 0 |                                                 |
|     | 0 0 1 0 1 0 0 0 1 0 |                                                 |
|     | 0 0 0 0 0 1 0 0 0 0 |                                                 |
|                                                                             |
|              10       10                                                    |
|o4 : Matrix ZZ   <-- ZZ                                                      |
+-----------------------------------------------------------------------------+
|i5 : first eigenvalues M                                                     |
|                                                                             |
|o5 = 2.999999999999999                                                       |
|                                                                             |
|o5 : CC (of precision 53)                                                    |
+-----------------------------------------------------------------------------+
|i6 : qdim L                                                                  |
|                                                                             |
|      4     2         -2    -4                                               |
|o6 = q  + 2q  + 2 + 2q   + q                                                 |
|                                                                             |
|o6 : ZZ[q]                                                                   |
+-----------------------------------------------------------------------------+
|i7 : qdim (L,3)                                                              |
|                                                                             |
|o7 = 3                                                                       |
|                                                                             |
|        ZZ[q]                                                                |
|o7 : -----------                                                             |
|      4    2                                                                 |
|     q  - q  + 1                                                             |
+-----------------------------------------------------------------------------+

Ways to use qdim:
=================

  * "qdim(LieAlgebraModule)"
  * "qdim(LieAlgebraModule,ZZ)"

For the programmer
==================

The object qdim, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2456:0.

simpleLieAlgebra -- construct a simple Lie algebra
**************************************************

  * Usage:
        simpleLieAlgebra("A",1)
  * Inputs:
      * t, a string (Macaulay2Doc), the type of the root system
        of the desired Lie algebra
      * k, an integer (Macaulay2Doc), the rank of the desired Lie
        algebra
  * Outputs:
      * g, an instance of the type LieAlgebra, the simple
        Lie algebra with the given rank and type

Description
===========

The classification of simple Lie algebras over the complex numbers is well
known. There are four infinite families (types $\mathfrak{a}_n$,
$\mathfrak{b}_n$, $\mathfrak{c}_n$, $\mathfrak{d}_n$) corresponding to the Lie
algebras $\mathfrak{sl}(n+1,\mathbb{C})$, $\mathfrak{so}(2n+1,\mathbb{C})$,
$\mathfrak{sp}(2n,\mathbb{C})$, $\mathfrak{so}(2n,\mathbb{C})$ respectively,
and five exceptional simple Lie algebras, $\mathfrak{e}_6$, $\mathfrak{e}_7$,
$\mathfrak{e}_8$, $\mathfrak{f}_4$, $\mathfrak{g}_2$.

+----------------------------+
|i1 : simpleLieAlgebra("A",1)|
|                            |
|o1 = 𝔞                      |
|      1                     |
|                            |
|o1 : simple LieAlgebra      |
+----------------------------+
|i2 : simpleLieAlgebra("E",6)|
|                            |
|o2 = 𝔢                      |
|      6                     |
|                            |
|o2 : simple LieAlgebra      |
+----------------------------+

Ways to use simpleLieAlgebra:
=============================

  * "simpleLieAlgebra(String,ZZ)"

For the programmer
==================

The object simpleLieAlgebra, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1549:0.

simpleRoots -- returns the simple roots of a simple Lie algebra
***************************************************************

  * Usage:
        simpleRoots(g), simpleRoots("A",2)
  * Inputs:
      * g, an instance of the type LieAlgebra,
  * Outputs:
      * t, a list (Macaulay2Doc),

Ways to use simpleRoots:
========================

  * "simpleRoots(LieAlgebra)"
  * "simpleRoots(String,ZZ)"

For the programmer
==================

The object simpleRoots, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1755:0.

starInvolution -- computes w* for a weight w
********************************************

  * Usage:
        starInvolution(w,g)
  * Inputs:
      * w, a list (Macaulay2Doc),
      * g, an instance of the type LieAlgebra,

Description
===========

Let $\mathbf{g}$ be a Lie algebra.  We give three equivalent descriptions of an
involution * on the weights of $\mathbf{g}$:

1. The involution * is given by $-w_0$, where $w_0$ is the longest word in the
Weyl group $W(\mathbf{g})$.

2. If $\mu$ is a dominant integral weight, and $V_{\mu}$ is the irreducible Lie
algebra module with highest weight $\mu$, then $\mu^*$ is the highest weight of
the dual module $(V_{\mu})^*$.

3. If the Dynkin diagram of $\mathbf{g}$ has an involution, then * corresponds
to the action of this involution on weights.

The formulas implemented have been adapted from Di Francesco, Mathieu, and
Senechal, Conformal Field Theory, Springer Graduate Texts in Theoretical
Physics, p. 511.  Some changes are needed because we use the Bourbaki ordering
of the roots in type E instead of the [DMS] ordering.

In the example below, we see that for $sl_3$, $\omega_1^* = \omega_2.$

+----------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)          |
|                                        |
|o1 = g                                  |
|                                        |
|o1 : simple LieAlgebra                  |
+----------------------------------------+
|i2 : starInvolution(LL_(1,0)(g))        |
|                                        |
|o2 = LL   (g)                           |
|       0,1                              |
|                                        |
|o2 : irreducible LieAlgebraModule over g|
+----------------------------------------+

Ways to use starInvolution:
===========================

  * "starInvolution(LieAlgebraModule)"

For the programmer
==================

The object starInvolution, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1791:0.

subLieAlgebra -- Define a sub-Lie algebra of an existing one
************************************************************

  * Usage:
        subLieAlgebra(g,S)
  * Inputs:
      * g, an instance of the type LieAlgebra,
      * S, a list (Macaulay2Doc), a matrix (Macaulay2Doc),
        or a string (Macaulay2Doc),
  * Outputs:
      * h, an instance of the type LieAlgebra,

Description
===========

For the purposes of this function, a sub-Lie algebra means an embedding of a
Lie algebra into another up to linear equivalence. According to Dynkin's
theory, this means that it is determined by the restriction of the embedding to
the Cartan subalgebra, and that is the data provided by S. Specifically, S must
be either a subset of vertices of the Dynkin diagram of g (as labelled by
dynkinDiagram):

+-----------------------------------+
|i1 : g=𝔢_8; dynkinDiagram g        |
|                                   |
|o2 =         o 2                   |
|             |                     |
|     o---o---o---o---o---o---o     |
|     1   3   4   5   6   7   8     |
+-----------------------------------+
|i3 : subLieAlgebra(g,{1,2,3,4,5,8})|
|                                   |
|o3 = 𝔡  ++ 𝔞                       |
|      5     1                      |
|                                   |
|o3 : LieAlgebra, subalgebra of g   |
+-----------------------------------+

The vertices are labelled from 1 to the rank of g; because we frequently want
to consider the lowest root, it is labelled 0:

+---------------------------------------+
|i4 : h=𝔣_4; dynkinDiagram h            |
|                                       |
|o5 = o---o=>=o---o                     |
|     1   2   3   4                     |
+---------------------------------------+
|i6 : subLieAlgebra(h,{0,1,2,3})        |
|                                       |
|o6 = 𝔟                                 |
|      4                                |
|                                       |
|o6 : simple LieAlgebra, subalgebra of h|
+---------------------------------------+

Or S must be a matrix whose columns are the simple coroots of the subalgebra
expanded in the basis of simple coroots of g:

+---------------------------------------------------------------------+
|i7 : g=𝔢_6                                                           |
|                                                                     |
|o7 = g                                                               |
|                                                                     |
|o7 : simple LieAlgebra                                               |
+---------------------------------------------------------------------+
|i8 : h=subLieAlgebra(g,{2,4,{0,0,1,0,1,0},{1,0,0,0,0,1}}); describe h|
|                                                                     |
|o9 = 𝔣                                                               |
|      4                                                              |
+---------------------------------------------------------------------+
|i10 : branchingRule(adjointModule g,h)                               |
|                                                                     |
|o10 = LL       (h) ++ LL       (h)                                   |
|        0,0,0,1         1,0,0,0                                      |
|                                                                     |
|o10 : LieAlgebraModule over h                                        |
+---------------------------------------------------------------------+

Or S is the string principal, which is currently the only predefined
subalgebra:

+-----------------------------------------------------------------------------+
|i11 : g=𝔞_2; h=subLieAlgebra(g,"principal"); describe h                      |
|                                                                             |
|o13 = 𝔞                                                                      |
|       1                                                                     |
+-----------------------------------------------------------------------------+
|i14 : V=LL_(2,4) g; qdim V                                                   |
|                                                                             |
|       12     10     8     6     4     2         -2     -4     -6     -8     |
|o15 = q   + 2q   + 4q  + 5q  + 7q  + 7q  + 8 + 7q   + 7q   + 5q   + 4q   +   |
|      -----------------------------------------------------------------------|
|        -10    -12                                                           |
|      2q    + q                                                              |
|                                                                             |
|o15 : ZZ[q]                                                                  |
+-----------------------------------------------------------------------------+
|i16 : W=branchingRule(V,h); describe W                                       |
|                                                                             |
|                        2                      2                             |
|o17 = LL (h) ++ (LL (h))  ++ LL (h) ++ (LL (h))  ++ LL  (h) ++ LL  (h)       |
|        0          4           6          8           10         12          |
+-----------------------------------------------------------------------------+
|i18 : character W                                                            |
|                                                                             |
|       12     10     8     6     4     2         -2     -4     -6     -8     |
|o18 = x   + 2x   + 4x  + 5x  + 7x  + 7x  + 8 + 7x   + 7x   + 5x   + 4x   +   |
|       1      1      1     1     1     1         1      1      1      1      |
|      -----------------------------------------------------------------------|
|        -10    -12                                                           |
|      2x    + x                                                              |
|        1      1                                                             |
|                                                                             |
|o18 : ZZ[x ]                                                                 |
|          1                                                                  |
+-----------------------------------------------------------------------------+

In simply laced types, principal specialisation (character of principal
subalgebra) and q-dimension agree.

Caveat
======

If S is a matrix, does not check if the map of Cartan subalgebras leads to a
valid Lie algebra embedding.

Ways to use subLieAlgebra:
==========================

  * "subLieAlgebra(LieAlgebra,List)"
  * "subLieAlgebra(LieAlgebra,Matrix)"
  * "subLieAlgebra(LieAlgebra,String)"

For the programmer
==================

The object subLieAlgebra, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2539:0.

symmetricPower(ZZ,LieAlgebraModule) -- Computes the nth symmetric / exterior tensor power of a Lie algebra module
*****************************************************************************************************************

  * Function: symmetricPower (Macaulay2Doc),
  * Usage:
        symmetricPower(n,M)
        exteriorPower(n,M)
  * Inputs:
      * n, an integer (Macaulay2Doc),
      * M, an instance of the type LieAlgebraModule,
  * Outputs:
      * M', an instance of the type LieAlgebraModule,

Ways to use this method:
========================

  * symmetricPower(ZZ,LieAlgebraModule)
    -- Computes the nth symmetric /
    exterior tensor power of a Lie algebra module
-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2396:0.

tensorCoefficient -- computes the multiplicity of W in U tensor V
*****************************************************************

  * Usage:
        tensorCoefficient(U,V,W)
  * Inputs:
      * U, an instance of the type LieAlgebraModule,
      * V, an instance of the type LieAlgebraModule,
      * W, an instance of the type LieAlgebraModule,
  * Outputs:
      * k, an integer (Macaulay2Doc),

Description
===========

This function implements the Racah-Speiser algorithm; see Di Francesco,
Mathieu, and Senechal, Conformal Field Theory, Springer Graduate Texts in
Theoretical Physics, Section 13.5.2.

Given three irreducible Lie algebra modules $U$, $V$, and $W$, the function
returns the multiplicity of $W$ in $U \otimes V$.  In Type A, these are related
to the Littlewood-Richardson coefficients (though in this package, irreducible
representations are indexed by the Dynkin labels of their highest weights,
rather than by partitions).

The example below shows that for $g=sl_3$ and $\lambda=2 \omega_1 + \omega_2$,
$\mu= \omega_1 + 2 \omega_2$, and $\nu= 2 \omega_1 + 2 \omega_2$, the tensor
product of $sl_3$ modules $V_{\lambda} \otimes V_{\mu}$ contains two copies of
$V_{\nu}$.

+-------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)             |
|                                           |
|o1 = g                                     |
|                                           |
|o1 : simple LieAlgebra                     |
+-------------------------------------------+
|i2 : U=irreducibleLieAlgebraModule({2,1},g)|
|                                           |
|o2 = U                                     |
|                                           |
|o2 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i3 : V=irreducibleLieAlgebraModule({1,2},g)|
|                                           |
|o3 = V                                     |
|                                           |
|o3 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i4 : W=irreducibleLieAlgebraModule({2,2},g)|
|                                           |
|o4 = W                                     |
|                                           |
|o4 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i5 : tensorCoefficient(U,V,W)              |
|                                           |
|o5 = 2                                     |
+-------------------------------------------+

See also
========

  * LieAlgebraModule ** LieAlgebraModule
    -- tensor product of LieAlgebraModules

Ways to use tensorCoefficient:
==============================

  * "tensorCoefficient(LieAlgebraModule,LieAlgebraModule,LieAlgebraModule)"

For the programmer
==================

The object tensorCoefficient, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2098:0.

trivialModule -- The trivial module of a Lie algebra
****************************************************

Description
===========

Returns the one-dimensional module with zero highest weight.

Ways to use trivialModule:
==========================

  * "trivialModule(LieAlgebra)"

For the programmer
==================

The object trivialModule, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2331:0.

weightDiagram -- computes the weights in a Lie algebra module and their multiplicities
**************************************************************************************

  * Usage:
        weightDiagram(V)
  * Inputs:
      * V, an instance of the type LieAlgebraModule,
  * Optional inputs (Macaulay2Doc),:
      * Strategy => ..., default value null
  * Outputs:
      * T, a virtual tally (Macaulay2Doc),

Description
===========

Let $V$ be the irreducible $\mathbf{g}$-module with highest weight $v$.  This
function returns a tally whose keys are the weights appearing in $V$ and whose
values are the multiplicities of these weights. An optional argument "Strategy"
allows to specify which algorithm to use, see character.

+-------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)             |
|                                           |
|o1 = g                                     |
|                                           |
|o1 : simple LieAlgebra                     |
+-------------------------------------------+
|i2 : V=irreducibleLieAlgebraModule({2,1},g)|
|                                           |
|o2 = V                                     |
|                                           |
|o2 : irreducible LieAlgebraModule over g   |
+-------------------------------------------+
|i3 : weightDiagram(V)                      |
|                                           |
|o3 = VirtualTally{{-1, -2} => 1}           |
|                  {-1, 1} => 2             |
|                  {-2, 0} => 1             |
|                  {-2, 3} => 1             |
|                  {-3, 2} => 1             |
|                  {0, -1} => 2             |
|                  {0, 2} => 1              |
|                  {1, -3} => 1             |
|                  {1, 0} => 2              |
|                  {2, -2} => 1             |
|                  {2, 1} => 1              |
|                  {3, -1} => 1             |
|                                           |
|o3 : VirtualTally                          |
+-------------------------------------------+

See also
========

  * multiplicity(List,LieAlgebraModule) (missing documentation)
  * character -- Computes the character of a Lie algebra
    module

Ways to use weightDiagram:
==========================

  * "weightDiagram(LieAlgebra,List)"
  * "weightDiagram(LieAlgebra,Vector)"
  * "weightDiagram(LieAlgebraModule)"

For the programmer
==================

The object weightDiagram, is a method function with options (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2000:0.

weylAlcove -- the dominant integral weights of level less than or equal to l
****************************************************************************

  * Usage:
        weylAlcove(g,l)
  * Inputs:
      * g, an instance of the type LieAlgebra,
      * l, an integer (Macaulay2Doc),

Description
===========

Let $\mathbf{g}$ be a Lie algebra, and let $l$ be a nonnegative integer. Choose
a Cartan subalgebra $\mathbf{h}$ and a base $\Delta= \{
\alpha_1,\ldots,\alpha_n\}$ of simple roots of $\mathbf{g}$. These choices
determine a highest root $\theta$. (See highestRoot). Let
$\mathbf{h}_{\mathbf{R}}^*$ be the real span of $\Delta$, and let $(,)$ denote
the Killing form, normalized so that $(\theta,\theta)=2$. The fundamental Weyl
chamber is $C^{+} = \{ \lambda \in \mathbf{h}_{\mathbf{R}}^*  :
(\lambda,\alpha_i) \ge 0, i=1,\ldots,n \}$. The fundamental Weyl alcove is the
subset of the fundamental Weyl chamber such that $(\lambda,\theta) \leq l$.
This function computes the set of integral weights in the fundamental Weyl
alcove.

In the example below, we see that the Weyl alcove of $sl_3$ at level 3 contains
10 integral weights.

+-----------------------------------------------------------------------------+
|i1 : g=simpleLieAlgebra("A",2)                                               |
|                                                                             |
|o1 = g                                                                       |
|                                                                             |
|o1 : simple LieAlgebra                                                       |
+-----------------------------------------------------------------------------+
|i2 : weylAlcove(g,3)                                                         |
|                                                                             |
|o2 = {{0, 0}, {0, 1}, {0, 2}, {0, 3}, {1, 0}, {1, 1}, {1, 2}, {2, 0}, {2, 1},|
|     ------------------------------------------------------------------------|
|     {3, 0}}                                                                 |
|                                                                             |
|o2 : List                                                                    |
+-----------------------------------------------------------------------------+

Ways to use weylAlcove:
=======================

  * "weylAlcove(LieAlgebra,ZZ)"
  * "weylAlcove(String,ZZ,ZZ)"
  * "weylAlcove(ZZ,LieAlgebra)"

For the programmer
==================

The object weylAlcove, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:1857:0.

zeroModule -- The zero module of a Lie algebra
**********************************************

Description
===========

Returns the zero-dimensional module.

Ways to use zeroModule:
=======================

  * "zeroModule(LieAlgebra)"

For the programmer
==================

The object zeroModule, is a method function (Macaulay2Doc).

-------------------------------------------------------------------------------

The source of this document is in LieTypes.m2:2342:0.