Go to the source code of this file.
Functions | |
| int | pd4ifwt (const int &Sizef, const int &ns, const int &ks, const int &size, const double *wdata, double *sdata, double *ws) |
| int | pd4ifwt (const int &Sizef, const int &ns, const int &ks, const int &size, const float *wdata, float *sdata, float *ws) |
| int | pd4ifwt (const int &Sizef, const int &ns, const int &ks, const int &size, const double *wdata, double *sdata) |
| int | pd4ifwt (const int &Sizef, const int &ns, const int &ks, const int &size, const float *wdata, float *sdata) |
|
||||||||||||||||||||||||||||||||
|
Definition at line 188 of file pd4ifwt.cpp. References dpd4ifwtws_(), H0, H1, H2, H3, sdata(), size1, and wdata().
00196 {
00197
00198 #ifdef STORM_USEF
00199
00200 int iflag;
00201 dpd4ifwtws_( &Sizef, &ns, &ks, &size, wdata, sdata, ws, &iflag );
00202 return iflag;
00203
00204 #else
00205
00206 int i1;
00207 int size2;
00208 int size1 = ns;
00209
00210 #ifdef STORM_FWT_CCHECKUSAGE
00211 if ( size < ns ) return 1;
00212 #endif
00213
00214 if ( size == ns ) {
00215 for( int i = 0; i < size; i++ ) { sdata[i] = wdata[i]; }
00216 return 0;
00217 }
00218 for( int i = 0; i < size; i++ ) { ws[i] = wdata[i]; }
00219 while ( size1 < size ) {
00220 size2 = size1;
00221 size1 = 2 * size1;
00222 for( int i = 0; i < size2; i++ ) {
00223 i1 = (i-1+size2)%size2;
00224 sdata[2*i] = H0*ws[i] + H2*ws[i1]
00225 + H3*ws[size2+i] + H1*ws[size2+i1];
00226 sdata[2*i+1] = H1*ws[i] + H3*ws[i1]
00227 - H2*ws[size2+i] - H0*ws[size2+i1];
00228 }
00229 for( int i = 0; i < size1; i++ ) { ws[i] = sdata[i]; }
00230 }
00231
00232 #ifdef STORM_FWT_CCHECKUSAGE
00233 if ( size1 != size ) return 2;
00234 #endif
00235
00236 return 0;
00237
00238 #endif
00239
00240 }
|
|
||||||||||||||||||||||||||||||||
|
Definition at line 133 of file pd4ifwt.cpp. References H0, H1, H2, H3, pd4ifwtws_(), sdata(), size1, and wdata().
00141 {
00142
00143 #ifdef STORM_USEF
00144
00145 int iflag;
00146 pd4ifwtws_( &Sizef, &ns, &ks, &size, wdata, sdata, ws, &iflag );
00147 return iflag;
00148
00149 #else
00150
00151 int i1;
00152 int size2;
00153 int size1 = ns;
00154
00155 #ifdef STORM_FWT_CCHECKUSAGE
00156 if ( size < ns ) return 1;
00157 #endif
00158
00159 if ( size == ns ) {
00160 for( int i = 0; i < size; i++ ) { sdata[i] = wdata[i]; }
00161 return 0;
00162 }
00163 for( int i = 0; i < size; i++ ) { ws[i] = wdata[i]; }
00164 while ( size1 < size ) {
00165 size2 = size1;
00166 size1 = 2 * size1;
00167 for( int i = 0; i < size2; i++ ) {
00168 i1 = (i-1+size2)%size2;
00169 sdata[2*i] = H0*ws[i] + H2*ws[i1]
00170 + H3*ws[size2+i] + H1*ws[size2+i1];
00171 sdata[2*i+1] = H1*ws[i] + H3*ws[i1]
00172 - H2*ws[size2+i] - H0*ws[size2+i1];
00173 }
00174 for( int i = 0; i < size1; i++ ) { ws[i] = sdata[i]; }
00175 }
00176
00177 #ifdef STORM_FWT_CCHECKUSAGE
00178 if ( size1 != size ) return 2;
00179 #endif
00180
00181 return 0;
00182
00183 #endif
00184
00185 }
|
|
||||||||||||||||||||||||||||
|
Definition at line 77 of file pd4ifwt.cpp. References dpd4ifwt_(), H0, H1, H2, H3, sdata(), size1, and wdata().
00084 {
00085
00086 #ifdef STORM_USEF
00087
00088 int iflag;
00089 dpd4ifwt_( &Sizef, &ns, &ks, &size, wdata, sdata, &iflag );
00090 return iflag;
00091
00092 #else
00093
00094 int i1;
00095 int size2;
00096 int size1 = ns;
00097 double *xx = new double[Sizef];
00098
00099 #ifdef STORM_FWT_CCHECKUSAGE
00100 if ( size < ns ) return 1;
00101 #endif
00102
00103 if ( size == ns ) {
00104 for( int i = 0; i < size; i++ ) { sdata[i] = wdata[i]; }
00105 return 0;
00106 }
00107 for( int i = 0; i < size; i++ ) { xx[i] = wdata[i]; }
00108 while ( size1 < size ) {
00109 size2 = size1;
00110 size1 = 2 * size1;
00111 for( int i = 0; i < size2; i++ ) {
00112 i1 = (i-1+size2)%size2;
00113 sdata[2*i] = H0*xx[i] + H2*xx[i1]
00114 + H3*xx[size2+i] + H1*xx[size2+i1];
00115 sdata[2*i+1] = H1*xx[i] + H3*xx[i1]
00116 - H2*xx[size2+i] - H0*xx[size2+i1];
00117 }
00118 for( int i = 0; i < size1; i++ ) { xx[i] = sdata[i]; }
00119 }
00120 delete [] xx;
00121
00122 #ifdef STORM_FWT_CCHECKUSAGE
00123 if ( size1 != size ) return 2;
00124 #endif
00125
00126 return 0;
00127
00128 #endif
00129
00130 }
|
|
||||||||||||||||||||||||||||
|
Definition at line 20 of file pd4ifwt.cpp. References H0, H1, H2, H3, pd4ifwt_(), sdata(), size1, and wdata().
00027 {
00028
00029 #ifdef STORM_USEF
00030
00031 int iflag;
00032 pd4ifwt_( &Sizef, &ns, &ks, &size, wdata, sdata, &iflag );
00033 return iflag;
00034
00035 #else
00036
00037 int i1;
00038 int size2;
00039 int size1 = ns;
00040 float* xx = new float[Sizef];
00041
00042 #ifdef STORM_FWT_CCHECKUSAGE
00043 if ( size < ns ) return 1;
00044 #endif
00045
00046 if ( size == ns ) {
00047 for( int i = 0; i < size; i++ ) { sdata[i] = wdata[i]; }
00048 return 0;
00049 }
00050 for( int i = 0; i < size; i++ ) { xx[i] = wdata[i]; }
00051 while ( size1 < size ) {
00052 size2 = size1;
00053 size1 = 2 * size1;
00054 for( int i = 0; i < size2; i++ ) {
00055 i1 = (i-1+size2)%size2;
00056 sdata[2*i] = H0*xx[i] + H2*xx[i1]
00057 + H3*xx[size2+i] + H1*xx[size2+i1];
00058 sdata[2*i+1] = H1*xx[i] + H3*xx[i1]
00059 - H2*xx[size2+i] - H0*xx[size2+i1];
00060 }
00061 for( int i = 0; i < size1; i++ ) { xx[i] = sdata[i]; }
00062 }
00063 delete [] xx;
00064
00065 #ifdef STORM_FWT_CCHECKUSAGE
00066 if ( size1 != size ) return 2;
00067 #endif
00068
00069 return 0;
00070
00071 #endif
00072
00073 }
|
1.3.6