Geometry is one of the oldest sciences in the world. It began with the earliest needs of people to find ways to construct buildings or other objects of daily use. At the latest in Ancient Greece about 500 D.C., the approach to geometry changed dramatically.
The practical need for measuring land and protecting the property transformed, as Greek scholars and philosophers abstracted some terms and started to study their interrelationships: point, straight line, surface and space. The key question was not how things can be constructed, but why they can be constructed. This new approach was possible due to the first axiomatic system constructed by Euclid of Alexandria (325 BC - 265 BC) in his Elements. This work was perceived as a standard work for almost 2000 years. But many mathematicians criticized Euclid's definitions since they introduced geometrical concepts like points, straight lines, triangles, circles, etc. explaining them only vague using other, undefined concepts (ex. "A point is that of which there is no part." or "The ends of a line are points."). However, the revolutionary approach of Euclid was to assume a few statements and to derive all other theorems from this shortlist. Using this approach, Euclid came up with 13 books of the "Elements" containing hundreds of theorems which have been rigorously derived from only 5 assumptions, he called postulates. In this sense, Euclid was the inventor of the axiomatic method, which remained since then the standard approach of creating mathematical theories.
Nevertheless, the Euclid's Fifth Postulate was criticized. Many scholars and mathematicians argued whether it is independent of the remaining postulates of Euclid. If not, it could be simply proven using these remaining postulates, without having to be assumed. It would make Euclid's logical system even more powerful.
Some of the first scholars of this kind were Proclus (411 - 485) and Omar Khayyam (1048 - 1131). They and many others after them tried to provide rigorous proof for the Fifth Postulate, which would convict it for being a superfluous postulate in Euclid's theory. However, all of these proofs were incorrect. We recognize today that they depended on the unproven assumption that parallel lines are everywhere equidistant. It can be even shown that this assumption is equivalent to the Fifth Postulate. Today, we know that there are valid geometries, in which the Fifth Postulate is not true.
A remarkable attempt to derive the Fifth Postulate from others was done by Giovanni Saccheri (1667 - 1733). His approach was to prove it by assuming that it was not true and trying to derive a contradiction. His argumentation was very strict and he managed to prove different interesting theorems based on the assumption the Fifth Postulate was wrong. In particular, he proved that if it was wrong that it would follow that the interior angles of triangles would add up to less than $180^\circ$. He also found that there must exist parallel lines that approach each other but never meet. Saccheri concluded that this result is "repugnant to the nature of straight lines", but he knew that this is not a contradiction up to the standards of rigor he had set for himself. Thus, while Saccheri finally failed to prove the Fifth Postulate, he is remembered for proving many results considered today as valid theorems in other systems of geometry. As such, Saccheri was very close to the discovery of what we today call "non-Euclidean" geometries.
The solution to the problem whether the Fifth Postulate is needed or not was found independently by the Russian mathematician Nikolai Lobachevsky (1792 - 1856), published in 1829, and a young son of a Hungarian mathematician János Bolyai (1802 - 1860), who sent the work of his son to the great contemporary German mathematician Carl Friedrich Gauss (1777 - 1855) for review. Gauss answered that it duplicated his unpublished investigations. Despite the secondary question, who can be credited for the discovery, Lobachevsky, Bolyai and/or Gauss have shown that the negation of the Fifth Postulate while keeping the remaining axioms led to other valid, "non-Euclidean" geometries.
In a sense, these three mathematicians achieved no new results. Also, before them, Khayyam and Saccheri managed to find valid geometrical theories based on the assumption the Fifth Postulate was not true. But their new achievement was to recognize these theories as such.
Still, the question, whether these "non-Euclidean" geometries are consistent, i.e. it one could never prove a contradiction inside these theories, remained unproven. The proof was worked out by Eugenio Beltrami (1835 - 1900) in 1868.
The old question of the Firth Postulate was now solved. It meant that proving the Fifth Postulate from the other four postulates is a logical impossibility, since both, its truth and its falseness led to consistent theories.
Today, we call versions of non-Euclidean geometry, in which the Fifth Postulate is not true, hyporbolic geometries. Some of the features of these geometries are that the interior angles of triangles add up to less than $180^\circ$ and that there exist straight lines approaching each other asymptotically but never meeting - the phenomenon which Saccheri - from his contemporary perspective - still had to declare to be "repugnant to the nature of the straight line".
In the Euclidean geometry, in a setup with a straight line and a given point which lies not on the straight line, there is exactly one line that passes the point and is parallel to the previous straight line. In the hyperbolic case, there are infinitely many such parallel straight lines going through this point. The careful reader will notice that only the uniqueness part of the Fifth Postulate is violated. The existence part continues to hold.
Therefore, the question arises if there are consistent geometries, in which no such parallel lines exist. This question was answered by Bernhard Riemann (1826 - 1866) who realized that such geometry can be found on the surface of a sphere. A "straight line" on the surface of a sphere is a path known as the great circle - a circle with a center coinciding with the center of the sphere. This is easy to understand since the only way to move as straight as possible on the surface of a sphere is to move along a great circle. Now, two distinct great circles on a sphere intersect each other (in fact, they do even twice, not only once). In other words, different straight lines on the surface of a sphere are never parallel!
But Riemann had to deal yet with another problem. In the geometry he has found, all remaining axioms of Euclid should be valid. In particular, the Segment Extension Postulate seemed to be violated on the surface of a sphere. However, Riemann noticed that reading the axiom carefully, it only requires that a segment can be extended to a longer one. It does not require that we can extend the segment to any length we wish. With this reading of the Segment Extension Postulate, it is not violated in the geometry found by Riemann. This alternative kind of non-Euclidean geometry is called today elliptic geometry.
As mentioned above, Euclid provided only vague definitions of the basic concepts in geometry, which are points, straight lines, and planes. He just replaced them by other, undefined concepts (for instance, according to Euclid, "a point is that of which there is no part").
Later authors of other axiomatic systems, including those for hyperbolic and elliptic geometries, stuck to this tradition and either presupposed that the readers are already familiar with these primitive concepts, or left these concepts explicitly as "undefined", avoiding any attempt of a strict definition. Thus, all of the postulates and theorems developed in these geometries relied on the ability of the readers to visualize "points", "lines" and "planes" by comparing them with real-world objects.
David Hilbert (1862 - 1943) had the radical idea to detach the postulates from real-world objects. Progresses made in set theory enabled Hilbert to develop an axiomatic system for geometry he published in 1899, which is independent of real-world objects. Hilbert is supposed to have said: "One must be able to say at all times - instead of points, straight lines, and planes - tables, chairs, and beer mugs." Hilbert defines points, lines, and planes simply as elements of arbitrary sets. The only thing that counts for Hilbert is how these objects are related to each other rather than which specific properties they have. The cost of this abstraction was the relatively high number of $21$ axioms which could be grouped into the following types:
Euclidean Geometry is full of mathematical theorems - most of which very popular - like the Pythagorean theorem - all summarizing what we know about lengths, positions, angles and shapes and what we are able to relate to our every-day experience. In this respect, the Euclidean Geometry is highly demonstrative and intuitive, because it seems to model the real-world quite well.
But it took centuries to recognize that the Euclidean geometry is a good approximation of the real world only in small scales, as we experience them on the surface of our planet Earth. For instance, it is good enough for practical problems like constructing buildings, pyramids, or measuring distances. Astonishing discoveries of the 19th and 20th centuries, like Albert Einstein's general relativity, have shown that non-Euclidean geometries even better model the real world in greater scales and are dependent on the gravitational field. This can be observed in the so-called gravitational lens. A straight line is usually the shortest connection between two points and light rays always take this trajectory. But in a gravitational lens, it is not the case.
Illustration demonstrating how a gravitational lens Credit: NASA, ESA, L. Calcada
The gravity of a massive object in the universe, like a large galaxy or a black hole, bends light rays of a distant object, creating multiple images of it. Thus, there are more than two shortest" connections between two points in the universe - a bright object and the eye of the observer on Earth. In other words, there is more than one straight line through two distinct points, contradicting the first of "Euclid's axioms which seems to be undisputed under "normal" conditions we experience on Earth.
In the 20th and 21st century, also other axiomatic systems for plane geometry have been developed, reducing the number of required axioms even further. One approach was done in 1932 by George Birkhoff (1884 - 1944) who based his only 4 axioms on real numbers. He wanted to approach geometry via facts embodied by the scale and protractor. However, he used the terms "point", "line", "distance" and "angle" as primitive, without defining them.
In 1961, the School Mathematics Study Group, a group of US academics and teachers sponsored by the U.S. National Science Foundation who focussed to reform mathematical eduction, published a set of $22$ postulates (also known as "SMSG Postulates") which became quite influential for U.S. high-school geometry texts.
Yet another approach was published in 2013 in [^6260], using $9$ postulates for "neutral geometry", which can be complemented by either two further axioms leading to Euclidean geometry or by one axiom, leading to hyperbolic geometry. The primitive terms in this book are "point", "line", "distance" (between points) and "measure" (of an angle). In this book, some of the redundant SMSG Postulates have been eliminated, and some have been rephrased to be more intuitive for students.
The variety of axiomatic systems developed in geometry, starting by Euclid and followed by many others, have shown that conflicting systems of postulates might work equally well as logical foundations for geometry. This is exemplary for the axiomatic method as such and works perfectly well also for other mathematical disciplines. The axiomatic method is a powerful tool to develop such mathematical theories, but it raises a rather uncomfortable question to all who consider postulates as evident truths: What exactly are we doing when we accept postulates?
The history of geometry shows that the choice of postulates is in some sense arbitrary. Once we have chosen a set of postulates, avoiding contradictions, we can derive whatever theorems from them. This insight influenced the development of logic in the 20th century, especially the discoveries of Gödel in his Incompleteness Theorems as principal limits of mathematics and logic and the philosophical question "What is truth?"