User Rating 0.0
Total Usage 0 times
8
Presets:
Is this tool helpful?

Your feedback helps us improve.

About

Pentanacci words belong to the family of k-bonacci words - strings constructed by iterated morphism over a finite alphabet. The Pentanacci recurrence defines each term as the sum of the five preceding terms: L(n) = L(n1) + L(n2) + L(n3) + L(n4) + L(n5). The morphism operates on a 5-letter alphabet {1, 2, 3, 4, 5} with substitution rules σ(1) = 12, σ(2) = 13, σ(3) = 14, σ(4) = 15, σ(5) = 1. Incorrect construction leads to sequences that do not satisfy the Pentanacci length recurrence and corrupts downstream analysis of factor complexity or balance properties.

This tool computes exact Pentanacci words up to iteration 12. Beyond that, word lengths exceed millions of characters and become impractical for browser memory. The tool also supports generalized k-bonacci orders from 2 (Fibonacci) through 7 (Heptanacci). Note: letter frequency ratios converge to the roots of the characteristic polynomial x5 x4 x3 x2 x 1 = 0, not to simple rational values.

pentanacci fibonacci words morphism substitution sequence combinatorics on words k-bonacci tribonacci

Formulas

The k-bonacci morphism σ acts on a k-letter alphabet. For Pentanacci (k = 5), the substitution rules are:

{
σ(1) = 12σ(2) = 13σ(3) = 14σ(4) = 15σ(5) = 1

Starting from the axiom w0 = 1, each iteration applies σ to every letter of the current word: wn+1 = σ(wn). The word length L(n) satisfies the Pentanacci recurrence:

L(n) = 5i=1 L(n i)

The substitution matrix M whose dominant eigenvalue ρ governs asymptotic growth is:

M = 1111110000010000010000010

where ρ 1.96595 is the unique real root of the characteristic polynomial x5 x4 x3 x2 x 1 = 0 greater than 1. The letter frequencies fi converge to the left eigenvector of M normalized to sum 1.

where σ = morphism (substitution function), wn = word at iteration n, L(n) = length of wn, M = substitution (incidence) matrix, ρ = Pisot number (dominant eigenvalue), fi = asymptotic frequency of letter i.

Reference Data

Order kNameAlphabet SizeMorphism RulesGrowth Rate ρIteration 5 LengthIteration 8 LengthIteration 10 Length
2Fibonacci2σ(1)=12, σ(2)=11.61801355144
3Tribonacci3σ(1)=12, σ(2)=13, σ(3)=11.8393312741330
4Tetranacci4σ(1)=12, σ(2)=13, σ(3)=14, σ(4)=11.9275639127280
5Pentanacci5σ(1)=12, σ(2)=13, σ(3)=14, σ(4)=15, σ(5)=11.9659127291237120
6Hexanacci6σ(1)=12, ... σ(6)=11.98362559198186114
7Heptanacci7σ(1)=12, ... σ(7)=11.992051128925924199
Pentanacci Sequence (first 15 terms)
n1, 1, 1, 1, 1, 5, 9, 17, 33, 65, 129, 253, 497, 977, 1921
Pentanacci Word Lengths by Iteration
Iter 0Length 1Iter 1Length 2Iter 2Length 3
Iter 3Length 5Iter 4Length 9Iter 5Length 17
Iter 6Length 33Iter 7Length 65Iter 8Length 129
Iter 9Length 253Iter 10Length 497Iter 11Length 977
Iter 12Length 1921Iter 13Length 3777Iter 14Length 7425

Frequently Asked Questions

The length of the word at iteration n equals the (n+1)-th Pentanacci number when using initial conditions L(0)=1, L(1)=2, L(2)=3, L(3)=5, L(4)=9. Each subsequent length is the sum of the five preceding lengths. This is a direct consequence of the substitution matrix: letters of type 1 through 4 each produce 2 letters, while letter 5 produces 1. The total count follows the recurrence exactly.
They converge to components of the normalized left eigenvector of the 5×5 substitution matrix M associated with the Pisot eigenvalue ρ ≈ 1.96595. For Pentanacci, letter 1 dominates at roughly 50.86% frequency, letter 2 at ~25.87%, letter 3 at ~13.16%, letter 4 at ~6.69%, and letter 5 at ~3.41%. Convergence is geometric with rate equal to the ratio of the second-largest eigenvalue modulus to ρ.
Pentanacci word length grows as ρ^n ≈ 1.966^n. At iteration 12 the word has 1,921 characters. At iteration 15 it exceeds 14,000. At iteration 20 it surpasses 500,000. JavaScript strings and DOM rendering become impractical beyond ~1 million characters in a browser tab. The tool caps at iteration 12 for full display and allows up to 18 for analysis-only mode where only statistics are computed without rendering the full string.
The classic Fibonacci word uses a 2-letter alphabet {0,1} with σ(0)=01, σ(1)=0. The k-bonacci generalization uses a k-letter alphabet {1,...,k} with σ(i)=1(i+1) for i
Yes. Like Fibonacci words encoding Penrose-type 1D quasicrystals, k-bonacci words encode substitution tilings in one dimension. The Pentanacci word defines an aperiodic sequence with pure point diffraction spectrum. The Pisot property of the dominant eigenvalue (ρ ≈ 1.966 is a Pisot number since all conjugate roots have modulus less than 1) guarantees this spectral purity. Physical applications include modeling multilayer optical filters with non-periodic but deterministic structure.
Yes. The tool allows starting from any single letter in the alphabet. Starting from letter j means w₀ = j, and σ is applied from there. The resulting word is a suffix or subword of the infinite fixed point only if you start from letter 1. Starting from other letters produces valid k-bonacci substitution sequences but with different prefix structure. The length recurrence still holds after a transient of k initial terms.