Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
boost::numeric::ublas::permutation_matrix< T, A > Class Template Reference

#include <lu.hpp>

Inheritance diagram for boost::numeric::ublas::permutation_matrix< T, A >:
Collaboration diagram for boost::numeric::ublas::permutation_matrix< T, A >:

Public Types

typedef vector< T, A > vector_type
 
typedef vector_type::size_type size_type
 
typedef A::difference_type difference_type
 
typedef T value_type
 
typedef type_traits< T >
::const_reference 
const_reference
 
typedef Treference
 
typedef Tpointer
 
typedef const Tconst_pointer
 
typedef A array_type
 
typedef const vector_reference
< const self_type
const_closure_type
 
typedef vector_reference
< self_type
closure_type
 
typedef self_type vector_temporary_type
 
typedef dense_tag storage_category
 
typedef reverse_iterator_base
< const_iterator
const_reverse_iterator
 
typedef reverse_iterator_base
< iterator
reverse_iterator
 
typedef vector< T, A > container_type
 
typedef vector_tag type_category
 
typedef E expression_type
 

Public Member Functions

BOOST_UBLAS_INLINE permutation_matrix (size_type size)
 
BOOST_UBLAS_INLINE permutation_matrix (const vector_type &init)
 
BOOST_UBLAS_INLINE ~permutation_matrix ()
 
BOOST_UBLAS_INLINE
permutation_matrix
operator= (const permutation_matrix &m)
 
BOOST_UBLAS_INLINE size_type max_size () const
 Return the maximum size of the data container. More...
 
BOOST_UBLAS_INLINE bool empty () const
 Return true if the vector is empty (size==0) More...
 
BOOST_UBLAS_INLINE size_type size () const
 Return the size of the vector. More...
 
BOOST_UBLAS_INLINE const
array_type
data () const
 Return a const reference to the container. Useful to access data directly for specific type of container. More...
 
BOOST_UBLAS_INLINE array_typedata ()
 Return a reference to the container. Useful to speed-up write operations to the data in very specific case. More...
 
BOOST_UBLAS_INLINE void resize (size_type size, bool preserve=true)
 Resize the vector Resize the vector to a new size. More...
 
BOOST_UBLAS_INLINE pointer find_element (size_type i)
 Return a pointer to the element $i$. More...
 
BOOST_UBLAS_INLINE const_pointer find_element (size_type i) const
 Return a const pointer to the element $i$. More...
 
BOOST_UBLAS_INLINE const_reference operator() (size_type i) const
 Return a const reference to the element $i$ Return a const reference to the element $i$. More...
 
BOOST_UBLAS_INLINE reference operator() (size_type i)
 Return a reference to the element $i$ Return a reference to the element $i$. More...
 
BOOST_UBLAS_INLINE const
container_type
operator() () const
 
BOOST_UBLAS_INLINE container_typeoperator() ()
 
BOOST_UBLAS_INLINE const_reference operator[] (size_type i) const
 Return a const reference to the element $i$. More...
 
BOOST_UBLAS_INLINE reference operator[] (size_type i)
 Return a reference to the element $i$. More...
 
BOOST_UBLAS_INLINE reference insert_element (size_type i, const_reference t)
 Set element $i$ to the value t. More...
 
BOOST_UBLAS_INLINE void erase_element (size_type i)
 Set element $i$ to the zero value. More...
 
BOOST_UBLAS_INLINE void clear ()
 Clear the vector, i.e. set all values to the zero value. More...
 
BOOST_UBLAS_INLINE vectorassign_temporary (vector &v)
 Assign a full vector (RHS-vector) to the current vector (LHS-vector) More...
 
template<class AE >
BOOST_UBLAS_INLINE vectorassign (const vector_expression< AE > &ae)
 Assign the result of a vector_expression to the vector Assign the result of a vector_expression to the vector. More...
 
template<class AE >
BOOST_UBLAS_INLINE vectoroperator+= (const vector_expression< AE > &ae)
 Assign the sum of the vector and a vector_expression to the vector Assign the sum of the vector and a vector_expression to the vector. More...
 
