{"version":"1.0","type":"rich","title":"Mandelbrot with P5.js","description":"This visualization renders the Mandelbrot set as a monochrome fractal, mapping each pixel to a complex coordinate and coloring it based on iteration count using P5.js. The sketch initializes a canvas sized to its container, sets `pixelDensity(1)`, and loads pixel data via `loadPixels()`. It iterates through the plane, applying the recurrence `z = z² + c`, and determines brightness with `dist()` and `map()` functions. The code uses `noLoop()` to draw once, then `updatePixels()` to display the computed grayscale values.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/96b514946282455d9ff7875368803397?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}