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.

Showing 1-4 of 4 results.

A115261 Prime numbers such that the absolute difference of the sum of their digits in odd positions and the sum of their digits in even positions is also a prime.

Original entry on oeis.org

2, 3, 5, 7, 13, 29, 31, 41, 47, 53, 61, 79, 83, 97, 101, 113, 137, 139, 151, 157, 163, 167, 173, 179, 191, 193, 211, 223, 227, 233, 251, 269, 277, 281, 283, 311, 313, 337, 359, 379, 383, 401, 409, 421, 431, 443, 467, 487, 541, 557, 563, 577, 599, 601, 607, 641
Offset: 1

Views

Author

Keywords

Examples

			1237 is in the sequence because it is prime and abs((7+2)-(3+1)) = 5 is prime
		

Crossrefs

Programs

  • Maple
    Df:=proc(N) j:=1; for n from 1 while j<=N do B:= convert(ithprime(n),base,10); ap:=-(sum(B[2*i],i=1..nops(B)/2)-sum(B[2*n+1],i=0..(nops(B)-1)/2)); if (isprime(abs(ap)) = true) then a[j]:=ithprime(n); j:=j+1; fi; od; end:

A004936 Numerator of (binomial(2*n-2,n-1)/n!)^2.

Original entry on oeis.org

1, 1, 1, 25, 49, 49, 121, 20449, 20449, 5909761, 17631601, 17631601, 55190041, 55190041, 55190041, 46414824481, 154341336769, 154341336769, 427538329, 585299972401, 585299972401, 983889253606081, 3438962627443561, 3438962627443561, 7596668444022826249
Offset: 1

Views

Author

Keywords

Crossrefs

Cf. A000108, A005017 (denominators).

Programs

  • Magma
    [Numerator((Catalan(n-1)/Factorial(n-1))^2): n in [1..40]]; // G. C. Greubel, Sep 12 2023
    
  • Mathematica
    Numerator[Table[(Binomial[2n-2,n-1]/n!)^2,{n,30}]] (* Harvey P. Dale, May 30 2012 *)
  • PARI
    a(n) = numerator((binomial(2*n-2,n-1)/n!)^2); \\ Michel Marcus, Jul 14 2022
    
  • SageMath
    [numerator((catalan_number(n-1)/factorial(n-1))^2) for n in range(1,41)] # G. C. Greubel, Sep 12 2023

Formula

a(n) = numerator( (A000108(n-1)/(n-1)!)^2 ). - G. C. Greubel, Sep 12 2023

A115260 Prime numbers in the sequence of the absolute difference of the sum of digits in odd positions and the sum of digits in even positions of prime numbers.

Original entry on oeis.org

2, 3, 5, 7, 2, 7, 2, 3, 3, 2, 5, 2, 5, 2, 2, 3, 5, 7, 3, 3, 2, 2, 3, 3, 7, 5, 2, 3, 7, 2, 2, 5, 2, 5, 3, 3, 5, 7, 7, 5, 2, 5, 13, 3, 2, 3, 5, 3, 2, 7, 2, 5, 5, 7, 13, 3, 5, 2, 2, 7, 13, 3, 2, 3, 5, 17, 7, 13, 5, 3, 7, 17, 13, 7, 3, 7, 7, 2, 3, 5, 5, 2, 2, 7, 3, 3, 7, 2, 3, 7, 2, 3, 7, 2, 5, 5, 3, 2, 7, 3, 5, 7
Offset: 1

Views

Author

Keywords

Comments

Primes in the sequence A115259.

Examples

			a(37) = 3 because 37th prime = 157, (7+1) - 5 = 3, 3 is prime.
		

Crossrefs

Programs

  • Maple
    select(isprime,[seq(abs(sum(convert(ithprime(a),base,10)[2*i],i=1..nops(convert (ithprime(a),base,10))/2)-sum(convert(ithprime(a),base,10)[2*i+1],i=0..(nops (convert(ithprime(a),base,10))-1)/2)),a=1..N)]);

A242780 Decimal expansion of the maximum probability that the convex hull of four points, chosen at random inside a convex planar region, is a quadrilateral (Sylvester's four-point problem).

Original entry on oeis.org

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

Views

Author

Jean-François Alcover, May 22 2014

Keywords

Comments

It is proved that this maximum probability is achieved when the region is an ellipse (or a disk). [after Steven Finch]

Examples

			0.70447988104318149995535...
		

References

  • Steven R. Finch, Mathematical Constants, Cambridge University Press, 2003, Section 8.18, p. 533.

Crossrefs

Programs

  • Mathematica
    RealDigits[1 - 35/(12*Pi^2), 10, 103] // First
  • PARI
    1 - 35/(12*Pi^2) \\ Stefano Spezia, Dec 26 2024

Formula

Equals 1 - 35/(12*Pi^2).
Showing 1-4 of 4 results.