template<class C >
BOOST_UBLAS_INLINE vectoroperator+= (const vector_container< C > &v)
 Assign the sum of the vector and a vector_expression to the vector Assign the sum of the vector and a vector_expression to the vector. More...
 
template<class AE >
BOOST_UBLAS_INLINE vectorplus_assign (const vector_expression< AE > &ae)
 Assign the sum of the vector and a vector_expression to the vector Assign the sum of the vector and a vector_expression to the vector. More...
 
template<class AE >
BOOST_UBLAS_INLINE vectoroperator-= (const vector_expression< AE > &ae)
 Assign the difference of the vector and a vector_expression to the vector Assign the difference of the vector and a vector_expression to the vector. More...
 
template<class C >
BOOST_UBLAS_INLINE vectoroperator-= (const vector_container< C > &v)
 Assign the difference of the vector and a vector_expression to the vector Assign the difference of the vector and a vector_expression to the vector. More...
 
template<class AE >
BOOST_UBLAS_INLINE vectorminus_assign (const vector_expression< AE > &ae)
 Assign the difference of the vector and a vector_expression to the vector Assign the difference of the vector and a vector_expression to the vector. More...
 
template<class AT >
BOOST_UBLAS_INLINE vectoroperator*= (const AT &at)
 Assign the product of the vector and a scalar to the vector Assign the product of the vector and a scalar to the vector. More...
 
template<class AT >
BOOST_UBLAS_INLINE vectoroperator/= (const AT &at)
 Assign the division of the vector by a scalar to the vector Assign the division of the vector by a scalar to the vector. More...
 
BOOST_UBLAS_INLINE void swap (vector &v)
 Swap the content of the vector with another vector. More...
 
BOOST_UBLAS_INLINE const_iterator find (size_type i) const
 Return a const iterator to the element i. More...
 
BOOST_UBLAS_INLINE iterator find (size_type i)
 Return an iterator to the element i. More...
 
BOOST_UBLAS_INLINE const_iterator begin () const
 return an iterator on the first element of the vector More...
 
BOOST_UBLAS_INLINE iterator begin ()
 Return an iterator on the first element of the vector. More...
 
BOOST_UBLAS_INLINE const_iterator cbegin () const
 return an iterator on the first element of the vector More...
 
BOOST_UBLAS_INLINE const_iterator end () const
 return an iterator after the last element of the vector More...
 
BOOST_UBLAS_INLINE iterator end ()
 Return an iterator at the end of the vector. More...
 
BOOST_UBLAS_INLINE const_iterator cend () const
 return an iterator after the last element of the vector More...
 
BOOST_UBLAS_INLINE
const_reverse_iterator 
rbegin () const
 Return a const reverse iterator before the first element of the reversed vector (i.e. end() of normal vector) More...
 
BOOST_UBLAS_INLINE reverse_iterator rbegin ()
 Return a const reverse iterator before the first element of the reversed vector (i.e. end() of normal vector) More...
 
BOOST_UBLAS_INLINE
const_reverse_iterator 
crbegin () const
 Return a const reverse iterator before the first element of the reversed vector (i.e. end() of normal vector) More...
 
BOOST_UBLAS_INLINE
const_reverse_iterator 
rend () const
 Return a const reverse iterator on the end of the reverse vector (i.e. first element of the normal vector) More...
 
BOOST_UBLAS_INLINE reverse_iterator rend ()
 Return a const reverse iterator on the end of the reverse vector (i.e. first element of the normal vector) More...
 
BOOST_UBLAS_INLINE
const_reverse_iterator 
crend () const
 Return a const reverse iterator on the end of the reverse vector (i.e. first element of the normal vector) More...
 
template<class Archive >
void serialize (Archive &ar, const unsigned int)
 Serialize a vector into and archive as defined in Boost. More...
 

Static Public Attributes

static const unsigned complexity
 

Detailed Description

template<class T = std::size_t, class A = unbounded_array<T>>
class boost::numeric::ublas::permutation_matrix< T, A >

Template Parameters
T
A

Member Typedef Documentation

