Skip to main content
šŸŒ Public

Share visualization

Send this visualization to others.

Fork of Value of PI

Public visualization

Viewing a saved revision (read-only)

8bbceda111684be7bb5956f9b0632e8c

Fork of Value of PI

0 stars1šŸŒ Public
NNita
Last edited Aug 4, 2025
Created on Aug 4, 2025
Forked from Value of PI

This interactive Monte Carlo simulation estimates the value of pi by randomly placing steel-blue points inside a square and counting how many fall within an inscribed sky-blue circle. Each click of the "Add 100 Points" button appends 100 new circles to an SVG canvas using D3.js selection and append methods, while React state tracks the running totals. The estimate updates in real time, calculated as four times the number of points inside the circle divided by the total points, with the current counts and approximation displayed in a grey overlay panel.

AI-generated description
MIT Licensed