MADNESS 0.10.1
Public Types | Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
madness::Derivative< T, NDIM > Class Template Reference

Implements derivatives operators with variety of boundary conditions on simulation domain. More...

#include <derivative.h>

Inheritance diagram for madness::Derivative< T, NDIM >:
Inheritance graph
[legend]
Collaboration diagram for madness::Derivative< T, NDIM >:
Collaboration graph
[legend]

Public Types

typedef std::pair< keyT, coeffTargT
 
typedef GenTensor< TcoeffT
 holding the node's coeffs (possibly low rank)
 
typedef WorldContainer< Key< NDIM >, FunctionNode< T, NDIM > > dcT
 
typedef Function< T, NDIMfunctionT
 
typedef FunctionImpl< T, NDIMimplT
 
typedef Key< NDIMkeyT
 
typedef FunctionNode< T, NDIMnodeT
 
typedef T opT
 
typedef Tensor< TtensorT
 
- Public Types inherited from madness::DerivativeBase< T, NDIM >
typedef std::pair< keyT, coeffTargT
 
typedef GenTensor< TcoeffT
 holding the node's coeffs (possibly low rank)
 
typedef WorldContainer< Key< NDIM >, FunctionNode< T, NDIM > > dcT
 
typedef Function< T, NDIMfunctionT
 
typedef FunctionImpl< T, NDIMimplT
 
typedef Key< NDIMkeyT
 
typedef FunctionNode< T, NDIMnodeT
 
typedef Tensor< TtensorT
 regular tensors, like rm, etc
 
- Public Types inherited from madness::WorldObject< DerivativeBase< T, NDIM > >
typedef WorldObject< DerivativeBase< T, NDIM > > objT
 

Public Member Functions

 Derivative (World &world, std::size_t axis, const BoundaryConditions< NDIM > &bc=FunctionDefaults< NDIM >::get_bc(), const functionT g1=functionT(), const functionT g2=functionT(), int k=FunctionDefaults< NDIM >::get_k())
 Constructs a derivative operator.
 
virtual ~Derivative ()
 
void read_from_file (const std::string &filename, unsigned int order=1)
 
void set_ble1 ()
 
void set_ble2 ()
 
void set_bspline1 ()
 
void set_bspline2 ()
 
void set_bspline3 ()
 
void set_is_first ()
 
void set_is_second ()
 
void set_is_third ()
 
- Public Member Functions inherited from madness::DerivativeBase< T, NDIM >
 DerivativeBase (World &world, std::size_t axis, int k, BoundaryConditions< NDIM > bc)
 
virtual ~DerivativeBase ()
 
void do_diff1 (const implT *f, implT *df, const keyT &key, const argT &left, const argT &center, const argT &right) const
 
Future< argTfind_neighbor (const implT *f, const Key< NDIM > &key, int step) const
 
void forward_do_diff1 (const implT *f, implT *df, const keyT &key, const argT &left, const argT &center, const argT &right) const
 
Key< NDIMneighbor (const keyT &key, int step) const
 
Function< T, NDIMoperator() (const functionT &f, bool fence=true) const
 Differentiate w.r.t. given coordinate (x=0, y=1, ...) with optional fence.
 
template<typename Archive >
void serialize (const Archive &ar) const
 
- Public Member Functions inherited from madness::WorldObject< DerivativeBase< T, NDIM > >
 WorldObject (const WorldObject &other)
 
 WorldObject (World &world)
 Constructor that associates an object (via the derived class) with a globally unique ID.
 
virtual ~WorldObject ()
 
Worldget_world () const
 Returns a reference to the world.
 
const uniqueidTid () const
 Returns the globally unique object ID.
 
WorldObjectoperator= (const WorldObject &)=delete
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn) const
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn, const a1T &a1) const
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2) const
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3) const
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4) const
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5) const
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5, const a6T &a6) const
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5, const a6T &a6, const a7T &a7) const
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5, const a6T &a6, const a7T &a7, const a8T &a8) const
 
detail::task_result_type< memfnT >::futureT send (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5, const a6T &a6, const a7T &a7, const a8T &a8, const a9T &a9) const
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5, const a6T &a6, const a7T &a7, const a8T &a8, const a9T &a9, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)(a1,a2,a3,a4,a5,a6,a7,a8,a9).
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5, const a6T &a6, const a7T &a7, const a8T &a8, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)(a1,a2,a3,a4,a5,a6,a7,a8).
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5, const a6T &a6, const a7T &a7, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)(a1,a2,a3,a4,a5,a6,a7).
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5, const a6T &a6, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)(a1,a2,a3,a4,a5,a6).
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const a5T &a5, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)(a1,a2,a3,a4,a5).
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const a4T &a4, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)(a1,a2,a3,a4).
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const a3T &a3, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)(a1,a2,a3).
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const a1T &a1, const a2T &a2, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)(a1,a2).
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const a1T &a1, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)(a1).
 
