qojulia / QuantumCumulants.jl

Generalized mean-field equations in open quantum systems
Other
70 stars 13 forks source link

Sums with IndexedVariable simplifies incorrectly #189

Closed andia89 closed 1 week ago

andia89 commented 8 months ago

Related to #188 when using IndexedVariables some resulting sums get simplified incorrectly

Example:

@cnumbers N
ha = NLevelSpace(:atoms, 2)
i = Index(ha,:i,N,ha)
gi = IndexedVariable(:g, i)
s=∑(gi,i)+∑(gi,i)
SymbolicUtils.simplify(s)

outputs

2N*gi

which is not correct. Is the missing of an operator an issue?

ChristophHotter commented 5 months ago

Thanks for this issue and sorry for the very late reply. I solved this in version 0.2.27.