template<class T, class A>
typedef A boost::numeric::ublas::vector< T, A >::array_type
inherited
template<class T, class A>
typedef vector_reference<self_type> boost::numeric::ublas::vector< T, A >::closure_type
inherited
template<class T, class A>
typedef const vector_reference<const self_type> boost::numeric::ublas::vector< T, A >::const_closure_type
inherited
template<class T, class A>
typedef const T* boost::numeric::ublas::vector< T, A >::const_pointer
inherited
template<class T, class A>
typedef type_traits<T>::const_reference boost::numeric::ublas::vector< T, A >::const_reference
inherited
template<class T, class A>
typedef reverse_iterator_base<const_iterator> boost::numeric::ublas::vector< T, A >::const_reverse_iterator
inherited
template<class T, class A>
typedef A::difference_type boost::numeric::ublas::vector< T, A >::difference_type
inherited
template<class E>
typedef E boost::numeric::ublas::vector_expression< E >::expression_type
inherited
template<class T, class A>
typedef T* boost::numeric::ublas::vector< T, A >::pointer
inherited
template<class T, class A>
typedef T& boost::numeric::ublas::vector< T, A >::reference
inherited
template<class T, class A>
typedef reverse_iterator_base<iterator> boost::numeric::ublas::vector< T, A >::reverse_iterator
inherited
template<class T = std::size_t, class A = unbounded_array<T>>
typedef vector_type::size_type boost::numeric::ublas::permutation_matrix< T, A >::size_type
template<class T, class A>
typedef dense_tag boost::numeric::ublas::vector< T, A >::storage_category
inherited
template<class T, class A>
typedef T boost::numeric::ublas::vector< T, A >::value_type
inherited
template<class T, class A>
typedef self_type boost::numeric::ublas::vector< T, A >::vector_temporary_type
inherited
template<class T = std::size_t, class A = unbounded_array<T>>
typedef vector<T, A> boost::numeric::ublas::permutation_matrix< T, A >::vector_type

Constructor & Destructor Documentation

template<class T = std::size_t, class A = unbounded_array<T>>
BOOST_UBLAS_INLINE boost::numeric::ublas::permutation_matrix< T, A >::permutation_matrix ( size_type  size)
inlineexplicit
template<class T = std::size_t, class A = unbounded_array<T>>
BOOST_UBLAS_INLINE boost::numeric::ublas::permutation_matrix< T, A >::permutation_matrix ( const vector_type init)
inlineexplicit
template<class T = std::size_t, class A = unbounded_array<T>>
BOOST_UBLAS_INLINE boost::numeric::ublas::permutation_matrix< T, A >::~permutation_matrix ( )
inline

Member Function Documentation

template<class T, class A>
template<class AE >
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::assign ( const vector_expression< AE > &  ae)
inlineinherited

Assign the result of a vector_expression to the vector Assign the result of a vector_expression to the vector.

This is lazy-compiled and will be optimized out by the compiler on any type of expression.

Template Parameters
AEis the type of the vector_expression
Parameters
aeis a const reference to the vector_expression
Returns
a reference to the resulting vector

Referenced by boost::numeric::ublas::block_prod(), and boost::numeric::ublas::vector< T, bounded_array< T, N > >::operator=().

template<class T, class A>
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::assign_temporary ( vector< T, A > &  v)
inlineinherited

Assign a full vector (RHS-vector) to the current vector (LHS-vector)

Parameters
vis the source vector
Returns
a reference to a vector (i.e. the destination vector)

Referenced by boost::numeric::ublas::vector< T, bounded_array< T, N > >::operator+=(), boost::numeric::ublas::vector< T, bounded_array< T, N > >::operator-=(), and boost::numeric::ublas::vector< T, bounded_array< T, N > >::operator=().

template<class T, class A>
BOOST_UBLAS_INLINE iterator boost::numeric::ublas::vector< T, A >::begin ( void  )
inlineinherited

Return an iterator on the first element of the vector.

template<class T, class A>
BOOST_UBLAS_INLINE const_iterator boost::numeric::ublas::vector< T, A >::cbegin ( ) const
inlineinherited

