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.

User: Fred Daniel Kline

Fred Daniel Kline's wiki page.

Fred Daniel Kline has authored 8 sequences.

A327910 This is the reduced A317745, with primes -> 1 and prime + prime -> 2.

Original entry on oeis.org

0, 1, 1, 1, 2, 1, 1, 2, 2, 1, 0, 2, 2, 2, 0, 1, 1, 2, 2, 1, 1, 1, 2, 1, 2, 1, 2, 1, 0, 2, 2, 1, 1, 2, 2, 0, 1, 1, 2, 2, 0, 2, 2, 1, 1, 1, 2, 1, 2, 1, 1, 2, 1, 2, 1, 0, 2, 2, 1, 1, 2, 1, 1, 2, 2, 0, 1, 1, 2, 2, 0, 2, 2, 0, 2, 2, 1, 1
Offset: 1

Author

Fred Daniel Kline, Oct 05 2019

Keywords

Comments

This is related to Goldbach's conjecture, since entries for which the leftmost entry and the top entry are both nonzero are the sums of two primes.
The successive antidiagonals may also be regarded as the rows of a triangle, having A101264 as outside diagonals.

Examples

			Beginning of the array. All elements are equal to topmost value plus leftmost value.
   0 1 1 1 0 1 1 0 1 1 0 1 0 0 1 1 0 0 1 0 1 1 0 1
   1 2 2 2 1 2 2 1 2 2 1 2 1 1 2 2 1 1 2 1 2 2 1
   1 2 2 2 1 2 2 1 2 2 1 2 1 1 2 2 1 1 2 1 2 2
   1 2 2 2 1 2 2 1 2 2 1 2 1 1 2 2 1 1 2 1 2
   0 1 1 1 0 1 1 0 1 1 0 1 0 0 1 1 0 0 1 0
   1 2 2 2 1 2 2 1 2 2 1 2 1 1 2 2 1 1 2
   1 2 2 2 1 2 2 1 2 2 1 2 1 1 2 2 1 1
   0 1 1 1 0 1 1 0 1 1 0 1 0 0 1 1 0
   1 2 2 2 1 2 2 1 2 2 1 2 1 1 2 2
   1 2 2 2 1 2 2 1 2 2 1 2 1 1 2
   0 1 1 1 0 1 1 0 1 1 0 1 0 0
   1 2 2 2 1 2 2 1 2 2 1 2 1
   0 1 1 1 0 1 1 0 1 1 0 1
   0 1 1 1 0 1 1 0 1 1 0
   1 2 2 2 1 2 2 1 2 2
   1 2 2 2 1 2 2 1 2
   0 1 1 1 0 1 1 0
   0 1 1 1 0 1 1
   1 2 2 2 1 2
   0 1 1 1 0
   1 2 2 2
   1 2 2
   0 1
   1
Note: A101264 is both outside diagonals. A101264 and A101264 + 1 are inside diagonals, determined by their positions in the outside diagonals.
		

Crossrefs

Programs

  • Mathematica
    i[n_] := If[PrimeQ[2 n - 1], 2 n - 1, 0]; A101264 = Array[i, 82];
    r[k_] := Table[A101264[[j]] + A101264[[k - j + 1]], {j, 1, k}];
    a = Array[r, 12] // Flatten,

Formula

T(n, k) = A101264(n) + A101264(k).

A317745 Square array T(n,k) (n >= 1, k >= 1) read by antidiagonals: first row and column are A085090, other entries equal sum of entries in first row and first column.

Original entry on oeis.org

0, 3, 3, 5, 6, 5, 7, 8, 8, 7, 0, 10, 10, 10, 0, 11, 3, 12, 12, 3, 11, 13, 14, 5, 14, 5, 14, 13, 0, 16, 16, 7, 7, 16, 16, 0, 17, 3, 18, 18, 0, 18, 18, 3, 17, 19, 20, 5, 20, 11, 11, 20, 5, 20, 19, 0, 22, 22, 7, 13, 22, 13, 7, 22, 22, 0, 23, 3, 24, 24, 0, 24, 24, 0, 24, 24, 3, 23
Offset: 1

Author

Fred Daniel Kline, Aug 05 2018

Keywords

Comments

This is related to Goldbach's conjecture, since entries for which the leftmost entry and the top entry are both nonzero are the sums of two primes.
The successive antidiagonals may also be regarded as the rows of a triangle, having A085090 as outside diagonals.

