q1=2.0;y0=2852.91/2;f=.1; N=100;
n1d=-100:q1:-60;
nd=.05.*n1d;
%di=ones(size(nd));
b=2*pi*y0;x1=zeros(size(nd));%di=zeros(size(nd));%s1=ones(size(nd));
ss=ones(size(nd));
x1=10 .^nd;x=b.*x1;
n1z=-77.18:5:-77.18;
nz=.1.*n1z;
r0=zeros(size(nz));
r0=(b/2)^2.*(10 .^nz);
t1=0:f:.5;
t=2*pi.*t1;P=length(nz);T=length(t);Q=length(nd);ss=ones(T,Q);s1=ones(T,Q);
for p=1:P
a=7
  for l=1:T;
    for q=1:Q;
s=0;
for n=1:100;xn=x(q)*n; bn=besselj(1,xn);
s=s+(1/xn)*bn*cos(t(l)*n)*exp(-n^2*r0(p));
end
s1(l,q)=(1+4*s)^2;ss(l,q)=10*log10(s1(l,q));
%di(q)=n1d(q)+ss(q);
    end

%plot(n1d,di)
%axis([-100 -60 -100 -60])
%hold on
  end
end
c=ones(T+1,Q);
c=[n1d;ss];
disp('Nivel zgomot la intrare=-77,18 dbm0')
disp(c)