USAGE:
fwwd-spectrum <file>
[-L<label>] [options] FILTER
<filter parameters>
PURPOSE:
Investigate Kaiser-Bessel low-pass filter
properties, which are
- formal pass-band deficiency
- critical pass-band deficiency
- stop-band rejection
Up to three filter parameters can be varied in one call, which
are
- the filter length (one-sided): lfp
- the window design parameter: wdp
- the upper pass-band corner: f2
The investigation is carried out for two cases,
A data file
The idealistic response
Since we know that the pass-band is inevitably deficient near
the corner, a critical bandwidth
can be specified within which your significant signals will be
located. This is especially
useful in the first stages of a cascaded filter chain.
The protocol output (STDOUT) can be filtered to retain lines
containing '>R>' (and '>r>')
with the test results.
An example for output, filtered with
| fgrep -i '>R>'
<Main-->r> T
lfp wdp
f2 ::
ecc_
ecb_
ecp_ ecs_[dB]
f0|f-80 fnyd
<Main-->r>
__________________________________________________________________________________________________
<Main-->R> R 48
2.5000 7.5000E-02 :: -83.830084
-88.774883 -8.042363
-85.506738 0.1016 0.1000
<Main-->R> I 48
2.5000 7.5000E-02 :: -84.715148
-85.625079 -7.013949
-91.949932 0.0505 0.1000
<Main-->R> R 48
2.5000 7.6000E-02 :: -78.543322
-86.295376 -8.294929
-79.341050 0.1026 0.1000
<Main-->R> I 48
2.5000 7.6000E-02 :: -81.561380
-83.451222 -7.237595
-86.085679 0.0513 0.1000
<Main-->R> R 48
2.5000 7.7000E-02 :: -72.627879
-85.166479 -8.550657
-72.876947 0.1036 0.1000
<Main-->R> I 48
2.5000 7.7000E-02 :: -78.016671
-82.533702 -7.472965
-79.910481 0.0522 0.1000
<Main-->R> R 48
2.5000 7.8000E-02 :: -67.253276
-85.038665 -8.809983
-67.326203 0.1045 0.1000
<Main-->R> I 48
2.5000 7.8000E-02 :: -73.886105
-82.588202 -7.721120
-74.515097 0.0533 0.1000
<Main-->R> R 48
2.5000 7.9000E-02 :: -62.521246
-85.852209 -9.073524
-62.541462 0.1055 0.1000
<Main-->R> I 48
2.5000 7.9000E-02 :: -69.646417
-83.592710 -7.983211
-69.825089 0.0544 0.1000
<Main-->R> R 48
2.5000 8.0000E-02 :: -58.326189
-87.773801 -9.342091
-58.331124 0.1065 0.1000
<Main-->R> I 48
2.5000 8.0000E-02 :: -65.638305
-85.764912 -8.260474
-65.680693 0.0555 0.1000
<Main-->R> R 48
2.5000 8.1000E-02 :: -54.562759
-91.402638 -9.616693
-54.563658 0.1075 0.1000
<Main-->R> I 48
2.5000 8.1000E-02 :: -61.956175
-89.855042 -8.554236
-61.963226 0.0567 0.1000
<Main-->R> R 48
2.5000 8.2000E-02 :: -51.150620
-99.023815 -9.898550
-51.150691 0.1085 0.1000
<Main-->R> I 48
2.5000 8.2000E-02 :: -58.589847
-99.103427 -8.865907
-58.590233 0.0577 0.1000
<Main-->R> R 48
2.5000 8.3000E-02 :: -48.030581
-101.028201 -10.189081
-48.030603 0.1095 0.1000
<Main-->R> I 48
2.5000 8.3000E-02 :: -55.502906
-96.832362 -9.196987
-55.503225 0.0588 0.1000
<Main-->R> R 48
2.5000 8.4000E-02 :: -45.158546
-92.511709 -10.489910 -45.158626
0.1106 0.1000
<Main-->R> I 48
2.5000 8.4000E-02 :: -52.658355
-89.324107 -9.549056
-52.659291 0.0598 0.1000
The rows tagged I show the results with the
ideal band-pass as the objective.
The rows tagged R show the results from real data.
The result columns are (in dB-units unless stated
otherwise)
- ecc_ - the combined errors added together with
weights we call penalties,
- ecb_ - the deficiency in the critical part of the
pass-band
- ecp_ - the deficiency in the entire
pass-band
- ecs_ - the leakage in the stop-band
All these results are integral deficiencies, summed up over
the respective frequency ranges
Dimensionless frequencies, Nyquist fny = 0.5 for the input,
- f0 - given in the rows tagged R:
the frequency of the first zero (should be greater than
fnyd)
- f-80 - given in the rows tagged I:
the frequency where the pass-band deficiency (should be
less than fnyd)
- fnyd - the Nyquist of the planned
undersampling.
Filter series are output to a binary
file tmp/fwwd-test.fs
and filter spectra (a real-valued series
tagged FSP) to tmp/fwwd-test.fsp (to change,
use option -o).
The subroutines (sas/p/fwwd-iterate.f) permit
backtransform and complex-spectrum output, of which no
or only limited use is presently made.
OPTIONS:
-Tn
- Truncate the data series to contain n samples.
-Xn
- Extend the time domain with n (to avoid circular
correlation).
-C[y]a,p,ph[,S=s]
- Can be repeated: A cosine generator with amplitude a,
period p, and phase ph [deg].
p is assumed in the unit signified by y:
h for hours (default), m for minutes or s
for seconds.
s is a sweep parameter: the start and end
frequencies differ by this relative amount (default = 0.1),
a broadened spectral feature is thus produced instead of a sharp
line.
-Du[,tcr]
- The undersampling rate, an integer u
> 1
optionally followed by the period [h] of the critical part of the
pass-band.
-Pcp[,fcr]
- The penalty p for critical
pass-band deficiency (default 1.0),
optionally followed by the frequency of the critical
part of the pass-band.
-Ppp
- The penalty p for whole
pass-band deficiency (default 1.0)
-Psp
- The penalty p for
stop-band deficiency (default 1.0)
-Ifn,df
- Vary the upper band corner (f2) with increment df
-Inn,dn
- Vary the filter length with increment (integer) dn
-Iwn,dp
- Vary the window design parameter (wdp) with increment dp
In all -I options, the loop is starting with the
respective parameter given in the FILTER arguments
and goes n rounds. Default is a single
pass.
-o<fnr>
- output files, name's path+root (extensions .fs .fsp .sp
.ts will be added). Default=`tmp/fwwd-testยด
-QDB
- A debug option, for use in code development.
FILTER D:WD KAIS -
Just like it's stated in tsf-edit commands. Must be of type D:WD
KAIS
EXAMPLE:
fwwd-spectrum d/G1_garb_190105-1s.mc -LG+B
-X36000 -Cs200.,6.,0.,S=0.2 -D5 \
-Pc1.0,0.01666667 -Pp0.0 -Iw10,-0.05 -If10,0.001 \
FILTER D:WD KAIS 48 2.5 0.0 0.075 0.5 0.0
splist -n~8.00e-2 -AdB tmp/fwwd-test.fsp FSP