function [randXY] = generateRandomPupilSamplingPoints(N,xc,yc,R) % Generates N random points in a circle.
% generateRandomPupilSamplingPoints(N) generates N random points in the unit circle at (0,0).
% generateRandomPupilSamplingPoints(N,xc,yc,R) generates N random points in a circle with radius R 
% and center at (xc,yc).
if nargin<2
   xc = 0;
   yc = 0;
   R = 1;
end  

theta = rand(N,1)*(2*pi);
r = sqrt(rand(N,1))*R;
randX = xc+ r.*cos(theta);
randY = yc+ r.*sin(theta);
randXY = [randX randY];
end
