Experimenting with the main portion of the algorithm