Refactor divisibility checks in `search`

* Keep track of the numeric value of the current sequence each iteration
* Remove obsolete `Polydivisible.divisible`, `digit_weights` and `mask`