Skip to main content
Public

Share visualization

Loading preview…

State

vizhub.com

Shared links may look like this on X, LinkedIn, Slack, and Discord.

Before sharing, review the publishing checklist.

Choose how to deliver this visualization

LinkedIn caption

LinkedIn may not keep text supplied by the share sheet. Copy the caption and paste it into the post if needed. You can tag the VizHub company page when posting.

More options

Embed on a websiteCopy iframe embed code
Download & exportPNG, HTML, source ZIP

State

0
MMTR
Last edited Sep 12, 2021
Created on Aug 25, 2021
Forked from HTML Starter

This interactive visualization illustrates the Collatz conjecture, a sequence where even numbers are halved and odd numbers are tripled and incremented, continuing until reaching 1. A user enters a starting number and presses a button, which triggers a step-by-step animated traversal through six circular state nodes displayed on a grid. Each node highlights and the current value is shown in a text output as the sequence progresses. The visualization uses plain HTML, CSS Grid for the state layout, and the Web Audio API to optionally generate a triangle-wave tone on each step, with the frequency varying based on whether the current number is even or odd. JavaScript timers (setTimeout) control the sequential highlighting of the nodes.

AI-generated description

Collatz .

Comments

Sign in to join the discussion.

MIT Licensed