Butterworth filter for vector/scalar fields
FF = bwfilterf(F,FSIZE,ORDER) applies a spatial Butterworth filter to
the vector/scalar fields F, with a cutoff size FSIZE (in grid units)
and order ORDER. A Butterworth filter is a low-pass or high-pass filter
in the Fourier space. bwfilterf first Fourier-transforms the field(s),
applies a low/high-pass transfer function T(k), and inverse Fourier
transforms back in the physical space. T(k) is defined as:
T(k) = 1/(1+(k/kc)^(ORDER/2)),
where k = (kx^2+ky^2)^(1/2) is the wave number, and kc is the cutoff
wave number of the filter, such that kc = N/FSIZE, with N the size the
fields. If ORDER>0, the filter is low-pass (i.e., it filters out the
small scales). If ORDER<0, the filter is high-pass (i.e., it filters
out the large scales). The X and Y dimensions of the fields must be
even. If one of the dimension is odd, the last column/row is discarded.
Typical values for FSIZE are around 1-10, and typical values for ORDER
are in the range 2-10 (positive for a low-pass filter, negative for a
high-pass filter). Large values of ORDER correspond to a sharper
filter. Values too large (say, ORDER > 10) may produce oscillations in
the physical space.
If FSIZE and ORDER are scalar, the same cutoff and order is applied
to each field F. IF FSIZE and/or ORDER are arrays, a different cutoff
and/or order is applied to each field (their dimensions must match the
dimension of the field F).
FF = bwfilterf(F,FSIZE,ORDER,'opt',...) specifies the options:
'low', 'high': applies a lowpass (by default) or highpass filter.
option 'high' simply changes the sign of ORDER.
'trunc': truncates the borders of width FSIZE, which are
affected by the filtering.
If no output argument, the result is displayed by showf.
Note: If there are missing data in the field, it is better to first
interpolate the data, using interpf.
v = loadvec('*.vc7');
filterf, interpf, addnoisef, truncf, extractf.
Published output in the Help browser
2005-2016 PIVMat Toolbox 4.01