ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
Loading...
Searching...
No Matches
test_radial_proj.cpp File Reference
#include "source_pw/module_proj/radial_proj.h"
#include <algorithm>
#include <fftw3.h>
#include <gtest/gtest.h>
#include <numeric>
#include <random>
Include dependency graph for test_radial_proj.cpp:

Macros

#define DOUBLETHRESHOLD   1e-15

Functions

 TEST (RadialProjectionTest, BuildBackwardMapTest)
 TEST (RadialProjectionTest, BuildForwardMapTest)
 TEST (RadialProjectionTest, MaskfunctionGenerationTest)
 TEST (RadialProjectionTest, BuildSbtTabCorrectnessTest)
 TEST (RadialProjectionTest, BuildSbtTabStabilityTest)
int main ()

Macro Definition Documentation

◆ DOUBLETHRESHOLD

#define DOUBLETHRESHOLD   1e-15

Function Documentation

◆ main()

int main ( )

◆ TEST() [1/5]

TEST ( RadialProjectionTest ,
BuildBackwardMapTest  )

a backward map will index irow to (it, iproj, m). For the above example, it is actually the first atom type has two projectors, the first projector has l = 0, the second has l = 1. The former will have only one channel, the second will have 3. The second atom type has 4 projectors...

Therefore, it is expected there are 1+3+1+3+5+7+1+3+5 = 29 rows in total.

Here is the call graph for this function:

◆ TEST() [2/5]

TEST ( RadialProjectionTest ,
BuildForwardMapTest  )
Here is the call graph for this function:

◆ TEST() [3/5]

TEST ( RadialProjectionTest ,
BuildSbtTabCorrectnessTest  )

The following Python code is used to generate the reference data from scipy.integrate import simps import numpy as np

r = np.arange(0, 2.01, 0.01) mask = np.array(mask) omega = 1

Y00 is 1/sqrt(4*pi)

val = simps(mask*r**2, x=r) * np.sqrt(4*np.pi) print(val/np.sqrt(omega))

Here is the call graph for this function:

◆ TEST() [4/5]

TEST ( RadialProjectionTest ,
BuildSbtTabStabilityTest  )
Here is the call graph for this function:

◆ TEST() [5/5]

TEST ( RadialProjectionTest ,
MaskfunctionGenerationTest  )
Here is the call graph for this function: