cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Previous Showing 11-20 of 22 results. Next

A077077 Trajectory of 775 under the Reverse and Add! operation carried out in base 2, written in base 10.

Original entry on oeis.org

775, 1674, 2325, 5022, 8919, 23976, 26757, 47376, 49581, 96048, 102669, 193056, 197469, 388704, 401949, 779328, 788157, 1563840, 1590333, 3131520, 3149181, 6273408, 6326397, 12554496, 12589821, 25129728, 25235709, 50274816, 50345469
Offset: 0

Views

Author

Klaus Brockhaus, Oct 25 2002

Keywords

Comments

The base 2 trajectory of 775 = A075252(5) provably does not contain a palindrome. A proof can be based on the formula given below.
lim_{n -> infinity} a(n)/a(n-1) = 1 for n mod 2 = 1.
lim_{n -> infinity} a(n)/a(n-1) = 2 for n mod 2 = 0.
Interleaving of A177843, 6*A177844, 3*A177845, 6*A177846.

Examples

			775 (decimal) = 1100000111 -> 1100000111 + 1110000011 = 11010001010 = 1674 (decimal).
		

Crossrefs

Cf. A058042 (trajectory of 22 in base 2, written in base 2), A061561 (trajectory of 22 in base 2), A075253 (trajectory of 77 in base 2), A075268 (trajectory of 442 in base 2), A077076 (trajectory of 537 in base 2), A075252 (trajectory of n in base 2 does not reach a palindrome and (presumably) does not join the trajectory of any term m < n).
Cf. A177843 (a(4*n)), A177844 (a(4*n+1)/6), A177845 (a(4*n+2)/3), A177846 (a(4*n+3)/6).

Programs

  • Haskell
    a077077 n = a077077_list !! n
    a077077_list = iterate a055944 775  -- Reinhard Zumkeller, Apr 21 2013
  • Magma
    trajectory:=function(init, steps, base) a:=init; S:=[a]; for n in [1..steps] do a+:= Seqint(Reverse(Intseq(a,base)),base); Append(~S, a); end for; return S; end function; trajectory(775, 28, 2);
    
  • Mathematica
    NestWhileList[# + IntegerReverse[#, 2] &, 775,  # !=
    IntegerReverse[#, 2] &, 1, 28] (* Robert Price, Oct 18 2019 *)
  • PARI
    trajectory(n,steps) = {local(v, k=n); for(j=0, steps, print1(k, ", "); v=binary(k); k+=sum(j=1, #v, 2^(j-1)*v[j]))};
    trajectory(775,28);
    

Formula

a(0), ..., a(5) as above; for n > 5 and
n = 2 (mod 4): a(n) = 3*2^(2*k+7)+273*2^k-3 where k = (n+6)/4;
n = 3 (mod 4): a(n) = 6*2^(2*k+7)-222*2^k where k = (n+5)/4;
n = 0 (mod 4): a(n) = 6*2^(2*k+7)+54*2^k-3 where k = (n+4)/4;
n = 1 (mod 4): a(n) = 12*2^(2*k+7)-282*2^k where k = (n+3)/4.
a(n) = -a(n-1)+2*a(n-2)+2*a(n-3)+2*a(n-4)+2*a(n-5)-4*a(n-6)-4*a(n-7)-3 for n > 12; a(0), ..., a(12) as above.
G.f.: (775+1674*x+1944*x^4+8910*x^5+4650*x^6-14508*x^7-19840*x^8-22644*x^9- 1860*x^10+28680*x^11+14328*x^12-2112*x^13) / ((1-x)*(1+x)*(1-2*x^2)*(1-2*x^4)).
G.f. for the sequence starting at a(6): 3*(8919+15792*x-10230*x^2- 15360*x^3-15358*x^4-31696*x^5+16668*x^6+31264*x^7) / ((1-x)*(1+x)*(1-2*x^2)*(1-2*x^4)).
a(n+1) = A055944(a(n)). - Reinhard Zumkeller, Apr 21 2013

Extensions

Comment edited, three comments and formula added, g.f. edited, PARI program revised, MAGMA program and crossrefs added by Klaus Brockhaus, May 14 2010

A062130 A062128 written in base 10.

Original entry on oeis.org

0, 1, 3, 3, 5, 5, 9, 7, 9, 9, 15, 27, 15, 27, 21, 15, 17, 17, 27, 99, 99, 21, -1, 63, 27, 99, -1, 27, -1, 63, 45, 31, 33, 33, 51, -1, 45, -1, 63, 99, 45, -1, 63, 99, 99, 45, -1, -1, 51, -1, 255, 51, 63, 99, 255, 153, 63, 99, 255, 153, -1, -1, 93, 63, 65, 65, 99, -1, 85, 255, 119, 387, 255, 73, 13299, -1, 387, -1, -1, 219, 85
Offset: 0

Views

Author

Klaus Brockhaus, Jun 06 2001

Keywords

Examples

			23 -> 23 + 29 = 52 -> 52 + 11 = 63, so a(23) = 63.
		

Crossrefs

Programs

  • ARIBAS
    stop := 500; for k := 0 to 80 do c := 0; m := k; rev := bit_reverse(m); while m <> rev and c < stop do inc(c); m := m + rev; rev := bit_reverse(m); end; if c < stop then write(m); else write(-1); end; write(" "); end;.
  • Mathematica
    limit = 10^4; (* Assumes that there is no palindrome if none is found before "limit" iterations *)
    Table[np = n; i = 0;
     While[np != IntegerReverse[np, 2] && i < limit,
      np = np + IntegerReverse[np, 2]; i++];
    If[i >= limit, -1, np], {n, 0, 80}] (* Robert Price, Oct 14 2019 *)

A171470 a(n) = 6*a(n-1) - 8*a(n-2) for n > 2; a(0) = 11, a(1) = 90, a(2) = 372.

Original entry on oeis.org

11, 90, 372, 1512, 6096, 24480, 98112, 392832, 1572096, 6289920, 25162752, 100657152, 402640896, 1610588160, 6442401792, 25769705472, 103079018496, 412316467200, 1649266655232, 6597068193792, 26388275920896
Offset: 0

Views

Author

Klaus Brockhaus, Dec 09 2009

Keywords

Comments

Related to Reverse and Add trajectory of 22 in base 2: A061561(4*n) = 2*a(n).
Binary representation of a(n) for n > 0 is given by the following production rules of the contextfree grammar: S -> 101 T 0, T -> 1 T 0 | 101. - A.H.M. Smeets, Feb 11 2019

Crossrefs

Programs

  • PARI
    {m=21; v=concat([11, 90, 372], vector(m-3)); for(n=4, m, v[n]=6*v[n-1]-8*v[n-2]); v}

Formula

a(n) = 24*4^n-3*2^n for n > 0.
G.f.: (1+4*x)*(11-20*x)/((1-2*x)*(1-4*x)).

A171471 a(n) = 6*a(n-1)-8*a(n-2)-9 for n > 2; a(0) = 35, a(1) = 225, a(2) = 837.

Original entry on oeis.org

35, 225, 837, 3213, 12573, 49725, 197757, 788733, 3150333, 12592125, 50350077, 201363453, 805380093, 3221372925, 12885196797, 51540197373, 206159609853, 824636080125, 3298539601917, 13194148970493, 52776577007613
Offset: 0

Views

Author

Klaus Brockhaus, Dec 09 2009

Keywords

Comments

Related to Reverse and Add trajectory of 22 in base 2: A061561(4*n+1) = a(n).

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{7,-14,8},{35,225,837,3213},30] (* Harvey P. Dale, Mar 22 2018 *)
  • PARI
    {m=22; v=concat([35, 225, 837], vector(m-3)); for(n=4, m, v[n]=6*v[n-1]-8*v[n-2]-9); v}

Formula

a(n) = 48*4^n+18*2^n-3 for n > 0.
G.f.: (35-20*x-248*x^2+224*x^3)/((1-x)*(1-2*x)*(1-4*x)).

A075299 Trajectory of 290 under the Reverse and Add! operation carried out in base 4, written in base 10.

Original entry on oeis.org

290, 835, 1610, 4195, 17060, 23845, 46490, 89080, 138125, 255775, 506510, 1238395, 5127260, 8616205, 15984335, 31949470, 79793675, 315404860, 569392925, 1060061935, 2114961710, 5206421995, 20997654620, 35262166285
Offset: 0

Views

Author

Klaus Brockhaus, Sep 12 2002

Keywords

Comments

290 is conjectured (cf. A066450) to be the smallest number such that the Reverse and Add! algorithm in base 4 does not lead to a palindrome. Unlike 318 (cf. A075153) its trajectory does not exhibit any recognizable regularity, so that the method by which the base 4 trajectory of 318 as well as the base 2 trajectories of 22 (cf. A061561), 77 (cf. A075253), 442 (cf. A075268) etc. can be proved to be palindrome-free (cf. Links), is not applicable here.

Examples

			290 (decimal) = 10202 -> 10202 + 20201 = 31003 = 835 (decimal).
		

Crossrefs

Programs

  • Mathematica
    NestWhileList[# + IntegerReverse[#, 4] &, 290,  # !=
    IntegerReverse[#, 4] &, 1, 23] (* Robert Price, Oct 18 2019 *)
  • PARI
    {m=290; stop=26; c=0; while(c0,d=divrem(k,4); k=d[1]; rev=4*rev+d[2]); c++; m=m+rev)}

A103897 a(n) = 3*2^(n-1)*(2^n-1).

Original entry on oeis.org

3, 18, 84, 360, 1488, 6048, 24384, 97920, 392448, 1571328, 6288384, 25159680, 100651008, 402628608, 1610563584, 6442352640, 25769607168, 103078821888, 412316073984, 1649265868800, 6597066620928, 26388272775168, 105553103683584, 422212439900160
Offset: 1

Views

Author

Zak Seidov, Mar 30 2005

Keywords

Comments

Divide the sequence of natural numbers: s0=1,2,3,4,5,6,7,8,9,10,11,12,13,14,... into sections s(n) of length 2*s1-1, where s1=initial digits of s(n): s={1,2},{3,4,5,6},{7,8,9,10,11,12,13,14},... then a(n)=sum of terms of s(n): 3,18,84,...
Sum of the numbers between 2^n and 2^(n+1), both excluded. - Gionata Neri, Jun 16 2015

Crossrefs

Cf. A006516.

Programs

  • Magma
    [3*2^(n-1)*(2^n-1): n in [1..24]];  // Bruno Berselli, Sep 19 2011
    
  • Mathematica
    Table[3*2^(n - 1)*(2^n - 1), {n, 30}]
    LinearRecurrence[{6,-8},{3,18},30] (* Harvey P. Dale, Feb 11 2018 *)
  • PARI
    a(n)=3*2^(n-1)*(2^n-1) \\ Charles R Greathouse IV, Jun 08 2015
    
  • Python
    b = list(range(0,2**20-1)); a = [sum(b[2**i-1:2**(i+1)-1]) for i in range(1,20)] ## Johan Claes, Nov 10 2019

Formula

a(n) = 3*A006516(n).
From Bruno Berselli, Sep 19 2011: (Start)
G.f.: 3*x/((1-2*x)*(1-4*x)).
a(n+2) = A061561(4n-2). (End)
E.g.f.: (3/2)*(exp(4*x) - exp(2*x)). - Stefano Spezia, Nov 10 2019

A306514 Decimal representation of binary numbers with string structure 10s00, s in {0,1}*, such that it results in a non-palindromic cycle of length 4 in the Reverse and Add! procedure in base 2.

Original entry on oeis.org

84, 180, 324, 360, 684, 744, 1416, 1488, 2628, 2904, 3024, 5580, 5904, 6048, 10836, 11400, 11952, 12192, 21060, 21684, 23220, 23448, 23556, 24096, 24384, 43188, 43668, 44604, 44748, 46248, 46260, 47376, 48480, 48960, 86388, 86964, 91272, 92520, 92532, 93108, 95592, 96048, 96264, 97344, 97920, 166212
Offset: 1

Views

Author

A.H.M. Smeets, Feb 21 2019

Keywords

Comments

If the decimal representation of the binary string 10s00 is in the sequence, so is 101s000.
For binary representation see A306515.
This sequence is a subset of A066059.
These regular patterns can be represented by the context-free grammar with production rules:
S -> S_a | S_b | S_c | S_d
S_a -> 10 T_a 00, T_a -> 1 T_a 0 | T_a0,
S_b -> 11 T_b 01, T_b -> 0 T_b 1 | T_b0,
S_c -> 10 T_c 000, T_c -> 1 T_c 0 | T_c0,
S_d -> 11 T_d 101, T_d -> 0 T_d 1 | T_d0,
where T_a0, T_b0, T_c0 and T_d0 are some terminating strings.
Numbers in this sequence are generated by choosing S_a or S_c from the starting symbol S.
The decimal representation of all binary numbers derived by S -> S_a -> 10 T_a 00 -> 10 T_a0 00 are given in sequence A306516, its binary representation in A306517.
Observed: all values are in the ranges lower(k)..upper(k), where lower(k) = 81*2^k + 2^floor((k+6)/2) + 2^6*(2^floor((k-8)/2) - 1) + 4, which holds for k >= 11, and upper(k) = 3*2^floor((k+4)/2)*(2^floor((k+7)/2) - 1), which holds for k >= 0; the number of terms in each successive range increases by about a factor of 4/3. All terms between lower(k) and upper(k) are represented by a (k+7)-binary-digit number (see A306515). Each m-binary-digit number will have a successive number of m+1 binary digits in the next range. About 1/4 of each obtained number in this sequence has a new unique cyclic trajectory (see A306516 and A306517), i.e., a cyclic trajectory not joining a previous cyclic trajectory, which explains the growth factor of 4/3 for each successive range.
All terms A061561(4k+2) for k >= 0 are included in this sequence.
All values in A103897(k+3) for k >= 0 are included in this sequence.

Examples

			a(45) = 97920 = upper(10)
The following burst of terms is from a(46) = 166212 = lower(11) up to and including a(60) = 196224 = upper(12).
The burst of terms corresponding with k = 28 is from lower(28) = 21743468484 = a(5276) up to and including upper(28) = 25769607168 = a(6976).
		

Crossrefs

Formula

a(n) = 0 (mod 12).

A062131 A062129 written in base 10.

Original entry on oeis.org

0, 3, 3, 9, 5, 15, 9, 21, 9, 27, 15, 27, 15, 27, 21, 45, 17, 51, 27, 99, 99, 63, -1, 63, 27, 99, -1, 255, -1, 63, 45, 93, 33, 99, 51, -1, 45, -1, 63, 99, 45, -1, 63, 99, 99, -1, -1, -1, 51, -1, 255, 153, 63, 99, 255, 153, 63, 99, 255, 153, -1, -1, 93, 189, 65, 195, 99, -1, 85, 255, 119, 387, 255, 219, 13299, -1, 387, -1, -1, 219
Offset: 0

Views

Author

Klaus Brockhaus, Jun 06 2001

Keywords

Comments

Differs from A062130 only for those n, which are palindromes in base 2.

Examples

			23 -> 23 + 29 = 52 -> 52 + 11 = 63, so a(23) = 63.
		

Crossrefs

Programs

  • ARIBAS
    stop := 500; for k := 0 to 80 do c := 0; m := k; test := true; while test and c < stop do inc(c); m := m + bit_reverse(m); test := m <> bit_reverse(m); end; if c < stop then write(m); else write(-1); end; write(" "); end;

A348570 Positive integers which apparently never result in a palindrome under repeated applications of the function f(x) = x + (x with digits in Zeckendorf representation reversed). Zeckendorf representation analog of Lychrel numbers.

Original entry on oeis.org

59, 61, 69, 75, 77, 100, 105, 113, 115, 122, 128, 130, 131, 135, 136, 140, 142, 143, 148, 151, 153, 160, 162, 163, 166, 172, 177, 180, 183, 188, 191, 192, 196, 198, 200, 209, 210, 212, 215, 222, 223, 229, 230, 231, 237, 240, 249, 250, 257, 258, 263, 264, 266
Offset: 1

Views

Author

A.H.M. Smeets, Oct 23 2021

Keywords

Comments

Zeckendorf representation version of A023108 (base 10).
For the Zeckendorf representation of numbers see A014417.
For palindromic numbers in Zeckendorf representation see A094202.
The "Reverse and Add!" operation (A349239) applied in Zeckendorf representation seems to behave similarly to the "Reverse and Add!" operation applied in any fixed-base representation. The first 53 terms are however obtained after performing 10^4 "Reverse and Add!" steps (see Python program).
For records and record-setting values in the number of "Reverse and Add!" steps see A348572 and A348571 respectively.
Do any of these numbers have a trajectory in which the Lychrel property can be proved (like 22 in base 2 as in A061561)?
Iteration steps are given by n := n+A349238(n), or n := A349239(n).
Closure of reverse operation is given by: Let Z be the regular expression for numbers in Zeckendorf representation, Z = 0|(100*)*10*, and L(Z) its corresponding regular language. Then for s in L(Z), the reversal of s is in L(0*)L(Z).
Let h be the homomorphism from Zeckendorf representation to a conventional radix representation, then addition in Zeckendorf representation, +_Z, is given by z1 +_Z z2 = h^(-1)(h(z1) + h(z2)). A direct method for addition in Zeckendorf representation is given by Ahlbach et al.

Crossrefs

Lychrel numbers in fixed bases: A066059 (base 2), A077404 (base 3), A075420 (base 4), A023108 (base 10).

Programs

  • Python
    # Using functions NumToFib and RevFibToNum from A349238.
    n, a = 0, 0
    while n < 53:
        a += 1
        aa, sa = a, NumToFib(a)
        ar, s = RevFibToNum(sa), 0
        while aa != ar and s < 10000:
            s, aa = s+1, aa+ar
            sa = NumToFib(aa)
            ar = RevFibToNum(sa)
        if aa != ar:
            n += 1
            print(a, end = ", ")

A077408 Trajectory of 103 under the Reverse and Add! operation carried out in base 3, written in base 10.

Original entry on oeis.org

103, 230, 436, 776, 2424, 3856, 7400, 20856, 30928, 60920, 220248, 242704, 432896, 857152, 1460408, 2754688, 5134016, 16206744, 24437488, 44623424, 138104472, 201737128, 401511824, 1438324704, 1601682040, 2820726320, 5622321088
Offset: 0

Views

Author

Klaus Brockhaus, Nov 05 2002

Keywords

Comments

103 = A077405(0) is conjectured (cf. A066450) to be the smallest number such that the Reverse and Add! algorithm in base 3 does not lead to a palindrome. Its trajectory does not exhibit any recognizable regularity, so that the method by which the base-2 trajectories of 22 (cf. A061561), 77 (cf. A075253), 442 (cf. A075268) etc. as well as the base-4 trajectories of 318 (cf. A075153), 266718 (cf. A075466), 270798 (cf. A075467) etc. can be proved to be palindrome-free (cf. Links), is not applicable here.

Examples

			103 (decimal) = 10211 -> 10211 + 11201 = 22112 = 230 (decimal).
		

Crossrefs

Programs

  • ARIBAS
    m := 103; stop := 28; c := 0; while c < stop do write(m:group(0),","); k := m; rev := 0; while k > 0 do rev := 3*rev + (k mod 3); k := k div 3; end; inc(c); m := m+rev; end;
Previous Showing 11-20 of 22 results. Next