return an iterator on the first element of the vector

template<class T, class A>
BOOST_UBLAS_INLINE const_iterator boost::numeric::ublas::vector< T, A >::cend ( ) const
inlineinherited

return an iterator after the last element of the vector

template<class T, class A>
BOOST_UBLAS_INLINE void boost::numeric::ublas::vector< T, A >::clear ( void  )
inlineinherited

Clear the vector, i.e. set all values to the zero value.

Referenced by boost::numeric::ublas::sparse_prod().

template<class T, class A>
BOOST_UBLAS_INLINE const_reverse_iterator boost::numeric::ublas::vector< T, A >::crbegin ( ) const
inlineinherited

Return a const reverse iterator before the first element of the reversed vector (i.e. end() of normal vector)

template<class T, class A>
BOOST_UBLAS_INLINE const_reverse_iterator boost::numeric::ublas::vector< T, A >::crend ( ) const
inlineinherited

Return a const reverse iterator on the end of the reverse vector (i.e. first element of the normal vector)

template<class T, class A>
BOOST_UBLAS_INLINE array_type& boost::numeric::ublas::vector< T, A >::data ( )
inlineinherited

Return a reference to the container. Useful to speed-up write operations to the data in very specific case.

template<class T, class A>
BOOST_UBLAS_INLINE bool boost::numeric::ublas::vector< T, A >::empty ( void  ) const
inlineinherited

Return true if the vector is empty (size==0)

Returns
true if empty, false otherwise
template<class T, class A>
BOOST_UBLAS_INLINE iterator boost::numeric::ublas::vector< T, A >::end ( void  )
inlineinherited

Return an iterator at the end of the vector.

template<class T, class A>
BOOST_UBLAS_INLINE void boost::numeric::ublas::vector< T, A >::erase_element ( size_type  i)
inlineinherited

Set element $i$ to the zero value.

Parameters
iindex of the element
template<class T, class A>
BOOST_UBLAS_INLINE const_iterator boost::numeric::ublas::vector< T, A >::find ( size_type  i) const
inlineinherited

Return a const iterator to the element i.

Parameters
iindex of the element

Referenced by boost::numeric::ublas::vector< T, bounded_array< T, N > >::begin(), and boost::numeric::ublas::vector< T, bounded_array< T, N > >::end().

template<class T, class A>
BOOST_UBLAS_INLINE iterator boost::numeric::ublas::vector< T, A >::find ( size_type  i)
inlineinherited

Return an iterator to the element i.

Parameters
iindex of the element
template<class T, class A>
BOOST_UBLAS_INLINE pointer boost::numeric::ublas::vector< T, A >::find_element ( size_type  i)
inlineinherited

Return a pointer to the element $i$.

Parameters
iindex of the element
template<class T, class A>
BOOST_UBLAS_INLINE const_pointer boost::numeric::ublas::vector< T, A >::find_element ( size_type  i) const
inlineinherited

Return a const pointer to the element $i$.

Parameters
iindex of the element
template<class T, class A>
BOOST_UBLAS_INLINE reference boost::numeric::ublas::vector< T, A >::insert_element ( size_type  i,
const_reference  t 
)
inlineinherited

Set element $i$ to the value t.

Parameters
iindex of the element
treference to the value to be set
template<class T, class A>
BOOST_UBLAS_INLINE size_type boost::numeric::ublas::vector< T, A >::max_size ( void  ) const
inlineinherited

Return the maximum size of the data container.

Return the upper bound (maximum size) on the data container. Depending on the container, it can be bigger than the current size of the vector.

template<class T, class A>
template<class AE >
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::minus_assign ( const vector_expression< AE > &  ae)
inlineinherited

Assign the difference of the vector and a vector_expression to the vector Assign the difference of the vector and a vector_expression to the vector.

This is lazy-compiled and will be optimized out by the compiler on any type of expression. No temporary is created. Computations are done and stored directly into the resulting vector.

Template Parameters
AEis the type of the vector_expression
Parameters
aeis a const reference to the vector_expression
Returns
a reference to the resulting vector

