Wave pool: interference you can see
Two sources, circular waves and bands where waves boost and cancel each other. Interference you can touch with your finger, from one prompt.

✓ Prompt tested in Gemini (signed out): worked 3 out of 3 times
- Level
- Intermediate
- You make
- A wave interference model in one HTML file
- Age
- 11+
- Time
- ≈ 25 min
- Tools
- Gemini
- Account
- Not needed
What you’ll get
Two sources send out waves. Blue is a crest, red is a trough, white is zero. Sliders for frequency, amplitude and distance, and you can drag a source with your finger. Press “Play the example” above — Gemini made it from the prompt below.
Steps
-
Open gemini.google.com. If you’re under 13, do it together with a parent, on their device.
-
Copy the whole prompt and send it:
Make a "Wave Pool" in one HTML file. Don't load anything from the internet: no Tailwind, CDN, fonts, images or libraries — only your own CSS and JavaScript inside the file. Don't save anything in browser storage. On a canvas, two point sources send out circular waves. Draw the sum of the waves from both sources in color: blue is a crest, red is a trough, white is zero, so the bands of reinforcement and cancellation are visible. Sliders: frequency, amplitude and distance between the sources. A source can be dragged with a finger. Add a small legend and a "Pause" button. Everything should look good on a phone. Show the result in Canvas. -
Wait about a minute, press Preview and try every button and slider.
-
Check the AI (see the question above).
-
Press Download (sometimes it’s under the Export menu). The file opens in any browser. Show it off in class!
Change the prompt
Before sending, swap a few words to make your own version. Change only the words, and keep the rules about the internet and Canvas.
- “two point sources” → “three point sources”
- “blue is a crest, red is a trough” → “yellow is a crest, purple is a trough”
If it doesn’t work
- The AI says it changed everything, but the result looks the same? Write:
Nothing changed. Show the updated version in Canvas. - No Preview button? Write:
Show the result in Canvas. - Just circles with no bands? Write: “The waves are not adding up. Draw the sum of the waves from both sources at every point.”
Sending work to the gallery opens soon.