OpenFPM  5.2.0
Project that contain the implementation of distributed structures
vector_dist_expression_impl< vector_type > Class Template Reference

Main class that encapsulate a vector properties operand to be used for expressions construction Temporal Expressions. More...

#include <vector_dist_operators.hpp>

Public Types

typedef T * iterator
 
typedef const T * const_iterator
 
typedef has_vector_kernel< vector >::type is_ker
 
typedef vector vtype
 The type of the internal vector.
 
typedef T value_type
 The type of the internal value.
 
typedef void NN_type
 NN_type.
 

Public Member Functions

void setVarId (int var_id)
 
iterator begin ()
 
const_iterator begin () const
 
iterator end ()
 
const_iterator end () const
 
size_t size () const
 
void resize (size_t n)
 
template<unsigned int prp2, typename vector2 >
 vector_dist_expression_impl (const vector_dist_expression< prp2, vector2 > &v_exp)
 
template<typename exp1 , typename exp2 , unsigned int op>
 vector_dist_expression_impl (const vector_dist_expression_op< exp1, exp2, op > &v_exp)
 
void * getNN () const
 get the NN object More...
 
__device__ __host__ const vectorgetVector () const
 Return the vector on which is acting. More...
 
__device__ __host__ vectorgetVector ()
 Return the vector on which is acting. More...
 
void init () const
 This function must be called before value. More...
 
__host__ __device__ auto value (const vect_dist_key_dx &k) const -> decltype(v.template get< 0 >(k.getKey()))
 Evaluate the expression. More...
 
template<unsigned int prp2, typename vector2 >
vectoroperator= (const vector_dist_expression< prp2, vector2 > &v_exp)
 Fill the vector property with the evaluated expression. More...
 
template<typename exp1 , typename exp2 , unsigned int op>
vectoroperator= (const vector_dist_expression_op< exp1, exp2, op > &v_exp)
 Fill the vector property with the evaluated expression. More...
 
vectoroperator= (double d)
 Fill the vector property with the double. More...
 
template<typename Sys_eqs , typename pmap_type , typename unordered_map_type , typename coeff_type >
void value_nz (pmap_type &p_map, const vect_dist_key_dx &key, unordered_map_type &cols, coeff_type &coeff, unsigned int comp) const
 
vector_dist_expression_op< vector_dist_expression< 0, vector >, boost::mpl::int_< 1 >, VECT_COMP > operator[] (int comp)
 

Data Fields

int var_id = 0
 

Static Public Attributes

static const unsigned int prop = 0
 Property id of the point.
 

Private Types

typedef vector_type vector
 Internal vector.
 
typedef boost::mpl::at< typename vector_type::value_type::type, boost::mpl::int_< 0 > >::type T
 

Private Attributes

vector v
 The temporal vector.
 

Detailed Description

template<typename vector_type>
class vector_dist_expression_impl< vector_type >

Main class that encapsulate a vector properties operand to be used for expressions construction Temporal Expressions.

Template Parameters
prpproperty involved
vectorinvolved

Definition at line 1189 of file vector_dist_operators.hpp.

Member Function Documentation

◆ getNN()

template<typename vector_type >
void* vector_dist_expression_impl< vector_type >::getNN ( ) const
inline

get the NN object

Returns
the NN object

Definition at line 1305 of file vector_dist_operators.hpp.

◆ getVector() [1/2]

template<typename vector_type >
__device__ __host__ vector& vector_dist_expression_impl< vector_type >::getVector ( )
inline

Return the vector on which is acting.

It return the vector used in getVExpr, to get this object

Returns
the vector

Definition at line 1329 of file vector_dist_operators.hpp.

◆ getVector() [2/2]

template<typename vector_type >
__device__ __host__ const vector& vector_dist_expression_impl< vector_type >::getVector ( ) const
inline

Return the vector on which is acting.

It return the vector used in getVExpr, to get this object

Returns
the vector

Definition at line 1317 of file vector_dist_operators.hpp.

◆ init()

template<typename vector_type >
void vector_dist_expression_impl< vector_type >::init ( ) const
inline

This function must be called before value.

it initialize the expression if needed

Definition at line 1339 of file vector_dist_operators.hpp.

◆ operator=() [1/3]

template<typename vector_type >
template<unsigned int prp2, typename vector2 >
vector& vector_dist_expression_impl< vector_type >::operator= ( const vector_dist_expression< prp2, vector2 > &  v_exp)
inline

Fill the vector property with the evaluated expression.

Parameters
v_expexpression to evaluate
Returns
itself

Definition at line 1362 of file vector_dist_operators.hpp.

◆ operator=() [2/3]

template<typename vector_type >
template<typename exp1 , typename exp2 , unsigned int op>
vector& vector_dist_expression_impl< vector_type >::operator= ( const vector_dist_expression_op< exp1, exp2, op > &  v_exp)
inline

Fill the vector property with the evaluated expression.

Parameters
v_expexpression to evaluate
Returns
itself

Definition at line 1395 of file vector_dist_operators.hpp.

◆ operator=() [3/3]

template<typename vector_type >
vector& vector_dist_expression_impl< vector_type >::operator= ( double  d)
inline

Fill the vector property with the double.

Parameters
dvalue to fill
Returns
the internal vector

Definition at line 1426 of file vector_dist_operators.hpp.

◆ value()

template<typename vector_type >
__host__ __device__ auto vector_dist_expression_impl< vector_type >::value ( const vect_dist_key_dx k) const -> decltype(v.template get<0>(k.getKey()))
inline

Evaluate the expression.

Parameters
kwhere to evaluate the expression
Returns
the result of the expression

Definition at line 1349 of file vector_dist_operators.hpp.


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