WaveBlocksND
Classes | Public Member Functions | Private Attributes | List of all members
waveblocks::wavepackets::HaWpGradient< D, MultiIndex > Class Template Reference

This class represents the gradient \( -i\varepsilon^2\nabla_x \Phi \) of a (scalar) Hagedorn wavepacket \( \Phi \). More...

#include <hawp_gradient_operator.hpp>

Inheritance diagram for waveblocks::wavepackets::HaWpGradient< D, MultiIndex >:
waveblocks::wavepackets::AbstractScalarHaWpBasis< D, MultiIndex >

Classes

class  Component
 This class is component of a Hagedorn wavepacket gradient. More...
 

Public Member Functions

 HaWpGradient ()
 
real_teps ()
 Grants writeable access to the semi-classical scaling parameter \( \varepsilon \) of the wavepacket. More...
 
real_t eps () const override
 Retrieves the semi-classical scaling parameter \( \varepsilon \) of the wavepacket. More...
 
HaWpParamSet< D > & parameters ()
 Grants writeable access to the Hagedorn parameter set \( \Pi \) of the wavepacket. More...
 
HaWpParamSet< D > const & parameters () const override
 Grants read-only access to the Hagedorn parameter set \( \Pi \) of the wavepacket. More...
 
shapes::ShapeEnumSharedPtr< D, MultiIndex > & shape ()
 Grants access to the basis shape \( \mathfrak{K} \) of the wavepacket. More...
 
shapes::ShapeEnumSharedPtr< D, MultiIndex > shape () const override
 Retrieves the basis shape \( \mathfrak{K} \) of the wavepacket. More...
 
Componentcomponent (std::size_t n)
 Grants writeable access to the \( n \)-th component \( \Phi_n \). More...
 
Component const & component (std::size_t n) const
 Grants read-only access to the \( n \)-th component \( \Phi_n \). More...
 
Componentoperator[] (std::size_t n)
 Grants writeable access to the \( n \)-th component \( \Phi_n \). More...
 
Component const & operator[] (std::size_t n) const
 Grants read-only access to the \( n \)-th component \( \Phi_n \). More...
 
std::size_t n_components () const
 Returns the number of components. More...
 
template<int N>
CArray< Eigen::Dynamic, N > evaluate (CMatrix< D, N > const &grid) const
 Evaluate the value of all components at once. More...
 
template<int N>
CArray< Eigen::Dynamic, N > evaluate (RMatrix< D, N > const &rgrid) const
 Evaluates the value of all components at once. More...
 
- Public Member Functions inherited from waveblocks::wavepackets::AbstractScalarHaWpBasis< D, MultiIndex >
template<int N>
HaWpEvaluator< D, MultiIndex, N > create_evaluator (CMatrix< D, N > const &grid) const
 
template<int N>
HaWpBasisVector< N > evaluate_basis (CMatrix< D, N > const &grid) const
 Evaluates all basis functions \( \{\phi_k\} \) on complex grid nodes \( x \in \gamma \). More...
 
template<int N>
HaWpBasisVector< N > evaluate_basis (RMatrix< D, N > const &rgrid) const
 Evaluates all basis functions \( \{\phi_k\} \) on real grid nodes \( x \in \gamma \). More...
 
shapes::ShapeEnumSharedPtr< D, MultiIndex > extended_shape () const
 Computes the extension \( \mathfrak{K}_{ext} \) of the stored basis shape \( \mathfrak{K} \). More...
 

Private Attributes

real_t eps_
 
HaWpParamSet< D > parameters_
 
shapes::ShapeEnumSharedPtr< D, MultiIndex > shape_
 
std::vector< Componentcomponents_
 

Detailed Description

template<dim_t D, class MultiIndex>
class waveblocks::wavepackets::HaWpGradient< D, MultiIndex >

This class represents the gradient \( -i\varepsilon^2\nabla_x \Phi \) of a (scalar) Hagedorn wavepacket \( \Phi \).

The gradient of a \( D \)-dimensional wavepacket has \( D \) components.

Creation

Apply HaWpGradientOperator to an AbstractScalarHaWp to create an instance:

HaWpGradientOperator<D,MultiIndex> nabla;
HaWpGradient<D,MultiIndex> gradwp = nabla(wavepacket);
Template Parameters
Ddimensionality and number of components
MultiIndex

Constructor & Destructor Documentation

template<dim_t D, class MultiIndex>
waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::HaWpGradient ( )
inline

Member Function Documentation

template<dim_t D, class MultiIndex>
Component& waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::component ( std::size_t  n)
inline

