|
template<typename VT , bool AF, bool TF> |
void | blaze::reset (SparseSubvector< VT, AF, TF > &sv) |
| Resetting the given sparse subvector. More...
|
|
template<typename VT , bool AF, bool TF> |
void | blaze::clear (SparseSubvector< VT, AF, TF > &sv) |
| Clearing the given sparse subvector. More...
|
|
template<typename VT , bool AF, bool TF> |
bool | blaze::isDefault (const SparseSubvector< VT, AF, TF > &sv) |
| Returns whether the given sparse subvector is in default state. More...
|
|
template<typename VT , bool AF, bool TF>
bool blaze::isDefault |
( |
const SparseSubvector< VT, AF, TF > & |
sv | ) |
|
|
inline |
Returns whether the given sparse subvector is in default state.
- Parameters
-
sv | The sparse subvector to be tested for its default state. |
- Returns
- true in case the given subvector is component-wise zero, false otherwise.
This function checks whether the sparse subvector is in default state. For instance, in case the subvector is instantiated for a vector of built-in integral or floating point data type, the function returns true in case all subvector elements are 0 and false in case any element is not 0. The following example demonstrates the use of the isDefault function: