📄 pdfb_ang.m
字号:
function ang= pdfb_ang(insub, nlev)% PDFB_ANG Determine the dfb subband that the angle fall into% ang = pdfb_ang(insub, nlev)% % Returning value ang is from 3pi*4 to -pi/4 to make the range of value% change continuosly from band 1 to 2^nlev% Input:% insub: index of the subband from 1 to 2^nlev% nlev: 2^nlev is the number of direction band%% Output:% ang: the angle of direction of the band in radian%% Note:% Note: An important thing to remember is that the ang is limited to -pi/2% to pi/2, but the actual angle of the complex filter is from -pi to pi.% This is because the complex filter contained a imaginary anti-symmetric% component. We consider the direction of the impulse responses is that if% we go in the positive direction, the right hand side will corresponds to% the positive (larger than zero) of an antisymmetric wave (forexample,% sine function)% ^ pi/2% \ | /band 2^(N-1) % \ | / % \ | / % \|/ + band 2^(N-1)+2^(N-2)% |----------------->% |\ -% | \ % | \ band 2^N - 1 % | b0 \ % |-pi/2% See also: ANG_PDFB% number of all sb n4 = 2^(nlev-2);% artang value of the smallest angleatanstrt = 1/(n4*2);% artang step from adjacent subbandatanstep = 1/(n4);atanv = atanstrt:atanstep:atanstrt+atanstep*(n4-1);% correspoding angle value in radianangsb = atan(atanv);angsbrev = fliplr(angsb);% angle of the four group of direction subbandsaq1 = angsbrev + pi/2;aq2 = -fliplr(angsbrev - pi/2);aq3 = angsbrev;aq4 = -fliplr(aq3);aq = [aq1, aq2, aq3, aq4];ang = aq(insub);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -