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 41-50 of 61 results. Next

A060136 Square array read by antidiagonals with T(n,k)=T(n,k-1)^2+n*T(n,k-1)+1 and T(n,0)=0.

Original entry on oeis.org

0, 1, 0, 2, 1, 0, 5, 3, 1, 0, 26, 13, 4, 1, 0, 677, 183, 25, 5, 1, 0, 458330, 33673, 676, 41, 6, 1, 0, 210066388901, 1133904603, 458329, 1805, 61, 7, 1, 0, 44127887745906175987802, 1285739649838492213, 210066388900, 3263441, 3966
Offset: 0

Views

Author

Henry Bottomley, Mar 05 2001

Keywords

Crossrefs

Rows include A003095, A002065, A004019. Columns include A000004, A000012, A000027 (offset), A001844. Cf. A060137.

A101190 G.f.: A(x) = Sum_{n>=0} a(n)/2^A005187(n) * x^n = lim_{n->oo} F(n)^(1/2^n) where F(n) is defined by F(n) = F(n-1)^2 + x^(2^n-1) for n >= 1 with F(0) = 1.

Original entry on oeis.org

1, 1, -1, 5, -53, 127, -677, 2221, -61133, 205563, -1394207, 4852339, -68586849, 243751723, -1741612525, 6265913725, -363239625661, 1323861506899, -9699189175227, 35700526467479, -527987675255931, 1960112858076289, -14606721595781139, 54604708004873403
Offset: 0

Views

Author

Paul D. Hanna, Dec 03 2004

Keywords

Examples

			G.f.: A(x) = 1 + 1/2*x - 1/8*x^2 + 5/16*x^3 - 53/128*x^4 + 127/256*x^5 - 677/1024*x^6 + 2221/2048*x^7 + ... + a(n)/2^A005187(n)*x^n + ...
where 2^A005187(n) is also the denominator of [x^n] 1/sqrt(1-x).
GENERATING METHOD.
We can illustrate the generating method for g.f. A(x) as follows.
Given F(n) = F(n-1)^2 + (2*x)^(2^n-1) for n >= 1 with F(0) = 1,
the first few polynomials generated by F(n) begin
F(0) = 1,
F(1) = F(0)^2 + x^(2^1-1) = 1 + x,
F(2) = F(1)^2 + x^(2^2-1) = 1 + 2*x + x^2 + x^3,
F(3) = F(2)^2 + x^(2^3-1) = 1 + 4*x + 6*x^2 + 6*x^3 + 5*x^4 + 2*x^5 + x^6 + x^7.
...
The 2^n-th roots of F(n) tend to the limit of the g.f.:
F(1)^(1/2^1) = 1 + 1/2*x - 1/8*x^2 + 1/16*x^3 - 5/128*x^4 + 7/256*x^5 - 21/1024*x^6 + 33/2048*x^7 - 429/32768*x^8 + ...
F(2)^(1/2^2) = 1 + 1/2*x - 1/8*x^2 + 5/16*x^3 - 53/128*x^4 + 127/256*x^5 - 677/1024*x^6 + 1965/2048*x^7 - 46797/32768*x^8 + ...
F(3)^(1/2^3) = 1 + 1/2*x - 1/8*x^2 + 5/16*x^3 - 53/128*x^4 + 127/256*x^5 - 677/1024*x^6 + 2221/2048*x^7 - 61133/32768*x^8 + ...
...
The limit of this process equals the g.f. A(x) of this sequence.
Note: the sum of the coefficients in F(n) equals A003095(n):
1, 2 = 1 + 1, 5 = 1 + 2 + 1 + 1, 26 = 1 + 4 + 6 + 6 + 5 + 2 + 1 + 1, ...
The last n coefficients in F(n) read backwards are Catalan numbers (A000108).
POWERS OF A(x).
The coefficients of x^k in the 2^n powers of the g.f. A(x) begin:
A^(2^0) = [1, 1/2, -1/8, 5/16, -53/128, 127/256, -677/1024, 2221/2048, ...],
A^(2^1) = [1, 1, 0, 1/2, -1/2, 1/2, -5/8, 9/8, -2, 53/16, -89/16, 155/16, ...],
A^(2^2) = [1, 2, 1, 1, 0, 0, 0, 1/2, -1, 3/2, -5/2, 9/2, -8, 14, -197/8, 44, ...],
A^(2^3) = [1, 4, 6, 6, 5, 2, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1/2, -2, 5, ...],
A^(2^4) = [1, 8, 28, 60, 94, 116, 114, 94, 69, 44, 26, 14, 5, 2, 1, 1, 0, 0, ...].
		

Crossrefs

Programs

  • PARI
    {a(n) = my(F=1,A,L); if(n==0,A=1,L=ceil(log(n+1)/log(2)); for(k=1,L, F = F^2 + x^(2^k-1) +x*O(x^n)); A = polcoeff(F^(1/2^L),n)); numerator(A)}
    for(n=0,32, print1(a(n),", "))

Formula

G.f. A(x) = ( Sum_{n>=0} A101191(n)/2^A004134(n) * x^n )^2.
G.f. A(x) satisfies A(2*x)^2 = Sum_{n>=0} A101189(n)*(2*x)^n.

Extensions

Entry revised by Paul D. Hanna, Mar 05 2024

A101191 G.f.: A(x) = Sum_{n>=0}a(n)/2^A004134(n)*x^n = limit_{n->oo} F(n)^(1/2^(n+1)) where F(n) is the n-th iteration of: F(0) = 1, F(n) = F(n-1)^2 + x^(2^n-1) for n>=1.

Original entry on oeis.org

1, 1, -3, 23, -525, 2695, -29687, 191991, -10488701, 70977675, -968279181, 6752850945, -191225421641, 1363019302883, -19538003443615, 140961586090743, -16379289413266717, 119621607825995891, -1755802638936696081, 12944528671963135869, -383361262914445548739
Offset: 0

Views

Author

Paul D. Hanna, Dec 03 2004

Keywords

Comments

Although the power series for the g.f. A(x) diverges at x=1, the Euler transform of the power series A(x) at x=1 converges to the constant A076949: Sum_{n>=0}[Sum_{k=0..n}C(n,k)*a(k))/2^A004134(n) ]/2^(n+1) = 1.2259024435...

Examples

			The iteration begins:
F(0) = 1,
F(1) = F(0)^2 + x^(2^1-1) = 1 +x,
F(2) = F(1)^2 + x^(2^2-1) = 1 +2*x +x^2 +x^3,
F(3) = F(2)^2 + x^(2^3-1) = 1 +4*x +6*x^2 +6*x^3 +5*x^4 +2*x^5 +x^6 +x^7.
The 2^(n+1)-th roots of F(n) tend to the limit of the g.f.:
F(1)^(1/2^2) = 1 +1/4*x -3/32*x^2 +7/128*x^3 -77/2048*x^4 +231/8192*x^5 +...
F(2)^(1/2^3) = 1 +1/4*x -3/32*x^2 +23/128*x^3 -525/2048*x^4 +2695/8192*x^5 +...
F(3)^(1/2^4) = 1 +1/4*x -3/32*x^2 +23/128*x^3 -525/2048*x^4 +2695/8192*x^5 +...
The limit of this process is the g.f. A(x) of this sequence.
The coefficients of x^k in the 2^n powers of the g.f. A(x) begin:
A^(2^0)=[1,1/4,-3/32,23/128,-525/2048,2695/8192,-29687/65536,...],
A^(2^1)=[1,1/2,-1/8,5/16,-53/128,127/256,-677/1024,2221/2048,...],
A^(2^2)=[1,1,0,1/2,-1/2,1/2,-5/8,9/8,-2,53/16,-89/16,155/16,...],
A^(2^3)=[1,2,1,1,0,0,0,1/2,-1,3/2,-5/2,9/2,-8,14,-197/8,44,...],
A^(2^4)=[1,4,6,6,5,2,1,1,0,0,0,0,0,0,0,1/2,-2,5,...],
A^(2^5)=[1,8,28,60,94,116,114,94,69,44,26,14,5,2,1,1,0,0,...].
Note: the sum of the coefficients of x^k in F(n) equals A003095(n+1):
1, 2=1+1, 5=1+2+1+1, 26=1+4+6+6+5+2+1+1, ...
The last n coefficients in F(n) read backwards are Catalan numbers (A000108).
		

Crossrefs

Programs

  • PARI
    {a(n)=local(F=1,A,L);if(n==0,A=1,L=ceil(log(n+1)/log(2)); for(k=1,L,F=F^2+x^(2^k-1)); A=polcoeff(F^(1/2^(L+1))+x*O(x^n),n));numerator(A)}

Formula

G.f. A(x) satisfies: A(x)^2 = Sum_{n>=0} A101190(n)/2^A005187(n)*x^n. G.f. A(x) satisfies: A(2*x)^4 = Sum_{n>=0} A101189(n)*(2x)^n.

A256348 Moduli n for which A248218(n) = 8.

Original entry on oeis.org

193, 386, 461, 523, 579, 772, 887, 922, 1019, 1046, 1158, 1351, 1383, 1544, 1569, 1774, 1844, 1861, 2038, 2092, 2123, 2153, 2269, 2316, 2509, 2661, 2702, 2766, 2887, 3057, 3088, 3138, 3227, 3391, 3449, 3541, 3548, 3661, 3667, 3688, 3722, 3919
Offset: 1

Views

Author

M. F. Hasler, Mar 25 2015

Keywords

Comments

If x and y are members, then so is LCM(x,y). - Robert Israel, Mar 08 2021

Crossrefs

Programs

  • Maple
    filter:= proc(n) local x,k,R;
      x:= 0; R[0]:= 0;
      for k from 1 do
        x:= x^2+1 mod n;
        if assigned(R[x]) then return evalb(k-R[x] = 8)
        else R[x]:= k fi
      od;
    end proc:
    select(filter, [$1..5000]); # Robert Israel, Mar 08 2021
  • Mathematica
    filter[n_] := Module[{x, k, R}, x = 0; R[0] = 0; For[k = 1, True, k++, x = Mod[x^2+1, n]; If[IntegerQ[R[x]], Return[k - R[x] == 8], R[x] = k]]];
    Select[Range[4000], filter] (* Jean-François Alcover, May 15 2023, after Robert Israel *)
  • PARI
    for(i=1,3000,A248218(i)==8&&print1(i","))

A293390 Least m such that the exponents in expression for n as a sum of distinct powers of 2 are pairwise distinct mod m; a(0) = 0 by convention.

Original entry on oeis.org

0, 1, 1, 2, 1, 3, 2, 3, 1, 2, 3, 4, 2, 4, 3, 4, 1, 3, 2, 5, 3, 3, 4, 5, 2, 5, 4, 5, 3, 5, 4, 5, 1, 2, 3, 3, 2, 4, 5, 6, 3, 4, 3, 6, 4, 4, 5, 6, 2, 3, 5, 6, 4, 6, 5, 6, 3, 6, 5, 6, 4, 6, 5, 6, 1, 4, 2, 4, 3, 5, 3, 7, 2, 4, 4, 4, 5, 5, 6, 7, 3, 5, 4, 7, 3, 5, 6
Offset: 0

Views

Author

Rémy Sigrist, Oct 08 2017

Keywords

Comments

The set of exponents in expression for n as a sum of distinct powers of 2 corresponds to the n-th row of A133457.
The sum of digits of n in base 2^a(n), say s, can be computed without carry in base 2; the Hamming weight of s equals the Hamming weight of n.
a(n) >= A000120(n) for any n > 0.
Apparently, a(n) = A000120(n) iff n = 0 or n belongs to A100290.
a(n) <= A070939(n) for any n >= 0.
For any sequence s of distinct nonnegative integers (s(n) being defined for n >= 0):
- let D_s be defined for any n > 0 by D_s(n) = a(Sum_{k=0..n-1} 2^s(k)),
- then D_s is the discriminator of s as introduced by Arnold, Benkoski, and McCabe in 1985,
- D_s(1) = 1,
- D_s(n) >= n for any n >= 1,
- D_s(n+1) >= D_s(n) for any n >= 1.

Examples

			For n=42:
- 42 = 2^5 + 2^3 + 2^1,
- 5 mod 1 = 3 mod 1,
- 5 mod 2 = 3 mod 2,
- 5 mod 3, 3 mod 3 and 1 mod 3 are all distinct,
- hence a(42) = 3.
		

Crossrefs

Programs

  • Maple
    f:= proc(n) local L,D,k;
      L:= convert(n,base,2);
      L:= select(t -> L[t+1]=1, [$0..nops(L)-1]);
      if nops(L) = 1 then return 1 fi;
      D:= {seq(seq(L[j]-L[i],i=1..j-1),j=2..nops(L))};
      D:= `union`(seq(numtheory:-divisors(i),i=D));
      min({$2..max(D)+1} minus D)
    end proc:
    0, seq(f(i),i=1..100); # Robert Israel, Oct 08 2017
  • Mathematica
    {0}~Join~Table[Function[r, SelectFirst[Range@ 10, Length@ Union@ Mod[r, #] == Length@ r &]][Join @@ Position[#, 1] - 1 &@ Reverse@ IntegerDigits[n, 2]], {n, 86}] (* Michael De Vlieger, Oct 08 2017 *)
  • PARI
    a(n) = if (n, my (d=Vecrev(binary(n)), x = []); for (i=1, #d, if (d[i], x = concat(x, i-1))); for (m=1, oo, if (#Set(vector(#x, i, x[i]%m))==#x, return (m))), return (0))

Formula

a(2*n) = a(n) for any n >= 0.
a(2^k-1) = k for any k >= 0.
a(n) = 1 iff n = 2^k for some k >= 0.
a(n) = 2 iff n belongs to A173195.
a(Sum_{k=1..n} 2^(k^2)) = A016726(n) for any n >= 1.
a(Sum_{k=1..n} 2^A000069(k)) = A062383(n) for any n >= 1.
a(Sum_{k=0..n} 2^(2^k)) = A270097(n) for any n >= 0.
a(Sum_{k=1..n} 2^A000045(k+1)) = A270151(n) for any n >= 1.
a(Sum_{k=1..n} 2^A000041(k)) = A270176(n) for any n >= 1.
a(A076793(n)) = A272633(n) for any n >= 0.
a(Sum_{k=1..n} 2^A001969(k)) = A272881(n) for any n >= 1.
a(Sum_{k=1..n} 2^A005823(k)) = A272882(n) for any n >= 1.
a(Sum_{k=1..n} 2^A000215(k-1)) = A273037(n) for any n >= 1.
a(Sum_{k=1..n} 2^A000108(k)) = A273041(n) for any n >= 1.
a(Sum_{k=1..n} 2^A001566(k)) = A273043(n) for any n >= 1.
a(Sum_{k=1..n} 2^A003095(k)) = A273044(n) for any n >= 1.
a(Sum_{k=1..n} 2^A000058(k-1)) = A273056(n) for any n >= 1.
a(Sum_{k=1..n} 2^A002808(k)) = A273062(n) for any n >= 1.
a(Sum_{k=1..n} 2^(k!)) = A273064(n) for any n >= 1.
a(Sum_{k=1..n} 2^(k^k)) = A273068(n) for any n >= 1.
a(Sum_{k=1..n} 2^A000110(k)) = A273237(n) for any n >= 1.
a(Sum_{k=1..n} 2^A001147(k)) = A273377(n) for any n >= 1.

A330405 a(1) = 0; thereafter a(n) = (a(n-1)^2+1) mod n.

Original entry on oeis.org

0, 1, 2, 1, 2, 5, 5, 2, 5, 6, 4, 5, 0, 1, 2, 5, 9, 10, 6, 17, 17, 4, 17, 2, 5, 0, 1, 2, 5, 26, 26, 5, 26, 31, 17, 2, 5, 26, 14, 37, 17, 38, 26, 17, 20, 33, 9, 34, 30, 1, 2, 5, 26, 29, 17, 10, 44, 23, 58, 5, 26, 57, 37, 26, 27, 4, 17, 18, 49, 22, 59, 26, 20, 31, 62, 45, 24
Offset: 1

Views

Author

Matthew Ryan, Dec 12 2019

Keywords

Comments

Does the value 0 appear infinitely many times? - Rémy Sigrist, Dec 16 2019
From Michael De Vlieger, Jan 26 2020: (Start)
Observations based on a(n) for 1 <= n <= 300000:
The value 0 appears at indices n = {1, 13, 26, 89, 205, 530, 2041, 276205, ...}.
The value 1 appears at indices n = {2, 4, 14, 27, 50, 90, 99, 175, 188, 206, 531, 2042, 5445, 6845, 7200, 18225, 24389, 25215, 37538, 46875, 48672, 53066, 79527, 93900, 147875, 176267, 186576, 196025, 254457, 276206, ...}. Let M be the indices in a(n) where 1 appears.
The subsequence {1, 2, 5, 26} appears with the first term at index n = 27, and apparently for all subsequent indices listed n M.
The subsequence {1, 2, 5, 26, 677} appears with the first term at index n = 2042, and apparently for all subsequent indices listed n M.
A stable next term in the subsequence S = {1, 2, 5, 26, 677} is not yet apparent, given 300000 terms of a(n). (End)

Examples

			a(1) = 0; a(2) = (0^2+1) mod 2 = 1; a(3) = (1^2+1) mod 2 = 2.
		

Crossrefs

Programs

  • Mathematica
    Nest[Append[#1, Mod[#1[[#2 - 1]]^2 + 1, #2]] & @@ {#, Length@ # + 1} &, {0}, 76] (* Michael De Vlieger, Dec 16 2019 *)
  • PARI
    v=0; for (n=1, 77, print1 (v=(v^2+1)%n", ")) \\ Rémy Sigrist, Dec 16 2019

Formula

a(1) = 0; a(n) = (a(n-1)^2+1) mod n.

A332965 a(n) is the number of distinct values in the sequence s defined by s(1) = 0 and for any k > 0, s(k+1) = (s(k)^2+1) mod n.

Original entry on oeis.org

1, 2, 3, 3, 3, 4, 4, 4, 5, 6, 6, 4, 4, 5, 5, 5, 8, 8, 6, 7, 4, 6, 8, 4, 4, 4, 5, 5, 11, 8, 5, 5, 6, 8, 6, 8, 6, 7, 6, 8, 7, 5, 8, 6, 5, 8, 14, 5, 9, 7, 8, 5, 9, 8, 10, 5, 6, 11, 11, 8, 15, 6, 6, 6, 12, 6, 12, 8, 8, 9, 18, 8, 9, 7, 5, 7, 6, 6, 8, 9, 11, 14, 11
Offset: 1

Views

Author

Rémy Sigrist, Mar 04 2020

Keywords

Comments

For any n > 0, the sequence s is eventually periodic, so this sequence is well defined.
a(n) tends to infinity as n tends to infinity.

Examples

			For n = 42:
- we have:
  k  s(k)
  -  ----
  1     1
  2     2
  3     5
  4    26
  5     5
  6    26
  ...
- the sequence s has 4 distinct values, so a(42) = 4.
		

Crossrefs

Programs

  • PARI
    a(n) = { my (s=0, v=0, w=0); while (!bittest(w,s), w+=2^s; v++; s=(s^2+1)%n); v }

Formula

a(n) > k for any k >= 0 and n > A003095(k).

A332966 a(n) is the largest value in the sequence s defined by s(1) = 0 and for any k > 0, s(k+1) = (s(k)^2+1) mod n.

Original entry on oeis.org

0, 1, 2, 2, 2, 5, 5, 5, 8, 7, 6, 5, 5, 12, 11, 10, 16, 17, 12, 17, 5, 17, 13, 5, 5, 5, 26, 26, 26, 26, 26, 26, 26, 33, 26, 29, 26, 31, 26, 37, 32, 26, 36, 26, 26, 33, 43, 26, 47, 30, 50, 26, 41, 53, 50, 26, 50, 50, 30, 50, 53, 57, 47, 37, 57, 26, 56, 65, 59
Offset: 1

Views

Author

Rémy Sigrist, Mar 04 2020

Keywords

Comments

For any n > 0, the sequence s is eventually periodic, so this sequence is well defined.
a(n) tends to infinity as n tends to infinity.

Examples

			For n = 42:
- we have:
  k  s(k)
  -  ----
  1     1
  2     2
  3     5
  4    26
  5     5
  6    26
  ...
- the sequence s has largest value 26, so a(42) = 26.
		

Crossrefs

Programs

  • PARI
    a(n) = { my (s=0, v=s, w=0); while (!bittest(w,s), w+=2^s; v=max(v,s); s=(s^2+1)%n); v }

Formula

a(n) >= A003095(k) for any k >=0 and n > A003095(k).

A060137 Square array read by antidiagonals with T(n,k)=T(n,k-1)^2-n*T(n,k-1)+1 and T(n,0)=0.

Original entry on oeis.org

0, 1, 0, 2, 1, 0, 5, 1, 1, 0, 26, 1, 0, 1, 0, 677, 1, 1, -1, 1, 0, 458330, 1, 0, 5, -2, 1, 0, 210066388901, 1, 1, 11, 13, -3, 1, 0, 44127887745906175987802, 1, 0, 89, 118, 25, -4, 1, 0, 1947270476915296449559703445493848930452791205, 1, 1, 7655, 13453, 501, 41, -5, 1, 0
Offset: 0

Views

Author

Henry Bottomley, Mar 05 2001

Keywords

Crossrefs

Rows include A003095, A057427, A000035. Columns include A000004, A000012, A022958, A001844 (offset). Cf. A060136.

Formula

T(0,k)=A004019(k-1)+1=A056207(k-2)+2. - R. J. Mathar, Apr 24 2007

A135361 a(n) = a(n-1)^3 + 1 with a(0) = 0.

Original entry on oeis.org

0, 1, 2, 9, 730, 389017001, 58871587162270593034051002, 204040901322752673844230437877671861543858084850895762746141813554591014612009
Offset: 0

Views

Author

Gerald McGarvey, Dec 08 2007

Keywords

Comments

Number of ternary trees of height less than n.
The rightmost digits cycle (0, 1, 2, 9, 0, 1, 2, 9, ...).

Crossrefs

Programs

  • Mathematica
    Nest[Append[#, #[[-1]]^3 + 1] &, {0}, 7] (* Michael De Vlieger, Oct 24 2018 *)
  • Sage
    def a(n): return 0 if (n==0) else a(n-1)^3 + 1
    [a(n) for n in (0..9)] # G. C. Greubel, Jul 19 2021

Formula

a(n) is asymptotic to c^(3^n) where c=1.0847999710783722816939038440390528005339362697...
Previous Showing 41-50 of 61 results. Next