There are affine decompositions, such as the magnetization $2L^{-1} \sum_iS_i^z$, that don't have a parameter-dependent coefficients. In these cases it would be sensible to have a coefficient_map that is just a vector of coefficients instead of a function returning that vector.
Then it would be possible to dispatch compress on AffineDecomposition{T, <:AbstractArray{<:Number}} which would return the (constant) compressed matrix directly instead of another AffineDecomposition.
We would then also avoid the inconvenient m_reduced = m([]) definitions in the docs examples.
There are affine decompositions, such as the magnetization $2L^{-1} \sum_iS_i^z$, that don't have a parameter-dependent coefficients. In these cases it would be sensible to have a
coefficient_map
that is just a vector of coefficients instead of a function returning that vector.Then it would be possible to dispatch
compress
onAffineDecomposition{T, <:AbstractArray{<:Number}}
which would return the (constant) compressed matrix directly instead of anotherAffineDecomposition
.We would then also avoid the inconvenient
m_reduced = m([])
definitions in the docs examples.