{
  "id": "bpm",
  "version": "77a8235dc6cf",
  "status": "published",
  "name": "BPM Calculator",
  "question": "How do I calculate BPM?",
  "summary": "Works out the tempo of a song in beats per minute from the beats counted in a time, or the time or beats from the tempo, and the length of each note value in milliseconds.",
  "category": "everyday-life",
  "subcategory": "fun",
  "url": "https://www.acalculator.org/everyday-life/bpm-calculator",
  "markdown": "https://www.acalculator.org/everyday-life/bpm-calculator.md",
  "kind": "formulas",
  "method": "BPM = beats × 60 ÷ seconds; one beat (a quarter note) lasts 60,000 ÷ BPM milliseconds",
  "assumptions": [
    "The beat is a quarter note, as in 4/4 time; half a beat is an eighth note.",
    "A dotted note is 1.5 times its plain length; a triplet eighth is a third of a beat.",
    "The tempo is steady over the time counted."
  ],
  "inputs": {
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "type": "object",
    "properties": {
      "beats": {
        "title": "Beats counted",
        "description": "How many beats you counted.",
        "type": "number",
        "exclusiveMinimum": 0,
        "maximum": 1000000
      },
      "time": {
        "title": "Time",
        "description": "How long you counted for.",
        "type": [
          "number",
          "string"
        ],
        "x-quantity": "time",
        "exclusiveMinimum": 0,
        "maximum": 86400
      },
      "bpm": {
        "title": "Tempo (BPM)",
        "description": "The tempo in beats per minute, from 1 to 1,000.",
        "type": "number",
        "minimum": 1,
        "maximum": 1000
      }
    }
  },
  "solve": {
    "fillAny": 2,
    "variables": [
      "beats",
      "time",
      "bpm"
    ],
    "inputsOnly": []
  },
  "outputs": {
    "beats": {
      "label": "Beats counted",
      "description": "How many beats you counted.",
      "format": "number"
    },
    "seconds": {
      "label": "Time",
      "description": "How long you counted for.",
      "format": "quantity"
    },
    "bpm": {
      "label": "Tempo",
      "description": "Beats per minute: beats × 60 ÷ seconds.",
      "format": "number"
    },
    "beat": {
      "label": "Beat (quarter note)",
      "description": "The length of one beat, a quarter note: 60,000 ms ÷ BPM.",
      "format": "quantity",
      "unit": "ms"
    },
    "half": {
      "label": "Half note",
      "description": "Two beats.",
      "format": "quantity",
      "unit": "ms"
    },
    "whole": {
      "label": "Whole note (4/4 bar)",
      "description": "Four beats, one bar of 4/4.",
      "format": "quantity",
      "unit": "ms"
    },
    "eighth": {
      "label": "Eighth note",
      "description": "Half a beat.",
      "format": "quantity",
      "unit": "ms"
    },
    "sixteenth": {
      "label": "Sixteenth note",
      "description": "A quarter of a beat.",
      "format": "quantity",
      "unit": "ms"
    },
    "dottedEighth": {
      "label": "Dotted eighth note",
      "description": "Three quarters of a beat.",
      "format": "quantity",
      "unit": "ms"
    },
    "tripletEighth": {
      "label": "Eighth-note triplet",
      "description": "A third of a beat.",
      "format": "quantity",
      "unit": "ms"
    }
  },
  "defaultAnswer": {
    "inputs": {
      "beats": 32,
      "time": 15
    },
    "outputs": {
      "bpm": 128,
      "beat": 0.46875000000000006,
      "half": 0.9375,
      "whole": 1.875,
      "eighth": 0.234375,
      "sixteenth": 0.1171875,
      "dottedEighth": 0.3515625,
      "tripletEighth": 0.15625000000000003
    },
    "text": "32 beats in 15 s is 128 BPM."
  },
  "examples": [
    {
      "given": {
        "beats": 32,
        "time": 15
      },
      "expect": {
        "bpm": 128,
        "beat": 0.46875,
        "eighth": 0.234375,
        "dottedEighth": 0.3515625
      },
      "source": "SI Brochure (BIPM, 9th edition, 2019), Table 8: 1 min = 60 s; hand calculation in content.mdx: 32 × 60 ÷ 15 = 128"
    },
    {
      "given": {
        "bpm": 120,
        "time": 30
      },
      "expect": {
        "beats": 60,
        "beat": 0.5,
        "whole": 2,
        "sixteenth": 0.125
      },
      "source": "SI Brochure (BIPM, 9th edition, 2019), Table 8: 1 min = 60 s; hand calculation in content.mdx"
    },
    {
      "given": {
        "beats": 100,
        "bpm": 90
      },
      "expect": {
        "time": 66.66666666666666,
        "tripletEighth": 0.2222222222222222
      },
      "source": "hand calculation in content.mdx: 100 × 60 ÷ 90 = 66.67 s"
    }
  ],
  "sources": [
    "Bureau International des Poids et Mesures, The International System of Units (SI Brochure, 9th edition, 2019), Table 8: 1 min = 60 s."
  ],
  "related": [
    "time-to-decimal",
    "minutes"
  ],
  "changelog": []
}
