Rename *ll* and *ul* to ll and ul in in-interval
[maxima.git] / share / tensor / tracefree-code / makeQ0-example.mac
blob57edadf13edd8d2a4b5f78929778bf7dde081a20
1 load("makeQ0.mac")$
2 makeQ0(3,3,g,T)$
3 components(T([],[c]),g([a,b],[])*T([],[a,b,c]))$
4 EQ:T0([],[a,b,c])$
5 EQ:EQ,T$
6 EQ:subst(T0[a][b,c],'T0[a,b,c],ic_convert('T0([],[a,b,c])=EQ))$
7 lg:ident(3)$
8 ug:ident(3)$
9 dim:3$
10 T0:[0,0,0]$
11 for i thru dim do T0[i]:zeromatrix(dim,dim)$
12 for i thru 3 do for j thru 3 do for k thru 3 do T[i,j,k]:0$
13 T[3,3,3]:m*z^3$
14 ev(EQ)$
15 T0:factor(T0);
16 /* output shown in paper:
17                                                       [      3                 ]
18         [                 3 ]  [ 0    0       0    ]  [   m z                  ]
19         [              m z  ]  [                   ]  [ - ----    0       0    ]
20         [   0     0  - ---- ]  [                 3 ]  [    5                   ]
21         [               5   ]  [              m z  ]  [                        ]
22         [                   ]  [ 0    0     - ---- ]  [              3         ]
23 (%o15) [[   0     0    0    ], [               5   ], [           m z          ]]
24         [                   ]  [                   ]  [   0     - ----    0    ]
25         [      3            ]  [         3         ]  [            5           ]
26         [   m z             ]  [      m z          ]  [                        ]
27         [ - ----  0    0    ]  [ 0  - ----    0    ]  [                      3 ]
28         [    5              ]  [       5           ]  [                 2 m z  ]
29                                                       [   0       0     ------ ]
30                                                       [                   5    ]
31  */