Dirichlet problem for elliptic equations in weighted Sobolev spaces