function  s_random = randomization(X_hat,G,n,s_1_p,iter_num, PAMQ)
% Let the optimum solution has the  rank-1 condition
% approximated by Gaussian randomization
%
W = chol(X_hat); %% Cholesky factorization of optimum solution
for ii=1:iter_num  % construct L random vectors 
    s_ter(:,ii)=W'*randn(n,1);
    s_tsst(:,ii)=sign(s_ter(end,ii))*s_ter(1:end-1,ii);
end
for ii=1:n-1
    for jj=1:iter_num
          [a,b]=min(abs(s_tsst(ii,jj)-PAMQ));  
           s_oo(ii,jj)=PAMQ(b);
    end
end
for ii=1:iter_num
    s_ran(:,ii)=[s_oo(:,ii);1];
    DDH(1,ii)=(s_ran(:,ii)'*G*s_ran(:,ii))/(s_1_p(1,1)^2+s_oo(:,ii)'*s_oo(:,ii));
end
[val1,index1]=max(DDH);
s_random = [s_1_p(1,1); s_oo(:,index1)];