%function gamma=SEgamma(M,src_var)
%
% This function returns the optimal gamma
% (i.e. radius) for noiseless SE-CMA.

% A.Klein 2/20/98

function gamma=SEgamma(M,src_var)

k=1:M/2;
s=sqrt(3*src_var/(M^2-1))*(2*k-1);
[a,b]=min((k-0.5*(1+sqrt(M^2/2-1))).^2./(k-0.5));
gamma=s(b)^2;