The algebraic determination of the topological type of the complement of a knot