In mathematics, a base (or basis) B for a topological space X with topology T is a collection of open sets in T such that every open set in T can be written as a union of elements of B. We say that the base generates the topology T. Bases are useful because many properties of topologies can be reduced to statements about a base generating that topology, and because many topologies are most easily defined in terms of a base which generates them.
A base is a collection B of subsets of X satisfying these two properties:
If a collection B of subsets of X fails to satisfy either of these, then it is not a base for any topology on X. (It is a subbase, however, as is any collection of subsets of X.) Conversely, if B satisfies both of the conditions 1 and 2, then there is a unique topology on X for which B is a base; it is called the topology generated by B. (This topology is the intersection of all topologies on X containing B.) This is a very common way of defining topologies. A sufficient but not necessary condition for B to generate a topology on X is that B is closed under intersections; then we can always take B3 = I above.
For example, the collection of all open intervals in the real line forms a base for a topology on the real line because the intersection of any two open intervals is itself an open interval or empty. In fact they are a base for the standard topology on the real numbers.
However, a base is not unique. Many bases, even of different sizes, may generate the same topology. For example, the open intervals with rational endpoints are also a base for the standard real topology, as are the open intervals with irrational endpoints, but these two sets are completely disjoint and both properly contained in the base of all open intervals. 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. The smallest possible cardinality of a base is called the weight of the topological space.