Example 1.
Create the Lie algebra data structure for the Lie algebra of all 2 x 2 matrices.
Let us check that this result agrees with the direct computation of gl(2) using LieAlgebraData.
Example 2.
We create the 6 dimensional Lie algebra of all 3 x 3 Upper triangular matrices. This is the standard example of a solvable algebra.
Example 3.
We create the 8 dimensional Lie algebra of all 3 x 3 trace-free matrices. This is the classical matrix algebra sl(3, R). It is simple (i.e. semisimple and indecomposable). First we create the Lie algebra of all 3 x 3 matrices.
Now define an auxiliary 3 dimensional space, call it R3. Choose any coordinates labels.
Define the standard volume form on R3.
Find the subalgebra of gl(3) which preserves this volume form.
Note that each of the matrices represented by the elements of the list SL3 are trace-free.
Example 4.
We create the 6 dimensional Lie algebra of all 4 x 4 skew-symmetric matrices. This is the classical matrix algebra so(4, R). It is semisimple but not simple (that is, it is decomposable). First we create the Lie algebra of all 4 x 4 matrices.
Now define an auxiliary 4 dimensional space, call it R4. Choose any coordinates labels.
Define the standard Euclidean metric tensor on R4.
Find the subalgebra of gl(3) which preserves this volume form.
Note that each of the matrices represented by the elements of the list SO4 are skew-symmetric.