Referenced by boost::numeric::ublas::vector< T, bounded_array< T, N > >::operator-=().

template<class T, class A>
BOOST_UBLAS_INLINE const_reference boost::numeric::ublas::vector< T, A >::operator() ( size_type  i) const
inlineinherited

Return a const reference to the element $i$ Return a const reference to the element $i$.

With some compilers, this notation will be faster than [i]

Parameters
iindex of the element
template<class T, class A>
BOOST_UBLAS_INLINE reference boost::numeric::ublas::vector< T, A >::operator() ( size_type  i)
inlineinherited

Return a reference to the element $i$ Return a reference to the element $i$.

With some compilers, this notation will be faster than [i]

Parameters
iindex of the element
BOOST_UBLAS_INLINE const container_type& boost::numeric::ublas::vector_container< vector< T, A > >::operator() ( ) const
inlineinherited
BOOST_UBLAS_INLINE container_type& boost::numeric::ublas::vector_container< vector< T, A > >::operator() ( )
inlineinherited
template<class T, class A>
template<class AT >
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::operator*= ( const AT &  at)
inlineinherited

Assign the product of the vector and a scalar to the vector Assign the product of the vector and a scalar to the vector.

This is lazy-compiled and will be optimized out by the compiler on any type of expression. No temporary is created. Computations are done and stored directly into the resulting vector.

Template Parameters
AEis the type of the vector_expression
Parameters
atis a const reference to the scalar
Returns
a reference to the resulting vector
template<class T, class A>
template<class AE >
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::operator+= ( const vector_expression< AE > &  ae)
inlineinherited

Assign the sum of the vector and a vector_expression to the vector Assign the sum of the vector and a vector_expression to the vector.

This is lazy-compiled and will be optimized out by the compiler on any type of expression. A temporary is created for the computations.

Template Parameters
AEis the type of the vector_expression
Parameters
aeis a const reference to the vector_expression
Returns
a reference to the resulting vector
template<class T, class A>
template<class C >
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::operator+= ( const vector_container< C > &  v)
inlineinherited

Assign the sum of the vector and a vector_expression to the vector Assign the sum of the vector and a vector_expression to the vector.

This is lazy-compiled and will be optimized out by the compiler on any type of expression. No temporary is created. Computations are done and stored directly into the resulting vector.

Template Parameters
AEis the type of the vector_expression
Parameters
aeis a const reference to the vector_expression
Returns
a reference to the resulting vector
template<class T, class A>
template<class AE >
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::operator-= ( const vector_expression< AE > &  ae)
inlineinherited

Assign the difference of the vector and a vector_expression to the vector Assign the difference of the vector and a vector_expression to the vector.

This is lazy-compiled and will be optimized out by the compiler on any type of expression. A temporary is created for the computations.

Template Parameters
AEis the type of the vector_expression
Parameters
aeis a const reference to the vector_expression
template<class T, class A>
template<class C >
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::operator-= ( const vector_container< C > &  v)
inlineinherited

Assign the difference of the vector and a vector_expression to the vector Assign the difference of the vector and a vector_expression to the vector.

This is lazy-compiled and will be optimized out by the compiler on any type of expression. No temporary is created. Computations are done and stored directly into the resulting vector.

Template Parameters
AEis the type of the vector_expression
Parameters
aeis a const reference to the vector_expression
Returns
a reference to the resulting vector
template<class T, class A>
template<class AT >
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::operator/= ( const AT &  at)
inlineinherited

Assign the division of the vector by a scalar to the vector Assign the division of the vector by a scalar to the vector.

This is lazy-compiled and will be optimized out by the compiler on any type of expression. No temporary is created. Computations are done and stored directly into the resulting vector.

Template Parameters
AEis the type of the vector_expression
Parameters
atis a const reference to the scalar
Returns
a reference to the resulting vector
template<class T = std::size_t, class A = unbounded_array<T>>
BOOST_UBLAS_INLINE permutation_matrix& boost::numeric::ublas::permutation_matrix< T, A >::operator= ( const permutation_matrix< T, A > &  m)
inline
template<class T, class A>
BOOST_UBLAS_INLINE const_reference boost::numeric::ublas::vector< T, A >::operator[] ( size_type  i) const
inlineinherited

