OFFSET
1,2
COMMENTS
From Jon E. Schoenfield, Dec 23 2017: (Start)
Starting with the sequence S_0 = {1,2} and extending it one pass at a time as described at A293630 (obtaining S_1 = {1,2,1,1}, S_2 = {1,2,1,1,1,2,1}, etc.), let n_j be the number of terms in S_j; then for j=0,1,2,..., n_j = 2, 4, 7, 13, 37, 73, 145, 289, 865, 1729, 3457, 10369, 20737, 41473, 82945, 248833, 497665, ... (see A291481).
In the algorithm implemented in the PARI program, the variable "build" specifies the number of passes during which the terms of S_j are actually built and stored. The algorithm then uses the terms of S_build to compute the number (n_j) of terms in S_j and their total value (t_j) for each j in build+1..build+n_build. For build=0,1,2,..., the number of decimal digits to which the final ratio t_j/n_j at j = build + n_build matches the actual limit 1.275261842... is 2, 3, 4, 7, 15, 29, 54, 105, 306, 608, 1213, 3629, 7253, 14501, 28995, 86974, 173941, ...
Thus, for example, using build=7, the number of 1s and 2s in the last sequence actually stored, i.e., S_7, is 289, but the number of terms n_j and their total value t_j are computed for every j up through j = build+n_build = 7 + n_7 = 7 + 289 = 296 (both n_296 and t_296 are 104-digit numbers) and the final ratio t_296/n_296 matches the actual limit to 105 decimal digits. (End)
From Iain Fox, Dec 23 2017: (Start)
This is the average value of A293630 on the interval n = 1..infinity.
Is this number transcendental? (End)
LINKS
Iain Fox, Table of n, a(n) for n = 1..20000
EXAMPLE
Equals 1.2752618420911721359284772047801515149347600371...
After generating k steps of A293630:
k = 0: [1, 2]; 1.500000000000...
k = 1: [1, 2, 1, 1]; 1.250000000000...
k = 2: [1, 2, 1, 1, 1, 2, 1]; 1.285714285714...
k = 3: [1, 2, 1, 1, 1, 2, ...]; 1.307692307692...
k = 4: [1, 2, 1, 1, 1, 2, ...]; 1.270270270270...
k = 5: [1, 2, 1, 1, 1, 2, ...]; 1.273972602739...
k = 6: [1, 2, 1, 1, 1, 2, ...]; 1.275862068965...
...
k = infinity: [1, 2, 1, 1, 1, 2, ...]; 1.275261842091...
PROG
(PARI) gen(build) = {
my(S = [1, 2], n = 2, t = 3, L, nPrev, E);
print(S);
print(1.0*t/n);
for(j = 1, build, L = S[#S]; n = n*(1+L)-L; t = t*(1+L)-L^2; nPrev = #S; for(r = 1, L, for(i = 1, nPrev-1, S = concat(S, S[i]))); print(S); print(1.0*t/n));
E = S;
for(j = build + 1, build + #E, L = E[#E+1-(j-build)]; n = n*(1+L)-L; t = t*(1+L)-L^2; print(1.0*t/n));
} \\ (gradually increase build to get more precise answers) Iain Fox, Dec 23 2017 with help of Jon E. Schoenfield
CROSSREFS
KEYWORD
cons,nonn
AUTHOR
Iain Fox, Dec 15 2017
STATUS
approved