Wind Chime Simulator

Experience the soothing sounds of wind chimes with an interactive Wind Chime Simulator.
Customize the chimes and wind settings to create your perfect ambient soundscape.

Wind Settings Menu


60 mph

Chimes



5 notes


0.001 seconds


2.0 seconds

The Science Behind the Simulation

A Brief History of Wind Chimes

Wind chimes have been around for a very long time—about 5,000 years! The earliest ones were found in Southeast Asia around 3000 B.C., made from bones, wood, bamboo, and seashells. People believed they could scare away evil spirits and invite good ones.

In China, wind chimes are called "Feng Ling" and were hung in temples and homes to bring positive energy. In Japan, they're called "Fūrin" and are hung outside during hot summers—the soft tinkling sound is thought to make you feel cooler and calmer. Today, people all over the world use wind chimes for relaxation and meditation.

Swinging on a String (Pendulum Physics)

The center striker in this simulation hangs from an invisible string (300 pixels long in the code). Gravity constantly pulls it down (gravity = 0.0098), and when the wind pushes it, it swings back and forth. This back-and-forth motion is called a pendulum.

Here's the cool part: how fast a pendulum swings depends only on the length of the string, NOT on how heavy it is! The famous scientist Galileo figured this out about 400 years ago by watching a chandelier swing in a church.

Damping (centerPieceDamping = 0.995) is why the striker eventually stops swinging. Each swing loses a tiny bit of energy to "air resistance"—just like how a real swing slows down if you stop pumping your legs.

Parts of the Wind Chime

The simulation has three main parts:

All the chimes are arranged in a circle, spaced chimesSpacing = 150 pixels apart.

Bump! Collision Detection

How does the computer know when two circles touch? It uses the Pythagorean theorem (a² + b² = c²) that you might have learned in math class!

The code calculates the distance between the centers of two circles: distance = Math.sqrt(dx * dx + dy * dy). If that distance is smaller than the two radii added together (strikerRadius + chimeRadius), they're touching!

When they collide, momentum transfer happens—some energy moves from the striker to the chime. The transferFactor = 0.1 means 10% of the energy transfers. The heavier striker (massDifference = 20) pushes the lighter chimes, just like a bowling ball knocking over pins.

Making Music (Sound Synthesis)

The sounds you hear aren't recordings—they're created by the computer in real-time! Here's how:

Why It Sounds Good (Music Theory)

The default scale is C Major Pentatonic: C, D, E, G, A. "Penta" means five—so this scale has only 5 notes instead of the usual 7 in a regular scale.

Here's the magic: these 5 notes sound good together no matter what order you play them! That's why wind chimes never sound "wrong"—there are no clashing notes in a pentatonic scale. Musicians call this a "foolproof" scale because you really can't hit a bad note.

Random timing + pleasant notes = the relaxing ambient sound that makes wind chimes so soothing.