LIBINT  2.1.0-stable
Classes | Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
libint2::OneBodyEngine Class Reference

OneBodyEngine computes integrals of operators (or operator sets) given by OneBodyOperator::operator_type. More...

#include <engine.h>

Classes

struct  operator_traits
 describes operator sets given by OneBodyOperator More...
 
struct  operator_traits< OneBodyEngine::emultipole1 >
 
struct  operator_traits< OneBodyEngine::emultipole2 >
 
struct  operator_traits< OneBodyEngine::emultipole3 >
 
struct  operator_traits< OneBodyEngine::nuclear >
 

Public Types

enum  operator_type {
  overlap =0, kinetic =1, nuclear =2, emultipole1 =3,
  emultipole2 =4, emultipole3 =5, _invalid =-1
}
 types of operators (operator sets) supported by OneBodyEngine. More...
 
typedef libint2::FmEval_Taylor< real_t, 7 > coulomb_core_eval_t
 

Public Member Functions

 OneBodyEngine ()
 creates a default (unusable) OneBodyEngine; to be used as placeholder for copying a usable engine
 
template<typename Params = empty_pod>
 OneBodyEngine (operator_type type, size_t max_nprim, int max_l, int deriv_order=0, Params params=empty_pod())
 Constructs a (usable) OneBodyEngine. More...
 
 OneBodyEngine (OneBodyEngine &&other)
 move constructor
 
 OneBodyEngine (const OneBodyEngine &other)
 (deep) copy constructor
 
OneBodyEngineoperator= (OneBodyEngine &&other)
 move assignment is default
 
OneBodyEngineoperator= (const OneBodyEngine &other)
 (deep) copy assignment
 
template<typename Params >
void set_params (const Params &params)
 resets operator parameters; this may be useful if need to compute Coulomb potential integrals over batches of charges for the sake of parallelism. More...
 
template<typename Params >
DEPRECATED void set_q (const Params &params)
 alias to set_params() for backward compatibility with pre-05/13/2015 code More...
 
unsigned int nshellsets () const
 reports the number of shell sets that each call to compute() produces. More...
 
const real_t * compute (const libint2::Shell &s1, const libint2::Shell &s2)
 computes shell set of integrals More...
 
void compute_primdata (Libint_t &primdata, const Shell &s1, const Shell &s2, size_t p1, size_t p2, size_t oset)
 

Static Public Member Functions

static unsigned int to_target_deriv_index (unsigned int deriv_idx, unsigned int deriv_order, unsigned int ncenters, unsigned int omitted_center)
 Given the Cartesian geometric derivative index that refers to center set (0...n-1) with one center omitted compute the derivative index referring to the full center set. More...
 

Public Attributes

DEPRECATED typedef operator_type integral_type
 alias to operator_type for backward compatibility to pre-05/13/2015 code More...
 

Detailed Description

OneBodyEngine computes integrals of operators (or operator sets) given by OneBodyOperator::operator_type.

Member Enumeration Documentation

types of operators (operator sets) supported by OneBodyEngine.

Warning
These must start with 0 and appear in same order as elements of BOOST_PP_ONEBODY_OPERATOR_LIST preprocessor macro.
Enumerator
overlap 

overlap

kinetic 

electronic kinetic energy, i.e. $ -\frac{1}{2} \nabla^2 $

nuclear 

Coulomb potential due to point charges.

emultipole1 

overlap + (Cartesian) electric dipole moment, $ x_O, y_O, z_O $, where $ x_O \equiv x - O_x $ is relative to origin $ \vec{O} $

emultipole2 

emultipole1 + (Cartesian) electric quadrupole moment, $ x^2, xy, xz, y^2, yz, z^2 $

emultipole3 

emultipole2 + (Cartesian) electric octupole moment, $ x^3, x^2y, x^2z, xy^2, xyz, xz^2, y^3, y^2z, yz^2, z^3 $

Constructor & Destructor Documentation

template<typename Params = empty_pod>
libint2::OneBodyEngine::OneBodyEngine ( operator_type  type,
size_t  max_nprim,
int  max_l,
int  deriv_order = 0,
Params  params = empty_pod() 
)
inline

Constructs a (usable) OneBodyEngine.

Parameters
max_nprimthe maximum number of primitives per contracted Gaussian shell
max_lthe maximum angular momentum of Gaussian shell
deriv_orderif not 0, will compute geometric derivatives of Gaussian integrals of order deriv_order
paramsa value of type OneBodyEngine::operator_traits<type>::oper_params_type specifying the parameters of the operator set, e.g. position and magnitude of the charges creating the Coulomb potential for type == nuclear. For most values of type this is not needed.
See also
OneBodyEngine::operator_traits

Member Function Documentation

const real_t* libint2::OneBodyEngine::compute ( const libint2::Shell s1,
const libint2::Shell s2 
)
inline

computes shell set of integrals

Note
result is stored in row-major order

References libint2::Shell::contr, kinetic, nshellsets(), nuclear, and overlap.

unsigned int libint2::OneBodyEngine::nshellsets ( ) const
inline

reports the number of shell sets that each call to compute() produces.

this depends on the order of geometrical derivatives requested and on the operator set.

See also
compute()
Note
need to specialize for some operator types

References nuclear.

Referenced by compute().

template<typename Params >
void libint2::OneBodyEngine::set_params ( const Params &  params)
inline

resets operator parameters; this may be useful if need to compute Coulomb potential integrals over batches of charges for the sake of parallelism.

Referenced by set_q().

template<typename Params >
DEPRECATED void libint2::OneBodyEngine::set_q ( const Params &  params)
inline

alias to set_params() for backward compatibility with pre-05/13/2015 code

Deprecated:
use set_params() instead

References set_params().

static unsigned int libint2::OneBodyEngine::to_target_deriv_index ( unsigned int  deriv_idx,
unsigned int  deriv_order,
unsigned int  ncenters,
unsigned int  omitted_center 
)
inlinestatic

Given the Cartesian geometric derivative index that refers to center set (0...n-1) with one center omitted compute the derivative index referring to the full center set.

Parameters
deriv_idxindex of the derivative referring to the set with center omitted_center omitted
deriv_orderorder of the geometric derivative
ncentersnumber of centers in the full set
omitted_centerthe omitted center, must be less than ncenters.
Returns
the index of the derivative referring to full set

Member Data Documentation

DEPRECATED typedef operator_type libint2::OneBodyEngine::integral_type

alias to operator_type for backward compatibility to pre-05/13/2015 code

Deprecated:
use operator_type instead

The documentation for this class was generated from the following file: