You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to create an NBodyMatrixElement of a zero-body operator fails with the following error:
julia>using EnergyExpressions
julia>import EnergyExpressions: NBodyMatrixElement
julia> a=SlaterDeterminant([:a,:b])
a(1)b(2) -a(2)b(1)
julia>NBodyMatrixElement(a, IdentityOperator{0}(), a, overlap_matrix(a,a))
ERROR: UndefVarError: A not defined
Stacktrace:
[1] EnergyExpressions.OrbitalMatrixElement(::Tuple{}, ::IdentityOperator{0}, ::Tuple{}) at /home/jagot/.julia/dev/EnergyExpressions/src/nbody_matrix_elements.jl:85
[2] NBodyMatrixElement(::SlaterDeterminant{Symbol}, ::IdentityOperator{0}, ::SlaterDeterminant{Symbol}, ::SparseArrays.SparseMatrixCSC{EnergyExpressions.NBodyTerm,Int64}) at /home/jagot/.julia/dev/EnergyExpressions/src/nbody_matrix_elements.jl:442
[3] top-level scope at none:0
[4] run_backend(::REPL.REPLBackend) at /home/jagot/.julia/packages/Revise/gStbk/src/Revise.jl:771
[5] (::getfield(Revise, Symbol("##58#60")){REPL.REPLBackend})() at ./task.jl:259
This is because the type cannot be inferred for the tuples of zero length. However, the OrbitalMatrixElement should not be necessary for zero-body operators, since the full energy expression consists solely of OrbitalOverlaps.
The text was updated successfully, but these errors were encountered:
Trying to create an
NBodyMatrixElement
of a zero-body operator fails with the following error:This is because the type cannot be inferred for the tuples of zero length. However, the
OrbitalMatrixElement
should not be necessary for zero-body operators, since the full energy expression consists solely ofOrbitalOverlap
s.The text was updated successfully, but these errors were encountered: