Stokhos Package Browser (Single Doxygen Collection) Version of the Day
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Protected Attributes | List of all members
Stokhos::MultiIndex< ordinal_t > Class Template Reference

A multidimensional index. More...

#include <Stokhos_ProductBasisUtils.hpp>

Inheritance diagram for Stokhos::MultiIndex< ordinal_t >:
Inheritance graph
[legend]

Public Types

typedef ordinal_t ordinal_type
 
typedef ordinal_t element_type
 

Public Member Functions

 MultiIndex ()
 Constructor.
 
 MultiIndex (ordinal_type dim, ordinal_type v=ordinal_type(0))
 Constructor.
 
 ~MultiIndex ()
 Destructor.
 
ordinal_type dimension () const
 Dimension.
 
ordinal_type size () const
 Size.
 
const ordinal_typeoperator[] (ordinal_type i) const
 Term access.
 
ordinal_typeoperator[] (ordinal_type i)
 Term access.
 
const Teuchos::Array< element_type > & getTerm () const
 Term access.
 
Teuchos::Array< element_type > & getTerm ()
 Term access.
 
void init (ordinal_type v)
 Initialize.
 
void resize (ordinal_type d, ordinal_type v=ordinal_type(0))
 Resize.
 
ordinal_type order () const
 Compute total order of index.
 
bool operator== (const MultiIndex &idx) const
 Compare equality.
 
bool operator!= (const MultiIndex &idx) const
 Compare equality.
 
bool termWiseLEQ (const MultiIndex &idx) const
 Compare term-wise less-than or equal-to.
 
std::ostream & print (std::ostream &os) const
 Print multiindex.
 
MultiIndextermWiseMin (const MultiIndex &idx)
 Replace multiindex with min of this and other multiindex.
 
MultiIndextermWiseMin (const ordinal_type idx)
 Replace multiindex with min of this and given value.
 
MultiIndextermWiseMax (const MultiIndex &idx)
 Replace multiindex with max of this and other multiindex.
 
MultiIndextermWiseMax (const ordinal_type idx)
 Replace multiindex with max of this and given value.
 

Protected Attributes

Teuchos::Array< ordinal_typeindex
 index terms
 

Detailed Description

template<typename ordinal_t>
class Stokhos::MultiIndex< ordinal_t >

A multidimensional index.

Definition at line 79 of file Stokhos_ProductBasisUtils.hpp.

Member Typedef Documentation

◆ ordinal_type

template<typename ordinal_t >
typedef ordinal_t Stokhos::MultiIndex< ordinal_t >::ordinal_type

Definition at line 82 of file Stokhos_ProductBasisUtils.hpp.

◆ element_type

template<typename ordinal_t >
typedef ordinal_t Stokhos::MultiIndex< ordinal_t >::element_type

Definition at line 83 of file Stokhos_ProductBasisUtils.hpp.

Constructor & Destructor Documentation

◆ MultiIndex() [1/2]

template<typename ordinal_t >
Stokhos::MultiIndex< ordinal_t >::MultiIndex ( )
inline

Constructor.

Definition at line 86 of file Stokhos_ProductBasisUtils.hpp.

◆ MultiIndex() [2/2]

template<typename ordinal_t >
Stokhos::MultiIndex< ordinal_t >::MultiIndex ( ordinal_type  dim,
ordinal_type  v = ordinal_type(0) 
)
inline

Constructor.

Definition at line 89 of file Stokhos_ProductBasisUtils.hpp.

◆ ~MultiIndex()

template<typename ordinal_t >
Stokhos::MultiIndex< ordinal_t >::~MultiIndex ( )
inline

Destructor.

Definition at line 93 of file Stokhos_ProductBasisUtils.hpp.

Member Function Documentation

◆ dimension()

template<typename ordinal_t >
ordinal_type Stokhos::MultiIndex< ordinal_t >::dimension ( ) const
inline

Dimension.

Definition at line 96 of file Stokhos_ProductBasisUtils.hpp.

◆ size()

template<typename ordinal_t >
ordinal_type Stokhos::MultiIndex< ordinal_t >::size ( ) const
inline

Size.

Definition at line 99 of file Stokhos_ProductBasisUtils.hpp.

◆ operator[]() [1/2]

template<typename ordinal_t >
const ordinal_type & Stokhos::MultiIndex< ordinal_t >::operator[] ( ordinal_type  i) const
inline

Term access.

