{"id":18986072,"url":"https://github.com/deanpdx/monte-carlo-pi","last_synced_at":"2025-11-11T10:03:15.693Z","repository":{"id":57619077,"uuid":"365375471","full_name":"DeanPDX/monte-carlo-pi","owner":"DeanPDX","description":null,"archived":false,"fork":false,"pushed_at":"2022-09-01T16:06:14.000Z","size":1149,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-01T12:46:09.503Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DeanPDX.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-05-07T23:28:04.000Z","updated_at":"2024-12-25T03:11:20.000Z","dependencies_parsed_at":"2022-09-14T12:41:32.776Z","dependency_job_id":null,"html_url":"https://github.com/DeanPDX/monte-carlo-pi","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeanPDX%2Fmonte-carlo-pi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeanPDX%2Fmonte-carlo-pi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeanPDX%2Fmonte-carlo-pi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeanPDX%2Fmonte-carlo-pi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DeanPDX","download_url":"https://codeload.github.com/DeanPDX/monte-carlo-pi/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239994005,"owners_count":19730780,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-08T16:29:28.683Z","updated_at":"2025-11-11T10:03:15.686Z","avatar_url":"https://github.com/DeanPDX.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# monte-carlo-pi\n\nA monte carlo simulation written in go that attempts to estimate [Pi](https://golang.org/pkg/math/#pkg-constants). Inspired by [this excellent blog post](https://ggcarvalho.dev/posts/montecarlo/). I'm using [Ebitengine](https://github.com/hajimehoshi/ebiten) to show the algorithm work visually. When you `go run main.go` you will see something like this:\n\n![./.github/demo.gif](./.github/demo.gif)\n\nAs you can see, this run achieved a result of 3.140872, which is off by only 0.000721. Due to the nature of monte carlo simulations, different runs will give you different results but I was consistently estimating Pi pretty accurately. Play with the constants at the top (make sure to keep width/height proportionate if you change them) and try running the test again.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeanpdx%2Fmonte-carlo-pi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeanpdx%2Fmonte-carlo-pi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeanpdx%2Fmonte-carlo-pi/lists"}