Refactoring code, and trying to do initial implementation of genetic algorithm application