News for hackers. Stuff that matters.
Re:Random(Random(Random(Random()))) by j7ake on Tuesday May 16, 2023 @01:51AM (#35958135)
I think there is a link with curse of dimensionality here.

As you add more randoms, most of the points lie close to the surface.

This is also the case in high dimensional spheres: most of volume lie near the surface of the hyper sphere.

Re:Random(Random(Random(Random()))) by locuscoeruleus on Tuesday May 16, 2023 @01:57AM (#35958168)
This was my immediate thought as well! Can someone more mathematical say if this is an unreasonable thought?
Re:Random(Random(Random(Random()))) by j7ake on Tuesday May 16, 2023 @02:21AM (#35958301)
As one increases more dimensions, it becomes increasingly likely that at least one of them will be an "extreme" value (i.e. point is at the edge of the hypercube ).

In the random() * random() * random() ... , once you draw at least one number close to 0 (chances will increase as you add more randoms), then your output collapses to a very small number. And in this visualization, 0 is shown as a point at the edge of the circle.

Re:Random(Random(Random(Random()))) by tysam_and on Tuesday May 16, 2023 @01:59AM (#35958184)
It depends upon what metric you use to measure it.

Of course with Euclidean it will as that seems to match our expectations for low dimensional space.

I'm not a mathematician so there is not much more that I could say on the matter at this juncture.

Re:Random(Random(Random(Random()))) by j7ake on Tuesday May 16, 2023 @02:25AM (#35958318)
The volume of an n-ball has been calculated for other non-Euclidean distances.

For p goes to infinity, the unit "ball" becomes a "cube" of two units wide per side.

https://en.wikipedia.org/wiki/Volume_of_an_n-ball#Balls_in_L...

https://www.johndcook.com/blog/2010/07/02/volumes-of-general...

Re:Random(Random(Random(Random()))) by tysam_and on Tuesday May 16, 2023 @03:06AM (#35958578)
Many thanks, I've been wondering about this one for quite a while. <3 :))))