qmctorch.wavefunction.jastrows.elec_elec_nuclei.kernels package

Submodules

Module contents

class qmctorch.wavefunction.jastrows.elec_elec_nuclei.kernels.FullyConnectedJastrowKernel(*args: Any, **kwargs: Any)[source]

Bases: JastrowKernelElectronElectronNucleiBase

Defines a fully connected jastrow factors.

forward(x)[source]

Compute the values of the individual f_ij=f(r_ij)

Parameters:

x (torch.tensor) – e-e distance Nbatch, Nele_pairs

Returns:

values of the f_ij

Return type:

torch.tensor

class qmctorch.wavefunction.jastrows.elec_elec_nuclei.kernels.JastrowKernelElectronElectronNucleiBase(*args: Any, **kwargs: Any)[source]

Bases: Module

Base Class for the elec-elec-nuc jastrow kernel

Parameters:
  • nup (int) – number of spin up electons

  • ndow (int) – number of spin down electons

  • atoms (torch.tensor) – atomic positions of the atoms

  • cuda (bool, optional) – Turns GPU ON/OFF. Defaults to False.

forward(x)[source]

Compute the values of the kernel

Parameters:

x (torch.tensor) – e-e and e-n distances distance (Nbatch, Natom, Nelec_pairs, 3) the last dimension holds the values [R_{iA}, R_{jA}, r_{ij}] in that order.

Returns:

values of the kernel (Nbatch, Natom, Nelec_pairs, 1)

Return type:

torch.tensor

compute_derivative(r, dr)[source]

Get the elements of the derivative of the jastrow kernels.

compute_second_derivative(r, dr, d2r)[source]

Get the elements of the pure 2nd derivative of the jastrow kernels.

class qmctorch.wavefunction.jastrows.elec_elec_nuclei.kernels.BoysHandyJastrowKernel(*args: Any, **kwargs: Any)[source]

Bases: JastrowKernelElectronElectronNucleiBase

Defines a Boys Handy jastrow factors.

J.W. Moskowitz et. al Correlated Monte Carlo Wave Functions for Some Cations and Anions of the First Row Atoms Journal of Chemical Physics, 97, 3382-85 (1992)

\[\text{K}(R_{iA}, R_{jA}, r_{ij) = \sum_\mu c_\mu \left(\frac{a_{1_\mu} R_{iA}}{1 + b_{1_\mu}R_{iA}}\right)^{u_\mu} \left(\frac{a_{2_\mu} R_{jA}}{1 + b_{2_\mu}R_{iA}}\right)^{v_\mu} \left(\frac{a_{3_\mu} r_{ij}}{1 + b_{3_\mu}r_{ij}}\right)^{w_\mu}\]

We restrict the parameters of the two electron-nucleus distance to be equal otherwise the jastrow factor is not permutation invariant

forward(x)[source]

Compute the values of the kernel

Parameters:

x (torch.tensor) – e-e and e-n distances distance (Nbatch, Natom, Nelec_pairs, 3) the last dimension holds the values [R_{iA}, R_{jA}, r_{ij}] where i,j are electron index in the pair and A the atom index.

Returns:

values of the kernel (Nbatch, Natom, Nelec_pairs, 1)

Return type:

torch.tensor