Added some faster implemented versions of the backtrack algorithm