Definition at line 102 of file Stokhos_ProductBasisUtils.hpp.

◆ operator[]() [2/2]

template<typename ordinal_t >
ordinal_type & Stokhos::MultiIndex< ordinal_t >::operator[] ( ordinal_type  i)
inline

Term access.

Definition at line 105 of file Stokhos_ProductBasisUtils.hpp.

◆ getTerm() [1/2]

template<typename ordinal_t >
const Teuchos::Array< element_type > & Stokhos::MultiIndex< ordinal_t >::getTerm ( ) const
inline

Term access.

Definition at line 108 of file Stokhos_ProductBasisUtils.hpp.

◆ getTerm() [2/2]

template<typename ordinal_t >
Teuchos::Array< element_type > & Stokhos::MultiIndex< ordinal_t >::getTerm ( )
inline

Term access.

Definition at line 111 of file Stokhos_ProductBasisUtils.hpp.

◆ init()

template<typename ordinal_t >
void Stokhos::MultiIndex< ordinal_t >::init ( ordinal_type  v)
inline

Initialize.

Definition at line 114 of file Stokhos_ProductBasisUtils.hpp.

◆ resize()

template<typename ordinal_t >
void Stokhos::MultiIndex< ordinal_t >::resize ( ordinal_type  d,
ordinal_type  v = ordinal_type(0) 
)
inline

Resize.

Definition at line 120 of file Stokhos_ProductBasisUtils.hpp.

◆ order()

template<typename ordinal_t >
ordinal_type Stokhos::MultiIndex< ordinal_t >::order ( ) const
inline

Compute total order of index.

Definition at line 125 of file Stokhos_ProductBasisUtils.hpp.

◆ operator==()

template<typename ordinal_t >
bool Stokhos::MultiIndex< ordinal_t >::operator== ( const MultiIndex< ordinal_t > &  idx) const
inline

Compare equality.

Definition at line 132 of file Stokhos_ProductBasisUtils.hpp.

◆ operator!=()

template<typename ordinal_t >
bool Stokhos::MultiIndex< ordinal_t >::operator!= ( const MultiIndex< ordinal_t > &  idx) const
inline

Compare equality.

Definition at line 143 of file Stokhos_ProductBasisUtils.hpp.

◆ termWiseLEQ()

template<typename ordinal_t >
bool Stokhos::MultiIndex< ordinal_t >::termWiseLEQ ( const MultiIndex< ordinal_t > &  idx) const
inline

Compare term-wise less-than or equal-to.

Definition at line 146 of file Stokhos_ProductBasisUtils.hpp.

◆ print()

template<typename ordinal_t >
std::ostream & Stokhos::MultiIndex< ordinal_t >::print ( std::ostream &  os) const
inline

Print multiindex.

Definition at line 155 of file Stokhos_ProductBasisUtils.hpp.

◆ termWiseMin() [1/2]

template<typename ordinal_t >
MultiIndex & Stokhos::MultiIndex< ordinal_t >::termWiseMin ( const MultiIndex< ordinal_t > &  idx)
inline

Replace multiindex with min of this and other multiindex.

Definition at line 164 of file Stokhos_ProductBasisUtils.hpp.

◆ termWiseMin() [2/2]

template<typename ordinal_t >
MultiIndex & Stokhos::MultiIndex< ordinal_t >::termWiseMin ( const ordinal_type  idx)
inline

Replace multiindex with min of this and given value.

Definition at line 171 of file Stokhos_ProductBasisUtils.hpp.

◆ termWiseMax() [1/2]

template<typename ordinal_t >
MultiIndex & Stokhos::MultiIndex< ordinal_t >::termWiseMax ( const MultiIndex< ordinal_t > &  idx)
inline

Replace multiindex with max of this and other multiindex.

Definition at line 178 of file Stokhos_ProductBasisUtils.hpp.

◆ termWiseMax() [2/2]

template<typename ordinal_t >
MultiIndex & Stokhos::MultiIndex< ordinal_t >::termWiseMax ( const ordinal_type  idx)
inline

Replace multiindex with max of this and given value.

Definition at line 185 of file Stokhos_ProductBasisUtils.hpp.

Member Data Documentation

◆ index

template<typename ordinal_t >
Teuchos::Array<ordinal_type> Stokhos::MultiIndex< ordinal_t >::index
protected

index terms

Definition at line 194 of file Stokhos_ProductBasisUtils.hpp.


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