npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

cymatics

v1.0.0

Published

Play a frequency and watch the sand settle into its Chladni figure: square plate and drumhead modes, computed from the wave equation.

Readme

Cymatics

Play a frequency and watch the sand settle into its Chladni figure. Everything on the page — the plate, the sand, and the tone — is computed from the wave equation in the browser. No libraries, no images, no tables.

Cymatics

The modes

What it does

Drag the frequency slider and the plate jumps to whichever mode resonates nearest, plays that tone, and lets the sand find the figure. Two plates are available:

  • a square steel plate 1 mm thick, free at its edges — the plate Chladni himself bowed;
  • a drumhead, an ideal circular membrane fixed at its rim.

The sand is a particle simulation, not a drawing. Each grain measures how far it is from the nearest nodal line, walks downhill, and is thrown about in proportion to how much the plate moves under it. It comes to rest where the plate does not move, which is exactly what sand does on a real plate.

The mathematics

The square plate's figures are the zero set of

cos(n·πx)·cos(m·πy) − cos(m·πx)·cos(n·πy)

two modes of the same frequency, superposed so that they cancel. The Superposition slider sweeps that cancellation from one mode to the other, which is why a single frequency can show a family of figures.

The drumhead's modes are Bessel functions, Jₙ(α·r)·cos(n·θ), giving n nodal diameters and s nodal circles. The Bessel functions are computed from their own series and their zeros are found by scanning for sign changes and bisecting, so no table of zeros is needed.

The frequencies are the real ones for these idealised objects. A stiff plate obeys a fourth-order equation and rings in proportion to m² + n²; a membrane has tension but no stiffness and rings in proportion to the Bessel zero itself. Both are derived from the material constants at the top of js/cymatics.js:

const PLATE = {
  young: 200e9, // Pa, steel
  density: 7850, // kg/m3
  poisson: 0.3,
  thickness: 0.001, // m
};
const MEMBRANE = {
  speed: 100, // m/s, wave speed of the stretched skin
};

A real plate of brass or glass, with its own thickness, mounting, and imperfections, will not match these numbers exactly. The shapes are the honest part; the frequencies are those of the model.

Ernst Chladni

Ernst Chladni sprinkled sand on a metal plate and drew a violin bow along its edge. At most speeds nothing happened. At certain ones the plate rang and the sand fled the moving parts to gather along the lines that stood still. He published the figures in Entdeckungen über die Theorie des Klanges and toured Europe demonstrating them, giving acoustics its first pictures. Napoleon saw the demonstration in Paris and had the Institut de France offer a prize to whoever could explain the figures mathematically. Sophie Germain won it in 1816, on her third attempt, with the first theory of elastic surfaces.

Cymatics is open source at GitHub with MIT license.

If you like frequencies, see also my other projects Healing-Frequencies (demo) and Binaural-Beats (demo). If you like figures made of circles and lines, see Sacred-Geometry (demo) and Platonic-Solids (demo).

Copyright (c) 2026 Olivier Giulieri.