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: René Gy

René Gy's wiki page.

René Gy has authored 15 sequences. Here are the ten most recent ones:

A348153 Primes for which there is no pair (k,q) with k a positive integer and q another prime, such that p=q*(2k+1)-2k.

Original entry on oeis.org

2, 3, 5, 17, 41, 73, 89, 97, 137, 193, 233, 257, 313, 353, 449, 457, 569, 641, 809, 857, 929, 1033, 1049, 1097, 1129, 1153, 1193, 1217, 1289, 1409, 1433, 1601, 1609, 1697, 1753, 1889, 1913, 1993, 2081, 2137, 2153, 2273, 2297, 2393, 2473, 2617, 2633, 2657, 2689, 2713, 2753, 2777, 2969
Offset: 1

Author

René Gy, Oct 03 2021

Keywords

Comments

There are primes p for which there exist a positive integer k and another prime q such that p=q*(2k+1)-2k. See A136020, A091180, A136061 and the subsequent sequences. Such k is called an "order" of the prime p. Note that q is necessarily larger than 2 and that 4*k is necessarily smaller than p-1. A prime may belong to more than one order, but the primes listed in the present sequence do not belong to any order.
As soon as they are larger than 8, all members minus 1 are multiples of 8.

Crossrefs

Programs

  • Mathematica
    lim = 2000; p = 2; listc = {}; listp = {}; While[p < lim, n = 1;
    While[n <= (p - 3)/4,
      If[PrimeQ[(p + 2 n)/(2 n + 1)], n = 2*p, n = n + 1]];
    If[n == 2*p, AppendTo[listc, p]]; AppendTo[listp, p];
    p = NextPrime[p]]; Complement[listp, listc]
  • PARI
    isok(p) = {if (isprime(p), for (k=1, (p-3)/4, my(q = (p+2*k)/(2*k+1)); if ((denominator(q)==1) && isprime(q), return(0));); return (1););} \\ Michel Marcus, Oct 07 2021

Extensions

More terms from Michel Marcus, Oct 04 2021

A344380 Complement of A344378 in A172186.

Original entry on oeis.org

6, 14, 38, 42, 57, 65, 70, 93, 106, 114, 118, 138, 154, 158, 182, 186, 190, 205, 210, 217, 218, 222, 266, 277, 281, 285, 309, 326, 334, 366, 381, 390, 393, 394, 397, 398, 401, 406, 434, 457, 469, 473, 478, 493, 498, 505, 518, 542, 561, 570, 581, 606, 614, 618
Offset: 1

Author

René Gy, May 16 2021

Keywords

Comments

Terms belong to A172186 but not to A344378. Even though a(n)*(a(n)+1)*(2*a(n)+1) is squarefree, Sum_{j=1..a(n)} j^(2k) always has a prime divisor which is smaller than 2*a(n)+3, whatever k. For the integers m such that m*(m+1)*(2*m+1) is nonsquarefree, Sum_{j=1..m} j^(2k) always has a prime divisor which is smaller than 2*m+3, whatever k, because it is divisible by any prime p such that p^2 divides m*(m+1)*(2*m+1).

Examples

			14 belongs to the sequence, because it is squarefree, and Sum_{j=1..14} j^(2k) is always divisible by 29 when 14 does not divide k, and when 14 divides k, it is divisible by 13 or by 7.
		

Crossrefs

Extensions

More terms added and incorrect Mathematica program removed by Jinyuan Wang, Mar 07 2025

A344378 Positive integers m for which there exists a positive even integer 2k such that Sum_{j=1..m} j^(2k) has no prime divisor smaller than 2*m + 3.

Original entry on oeis.org

1, 2, 5, 10, 21, 29, 30, 33, 34, 41, 46, 61, 66, 69, 77, 78, 82, 86, 101, 102, 105, 109, 110, 113, 129, 133, 141, 142, 145, 165, 173, 177, 178, 185, 194, 201, 209, 213, 214, 221, 226, 230, 246, 254, 257, 258, 273, 282, 286, 290, 298, 313, 317, 321, 322, 329, 330
Offset: 1

Author

René Gy, May 16 2021

Keywords

Comments

a(n)*(a(n)+1)*(2a(n)+1) must be squarefree, so this is a subsequence of A172186. It is the complement of A344380 in A172186.
Let L= LCM_j[(p_j-1)/2], where p_j run through the set of the prime divisors of a(n)*(a(n)+1)*(2a(n)+1). For a given member a(n) any admissible k must be a multiple of L, and for any prime p smaller than a(n) such that (p-1)/2 divides L, it holds that p does not divide a(n)-Floor[a(n)/p]. But the converse is not true: 397 is squarefree and satisfies the former condition, but Sum_{j=1..397} j^(2k) is always divisible either by 17 or by 73. 397 is the smallest "false positive" with the above test. Other "false positives" are rather scarce: 397,469,478,561,885,1002,1554,1658,1702,1977,... - René Gy, Apr 15 2025

Examples

			2 belongs to the sequence since 1 + 2^(2*2) = 17 is a prime number which is larger than 2*2 + 1 = 5.
5 belongs to the sequence because 1 + 2^20 + 3^20 + 4^20 + 5^20 = 96470431101379 = 137*704163730667 has no prime divisor smaller than 2*5 + 3 = 13.
		

Crossrefs

Extensions

Incorrect Mathematica program removed by Jinyuan Wang, Mar 18 2025

A308304 a(n) = (i^n)*Sum_{k=0..n} B_k*|s(n+1,k+1)|*(n+1)^k.

Original entry on oeis.org

1, 0, 1, 0, 24, 0, 3396, 0, 1706112, 0, 2277172800, 0, 6690143635200, 0, 38006393154105600, 0, 380203596126189158400, 0, 6242084318591496668160000, 0, 159215887013285165806891008000
Offset: 0

Author

René Gy, May 19 2019

Keywords

Comments

|s(n,k)| is the unsigned Stirling number of first kind (see A008275), B_k is the Bernoulli number and i^2=-1. All even-indexed terms are positive integers, and the odd-indexed terms are zero. A generating function would be welcomed.

Crossrefs

Cf. A286483.

Programs

  • PARI
    a(n) = (I^n)*sum(k=0, n, bernfrac(k)*abs(stirling(n+1,k+1,1))*(n+1)^k); \\ Michel Marcus, May 19 2019

A316275 Lucas analog to A101361.

Original entry on oeis.org

2, 3, 3, 7, 18, 123, 2207, 271443, 599074578, 162614600673847, 97418273275323406890123, 15841633607002416873831447357889638603, 1543264591854508694059691789796980188767738307671225999544322
Offset: 0

Author

René Gy, Nov 23 2018

Keywords

Comments

This is the sequence defined by the third-order non-linear recurrence a(n+1) = a(n)*a(n-1) - a(n-2) and a(0)=2, a(1)=3, a(2)=3.

Crossrefs

Programs

  • Mathematica
    Table[LucasL[2 Fibonacci[n]], {n, 0, 10}]
    RecurrenceTable[{a[0]==2,a[1]==a[2]==3,a[n+1]==a[n]a[n-1]-a[n-2]},a,{n,20}] (* Harvey P. Dale, Mar 28 2020 *)
  • PARI
    a(n)={my(t=2*fibonacci(n)); fibonacci(t + 1) + fibonacci(t - 1)} \\ Andrew Howroyd, Mar 01 2020

Formula

a(n) = A000032(2*A000045(n)) = Lucas(2*Fibonacci(n)).

Extensions

Terms a(11) and beyond from Andrew Howroyd, Mar 01 2020

A319404 a(n) is the period of the periodic k-sequence q_k=lcm(k+1,k+2,...,k+n)/(n*binomial(k+n,n)).

Original entry on oeis.org

