What is custom filter curve?
SIGVIEW allows you to define custom filter curves and to apply those during time-domain signal
filter or for spectrum modification. Custom filter curve is actually a sequence of [frequency,
modification factor] pairs which define how should a frequency component be changed.
For example, a band-pass filter with a pass-band between 1000 - 2000Hz could be defined this
meaning that all frequency components up to 1000Hz should be removed (factor 0.0 ), all
between 1000Hz and 2000Hz should remain intact (factor 1.0) and all above 2000Hz up to
20000Hz should be removed (factor 0.0).
Another example would be a standard a-weighting curve used in sound pressure level
measurement. This curve is defined in dB, i.e. signal increase or decrease dB level for certain
meaning that frequency components around 10Hz should be reduced for -70.43dB, around 20Hz
for -50.39 dB and so on...Note that we do not define upper frequency limits here as in first
examples but center frequencies of each "bin".
What is included in SIGVIEW
SIGVIEW allows you to define all those filter types manually (by editing text files) or from existing
spectrum curves and to apply them to signals or spectrums. All filter curves used by SIGVIEW
are stored in a "filters" subdirectory of the SIGVIEW data directory (usually C:\Documents and
Settings\<UserName>\Application Data\Sigview\). For more information about filter file structure
and creation, see bellow.
Following filter curve types are supported:
Magnitude values filter: Filter values are used as absolute magnitude values in signal units. The
filter amplitude values will be subtracted from the actual signal values when filter is applied
(magnitude reduction). This means that value of 5 in a filter for certain frequency will actually
reduce signal amplitude on that frequency for 5 signal units (for example Volts) when filter is
applied. This filter will mostly be created from existing spectrum curves. For example, you can
use SIGVIEW to calculate your microphone characteristic response curve, save it as a filter and
subtract from a spectrum of the recorded audio.
Relative dB values filter: As in second example above, this filter contains dB values to modify
certain frequency components. For example, value of -50 means that frequency component will
be reduced for 50dB.
Relative values filter: As described in first example above, this filter contains relative coefficients
which are used to multiply frequency components on certain frequencies (for example 0.5 means
that frequency component is reduced to 50%). This type of filter will mostly be created manually
by editing filter file with editor.
Creating custom filter curves manually
Custom filter curves are stored in plain-text files with extension *.flt stored in a "filters"
subdirectory of the SIGVIEW installation directory. You can create these files in any text editor
and save them into "filters" directory located in SIGVIEW's application data directory (usually
C:\Documents and Settings\<UserName>\Application Data\Sigview\). During next startup, SIGVIEW will read your file and include it in all filter functions. Each filter has 3 header lines at the
beginning and looking similar like these:
These lines are followed by rows containing frequency in Hz/value pairs using TAB (ASCII 0x9)
as value separator. For an example, please take a look at delivered "a-weighting.flt" file.
Type parameter (Type=) in the FLT file defines which type of filter is in the file. Following values
ABS_SUB: Corresponds to "Magnitude values filter" as described above. Following filter values
will be interpreted as magnitude values and subtracted from corresponding signal magnitude
DB_ADD: Corresponds to "Relative dB values filter" as described above. Following filter values
will be interpreted as dB values defining how to modify certain frequency component (for example
-50 means that signal magnitude on that frequency will be reduced for 50dB).
ABS_MUL : Corresponds to "Relative values filter" as described above. Following filter values will
be interpreted as coefficients to multiply certain frequency component with (0.5 means reduction
of the magnitude for 50%).
Frequency parameter defines how to interpret frequency values. Following values for this
parameter are allowed:
CENTER: Frequency value is center frequency. Corresponding filter value will be applied to all
frequencies ( (fi + fi-1)/2, (fi+fi+1)/2 ]
MAX: Frequency value is a upper limit frequency. Corresponding filter value will be applied to all
frequencies ( fi-1, fi]
Creating custom filter curves from SIGVIEW
You can save any signal or analysis result from SIGVIEW as filter curve. You will usually start
with a magnitude spectrum or its averaged version. It can be directly saved as "Magnitude values
filter". The ratio between two spectrums can, for example, be stored as "Relative values filter". In
all cases, you will use File/Save as filter curve... main menu option on a window containing your
filter sequence. The following dialog appears after opening this menu item:
You have to define the file name of your filter. It has to have FLT extension and it should be
stored in "filters" directory under SIGVIEW's application data directory (usually C:\Documents and
Settings\<UserName>\Application Data\Sigview\). Otherwise, it will not be visible to SIGVIEW. You can also decide to store filter as a temporary file. In that case, you should only give it a
name - there will be no file actually stored on disk. Of course, the filter will be lost when you close SIGVIEW. In Filter type box you have to tell SIGVIEW what type of filter it is, i.e. how to interpret
filter values later when applying the filter. These types correspond exactly to the filter types
explained above. After you press OK, filter will be saved and will be accessible from filter and
spectrum properties functions.
All filters stored in this way will use CENTER setting to interpret frequency values (see above).
To delete filter, simply delete its *.FLT file in filters directory.
Using custom filter curves for time-domain signal filtering
You can use custom filters to directly filter time-domain data. This feature is implemented as a
part of Signal tools/Filter... menu option. After applying your filter to a time-domain signal, the
difference (or ratio) between magnitude spectrum of the original signal and magnitude spectrum
of the filtered signal will correspond to the custom filter curve.
Using custom filter curves for spectrum modification
You can use custom filters to modify calculated magnitude spectrum or power spectrum just as if
the filter were applied to the origin time-domain data. This option is available from Properties
dialog of any spectrum window or as general setting in Spectrum Analysis defaults
applying your filter to a spectrum, the difference (or ratio) between original spectrum and modified
spectrum will correspond to the custom filter curve.
No matter what is the type of your custom filter (dB, absolute,...), SIGVIEW will be able to apply it
to all spectrum types, i.e. dB filter will be also applicable on magnitude spectrum with linear scale
values. SIGVIEW will perform all needed filter conversions internally.