Text this: A computational solution for the software refactoring problem: a formalism toward an optimization approach