function [x,y] = moivre(N,style)
% de moivre paradoxon

%% valasztunk parametereket
if nargin==0;
    N = 6;
elseif nargin==1;
    style='k';
end;
%% X- es Y- tengely
x = 0:N;
y = zeros(size(x));
for ii=x;
    y(ii+1) = nchoosek(N,ii);
end;
y = y ./ (2^N);
x = 2*x - N;
%% normalissa valtoztatni
x = x/sqrt(N);
y = y/2*sqrt(N);
%% kirajzolni
box on; hold on;
bar(x,y,style);
xlim([-4.5,4.5]);
%% tul kicsi ertekek
ii = find(y>0.001);
x  = x(ii);
y  = y(ii);