MADNESS  0.10.1
Macros | Typedefs | Functions | Variables
lda.h File Reference
#include <madness/mra/mra.h>
#include <madness/world/MADworld.h>
#include <math.h>
#include <madness/madness_config.h>
#include <cmath>
Include dependency graph for lda.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define max(a, b)   ((a)>=(b)?(a):(b))
 

Typedefs

typedef double doublereal
 
typedef MADNESS_FORINT integer
 
typedef int logical
 

Functions

int c_rks_vwn5__ (const double *r__, double *f, double *dfdra)
 
int c_uks_vwn5__ (double *ra, double *rb, double *f, double *dfdra, double *dfdrb)
 
template<int NDIM>
void dft_xc_lda_ene (const Key< NDIM > &key, Tensor< double > &t)
 
template<int NDIM>
void dft_xc_lda_V (const Key< NDIM > &key, Tensor< double > &t)
 
static double pow (const double *a, const double *b)
 
int rks_c_vwn5__ (integer *ideriv, integer *npt, doublereal *rhoa1, doublereal *sigmaaa1, doublereal *zk, doublereal *vrhoa, doublereal *vsigmaaa, doublereal *v2rhoa2, doublereal *v2rhoasigmaaa, doublereal *v2sigmaaa2)
 
int rks_x_lda__ (integer *ideriv, integer *npt, doublereal *rhoa1, doublereal *sigmaaa1, doublereal *zk, doublereal *vrhoa, doublereal *vsigmaaa, doublereal *v2rhoa2, doublereal *v2rhoasigmaaa, doublereal *v2sigmaaa2)
 
void wst_munge_grho (int npoint, double *rho, double *grho)
 
void wst_munge_rho (int npoint, double *rho)
 
int x_rks_s__ (const double *r__, double *f, double *dfdra)
 
int x_uks_s__ (double *ra, double *rb, double *f, double *dfdra, double *dfdrb)
 
void xc_rks_generic_lda (Tensor< double > rho_alpha, Tensor< double > f, Tensor< double > df_drho)
 

Variables

static double c_b14 = 1.333333333333333333333333333333
 
static double c_b2 = .333333333333333333333333333333333
 
static double c_b7 = .333333333333333333333333333333
 
static double c_b8 = .5
 
const double THRESH_GRHO = 1e-20
 
const double THRESH_RHO = 1e-8
 

Macro Definition Documentation

◆ max

#define max (   a,
  b 
)    ((a)>=(b)?(a):(b))

Typedef Documentation

◆ doublereal

typedef double doublereal

◆ integer

typedef MADNESS_FORINT integer

◆ logical

typedef int logical

Function Documentation

◆ c_rks_vwn5__()

int c_rks_vwn5__ ( const double *  r__,
double *  f,
double *  dfdra 
)
inline

References a2, c_b7, c_b8, f, and pow().

Referenced by ldaeop(), and ldaop().

◆ c_uks_vwn5__()

int c_uks_vwn5__ ( double *  ra,
double *  rb,
double *  f,
double *  dfdra,
double *  dfdrb 
)
inline

References a1, a2, c_b14, c_b7, f, f1, f2, f3, pow(), ss1, v, and zeta.

◆ dft_xc_lda_ene()

template<int NDIM>
void dft_xc_lda_ene ( const Key< NDIM > &  key,
Tensor< double > &  t 
)
inline

◆ dft_xc_lda_V()

template<int NDIM>
void dft_xc_lda_V ( const Key< NDIM > &  key,
Tensor< double > &  t 
)
inline

◆ pow()

static double pow ( const double *  a,
const double *  b 
)
inlinestatic

References a, and b.

