Glueing manifolds with boundaries and Seifert-Van Kampen theorem I've seen many times the following application of the SVK theorem:

Let $M$ and $N$ two smooth $n$-manifolds ($n\ge 3$) with boundary  and suppose that they have the same boundary $B$. Now, after glueing $M$ and $N$ along $B$ we obtain:
  $$X=M\cup_{B} N$$
  At this point we can apply the SVK to the triple $M$, $N$, $M\cap N=B$ in order to calculate the fundamental group of $X$.


The problem is that $M$, $N$ and $B$ are in general not open in $X$ (once that they are glued together). On the other hand we know that the openness condition is necessary in the proof of SVK theorem. 
 A: Let $M$ be a smooth manifold with boundary. A neighborhood of $\partial M$ is called a collar neighbourhood if it is the image of a smooth embedding $[0, 1)\times\partial M \to M$ that restricts to the identification $\{0\}\times\partial M \to \partial M$.
Every smooth manifold with nonempty boundary has a collar neighbourhood - see Lee's Introduction to Smooth Manifolds (second edition), Theorem $9.25$. 
As $B$ is the boundary of $M$, it has a collar neighbourhood $C \subset M$ and as $B$ is the boundary of $N$, it has a collar neighbourhood $D \subset N$. Then $C\cup D$ becomes an open neighbourhood of $B$ in $X = M\cup_B N$. Furthermore, $C\cup D$ deformation retracts onto $B$, so $\pi_1(C\cup D, b_0) \cong \pi_1(B, b_0)$ for all $b_0 \in B$.
So we really want to apply the Seifert-van Kampen Theorem to the following open sets of $X$: $M\cup D$ (which deformation retracts to $M$), $C\cup N$ (which deformation retracts to $N$), and $C\cup D$ (which deformation retracts to $B$). 
Note, it doesn't matter which collar neighbourhoods we take as the fundamental groups of the resulting open sets are independent of $C$ and $D$.
