JDFTx  1.7.0
RadialFunctionR Struct Reference

A function on a non-uniform real-space radial grid. More...

#include <RadialFunction.h>

Public Member Functions

 RadialFunctionR (int nSamples=0)
 allocate for a specified sample count
 
 RadialFunctionR (const std::vector< double > &r, double dlogr)
 initialize logarithmic grid
 
void set (std::vector< double > r, std::vector< double > dr)
 update the sample locations, weights
 
void initWeights ()
 
double transform (int l, double G) const
 
void transform (int l, double dG, int nGrid, RadialFunctionG &func) const
 

Public Attributes

std::vector< double > r
 radial location
 
std::vector< double > dr
 radial weight
 
std::vector< double > f
 sample value
 

Detailed Description

A function on a non-uniform real-space radial grid.

Member Function Documentation

◆ initWeights()

void RadialFunctionR::initWeights ( )

Compute optimum dr given r (must be in ascending order) which will be exact for the integration of cubic splines with natural boundary conditions. It is recommended that r[0]=0 or r[0]<<r[1], but it'll work fine even otherwise.

◆ transform() [1/2]

void RadialFunctionR::transform ( int  l,
double  dG,
int  nGrid,
RadialFunctionG func 
) const

Initialize a uniform G radial function from the logPrintf grid function according to $ func(G) = \int dr 4\pi r^2 j_l(G r) f(r) $

◆ transform() [2/2]

double RadialFunctionR::transform ( int  l,
double  G 
) const

Evaluate spherical bessel transform of order l at wavevector G: $ func(G) = \int dr 4\pi r^2 j_l(G r) f(r) $


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