  Using first-principles density functional theory calculations, we
investigated the effect of charge doping in a LaNiO$_3$/SrTiO$_3$ superlattice.
The detailed analysis based on two different simulation methods for doping
clearly shows that the electronic and structural properties change in a
systematic way that the orbital polarization ({\it i.e.} relative occupation of
two Ni-$e_g$ orbitals) is reduced and the Ni to apical oxygen distance enlarged
as the number of doped electrons increases. Also, the rotation angles of the
NiO$_6$/TiO$_6$ octahedra strongly and systematically depend on the doping so
that the angle $\gamma$ gradually decreases whereas the $\alpha$ and $\beta$
increase as a function of electron doping. Further analysis shows that the
electron (hole) doping can play a similar role with the compressive (tensile)
strain for the octahedral rotations. Our results not only suggest a possible
way to control the orbital and structural property by means of charge doping,
but also provide useful information to understand the experiments under various
doping situations such as oxygen vacancy.
