Next: iridgelet Up: Reference Previous: precond2d   Contents   Index

#### sconvolve

Name

sconvolve Convolves a signal with a filter

Command Synopsis

sconvolve [-d Decimation] [-i Interpolation] [-r] [-e Edgemode] [-b] [-p EdgeProl] Signal FicConvol ImpulseResponse [EdgeIR ]

-d Decimation : Downsampling rate (default 1)

-i Interpolation : Upsampling rate (default 1)

-r : Convolution with symetric filter

-e Edgemode : Edge processing mode (0/1/2/3, default 0)

-b : Convolution with high pass filter

-p EdgeProl : Extension of output on edges (0/1/2, default 0)

Signal : Input signal (fsignal)

FicConvol : Result of convolution (fsignal)

ImpulseResponse : Impulse response of inner filter (fsignal)

EdgeIR : Impulse reponses of edge and preconditionning filters (fimage)

Function Summary

void sconvolve (Signal , Output , DownRate , UpRate , ReflIR , Band , Edge , Prolong , Ri , Edge_Ri )

Fsignal Signal ;

Fsignal Output ;

int *DownRate ;

int *UpRate ;

int *ReflIR ;

int *Edge ;

int *Band ;

int *Prolong ;

Fsignal Ri ;

Fimage Edge_Ri ;

Description

sconvolve computes the convolution of a fsignal with a discrete filter which is also of fsignal type. The signal can eventually be interpolated or over-sampled (adding M - 1 zero-valued samples betwen each successive samples) before the convolution, and the result can eventually be decimated or sub-sampled (discarding N - 1 samples over N).

Let {xk} and {yk} be the sample values of the input and output signal, and {hk} the impulse response of the filter, then :

yk = hNk-Mlxl

Because the signal is of finite size, one has to use special tricks to compute the edge (i.e. the first and last) coefficients. These are the following :

• One can extend the signal with 0-valued samples.
• One can periodize the signal.
• One can also reflect the signal around each edge.
• Finally one can use special filters to compute the coefficients near edges. For example one can use filters that correspond to wavelet basis adapted to the interval (see owave1 module's documentation).

Notice that if n is the size of the input signal, then the size of the output signal is nM/N, unless the -p option is selected.

The coefficients hk of the filter's impulse response are stored in the fsignal type file ImpulseResponse. The coefficients of the filter's impulse response for computing the edge coefficients are stored in the fimage type file EdgeIR.

The sample values of the input signal are read in the fsignal type file Signal, the sample values of the output signal are stored in the file FicConvol.

• The -d option specifies the rate N of sub-sampling after the convolution.
• The -i option specifies the rate M of over-sampling before convolution.
• The -e option specifies the edge processing mode.
• 0 : 0 extension.
• 1 : periodization.
• 2 : reflexion.
• 3 : adapted filtering (default).
• The -p option specifies the extension or shrinkage of the output signal near edges. It works only if the edge processing mode is 0 or 1, and enables then to get exact reconstruciton in wavelet decompositions (see owave1).
• 0 : no extension nor shrinkage (default).
• 1 : prolongation. All the coefficients yk which are not always nul when the 0 extension is selected are kept.
• 2 : shrinkage, the size of output is (input.lastp  -  input.firstp + 1)uprate/domwrate.
• The -b option specifies the high-pass filtering, i.e. the convolution is performed with {gk = (- 1)k+1h1-k} rather than {hk}.
• The -r option specifies that the convolution is performed with reflected filter {h-k} (resp. {g-k}) rather than {hk} (resp. {gk}).

Version 1.3

Last Modification date : Thu Jan 31 15:09:23 2002

Author

Jean-Pierre D'Ales

Next: iridgelet Up: Reference Previous: precond2d   Contents   Index
mw 2004-05-05