 The algorithm was probably not discovered by Euclid, who compiled results from earlier mathematicians in his "Elements".The mathematician and historian B. L. van der Waerden suggests that Book VII derives from a textbook on number theory written by mathematicians in the school of Pythagoras.The algorithm was probably known by Eudoxus of Cnidus (about 375 BC).