One of the theses of TDD is that the tests guide the design and implementation of an under specified (e.g. unknown) problem, given the requirements regarding the outcomes and a complete enough set of test cases. “Theoretically” one
should be able to develop a correct solver without knowing how it works by iterative improvements using TDD. It might not be of good quality, but it should work.
Note: I am quite skeptical of TDD in general.