Learn R Programming

spectral (version 1.3)

BP: Simple bandpass function

Description

This function represents a simple weighting function for spectral filtering.

Usage

BP(f, fc, BW, n = 3)

Arguments

f

vector of frequencies

fc

center frequency

BW

bandwidth, with w[f < (fc - BW) | f > (fc+BW)] == 0

n

degree of the polynom, n can be real, e.g. n = 2.5

Value

This function returns a weight vector, which is to apply to the frequency vector f in a top level function

Details

The band pass is represented troughout a polynom in the form $$w = 1 - a * (f-fc)^n$$ with the degree \(n\). The parameter \(fc\) controlls the center frequency and \(a\) scales the required band width BW. outside the band width the result is forced to zero.