Closed thchr closed 1 year ago
Should be fixed by https://github.com/thchr/SymmetryBases.jl/commit/3f3bf09fa067a893ebcd53f85d24dc0e05da3e3d now.
(But beware that the solution is not unique in general: it is just some minimum norm solution - not even sure if necessarily a global minimum)
Reading a recent preprint, I realized that the docstring for
decompose
, which claims it returns a minimum-norm solution, is not correct. It seems that even though the argument works for real-coefficient solutions, it does not work the solution space is restricted to integer coefficients. My previous thinking was described here: https://github.com/thchr/SymmetryBases.jl/blob/7836d9efd5ed6301ecf82c0c32e9bcf3a6a26d5d/src/symvec.jl#L374-L379Below is an example that demonstrates that it is possible to obtain a smaller-norm solution:
I don't know what the best way to fix this robustly and yet cheaply could be. There is rarely a need to guarantee having the minimum-norm solution, but right now, the docs for
decompose
are not factual. Specifically, we currently, misleadingly, write: https://github.com/thchr/SymmetryBases.jl/blob/7836d9efd5ed6301ecf82c0c32e9bcf3a6a26d5d/src/symvec.jl#L340-L342It could potentially be fixed by using the Pajarito solver above, but I don't know if the approach guarantees a solution - and it is also not super fast. Conceivably, it could be very slow in some situations.