gill09_harmonicity: Harmonicity

View source: R/model-bowl18.R

gill09_harmonicityR Documentation

Harmonicity

Description

Computes the harmonicity of a chord using the percentage similarity measure of Gill & Purves (2009).

Usage

gill09_harmonicity(x, tonic = 0L)

Arguments

x

Chord to analyse, expressed as an integerish vector of MIDI note numbers, or more generally as any valid input to pi_chord.

tonic

(Integerish scalar, default = 0L) Tonic to use when defining the just-tuned scale.

Details

This percentage similarity measure corresponds to the percentage of the harmonics that the chord holds in common with a harmonic series rooted on the chord's fundamental frequency.

While \insertCiteGill2009;textualincon originally presented this measure to quantify the harmonicity of two-note chords (dyads) \insertCiteBowling2018;textualincon subsequently demonstrated the application of this measure to chords of arbitrary sizes.

Value

(Numeric scalar) The chord's harmonicity, defined as the proportion of harmonics of the chord's fundamental frequency that coincide with the harmonics of the chord tones.

Note

The algorithm assumes that chord pitches are precisely tuned to the just-tuned scale provided by Bowling et al. (2018). This scale can be found at rational_scale.

References

\insertRef

Bowling2018incon

Examples

gill09_harmonicity(c(60, 64, 67))
gill09_harmonicity("60 64 67")
gill09_harmonicity(hrep::pi_chord(c(60, 64, 67)))

pmcharrison/incon documentation built on Feb. 12, 2024, 3:18 a.m.