MOS substitution: Difference between revisions

Inthar (talk | contribs)
Inthar (talk | contribs)
Line 7: Line 7:
Let <math>M_{a,b}(x,y;k)</math> be the mode of axby that would have brightness k if x were L and y were s. For example, <math>M_{a,b}(5,2;5)(x,y) = xxyxxxy.</math> Let <math> n = a+b+c</math> and <math>q = a + c</math> (resp. <math>b + c</math>).
Let <math>M_{a,b}(x,y;k)</math> be the mode of axby that would have brightness k if x were L and y were s. For example, <math>M_{a,b}(5,2;5)(x,y) = xxyxxxy.</math> Let <math> n = a+b+c</math> and <math>q = a + c</math> (resp. <math>b + c</math>).


The following holds for <math>S = \mathsf{mos\_subst\_aberrize}(a, b, L, c, k)</math> (resp. <math>\mathsf{mos\_subst\_aberrize}(a, b, m, c, k)</math>):
The following holds for <math>S = \mathsf{mos\_subst\_aberrize}(a, b, L, c, k)</math> (and mutatis mutandis, also for <math>\mathsf{mos\_subst\_aberrize}(a, b, m, c, k)</math> as well):


# If the template MOS <math>T = T(m,X) = M_{b,n}(m,X;n-1)</math> (resp. <math>T(L,X)=M_{a, b+c}(L,X;n-1)</math>) is primitive, let <math>r</math> the count of X steps in a chosen (reduced) generator of <math>T.</math> Since <math>r</math> must be coprime to <math>n</math>, <math>r</math>-steps in the filling MOS <math>F = M_{a,c}(L,s;k)</math> (resp. <math>M_{b,c}(m,s;k)</math>) come in exactly 2 sizes, <math>iL+js</math> and <math>(i-1)L+(j+1)s</math> (resp. <math>im+js</math> and <math>(i-1)m+(j+1)s</math>), and taking this generator of <math>T</math> results in a [[generator sequence]] of length <math>q</math>. Letting <math>\mathsf{GS}(g_1, ..., g_{q})</math> be this generator sequence, <math>g_j</math> is either <math>pm + iL + js</math> or <math>pm + (i-1)L + (j+1)s,</math> (resp. <math>pL + im + js</math> or <math>pL + (i-1)m + (j+1)s,</math>) according as the ''j''-th ''r''-step in the sequence of stacked <math>r</math>-steps in the chosen mode of <math>F</math> is <math>iL + js</math> or <math>(i-1)L + (j+1)s</math> (resp. <math>im + js</math> or <math>(i-1)m + (j+1)s</math>). (We could have chosen to use the "darkest" mode of <math>T</math> instead, which corresponds to taking the circle of (''n &minus; r'')-steps in ''F'' and is thus also valid.)
# If the template MOS <math>T = T(m,X) = M_{b,n}(m,X;n-1)</math> is primitive, let <math>r</math> the count of X steps in a chosen (reduced) generator of <math>T.</math> Since <math>r</math> must be coprime to <math>n</math>, <math>r</math>-steps in the filling MOS <math>F = M_{a,c}(L,s;k)</math> come in exactly 2 sizes, <math>iL+js</math> and <math>(i-1)L+(j+1)s</math>, and taking this generator of <math>T</math> results in a [[generator sequence]] of length <math>q</math>. Letting <math>\mathsf{GS}(g_1, ..., g_{q})</math> be this generator sequence, <math>g_j</math> is either <math>pm + iL + js</math> or <math>pm + (i-1)L + (j+1)s,</math> according as the ''j''-th ''r''-step in the sequence of stacked <math>r</math>-steps in the chosen mode of <math>F</math> is <math>iL + js</math> or <math>(i-1)L + (j+1)s</math> (We could have chosen to use the "darkest" mode of <math>T</math> instead, which corresponds to taking the circle of (''n &minus; r'')-steps in ''F'' and is thus also valid.)
# Suppose that the perfect generator of ''T'' that we use subtends r < |T|/2 steps. Assume without loss of generality that the template MOS identifies L and s steps. Suppose the perfect generator is tL + us and the imperfect generator is (t - 1)L + (u + 1)s. Then the interval class of (r + 1)-steps has either (a) tL + (u + 1)s and (t - 1)L + (u + 2)s, or (b) tL + (u + 1)s and (t + 1)L + us.
# Suppose that the perfect generator of ''T'' that we use subtends r < |T|/2 steps. Suppose the perfect generator is tL + us and the imperfect generator is (t - 1)L + (u + 1)s. Then the interval class of (r + 1)-steps has either (a) tL + (u + 1)s and (t - 1)L + (u + 2)s, or (b) tL + (u + 1)s and (t + 1)L + us.
#* In case (a), S becomes a mos after deleting s steps for any k in {0, ..., q-1}.
#* In case (a), S becomes a mos after deleting s steps for any k in {0, ..., q-1}.
#* In case (b), S becomes a mos after deleting s steps for k = 0, ..., v, where v is the number of generators stacked to obtain (t + 1)L + us in the filling MOS F.
#* In case (b), S becomes a mos after deleting s steps for k = 0, ..., v, where v is the number of generators stacked to obtain (t + 1)L + us in the filling MOS F.