modify ordering of quadratic and binomial roots

This will merge #8237 with your PR while eliminating modifications to the trivial roots calculation.
changed to "numerical_domain"; this is a variable that might need to be updated.