DiFfRG
Loading...
Searching...
No Matches
DiFfRG::Integrator2Dpq0TBB< NT, KERNEL > Class Template Reference

Integrator for 2+1D integrals over p, q0 and an angle using TBB. Calculates. More...

#include <integrator_2Dpq0_cpu.hh>

Public Types

using ctype = typename get_type::ctype<NT>
 Numerical type to be used for integration tasks e.g. the argument or possible jacobians.
 

Public Member Functions

 Integrator2Dpq0TBB (QuadratureProvider &quadrature_provider, const std::array< uint, 3 > grid_sizes, const ctype x_extent, const ctype q0_extent, const JSONValue &)
 Construct a new Integrator2Dpq0TBB object.
 
 Integrator2Dpq0TBB (QuadratureProvider &quadrature_provider, std::array< uint, 3 > grid_sizes, const ctype x_extent, const ctype q0_extent, const uint max_block_size=0)
 Construct a new Integrator2Dpq0TBB object.
 
template<typename... T>
NT get (const ctype k, const T &...t) const
 Get the integral of the kernel.
 
template<typename... T>
std::future< NT > request (const ctype k, const T &...t) const
 Request a future for the integral of the kernel.
 

Private Attributes

const std::array< uint, 3 > grid_sizes
 
const ctype x_extent
 
const ctype q0_extent
 
const std::vector< ctype > & x_quadrature_p
 
const std::vector< ctype > & x_quadrature_w
 
const std::vector< ctype > & ang_quadrature_p
 
const std::vector< ctype > & ang_quadrature_w
 
const std::vector< ctype > & q0_quadrature_p
 
const std::vector< ctype > & q0_quadrature_w
 

Detailed Description

template<typename NT, typename KERNEL>
class DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >

Integrator for 2+1D integrals over p, q0 and an angle using TBB. Calculates.

\[ \int dp dcos dq0 f(p, cos, q0) + c \]

Template Parameters
NTNumerical type.
KERNELKernel to integrate. Must have a static constant member function constant which supplies c and a static member function kernel which supplies the integrand.

Member Typedef Documentation

◆ ctype

template<typename NT , typename KERNEL >
using DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::ctype = typename get_type::ctype<NT>

Numerical type to be used for integration tasks e.g. the argument or possible jacobians.

Constructor & Destructor Documentation

◆ Integrator2Dpq0TBB() [1/2]

template<typename NT , typename KERNEL >
DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::Integrator2Dpq0TBB ( QuadratureProvider & quadrature_provider,
const std::array< uint, 3 > grid_sizes,
const ctype x_extent,
const ctype q0_extent,
const JSONValue &  )
inline

Construct a new Integrator2Dpq0TBB object.

Parameters
quadrature_providerQuadratureProvider object.
grid_sizesGrid sizes for the integrator.
x_extentExtent of the x-quadrature.
q0_extentExtent of the q0-quadrature.
jsonJSON object.

◆ Integrator2Dpq0TBB() [2/2]

template<typename NT , typename KERNEL >
DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::Integrator2Dpq0TBB ( QuadratureProvider & quadrature_provider,
std::array< uint, 3 > grid_sizes,
const ctype x_extent,
const ctype q0_extent,
const uint max_block_size = 0 )
inline

Construct a new Integrator2Dpq0TBB object.

Parameters
quadrature_providerQuadratureProvider object.
grid_sizesGrid sizes for the integrator.
x_extentExtent of the x-quadrature.
q0_extentExtent of the q0-quadrature.
max_block_sizeMaximum block size for the TBB parallel_reduce.

Member Function Documentation

◆ get()

template<typename NT , typename KERNEL >
template<typename... T>
NT DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::get ( const ctype k,
const T &... t ) const
inline

Get the integral of the kernel.

Template Parameters
TTypes of the parameters for the kernel.
Parameters
kRG-scale.
tParameters forwarded to the kernel.
Returns
NT Integral of the kernel plus the constant part.

◆ request()

template<typename NT , typename KERNEL >
template<typename... T>
std::future< NT > DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::request ( const ctype k,
const T &... t ) const
inline

Request a future for the integral of the kernel.

Template Parameters
TTypes of the parameters for the kernel.
Parameters
kRG-scale.
tParameters forwarded to the kernel.
Returns
std::future<NT> future holding the integral of the kernel plus the constant part.

Member Data Documentation

◆ ang_quadrature_p

template<typename NT , typename KERNEL >
const std::vector<ctype>& DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::ang_quadrature_p
private

◆ ang_quadrature_w

template<typename NT , typename KERNEL >
const std::vector<ctype>& DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::ang_quadrature_w
private

◆ grid_sizes

template<typename NT , typename KERNEL >
const std::array<uint, 3> DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::grid_sizes
private

◆ q0_extent

template<typename NT , typename KERNEL >
const ctype DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::q0_extent
private

◆ q0_quadrature_p

template<typename NT , typename KERNEL >
const std::vector<ctype>& DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::q0_quadrature_p
private

◆ q0_quadrature_w

template<typename NT , typename KERNEL >
const std::vector<ctype>& DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::q0_quadrature_w
private

◆ x_extent

template<typename NT , typename KERNEL >
const ctype DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::x_extent
private

◆ x_quadrature_p

template<typename NT , typename KERNEL >
const std::vector<ctype>& DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::x_quadrature_p
private

◆ x_quadrature_w

template<typename NT , typename KERNEL >
const std::vector<ctype>& DiFfRG::Integrator2Dpq0TBB< NT, KERNEL >::x_quadrature_w
private

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