Mathematics is the foundation of architecture. The relationship between math and architecture dates back to the earliest examples of man's building of functional structures. In ancient Byzantine, Egyptian, Greek, Islamic and Roman societies, mathematicians were architects, and architects were mathematicians. Mathematicians were called upon when great structures like pyramids, stadia, temples, ziggurats and irrigation projects were to be designed and built.