Examples

			Beginning of the array. All elements are equal to topmost value plus leftmost value.
   0  3  5  7  0 11 13  0 17 19  0 23
   3  6  8 10  3 14 16  3 20 22  3
   5  8 10 12  5 16 18  5 22 24
   7 10 12 14  7 18 20  7 24
   0  3  5  7  0 11 13  0
  11 14 16 18 11 22 24
  13 16 18 20 13 24
   0  3  5  7  0
  17 20 22 24
  19 22 24
   0  3
  23
		

Crossrefs

Cf. A085090.

Programs

  • Mathematica
    i[n_] := If[PrimeQ[2 n - 1], 2 n - 1, 0]; A085090 = Array[i, 82];
    r[k_] := Table[A085090[[j]] + A085090[[k - j + 1]], {j, 1, k}];
    a = Array[r, 12] // Flatten,
  • PARI
    a085090(n) = if (isprime(p=2*n-1), p, 0);
    row(n) = vector(n, k, a085090(k) + a085090(n-k+1));
    tabl(nn) = for (n=1, nn, print(row(n))); \\ Michel Marcus, Aug 09 2018

Formula

T(n, k) = A085090(n) + A085090(k).

Extensions

Edited by N. J. A. Sloane, Sep 09 2018

A316859 Triangle read by rows constructed from A076565 as sum of greatest prime factors.

Original entry on oeis.org

6, 8, 8, 10, 10, 10, 6, 12, 12, 6, 14, 8, 14, 8, 14, 16, 16, 10, 10, 16, 16, 8, 18, 18, 6, 18, 18, 8, 20, 10, 20, 14, 14, 20, 10, 20, 22, 22, 12, 16, 22, 16, 12, 22, 22, 10, 24, 24, 8, 24, 24, 8, 24, 24, 10, 26, 12, 26, 20, 16, 26, 16, 20, 26, 12, 26, 8, 28, 14, 22, 28, 18, 18, 28, 22, 14, 28, 8
Offset: 1

Author

Fred Daniel Kline, Jul 15 2018

Keywords

Comments

The greatest number in row k is 2*k + 4, thus consecutive rows identify consecutive even numbers (sums of primes).
To get the n-th row: copy (1...n) of A076565, reverse, and add together.
When primes meet primes we get the maximum values. When primes or prime factors meet prime factors, we get lesser values. (Spot checked. Still empirical.)

Examples

			{ 6},           <--- copy (1,1) of A076565, add together
{ 8,  8},       <--- copy (1,2) of A076565, reverse, and add together
{10, 10, 10},   <--- copy (1,3) of A076565, reverse, and add together
{ 6, 12, 12,  6},
{14,  8, 14,  8, 14},
{16, 16, 10, 10, 16, 16},
{ 8, 18, 18,  6, 18, 18,  8}, <=== differences with A316858 begin here
{20, 10, 20, 14, 14, 20, 10, 20},
{22, 22, 12, 16, 22, 16, 12, 22, 22},
{10, 24, 24,  8, 24, 24,  8, 24, 24, 10},
{26, 12, 26, 20, 16, 26, 16, 20, 26, 12, 26},
{ 8, 28, 14, 22, 28, 18, 18, 28, 22, 14, 28,  8}
		

Crossrefs

Cf. A076565, A316858 related triangle using lpfs.

Programs

  • Mathematica
    gpf[n_] := FactorInteger[2 n + 1][[-1, 1]]; A076565 = Array[gpf, 12];
    a = Table[A076565[[1 ;; -n]] + Reverse[A076565[[1 ;; -n]]],
      {n, Length[A076565], 1, -1}];

A316858 Triangle read by rows constructed from A090368 as sum of least prime factors.

Original entry on oeis.org

6, 8, 8, 10, 10, 10, 6, 12, 12, 6, 14, 8, 14, 8, 14, 16, 16, 10, 10, 16, 16, 6, 18, 18, 6, 18, 18, 6, 20, 8, 20, 14, 14, 20, 8, 20, 22, 22, 10, 16, 22, 16, 10, 22, 22, 6, 24, 24, 6, 24, 24, 6, 24, 24, 6, 26, 8, 26, 20, 14, 26, 14, 20, 26, 8, 26, 8, 28, 10, 22, 28, 16, 16, 28, 22, 10, 28, 8
Offset: 1

