Module:Harmonics in cet: Difference between revisions

Fix module dependency
Comment out problem parts for the moment
 
Line 14: Line 14:
local trel = {"! [[Relative interval error|Relative]] ([[relative cent|%]]) "}
local trel = {"! [[Relative interval error|Relative]] ([[relative cent|%]]) "}
local tdeg
local tdeg
if reduction then
tdeg = {"! colspan=\"2\" | Steps<br>([[octave reduction|reduced]])"}
-- TODO: determine `steps`
else
-- if reduction then
tdeg = {"! colspan=\"2\" | Step"}
-- tdeg = {"! colspan=\"2\" | Steps<br>([[octave reduction|reduced]])"}
end
-- else
-- tdeg = {"! colspan=\"2\" | Step"}
-- end
tdeg = {"! colspan=\"2\" | Step"}
local fmt_abs = string.format(" %%+.%df", prec)
local fmt_abs = string.format(" %%+.%df", prec)
local fmt_rel = " %+.1f"
local fmt_rel = " %+.1f"
Line 30: Line 34:
table.insert(tabs, "" .. string.gsub(string.format(fmt_abs, 1200 * (ev - v) * size), "%-", "-"))
table.insert(tabs, "" .. string.gsub(string.format(fmt_abs, 1200 * (ev - v) * size), "%-", "-"))
table.insert(trel, "" .. string.gsub(string.format(fmt_rel, 100 * (ev - v)), "%-", "-"))
table.insert(trel, "" .. string.gsub(string.format(fmt_rel, 100 * (ev - v)), "%-", "-"))
if reduction then
table.insert(tdeg, "" .. ev .. "<br>(".. ev % steps .. ")")
-- TODO: determine `steps`
else
-- if reduction then
table.insert(tdeg, "" .. ev)
-- table.insert(tdeg, "" .. ev .. "<br>(".. ev % steps .. ")")
end
-- else
-- table.insert(tdeg, "" .. ev)
-- end
table.insert(tdeg, "" .. ev)
end
end
local titleMarkup = ""
local titleMarkup = ""