Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members  

costwidth Class Reference

For a wavelet packet tree node, consisting of n integer values, calculate the minimal number of bits needed to represent the values. More...

#include <costwidth.h>

Inheritance diagram for costwidth::

costbase_int List of all members.

Public Methods

 costwidth (packnode< int > *root)

Protected Methods

int costCalc (packnode< int > *root)
 Cost function to be defined by the subclass. More...


Detailed Description

For a wavelet packet tree node, consisting of n integer values, calculate the minimal number of bits needed to represent the values.

This cost function is used for lossless wavelet packet compression.

Definition at line 48 of file costwidth.h.


Constructor & Destructor Documentation

costwidth::costwidth ( packnode< int > * root ) [inline]
 

Definition at line 53 of file costwidth.h.

00053 { traverse( root ); }


Member Function Documentation

int costwidth::costCalc ( packnode< int > * root ) [protected, virtual]
 

Cost function to be defined by the subclass.

Reimplemented from costbase_int.

Definition at line 39 of file costwidth.cpp.

00040 {
00041   assert( root != 0 );
00042 
00043   size_t N = root->length();
00044   const int *a = root->getData();
00045 
00046   int width = support::vecWidth( a, N );
00047 
00048   return width;
00049 } // costCalc


The documentation for this class was generated from the following files:
Generated at Tue May 27 21:56:17 2003 for Wavelet compression, determinism and time series forecasting by doxygen1.2.8.1 written by Dimitri van Heesch, © 1997-2001