Converts MIDI note numbers to frequencies (Hz), optionally using stretched octaves. Corresponds to Equation 1 of Parncutt & Strasburger (1994), but with Hz instead of kHz.

midi_to_freq(midi, stretched_octave = FALSE, tuning_ref_Hz = 440)

Arguments

midi

Numeric vector of MIDI note numbers

stretched_octave

Logical scalar; whether or not to use a stretched octave. Default is FALSE

tuning_ref_Hz

The tuning reference point in Hz, should correspond to the frequency of the A above middle C (typically 440 Hz)

Value

Numeric vector of frequencies in Hz