|
Nektar++
|
#include <NekVector.hpp>
Public Types | |
| typedef DataType * | iterator |
| typedef const DataType * | const_iterator |
Public Member Functions | |
| NekVector () | |
| Creates an empty vector. More... | |
| NekVector (unsigned int size) | |
| Creates a vector of given size. The elements are not initialized. More... | |
| NekVector (unsigned int size, typename boost::call_traits< DataType >::const_reference a) | |
| Creates a vector with given size and initial value. More... | |
| NekVector (const std::string &vectorValues) | |
| NekVector (typename boost::call_traits< DataType >::const_reference x, typename boost::call_traits< DataType >::const_reference y, typename boost::call_traits< DataType >::const_reference z) | |
| NekVector (const NekVector< DataType > &rhs) | |
| NekVector (unsigned int size, const DataType *const ptr) | |
| NekVector (const Array< OneD, DataType > &ptr, PointerWrapper h=eCopy) | |
| NekVector (unsigned int size, Array< OneD, DataType > &ptr, PointerWrapper h=eCopy) | |
| NekVector (unsigned int size, const Array< OneD, const DataType > &ptr, PointerWrapper h=eCopy) | |
| ~NekVector () | |
| NekVector< DataType > & | operator= (const NekVector< DataType > &rhs) |
| unsigned int | GetDimension () const |
| Returns the number of dimensions for the point. More... | |
| unsigned int | GetRows () const |
| DataType * | GetRawPtr () |
| Array< OneD, DataType > & | GetPtr () |
| const DataType * | GetRawPtr () const |
| const Array< OneD, const DataType > & | GetPtr () const |
| iterator | begin () |
| iterator | end () |
| const_iterator | begin () const |
| const_iterator | end () const |
| boost::call_traits< DataType >::reference | operator() (unsigned int i) |
| Returns i^{th} element. More... | |
| boost::call_traits< DataType >::reference | operator[] (unsigned int i) |
| boost::call_traits< DataType >::reference | x () |
| boost::call_traits< DataType >::reference | y () |
| boost::call_traits< DataType >::reference | z () |
| void | SetX (typename boost::call_traits< DataType >::const_reference val) |
| void | SetY (typename boost::call_traits< DataType >::const_reference val) |
| void | SetZ (typename boost::call_traits< DataType >::const_reference val) |
| NekVector< DataType > & | operator+= (const NekVector< DataType > &rhs) |
| NekVector< DataType > & | operator-= (const NekVector< DataType > &rhs) |
| NekVector< DataType > & | operator*= (typename boost::call_traits< DataType >::const_reference rhs) |
| NekVector< DataType > & | operator/= (typename boost::call_traits< DataType >::const_reference rhs) |
| void | Normalize () |
| boost::call_traits< DataType >::const_reference | operator() (unsigned int i) const |
| boost::call_traits< DataType >::const_reference | operator[] (unsigned int i) const |
| boost::call_traits< DataType >::const_reference | x () const |
| boost::call_traits< DataType >::const_reference | y () const |
| boost::call_traits< DataType >::const_reference | z () const |
| NekVector< DataType > | operator- () const |
| DataType | Magnitude () const |
| DataType | Dot (const NekVector< DataType > &rhs) const |
| NekVector< DataType > | Cross (const NekVector< DataType > &rhs) const |
| std::string | AsString () const |
| DataType | L1Norm () const |
| DataType | L2Norm () const |
| DataType | InfinityNorm () const |
| PointerWrapper | GetWrapperType () const |
Protected Member Functions | |
| Array< OneD, DataType > & | GetData () |
| void | SetSize (unsigned int s) |
| void | SetWrapperType (PointerWrapper p) |
| void | SetData (const Array< OneD, DataType > &newData) |
| void | Resize (unsigned int newSize) |
Private Member Functions | |
| NekVector (const Array< OneD, const DataType > &ptr, PointerWrapper h) | |
Private Attributes | |
| unsigned int | m_size |
| Array< OneD, DataType > | m_data |
| PointerWrapper | m_wrapperType |
Definition at line 56 of file NekVector.hpp.
| typedef const DataType* Nektar::NekVector< DataType >::const_iterator |
Definition at line 105 of file NekVector.hpp.
| typedef DataType* Nektar::NekVector< DataType >::iterator |
Definition at line 101 of file NekVector.hpp.
| Nektar::NekVector< DataType >::NekVector | ( | ) |
Creates an empty vector.
Definition at line 41 of file NekVector.cpp.
|
explicit |
Creates a vector of given size. The elements are not initialized.
Definition at line 49 of file NekVector.cpp.
| Nektar::NekVector< DataType >::NekVector | ( | unsigned int | size, |
| typename boost::call_traits< DataType >::const_reference | a | ||
| ) |
Creates a vector with given size and initial value.
Definition at line 57 of file NekVector.cpp.
|
explicit |
Definition at line 66 of file NekVector.cpp.
| Nektar::NekVector< DataType >::NekVector | ( | typename boost::call_traits< DataType >::const_reference | x, |
| typename boost::call_traits< DataType >::const_reference | y, | ||
| typename boost::call_traits< DataType >::const_reference | z | ||
| ) |
Definition at line 87 of file NekVector.cpp.
| Nektar::NekVector< DataType >::NekVector | ( | const NekVector< DataType > & | rhs | ) |
Definition at line 100 of file NekVector.cpp.
| Nektar::NekVector< DataType >::NekVector | ( | unsigned int | size, |
| const DataType *const | ptr | ||
| ) |
Definition at line 113 of file NekVector.cpp.
|
explicit |
Definition at line 121 of file NekVector.cpp.
| Nektar::NekVector< DataType >::NekVector | ( | unsigned int | size, |
| Array< OneD, DataType > & | ptr, | ||
| PointerWrapper | h = eCopy |
||
| ) |
Definition at line 134 of file NekVector.cpp.
| Nektar::NekVector< DataType >::NekVector | ( | unsigned int | size, |
| const Array< OneD, const DataType > & | ptr, | ||
| PointerWrapper | h = eCopy |
||
| ) |
Definition at line 164 of file NekVector.cpp.
| Nektar::NekVector< DataType >::~NekVector | ( | ) |
Definition at line 181 of file NekVector.cpp.
|
private |
Definition at line 151 of file NekVector.cpp.
| std::string Nektar::NekVector< DataType >::AsString | ( | ) | const |
Definition at line 388 of file NekVector.cpp.
Referenced by Nektar::operator-(), and Nektar::operator<<().
| NekVector< DataType >::iterator Nektar::NekVector< DataType >::begin | ( | ) |
Definition at line 239 of file NekVector.cpp.
Referenced by Nektar::DiagonalBlockFullScalMatrixMultiply(), Nektar::DiagonalBlockMatrixMultiply(), Nektar::L1Norm(), Nektar::L2Norm(), Nektar::NekVector< NekDouble >::NekVector(), Nektar::NekVector< NekDouble >::operator=(), and Nektar::operator==().
| NekVector< DataType >::const_iterator Nektar::NekVector< DataType >::begin | ( | ) | const |
Definition at line 245 of file NekVector.cpp.
| NekVector< DataType > Nektar::NekVector< DataType >::Cross | ( | const NekVector< DataType > & | rhs | ) | const |
Definition at line 382 of file NekVector.cpp.
Referenced by Nektar::operator-().
| DataType Nektar::NekVector< DataType >::Dot | ( | const NekVector< DataType > & | rhs | ) | const |
Definition at line 379 of file NekVector.cpp.
Referenced by Nektar::operator-().
| NekVector< DataType >::iterator Nektar::NekVector< DataType >::end | ( | ) |
Definition at line 242 of file NekVector.cpp.
Referenced by Nektar::DiagonalBlockFullScalMatrixMultiply(), Nektar::DiagonalBlockMatrixMultiply(), Nektar::L1Norm(), Nektar::L2Norm(), Nektar::NekVector< NekDouble >::NekVector(), Nektar::NekVector< NekDouble >::operator=(), and Nektar::operator==().
| NekVector< DataType >::const_iterator Nektar::NekVector< DataType >::end | ( | ) | const |
Definition at line 248 of file NekVector.cpp.
|
protected |
Definition at line 404 of file NekVector.cpp.
| unsigned int Nektar::NekVector< DataType >::GetDimension | ( | ) | const |
Returns the number of dimensions for the point.
Definition at line 209 of file NekVector.cpp.
Referenced by Nektar::Add(), Nektar::AddEqual(), Nektar::AddEqualNegatedLhs(), Nektar::AddNegatedLhs(), Nektar::AsString(), Nektar::Cross(), Nektar::Divide(), Nektar::DivideEqual(), Nektar::Dot(), Nektar::FullBlockMatrixMultiply(), Nektar::InfinityNorm(), Nektar::Magnitude(), Nektar::Multiply(), Nektar::MultiplyEqual(), Nektar::MultiplyInvertedLhs(), Nektar::Negate(), Nektar::NegateInPlace(), Nektar::NekVector< NekDouble >::operator=(), Nektar::operator==(), Nektar::MultiRegions::GlobalLinSysIterative::Set_Rhs_Magnitude(), Nektar::Subtract(), Nektar::SubtractEqual(), Nektar::SubtractEqualNegatedLhs(), and Nektar::SubtractNegatedLhs().
| Array< OneD, DataType > & Nektar::NekVector< DataType >::GetPtr | ( | ) |
Definition at line 227 of file NekVector.cpp.
Referenced by Nektar::MultiRegions::AssemblyMap::AssembleBnd(), Nektar::LibUtilities::NodalTriElec::CalculateWeights(), Nektar::LibUtilities::NodalPrismElec::CalculateWeights(), Nektar::LibUtilities::NodalTetElec::CalculateWeights(), Nektar::LibUtilities::NodalTriEvenlySpaced::CalculateWeights(), Nektar::LibUtilities::NodalTriFekete::CalculateWeights(), Nektar::LibUtilities::NodalPrismEvenlySpaced::CalculateWeights(), Nektar::LibUtilities::NodalTetEvenlySpaced::CalculateWeights(), Nektar::MultiRegions::DisContField3D::EvaluateHDGPostProcessing(), Nektar::MultiRegions::DisContField2D::EvaluateHDGPostProcessing(), Nektar::MultiRegions::AssemblyMap::GlobalToLocalBnd(), Nektar::MultiRegions::AssemblyMap::LocalBndToGlobal(), Nektar::MultiRegions::AssemblyMap::UniversalAssembleBnd(), Nektar::MultiRegions::AssemblyMapCG::v_Assemble(), Nektar::MultiRegions::GlobalLinSysPETScStaticCond::v_DoMatrixMultiply(), Nektar::SpatialDomains::SegGeom::v_FillGeom(), Nektar::MultiRegions::AssemblyMapCG::v_GlobalToLocal(), Nektar::MultiRegions::AssemblyMapCG::v_LocalToGlobal(), Nektar::MultiRegions::GlobalLinSysStaticCond::v_Solve(), Nektar::MultiRegions::AssemblyMapDG::v_UniversalAssemble(), and Nektar::MultiRegions::AssemblyMapCG::v_UniversalAssemble().
| const Array< OneD, const DataType > & Nektar::NekVector< DataType >::GetPtr | ( | ) | const |
Definition at line 236 of file NekVector.cpp.
| DataType * Nektar::NekVector< DataType >::GetRawPtr | ( | ) |
Definition at line 221 of file NekVector.cpp.
Referenced by Nektar::Add(), Nektar::AddEqual(), Nektar::AddEqualNegatedLhs(), Nektar::AddNegatedLhs(), Nektar::DiagonalBlockFullScalMatrixMultiply(), Nektar::DiagonalBlockMatrixMultiply(), Nektar::Divide(), Nektar::DivideEqual(), Nektar::FullBlockMatrixMultiply(), Nektar::Multiply(), Nektar::MultiplyEqual(), Nektar::MultiplyInvertedLhs(), Nektar::NegateInPlace(), Nektar::Subtract(), Nektar::SubtractEqual(), Nektar::SubtractEqualNegatedLhs(), and Nektar::SubtractNegatedLhs().
| const DataType * Nektar::NekVector< DataType >::GetRawPtr | ( | ) | const |
Definition at line 230 of file NekVector.cpp.
| unsigned int Nektar::NekVector< DataType >::GetRows | ( | ) | const |
Definition at line 215 of file NekVector.cpp.
Referenced by Nektar::AsString(), Nektar::LibUtilities::NodalPrismElec::CalculateWeights(), Nektar::LibUtilities::NodalTriElec::CalculateWeights(), Nektar::LibUtilities::NodalTriFekete::CalculateWeights(), Nektar::LibUtilities::NodalTriEvenlySpaced::CalculateWeights(), Nektar::LibUtilities::NodalTetElec::CalculateWeights(), Nektar::LibUtilities::NodalPrismEvenlySpaced::CalculateWeights(), Nektar::LibUtilities::NodalTetEvenlySpaced::CalculateWeights(), Nektar::DiagonalBlockFullScalMatrixMultiply(), Nektar::DiagonalBlockMatrixMultiply(), and Nektar::Multiply().
| PointerWrapper Nektar::NekVector< DataType >::GetWrapperType | ( | ) | const |
Definition at line 401 of file NekVector.cpp.
| DataType Nektar::NekVector< DataType >::InfinityNorm | ( | ) | const |
Definition at line 398 of file NekVector.cpp.
Referenced by Nektar::operator-().
| DataType Nektar::NekVector< DataType >::L1Norm | ( | ) | const |
| DataType Nektar::NekVector< DataType >::L2Norm | ( | ) | const |
| DataType Nektar::NekVector< DataType >::Magnitude | ( | ) | const |
Definition at line 376 of file NekVector.cpp.
Referenced by Nektar::Normalize(), and Nektar::operator-().
| void Nektar::NekVector< DataType >::Normalize | ( | ) |
| boost::call_traits< DataType >::reference Nektar::NekVector< DataType >::operator() | ( | unsigned int | i | ) |
Returns i^{th} element.
| i | The element to return. |
Retrieves the i^{th} element. Since it returns a reference you may assign a new value (i.e., p(2) = 3.2;)
This operator performs range checking.
Definition at line 251 of file NekVector.cpp.
| boost::call_traits< DataType >::const_reference Nektar::NekVector< DataType >::operator() | ( | unsigned int | i | ) | const |
Definition at line 338 of file NekVector.cpp.
| NekVector< DataType > & Nektar::NekVector< DataType >::operator*= | ( | typename boost::call_traits< DataType >::const_reference | rhs | ) |
Definition at line 321 of file NekVector.cpp.
| NekVector< DataType > & Nektar::NekVector< DataType >::operator+= | ( | const NekVector< DataType > & | rhs | ) |
Definition at line 307 of file NekVector.cpp.
| NekVector< DataType > Nektar::NekVector< DataType >::operator- | ( | ) | const |
Definition at line 373 of file NekVector.cpp.
| NekVector< DataType > & Nektar::NekVector< DataType >::operator-= | ( | const NekVector< DataType > & | rhs | ) |
Definition at line 314 of file NekVector.cpp.
| NekVector< DataType > & Nektar::NekVector< DataType >::operator/= | ( | typename boost::call_traits< DataType >::const_reference | rhs | ) |
Definition at line 328 of file NekVector.cpp.
| NekVector< DataType > & Nektar::NekVector< DataType >::operator= | ( | const NekVector< DataType > & | rhs | ) |
Definition at line 184 of file NekVector.cpp.
| boost::call_traits< DataType >::reference Nektar::NekVector< DataType >::operator[] | ( | unsigned int | i | ) |
Definition at line 259 of file NekVector.cpp.
| boost::call_traits< DataType >::const_reference Nektar::NekVector< DataType >::operator[] | ( | unsigned int | i | ) | const |
Definition at line 346 of file NekVector.cpp.
|
protected |
Definition at line 416 of file NekVector.cpp.
|
protected |
Definition at line 413 of file NekVector.cpp.
|
protected |
Definition at line 407 of file NekVector.cpp.
|
protected |
Definition at line 410 of file NekVector.cpp.
| void Nektar::NekVector< DataType >::SetX | ( | typename boost::call_traits< DataType >::const_reference | val | ) |
Definition at line 286 of file NekVector.cpp.
| void Nektar::NekVector< DataType >::SetY | ( | typename boost::call_traits< DataType >::const_reference | val | ) |
Definition at line 293 of file NekVector.cpp.
| void Nektar::NekVector< DataType >::SetZ | ( | typename boost::call_traits< DataType >::const_reference | val | ) |
Definition at line 300 of file NekVector.cpp.
| boost::call_traits< DataType >::reference Nektar::NekVector< DataType >::x | ( | ) |
Definition at line 265 of file NekVector.cpp.
Referenced by Nektar::Cross().
| boost::call_traits< DataType >::const_reference Nektar::NekVector< DataType >::x | ( | ) | const |
Definition at line 352 of file NekVector.cpp.
| boost::call_traits< DataType >::reference Nektar::NekVector< DataType >::y | ( | ) |
Definition at line 272 of file NekVector.cpp.
Referenced by Nektar::Cross().
| boost::call_traits< DataType >::const_reference Nektar::NekVector< DataType >::y | ( | ) | const |
Definition at line 359 of file NekVector.cpp.
| boost::call_traits< DataType >::reference Nektar::NekVector< DataType >::z | ( | ) |
Definition at line 279 of file NekVector.cpp.
Referenced by Nektar::Cross().
| boost::call_traits< DataType >::const_reference Nektar::NekVector< DataType >::z | ( | ) | const |
Definition at line 366 of file NekVector.cpp.
|
private |
Definition at line 184 of file NekVector.hpp.
|
private |
Definition at line 183 of file NekVector.hpp.
|
private |
Definition at line 185 of file NekVector.hpp.
1.8.13