Skip to main content

Module tuningsystem

Module tuningsystem 

Source
Expand description

Tuning-system ratios, labels and frequency helpers.

Structs§

Fraction
A ratio-like value used by tuning tables.

Enums§

TuningSystem
Supported tuning systems and ratio tables.

Constants§

A0
Frequency of A0 in hertz.
A4
Frequency of A4 in hertz.
ALL_TUNING_SYSTEMS
All built-in tuning systems in canonical display order.
AN1
Frequency of A-1 in hertz.
C0
Frequency of C0 in hertz.
C4
Frequency of middle C in hertz.
CN1
Frequency of C-1 in hertz.
COMMON_TWELVE_TONE_TUNING_SYSTEMS
The common twelve-tone tuning systems useful for comparing pitch frequencies.
ELEVEN_LIMIT
Twenty-nine-tone eleven-limit tuning ratios.
FIVE_LIMIT
Twelve-tone five-limit tuning ratios.
FORTYTHREE_TONE
Backwards-compatible alias for FORTY_THREE_TONE.
FORTY_THREE_TONE
Forty-three-tone tuning ratios.
INDIAN_SCALE
Seven-tone Indian scale ratios.
INDIAN_SCALE_22
Twenty-two-tone Indian scale ratios.
INDIAN_SCALE_NAMES
Degree labels for the seven-tone Indian scale.
INDIA_SCALE_ALT
Alternate seven-tone Indian scale ratios.
JAVANESE
Five-tone Javanese equal-temperament approximation.
JUST_INTONATION
Twelve-tone just intonation ratios.
JUST_INTONATION_24
Twenty-four-tone just intonation ratios.
OCTAVE_SIZE
Default octave size for twelve-tone systems.
PYTHAGOREAN_TUNING
Twelve-tone Pythagorean tuning ratios.
THAI
Seven-tone Thai equal-temperament approximation.
TWELVE_TONE_NAMES
Degree labels for a twelve-tone chromatic octave.
WHOLE_TONE_NAMES
Degree labels for a whole-tone octave.

Functions§

equal_temperament
Creates an equal-temperament fraction for tone within octave_size.
equal_temperament_12
Creates a twelve-tone equal-temperament fraction.
equal_temperament_default
Creates an equal-temperament fraction using OCTAVE_SIZE.
get_cents
Returns cents offset from equal temperament for a tuning-system degree.
get_cents_at
Returns cents offset from equal temperament for a fractional degree index.
get_fraction
Returns the fraction for a tuning-system degree.
get_frequency
Returns the frequency in hertz for a tuning-system degree.
get_frequency_at
Returns the frequency in hertz for a fractional tuning-system degree.
get_label
Returns a display label for a tuning-system degree.
get_ratio
Returns the frequency ratio for a tuning-system degree.