QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace > Class Template Reference#

DiFfRG: DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace > Class Template Reference
DiFfRG
Discretization Framework for functional Renormalization Group flows
DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace > Class Template Reference

This class performs numerical integration over a d-dimensional hypercube using quadrature rules. More...

#include <quadrature_integrator.hh>

Inheritance diagram for DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >:
DiFfRG::AbstractIntegrator

Public Types

using ctype = typename get_type::ctype< NT >
 Numerical type to be used for integration tasks e.g. the argument or possible jacobians.
 
using execution_space = ExecutionSpace
 Execution space to be used for the integration, e.g. GPU_exec, TBB_exec.
 

Public Member Functions

 QuadratureIntegrator (QuadratureProvider &quadrature_provider, const std::array< size_t, dim > &_grid_size, const std::array< ctype, dim > &grid_min, const std::array< ctype, dim > &grid_max, const std::array< QuadratureType, dim > &quadrature_type)
 
void set_grid_extents (const std::array< ctype, dim > &grid_min, const std::array< ctype, dim > &grid_max)
 
template<typename... T>
requires is_valid_kernel<NT, KERNEL, ctype, dim, T...>
void get (NT &dest, const T &...t) const
 
template<typename OT , typename... T>
requires (!std::is_same_v<OT, NT> && is_valid_kernel<NT, KERNEL, ctype, dim, T...>)
void get (OT &dest, const T &...t) const
 
template<typename OT , typename... T>
requires (!std::is_same_v<OT, NT> && is_valid_kernel<NT, KERNEL, ctype, dim, T...>)
void get (ExecutionSpace &space, OT &dest, const T &...t) const
 
template<typename view_type , typename Coordinates , typename... Args>
void map (ExecutionSpace &space, const view_type integral_view, const Coordinates &coordinates, const Args &...args)
 
template<typename Coordinates , typename... Args>
auto map (NT *dest, const Coordinates &coordinates, const Args &...args)
 
template<typename Coordinates , typename... Args>
auto map_dist (NT *dest, const Coordinates &coordinates, const Args &...args)
 
- Public Member Functions inherited from DiFfRG::AbstractIntegrator
void set_node_distribution (const NodeDistribution &distribution)
 
const NodeDistributionget_node_distribution () const
 
void set_load_balancer (IntegrationLoadBalancer &load_balancer)
 

Protected Attributes

device::array< size_t, dim > grid_size
 
ExecutionSpace space
 
QuadratureProviderquadrature_provider
 
device::array< device::array< ctype, dim >, 2 > grid_extents
 
device::array< ctype, dim > grid_start
 
device::array< ctype, dim > grid_scale
 
device::array< Kokkos::View< const ctype *, typename ExecutionSpace::memory_space >, dim > nodes
 
device::array< Kokkos::View< const ctype *, typename ExecutionSpace::memory_space >, dim > weights
 
KokkosNDView< 1+dim, NT, ExecutionSpacem_cache
 
device::array< size_t, 1+dim > m_cache_extents {}
 
Kokkos::View< NT *, ExecutionSpacem_dest_device
 
size_t m_dest_device_size = 0
 
Kokkos::View< NT, typename ExecutionSpace::memory_space > m_result_view
 
Kokkos::View< NT, typenameExecutionSpace::memory_space >::host_mirror_type m_result_host
 
bool m_result_views_initialized = false
 
- Protected Attributes inherited from DiFfRG::AbstractIntegrator
NodeDistribution node_distribution
 

Detailed Description

template<int dim, typename NT, typename KERNEL, typename ExecutionSpace>
requires (dim > 0)
class DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >

This class performs numerical integration over a d-dimensional hypercube using quadrature rules.

Template Parameters
dimThe dimension of the hypercube, which can be between 1 and 5.
NTnumerical type of the result
KERNELkernel to be integrated, which must provide the static methods kernel and constant
ExecutionSpacecan be any execution space, e.g. GPU_exec, TBB_exec.

Member Typedef Documentation

◆ ctype

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

◆ execution_space

Execution space to be used for the integration, e.g. GPU_exec, TBB_exec.

Constructor & Destructor Documentation

◆ QuadratureIntegrator()

DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::QuadratureIntegrator ( QuadratureProvider quadrature_provider,
const std::array< size_t, dim > &  _grid_size,
const std::array< ctype, dim > &  grid_min,
const std::array< ctype, dim > &  grid_max,
const std::array< QuadratureType, dim > &  quadrature_type 
)
inline

Member Function Documentation

◆ get() [1/3]

template<typename OT , typename... T>
requires (!std::is_same_v<OT, NT> && is_valid_kernel<NT, KERNEL, ctype, dim, T...>)
void DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::get ( ExecutionSpace space,
OT dest,
const T &...  t 
) const
inline

◆ get() [2/3]

template<typename... T>
requires is_valid_kernel<NT, KERNEL, ctype, dim, T...>
void DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::get ( NT dest,
const T &...  t 
) const
inline

◆ get() [3/3]

template<typename OT , typename... T>
requires (!std::is_same_v<OT, NT> && is_valid_kernel<NT, KERNEL, ctype, dim, T...>)
void DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::get ( OT dest,
const T &...  t 
) const
inline

◆ map() [1/2]

template<typename view_type , typename Coordinates , typename... Args>
void DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::map ( ExecutionSpace space,
const view_type  integral_view,
const Coordinates coordinates,
const Args &...  args 
)
inline

◆ map() [2/2]

template<typename Coordinates , typename... Args>
auto DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::map ( NT dest,
const Coordinates coordinates,
const Args &...  args 
)
inline

◆ map_dist()

template<typename Coordinates , typename... Args>
auto DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::map_dist ( NT dest,
const Coordinates coordinates,
const Args &...  args 
)
inline

◆ set_grid_extents()

void DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::set_grid_extents ( const std::array< ctype, dim > &  grid_min,
const std::array< ctype, dim > &  grid_max 
)
inline

Member Data Documentation

◆ grid_extents

◆ grid_scale

◆ grid_size

◆ grid_start

◆ m_cache

◆ m_cache_extents

device::array<size_t, 1 + dim> DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::m_cache_extents {}
mutableprotected

◆ m_dest_device

Kokkos::View<NT *, ExecutionSpace> DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::m_dest_device
mutableprotected

◆ m_dest_device_size

size_t DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::m_dest_device_size = 0
mutableprotected

◆ m_result_host

Kokkos::View<NT,typenameExecutionSpace::memory_space>::host_mirror_type DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::m_result_host
mutableprotected

◆ m_result_view

Kokkos::View<NT, typename ExecutionSpace::memory_space> DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::m_result_view
mutableprotected

◆ m_result_views_initialized

bool DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::m_result_views_initialized = false
mutableprotected

◆ nodes

device::array<Kokkos::View<const ctype *, typename ExecutionSpace::memory_space>, dim> DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::nodes
protected

◆ quadrature_provider

◆ space

◆ weights

device::array<Kokkos::View<const ctype *, typename ExecutionSpace::memory_space>, dim> DiFfRG::QuadratureIntegrator< dim, NT, KERNEL, ExecutionSpace >::weights
protected

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