Non trivial vector bundle over non-paracompact contractible space

Let $U$ and $V$ be two copies of the real line and make a space $X$ by gluing them by the identity along the strictly positive half-line: $x\in U$ equals $x\in V$ for $x>0$. Now make a rank one vector bundle over this space by taking a trivial bundle over each of the lines: glue $U\times\mathbb R$ to $V\times \mathbb R$ by identifying $(x,y)\in U\times\mathbb R$ with $(x,f(x)y)\in V\times\mathbb R$ for $x>0$. Let's choose the clutching function to be $f(x)=x$, or any other nowhere zero continuous function of positive real $x$ that cannot be extended to a nowhere zero function of all real $x$. Surely $X$ is contractible, but the bundle can't be trivial since the function $f:U\cap V\to GL_1(\mathbb R)$ cannot be expressed as the quotient of a function extendible to $U$ and a function extendible to $V$, since that would make it itself extendible to all of $\mathbb R$.


To complement the answer providing a non-Hausdorff example, here is an example on a non-paracompact Hausdorff space as given in Schröer's Pathologies in cohomology of non-paracompact Hausdorff spaces arxiv:1309.2524.

I will slightly simplify the space in question, though. Let $(X,0)$ be the wedge sum of countably many copies of intervals $([0,1],0)$. We denote the $1$ of the $n$-th copy by $1_n\in X$, $n\geq 1$. Of course, we have to alter the topology a little to get a non-paracompact space. Namely, the open subsets $U\subset X$ are those which are open in the CW-topology, and which either do not contain $0$, or if they do, they have to contain all but finitely many of the half-open intervals $[0,1_n)$.

This space is Hausdorff, as is easily seen, and contractible: each interval $[0,1_n]\subset X$ carries the usual topology and so $\{0\}\subset [0,1_n]$ is a strong deformation retract, which implies that each arm of $X$ can be contracted onto $0$ simultaneously.

Instead of an explicit example of a (complex) line bundle, Schröer shows that $H^1(X,U(1))\not = 0$, as follows. Using that even for non-paracompact spaces, $H^1$-sheaf cohomology is computed by Čech-cohomology, it is first shown that $H^1(X,C^0(X))\not = 0$; then $H^1(X,U(1))\not = 0$ follows from the real Euler sequence $0\to\underline{\mathbb Z}_X\to C^0(X)\xrightarrow{exp(\cdot 2\pi i)}\underline{U(1)}_X\to0$, and $H^1(X,\underline{\mathbb Z}_X) = 0$.

Instead of giving all the details, let me directly construct a non-trivial real line bundle, but using the same idea. Consider the open cover of $X$ defined by $U_0 = \bigcup_{n\geq 1}[0,1_n)$ and $U_n = (0,1_n]\subset X$, $n\geq 1$. Then clearly $U_n\cap U_m=\emptyset$ unless $n = m$ or $n = 0$ or $m=0$. Hence, we have to specify transition functions $g_n\colon U_0\cap U_n = (0,1_n)\to\mathbb{R}^\times$, $n\geq 1$. Let $f_n\colon U_n\to\mathbb{R}$, $n\geq 1$, be continuous functions with $f_n(1) = 0$, but $f_n(x)\not=0$ for $x\not=1$, and let $g_n = \tfrac{1}{f_n}$. (E.g., $g_n(x) = (1-x)^{-1}$.) Let $L$ be the line bundle defined by those transition functions. I claim that every section $s\colon X\to L$ is trivial at all but finitely many $1_n$. In particular, $L$ itself is non-trivial.

Let $s\colon X\to L$ be any section. It defines (and is defined by) continuous functions $s_n\colon U_n\to \mathbb{R}$, $n\geq 0$, satisfying $s_n(x) = f_n(x)s_0(x)$ for all $x\in (0,1_n)$, $n\geq 1$. From the existence of the limit $\lim_{x\to 1}f_n(x) = f_n(1) = 0$, we conclude that $s_n(1_n) = 0$ as soon as the limit $\lim_{x\to 1_n}s_0(x)$ exists as well. To see that this happens for all but finitely many $n$, it suffices to observe that $s_0$ is bounded away from finitely many $U_n$, which is a consequence of our choice of topology.