clf;
clear;

m = 100;
range = 50;

for w0 = m:0.05:m+1,
t0 = 0;
p1 = 0;
p2 = 0;
n1 = 0;
n2 = 0;

for mp = m-range:m+range,
t0 = t0 + N(mp,mp,w0);
p1 = p1 + N(mp,mp+1,w0);
p2 = p2 + N(mp,mp+2,w0);
n1 = n1 + N(mp,mp-1,w0);
n2 = n2 + N(mp,mp-2,w0);
end;

pw = [pw w0];
pt0 = [pt0 t0];
pp1 = [pp1 p1];
pp2 = [pp2 p2];
pn1 = [pn1 n1];
pn2 = [pn2 n2];
end;

plot (pw,pt0);

