In mathematics, an H-space, or a topological unital magma, is a topological space X (generally assumed to be connected) together with a continuous map μ : X × X → X with an identity element e so that μ(e, x) = μ(x, e) = x for all x in X. Alternatively, the maps μ(e, x) and μ(x, e) are sometimes only required to be homotopic to the identity (in this case e is called homotopy identity), sometimes through basepoint preserving maps.