Motivation of the definition of topology In general topology the the definition of topology is the following:

Let X be a non empty set. A set $\tau$ of subsets of $X$ is said to be a topology on $X$ if

*

*$X \in \tau$ and $\emptyset \in \tau$

*The union of any (finite or infinite) number of sets in $\tau$ belongs to $\tau$

*The intersection of finitely many elements of $τ$ is an element of $τ$.


My question is, why do we define the topology on a set this way?
Why does the finite or infinite union of sets in $\tau$ belongs in $\tau$ but only the finite intersection of elements of $\tau$ belongs on $\tau$?
And why do we need to have that  $X \in \tau$ and $\emptyset \in \tau$?
What is the motivation for this definition?
 A: Intuitively an open set is  a set with the property that if a point $x$ is in  it then all points sufficiently close to it are also in the set. When you study such sets in the real line you will quickly discover that unions of such sets always have this property but the same is not true for intersections. For example the intervals $(-\frac  1n , \frac  1 n)$ are all open. The intersection of these sets is $\{0\}$. Now $0$ is in this set but points close to $0$ are not. Hence intersection of open sets need not be open. However we can show that finite  intersections of open sets are open.
A: You ask a good question. I agree with the two answers above but wanted to add something. As a mathematician coming to these definitions they do seem arbitrary and perhaps lacking in justification. I found myself asking the same question about the axioms for a category. I think what happens is that mathematicians find lots of interesting examples of spaces (e.g. the metric spaces given above). They then develop a set of axioms for a new thing (a topological space). The axioms are chosen so they are strong enough to prove many interesting theorems but weak enough to admit loads of interesting and varied examples as topological space (for example the particular point topology https://en.wikipedia.org/wiki/Particular_point_topology in which a single point set is compact but its closure is not compact (if the space is infinite) - crazy!). Note that the axioms of topology evolved (some people included a separation axiom https://en.wikipedia.org/wiki/History_of_the_separation_axioms). I think groups, categories, rings and fields are all a bit like this. This is quite different from natural numbers, real numbers and geometry which all seem to be understood by us intuitively. A difficult question is whether ZF Set Theory is of the first type (axioms chosen by humans) or the second (things that 'really' exist or at least are consistent with some intuition, real or conceptual).
A: Topological spaces are generalization of metric spaces, where 'open' sets are defined by containing an open ball at each point of the set. And the property of continuousness in metric spaces is equivalent to reflecting open sets. This inspires us to extract the properties of open sets from metric spaces, which forms the topological space axioms.
