function alpha=define_recombination_no_interference(L, alpha, r)
%define alpha for cross-over freq xi between each locus
%1-r is probability of no cross-over occurring
if r==0
    alpha(1)=1;
    alpha(2^L)=1;
else
    xi=1-(1-r)^(1/(L-1));
    for x=uint16(0:2^L-1) %index of alpha
        n=0;
        bit=bitget(x,1);
        for locus=2:L
            bitnext=bitget(x,locus);
            if bit~=bitnext
                n=n+1;
            end
            bit=bitnext;
        end
        alpha(1+double(x))=xi^n * (1-xi)^(L-1-n);
    end
end