Author

Fred Daniel Kline, Jul 15 2018

Keywords

Comments

The greatest number in row k is 2*k + 4, thus consecutive rows identify consecutive even numbers (sums of two primes).
To get the n-th row: copy (1...n) of A090368, reverse, and add together.
When primes meet primes we get the maximum values. When primes or prime factors meet prime factors, we get lesser values. (Spot checked. Still empirical.)

Examples

			Triangle begins:
{ 6},         <--- copy (1,1) of A090368, add together
{ 8,  8},     <--- copy (1,2) of A090368, reverse, and add together
{10, 10, 10}, <--- copy (1,3) of A090368, reverse, and add together
{ 6, 12, 12,  6},
{14,  8, 14,  8, 14},
{16, 16, 10, 10, 16, 16},
{ 6, 18, 18,  6, 18, 18,  6}, <=== differences from A316859 begin here
{20,  8, 20, 14, 14, 20,  8, 20},
{22, 22, 10, 16, 22, 16, 10, 22, 22},
{ 6, 24, 24,  6, 24, 24,  6, 24, 24,  6},
{26,  8, 26, 20, 14, 26, 14, 20, 26,  8, 26},
{ 8, 28, 10, 22, 28, 16, 16, 28, 22, 10, 28,  8}
		

Crossrefs

Cf. A090368, A316859 (related triangle using gpfs).

Programs

  • Mathematica
    lpf[n_] := FactorInteger[2 n + 1][[1, 1]]; A090368 = Array[lpf, 12];
    a = Flatten[Table[A090368[[1 ;; -n]] + Reverse[A090368[[1 ;; -n]]],
        {n, Length[A090368], 1, -1}]];

A297446 a(1) = 1; a(n) = (2^n - 1)*((3^n - 1)/(2^n - 1) mod 1), n >= 2. Unreduced numerators of fractional parts of (3^n - 1)/(2^n - 1).

Original entry on oeis.org

1, 2, 5, 5, 25, 35, 27, 185, 264, 737, 1104, 3185, 5268, 15515, 29727, 55760, 35227, 235277, 441474, 272525, 1861165, 3478865, 6231072, 1899170, 5672261, 50533340, 17325481, 186108950, 21328108, 63792575, 1264831924, 3794064335, 7086578553
Offset: 1

Author

Fred Daniel Kline, Dec 30 2017

Keywords

Comments

An easy way to get the numerator of the fractional part of the proper fraction (3/2)^n is (3^n - 2^n) (mod 2^n), which is not considered an elementary function. So, we created a function that subtracted the denominator from this difference until we got a sign change from positive to negative. I asked if this might be considered elementary at the Kline-Iwaniuk link. Mariusz Iwaniuk noticed the similarity to the sawtooth wave, and crafted a closed form for the floor of (3/2)^n from which we can get the modulus value for the numerator.
A back-of-the-envelope proof sketch of Waring's Problem.
We start with the original Diophantine equation from A060692, which we designate as x(n)+y(n), and substitute it into the "if statement" from Wikipedia Waring's Problem link: "if x(n) + y(n) <= 2^n." This has had no proof because we need more information.
So we extend the expression to three variables, (x,y,z), with z as the numerator of the fractional part of (3^n-1)/(2^n-1), and add the restriction that x is the common floor of (3^n - 1) / (2^n - 1) and 3^n / 2^n.
We find an identity for n >= 2, x(n) + y(n) == z(n) + 1, and substitute it into the if statement: "if x(n) + y(n) == z(n) + 1 <= 2^n."
Since the numerator of the fractional part must be within the bounds, 1 < z < 2^n -1, we determine that the greatest possible value of z is 2^n -2. Substituting for z(n), "if 2^n - 2 + 1 <= 2^n," shows it is always True. And more importantly, the Diophantine equation is always less than 2^n.
Inspection of z[1] shows it is also always True, with and without the anomaly. So, Waring is shown for n >= 1.

Crossrefs

