Generalized Poincaré Inequality In my numeric script it states for a bounded domain $\Omega \subset\mathbb{R^n}$ and any map $0 < a_0 \leq a(x) \leq a_1 < \infty $ for $x\in \Omega$ it exists a $\gamma>0$ such that the bilineaform 
$$ a(u,v) = \int_\Omega a(x) \nabla u(x)  \nabla v(x) dx$$
meets
$$\gamma ||v||^2_{L^2} \leq a(v,v) \quad \forall v \in H^1_0. $$
However, the proof shows only the inequality for $v\in C^\infty_0$. I am trying to end the proof by my own with a density argument, but I get stuck.
So for $u\in H^1_0$ I find a sequence $v_n \subset C^\infty_0$ with 
$$|| v_n - u ||_{L^2} \to 0,$$
$$ || \frac{\partial v_n}{\partial x_i}-\frac{\partial u}{\partial x_i}||_{L^2} \to 0 , $$
and
$$ \gamma ||v_n||^2_{L^2} \leq a(v_n,v_n) .$$
Now its clear to me that $$||v_n||^2_{L^2} \to ||u||^2_{L^2}$$ holds. Unfortunately I do not see that
$$ a(v_n,v_n) \to a(u,u)$$ holds, in other words I do not see why
$$\int_\Omega a(x) \left( \frac{\partial v_n(x)}{\partial x_i}\right)^2 dx \to \int_\Omega a(x) \left( \frac{\partial u(x)}{\partial x_i} \right)dx \quad for \quad n \to \infty$$
holds. Am I missing anything?
 A: First note, that you do not need to show
$$
\int_{\Omega}a\left(x\right)\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)\, dx\rightarrow\int_{\Omega}a\left(x\right)\frac{\partial u}{\partial x_{i}}\left(x\right)\, dx
$$
but instead
$$
\int_{\Omega}a\left(x\right)\sum_{i=1}^{n}\left(\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)\right)^{2}\, dx\rightarrow\int_{\Omega}a\left(x\right)\sum_{i=1}^{n}\left(\frac{\partial u}{\partial x_{i}}\left(x\right)\right)^{2}\, dx
$$
Now note
$$
\begin{align*}
 & \int_{\Omega}\left|a\left(x\right)\sum_{i=1}^{n}\left(\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)\right)^{2}-a\left(x\right)\sum_{i=1}^{n}\left(\frac{\partial u}{\partial x_{i}}\left(x\right)\right)^{2}\right|\, dx\\
& = \int_{\Omega}\left|a\left(x\right)\right|\cdot\left|\sum_{i=1}^{n}\left[\left(\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)\right)^{2}-\left(\frac{\partial u}{\partial x_{i}}\left(x\right)\right)^{2}\right]\right|\, dx\\
&  \overset{\left(\ast\right)}{\leq} a_{1}\cdot\sum_{i=1}^{n}\int_{\Omega}\left|\left(\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)\right)^{2}-\left(\frac{\partial u}{\partial x_{i}}\left(x\right)\right)^{2} \right|\, dx
\end{align*}
$$
where I used $0 \leq a_0 \leq a(x) \leq a_1$ in the step marked with $(\ast)$.
Now use the third binomial formula to conclude
$$
\begin{align*}
 & \left|\left(\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)\right)^{2}-\left(\frac{\partial u}{\partial x_{i}}\left(x\right)\right)^{2}\right|\\
& =  \left|\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)-\frac{\partial u}{\partial x_{i}}\left(x\right)\right|\cdot\left|\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)+\frac{\partial u}{\partial x_{i}}\left(x\right)\right|.
\end{align*}
$$
The Cauchy-Schwarz inequality yields
$$
\begin{align*}
 & \int_{\Omega}\left|\left(\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)\right)^{2}-\left(\frac{\partial u}{\partial x_{i}}\left(x\right)\right)^{2}\right|\, dx\\
& \leq  \sqrt{\int_{\Omega}\left|\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)-\frac{\partial u}{\partial x_{i}}\left(x\right)\right|^{2}\, dx}\cdot\sqrt{\int_{\Omega}\left|\frac{\partial v_{n}}{\partial x_{i}}\left(x\right)+\frac{\partial u}{\partial x_{i}}\left(x\right)\right|^{2}\, dx}\\
& =  \left\Vert \partial_{i}v_{n}-\partial_{i}u\right\Vert _{2}\cdot\left\Vert \partial_{i}v_{n}+\partial_{i}u\right\Vert _{2}\\
& \leq  \left\Vert \partial_{i}v_{n}-\partial_{i}u\right\Vert _{2}\cdot\left(\left\Vert \partial_{i}v_{n}\right\Vert _{2}+\left\Vert \partial_{i}u\right\Vert _{2}\right)\\
& \xrightarrow[n\rightarrow\infty]{}  0\cdot\left(\left\Vert \partial_{i}u\right\Vert _{2}+\left\Vert \partial_{i}u\right\Vert _{2}\right)=0.
\end{align*}
$$
