What is the dimension of a topology? We know about the manifold dimensions of topological objects. I have a query, as every vector space has Hamel basis and the dimension of a vector space is defined as the number of elements in the basis set. My question is why this definition of dimension is not used to defined the basis of a topological space. Is that the reason, a topological space may not have same number of elements in its every basis?
 A: Your idea, of defining the dimension using a basis of a topological space, does not work [Wikipedia]:

However, a base is not unique. Many bases, even of different sizes, may generate the same topology. [...] In contrast to a basis of a vector space in linear algebra, a base need not be maximal; indeed, the only maximal base is the topology itself. In fact, any open set generated by a base may be safely added to the base without changing the topology.

Your idea now might be: "let's take the smallest possible basis and define the dimension as the cardinality of that basis". This is actually the weight of a topology [Wikipedia]:

The smallest possible cardinality of a base is called the weight of the topological space.

This is a topological invariant, so you could do this. But then the topological dimension then will rarely (if ever) agree with other definitions of dimension, as @MikeMiller mentioned in his comment.
In case you want to know how topologists usually define the (topological) dimension of a topological space, first recall the concepts of order and refinement [Munkres]:

A collection $\mathcal{A}$ of subsets of the space $X$ is said to have order $m+1$ if some point of $X$ lies in $m+1$ elements of $\mathcal{A}$, and no point of $X$ lies in more than $m+1$ elements of $\mathcal{A}$.
Given a collection $\mathcal{A}$ of subsets of $X$, a collection $\mathcal{B}$ is said to refine $\mathcal{A}$, or to be a refinement of $\mathcal{A}$, if for each element $B$ of $\mathcal{B}$, there is an element $A$ of $\mathcal{A}$ such that $B \subseteq A$.

With these notions we can define the dimension of topological space [Munkres]:

A space $X$ is said to be finite dimensional if there is some integer $m$ such that for every open covering $\mathcal{A}$ of $X$, there is an open covering $\mathcal{B}$ of $X$ that refines $\mathcal{A}$ and has order at most $m+1$. The topological dimension of $X$ is defined to be the smallest value of $m$ for which this statement holds; we denote it by $\dim X$.

The nice thing about this definition is that, in some major cases, it does agree with other notions of dimension:

*

*Any compact subspace $X \subset \mathbb{R}^n$ has dimension $\leq n$. E.g. $[0,1]  \subset \mathbb{R}$ has dimension $1$.

*Any compact $m$-manifold has dimension $m$.

You can read more about this definition on the Wikipedia article on Lebesgue covering dimension.