1, 1, 2, 3, 12, 20, 60, 105, 280, 504, 2520, 27720, 27720, 51480, 72072, 45045, 720720, 1361360, 12252240, 46558512, 33256080, 21162960, 232792560, 5354228880, 1070845776, 2059318800, 2974571600, 11473347600, 80313433200, 2329089562800, 2329089562800, 4512611027925
Offset: 1

Author

René Gy, Sep 18 2018

Keywords

Comments

For n>0, k>=0, the k-sequence q_k=lcm(k+1,k+2,...,k+n)/(n*binomial(k+n,n)) is a periodic integer sequence with period a(n).
a(n) is a divisor of A003418(n-1) and a multiple of A003418(n)/n.
a(n) = A003418(n-1) if n is a member of A027854 (a mutinous number), otherwise a(n) = A003418(n)/q^v where q^v is the highest prime power which divides n.
a(n) = A003418(n-1) iff n is a mutinous number or n is a prime number.
a(n) = A003418(n) iff n is a mutinous number.
lcm(k+1,k+2,...,k+n)/(n*binomial(k+n,n)) is a divisor of lcm(1,2,...,n)/n, therefore a(n) is also the period of the periodic k-sequence r_k= binomial(k+n,n)*lcm(1,2,...,n)/lcm(k+1,k+2,...,k+n).
Let g be the smallest multiple of A003418(n)/n such that r_g=r_0=1 and r_{g+1}=r_1=gcd(m+1,A003418(n)), then a(n)=g.
a(n+j) is a multiple of binomial(n+j-1,j).
All these statements require proofs.

Examples

			For n = 5, a(5) = 12 since from k>=0, we have lcm(k+1,k+2,k+3,k+4,k+5)/5/binomial(k+5,5) =  12,2,4,3,4,2,12,1,4,6,4,1,12,2,4,3,4,2,12,1,4,6,4,1,12,2,4,3,4,2,12,1,4,6,4,1,12,..., etc. a periodic sequence of period 12.
		

Crossrefs

Programs

  • Mathematica
    ll2[n0_, m0_] :=
    Module[{f, g, i, n = n0, m = m0}, g = 1;
      If[1 <= m <= n, Do[f = LCM[g, n - i]; g = f, {i, 0, m - 1}], f = 1];f]
    list3 = {1};
    Do[i = 0; ll = ll2[m, m]/m; b = {1, ll };a = {0, 0 };
      While[ a != b, i = i + ll;
       a = { ll2[m + i - 1, m]/(m*Binomial[m + i - 1, m]), ll2[m + i, m]/(
         m*Binomial[m + i, m])}]; AppendTo[list3, i], {m, 2, 50}]; Print[list3]

A286483 a(n) = (i^n)*Sum_{k=0..n} (k+1)*B_k*|s(n+2,k+2)|*(n+2)^k.

Original entry on oeis.org

1, 0, 5, 0, 238, 0, 51508, 0, 35028576, 0, 59053389408, 0, 209726098354368, 0, 1397532391623302400, 0, 16043549794523492290560, 0, 297285345537576037788672000, 0, 8447414796960536731803240038400
Offset: 0

Author

René Gy, May 10 2017

Keywords

Comments

|s(n,k)| is the unsigned Stirling number of first kind (see A008275), B_k is the Bernoulli number and i^2=-1. All even-indexed terms are positive integers, and the odd-indexed terms are zero. A generating function would be welcomed.

Programs

  • Mathematica
    list = {};
    nlim = 20; Do[s=(-1)^(n/2) Sum[(-1)^(n-k)*(k+1)*BernoulliB[k]*StirlingS1[n+2,k+2]*(n+2)^k,{k,0,n}];AppendTo[list,s], {n,0,nlim}]; Print[list]
  • PARI
    a(n) = (I^n)*sum(k=0, n, (k+1)*bernfrac(k)*abs(stirling(n+2,k+2,1))*(n+2)^k); \\ Michel Marcus, May 19 2019

A280300 Primes such that the Wilson quotient and the Fermat quotient satisfy 2*((p-1)!+1)/p +(2^(p-1)-1)/p == 0 (mod p).

