# Derivation of IV estimator?

Assume, the model we are trying to estimate is:

$Y=\beta_ß+\beta_1X+U$

where x and u are correlated: $Cov(X,U)\neq 0$

Then OLS is inconsistent:

$\beta_1^{OLS}=\frac{Cov(Y,X)}{Var(X)}=\frac{Cov(\beta_0+\beta_1X+U,X)}{Var(X)}=\beta_1\frac{Cov(X,X)}{Var(X)}+\frac{Cov(X,U)}{Var(X)}=\beta_1+\frac{Cov(X,U)}{VaR(X)}\neq 0$

If we introduce an instrumental variable, for which it holds:

$Cov(Z,X)\neq 0$

$Cov(Z,U) = 0$

One can show, that OLS is consitent, so that

$\beta_1^{IV}=\beta_1+\frac{Cov(Z,U)}{Cov(X,Z)}=\beta_1$

I wanted to proof this. Therefore I tried the following: $\beta_1^{OLS}=\frac{Cov(Y,Z)}{Var(Z)}=\frac{Cov(\beta_0+\beta_1X+U,Z)}{Var(Z)}=\beta_1\frac{Cov(Z,X)}{Var(Z)}+\frac{Cov(Z,U)}{Var(Z)}=?$

This does not lead to a nice solution (first of all $\frac{Cov(Z,X)}{Var(Z)}\neq 1$ and I have $Var(Z)$ in the denominator and not $Cov(X,Z)$)? Why, where is my mistake and how can I proof this?

I think you tried to prove consistency of the IV estimator but started the proof with the OLS estimator instead. If you write: $$\newcommand{\Cov}{\operatorname{Cov}}\beta_{1}^{\mathrm{IV}} = \frac{\Cov(Z,Y)}{\Cov(Z,X)} = \frac{\Cov(Z,\beta_{0}+\beta_{1}X+U)}{\Cov(Z,X)}$$ you should get your desired result $$\beta_{1}\frac{\Cov(Z,X)}{\Cov(Z,X)} + \frac{\Cov(Z,U)}{\Cov(Z,X)}$$ and then by the assumption that $\Cov(Z,U) = 0$ you will be left with $\beta_{1}$.
For your model $$Y = \beta_{0} + \beta_{1}X_{1} + U$$ take the covariance of all terms with the instrument $Z$, which gives $$\Cov(Z,Y) = \beta_{1}\Cov(Z,X) + \Cov(Z,U)$$ Then $\Cov(Z,U) = 0$ by assumption and dividing by $\Cov(Z,X)$ gives $$\beta_{1}^{\mathrm{IV}} = \frac{\Cov(Z,Y)}{\Cov(Z,X)}$$