Question: why eval not substitute the following expression?

Hi guys I showing the problem in the following document, and the file is attached

restart; Setup(mathematicalnotation = true); with(Physics); Setup(op = {A, B, S, omega, v, x, x_, `ω_`})

_______________________________________________________; "_noterminate"

(1)

 

 

ok now here is the question: I first initialize some matrices (noncommutative objects) with Setup(op = {A, B, S, omega, v, x, x_, `ω_`}) then I have an expression which is:

 

(Iota[c][i]*Dagger(diff(x[i](t), t)).Dagger(A[i]).A[i].(diff(x[i](t), t)))/L[i](t)^2

Iota[c][i]*Physics:-`*`(Physics:-Dagger(diff(x[i](t), t)), Physics:-Dagger(A[i]), A[i], diff(x[i](t), t))/L[i](t)^2

(2)

 

Now I want to substitute the expression Dagger(A[i])*A[i]with -A[i]^2,so I write
eval(Iota[c][i]*Physics[`*`](Physics[Dagger](diff(x[i](t), t)), Physics[Dagger](A[i]), A[i], diff(x[i](t), t))/L[i](t)^2, Dagger(A[i])*A[i] = -A[i]^2)

Iota[c][i]*Physics:-`*`(Physics:-Dagger(diff(x[i](t), t)), Physics:-Dagger(A[i]), A[i], diff(x[i](t), t))/L[i](t)^2

(3)

now guess what it doesn't substitute the expression. Help me please !!. for now I have some clues:
1-its because I initialize the Matrices as noncommutative objects.
2-altering the substitution expression to this one will fix the issue (but what the hell!! let's say I beside of x I have y so now I most write a similar expression for y and so on)

  Dagger(diff(x[i](t), t))*Dagger(A[i])*A[i]*(diff(x[i](t), t)) = -Dagger(diff(x[i](t), t))*A[i]^2*(diff(x[i](t), t))

Physics:-`*`(Physics:-Dagger(diff(x[i](t), t)), Physics:-Dagger(A[i]), A[i], diff(x[i](t), t)) = -Physics:-`*`(Physics:-Dagger(diff(x[i](t), t)), Physics:-`^`(A[i], 2), diff(x[i](t), t))

(4)

eval(Iota[c][i]*Physics[`*`](Physics[Dagger](diff(x[i](t), t)), Physics[Dagger](A[i]), A[i], diff(x[i](t), t))/L[i](t)^2, Physics[`*`](Physics[Dagger](diff(x[i](t), t)), Physics[Dagger](A[i]), A[i], diff(x[i](t), t)) = -Physics[`*`](Physics[Dagger](diff(x[i](t), t)), Physics[`^`](A[i], 2), diff(x[i](t), t)))

-Iota[c][i]*Physics:-`*`(Physics:-Dagger(diff(x[i](t), t)), Physics:-`^`(A[i], 2), diff(x[i](t), t))/L[i](t)^2

(5)

 

``


 

Download MapleProblem.mw

 

Please Wait...