detail::task_result_type< memfnT >::futureT task (ProcessID dest, memfnT memfn, const TaskAttributes &attr=TaskAttributes()) const
 Sends task to derived class method returnT (this->*memfn)().
 
- Public Member Functions inherited from madness::WorldObjectBase
virtual ~WorldObjectBase ()=default
 

Private Types

typedef DerivativeBase< T, NDIMbaseT
 

Private Member Functions

void do_diff2b (const implT *f, implT *df, const keyT &key, const argT &left, const argT &center, const argT &right) const
 
void do_diff2i (const implT *f, implT *df, const keyT &key, const argT &left, const argT &center, const argT &right) const
 
void initCoefficients ()
 

Private Attributes

Tensor< double > bv_left
 
Tensor< double > bv_right
 Blocks of the derivative operator for the boundary contribution.
 
const functionT g1
 Function describing the boundary condition on the right side.
 
const functionT g2
 Function describing the boundary condition on the left side.
 
bool is_second
 
bool is_third
 
Tensor< double > left_r0
 Blocks of the derivative for the left boundary.
 
Tensor< double > left_r0t
 Blocks of the derivative for the left boundary.
 
Tensor< double > left_rm
 
Tensor< double > left_rmt
 
Tensor< double > r0
 
Tensor< double > r0_bsp
 
Tensor< double > r0_bsp_t
 
Tensor< double > r0t
 
Tensor< double > right_r0
 
Tensor< double > right_r0t
 
Tensor< double > right_rp
 Blocks of the derivative for the right boundary.
 
Tensor< double > right_rpt
 Blocks of the derivative for the right boundary.
 
Tensor< double > rm
 
Tensor< double > rm_bsp
 
Tensor< double > rm_bsp_t
 
Tensor< double > rmt
 
Tensor< double > rp
 Blocks of the derivative operator.
 
Tensor< double > rp_bsp
 
Tensor< double > rp_bsp_t
 
Tensor< double > rpt
 Blocks of the derivative operator, transposed.
 

Additional Inherited Members

- Static Public Member Functions inherited from madness::DerivativeBase< T, NDIM >
static bool enforce_bc (int bc_left, int bc_right, Level n, Translation &l)
 
- Protected Member Functions inherited from madness::WorldObject< DerivativeBase< T, NDIM > >
void process_pending ()
 To be called from derived constructor to process pending messages.
 
- Protected Attributes inherited from madness::DerivativeBase< T, NDIM >
const std::size_t axis
 Axis along which the operation is performed.
 
const BoundaryConditions< NDIMbc
 
const int k
 Number of wavelets of the function.
 
const std::vector< long > vk
 (k,...) used to initialize Tensors
 
Worldworld
 

Detailed Description

template<typename T, std::size_t NDIM>
class madness::Derivative< T, NDIM >

Implements derivatives operators with variety of boundary conditions on simulation domain.

Member Typedef Documentation

◆ argT

template<typename T , std::size_t NDIM>
typedef std::pair<keyT,coeffT> madness::Derivative< T, NDIM >::argT

◆ baseT

template<typename T , std::size_t NDIM>
typedef DerivativeBase<T, NDIM> madness::Derivative< T, NDIM >::baseT
private

◆ coeffT

template<typename T , std::size_t NDIM>
typedef GenTensor<T> madness::Derivative< T, NDIM >::coeffT

holding the node's coeffs (possibly low rank)

◆ dcT

template<typename T , std::size_t NDIM>
typedef WorldContainer< Key<NDIM> , FunctionNode<T, NDIM> > madness::Derivative< T, NDIM >::dcT

◆ functionT

template<typename T , std::size_t NDIM>
typedef Function<T,NDIM> madness::Derivative< T, NDIM >::functionT

◆ implT

template<typename T , std::size_t NDIM>
typedef FunctionImpl<T,NDIM> madness::Derivative< T, NDIM >::implT

◆ keyT

template<typename T , std::size_t NDIM>
typedef Key<NDIM> madness::Derivative< T, NDIM >::keyT

◆ nodeT

template<typename T , std::size_t NDIM>
typedef FunctionNode<T,NDIM> madness::Derivative< T, NDIM >::nodeT

◆ opT

template<typename T , std::size_t NDIM>
typedef T madness::Derivative< T, NDIM >::opT

◆ tensorT

template<typename T , std::size_t NDIM>
typedef Tensor<T> madness::Derivative< T, NDIM >::tensorT

Constructor & Destructor Documentation

◆ Derivative()

