Module:Infobox interval: Difference between revisions
ArrowHead294 (talk | contribs) mNo edit summary |
m maybe i should discuss this before editing a template lol. Tags: Undo Mobile edit Mobile web edit Advanced mobile edit |
||
| (4 intermediate revisions by 4 users not shown) | |||
| Line 152: | Line 152: | ||
-- there was a subsequence of 4+ zeros | -- there was a subsequence of 4+ zeros | ||
table.insert(infobox_data, { | table.insert(infobox_data, { | ||
"[[ | "[[Subgroup monzos and vals|Subgroup monzo]]", | ||
rat.as_subgroup_ket(ratio, frame), | rat.as_subgroup_ket(ratio, frame), | ||
}) | }) | ||
| Line 218: | Line 218: | ||
if value_provided(colour_name) then | if value_provided(colour_name) then | ||
table.insert(infobox_data, { | table.insert(infobox_data, { | ||
"[[ | "[[Kite's color notation|Color name]]", | ||
colour_name, | colour_name, | ||
}) | }) | ||
| Line 265: | Line 265: | ||
if rational and regular then | if rational and regular then | ||
table.insert(infobox_data, { | table.insert(infobox_data, { | ||
"[[Tenney | "[[Tenney norm]] (log<sub>2</sub> ''nd'')", | ||
utils._round(rat.tenney_height(ratio), 6), | utils._round(rat.tenney_height(ratio), 6), | ||
}) | }) | ||
table.insert(infobox_data, { | table.insert(infobox_data, { | ||
"[[Weil | "[[Weil norm]] (log<sub>2</sub> max(''n'', ''d''))", | ||
utils._round(rat.weil_height(ratio), 6), | utils._round(rat.weil_height(ratio), 6), | ||
}) | }) | ||
table.insert(infobox_data, { | table.insert(infobox_data, { | ||
"[[Wilson | "[[Wilson norm]] (sopfr(''nd''))", | ||
utils._round(rat.wilson_height(ratio), 6), | utils._round(rat.wilson_height(ratio), 6), | ||
}) | }) | ||
end | end | ||
if regular then | local harmonic_entropy = frame.args["Harmonic entropy"] | ||
table.insert(infobox_data, { | if regular and value_provided(harmonic_entropy) then | ||
harmonic_entropy_switch = harmonic_entropy:match("^[Yy][Ee][Ss]$") | |||
if harmonic_entropy_switch then | |||
table.insert(infobox_data, { | |||
"[[Harmonic entropy]]<br>(Shannon, <math>\\sqrt{nd}</math>)", | |||
"~" .. utils._round(he.harmonic_entropy(cents), 6) .. " bits", | |||
}) | |||
end | |||
end | end | ||
| Line 314: | Line 318: | ||
local S_expressions = rat.find_S_expression(ratio) | local S_expressions = rat.find_S_expression(ratio) | ||
if #S_expressions > 0 then | if #S_expressions > 0 then | ||
local caption = "[[ | local caption = "[[S-expression]]" | ||
if #S_expressions > 1 then | if #S_expressions > 1 then | ||
caption = caption .. "s" | caption = caption .. "s" | ||