Referenced by madness::BandlimitedPropagator::BandlimitedPropagator(), madness::cartesian_grid< NDIM >::cartesian_grid(), madness::dftgrid< NDIM >::dftgrid(), madness::F12Potentials::F12Potentials(), FermiNucDistFunctor::FermiNucDistFunctor(), GaussianNucleusFunctor::GaussianNucleusFunctor(), HO_function< NDIM >::HO_function(), OpFExact::OpFExact(), slymer::PrimitiveGaussian::PrimitiveGaussian(), madness::ProjRLMFunctor::ProjRLMFunctor(), refpotfunctor::refpotfunctor(), madness::SeparatedConvolution< Q, NDIM >::SeparatedConvolution(), A(), A2(), a_fit(), madness::FunctionImpl< T, NDIM >::add_scalar_inplace(), madness::analytical_slater_functor(), ExactSpinor::angular(), apbar_fit(), apply_potential(), madness::Specialbox_op< T, NDIM >::box_is_at_boundary(), madness::GFit< T, NDIM >::bsh_fit_ndim(), madness::GFit< T, NDIM >::bsh_spherical_moments(), bshrel_fit(), bshrel_OMEGA(), C(), c_rks_vwn5__(), madness::c_rks_vwn5__(), c_uks_vwn5__(), madness::c_uks_vwn5__(), charge_function(), madness::FunctionCommonFunctionality< T, NDIM >::coeffs2values(), madness::FunctionImpl< T, NDIM >::coeffs2values(), ExactSpinor::compute_energy(), madness::MP3::compute_mp3_ef_with_permutational_symmetry(), madness::guessfactory::PolynomialFunctor::compute_value(), madness::guessfactory::PolynomialTrigonometricsFunctor::compute_value(), converge(), madness::Diamagnetic_potential_factor::custom_factor(), madness::FunctionImpl< T, NDIM >::do_apply_directed_screening(), madness::FunctionImpl< T, NDIM >::do_binary_op(), madness::Derivative< T, NDIM >::do_diff2b(), madness::Derivative< T, NDIM >::do_diff2i(), madness::FunctionImpl< T, NDIM >::do_mul(), madness::FunctionImpl< T, NDIM >::do_print_grid(), Ebar(), Ebark(), madness::FunctionImpl< T, NDIM >::err_box(), errsq(), madness::SeparatedConvolution< Q, NDIM >::estimate_costs(), madness::CorePotential::eval(), madness::FunctionImpl< T, NDIM >::eval_cube(), madness::CorePotential::eval_derivative(), madness::CoreOrbital::eval_radial(), madness::CoreOrbital::eval_radial_derivative(), exact_function(), madness::GFit< T, NDIM >::F12sqFit(), f_dipole(), f_quadrupole(), f_spheropole(), fastsum_oscillating(), madness::fcube(), fit(), function(), ExactSpinor::Fvalue(), fxexact(), fyexact(), fzexact(), madness::BandlimitedPropagator::g0_filtered(), madness::smooth< T, NDIM >::gauss_norm(), gaussian(), gaussian1(), gaussian2(), gaussian3(), madness::GFit< T, NDIM >::gaussian_spherical_moments(), madness::smooth< T, NDIM >::get_density_thresh(), madness::GradBSHOperator(), GradBSHOperator_Joel(), madness::GradCoulombOperator(), gradPbarA(), madness::GradSlaterOperator(), madness::Derivative< T, NDIM >::initCoefficients(), madness::TwoElectronInterface< T, NDIM >::initialize(), madness::cartesian_grid< NDIM >::initialize(), madness::SeparatedConvolution< Q, NDIM >::initialize(), madness::FunctionImpl< T, NDIM >::inner_ext_recursive(), madness::GaussianConvolution1D< Q >::issmall(), iterate(), logplot(), main(), DF::make_component_logplots(), make_grad_operator(), Ansatz0::make_guess(), make_operator(), mask(), moments(), madness::FunctionImpl< T, NDIM >::mul(), ContractedGaussianShell::normalize(), madness::ContractedGaussianShell::normalize(), madness::FunctionImpl< T, NDIM >::NScoeffs2values(), nuc_func(), nuclear_charge_function(), madness::Molecule::nuclear_repulsion_second_derivative(), sgl_guess::operator()(), Guess::operator()(), Charge::operator()(), ncf::operator()(), madness::NuclearCorrelationFactor::R_functor::operator()(), madness::BasisFunctions::CartesianGaussian::operator()(), madness::BasisFunctions::SolidHarmonicGaussian::operator()(), madness::Znemo::landau_wave_function::operator()(), QMtest::operator()(), uexact::operator()(), PotentialBasisFunctor::operator()(), GaussianGuess< NDIM >::operator()(), ncf_singularity::operator()(), madness::apply_kernel_helper::slater_kernel::operator()(), gauss_1d::operator()(), Uop::operator()(), madness::slater_kernel::operator()(), GygiPot::Pow< T, DIM >::operator()(), GygiPot::Pow_beta_one< T, DIM >::operator()(), madness::FunctionImpl< T, NDIM >::project_out_op< LDIM >::operator()(), madness::GenericConvolution1D< Q, opT >::Shmoo::operator()(), madness::FunctionImpl< T, NDIM >::do_unary_op_value_inplace< opT >::operator()(), optimize_coeffs(), madness::FunctionImpl< T, NDIM >::parent_to_child(), pbar_fit(), PbarA(), madness::PeriodicBSHOp(), madness::PeriodicBSHOpPtr(), madness::PeriodicCoulombOp(), madness::PeriodicCoulombOpPtr(), madness::FunctionImpl< T, NDIM >::phi_for_mul(), madness::XCfunctional::plot(), plot(), madness::power(), madness::GFit< T, NDIM >::print_accuracy(), FermiNucDistFunctor::print_details(), madness::FunctionImpl< T, NDIM >::print_plane_local(), madness::FunctionImpl< T, NDIM >::print_stats(), madness::FunctionImpl< T, NDIM >::project(), psi_guess(), ExactSpinor::psivalue(), random_gaussian(), RandomGaussian(), madness::FunctionImpl< T, NDIM >::read_grid(), madness::FunctionImpl< T, NDIM >::read_grid2(), madness::LowRankFunction< T, NDIM, LDIM >::reorthonormalize(), rho_function(), rho_gaussian_func3d(), madness::Convolution1D< Q >::rnlij(), madness::GaussianConvolution1D< Q >::rnlp(), simpt2key(), madness::simpt2key(), madness::GFit< T, NDIM >::slater_fit(), madness::smoothed_density(), smoothing_parameter(), madness::smoothing_parameter(), madness::SmoothingOperator(), madness::SmoothingOperator3D(), tbar_fit(), test(), test2(), madness::smooth< T, NDIM >::test_1d(), test_apply_push_1d(), test_basic(), test_bsh(), test_conv(), test_conversion(), test_coulomb(), test_diff(), test_gaussian_num_coeffs(), OptimizationTargetInterface::test_gradient(), madness::OptimizationTargetInterface::test_gradient(), test_hartree_product(), test_integration(), test_io(), test_math(), test_op(), test_opdir(), test_periodic(), test_periodic1(), test_plot(), test_proj(), test_smooth_maxout(), test_spherical_box(), test_stuff(), test_tight_diffuse(), test_vector_composite(), test_xc1(), madness::Key< NDIM >::thisKeyContains(), madness::FunctionImpl< T, NDIM >::trace_local(), madness::FunctionImpl< T, NDIM >::truncate_tol(), uexact(), uinitial(), updatex(), GaussianGuess< NDIM >::val(), Fred::value_and_gradient(), madness::FunctionCommonFunctionality< T, NDIM >::values2coeffs(), madness::FunctionImpl< T, NDIM >::values2coeffs(), madness::FunctionImpl< T, NDIM >::values2NScoeffs(), Vdynamic(), madness::FunctionImpl< T, NDIM >::vol_nsphere(), madness::randomgrid< NDIM >::volume(), x_rks_s__(), madness::x_rks_s__(), x_uks_s__(), madness::x_uks_s__(), xc_functor< NDIM >::xc_potential(), and madness::LowRankFunctionFactory< T, NDIM, LDIM >::Yformer().

