view m-toolbox/classes/@specwin/kaiser_w3db.m @ 50:7d2e2e065cf1 database-connection-manager

Update unit tests
author Daniele Nicolodi <nicolodi@science.unitn.it>
date Wed, 07 Dec 2011 17:24:37 +0100
parents f0afece42f48
children
line wrap: on
line source

function w3db = kaiser_w3db(alpha)

% KAISER_W3DB returns the 3dB bandwidth in bins of a kaiser window with
% parameter alpha.
% 
% Taken from C code of Gerhard Heinzel:
% 
%    Compute the 3dB bandwidth (W3db) [bins]
%    of Kaiser windows from the parameter alpha.
%    Best-fit polynomial was obtained from 180 data 
%    points between alpha=1 and alpha=9.95.
%    Maximum error is 0.006 bins.
% 
% M Hewitson 19-05-07
% 
% $Id: kaiser_w3db.m,v 1.2 2011/04/08 08:56:35 hewitson Exp $
% 

a0   = 0.757185;
a1   = 0.377847;
a2   = -0.0238342;
a3   = 0.00086012;
x    = alpha;
w3db = (((((a3 * x) + a2) * x) + a1) * x + a0);

% END