Original entry on oeis.org

3, 9511, 13691
Offset: 1

Author

René Gy, Dec 31 2016

Keywords

Comments

No new term less than 2000000. This sequence is included in A274994 because it can be shown that Sum_{k=1..(p-1)/2} (k^(p-2))*(k^(p-1)-1) == p*((2^(p-1)-1)/p)*(2*((p-1)!+1)/p +(2^(p-1)-1)/p) (mod p^2).

Crossrefs

A274994 Primes p such that p^2 divides Sum_{k=1..(p-1)/2} (k^(p-2))*(k^(p-1)-1).

Original entry on oeis.org

3, 1093, 3511, 9511, 13691
Offset: 1

Author

René Gy, Nov 11 2016

Keywords

Comments

Any prime p divides Sum_{k=1..(p-1)/2} (k^(p-2))*(k^(p-1)-1). But a restricted list of primes p are such that p^2 divides Sum_{k=1..(p-1)/2}(k^(p-2))*(k^(p-1)-1).
Also primes p such that (2^(p-1)-1)/p == 0 (mod p) or 2*((p-1)!+1)/p +(2^(p-1)-1)/p == 0 (mod p), because it can be shown that Sum_{k=1..(p-1)/2} (k^(p-2))*(k^(p-1)-1) == p*((2^(p-1)-1)/p)*(2*((p-1)!+1)/p +(2^(p-1)-1)/p) (mod p^2).
The Wieferich primes (A001220) belong to the sequence.
No more terms up to 2000000, because A280300 has no more terms up to 2000000, and A001220 has no other terms below 4.97*10^17 (see the comments in these sequences). - René Gy, Jan 01 2017

Crossrefs

Equals the union of A001220 and A280300.

Programs

  • Mathematica
    p=3; While[p<20000, If[Mod[Sum[PowerMod[k,p-2,p^2]*(PowerMod[k,p-1,p^2]-1), {k,1,(p-1)/2}], p^2] == 0, Print [p]]; p=NextPrime[p]]
  • PARI
    is(n)=if(!isprime(n), return(0)); my(m=n^2,e=n-2); sum(k=1,n\2, Mod(k,m)^e*(Mod(k,m)^(e+1)-1))==0 && n>2 \\ Charles R Greathouse IV, Nov 13 2016

A277167 Prime numbers p such that (-1)^h + (h!)^2 == 0 (mod p^2) where h = (p-1)/2.

Original entry on oeis.org

3, 11, 31, 47, 53
Offset: 1

Author

René Gy, Oct 01 2016

Keywords

Comments

The above congruence is true modulo p for all odd primes. See A089043. But like for Wilson congruence, it is true modulo p^2, for a restricted number of primes. After 53, the next one (if any) seems very far away (>500000).
The fact that the congruence is true modulo p for all odd primes was proved by Lagrange in 1771. Using a theorem of Mathews (1892) and Eisenstein's logarithmetic rule for the Fermat quotient, the condition stated in the definition can be restated as W_p == -2q_p(2) (mod p), where W_p is the Wilson quotient of p (A007619) and q_p(2) is the Fermat quotient of p, base 2 (A007663). - John Blythe Dobson, Jul 31 2017

Examples

			(-1)^((11-1)/2)+(((11-1)/2)!)^2 = 14399 = 7*11^2*17.
		

References

  • Lagrange, "Démonstration d’un théoreme nouveau concernant les nombres premiers," Nouveaux Mémoires de l’Académie Royale des Sciences et Belles-Lettres [de Berlin], année 1771 (published 1783), 125-137.
  • G. B. Mathews, Theory of Numbers, part 1 [all published] (Cambridge, 1892), 318.

Crossrefs

Programs

  • PARI
    lista(nn) = forprime(p=3, nn, if ((((-1)^((p-1)/2)+(((p-1)/2)!)^2) % p^2) == 0, print1(p, ", "))); \\ Michel Marcus, Oct 02 2016