Keyboard shortcuts

Press ← or → to navigate between chapters

Press ? to show this help

Press Esc to hide this help

Unary and Reverse-Unary Native Insertion

Abstract

Gap masses identify native unary insertion minima in both ordered orientations.

Words and masks use the original ordered source schedule: the first source is inserted and the second is the base. The degree is the minimum number of maximal nonempty first-source runs over all actual masks, with infinity for an invalid output. Neither source roles nor minimum semantics are exchanged when passing to the reverse-unary case.

The inserted-unary gap, degree and spectrum arguments use Hughes arXiv v2, Section 11, Theorem 9: https://arxiv.org/abs/2608.27755v2. The reverse-unary and universal minimum-mask exchange statements are separate arguments.

Definition 1.1 (Occupied extra gaps).

Formalization. D5/S1/Words/HughesUnaryInsertion.occupied (✓ std3).

Source. Repository-derived.

Commentary.

Count strictly positive extra masses; a positive original gap with zero extra mass is unoccupied. Both outer gaps are included in this count.

Definition 1.2 (Occupied internal extra gaps).

Formalization. D5/S1/Words/HughesUnaryInsertion.internalOccupied (✓ std3).

Source. Repository-derived.

Commentary.

Discard the initial and terminal gap before counting. For zero or one non-a occurrences there are no internal gaps.

Definition 1.3 (Actual native shuffles).

Formalization. D5/S1/Words/HughesUnaryInsertion.Sh (✓ std3).

Source. Repository-derived.

Commentary.

Membership means an actual positional mask evaluates to the word and consumes both original sources. No separate ordinary-shuffle identification is used.

Definition 1.4 (Attained natural degrees).

Formalization. D5/S1/Words/HughesUnaryInsertion.spectrum (✓ std3).

Source. Repository-derived.

Commentary.

A natural value occurs only through an actual shuffle output with that native minimum; infinity contributes no natural spectrum value.

Theorem 1.5 (Inserted-unary unique gap masses).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.inserted_gap_iff (✓ std3). ∎

Citation. Charles E. Hughes (2026). Undecidability of Adjacent Equality for Insertion, Shuffle, and Crossover Language Operations. URL: https://arxiv.org/abs/2608.27755v1.

Commentary.

Non-a occurrences are forced to the base source. Every output has a unique nonnegative extra vector of total inserted length, and every such vector has a full native mask. Repeated separator letters remain indexed occurrences.

Theorem 1.6 (Reverse-unary unique gap masses).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.reverse_gap_iff (✓ std3). ∎

Source. Repository-derived.

Commentary.

Here non-a occurrences are forced to the inserted source. The same concatenation description retains all base mass, including both outer gaps.

Theorem 1.7 (Inserted-unary minimum and attainment).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.inserted_degree (✓ std3). ∎

Citation. Charles E. Hughes (2026). Undecidability of Adjacent Equality for Insertion, Shuffle, and Crossover Language Operations. URL: https://arxiv.org/abs/2608.27755v1.

Commentary.

Each occupied gap needs an inserted run because non-a letters separate gaps. The grouped mask puts each gap’s inserted letters together, reaches exactly that number of runs, and preserves both projections. This formalizes the occupied-gap proof of Hughes arXiv v2, Theorem 9, for arbitrary alphabets. For positive inserted length its convention agrees with native U-run degree; when that length is zero the native count is zero.

Theorem 1.8 (Reverse-unary internal minimum and attainment).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.reverse_degree (✓ std3). ∎

Source. Repository-derived.

Commentary.

With at least one non-a occurrence, every occupied internal gap separates forced inserted-source groups. The grouped construction places outer base material outside those groups, so the count is one plus occupied internal gaps. Original a copies in every gap remain part of the inserted projection.

Theorem 1.9 (Reverse-unary boundary cases).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.reverse_degree_all (✓ std3). ∎

Source. Repository-derived.

Commentary.

