Main algorithm: improved handling of variables, substitutions.
The `Split` subalgorithm of the main `Solve` algorithm. Selecting the actual answers between `ans_min` and `ans_max` not implemented yet (function `select`).