LibreOffice Module sc (master)  1
Public Member Functions | Public Attributes | List of all members
ScMatrix::IterateResultMultiple< tRes > Struct Template Reference

When adding all numerical matrix elements for a scalar result such as summation, the interpreter wants to separate the first non-zero value with the rest of the summed values. More...

#include <scmatrix.hxx>

Public Member Functions

 IterateResultMultiple (size_t nCount)
 

Public Attributes

std::vector< tRes > maAccumulator
 
size_t mnCount
 

Detailed Description

template<typename tRes>
struct ScMatrix::IterateResultMultiple< tRes >

When adding all numerical matrix elements for a scalar result such as summation, the interpreter wants to separate the first non-zero value with the rest of the summed values.

This is necessary for better numerical stability, unless we sort all by absolute values before summing (not really an option) or use another algorithm, e.g. Kahan's summation algorithm, https://en.wikipedia.org/wiki/Kahan_summation_algorithm

Definition at line 144 of file scmatrix.hxx.

Constructor & Destructor Documentation

template<typename tRes>
ScMatrix::IterateResultMultiple< tRes >::IterateResultMultiple ( size_t  nCount)
inline

Definition at line 149 of file scmatrix.hxx.

Member Data Documentation

template<typename tRes>
std::vector<tRes> ScMatrix::IterateResultMultiple< tRes >::maAccumulator

Definition at line 146 of file scmatrix.hxx.

template<typename tRes>
size_t ScMatrix::IterateResultMultiple< tRes >::mnCount

Definition at line 147 of file scmatrix.hxx.


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