52 template<
typename Tmatrix,
typename Treal>
60 Treal const threshold ) = 0;
64 Treal const threshold ) = 0;
69 template<
typename Tmatrix,
typename Treal>
79 template<
typename Tmatrix,
typename Treal>
81 assert(threshold >= (
Treal)0.0);
82 if (threshold == (
Treal)0.0)
110 while (
euclEInt.upp() > threshold ) {
139 frobThreshLowLevel( (
Treal)0.0 );
153 template<
typename Tmatrix,
typename Treal>
160 Treal const threshold );
164 Treal const threshold );
167 template<
typename Tmatrix,
typename Treal>
169 Treal const threshold ) {
171 lowTrunc = (threshold * threshold) / 2;
172 highTrunc = (threshold * threshold * this->
A.get_nrows()) / 2;
175 template<
typename Tmatrix,
typename Treal>
177 this->
A.getMatrix().getFrobSqLowestLevel(frobsq_norms);
180 template<
typename Tmatrix,
typename Treal>
182 this->
A.getMatrix().frobThreshLowestLevel( threshold, &this->E.getMatrix() );
185 template<
typename Tmatrix,
typename Treal>
187 Treal const threshold ) {
202 template<
typename Tmatrix,
typename TmatrixZ,
typename Treal>
209 Treal const threshold );
213 Treal const threshold );
217 template<
typename Tmatrix,
typename TmatrixZ,
typename Treal>
219 Treal const threshold ) {
227 template<
typename Tmatrix,
typename TmatrixZ,
typename Treal>
229 Treal const threshold ) {
245 template<
typename Tmatrix,
typename Treal>
257 template<
typename Tmatrix,
typename Treal>
259 this->
A.getMatrix().getFrobSqElementLevel(frobsq_norms);
262 template<
typename Tmatrix,
typename Treal>
264 this->
A.getMatrix().frobThreshElementLevel(threshold, &this->E.getMatrix() );
271 template<
typename Tmatrix,
typename Treal>
278 Treal const threshold );
282 Treal const threshold );
285 template<
typename Tmatrix,
typename Treal>
287 Treal const threshold ) {
298 highTrunc = (threshold * threshold * this->
A.get_nrows());
301 template<
typename Tmatrix,
typename Treal>
303 this->
A.getMatrix().getFrobSqLowestLevel(frobsq_norms);
306 template<
typename Tmatrix,
typename Treal>
308 this->
A.getMatrix().frobThreshLowestLevel( threshold, &this->E.getMatrix() );
311 template<
typename Tmatrix,
typename Treal>
313 Treal const threshold ) {
337 template<
typename Tmatrix,
typename TmatrixB,
typename Treal>
344 Treal const threshold );
348 Treal const threshold );
352 template<
typename Tmatrix,
typename TmatrixB,
typename Treal>
355 Treal const threshold ) {
363 template<
typename Tmatrix,
typename TmatrixB,
typename Treal>
365 Treal const threshold ) {
Definition truncation.h:53
Treal run(Treal const threshold)
Definition truncation.h:80
virtual Interval< Treal > euclIfSmall(Treal const absTol, Treal const threshold)=0
virtual ~EuclTruncationBase()
Definition truncation.h:57
Tmatrix E
Definition truncation.h:66
virtual void getFrobTruncBounds(Treal &lowTrunc, Treal &highTrunc, Treal const threshold)=0
virtual void frobThreshLowLevel(Treal const threshold)=0
EuclTruncationBase(Tmatrix &A_)
Definition truncation.h:70
virtual void getFrobSqNorms(std::vector< Treal > &frobsq_norms)=0
Tmatrix & A
Definition truncation.h:65
Truncation of general matrices with impact on matrix triple multiply as error measure.
Definition truncation.h:338
EuclTruncationCongrTransMeasure(Tmatrix &A_, TmatrixB const &B_)
Definition truncation.h:340
virtual void getFrobTruncBounds(Treal &lowTrunc, Treal &highTrunc, Treal const threshold)
Definition truncation.h:353
virtual Interval< Treal > euclIfSmall(Treal const absTol, Treal const threshold)
Definition truncation.h:364
TmatrixB const & B
Definition truncation.h:349
Truncation of general matrices.
Definition truncation.h:272
virtual void frobThreshLowLevel(Treal const threshold)
Definition truncation.h:307
virtual void getFrobTruncBounds(Treal &lowTrunc, Treal &highTrunc, Treal const threshold)
Definition truncation.h:286
virtual void getFrobSqNorms(std::vector< Treal > &frobsq_norms)
Definition truncation.h:302
EuclTruncationGeneral(Tmatrix &A_)
Definition truncation.h:274
virtual Interval< Treal > euclIfSmall(Treal const absTol, Treal const threshold)
Definition truncation.h:312
Truncation of symmetric matrices at the element level (used for mixed norm truncation)
Definition truncation.h:246
EuclTruncationSymmElementLevel(Tmatrix &A_)
Definition truncation.h:248
virtual void frobThreshLowLevel(Treal const threshold)
Definition truncation.h:263
virtual void getFrobSqNorms(std::vector< Treal > &frobsq_norms)
Definition truncation.h:258
Truncation of symmetric matrices with Z.
Definition truncation.h:203
TmatrixZ const & Z
Definition truncation.h:214
virtual Interval< Treal > euclIfSmall(Treal const absTol, Treal const threshold)
Definition truncation.h:228
EuclTruncationSymmWithZ(Tmatrix &A_, TmatrixZ const &Z_)
Definition truncation.h:205
virtual void getFrobTruncBounds(Treal &lowTrunc, Treal &highTrunc, Treal const threshold)
Definition truncation.h:218
Truncation of symmetric matrices.
Definition truncation.h:154
virtual void frobThreshLowLevel(Treal const threshold)
Definition truncation.h:181
EuclTruncationSymm(Tmatrix &A_)
Definition truncation.h:156
virtual void getFrobTruncBounds(Treal &lowTrunc, Treal &highTrunc, Treal const threshold)
Definition truncation.h:168
virtual void getFrobSqNorms(std::vector< Treal > &frobsq_norms)
Definition truncation.h:176
virtual Interval< Treal > euclIfSmall(Treal const absTol, Treal const threshold)
Definition truncation.h:186
Describes dimensions of matrix and its blocks on all levels.
Definition SizesAndBlocks.h:45
mat::SizesAndBlocks rows
Definition test.cc:51
mat::SizesAndBlocks cols
Definition test.cc:52
Definition allocate.cc:39
static Treal getMachineEpsilon()
Definition matInclude.h:147
Interval< Treal > euclIfSmall(Tmatrix const &M, Treal const requestedAbsAccuracy, Treal const requestedRelAccuracy, Treal const maxAbsVal, typename Tmatrix::VectorType *const eVecPtr=0, int maxIter=-1)
Returns interval containing the Euclidean norm of the matrix M.
Definition LanczosLargestMagnitudeEig.h:260
Definition mat_utils.h:95
Definition mat_utils.h:154
Definition mat_utils.h:123
Treal template_blas_sqrt(Treal x)