GQCP
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
GQCP::CartesianExponents Struct Reference

#include <CartesianExponents.hpp>

Collaboration diagram for GQCP::CartesianExponents:
Collaboration graph

Public Member Functions

 CartesianExponents (const std::array< size_t, 3 > &array)
 
 CartesianExponents (const size_t x, const size_t y, const size_t z)
 
 CartesianExponents (const std::vector< size_t > &vector)
 
bool operator< (const CartesianExponents &rhs) const
 
bool operator== (const CartesianExponents &rhs) const
 
bool operator!= (const CartesianExponents &rhs) const
 
size_t angularMomentum () const
 
std::vector< CartesianExponentsallPermutations () const
 
const std::array< size_t, 3 > & asArray () const
 
std::string description () const
 
size_t value (const CartesianDirection direction) const
 

Public Attributes

std::array< size_t, 3 > exponents
 

Detailed Description

A class that represents exponents of the Cartesian functions x, y and z

Constructor & Destructor Documentation

◆ CartesianExponents() [1/3]

GQCP::CartesianExponents::CartesianExponents ( const std::array< size_t, 3 > &  array)
Parameters
arraythe array containing the x-, y- and z-exponent (in that order)

◆ CartesianExponents() [2/3]

GQCP::CartesianExponents::CartesianExponents ( const size_t  x,
const size_t  y,
const size_t  z 
)
Parameters
xthe exponent in x
ythe exponent in y
zthe exponent in z

◆ CartesianExponents() [3/3]

GQCP::CartesianExponents::CartesianExponents ( const std::vector< size_t > &  vector)
Parameters
vectorthe vector containing the x-, y- and z-exponent (in that order)

Member Function Documentation

◆ allPermutations()

std::vector< CartesianExponents > GQCP::CartesianExponents::allPermutations ( ) const
Returns
a sorted list of all permutations (i.e. switching x, y, z) of these Cartesian exponents

◆ angularMomentum()

size_t GQCP::CartesianExponents::angularMomentum ( ) const
Returns
the angular momentum corresponding to these exponents

◆ asArray()

const std::array< size_t, 3 > & GQCP::CartesianExponents::asArray ( ) const
inline
Returns
the exponents as an array

◆ description()

std::string GQCP::CartesianExponents::description ( ) const
Returns
a textual description of self

◆ operator!=()

bool GQCP::CartesianExponents::operator!= ( const CartesianExponents rhs) const
Parameters
rhsthe right-hand side of the operator ==
Returns
if the Cartesian exponents are considered different

◆ operator<()

bool GQCP::CartesianExponents::operator< ( const CartesianExponents rhs) const
Parameters
rhsthe right-hand side of the operator <
Returns
if these Cartesian exponents are 'smaller' than the ones on the right-hand side. The following logic is used: lhs < rhs
  • if lhs's angular momentum is smaller
  • if both angular momenta are equal, x takes precedence over y, over z

This means that {1, 0, 0}(=x) < {2, 0, 0}(=x^2), and {2, 0, 0}(=x^2) < {1, 1, 0}(=xy)

◆ operator==()

bool GQCP::CartesianExponents::operator== ( const CartesianExponents rhs) const
Parameters
rhsthe right-hand side of the operator ==
Returns
if the Cartesian exponents are considered equal

◆ value()

size_t GQCP::CartesianExponents::value ( const CartesianDirection  direction) const
inline
Parameters
directionthe direction (x,y,z) whose exponent should be returned
Returns
the exponent in the given direction

Member Data Documentation

◆ exponents

std::array<size_t, 3> GQCP::CartesianExponents::exponents

The documentation for this struct was generated from the following files: