📄 chebylp.m
字号:
function an=chebylp(nn,r0dB)%CHEBYLP Calculates Dolhp-Chebychev weights.%--------%Synopsis:% an=chebylp(nn,r0dB)%%Description% Dolhp-Chebychev weights of an n-element array with sidelobes r0dB.% see C. Balanis "Antenna Theory", pp. 245-254.%%Output and Input:% nn (IntScalarT): Number of weight coefficients to produce.% r0dB (RealScalarT): Side lobe level in dB. This number is positive.%%--------%Notations:% Data type names are shown in parentheses and they start with a capital% letter and end with a capital T. Data type definitions can be found in [1]% or by "help dbtdata".% [D] = This parameter can be omitted and then a default value is used.% When the [D]-input parameter is not the last used in the call, it must be% given the value [], i.e. an empty matrix.% ... = There can be more parameters. They are explained under respective% metod or choice.%%Examples:%Software Quality:% (About what is done to ascertain software quality. What tests are done.)%Known Bugs:%%References:% [1]: Bj鰎klund S.: "DBT, A MATLAB Toolbox for Radar Signal Processing.% Reference Guide", FOA-D--9x-00xxx-408--SE, To be published.%%See Also:% gettap1 taylorlp bartlett blackman* boxcar* chebwin* hamming* hanning* % kaiser* triang*% (* = Part of Matlab Signal Processing Toolbox)% * DBT, A Matlab Toolbox for Radar Signal Processing *% (c) FOA 1994-2000. See the file dbtright.m for copyright notice.%% Start : xxxxx Lars Pettersson (larpet).% Latest change: $Date: 2000/10/16 15:20:05 $ $Author: svabj $.% $Revision: 1.3 $% ***************************************************************************** an=zeros(1,nn); r0=10^(r0dB/20); if rem(nn,2)==0 eo='evn'; m=nn/2; msum=m; else eo='odd'; m=(nn-1)/2; msum=m+1; end z0=cos(acos(r0)/(nn-1)); for n=1:msum f1=(-1)^(msum-n); if strcmp(eo,'evn') f2=z0^(2*n-1); f4=2*m-1; else f2=z0^(2*n-2); f4=2*m; end f3=1; for k=1:(m+n-2); f3=f3*k; end f5=1; f6=1; for k=1:(2*n-2) f6=f6*k; end if strcmp(eo,'evn') f6=f6*(2*n-1); end f7=1; for k=1:(msum-n) f7=f7*k; end a=f1*f2*f3*f4/(f5*f6*f7); for q=n+1:msum f1=-f1; f2=f2*z0^2; f3=f3*(m-2+q); f5=f5*(q-n); if eo=='evn' f6=f6*(q+n-1); else f6=f6*(q+n-2); end f7=f7/(msum-q+1); a=a+f1*f2*f3*f4/(f5*f6*f7); end an(m+n)=a; an(msum+1-n)=a; end
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -