

A164126


First differences of A006995.


3



1, 2, 2, 2, 2, 6, 2, 4, 6, 4, 2, 12, 6, 12, 2, 8, 12, 8, 6, 8, 12, 8, 2, 24, 12, 24, 6, 24, 12, 24, 2, 16, 24, 16, 12, 16, 24, 16, 6, 16, 24, 16, 12, 16, 24, 16, 2, 48, 24, 48, 12, 48, 24, 48, 6, 48, 24, 48, 12, 48, 24, 48, 2, 32, 48, 32, 24, 32, 48, 32, 12, 32, 48, 32, 24, 32, 48, 32, 6
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,2


COMMENTS

From the formula section it follows that a(2^m  1 + 2^(m1)  k) = a(2^m  1 + k) for 0 <= k <= 2^(m1), as well as a(2^m  1 + 2^(m1)  k) = 2 for k=0, 2^(m1) and a(2^m  1 + 2^(m1)  k) = 6 for k=2^(m2), hence, starting from positions n=2^m1, the following 2^(m1) terms form symmetric tuples limited on the left and on the right by a '2' and always having a '6' as the center element.
Example: for n = 15 = 2^4  1, we have the (2^3+1)tuple (2,8,12,8,6,8,12,8,2).
Further on, since a(2^m  1 + 2^(m1) + k) = a(2^(m+1)  1  k) for 0 <= k <= 2^(m1) an analogous statement holds true for starting positions n = 2^m + 2^(m1)  1.
Example: for n = 23 = 2^4 + 2^3  1, we find the (2^3+1)tuple (2,24,12,24,6,24,12,24,2).
If we group the sequence terms according to the value of m=floor(log_2(n)), writing those terms together in separate lines and opening each new line for n >= 2^m + 2^(m1), then a kind of a 'logarithmic shaped' cone end will be formed, where both the symmetry and the calculation rules become obvious. The first 63 terms are depicted below:
1
2
2
2 2
6 2
4 6 4 2
12 6 12 2
8 12 8 6 8 12 8 2
24 12 24 6 24 12 24 2
16 24 16 12 16 24 16 6 16 24 16 12 16 24 16 2
48 24 48 12 48 24 48 6 48 24 48 12 48 24 48 2
.
(End)


LINKS



FORMULA

a(4*2^m  1) = a(6*2^m  1) = 2;
a(5*2^m  1) = a(7*2^m  1) = 6 (for m > 0);
Let m = floor(log_2(n)), then
Case 1: a(n) = 2, if n+1 = 2^(m+1) or n+1 = 3*2^(m1);
Case 2: a(n) = 2^(m1), if n = 0(mod 2) and n < 3*2^(m1);
Case 3: a(n) = 3*2^(m1), if n = 0(mod 2) and n >= 3*2^(m1);
Case 4: a(n) = 3*2^(m1)/gcd(n+12^m, 2^m), otherwise.
Cases 24 above can be combined as
Case 2': a(n) = (2  (1)^(n(n1)*floor(2*n/(3*2^m))))*2^(m1)/gcd(n+12^m, 2^m).
Recursion formula:
Let m = floor(log_2(n)); then
Case 1: a(n) = 2*a(n2^(m1)), if 2^m <= n < 2^m + 2^(m2)  1;
Case 2: a(n) = 6, if n = 2^m + 2^(m2)  1;
Case 3: a(n) = a(n2^(m2)), if 2^m + 2^(m2) <= n < 2^m + 2^(m1)  1;
Case 4: a(n) = 2, if n = 2^m + 2^(m1)  1;
Case 5: a(n) = (2 + (1)^n)*a(n2^(m1)), otherwise (which means 2^m + 2^(m1) <= n < 2^(m+1)).
(End)


EXAMPLE



MATHEMATICA

f[n_]:=FromDigits[RealDigits[n, 2][[1]]]==FromDigits[Reverse[RealDigits[n, 2][[1]]]]; a=1; lst={}; Do[If[f[n], AppendTo[lst, na]; a=n], {n, 1, 8!, 1}]; lst


CROSSREFS



KEYWORD

nonn,base,easy


AUTHOR



EXTENSIONS

a(1) changed to 1 and keyword:base added by R. J. Mathar, Aug 26 2009


STATUS

approved