For no non-a occurrences, nonemptiness of the inserted source forces a positive unary length and the degree is one. With a single non-a occurrence there are no internal gaps, again giving degree one regardless of both outer extra masses. Both statements use the same actual source projections.

Theorem 1.10 (Every-mask inserted lower bound).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.inserted_trace_lower (✓ std3). ∎

Source. Repository-derived.

Commentary.

Non-a base occurrences separate the label lists of successive gaps. Each positive first-source count contributes at least one maximal U-run.

Theorem 1.11 (Every-mask reverse lower bound).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.reverse_trace_lower (✓ std3). ∎

Source. Repository-derived.

Commentary.

The first non-a occurrence forces an initial U-group. Every positive internal base count forces a further separator; exterior counts add none.

Theorem 1.12 (Full inserted-unary spectrum).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.inserted_spectrum (✓ std3). ∎

Citation. Charles E. Hughes (2026). Undecidability of Adjacent Equality for Insertion, Shuffle, and Crossover Language Operations. URL: https://arxiv.org/abs/2608.27755v1.

Commentary.

The spectrum is every integer from one to min(m, length(cs)+1), for m>0. Support is bounded by both total mass and gap count. To attain r, put one unit in r-1 gaps, the remaining positive mass in one gap, and zero elsewhere.

Theorem 1.13 (Full reverse-unary spectrum).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.reverse_spectrum (✓ std3). ∎

Source. Repository-derived.

Commentary.

For a nonempty inserted source the spectrum is every integer from one to 1+min(n, length(cs)-1), with truncated subtraction. Put one unit in each chosen internal gap and all remaining mass at an exterior end. For no non-a occurrences the only value is one.

Definition 1.14 (Equality in every inserted gap).

Formalization. D5/S1/Words/HughesUnaryInsertion.InsertedTight (✓ std3).

Source. Repository-derived.

Commentary.

This positional trace requires rho(b)=1 in each gap whose inserted count is positive, and rho(b)=0 otherwise. All non-a occurrences have label V. Thus each occupied indexed gap has exactly one whole U-run.

Definition 1.15 (Internal and terminal equality).

Formalization. D5/S1/Words/HughesUnaryInsertion.ReverseTailTight (✓ std3).

Source. Repository-derived.

Commentary.

An internal label gap has the form U^x V^e U^z, with all its base mass e in that single V-block. The terminal gap has form U^x V^y. The internal restart cost is one exactly when e>0, and the terminal restart cost is zero.

Definition 1.16 (Full reverse minimum structure).

Formalization. D5/S1/Words/HughesUnaryInsertion.ReverseTight (✓ std3).

Source. Repository-derived.

Commentary.

The initial gap is V^x U^y followed by its forced non-a U occurrence, and the remaining trace has the internal and terminal forms above. Every U segment attaches to a bounding non-a occurrence; there is no additional all-a U-run. Outer base material is retained in its actual position.

Theorem 1.17 (Every inserted-unary minimum mask).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.inserted_minimum_shape (✓ std3). ∎

Source. Repository-derived.

Commentary.

Comparison with the grouped attaining mask forces equality in each individual gap lower bound, for every minimum mask of the output.

Theorem 1.18 (Every reverse-unary minimum mask).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.reverse_minimum_shape (✓ std3). ∎

Source. Repository-derived.

Commentary.

With at least one non-a occurrence, equality forces the initial cost one and every internal and terminal cost to be tight. The binary label classification proves the displayed pure-block forms for every minimum mask.

Theorem 1.19 (Spectra of arbitrary actual source words).

Proof. Machine-checked in Lean as D5/S1/Words/HughesUnaryInsertion.spectra (✓ std3). ∎

Source. Repository-derived.

Commentary.

For arbitrary nonempty u,v and positive m,n, let s_a(x) be the number of non-a occurrences of the actual word x, counting repetitions. Then D(a^m,v)={r: 1<=r<=min(m,s_a(v)+1)} and D(u,a^n)={r: 1<=r<=1+min(n,s_a(u)-1)}. The occurrence count is recovered from the canonical presentation of each actual source word.

References