Comment

Comment by jashkenas

The Wikipedia explanation is a fine one. To simplify -- it's when you observe a variable moving through through a space. In programming this means taking a coordinate or set of coordinates, and repeatedly feeding it into a function that will move the coordinates to a new location.

In this case, the heart of the function is:

    x = ((sin(xSeed * y) - cos(ySeed * x)) * width * 0.2) + width / 2
... and the same for "y".

(http://jashkenas.s3.amazonaws.com/misc/deJong/docs/deJong.ht...)

In our attractor, every time the coordinate pair lands on a new spot, that spot is exposed to a little bit of light.

What you can do for "x" and "y", you can also do for "z". If you generalize the deJong attractor into 3 dimensions, it looks like this:

https://www.youtube.com/watch?v=PrXe4RwtZpQ

parent jashkenas 14 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton