fzero said:
The energy to form temporary dipole moments comes from the thermal energy in the collection of atoms, so basically collisions.
There are phenomenons which work like this, but the London dispersion the OP was asking about is not of this nature. It is also there in pure wave function and at zero temperature, and has no relationship to thermal ensembles.
@OP: London dispersion can maybe be best imagined similarly to the resonance structures you might know from organic chemistry. The wave function of the molecule (even of a pure state at zero temperature) can be described by simultaneous linear combination of many different "resonance structures", which can be thought of as frozen combinations of electrons placed in specific orbitals. Even in molecules which do not have permanent dipole moments, some of the resonance structures which make up the full wave function, do have dipole moments. And if you have, for example, two interacting molecules, the resonance structures in which these "instantaneous" dipole moments are favourably aligned have a larger weight in the total two-molecule wave function than the configurations in which they do not.
However, it is important to stress that these "resonance structures" are not real wave functions, but only aspects of a single real wave function, which describes all electrons in the system at the same time. This single real wave function, and its time evolution, is still governed by the Schrödinger equation. Consequently, there is conservation of energy. If, for example, during time evolution of the single wave function,the weight of some of those "resonance structures" which make it up change, the weights must change in such a way that the total energy of the wave function stays constant (or, if there is an external driving force: stays consistent with the external energy input/drain).
In technical terms, what I called "resonance structure" here is called a "configuration", which can be made up of Slater determinants, Configuration State Functions, or other multi-electron wave functions (look up "Full Configuration Interaction"). Contrary to traditional resonance structures, in an quantitative description of these phenomena also energetically highly unfavourable configurations have to be considered (in fact, ALL possible distributions of electrons in orbitals, including very high lying orbitals, have to be considered in principle). Such things are done in higher wave function methods like Coupled Cluster or Configuration Interaction methods. If you want to read up on this: A good book to get a general feeling and intuition of how this works is "Electron Correlation in Molecules and Solids" of Peter Fulde.
One more terminology thing: "van der Waals" interactions is basically a catch-all term for "all kinds of weak inter-molecular interactions", and includes not only London dispersion (as described by the Casimir-Polder force and similar effects), but also electrostatic interactions (e.g., from permanent multipole moments), weak covalent intermolecular interactions (e.g., Hydrogen bonds) and so on. The term is sometimes assumed to be synonymous with the dispersion interaction, but this is not the standard definition.