OpenVDB 12.0.0
 
Loading...
Searching...
No Matches
Vector< T >::IsFiniteOp Struct Reference

#include <openvdb/math/ConjGradient.h>

Public Types

using ValueType
 
using Ptr
 

Public Member Functions

 IsFiniteOp (const T *data_)
 
bool operator() (const SizeRange &range, bool finite) const
 
 Vector ()
 Construct an empty vector.
 
 Vector (SizeType n)
 Construct a vector of n elements, with uninitialized values.
 
 Vector (SizeType n, const ValueType &val)
 Construct a vector of n elements and initialize each element to the given value.
 
 Vector (const Vector &)
 Deep copy the given vector.
 
 ~Vector ()
 
Vectoroperator= (const Vector &)
 Deep copy the given vector.
 
SizeType size () const
 Return the number of elements in this vector.
 
bool empty () const
 Return true if this vector has no elements.
 
void resize (SizeType n)
 Reset this vector to have n elements, with uninitialized values.
 
void swap (Vector &other)
 Swap internal storage with another vector, which need not be the same size.
 
void fill (const ValueType &value)
 Set all elements of this vector to value.
 
void scale (const Scalar &s)
 Multiply each element of this vector by s.
 
Vectoroperator*= (const Scalar &s)
 
ValueType dot (const Vector &) const
 Return the dot product of this vector with the given vector, which must be the same size.
 
ValueType infNorm () const
 Return the infinity norm of this vector.
 
ValueType l2Norm () const
 Return the L2 norm of this vector.
 
bool isFinite () const
 Return true if every element of this vector has a finite value.
 
bool eq (const Vector< OtherValueType > &other, ValueType eps=Tolerance< ValueType >::value()) const
 Return true if this vector is equivalent to the given vector to within the specified tolerance.
 
std::string str () const
 Return a string representation of this vector.
 
T & at (SizeType i)
 Return the value of this vector's ith element.
 
const T & at (SizeType i) const
 
T & operator[] (SizeType i)
 
const T & operator[] (SizeType i) const
 
T * data ()
 Return a pointer to this vector's elements.
 
const T * data () const
 
const T * constData () const
 

Public Attributes

const T * data
 

Member Typedef Documentation

◆ Ptr

using Ptr

◆ ValueType

using ValueType

Constructor & Destructor Documentation

◆ IsFiniteOp()

template<typename T>
IsFiniteOp ( const T * data_)
inline

◆ ~Vector()

~Vector ( )
inline

Member Function Documentation

◆ at() [1/2]

T & at ( SizeType i)
inline

Return the value of this vector's ith element.

◆ at() [2/2]

const T & at ( SizeType i) const
inline

◆ constData()

const T * constData ( ) const
inline

◆ data() [1/2]

T * data ( )
inline

Return a pointer to this vector's elements.

◆ data() [2/2]

const T * data ( ) const
inline

◆ dot()

T dot ( const Vector & ) const
inline

Return the dot product of this vector with the given vector, which must be the same size.

◆ empty()

bool empty ( ) const
inline

Return true if this vector has no elements.

◆ eq()

bool eq ( const Vector< OtherValueType > & other,
ValueType eps = Tolerance<ValueType>::value() ) const
inline

Return true if this vector is equivalent to the given vector to within the specified tolerance.

◆ fill()

void fill ( const ValueType & value)
inline

Set all elements of this vector to value.

◆ infNorm()

T infNorm ( ) const
inline

Return the infinity norm of this vector.

◆ isFinite()

bool isFinite ( ) const
inline

Return true if every element of this vector has a finite value.

◆ l2Norm()

ValueType l2Norm ( ) const
inline

Return the L2 norm of this vector.

◆ operator()()

template<typename T>
bool operator() ( const SizeRange & range,
bool finite ) const
inline

◆ operator*=()

Vector & operator*= ( const Scalar & s)
inline

◆ operator=()

Vector< T > & operator= ( const Vector & )
inline

Deep copy the given vector.

◆ operator[]() [1/2]

T & operator[] ( SizeType i)
inline

◆ operator[]() [2/2]

const T & operator[] ( SizeType i) const
inline

◆ resize()

void resize ( SizeType n)
inline

Reset this vector to have n elements, with uninitialized values.

Warning
All of this vector's existing values will be lost.

◆ scale()

void scale ( const Scalar & s)
inline

Multiply each element of this vector by s.

◆ size()

SizeType size ( ) const
inline

Return the number of elements in this vector.

◆ str()

std::string str ( ) const
inline

Return a string representation of this vector.

◆ swap()

void swap ( Vector & other)
inline

Swap internal storage with another vector, which need not be the same size.

◆ Vector() [1/4]

Vector ( )
inline

Construct an empty vector.

◆ Vector() [2/4]

Vector ( const Vector & other)
inline

Deep copy the given vector.

◆ Vector() [3/4]

Vector ( SizeType n)
inline

Construct a vector of n elements, with uninitialized values.

◆ Vector() [4/4]

Vector ( SizeType n,
const ValueType & val )
inline

Construct a vector of n elements and initialize each element to the given value.

Member Data Documentation

◆ data

template<typename T>
const T* data