# When is a disjoint union of manifolds a manifold with boundary?

Let $$X$$ be a topological space, where

• $$X$$ is Hausdorff.
• $$X = A \cup B$$,
• $$A \cap B = \emptyset$$,
• $$A$$ is a topological $$n$$-manifold,
• $$B$$ is a topological $$(n-1)$$-manifold,
• $$X = \overline{A}(X)$$ (the closure of $$A$$ in $$X$$),
• $$B = \circ A(X)$$ (the boundary of $$A$$ in $$X$$),

What are sufficient additional conditions for ensuring that $$X$$ is a manifold with boundary?

An example which shows that extra conditions are needed is $$A = \{(x, \sin(1/x)) : x \in ]0, 1[\}$$ and $$B = \{(0, 0), (1, \sin(1)\}$$ with the subspace topology of $$\mathbb{R}^2$$, i.e. $$X$$ is the topologist's sine. Then $$X$$ is not a manifold with boundary because $$X$$ is not locally connected at $$(0, 0)$$.

Although I'm interested in topological manifolds, if there is a simple answer for smooth manifolds, I'd be interested in that too, just to have more intuition.