Calculating the principal character by hand is time-consuming and repetitive: a perfect job for the computer! Below is code to calculate the prinicipal character for affine Lie algebras. For each, the command for finding the (s)=(s_0,s_1,s_2,...,s_n)-specialization for X sub N upper r is: charform(X,N,r,[s_0,s_1,s_2,...,s_n]). The result is a vector of the form [a_1,a_2, ..., a_{m-1}, a_0] which should be interpreted in the following way:

So, to find
we put in charform(C,3,1,[0,1,0,0]);. The result will come out as [0,-1,0,0,0,0,0,-1,0,0] which is to be interpreted as
