Show HN: 3D Ising Model Simulation – interactive web-based Monte Carlo simulator
ising-model.vercel.appHello HN! I’ve just released an interactive 3D Ising model simulator built with Next.js. It’s a teaching/demo tool for exploring phase transitions and critical phenomena in ferromagnets.
## Key Features
- Real-time 3D visualization: See a central 2D slice through a 32×32×32 periodic lattice
- Adjustable parameters: Sweep the dimensionless coupling strength (βJ = J/kBT) through the critical point (≈0.22) and tune the external field (βh = h/kBT)
- Monte Carlo updates: Uses the Metropolis algorithm, updating the display every 200 × N³ flip attempts (≈33 million total)
- Live observables: Watch energy and magnetization evolve as you change parameters
## Why this matters The Ising model is a cornerstone of statistical physics and computational science courses. This tool makes it easy to:
- Visualize how temperature and field affect domain formation
- Observe the sharp change in magnetization near Tc
- Experiment with finite-size effects
Try it out and let me know what you think! I’d love feedback on performance, usability, or ideas for new features (e.g., different lattice sizes or algorithms).
Demo & source: https://github.com/nwatab/ising-model
Enjoy!