Question: Two Simplify two answers

hi,

    In my note,i use Simplify or map(Simplify,eqs) to make the expression more simple,but i meet a fail,the answers i got lies two diffrent between Eq.(8) and Eq.(9) caused by last term ,i guess it's a bug in using Physics package,if not,how can i do, please tell me.

thanks.

NULL

restart; with(Physics); Setup(mathematicalnotation = true); Physics:-Version()[2]

`2014, January 6, 3:40 hours`

(1)

Setup(op = {a, ap})

`* Partial match of  'op' against keyword 'quantumoperators'`

 

[quantumoperators = {a, ap}]

(2)

ap := Dagger(a)

Physics:-Dagger(a)

(3)

Setup(alg = {%Commutator(a, ap) = 1})

`* Partial match of  'alg' against keyword 'algebrarules'`

 

[algebrarules = {%Commutator(a, %Dagger(a)) = 1}]

(4)

``

N := Physics:-`*`(ap, a)

Physics:-`*`(Physics:-Dagger(a), a)

(5)

K__0 := Physics:-`*`(ap, a)+1/2; 1; K__d := Physics:-`*`(a, sqrt(N)); 1; K__u := Dagger(K__d)

Physics:-`*`(Physics:-Dagger(a), a)+1/2

 

Physics:-`*`(a, Physics:-`*`(Physics:-Dagger(a), a)^(1/2))

 

Physics:-`*`(Physics:-`*`(Physics:-Dagger(a), a)^(1/2), Physics:-Dagger(a))

(6)

C := K__0^2-Physics:-`*`(Physics:-`*`(K__d, K__u)+Physics:-`*`(K__u, K__d), 1/2)

Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a)+1/2, 2)-(1/2)*Physics:-`*`(a, Physics:-Dagger(a), a, Physics:-Dagger(a))-(1/2)*Physics:-`*`(Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a), 1/2), Physics:-Dagger(a), a, Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a), 1/2))

(7)

ans1 := Simplify(C)

1/4-(3/2)*Physics:-`*`(a, Physics:-Dagger(a))+(1/2)*Physics:-`*`(Physics:-`^`(a, 2), Physics:-`^`(Physics:-Dagger(a), 2))-(1/2)*Physics:-`^`(-1+Physics:-`*`(a, Physics:-Dagger(a)), 3/2)

(8)

ans2 := map(Simplify, C)

1/4-2*Physics:-`*`(a, Physics:-Dagger(a))+Physics:-`*`(Physics:-`^`(a, 2), Physics:-`^`(Physics:-Dagger(a), 2))-(1/2)*Physics:-`*`(a, Physics:-Dagger(a), a, Physics:-Dagger(a))-(1/2)*Physics:-`*`(Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a), 1/2), Physics:-Dagger(a), a, Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a), 1/2))

(9)

Term3 := op(3, C)

-(1/2)*Physics:-`*`(Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a), 1/2), Physics:-Dagger(a), a, Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a), 1/2))

(10)

Simplify(Term3) = -Physics:-`*`(Physics:-`*`(ap, a)^2, 1/2)

-(1/2)*Physics:-`*`(Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a), 1/2), Physics:-Dagger(a), a, Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a), 1/2)) = -(1/2)*Physics:-`^`(Physics:-`*`(Physics:-Dagger(a), a), 2)

(11)

ans3 := Simplify(subsop(3 = -Physics:-`*`(Physics:-`*`(ap, a)^2, 1/2), C))

-1/4

(12)

  
"here,we can find a quite difference between Eq.(8) and Eq.(9)."

obviously,there lies a wrong result at last term in Eq.(8).

  The question is how we can simplify the style as last term in Eq.(9) even the soft can work correctly.

  yes,i want get a result from lhs(11) to rhs(11) through 'Simplify',in fact,in quantum operator computation,we can meet much more like sqrt(ap*a)*ap*a*sqrt(ap*a),exp(ap*a)*ap*a*exp(-ap*a),sin(ap*a)*a*ap*sin(ap*a),etc.if happen,can we  make this more simple with soft?

 

NULL

NULL



Download question_13.12.29.mw

Please Wait...