GNU Octave  4.2.1
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Public Member Functions | Public Attributes | Private Member Functions | List of all members
Sparse< T >::SparseRep Class Reference

#include "Sparse.h"

Collaboration diagram for Sparse< T >::SparseRep:
Collaboration graph
[legend]

Public Member Functions

 SparseRep (void)
 
 SparseRep (octave_idx_type n)
 
 SparseRep (octave_idx_type nr, octave_idx_type nc, octave_idx_type nz=0)
 
 SparseRep (const SparseRep &a)
 
 ~SparseRep (void)
 
bool any_element_is_nan (void) const
 
octave_idx_type ccidx (octave_idx_type i) const
 
cdata (octave_idx_type i) const
 
celem (octave_idx_type _r, octave_idx_type _c) const
 
void change_length (octave_idx_type nz)
 
octave_idx_typecidx (octave_idx_type i)
 
octave_idx_type cridx (octave_idx_type i) const
 
T & data (octave_idx_type i)
 
T & elem (octave_idx_type _r, octave_idx_type _c)
 
bool indices_ok (void) const
 
octave_idx_type length (void) const
 
void maybe_compress (bool remove_zeros)
 
octave_idx_type nnz (void) const
 
octave_idx_typeridx (octave_idx_type i)
 

Public Attributes

octave_idx_typec
 
octave_refcount< intcount
 
T * d
 
octave_idx_type ncols
 
octave_idx_type nrows
 
octave_idx_type nzmx
 
octave_idx_typer
 

Private Member Functions

SparseRepoperator= (const SparseRep &a)
 

Detailed Description

template<typename T>
class Sparse< T >::SparseRep

Definition at line 63 of file Sparse.h.

Constructor & Destructor Documentation

template<typename T>
Sparse< T >::SparseRep::SparseRep ( void  )
inline

Definition at line 75 of file Sparse.h.

template<typename T>
Sparse< T >::SparseRep::SparseRep ( octave_idx_type  n)
inline

Definition at line 82 of file Sparse.h.

template<typename T>
Sparse< T >::SparseRep::SparseRep ( octave_idx_type  nr,
octave_idx_type  nc,
octave_idx_type  nz = 0 
)
inline

Definition at line 90 of file Sparse.h.

template<typename T>
Sparse< T >::SparseRep::SparseRep ( const SparseRep a)
inline
template<typename T>
Sparse< T >::SparseRep::~SparseRep ( void  )
inline

Definition at line 111 of file Sparse.h.

References c, and d.

Member Function Documentation

template<typename T >
bool Sparse< T >::SparseRep::any_element_is_nan ( void  ) const

Definition at line 197 of file Sparse.cc.

References d, octave::math::isnan(), and Sparse< T >::nnz().

Referenced by Sparse< bool >::any_element_is_nan().

template<typename T>
octave_idx_type Sparse< T >::SparseRep::ccidx ( octave_idx_type  i) const
inline

Definition at line 131 of file Sparse.h.

Referenced by Sparse< bool >::cidx().

template<typename T>
T Sparse< T >::SparseRep::cdata ( octave_idx_type  i) const
inline

Definition at line 123 of file Sparse.h.

template<typename T >
T Sparse< T >::SparseRep::celem ( octave_idx_type  _r,
octave_idx_type  _c 
) const

Definition at line 124 of file Sparse.cc.

References c, and d.

Referenced by Sparse< bool >::xelem().

template<typename T >
void Sparse< T >::SparseRep::change_length ( octave_idx_type  nz)

Definition at line 159 of file Sparse.cc.

References c, d, and min().

Referenced by Sparse< bool >::change_capacity().

template<typename T>
octave_idx_type& Sparse< T >::SparseRep::cidx ( octave_idx_type  i)
inline

Definition at line 129 of file Sparse.h.

Referenced by Sparse< bool >::cidx(), and Sparse< bool >::xcidx().

template<typename T>
octave_idx_type Sparse< T >::SparseRep::cridx ( octave_idx_type  i) const
inline

Definition at line 127 of file Sparse.h.

Referenced by Sparse< bool >::ridx().

template<typename T>
T& Sparse< T >::SparseRep::data ( octave_idx_type  i)
inline

Definition at line 121 of file Sparse.h.

Referenced by Sparse< bool >::data(), and Sparse< bool >::xdata().

template<typename T >
T & Sparse< T >::SparseRep::elem ( octave_idx_type  _r,
octave_idx_type  _c 
)
template<typename T >
bool Sparse< T >::SparseRep::indices_ok ( void  ) const

Definition at line 190 of file Sparse.cc.

References c, Sparse< T >::nnz(), and sparse_indices_ok().

Referenced by Sparse< bool >::indices_ok().

template<typename T>
octave_idx_type Sparse< T >::SparseRep::length ( void  ) const
inline

Definition at line 113 of file Sparse.h.

Referenced by Sparse< bool >::nzmax().

template<typename T >
void Sparse< T >::SparseRep::maybe_compress ( bool  remove_zeros)

Definition at line 135 of file Sparse.cc.

References c, d, k, and u.

Referenced by Sparse< bool >::maybe_compress().

template<typename T>
octave_idx_type Sparse< T >::SparseRep::nnz ( void  ) const
inline

Definition at line 115 of file Sparse.h.

Referenced by Sparse< bool >::nnz(), and Sparse< T >::SparseRep::SparseRep().

template<typename T>
SparseRep& Sparse< T >::SparseRep::operator= ( const SparseRep a)
private
template<typename T>
octave_idx_type& Sparse< T >::SparseRep::ridx ( octave_idx_type  i)
inline

Definition at line 125 of file Sparse.h.

Referenced by Sparse< bool >::ridx(), and Sparse< bool >::xridx().

Member Data Documentation

template<typename T>
octave_idx_type* Sparse< T >::SparseRep::c
template<typename T>
octave_refcount<int> Sparse< T >::SparseRep::count

Definition at line 73 of file Sparse.h.

Referenced by Sparse< bool >::Sparse().

template<typename T>
T* Sparse< T >::SparseRep::d
template<typename T>
octave_idx_type Sparse< T >::SparseRep::ncols

Definition at line 72 of file Sparse.h.

Referenced by Sparse< T >::SparseRep::elem(), and Sparse< bool >::Sparse().

template<typename T>
octave_idx_type Sparse< T >::SparseRep::nrows

Definition at line 71 of file Sparse.h.

template<typename T>
octave_idx_type Sparse< T >::SparseRep::nzmx

Definition at line 70 of file Sparse.h.

Referenced by Sparse< T >::SparseRep::elem().

template<typename T>
octave_idx_type* Sparse< T >::SparseRep::r

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