Return a const reference to the element $i$.

Parameters
iindex of the element
template<class T, class A>
BOOST_UBLAS_INLINE reference boost::numeric::ublas::vector< T, A >::operator[] ( size_type  i)
inlineinherited

Return a reference to the element $i$.

Parameters
iindex of the element
template<class T, class A>
template<class AE >
BOOST_UBLAS_INLINE vector& boost::numeric::ublas::vector< T, A >::plus_assign ( const vector_expression< AE > &  ae)
inlineinherited

Assign the sum of the vector and a vector_expression to the vector Assign the sum of the vector and a vector_expression to the vector.

This is lazy-compiled and will be optimized out by the compiler on any type of expression. No temporary is created. Computations are done and stored directly into the resulting vector.

Template Parameters
AEis the type of the vector_expression
Parameters
aeis a const reference to the vector_expression
Returns
a reference to the resulting vector

Referenced by boost::numeric::ublas::block_prod(), and boost::numeric::ublas::vector< T, bounded_array< T, N > >::operator+=().

template<class T, class A>
BOOST_UBLAS_INLINE const_reverse_iterator boost::numeric::ublas::vector< T, A >::rbegin ( ) const
inlineinherited

Return a const reverse iterator before the first element of the reversed vector (i.e. end() of normal vector)

Referenced by boost::numeric::ublas::vector< T, bounded_array< T, N > >::crbegin().

template<class T, class A>
BOOST_UBLAS_INLINE reverse_iterator boost::numeric::ublas::vector< T, A >::rbegin ( )
inlineinherited

Return a const reverse iterator before the first element of the reversed vector (i.e. end() of normal vector)

template<class T, class A>
BOOST_UBLAS_INLINE const_reverse_iterator boost::numeric::ublas::vector< T, A >::rend ( ) const
inlineinherited

Return a const reverse iterator on the end of the reverse vector (i.e. first element of the normal vector)

Referenced by boost::numeric::ublas::vector< T, bounded_array< T, N > >::crend().

template<class T, class A>
BOOST_UBLAS_INLINE reverse_iterator boost::numeric::ublas::vector< T, A >::rend ( )
inlineinherited

Return a const reverse iterator on the end of the reverse vector (i.e. first element of the normal vector)

template<class T, class A>
BOOST_UBLAS_INLINE void boost::numeric::ublas::vector< T, A >::resize ( size_type  size,
bool  preserve = true 
)
inlineinherited

Resize the vector Resize the vector to a new size.

If preserve is true, data are copied otherwise data are lost. If the new size is bigger, the remaining values are filled in with the initial value (0 by default) in the case of unbounded_array, which is the container by default. If the new size is smaller, last values are lost. This behaviour can be different if you explicitely specify another type of container.

Parameters
sizenew size of the vector
preserveif true, keep values

Referenced by boost::numeric::ublas::vector< T, bounded_array< T, N > >::operator=(), and boost::numeric::odeint::resize_impl< boost::numeric::ublas::vector< T_V, A_V >, boost::numeric::ublas::permutation_matrix< T, A > >::resize().

template<class T, class A>
template<class Archive >
void boost::numeric::ublas::vector< T, A >::serialize ( Archive &  ar,
const unsigned  int 
)
inlineinherited

Serialize a vector into and archive as defined in Boost.

Parameters
arArchive object. Can be a flat file, an XML file or any other stream
file_versionOptional file version (not yet used)
template<class T, class A>
BOOST_UBLAS_INLINE void boost::numeric::ublas::vector< T, A >::swap ( vector< T, A > &  v)
inlineinherited

Swap the content of the vector with another vector.

Parameters
vis the vector to be swapped with

Referenced by boost::numeric::ublas::vector< T, bounded_array< T, N > >::assign_temporary(), and boost::numeric::ublas::operator>>().

Member Data Documentation

const unsigned boost::numeric::ublas::vector_container< vector< T, A > >::complexity
staticinherited

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