◆ rks_c_vwn5__()

int rks_c_vwn5__ ( integer ideriv,
integer npt,
doublereal rhoa1,
doublereal sigmaaa1,
doublereal zk,
doublereal vrhoa,
doublereal vsigmaaa,
doublereal v2rhoa2,
doublereal v2rhoasigmaaa,
doublereal v2sigmaaa2 
)
inline

References c_b2, e(), and max.

Referenced by xc_rks_generic_lda().

◆ rks_x_lda__()

int rks_x_lda__ ( integer ideriv,
integer npt,
doublereal rhoa1,
doublereal sigmaaa1,
doublereal zk,
doublereal vrhoa,
doublereal vsigmaaa,
doublereal v2rhoa2,
doublereal v2rhoasigmaaa,
doublereal v2sigmaaa2 
)
inline

References c_b2, e(), and max.

Referenced by xc_rks_generic_lda().

◆ wst_munge_grho()

void wst_munge_grho ( int  npoint,
double *  rho,
double *  grho 
)
inline

References THRESH_GRHO, and THRESH_RHO.

◆ wst_munge_rho()

void wst_munge_rho ( int  npoint,
double *  rho 
)
inline

References THRESH_RHO.

Referenced by xc_rks_generic_lda().

◆ x_rks_s__()

int x_rks_s__ ( const double *  r__,
double *  f,
double *  dfdra 
)
inline

References c_b2, f, and pow().

Referenced by ldaeop(), and ldaop().

◆ x_uks_s__()

int x_uks_s__ ( double *  ra,
double *  rb,
double *  f,
double *  dfdra,
double *  dfdrb 
)
inline

References c_b2, f, and pow().

◆ xc_rks_generic_lda()

void xc_rks_generic_lda ( Tensor< double >  rho_alpha,
Tensor< double >  f,
Tensor< double >  df_drho 
)
inline
Parameters
rho_alphaAlpha-spin density at each grid point
fValue of functional at each grid point
df_drhoDerivative of functional w.r.t. rho_alpha

References f, MADNESS_ASSERT, rks_c_vwn5__(), rks_x_lda__(), and wst_munge_rho().

Referenced by dft_xc_lda_ene(), and dft_xc_lda_V().

Variable Documentation

◆ c_b14

double c_b14 = 1.333333333333333333333333333333
static

Referenced by c_uks_vwn5__().

◆ c_b2

double c_b2 = .333333333333333333333333333333333
static

◆ c_b7

double c_b7 = .333333333333333333333333333333
static

Referenced by c_rks_vwn5__(), and c_uks_vwn5__().

◆ c_b8

double c_b8 = .5
static

Referenced by c_rks_vwn5__().

◆ THRESH_GRHO

const double THRESH_GRHO = 1e-20

Referenced by wst_munge_grho().

◆ THRESH_RHO

const double THRESH_RHO = 1e-8

Referenced by wst_munge_grho(), and wst_munge_rho().