Maxima Function
lc2kdt (expr)
Simplifies expressions containing the Levi-Civita symbol, converting these
to Kronecker-delta expressions when possible. The main difference between
this function and simply evaluating the Levi-Civita symbol is that direct
evaluation often results in Kronecker expressions containing numerical
indices. This is often undesirable as it prevents further simplification.
The lc2kdt
function avoids this problem, yielding expressions that
are more easily simplified with rename
or contract
.
(%i1) load(itensor); (%o1) /share/tensor/itensor.lisp (%i2) expr:ishow('levi_civita([],[i,j]) *'levi_civita([k,l],[])*a([j],[k]))$ i j k (%t2) levi_civita a levi_civita j k l (%i3) ishow(ev(expr,levi_civita))$ i j k 1 2 (%t3) kdelta a kdelta 1 2 j k l (%i4) ishow(ev(%,kdelta))$ i j j i k (%t4) (kdelta kdelta - kdelta kdelta ) a 1 2 1 2 j 1 2 2 1 (kdelta kdelta - kdelta kdelta ) k l k l (%i5) ishow(lc2kdt(expr))$ k i j k j i (%t5) a kdelta kdelta - a kdelta kdelta j k l j k l (%i6) ishow(contract(expand(%)))$ i i (%t6) a - a kdelta l l
The lc2kdt
function sometimes makes use of the metric tensor.
If the metric tensor was not defined previously with imetric
,
this results in an error.
(%i7) expr:ishow('levi_civita([],[i,j]) *'levi_civita([],[k,l])*a([j,k],[]))$ i j k l (%t7) levi_civita levi_civita a j k (%i8) ishow(lc2kdt(expr))$ Maxima encountered a Lisp error: Error in $IMETRIC [or a callee]: $IMETRIC [or a callee] requires less than two arguments. Automatically continuing. To reenable the Lisp debugger set *debugger-hook* to nil. (%i9) imetric(g); (%o9) done (%i10) ishow(lc2kdt(expr))$ %3 i k %4 j l %3 i l %4 j (%t10) (g kdelta g kdelta - g kdelta g %3 %4 %3 k kdelta ) a %4 j k (%i11) ishow(contract(expand(%)))$ l i l i (%t11) a - a g