symbolic math - Simplification rule not being applied properly -


i'm trying use dirac bra-ket notation in maxima using code here http://raoul.koalatux.ch/sites/ladderoperator/ladder_operator.html

declare(bra, nonscalar); declare(ket, nonscalar); dotscrules:true; matchdeclare(m,lambda([t],featurep(t,integer))); matchdeclare(n,lambda([t],featurep(t,integer)));  tellsimp(bra(m).ket(n), kron_delta(m,n)); 

for expressions works:

bra(0) . ket(0); ket(1) . bra(0) . ket(0); bra(1) . ket(1) . bra(0) . ket(0); 

all simplify correctly, but

bra(1) . ket(1) . bra(0); 

fails simplify bra(0). how can maxima simplify case?

i think can start this:

declare(bra, nonscalar); declare(ket, nonscalar); dotscrules:true; matchdeclare(m,lambda([t],featurep(t,integer))); matchdeclare(n,lambda([t],featurep(t,integer)));  tellsimp(bra(m).ket(n), kron_delta(m,n));  simp:false; matchdeclare(aa, true); matchdeclare(bb, true); matchdeclare(cc, true); tellsimp (aa.(bb.cc),(aa.bb).cc); simp:true;  /* tests */ bra(0) . ket(0); ket(1) . bra(0) . ket(0); bra(1) . ket(1) . bra(0) . ket(0); bra(1) . ket(1) . bra(0); ket(1) . bra(1) . ket(1); 

Comments

Popular posts from this blog

php - Why I am getting the Error "Commands out of sync; you can't run this command now" -

linux - Does gcc have any options to add version info in ELF binary file? -

java - Are there any classes that implement javax.persistence.Parameter<T>? -