definition of neighbourhood basis a very simple question I find different answers to online: 
In topology, what is the definition of a neighbourhood basis 
for a set, and what is the definition of the topology generated by it? 
 A: Suppose we have a set $X$ and for each $x \in X$ we have a collection of subsets of $x$ called $\mathscr{B}(x)$. Then we call this assignment from $x$ to $\mathscr{P}(\mathscr{P}(X))$ a system of neighbourhood bases for $X$ iff the following axioms hold:


*

*$\forall x \in X: \mathscr{B}(x) \neq \emptyset$.

*$\forall x \in X: \forall B \in \mathscr{B}(x): x \in B$. 

*$\forall x \in X : \forall U,V \in \mathscr{B}(x): \exists W \in \mathscr{B}(x): W \subseteq U \cap V$.

*$\forall x \in X: \forall U \in \mathscr{B}(x): \exists V \in \mathscr{B}(x) : \forall y \in V: \exists W \in \mathscr{B}(y) : W \subseteq U$.


There is an alternative axiom 4, which one encounters too and which in the end gives the same topology, but which is less "pure" as it were, because it involves a subset that is not in some $\mathscr{B}(x)$:
4'. $\forall x \in X: \forall U \in \mathscr{B}(x): \exists V \subseteq X: (x \in V \subseteq U) \land (\forall y \in V: \exists W \in \mathscr{B}(y): W \subseteq V)$.
In either system we define $O \subseteq X$ to be open iff $\forall x \in O \exists B \in \mathscr{B}(x): B \subseteq O$. So axiom 4' can be reformulated (using the observation that the $V$ in it is open according to this definition) as "every neighbourhood $U$ of $x$ contains an open set $V$ containing $x$ that sits inside $U$". 
One can easily show that this defines a topology (4 or 4' are not needed for that, even). 
In this answer I check that the topology on $X$ so defined is unique with the property that the original $\mathscr{B}(x)$ form a neighbourhod base for that topology, based on the 4' axiom.
In this answer there is a similar check based on the 1-4 axioms.