template<typename T , std::size_t NDIM>
madness::Derivative< T, NDIM >::Derivative ( World world,
std::size_t  axis,
const BoundaryConditions< NDIM > &  bc = FunctionDefaults<NDIM>::get_bc(),
const functionT  g1 = functionT(),
const functionT  g2 = functionT(),
int  k = FunctionDefaults<NDIM>::get_k() 
)
inline

Constructs a derivative operator.

Parameters
worldThe world
axisThe direction to differentiate
bcBoundary conditions (default from FunctionDefaults)
g1Function providing left boundary value (default empty)
g2Function providing right boundary value (default empty)
kWavelet order (default from FunctionDefaults)

References madness::DerivativeBase< T, NDIM >::axis, madness::Derivative< T, NDIM >::g1, madness::Derivative< T, NDIM >::g2, madness::Derivative< T, NDIM >::initCoefficients(), MADNESS_ASSERT, NDIM, and madness::WorldObject< DerivativeBase< T, NDIM > >::process_pending().

◆ ~Derivative()

template<typename T , std::size_t NDIM>
virtual madness::Derivative< T, NDIM >::~Derivative ( )
inlinevirtual

Member Function Documentation

◆ do_diff2b()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::do_diff2b ( const implT f,
implT df,
const keyT key,
const argT left,
const argT center,
const argT right 
) const
inlineprivatevirtual

◆ do_diff2i()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::do_diff2i ( const implT f,
implT df,
const keyT key,
const argT left,
const argT center,
const argT right 
) const
inlineprivatevirtual

◆ initCoefficients()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::initCoefficients ( )
inlineprivate

◆ read_from_file()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::read_from_file ( const std::string &  filename,
unsigned int  order = 1 
)
inline

◆ set_ble1()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::set_ble1 ( )
inline

◆ set_ble2()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::set_ble2 ( )
inline

◆ set_bspline1()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::set_bspline1 ( )
inline

◆ set_bspline2()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::set_bspline2 ( )
inline

◆ set_bspline3()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::set_bspline3 ( )
inline

◆ set_is_first()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::set_is_first ( )
inline

◆ set_is_second()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::set_is_second ( )
inline

◆ set_is_third()

template<typename T , std::size_t NDIM>
void madness::Derivative< T, NDIM >::set_is_third ( )
inline

Member Data Documentation

◆ bv_left

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::bv_left
private

◆ bv_right

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::bv_right
private

Blocks of the derivative operator for the boundary contribution.

Referenced by madness::Derivative< T, NDIM >::do_diff2b(), and madness::Derivative< T, NDIM >::initCoefficients().

◆ g1

template<typename T , std::size_t NDIM>
const functionT madness::Derivative< T, NDIM >::g1
private

Function describing the boundary condition on the right side.

Referenced by madness::Derivative< T, NDIM >::Derivative(), and madness::Derivative< T, NDIM >::do_diff2b().

◆ g2

template<typename T , std::size_t NDIM>
const functionT madness::Derivative< T, NDIM >::g2
private

Function describing the boundary condition on the left side.

Referenced by madness::Derivative< T, NDIM >::Derivative(), and madness::Derivative< T, NDIM >::do_diff2b().

◆ is_second

template<typename T , std::size_t NDIM>
bool madness::Derivative< T, NDIM >::is_second
private

◆ is_third

template<typename T , std::size_t NDIM>
bool madness::Derivative< T, NDIM >::is_third
private

◆ left_r0

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::left_r0
private

Blocks of the derivative for the left boundary.

Referenced by madness::Derivative< T, NDIM >::initCoefficients(), and madness::Derivative< T, NDIM >::read_from_file().

◆ left_r0t

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::left_r0t
private

◆ left_rm

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::left_rm
private

◆ left_rmt

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::left_rmt
private

◆ r0

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::r0
private

◆ r0_bsp

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::r0_bsp
private

◆ r0_bsp_t

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::r0_bsp_t
private

◆ r0t

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::r0t
private

◆ right_r0

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::right_r0
private

◆ right_r0t

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::right_r0t
private

◆ right_rp

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::right_rp
private

Blocks of the derivative for the right boundary.

Referenced by madness::Derivative< T, NDIM >::initCoefficients(), and madness::Derivative< T, NDIM >::read_from_file().

◆ right_rpt

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::right_rpt
private

◆ rm

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::rm
private

◆ rm_bsp

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::rm_bsp
private

◆ rm_bsp_t

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::rm_bsp_t
private

◆ rmt

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::rmt
private

◆ rp

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::rp
private

◆ rp_bsp

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::rp_bsp
private

◆ rp_bsp_t

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::rp_bsp_t
private

◆ rpt

template<typename T , std::size_t NDIM>
Tensor<double> madness::Derivative< T, NDIM >::rpt
private

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