What exactly is Tweaking ?

For that you need some context.

Historically speaking, music was an accompaniment for theatrical plays. A typical song has a Theme and develops Exposition / Conflict / Resolution through time. Its not a coincidence that the sonata and the dramatic structure share the same form. In a typical play you have scenes, transitions, sets in the background and characters in the foreground. While the play progresses and characters clash you get music alongside each of these elements. Every song has a title that guides the listener to what the song is about. Typical Scenes include intro, bridge, buildup, section, breakdown and climax. What is the intro about ? What is the bridge about ? What is the verse about ? What is the chorus about ? What are the sections about ? The essential question driving any story is how to be ? In a drama this question is answered with doubts, emotion, circularity, warnings from the chorus, exposition, rises, falls, reprisals, conclusions, contradictions, denouncements, confrontations, mistakes, reversals, recognition, revelation resolution, statements and breakdowns.

Modern music has evolved to be standalone but it retains elements of theatrical story telling. You can divide a song into verses and sections. In the documentation, we will use the terms from plays. Within each musical scene you typically have,

  • Background: You use layers of rhythm and groove to set the mood.

  • Foreground: Lead (Soliloquy), Counterpoint (Character Conflict), Call Response(Dialogues), Motif, Ornaments (Exposition)

In Electronic Music, the foreground is mainly developed using Layers(polyrhythms) and Tweaking. Tweaking and Layers effectively function for the purposes of Exposition and Conflict. Chorus, Fade, Drop are used for transitions typically in electronic music. Tweaking is also called knob-twisting by hardware users. To compare the foreground in others,

Classical Music: Counterpoint and Harmony
Rock: Call Response

Now EDM - Dub, Techno and Jungle - are distinct musical genres. What could they possibly share ?

  1. All three uphold the primacy of Rhythm for start.

  2. All three are instrumental.

  3. Voices are used sparingly as samples.

  4. All three have a tradition of live acts.

  5. Dub Plates are common for these genres.

  6. Melody is nothing but a repeating stab (motif)

If you want to add a solo to EDM, you typically add a live instrument.

Dub Music is made by messing with the Recording Engineer’s Mixing desk. A prime example of tweaking.

Techno is made by messing with Hardware or Hardware + Software. Tweaking + Layering.

Jungle is used as a catch all for Breakbeat, Hardcore as well. Jungle Music is made by messing with Hardware + Software combo. Complex Layering is used here.

Bitrhythm only supports rhythmic notations and is geared towards electronic music. My current goal is to produce an IDM track and Chiptune with it with complex rhythmic patterns. As for techno the current setup seems alright. Support will be added in the future for pitch manipulation in a different module or a different project. There is a piano module in the code with midi support but its currently deactivated.

You can treat a musical scale as no different than a drumset. The pentatanic scale approximately maps to a drumset and you can use techniques from melodic drumming with multiple samples. This is typically how drummers approach guitars.

Is Bitrhythm Maths heavy ?

You will need some basic maths operations to understand and use bitrhythm effectively. These operations are about working with lists of numbers and lists of strings.

Some common operations on lists include

  • Rotate

  • Invert

  • Slicing

  • Choose

  • Reverse

  • Shuffle

  • Filter

  • Map

Other math operations are useful for working with envelope ranges,

  • Clamp

  • Ramp

  • Waves

Programming is not that difficult. Programming is about organising reactions to events. A typical event comes from

  1. The timer

  2. User interface elements like sliders and dials

  3. Data change

A typical reaction to an event (often called a handler) either changes data or displays data. A data change triggers more events. Other programming concepts needed for birthythm

As Tone.js provides the bulk of sound generation in Bitrhythm you should make youself comfortable with its APIs.

You will also need to understand

  • Conditions

  • Loops

  • Functions

  • Javascript Math.random

  • Modulo Arithmetic

  • SetInterval Timers

What comes next - This is the pertinent question when composing music. If you are feeling adventurous you can try to use,

  1. Mathematical patterns like fibonacci series, geometric series, pi, fractals …

  2. Neo-Riemannian_theory, Combinatory theory

  3. Sacred Geometry

  4. Circle of fifths, chord progressions

  5. Set transformations like inversion on Scales

  6. Licks from books

  7. Randomness, I Ching, Playing Cards

DJ Controls



Essentially a DJ is like a conductor. Loops are like individual instrumentalists.

  1. Cueing -> Mute / Solo

  2. Dynamics -> Volume

  3. Ornamentation -> Cutoff

  4. Tempo, Beat Counting -> Beat Matching

Music is arrangement

See Also

In screenplays you also have a setup / payoff dynamic.


  • Obstacles

  • Challenges

  • Forces

  • Context