Help center
The calculator and formulas
Turn bars and beats into seconds at a tempo and seconds into frames, do sums in exact fractions with the working shown, and get a checked formula for a control from your words.
Describes Sonic Weaver v5.21, released .
What it does
The calculator answers the maths a music video needs and shows every step. Type a question in words or a formula: "2 bars at 128 bpm in seconds" answers 3.75 s (exactly 15/4 s), "how many frames is 3.5 s at 30 fps" answers 105 frames, and "1/3 + 1/6" answers 1/2. It runs in your browser; nothing is sent anywhere.
Music and video timing
A beat lasts 60 divided by the tempo, a bar is 4 beats (or the time signature you set), and a phrase is 4 bars. Add the tempo with "at 128 bpm" and the frame rate with "at 30 fps", or fill in your song's tempo and frame rate on the page, and beats, bars, seconds, milliseconds and frames turn into one another exactly.
- Time: s, ms, min.
- Music: beats, bars, phrases, bpm.
- Video: frames, fps.
- Also px, percent, degrees, radians and turns.
Exact fractions
Numbers are kept as exact fractions wherever they can be, so 0.1 + 0.2 is exactly 0.3 and 1/3 + 1/6 is exactly 1/2. A fraction written together (1/2) is one number, so 1/2 s is half a second. When a result never ends as a decimal, you see the decimal to 12 figures and the exact fraction beside it.
How it reads a formula
Powers come before signs and then the usual order: -2^2 is -4 and 2 + 3 * 4 is 14. Two values side by side multiply and bind tighter than a slash: 2t is 2 times t, and 1 / 2t is 1 / (2t). 50% is 0.5, and 50% of 200 is 100. You can use functions such as sqrt, sin, cos, log, round, min, max, clamp and lerp, and the maths of our visualizers: noise, the easing curves, springs, the superformula and roses.
Errors
When something does not work it says what and points at it: a division by zero at its slash, a unit that does not fit (bars cannot be added to pixels), or a missing tempo when beats need turning into seconds. Nothing you type is ever run as code.
Formulas for your controls
Describe a motion and you get a formula for one of a look's controls: "pulse the scale on every kick" gives value * (1 + 0.25 * pulse(beat, 6)), and "loop every 2 bars" a sweep that repeats every 2 bars. Each formula is checked before you see it: it reads, it stays inside the control's range over eight bars at silence and at full volume, it repeats exactly once a cycle, and its timing is worked out exactly from the tempo. On glow and opacity its flashes are counted, and more than three a second is refused (or the amount is turned down until it is safe), because faster flashing can trigger seizures. Under the formula, How I did it lists every fact it used and where it came from (the tempo from your song or your words, the bars, the control's range from the catalogue) and every check it passed.
- Pulse, bounce or punch on every beat or bar.
- Loop, sweep or cycle every so many bars.
- Wiggle, fade in or out, breathe, follow the bass or the energy, or strobe safely.
With SW Agent and AI assistants
Ask SW Agent a sum, a timing or a formula in your own words and it answers with the same working, with a link to the Calculator. AI assistants such as Claude can use the same calculator through our MCP endpoint, as the read-only tool calculate.
Help center
Keep going
Was this page helpful?
Anonymous. Only this page’s address and your yes/no are recorded, and only if you allowed analytics cookies.