Grants writeable access to the \( n \)-th component \( \Phi_n \).

Parameters
nThe index \( n \) of the requested component.
Returns
Reference to the requested component.
template<dim_t D, class MultiIndex>
Component const& waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::component ( std::size_t  n) const
inline

Grants read-only access to the \( n \)-th component \( \Phi_n \).

Parameters
nThe index \( n \) of the requested component.
Returns
Reference to the requested component.
template<dim_t D, class MultiIndex>
real_t& waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::eps ( )
inline

Grants writeable access to the semi-classical scaling parameter \( \varepsilon \) of the wavepacket.

template<dim_t D, class MultiIndex>
real_t waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::eps ( ) const
inlineoverridevirtual

Retrieves the semi-classical scaling parameter \( \varepsilon \) of the wavepacket.

Implements waveblocks::wavepackets::AbstractScalarHaWpBasis< D, MultiIndex >.

template<dim_t D, class MultiIndex>
template<int N>
CArray<Eigen::Dynamic,N> waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::evaluate ( CMatrix< D, N > const &  grid) const
inline

Evaluate the value of all components at once.

Evaluates \( \Psi(x) = \{\Phi_i(x)\} \), where \( x \) is is a complex quadrature point.

Parameters
gridComplex quadrature points. Complex matrix of shape \( (D \times X) \), where \( X \) is the number of quadrature points.
Returns
Complex 2D-Array of shape \( (D \times X) \)
Template Parameters
NNumber of quadrature points. Don't use Eigen::Dynamic. It works, but performance is bad.
template<dim_t D, class MultiIndex>
template<int N>
CArray<Eigen::Dynamic,N> waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::evaluate ( RMatrix< D, N > const &  rgrid) const
inline

Evaluates the value of all components at once.

Evaluates \( \Psi(x) = \{\Phi_i(x)\} \), where \( x \) is is a real quadrature point.

Parameters
rgridReal quadrature points. Real matrix of shape \( (D \times X) \), where \( X \) is the number of quadrature points.
Returns
Complex 2D-Array of shape \( (D \times X) \)
Template Parameters
NNumber of quadrature points. Don't use Eigen::Dynamic. It works, but performance is bad.
template<dim_t D, class MultiIndex>
std::size_t waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::n_components ( ) const
inline

Returns the number of components.

template<dim_t D, class MultiIndex>
Component& waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::operator[] ( std::size_t  n)
inline

Grants writeable access to the \( n \)-th component \( \Phi_n \).

Parameters
nThe index \( n \) of the requested component.
Returns
Reference to the requested component.
template<dim_t D, class MultiIndex>
Component const& waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::operator[] ( std::size_t  n) const
inline

Grants read-only access to the \( n \)-th component \( \Phi_n \).

Parameters
nThe index \( n \) of the requested component.
Returns
Reference to the requested component.
template<dim_t D, class MultiIndex>
HaWpParamSet<D>& waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::parameters ( )
inline

Grants writeable access to the Hagedorn parameter set \( \Pi \) of the wavepacket.

template<dim_t D, class MultiIndex>
HaWpParamSet<D> const& waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::parameters ( ) const
inlineoverridevirtual

Grants read-only access to the Hagedorn parameter set \( \Pi \) of the wavepacket.

Implements waveblocks::wavepackets::AbstractScalarHaWpBasis< D, MultiIndex >.

template<dim_t D, class MultiIndex>
shapes::ShapeEnumSharedPtr<D,MultiIndex>& waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::shape ( )
inline

Grants access to the basis shape \( \mathfrak{K} \) of the wavepacket.

Returns
Reference to the shape enumeration pointer. You can assign a new pointer to it!
template<dim_t D, class MultiIndex>
shapes::ShapeEnumSharedPtr<D,MultiIndex> waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::shape ( ) const
inlineoverridevirtual

Retrieves the basis shape \( \mathfrak{K} \) of the wavepacket.

Implements waveblocks::wavepackets::AbstractScalarHaWpBasis< D, MultiIndex >.

Member Data Documentation

template<dim_t D, class MultiIndex>
std::vector<Component> waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::components_
private
template<dim_t D, class MultiIndex>
real_t waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::eps_
private
template<dim_t D, class MultiIndex>
HaWpParamSet<D> waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::parameters_
private
template<dim_t D, class MultiIndex>
shapes::ShapeEnumSharedPtr<D,MultiIndex> waveblocks::wavepackets::HaWpGradient< D, MultiIndex >::shape_
private

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