Module:ED intro: Difference between revisions

Ganaram inukshuk (talk | contribs)
Rewrote code for better handling of ed types; added edo compare function (for outputting things like "12edf corresponds to 20.5edo"), but requires further rewriting/testing
Rework the comment (Expand "edh", "edr", and "edc" -- these are ad hoc inventions for this module, no one uses them outside. "Equal step tuning" isn't deprecated.)
Line 8: Line 8:


-- Notes:
-- Notes:
-- - Edo and edt are technically edh's, and edf an edr; these are their own
-- - Edo and edt are technically equal divisions of a harmonic, and edf an equal
--  types because their intros have specific wording.
--  division of a ratio; these are their own types because their intros have
-- - Edh is a special case of edr, where the ratio is h/1.
--  specific wording.
-- - Under harmonotonic tuning, edc and edr are also called ASp and APSp
-- - An equal division of a harmonic is a special case of an equal division of a
--  (ambitonal sequence and arithmetic pitch sequence, respectively). These
--  ratio, where the ratio is h/1.
--   were formerly called equal-step tunings but were reclassified as 1ed.
-- - An equal division of a ratio and an equal division of a non-integer
--  constant or cent value are also called AS (ambitonal sequence) and APS
--  (arithmetic pitch sequence), respectively.  
-- - All of these are equal-step tunings. We've adopted the 1ed-p notation where
--  possible.  
-- - Equal divisions of irrational constants (such as pi and e) are not very
-- - Equal divisions of irrational constants (such as pi and e) are not very
--  common, but count as equal divisions of arbitrary cent values.
--  common, but count as equal divisions of arbitrary cent values.
Line 20: Line 24:
local ED_TYPE_EDT = "EDT"
local ED_TYPE_EDT = "EDT"
local ED_TYPE_EDF = "EDF"
local ED_TYPE_EDF = "EDF"
local ED_TYPE_EDH = "EDH"
local ED_TYPE_EDH = "EDH" -- "equal division of a harmonic"
local ED_TYPE_EDR = "EDR"
local ED_TYPE_EDR = "EDR" -- "equal division of a ratio"
local ED_TYPE_EDC = "EDC"
local ED_TYPE_EDC = "EDC" -- "equal division of a cent value"
local ED_TYPE_DEFAULT = "UNKNOWN_TYPE"
local ED_TYPE_DEFAULT = "UNKNOWN_TYPE"