<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ja">
	<id>https://ja.xen.wiki/index.php?action=history&amp;feed=atom&amp;title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB%3AMOS_tunings</id>
	<title>モジュール:MOS tunings - 版の履歴</title>
	<link rel="self" type="application/atom+xml" href="https://ja.xen.wiki/index.php?action=history&amp;feed=atom&amp;title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB%3AMOS_tunings"/>
	<link rel="alternate" type="text/html" href="https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;action=history"/>
	<updated>2026-07-04T00:23:40Z</updated>
	<subtitle>このウィキのこのページに関する変更履歴</subtitle>
	<generator>MediaWiki 1.43.6</generator>
	<entry>
		<id>https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1405&amp;oldid=prev</id>
		<title>2026年4月1日 (水) 21:35にFurcht968による</title>
		<link rel="alternate" type="text/html" href="https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1405&amp;oldid=prev"/>
		<updated>2026-04-01T21:35:45Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;ja&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← 古い版&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;2026年4月1日 (水) 21:35時点における版&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l65&quot;&gt;65行目:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;65行目:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			and step_ratios[2][1] == 2 and step_ratios[2][2] == 1&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			and step_ratios[2][1] == 2 and step_ratios[2][2] == 1&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			and step_ratios[3][1] == 3 and step_ratios[3][2] == 1 then&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			and step_ratios[3][1] == 3 and step_ratios[3][2] == 1 then&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			return &quot;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Simple Tunings&lt;/del&gt;&quot;, {{2, 1}, {3, 1}, {3, 2}}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			return &quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;簡易な調律&lt;/ins&gt;&quot;, {{2, 1}, {3, 1}, {3, 2}}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l78&quot;&gt;78行目:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;78行目:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		step_ratio_range = tamnams.find_step_ratio_range_for_ratio_pair(lower_ratio, upper_ratio)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		step_ratio_range = tamnams.find_step_ratio_range_for_ratio_pair(lower_ratio, upper_ratio)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		if step_ratio_range ~= nil then&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		if step_ratio_range ~= nil then&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			step_ratio_range = p.capitalize_first(step_ratio_range) .. &quot; &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Tunings&lt;/del&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			step_ratio_range = p.capitalize_first(step_ratio_range) .. &quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;調律&lt;/ins&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		else&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		else&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			step_ratio_range = &quot;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Tunings&lt;/del&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			step_ratio_range = &quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;調律&lt;/ins&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	elseif #step_ratios == 1 then&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	elseif #step_ratios == 1 then&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		step_ratio_range = tamnams.lookup_step_ratio(step_ratios[1])&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		step_ratio_range = tamnams.lookup_step_ratio(step_ratios[1])&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		if step_ratio_range ~= nil then&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		if step_ratio_range ~= nil then&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			step_ratio_range = p.capitalize_first(step_ratio_range) .. &quot; &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Tuning&lt;/del&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			step_ratio_range = p.capitalize_first(step_ratio_range) .. &quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;調律&lt;/ins&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		else&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		else&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			step_ratio_range = string.format(&quot;%s/%s&quot;, step_ratios[1][1], step_ratios[1][2]) .. &quot; &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Tuning&lt;/del&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;			step_ratio_range = string.format(&quot;%s/%s&quot;, step_ratios[1][1], step_ratios[1][2]) .. &quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;調律&lt;/ins&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	else&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	else&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		step_ratio_range = &quot;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Tunings&lt;/del&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		step_ratio_range = &quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;調律&lt;/ins&gt;&quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Furcht968</name></author>
	</entry>
	<entry>
		<id>https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1404&amp;oldid=prev</id>
		<title>2026年4月1日 (水) 21:34にFurcht968による</title>
		<link rel="alternate" type="text/html" href="https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1404&amp;oldid=prev"/>
		<updated>2026-04-01T21:34:09Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;ja&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← 古い版&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;2026年4月1日 (水) 21:34時点における版&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l170&quot;&gt;170行目:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;170行目:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	result = result&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	result = result&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		.. &amp;quot;! rowspan=\&amp;quot;2\&amp;quot; class=\&amp;quot;unsortable\&amp;quot; | 音階の度数\n&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		.. &amp;quot;! rowspan=\&amp;quot;2\&amp;quot; class=\&amp;quot;unsortable\&amp;quot; | 音階の度数\n&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		.. &quot;! rowspan=\&quot;2\&quot; class=\&quot;unsortable\&quot; | &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Abbrev.&lt;/del&gt;\n&quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		.. &quot;! rowspan=\&quot;2\&quot; class=\&quot;unsortable\&quot; | &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;略記&lt;/ins&gt;\n&quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	-- Headers for tunings; these span two cols&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	-- Headers for tunings; these span two cols&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l197&quot;&gt;197行目:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;197行目:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	-- Second row of headers&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	-- Second row of headers&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	for i = 1, #step_ratios do&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	for i = 1, #step_ratios do&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		result = result .. &quot;! style=\&quot;border-right: none;\&quot; class=\&quot;unsortable\&quot; | &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;ステップ地&lt;/del&gt;\n&quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		result = result .. &quot;! style=\&quot;border-right: none;\&quot; class=\&quot;unsortable\&quot; | &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;ステップ値&lt;/ins&gt;\n&quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		result = result .. &amp;quot;! style=\&amp;quot;border-left: none; text-align: right;\&amp;quot; | セント値\n&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		result = result .. &amp;quot;! style=\&amp;quot;border-left: none; text-align: right;\&amp;quot; | セント値\n&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Furcht968</name></author>
	</entry>
	<entry>
		<id>https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1402&amp;oldid=prev</id>
		<title>2026年4月1日 (水) 21:25にFurcht968による</title>
		<link rel="alternate" type="text/html" href="https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1402&amp;oldid=prev"/>
		<updated>2026-04-01T21:25:21Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;ja&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← 古い版&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;2026年4月1日 (水) 21:25時点における版&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l206&quot;&gt;206行目:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;206行目:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		-- Add cells for the degree names&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		-- Add cells for the degree names&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		local degree_name   = tamnams.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;degree_quality&lt;/del&gt;(interval, input_mos&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;, &quot;sentence-case&quot;, mos_prefix&lt;/del&gt;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		local degree_name   = tamnams.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;degree_quality_japanese&lt;/ins&gt;(interval, input_mos)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		local degree_abbrev = tamnams.degree_quality(interval, input_mos, &amp;quot;abbrev&amp;quot;       , mos_abbrev)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		local degree_abbrev = tamnams.degree_quality(interval, input_mos, &amp;quot;abbrev&amp;quot;       , mos_abbrev)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Furcht968</name></author>
	</entry>
	<entry>
		<id>https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1381&amp;oldid=prev</id>
		<title>2026年4月1日 (水) 18:59にFurcht968による</title>
		<link rel="alternate" type="text/html" href="https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1381&amp;oldid=prev"/>
		<updated>2026-04-01T18:59:08Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;ja&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← 古い版&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;2026年4月1日 (水) 18:59時点における版&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l163&quot;&gt;163行目:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;163行目:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	-- Table caption&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	-- Table caption&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	result = result	.. &quot;|+ style=\&quot;font-size: 105%; white-space: nowrap;\&quot; | &quot; .. string.format(&quot;%&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;s of &lt;/del&gt;%s\n&quot;, step_ratio_range&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;, scale_sig&lt;/del&gt;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	result = result	.. &quot;|+ style=\&quot;font-size: 105%; white-space: nowrap;\&quot; | &quot; .. string.format(&quot;%&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;sの&lt;/ins&gt;%s\n&quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;, scale_sig&lt;/ins&gt;, step_ratio_range)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		.. &amp;quot;|-\n&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;		.. &amp;quot;|-\n&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Furcht968</name></author>
	</entry>
	<entry>
		<id>https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1377&amp;oldid=prev</id>
		<title>Furcht968: ページの作成:「local p = {}  local et = require(&quot;Module:ET&quot;) local jira = require(&quot;Module:JI ratios&quot;) local mos = require(&quot;Module:MOS&quot;) local tamnams = require(&quot;Module:TAMNAMS&quot;) local tip = require(&quot;Module:Template input parse&quot;) local yesno = require(&quot;Module:Yesno&quot;)  -- Rewritten/simplified module replacement for Module:MOS degrees -- A new template is chosen because it&#039;s a better name than the old one and is -- far easier to maintain than the old one.  -- TODO: -- - Relegate JI r…」</title>
		<link rel="alternate" type="text/html" href="https://ja.xen.wiki/index.php?title=%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB:MOS_tunings&amp;diff=1377&amp;oldid=prev"/>
		<updated>2026-04-01T18:52:40Z</updated>

		<summary type="html">&lt;p&gt;ページの作成:「local p = {}  local et = require(&amp;quot;Module:ET&amp;quot;) local jira = require(&amp;quot;Module:JI ratios&amp;quot;) local mos = require(&amp;quot;Module:MOS&amp;quot;) local tamnams = require(&amp;quot;Module:TAMNAMS&amp;quot;) local tip = require(&amp;quot;Module:Template input parse&amp;quot;) local yesno = require(&amp;quot;Module:Yesno&amp;quot;)  -- Rewritten/simplified module replacement for Module:MOS degrees -- A new template is chosen because it&amp;#039;s a better name than the old one and is -- far easier to maintain than the old one.  -- TODO: -- - Relegate JI r…」&lt;/p&gt;
&lt;p&gt;&lt;b&gt;新規ページ&lt;/b&gt;&lt;/p&gt;&lt;div&gt;local p = {}&lt;br /&gt;
&lt;br /&gt;
local et = require(&amp;quot;Module:ET&amp;quot;)&lt;br /&gt;
local jira = require(&amp;quot;Module:JI ratios&amp;quot;)&lt;br /&gt;
local mos = require(&amp;quot;Module:MOS&amp;quot;)&lt;br /&gt;
local tamnams = require(&amp;quot;Module:TAMNAMS&amp;quot;)&lt;br /&gt;
local tip = require(&amp;quot;Module:Template input parse&amp;quot;)&lt;br /&gt;
local yesno = require(&amp;quot;Module:Yesno&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
-- Rewritten/simplified module replacement for Module:MOS degrees&lt;br /&gt;
-- A new template is chosen because it&amp;#039;s a better name than the old one and is&lt;br /&gt;
-- far easier to maintain than the old one.&lt;br /&gt;
&lt;br /&gt;
-- TODO:&lt;br /&gt;
-- - Relegate JI ratio input to sorting entered ratios; this is to decouple&lt;br /&gt;
--   ratio search from ratio sorting/filtering.&lt;br /&gt;
-- - Diatonic interval category lookup?&lt;br /&gt;
&lt;br /&gt;
-- Helper function&lt;br /&gt;
-- Capitalizes the first character of a string&lt;br /&gt;
function p.capitalize_first(text)&lt;br /&gt;
	return string.upper(string.sub(text, 1, 1)) .. string.sub(text, 2, -1)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Helper function&lt;br /&gt;
-- Sorts step ratios L:s by their hardnesses&lt;br /&gt;
function p.sort_step_ratios(step_ratios)&lt;br /&gt;
	if #step_ratios &amp;lt; 2 then&lt;br /&gt;
		return step_ratios&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Sort using selection sort, which is ok for smol datasets.&lt;br /&gt;
	for i = 1, #step_ratios - 1 do&lt;br /&gt;
		local index_of_smallest = i&lt;br /&gt;
		local current_val = step_ratios[i][1] / step_ratios[i][2]&lt;br /&gt;
		&lt;br /&gt;
		-- Find the ratio with the smallest hardness&lt;br /&gt;
		for j = i + 1, #step_ratios do&lt;br /&gt;
			if (step_ratios[j][1] / step_ratios[j][2] &amp;lt; current_val) then&lt;br /&gt;
				index_of_smallest = j&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		if index_of_smallest ~= i then&lt;br /&gt;
			local temp = step_ratios[index_of_smallest]&lt;br /&gt;
			step_ratios[index_of_smallest] = step_ratios[i]&lt;br /&gt;
			step_ratios[i] = temp&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return step_ratios&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Helper function&lt;br /&gt;
-- Finds the step ratio range and sorts step ratios&lt;br /&gt;
function p.preprocess_step_ratios(step_ratios)&lt;br /&gt;
	local step_ratios = p.sort_step_ratios(step_ratios)&lt;br /&gt;
	local step_ratio_range = &amp;quot;&amp;quot;&lt;br /&gt;
	&lt;br /&gt;
	-- If the step ratios are 3/2, 2/1, and 3/1 in that order, then they are&lt;br /&gt;
	-- the simple step ratios: basic, hard, and soft.&lt;br /&gt;
	-- These should not be sorted, since the basic-hard-soft sorting is a little&lt;br /&gt;
	-- more intuitive than sorting by hardness.&lt;br /&gt;
	if #step_ratios == 3 then&lt;br /&gt;
		if step_ratios[1][1] == 3 and step_ratios[1][2] == 2&lt;br /&gt;
			and step_ratios[2][1] == 2 and step_ratios[2][2] == 1&lt;br /&gt;
			and step_ratios[3][1] == 3 and step_ratios[3][2] == 1 then&lt;br /&gt;
			return &amp;quot;Simple Tunings&amp;quot;, {{2, 1}, {3, 1}, {3, 2}}&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- If there are multiple step ratios, find the step ratio range it&lt;br /&gt;
	-- corresponds to. If there is one step ratio, find the name of that&lt;br /&gt;
	-- hardness. If there are zero step ratios, then return &amp;quot;Tunings&amp;quot;&lt;br /&gt;
	if #step_ratios &amp;gt; 1 then&lt;br /&gt;
		local lower_ratio = step_ratios[1]&lt;br /&gt;
		local upper_ratio = step_ratios[#step_ratios]&lt;br /&gt;
		&lt;br /&gt;
		step_ratio_range = tamnams.find_step_ratio_range_for_ratio_pair(lower_ratio, upper_ratio)&lt;br /&gt;
		if step_ratio_range ~= nil then&lt;br /&gt;
			step_ratio_range = p.capitalize_first(step_ratio_range) .. &amp;quot; Tunings&amp;quot;&lt;br /&gt;
		else&lt;br /&gt;
			step_ratio_range = &amp;quot;Tunings&amp;quot;&lt;br /&gt;
		end&lt;br /&gt;
	elseif #step_ratios == 1 then&lt;br /&gt;
		step_ratio_range = tamnams.lookup_step_ratio(step_ratios[1])&lt;br /&gt;
		if step_ratio_range ~= nil then&lt;br /&gt;
			step_ratio_range = p.capitalize_first(step_ratio_range) .. &amp;quot; Tuning&amp;quot;&lt;br /&gt;
		else&lt;br /&gt;
			step_ratio_range = string.format(&amp;quot;%s/%s&amp;quot;, step_ratios[1][1], step_ratios[1][2]) .. &amp;quot; Tuning&amp;quot;&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		step_ratio_range = &amp;quot;Tunings&amp;quot;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return step_ratio_range, step_ratios&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Preprocess step ratios&lt;br /&gt;
function p.preprocess_ji_ratios(input_mos, modal_union, step_ratios, ji_ratios, tolerance)&lt;br /&gt;
&lt;br /&gt;
	-- Calculate the avegrage step ratio&lt;br /&gt;
	local avg_step_ratio = {0, 0}&lt;br /&gt;
	for i = 1, #step_ratios do&lt;br /&gt;
		avg_step_ratio[1] = avg_step_ratio[1] + step_ratios[i][1]&lt;br /&gt;
		avg_step_ratio[2] = avg_step_ratio[2] + step_ratios[i][2]&lt;br /&gt;
	end&lt;br /&gt;
	avg_step_ratio[1] = avg_step_ratio[1] / #step_ratios&lt;br /&gt;
	avg_step_ratio[2] = avg_step_ratio[2] / #step_ratios&lt;br /&gt;
&lt;br /&gt;
	-- Normalize step ratio to be x:1, accounting for 1:0&lt;br /&gt;
	if avg_step_ratio[2] ~= 0 then&lt;br /&gt;
		avg_step_ratio[1] = avg_step_ratio[1] / avg_step_ratio[2]&lt;br /&gt;
		avg_step_ratio[2] = avg_step_ratio[2] / avg_step_ratio[2]&lt;br /&gt;
	else&lt;br /&gt;
		avg_step_ratio[1] = 1&lt;br /&gt;
		avg_step_ratio[2] = 0&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Calculate the tolerance, the range in which ratios can be accepted +/-&lt;br /&gt;
	-- from an et-step. (ET may be a non-integer value, since the L:s ratio is&lt;br /&gt;
	-- normalized to x:1.)&lt;br /&gt;
	-- Tolerance is how many cents away from an et-step a ratio can be. This is&lt;br /&gt;
	-- by default 30% of the small step size, and maxes out at 30 cent. Can be&lt;br /&gt;
	-- overridden with a custom tolerance value.&lt;br /&gt;
	local steps_in_et = input_mos.nL * avg_step_ratio[1] + input_mos.ns * avg_step_ratio[2]&lt;br /&gt;
	local tolerance = tolerance or math.min((mos.equave_to_cents(input_mos) / steps_in_et) * 0.30, 30)&lt;br /&gt;
	&lt;br /&gt;
	-- Calculate the cent values for each interval in the modal union&lt;br /&gt;
	local cent_values = {}&lt;br /&gt;
	for i = 1, #modal_union do&lt;br /&gt;
		table.insert(cent_values, mos.interval_to_cents(modal_union[i], input_mos, avg_step_ratio))&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	local sorted_ratios = jira.sort_by_closeness_to_cent_values(ji_ratios, cent_values, tolerance)&lt;br /&gt;
	&lt;br /&gt;
	return sorted_ratios&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Main function&lt;br /&gt;
function p._mos_tunings(input_mos, mos_prefix, mos_abbrev, step_ratios, ji_ratios, tolerance, footnotes, is_collapsed)&lt;br /&gt;
	local input_mos = input_mos or mos.new(5,2)&lt;br /&gt;
	local mos_prefix = mos_prefix or &amp;quot;mos&amp;quot;&lt;br /&gt;
	local mos_abbrev = mos_abbrev or &amp;quot;m&amp;quot;&lt;br /&gt;
	local step_ratios = step_ratios or {{2, 1}, {3, 1}, {3, 2}}&lt;br /&gt;
	local ji_ratios = ji_ratios or {}&lt;br /&gt;
	local tolerance = tolerance or nil&lt;br /&gt;
	local is_collapsed = is_collapsed == true&lt;br /&gt;
	local footnotes = footnotes or &amp;quot;(footnotes here)&amp;quot;&lt;br /&gt;
	&lt;br /&gt;
	-- Scalesig&lt;br /&gt;
	local scale_sig = mos.as_string(input_mos)&lt;br /&gt;
	&lt;br /&gt;
	-- Sort/preprocess step ratios&lt;br /&gt;
	local step_ratio_range = &amp;quot;&amp;quot;&lt;br /&gt;
	step_ratio_range, step_ratios = p.preprocess_step_ratios(step_ratios)&lt;br /&gt;
	&lt;br /&gt;
	-- Preprocess JI ratios&lt;br /&gt;
	local modal_union = mos.modal_union(input_mos)&lt;br /&gt;
	--local sorted_ji_ratios, search_info = p.preprocess_ji_ratios(input_mos, modal_union, step_ratios, ji_ratios, tolerance)&lt;br /&gt;
	&lt;br /&gt;
	-- Create table&lt;br /&gt;
	local result = &amp;quot;{| class=\&amp;quot;wikitable sortable right-all left-1 left-2 mw-collapsible&amp;quot; .. (is_collapsed and &amp;quot; mw-collapsed\&amp;quot;\n&amp;quot; or &amp;quot;\&amp;quot;\n&amp;quot;)&lt;br /&gt;
	&lt;br /&gt;
	-- Table caption&lt;br /&gt;
	result = result	.. &amp;quot;|+ style=\&amp;quot;font-size: 105%; white-space: nowrap;\&amp;quot; | &amp;quot; .. string.format(&amp;quot;%s of %s\n&amp;quot;, step_ratio_range, scale_sig)&lt;br /&gt;
		.. &amp;quot;|-\n&amp;quot;&lt;br /&gt;
	&lt;br /&gt;
	-- First row of headers&lt;br /&gt;
	-- First two headers span two rows&lt;br /&gt;
	result = result&lt;br /&gt;
		.. &amp;quot;! rowspan=\&amp;quot;2\&amp;quot; class=\&amp;quot;unsortable\&amp;quot; | 音階の度数\n&amp;quot;&lt;br /&gt;
		.. &amp;quot;! rowspan=\&amp;quot;2\&amp;quot; class=\&amp;quot;unsortable\&amp;quot; | Abbrev.\n&amp;quot;&lt;br /&gt;
	&lt;br /&gt;
	-- Headers for tunings; these span two cols&lt;br /&gt;
	for i = 1, #step_ratios do&lt;br /&gt;
		local step_ratio_as_text = tamnams.lookup_step_ratio(step_ratios[i])&lt;br /&gt;
		if step_ratio_as_text == nil then&lt;br /&gt;
			step_ratio_as_text = string.format(&amp;quot;%s:%s&amp;quot;, step_ratios[i][1], step_ratios[i][2])&lt;br /&gt;
		else&lt;br /&gt;
			step_ratio_as_text = p.capitalize_first(step_ratio_as_text) .. string.format(&amp;quot; (%s:%s)&amp;quot;, step_ratios[i][1], step_ratios[i][2])&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		local et_as_string = et.as_string(mos.as_et(input_mos, step_ratios[i]))&lt;br /&gt;
		local header_text = string.format(&amp;quot;%s&amp;lt;br /&amp;gt;[[%s]]&amp;quot;, step_ratio_as_text, et_as_string)&lt;br /&gt;
		result = result .. string.format(&amp;quot;! colspan=\&amp;quot;2\&amp;quot; | %s\n&amp;quot;, header_text)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Headers for JI ratios; this spans two rows&lt;br /&gt;
	-- Commented out, pending rewrite&lt;br /&gt;
	--[[&lt;br /&gt;
	if #ji_ratios ~= 0 then&lt;br /&gt;
		result = result .. &amp;quot;! rowspan=\&amp;quot;2\&amp;quot; class=\&amp;quot;unsortable\&amp;quot; | Approx. ratios*\n&amp;quot;&lt;br /&gt;
	end&lt;br /&gt;
	]]--&lt;br /&gt;
	result = result .. &amp;quot;|-\n&amp;quot;&lt;br /&gt;
	&lt;br /&gt;
	-- Second row of headers&lt;br /&gt;
	for i = 1, #step_ratios do&lt;br /&gt;
		result = result .. &amp;quot;! style=\&amp;quot;border-right: none;\&amp;quot; class=\&amp;quot;unsortable\&amp;quot; | ステップ地\n&amp;quot;&lt;br /&gt;
		result = result .. &amp;quot;! style=\&amp;quot;border-left: none; text-align: right;\&amp;quot; | セント値\n&amp;quot;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- Add a row for each scale degree&lt;br /&gt;
	for i = 1, #modal_union do&lt;br /&gt;
		local interval = modal_union[i]&lt;br /&gt;
		&lt;br /&gt;
		-- Add cells for the degree names&lt;br /&gt;
		local degree_name   = tamnams.degree_quality(interval, input_mos, &amp;quot;sentence-case&amp;quot;, mos_prefix)&lt;br /&gt;
		local degree_abbrev = tamnams.degree_quality(interval, input_mos, &amp;quot;abbrev&amp;quot;       , mos_abbrev)&lt;br /&gt;
		&lt;br /&gt;
		result = result&lt;br /&gt;
			.. &amp;quot;|-\n&amp;quot;&lt;br /&gt;
			.. string.format(&amp;quot;| %s\n&amp;quot;, degree_name)&lt;br /&gt;
			.. string.format(&amp;quot;| %s\n&amp;quot;, degree_abbrev)&lt;br /&gt;
	&lt;br /&gt;
		-- Add cells for each interval&amp;#039;s tunings&lt;br /&gt;
		for j = 1, #step_ratios do&lt;br /&gt;
			local step_ratio = step_ratios[j]&lt;br /&gt;
			local step_count = mos.interval_to_et_steps(interval, step_ratio)&lt;br /&gt;
			local cents = mos.interval_to_cents(interval, input_mos, step_ratio)&lt;br /&gt;
			&lt;br /&gt;
			result = result&lt;br /&gt;
				--.. string.format(&amp;quot;\n| %s\\%s\n| %.1f&amp;quot;, step_count, input_mos.nL * step_ratio[1] + input_mos.ns * step_ratio[2], cents)&lt;br /&gt;
				.. string.format(&amp;quot;| style=\&amp;quot;border-right: none;\&amp;quot; | %s\\%s\n&amp;quot;, step_count, input_mos.nL * step_ratio[1] + input_mos.ns * step_ratio[2])&lt;br /&gt;
				.. string.format(&amp;quot;| style=\&amp;quot;border-left: none;\&amp;quot; | %.1f\n&amp;quot;, cents)&lt;br /&gt;
		end&lt;br /&gt;
		&lt;br /&gt;
		-- Add cells for JI ratios&lt;br /&gt;
		--[[&lt;br /&gt;
		-- Commented out, pending rewrite&lt;br /&gt;
		if #ji_ratios ~= 0 then&lt;br /&gt;
			-- Ratios link to their respective pages, and are comma-delimited.&lt;br /&gt;
			local ratios_as_text = jira.ratios_as_string(sorted_ji_ratios[i], true, &amp;quot;,&amp;amp;nbsp;&amp;quot;)&lt;br /&gt;
			result = result .. &amp;quot;| style=\&amp;quot;text-align: left;\&amp;quot; | &amp;quot; .. string.format(&amp;quot;%s\n&amp;quot;, ratios_as_text)&lt;br /&gt;
		end&lt;br /&gt;
		]]--&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	-- End of table, plus footnotes&lt;br /&gt;
	result = result .. &amp;quot;|}&amp;quot;&lt;br /&gt;
&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Commented out, pending rewrite&lt;br /&gt;
	if #ji_ratios ~= 0 then&lt;br /&gt;
		-- Make footnote text smaller than the rest of the text to avoid confusion with paragraph text&lt;br /&gt;
		result = result .. string.format(&amp;quot;&amp;lt;span style=\&amp;quot;font-size: 0.75em;\&amp;quot;&amp;gt;&amp;amp;#42; %s&amp;lt;/span&amp;gt;&amp;quot;, footnotes)&lt;br /&gt;
	end&lt;br /&gt;
	]]--&lt;br /&gt;
	&lt;br /&gt;
	return result&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Parse step ratios passed into template&lt;br /&gt;
-- If the unparsed string is blank, default to the simple tunings.&lt;br /&gt;
-- If the unparsed string is any of the step ratio range names, list the named&lt;br /&gt;
-- ratios that fall within that range.&lt;br /&gt;
-- if the unparsed string is blank, don&amp;#039;t show any ratios.&lt;br /&gt;
-- If the ratios is a list, parse it.&lt;br /&gt;
function p.parse_step_ratios(unparsed)&lt;br /&gt;
	local parsed = {}&lt;br /&gt;
	&lt;br /&gt;
	local lookup_table = {&lt;br /&gt;
		[&amp;quot;Central Spectrum&amp;quot;] = {{4, 3}, {3, 2}, {5, 3}, {2, 1}, {5, 2}, {3, 1}, {4, 1}},&lt;br /&gt;
		[&amp;quot;Simple Tunings&amp;quot;]   = {{2, 1}, {3, 1}, {3, 2}},&lt;br /&gt;
		[&amp;quot;Soft-of-basic&amp;quot;]    = {{4, 3}, {3, 2}, {2, 1}},&lt;br /&gt;
		[&amp;quot;Ultrasoft&amp;quot;]        = {{6, 5}, {5, 4}, {4, 3}},&lt;br /&gt;
		[&amp;quot;Parasoft&amp;quot;]		 = {{4, 3}, {7, 5}, {3, 2}},&lt;br /&gt;
		[&amp;quot;Quasisoft&amp;quot;]        = {{3, 2}, {8, 5}, {5, 3}},&lt;br /&gt;
		[&amp;quot;Minisoft&amp;quot;]         = {{5, 3}, {7, 4}, {2, 1}},&lt;br /&gt;
		[&amp;quot;Hyposoft&amp;quot;]         = {{3, 2}, {5, 3}, {2, 1}},&lt;br /&gt;
		[&amp;quot;Hypohard&amp;quot;]         = {{2, 1}, {5, 2}, {3, 1}},&lt;br /&gt;
		[&amp;quot;Minihard&amp;quot;]         = {{2, 1}, {7, 3}, {5, 2}},&lt;br /&gt;
		[&amp;quot;Quasihard&amp;quot;]        = {{5, 2}, {8, 3}, {3, 1}},&lt;br /&gt;
		[&amp;quot;Parahard&amp;quot;]         = {{3, 1}, {7, 2}, {4, 1}},&lt;br /&gt;
		[&amp;quot;Ultrahard&amp;quot;]        = {{4, 1}, {5, 1}, {6, 1}},&lt;br /&gt;
		[&amp;quot;Hard-of-basic&amp;quot;]    = {{2, 1}, {3, 1}, {4, 1}},&lt;br /&gt;
	}&lt;br /&gt;
	&lt;br /&gt;
	if unparsed == &amp;quot;&amp;quot; then&lt;br /&gt;
		parsed = lookup_table[&amp;quot;Simple Tunings&amp;quot;]&lt;br /&gt;
	elseif unparsed == &amp;quot;NONE&amp;quot; then&lt;br /&gt;
		parsed = {}&lt;br /&gt;
	else&lt;br /&gt;
		parsed = lookup_table[unparsed] or tip.parse_numeric_pairs(unparsed)&lt;br /&gt;
	end&lt;br /&gt;
	return parsed&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Parse JI ratios passed into template&lt;br /&gt;
-- If the unparsed string corresponds to a list of JI ratios (&amp;quot;a/b; c/d; e/f&amp;quot;),&lt;br /&gt;
-- then parse it as a list of ratios. If it&amp;#039;s not that, parse it as search&lt;br /&gt;
-- args. If the text is &amp;quot;NONE&amp;quot;, then there should be no ratios passed in.&lt;br /&gt;
-- If the unparsed string is an empty string, return nil. (This is so the&lt;br /&gt;
-- wrapper function can go by default search args.)&lt;br /&gt;
function p.parse_ji_ratios(unparsed, equave)&lt;br /&gt;
	local ratios = nil&lt;br /&gt;
	local search_args = nil&lt;br /&gt;
	&lt;br /&gt;
	if unparsed == &amp;quot;&amp;quot; then&lt;br /&gt;
		search_args = {[&amp;quot;Int Limit&amp;quot;] = 50, [&amp;quot;Tenney Height&amp;quot;] = 8; [&amp;quot;Complements Only&amp;quot;] = true}		-- Defualt search args if no args were passed in&lt;br /&gt;
		ratios = jira.search_by_args_within_equave(equave, search_args)&lt;br /&gt;
	elseif unparsed == &amp;quot;NONE&amp;quot; then&lt;br /&gt;
		search_args = {}&lt;br /&gt;
		ratios = {}&lt;br /&gt;
	elseif string.match(unparsed, &amp;quot;Int Limit:&amp;quot;) then&lt;br /&gt;
		search_args = jira.parse_search_args(unparsed)	-- Search requires at the absolute least an int limit, so see if there&amp;#039;s &amp;quot;Int Limit&amp;quot;&lt;br /&gt;
		ratios = jira.search_by_args_within_equave(equave, search_args)&lt;br /&gt;
	else&lt;br /&gt;
		search_args = {}&lt;br /&gt;
		ratios = jira.parse_ratios(unparsed)&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return ratios, jira.search_footnotes(search_args)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Wrapper function; to be called by template&lt;br /&gt;
function p.mos_tunings(frame)&lt;br /&gt;
	-- Get params&lt;br /&gt;
	local scalesig     = frame.args[&amp;quot;Scale Signature&amp;quot;]&lt;br /&gt;
	local input_mos    = mos.parse(scalesig)&lt;br /&gt;
	local mos_prefix   = tamnams.verify_prefix(input_mos, frame.args[&amp;quot;MOS Prefix&amp;quot;])&lt;br /&gt;
	local mos_abbrev   = tamnams.verify_abbrev(input_mos, frame.args[&amp;quot;MOS Abbrev&amp;quot;])&lt;br /&gt;
	local is_collapsed = yesno(frame.args[&amp;quot;Collapsed&amp;quot;], false)&lt;br /&gt;
	local step_ratios  = p.parse_step_ratios(frame.args[&amp;quot;Step Ratios&amp;quot;])&lt;br /&gt;
	local tolerance    = tonumber(frame.args[&amp;quot;Tolerance&amp;quot;])&lt;br /&gt;
	local debugg       = yesno(frame.args[&amp;quot;debug&amp;quot;])&lt;br /&gt;
	&lt;br /&gt;
	--local ji_ratios, footnotes = p.parse_ji_ratios(frame.args[&amp;quot;JI Ratios&amp;quot;], input_mos.equave)&lt;br /&gt;
&lt;br /&gt;
	local result = p._mos_tunings(input_mos, mos_prefix, mos_abbrev, step_ratios, ji_ratios, tolerance, footnotes, is_collapsed)&lt;br /&gt;
	if debugg == true then&lt;br /&gt;
		result = &amp;quot;&amp;lt;syntaxhighlight lang=\&amp;quot;wikitext\&amp;quot;&amp;gt;&amp;quot; .. result .. &amp;quot;&amp;lt;/syntaxhighlight&amp;gt;&amp;quot;&lt;br /&gt;
	end&lt;br /&gt;
	&lt;br /&gt;
	return frame:preprocess(result)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.tester()&lt;br /&gt;
	local range, ratios = p.preprocess_step_ratios({{7, 1}, {3, 1}, {2, 1}})&lt;br /&gt;
	local input_mos = mos.parse(&amp;quot;9L 4s&amp;lt;7/2&amp;gt;&amp;quot;)&lt;br /&gt;
	&lt;br /&gt;
	--return p.preprocess_ji_ratios(input_mos, mos.modal_union(input_mos), {{2,1}, {3,2}, {5,3}}, ji_ratios)&lt;br /&gt;
	--return ji_ratios&lt;br /&gt;
	return p._mos_tunings(input_mos)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Furcht968</name></author>
	</entry>
</feed>