kill(all)$

maxima : triplevector product with itensor , version 1.0
peter.vlasschaert@gmail.com,17/11/2022

→ option :

ratprint:false;

load packages
-----------------

load(itensor)$$

dim:3;/*dimension 1,2,3*/

p1:ishow('levi_civita([i,j,k], []) *a([j], []) *'levi_civita([], [k, l, n])* b([l], []) *c([n], []))$
                                                        

p1a:ishow('levi_civita([i,j,k], [])*'levi_civita([], [i, l, n]))$

p1ab:listofvars(p1a);

p1ab1:delete(p1ab[1],p1ab);

p1ab2:makelist([p1ab1[2*ii-1],p1ab1[2*ii]],ii,1,2);

p1aa:ishow(kdelta(p1ab2[1],p1ab2[2]))$

p1aaa:p1a = p1aa;

'levi_civita([i,j,k], [])*'levi_civita([], [i, l, n]) ≠
'levi_civita([i,j,k], [])*'levi_civita([i, l, n], [])
-----------------------------------------------------------------
rhs : result error.
-----------------------------------------------------------------
i = common , result in product(lhs) of two levi_civita 
symbols.
-----------------------------------------------------------------

triple : vector product 
---------------------------
==============================
cross product :x
dot    product :.
==============================

→ vec(a)xvec(bxc) =vec(b)*(vec(a).vec(c)) -vec(c)*(vec(a).vec(b))

 p3:ishow(contract(expand(lc2kdt(p1))));

rem : first term & second term "p3",repeated index → use :sum einstein convention

rem :see → dim:3

rule : 1  → levi_civita
--------

 p4:levi_civita([i, j, j], []);/*index more than ones 2*j*/
 p4a:ev(p4,levi_civita);
 p5:levi_civita([i, j, k], []);   
 p5a:ev(p5,levi_civita);
 p5a1:subst([i=1,j=3,k=2],p5a)$/*odd ,interchange */
 p5a2:ev(p5a1,nouns);
 p6a1:subst([i=3,j=1,k=2],p5a)$/*even ,interchange */
 p6a2:ev(p6a1,nouns);

rule : 2  → kdelta
--------

p7a:kdelta([i,i], [1,2])$/*  different */
p7a1:ishow(kdelta([1,2], [1,2]))$/*same*/

p7a3:ishow(kdelta([i],[i]));

sum(kdelta([i],[i]),i,1,3) = 3

problem : no result
------------------------

assume(notequal(uu,ww));

[is(uu≠ww),is(uu=ww)];

p7a4:kdelta([uu],[ww])$

example : uu≠ww
----------------------

p7a41:ishow(ev(p7a4,kdelta))$
p7a42:ishow(ev(p7a4,nouns))$

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

rem : load(vect) can't be loaded in combination with load(itensor).

→ vec(a).vec(bxc)

p8:ishow( a([j], []) *'levi_civita([j, l, n], [])* b([l], []) *c([n], []))$
p8a:ishow(contract(expand(lc2kdt(p8))));

final result:

p9:a([i], []) *'levi_civita([], [i, j, k])* b([j], []) *c([k], [])$
p9a:ishow(contract(expand(lc2kdt(p9))));

to find other result : cyclic permutation
-------------------------------------------------
i→j→k→i

p10:psubst([i=j,j=k,k=i],p9);
p10a:ishow(contract(expand(lc2kdt(p10))));

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