Skip to content

question on runif

1 message · Carl Witthoft

#
While I agree that this is someone's homework,  it occur to me that we 
can mess him up a little more.

He asked for 200 points *uniformly* distributed on (or in) a circle. 
Well,  he did NOT say "uniform random distribution".

So in fact the plot, "on" a circle would be

theta <-seq(0,2*pi, by = pi/100 )  # plus or minus a couple
radius<-1

plot({x,y converted from theta, radius})


I'm not quite sure how one generates 200 uniformly distributed points 
inside a circle,-- which btw means "on a disc" .

Maybe simply requiring them to be arranged so that all nearest neighbor 
distances are the same  :-)


Carl