Programs

  • GAP
    Concatenation([1],List([2..35],n->(3^n-1) mod (2^n-1))); # Muniru A Asiru, Dec 19 2018
    
  • Magma
    [1] cat [(3^n-1) mod (2^n -1): n in [2..30]]; // G. C. Greubel, Dec 16 2018
    
  • Maple
    a:=n->`if`(n=1,1,modp(3^n-1,2^n-1)): seq(a(n),n=1..35); # Muniru A Asiru, Dec 19 2018
  • Mathematica
    x[n_] := -(1/2) + (3/2)^n + ArcTan[Cot[(3/2)^n Pi]]/Pi;
    y[n_] := 3^n - 2^n * x[n];
    z[n_] := x[n] + y[n] - 1;
    Array[z, {33}]
    f[n_] := PowerMod[3, n, 2^n -1] -1; f[1] = 1; f[2] = 2; Array[f, 33] (* Robert G. Wilson v, Jan 05 2018 *)
  • PARI
    a(n) = if (n==1, 1, (3^n-1) % (2^n-1)); \\ Michel Marcus, Jan 02 2018
    
  • Python
    def A297446(n): return pow(3,n,(1<2 else n # Chai Wah Wu, Jun 25 2024
  • Sage
    [1] + [mod(3^n-1, 2^n-1) for n in (2..30)] # G. C. Greubel, Dec 16 2018
    

Formula

a(1) = 1; a(n) = (2^n - 1)*((3^n - 1)/(2^n - 1) mod 1), n >= 2, is the conventional way to describe the sequence. z(n) is the closed form which includes the anomaly.
a(n) = z(n).
x(n) := (3/2)^n + ( tan^-1 ( cot( Pi * (3/2)^n ) ) ) / Pi - 1/2;
y(n) := 3^n - 2^n * x(n);
z(n) := x(n) + y(n) - 1.
a(n) = A060692(n) - 1. - Fred Daniel Kline, Dec 13 2018

A214869 Decimal expansion of Sum_{n >= 1} n!/(2*n)!.

Original entry on oeis.org

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

Author

Fred Daniel Kline, Mar 11 2013

Keywords

Comments

Equivalent to: 1/2 e^(1/4) Pi^(1/2) erf(1/2) where erf(1/2) is error function.

Examples

			0.5922965364693265756604150545390626872846166122169...
		

Programs

  • Maple
    evalf(1/2*exp(1/4)*Pi^(1/2)*erf(1/2),120) # Vaclav Kotesovec, Oct 16 2014
  • Mathematica
    NSum[n!/(2 n)!, {n, 1, Infinity}, WorkingPrecision -> 105]
    RealDigits[1/2*E^(1/4)*Sqrt[Pi]*Erf[1/2], 10, 105][[1]] (* Jean-François Alcover, Feb 20 2014 *)
  • PARI
    /* needs GP version >= 2.6 */
    N=200;
    default(realprecision, N+10);
    s=suminf(n=1,n!/(2*n)!);
    digits( floor( 10^N*s ), 10 )
    /* Joerg Arndt, Mar 11 2013 */

A219734 Decimal expansion of 1/s, where s = Sum_{n>=1} 1/p(n), where p(n) is the product of numbers n^2 + 1 to (n+1)^2 - 1.

Original entry on oeis.org

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

Author

Fred Daniel Kline, Nov 26 2012

Keywords

Comments

Decimal expansion of reciprocal of sum of reciprocal of product of numbers between perfect squares.

Examples

			5.9786377666105440959755656271823065138015646836250...
		

Crossrefs

Cf. A219733.

Programs

  • Maple
    evalf(1/Sum(GAMMA(n^2+1)/GAMMA((n+1)^2), n=1..infinity), 120); # Vaclav Kotesovec, Mar 01 2016
  • Mathematica
    1/NSum[(1/Pochhammer[m^2 + 1, 2 m]), {m, 1, Infinity}, WorkingPrecision -> 105]

A219733 Decimal expansion of Sum_{n >= 1} 1/p(n), where p(n) is the product of numbers n^2 + 1 to (n+1)^2 - 1.

Original entry on oeis.org

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

Author

Fred Daniel Kline, Nov 26 2012

Keywords

Comments

Decimal expansion of sum of reciprocal of product of numbers between perfect squares.

Examples

			0.16726218229590580987863882056891582636342622102204...
		

Crossrefs

Cf. A219734.

Programs

  • Maple
    evalf(Sum(GAMMA(n^2+1)/GAMMA((n+1)^2), n=1..infinity), 120); # Vaclav Kotesovec, Mar 01 2016
  • Mathematica
    NSum[1/(Pochhammer[m^2 + 1, 2 m]), {m, 1, Infinity}, WorkingPrecision -> 105]