Given a vector bundle $E \to M$ with connection $\nabla$, we get a twisted de Rham sequence using the exterior covariant derivative:
$$\mathcal{E} \xrightarrow{d^\nabla=\nabla} \Omega^1\_M \otimes\_{\Omega^0\_M} \mathcal{E} \xrightarrow{d^\nabla} \Omega^2\_M \otimes\_{\Omega^0\_M} \mathcal{E} \xrightarrow{d^\nabla} \cdots$$
Here, I am using $\mathcal{E}$ to denote the sheaf of smooth sections of $E$, and $\Omega\_M$ the sheaf of smooth differential forms on $M$. 


We say that the connection $\nabla$ is flat if $(d^\nabla)^2 = 0$, and in this case we get an actual complex of sheaves. In this situation, the sheaf $\mathcal{L}$ of parallel sections is a local system and we can use this complex (a soft resolution) to compute its sheaf cohomology. 


As described in Kashiwara and Schapira, or in [Liviu Nicolaescu's answer here](https://mathoverflow.net/questions/111059/relative-de-rham-cohomologies), given a closed submanifold $i: Z \hookrightarrow M$, and $j: M \setminus Z \hookrightarrow M$ the inclusion of its complement, we get a short exact sequence of sheaves
$$0 \to j\_!j^{-1}\mathcal{L} \to \mathcal{L} \to i\_\*i^{-1}\mathcal{L} \to 0.$$
The natural maps here are the counit $j\_!j^{-1}\mathcal{L} \to \mathcal{L}$ of the $j\_! \dashv j^{-1}$ adjunction, and the unit $\mathcal{L} \to i\_\*i^{-1}\mathcal{L}$ of the $i^{-1} \dashv i\_\*$ adjunction, respectively.


Note that the pullback bundle $i^\* E \to Z$ inherits the flat connection from $E \to M$, and this gives rise to a complex of sheaves on $Z$
$$\mathcal{i^\*E} \xrightarrow{d^\nabla=\nabla} \Omega^1\_Z \otimes\_{\Omega^0\_Z} i^\*\mathcal{E} \xrightarrow{d^\nabla} \Omega^2\_Z \otimes\_{\Omega^0\_Z} i^\*\mathcal{E} \xrightarrow{d^\nabla} \cdots$$
Note that $i^\*= \Omega^0\_Z \otimes\_{i^{-1} \Omega^0\_M} i^{-1}$, so it is not the same as the inverse image functor above. Is it correct to say that this complex gives a soft resolution of the sheaf $i^{-1} \mathcal{L}$? If so, how can I show that this is true? 


This problem has come up in my research (in differential geometry) but my department doesn't really have anyone who works with sheaves. I would really appreciate some help with this!



Relative version of de Rham cohomology with local coefficients
I had a look in Ramanan's Global Calculus, and sure enough he gives the necessary details:


Let $\mathbb{R}\_M$ denote the constant sheaf corresponding to $\mathbb{R}$ on $M$.


Note that $\Omega^k\_M\otimes\_{\mathbb{R}\_M} \mathcal{L} = \Omega^k\_M\otimes\_{\Omega^0\_M} \mathcal{E},$ and hence the connection is recovered from the exterior derivative by the formula:
$$\nabla = d \otimes\_{\mathbb{R}\_M} 1: \mathcal{E} \to \Omega^1\_M \otimes\_{\Omega^0\_M} \mathcal{E}.$$
So in particular, tensoring the de Rham resolution of $\mathbb{R}\_M$ with $\mathcal{L}$ recovers the twisted de Rham resolution of $\mathcal{L}$.


With regards to the resolution of $i^{-1} \mathcal{L}$ on $Z$, note that we have the following canonical isomorphisms:
\begin{align}
\Omega^k\_Z \otimes\_{\Omega^0\_Z} i^\* \mathcal{E} &= \Omega^k\_Z \otimes\_{\Omega^0\_Z} (\Omega^0\_Z \otimes\_{i^{-1}\Omega^0\_M} i^{-1} \mathcal{E}) \\
&\cong \Omega^k\_Z \otimes\_{i^{-1}\Omega^0\_M} i^{-1} \mathcal{E} \\
&\cong \Omega^k\_Z \otimes\_{i^{-1}\Omega^0\_M} i^{-1} (\Omega^0\_M\otimes\_{\mathbb{R}\_M} \mathcal{L}) \\
&\cong \Omega^k\_Z \otimes\_{i^{-1}\Omega^0\_M} i^{-1}\Omega^0\_M \otimes\_{\mathbb{R}\_Z} i^{-1} \mathcal{L} \\
&\cong\Omega^k\_Z \otimes\_{\mathbb{R}\_Z} i^{-1} \mathcal{L}.
\end{align}


Hence, tensoring the de Rham resolution of $\mathbb{R}\_Z$ with $i^{-1} \mathcal{L}$ gives the usual de Rham resolution of $i^{-1} \mathcal{L}$, and this computes the twisted de Rham cohomology on $Z$.


The same idea works to get the resolution of $j^{-1} \mathcal{L}$ on $M \setminus Z$. Then, applying the "extension by zero" functor $j\_!$, we get a resolution for $j\_!j^{-1} \mathcal{L}$, which computes the relative twisted de Rham cohomology.


