Dipole moment in Quantum Mechanicl
I dare to expand the answer of wzkchem5, taking into account how I understood (with some math).
The dipole moment of molecular system (which is described by wave function $\Phi$) is an observabe, so in QM we can write:
\begin{equation*}
\vec{\mu} = \int \Phi^* \hat{\mu} \,\, \Phi \vec{r}.
\end{equation*}
which leads to
\begin{equation}\label{DM}\tag{DM}
\vec{\mu} = \int\limits_V \vec{r} \left[\sum Z_A \delta(\vec{r} - \vec{R}_A) - \rho(x,y,x)\right] d\vec{r},
\end{equation}
or in nucleus - electrons separated form
\begin{equation}\label{N-e}\tag{N - e}
\vec{\mu} = \sum_a Z_a \vec{R}_a - \int \vec{r} \rho(x,y,x) d\vec{r},
\end{equation}
This formula from quantum mechanics is similar to classical one, where $\rho (x,y,z)$ --- electron charge density.
Calculation of dipole moment by RHF method
In RHF (with MO LCAO) approximation, the \eqref{DM} leads to
\begin{equation}\label{DM LCAO} \tag{DM from LCAO}
\vec{\mu} = \sum_A Z_A\vec{R}_A - 2 \sum_p\sum_q P_{pq}\int_V \vec{r} \chi_p^* \chi_q d\vec{r},
\end{equation}
where $\{P_{pq}\}$ -- density matrix, $\chi_q$ --- basis set functions.
Quantum chemistry software calculates this with the HF method using the formula \eqref{DM LCAO}.
As for the charges on the atoms.
From another side, an atomic partial charges $q_A$ are a central concept in general chemistry and widely used as mentioned wzkchem5. But, unfortunately, they do not correspond to a single well-defined quantum mechanical observable, so we have't operator $\hat{q}_A$ and as a concequence, their definition is quite arbitrary and they are not required to accurately reproduce the electrical characteristics of the molecule.
The calculation according to the formula (for diatomic molecule)
\begin{equation}\label{QR}\tag{QR}
\vec{\mu}_{q} = q_{Li} \vec{R_{Li}} - q_H \vec{R_{H}} = q \vec R_{Li-H},
\end{equation}
where $R_{Li-H}$ - the distence between atoms,
takes into account only a part of the contribution to the dipole moment of the molecule associated with interatomic charge transfer.
Let's show it.
Let's introduce $\vec r = \vec R_{Li} + \vec r_{Li}$ and substitute into the formula\eqref{N-e}
\begin{equation}
\vec{\mu} = \left(Z_{Li} - \int \rho(x,y,x) d\vec{r} \right) \vec R_{Li} + \left(Z_{H} - \int \rho(x,y,x) d\vec{r} \right) \vec R_{H} - \int \vec (\vec r_{H} + \vec r_{Li}) \rho(x,y,x) d\vec{r} = q_{Li} \vec R_{Li} + q_{H} \vec R_{H} - \int (\vec r_{H} + \vec r_{Li}) \rho(x,y,x) d\vec{r} = q_{Li} \vec R_{Li - H} - \int (\vec r_{H} + \vec r_{Li}) \rho(x,y,x) d\vec{r} = \mu_{q} - \int (\vec r_{H} + \vec r_{Li}) \rho(x,y,x) d\vec{r}.
\end{equation}
The last term $- \int (\vec r_{H} + \vec r_{li}) \rho(x,y,x) d\vec{r}$ takes into account the fact that the eletron density distribution of the bound atom is not spherically symmetric, and each atom acquires a dipole electric polarization, relative to its nucleus.
So, we can see, the $\vec{\mu}_q = q_{Li} \vec R_{Li-H}$ which is determined by the partial charge
on the atom is just a part of total dipole moment of molecule $\vec{\mu}$.
There are many methods for determining partial charges. In paper The Atomic Partial Charges Arboretum: Trying to See the Forest for the Trees the classification of charges is given, depending on the methods of their determination:
- Class I charges are derived from experimentally measurable
properties, e.g., from observed deformation densities, from the electronegativity
equalization principle, or from, e.g., dipole moments of diatomic and
small (usually highly symmetric) polyatomic molecules.
- Class II charges are extracted from the molecular orbitals (Mulliken, NPA,…)
or the electron density (Bader QTAIM, Hirshfeld,…).
- Class III charges are extracted from the wave function or electron density by fitting a physical observable (e.g., the electrostatic potential) derived from it.
- Class IV charges are based on semiempirical adjustment of a
well-defined Class II or Class III model to better reproduce one or
more physical observables (e.g. the dipole moment).