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 71-80 of 9099 results. Next

A127817 a(n) = least k such that the remainder when 9^k is divided by k is n.

Original entry on oeis.org

2, 7, 6, 5, 38, 723, 74, 2592842671511, 11, 3827, 14, 717, 34, 59035, 21, 259, 152, 237, 62, 626131, 30, 169, 58, 25, 56, 1921, 39, 361, 65, 49, 63010, 287, 48, 55, 46, 63, 932, 3786791, 69, 69637, 230, 221, 6707, 1057, 57, 4907, 253, 681, 148, 393217991, 70
Offset: 1

Views

Author

Alexander Adamchuk, Jan 30 2007

Keywords

Examples

			For n=4, since 9^5 == 4 (mod 5) and 9^k is not congruent to 4 (mod k) for any k < 5, a(4) = 5. _Michael B. Porter_, Dec 10 2016
		

Crossrefs

Programs

  • Maple
    a127817 := [seq(0,j=1..nmax)] ; for k from 1 do n := modp(9^k,k) ; if n > 0 and n <= nmax then if op(n,a127817) = 0 then a127817 := subsop(n=k,a127817) ; print( op(1..50,a127817) ) ; fi; fi; od: # R. J. Mathar, Jul 16 2009
  • Mathematica
    t = Table[0, {10000}]; k = 1; lst = {}; While[k < 4500000000, a = PowerMod[9, k, k]; If[ a<10001 && t[[a]]==0, t[[a]]=k; Print[{a,k}]]; k++ ]; t

Extensions

a(8) <= 2592842671511 from Joe K. Crump (joecr(AT)carolina.rr.com), Feb 06 2007
I changed the Mathematica coding to reflect the current limits Robert G. Wilson v, Jul 18 2009
Value for a(8) as suggested by J. K. Crump confirmed by Hagen von Eitzen, Jul 21 2009
Authorship of a-file corrected by R. J. Mathar, Aug 24 2009

A229542 Numbers n such that (19^n - 2^n)/17 is prime.

Original entry on oeis.org

11, 19, 79, 631, 1787, 2011, 2381, 20219, 49523
Offset: 1

Views

Author

Robert Price, Sep 25 2013

Keywords

Comments

All terms are primes.
a(10) > 2*10^5.

Crossrefs

Programs

  • Mathematica
    Select[ Prime[ Range[1, 100000] ], PrimeQ[ (19^# - 2^#)/17 ]& ]
  • PARI
    is(n)=ispseudoprime((19^n-2^n)/17) \\ Charles R Greathouse IV, Jun 13 2017

A005176 Number of regular graphs with n unlabeled nodes.

Original entry on oeis.org

1, 1, 2, 2, 4, 3, 8, 6, 22, 26, 176, 546, 19002, 389454, 50314870, 2942198546, 1698517037030, 442786966117636, 649978211591622812, 429712868499646587714, 2886054228478618215888598, 8835589045148342277802657274, 152929279364927228928025482936226, 1207932509391069805495173417972533120, 99162609848561525198669168653641835566774
Offset: 0

Views

Author

Keywords

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Not necessarily connected simple regular graphs: A005176 (any degree), A051031 (triangular array), specified degree k: A000012 (k=0), A059841 (k=1), A008483 (k=2), A005638 (k=3), A033301 (k=4), A165626 (k=5), A165627 (k=6), A165628 (k=7), A180260 (k=8).
Simple regular graphs of any degree: A005177 (connected), A068932 (disconnected), this sequence (not necessarily connected).
Not necessarily connected regular simple graphs with girth at least g: this sequence (g=3), A185314 (g=4), A185315 (g=5), A185316 (g=6), A185317 (g=7), A185318 (g=8), A185319 (g=9).
Cf. A295193.

Formula

a(n) = A005177(n) + A068932(n). - David Wasserman, Mar 08 2002
Row sums of triangle A051031.

Extensions

More terms from David Wasserman, Mar 08 2002
a(15) and a(16) from Jason Kimberley, Sep 25 2009
Edited by Jason Kimberley, Jan 06 2011 and May 24 2012
a(17)-a(21) from Andrew Howroyd, Mar 08 2020
a(22)-a(24) from Andrew Howroyd, Apr 05 2020

A014127 Mirimanoff primes: primes p such that p^2 divides 3^(p-1) - 1.

Original entry on oeis.org

11, 1006003
Offset: 1

Views

Author

Keywords

Comments

Dorais and Klyve proved that there are no further terms up to 9.7*10^14.
These primes are so named after the celebrated result of Mirimanoff in 1910 (see below) that for a failure of the first case of Fermat's Last Theorem, the exponent p must satisfy the criterion stated in the definition. Lerch (see below) showed that these primes also divide the numerator of the harmonic number H(floor(p/3)). This is analogous to the fact that Wieferich primes (A001220) divide the numerator of the harmonic number H((p-1)/2). - John Blythe Dobson, Mar 02 2014, Apr 09 2015
The prime 1006003 was apparently discovered by K. E. Kloss (cf. Kloss, 1965) according to various sources. - Felix Fröhlich, Dec 08 2020
If there is no term other than 11 and 1006003, then the only solution (a, w, x, y, z) to the diophantine equation a^w + a^x = 3^y + 3^z is (5, 1, 1, 2, 3) (cf. Scott, Styer, 2006, Lemma 12). - Felix Fröhlich, Dec 10 2020
Named after the Russian mathematician Dmitry Semionovitch Mirimanoff (1861-1945). - Amiram Eldar, Jun 10 2021

References

  • Paulo Ribenboim, 13 Lectures on Fermat's Last Theorem, Springer, 1979, pp. 23, 152-153.
  • Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See p. 233.
  • Alf van der Poorten, Notes on Fermat's Last Theorem, Wiley, 1996, p. 21.

Crossrefs

Sequences "primes p such that p^2 divides X^(p-1)-1": A001220 (X=2), A123692 (X=5), A212583 (X=6), A123693 (X=7), A045616 (X=10), A111027 (X=12), A128667 (X=13), A234810 (X=14), A242741 (X=15), A128668 (X=17), A244260 (X=18), A090968 (X=19), A242982 (X=20), A298951 (X=22), A128669 (X=23), A306255 (X=26), A306256 (X=30).

Programs

  • Mathematica
    Select[Prime[Range[1000000]], PowerMod[3, # - 1, #^2] == 1 &] (* Robert Price, May 17 2019 *)
  • PARI
    N=10^9; default(primelimit,N);
    forprime(n=2,N,if(Mod(3,n^2)^(n-1)==1,print1(n,", ")));
    \\ Joerg Arndt, May 01 2013
    
  • Python
    from sympy import prime
    from gmpy2 import powmod
    A014127_list = [p for p in (prime(n) for n in range(1,10**7)) if powmod(3,p-1,p*p) == 1] # Chai Wah Wu, Dec 03 2014

Extensions

Edited by Max Alekseyev, Oct 20 2010
Updated by Max Alekseyev, Jan 29 2012

A014545 Numbers k such that the k-th Euclid number A006862(k) = 1 + (Product of first k primes) is prime.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 11, 75, 171, 172, 384, 457, 616, 643, 1391, 1613, 2122, 2647, 2673, 4413, 13494, 31260, 33237, 304723, 365071, 436504, 498865, 637491
Offset: 1

Views

Author

Keywords

Examples

			a(1) = 0 because the (empty) product of 0 primes is 1, plus 1 yields the prime 2.
prime(4413) = 42209 and Primorial(4413) + 1 = 42209# + 1 is a 18241-digit prime.
prime(13494) = 145823 and Primorial(13494) + 1 = 145823# + 1 is a 63142-digit prime.
		

References

  • J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 211, p. 61, Ellipses, Paris 2008.
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, page 114.

Crossrefs

Cf. A005234 (values of p such that 1 + product of primes <= p is prime).
Cf. A018239 (primorial plus 1 primes).

Programs

  • Maple
    P:= 1:
    p:= 1:
    count:= 0:
    for n from 1 to 1000 do
      p:= nextprime(p);
      P:= P*p;
      if isprime(P+1) then
        count:= count+1;
        A[count]:= n;
      fi
    od:
    seq(A[i], i=1..count); # Robert Israel, Nov 04 2015
  • Mathematica
    Flatten[Position[Rest[FoldList[Times,1,Prime[Range[180]]]]+1,?PrimeQ]] (* _Harvey P. Dale, May 04 2012 *) (* this program generates the first 9 positive terms of the sequence; changing the Range constant to 33237 will generate all 23 terms above, but it will take a long time to do so *)
  • PARI
    is(n)=ispseudoprime(prod(i=1,n,prime(i))+1) \\ Charles R Greathouse IV, Mar 21 2013
    
  • PARI
    P=1; n=0; forprime(p=1, 10^5, if(ispseudoprime(P+1), print1(n", ")); n=n+1; P*=p;) \\ Hans Loeblich, May 10 2019

Formula

a(n+1) = A000720(A005234(n)). - M. F. Hasler, May 31 2018

Extensions

More terms from Labos Elemer
a(21) from Arlin Anderson (starship1(AT)gmail.com), Oct 20 2000
a(22)-a(23) from Eric W. Weisstein, Mar 13 2004 (based on information in A057704)
Offset and first term changed by Altug Alkan, Nov 27 2015
a(24) from Jeppe Stig Nielsen, Aug 08 2024
a(25) from Jeppe Stig Nielsen, Sep 01 2024
a(26) from Jeppe Stig Nielsen, Sep 24 2024
a(27) from Jeppe Stig Nielsen, Nov 10 2024
a(28) from Jeppe Stig Nielsen, Aug 21 2025

A250001 Number of arrangements of n circles in the affine plane.

Original entry on oeis.org

1, 1, 3, 14, 173, 16951
Offset: 0

Views

Author

Jon Wild, May 16 2014

Keywords

Comments

Two circles are either disjoint or meet in two points. Tangential contacts are not allowed. A point belongs to exactly one or two circles. Three circles may not meet at a point. The circles may have different radii.
This is in the affine plane, rather than the projective plane.
Two arrangements are considered the same if one can be continuously changed to the other while keeping all circles circular (although the radii may be continuously changed), without changing the multiplicity of intersection points, and without a circle passing through an intersection point. Turning the whole configuration over is allowed.
Several variations are possible:
- straight lines instead of circles (see A241600).
- straight lines in general position (see A090338).
- curved lines in general position (see A090339).
- allow circles to meet tangentially but without multiple intersection points (begins 1, 5, ...); more terms are needed.
- again use circles, but allow multiple intersection points (also begins 1, 5, ...); more terms are needed.
- use ellipses rather than circles.
- a question from Walter D. Wallis: what if the circles must all have the same radius?
a(1)-a(5) computed by Jon Wild.
a(n) >= A000081(n+1) - Benoit Jubin, Dec 21 2014. More precisely, there are A000081(n+1) ways to arrange n circles if no two of them meet. - N. J. A. Sloane, May 16 2017
From Daniel Forgues, Aug 08-09 2015: (Start)
A representation for the diagrams in a250001.jpg (in the same order):
a(1) = 1: {{2}};
a(2) = 3: {{2, 3}, {2, 4}, {4, 6}};
a(3) = 14: {{2, 4, 8}, {2, 3, 6}, {2, 3, 4}, {2, 3, 5}, {4, 6, 5},
{4, 6, 15}, {2, 6, 9}, {4, 6, 12}, {2, 8, 12}, {30, 42, 70},
{?, ?, ?}, {?, ?, ?}, {15, 21, 35}, {?, ?, ?}}.
In lexicographic order:
a(3) = 14: {{2, 3, 4}, {2, 3, 5}, {2, 3, 6}, {2, 4, 8}, {2, 6, 9},
{2, 8, 12}, {4, 6, 5}, {4, 6, 12}, {4, 6, 15}, {15, 21, 35},
{30, 42, 70}, {?, ?, ?}, {?, ?, ?}, {?, ?, ?}}.
The smallest integers greater than 1 are used for the representation:
(p_1)^(a_1)*...*(p_m)^(a_m), where
0 <= a_i <= n, for 1 <= i <= m;
(a_1)+...+(a_m) > 0.
Could the Venn diagram interpretation (of the k-wise, 1 <= k <= n, common divisors of k numbers from each subset) reveal a pattern?
Does this representation work for more complex diagrams? (End)
Once you get to n=5, geometric concerns mean that not all topologically-conceivable arrangements are actually circle-drawable. My program enumerated 16977 conceivable arrangements of 5 pseudo-circles, and Christopher Jones and I together have figured out how to show that 26 of these arrangements are not actually circle-drawable. So it seems that a(5) = 16951. This entry will be updated soon, and there will be a new sequence for the number of topologically-conceivable arrangements. - Jon Wild, Aug 25 2016 [The counts in this comment were amended by Jon Wild on Aug 30 2016. I apologize for taking so long to make the corrections here. - N. J. A. Sloane, Jun 11 2017]
a(n) <= 7*13^(binomial(n,3) + binomial(n,2) + 3n - 1) is a (loose) upper bound, see Reddit link. I believe XkF21WNJ's reply shaves off a factor of 13^3 from this bound for all n > 1. - Linus Hamilton, Apr 14 2019
A good upper bound for a(6) is given in sequence A288559, which counts the arrangements of pseudo-circles, i.e. the topologically conceivable arrangements mentioned above, which are not all necessarily realizable with true circles. The number of arrangements of 6 pseudo-circles was found by Andrii Shportko and Jon Wild to be 17,552,169. - Jon Wild, Jun 03 2025
In A288559, a(5) included 26 non-circularizable pseudocircle arrangements, which generated in turn 132,546 6-pseudocircle descendants. These descendants must be excluded from A250001, which means that a tighter upper bound for A250001(6) is 17,419,623. - Andrii Shportko, Jun 06 2025

Examples

			a(2) = 3, because two circles can either be next to each other, overlap with two intersection points, or one may be located within the other (of larger radius). (As per the first comment, the limiting case where they touch in one point is [somewhat arbitrarily] excluded. This would add two more independent configurations, where one touched the other "from inside" or "from outside".) - _M. F. Hasler_, May 03 2025
		

References

  • Jon Wild, Posting to Sequence Fans Mailing List, May 15 2014.

Crossrefs

Row sums of A261070.
Apart from first term, row sums of triangles A249752, A252158, A285996, A274776, A274777.
See A275923 and A275924 for the connected arrangements. See also A288554-A288568.
Cf. A132101 (one-dimensional analog).

Extensions

a(4) is 173, not 168. Corrected by Jon Wild, Aug 08 2015
A duplicate pair of configurations in an older file was spotted by Manfred Scheucher, Aug 13 2016. The pdf and svg files here are now correct.

A375161 Numbers k such that (23^k - 2^k)/21 is prime.

Original entry on oeis.org

5, 11, 197, 4159
Offset: 1

Views

Author

Robert Price, Aug 04 2024

Keywords

Comments

The definition implies that k must be a prime.
a(5) > 10^5.

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[100]], PrimeQ[(23^# - 2^#)/21] &]

A007764 Number of nonintersecting (or self-avoiding) rook paths joining opposite corners of an n X n grid.

Original entry on oeis.org

1, 2, 12, 184, 8512, 1262816, 575780564, 789360053252, 3266598486981642, 41044208702632496804, 1568758030464750013214100, 182413291514248049241470885236, 64528039343270018963357185158482118, 69450664761521361664274701548907358996488
Offset: 1

Views

Author

Keywords

Comments

The length of the path varies.

Examples

			Suppose we start at (1,1) and end at (n,n). Let U, D, L, R denote steps that are up, down, left, right.
a(2) = 2: UR or RU.
a(3) = 12: UURR, UURDRU, UURDDRUU, URUR, URRU, URDRUU and their reflections in the x=y line.
		

References

  • Steven R. Finch, Mathematical Constants, Cambridge, 2003, section 5.10, pp. 331-338.
  • Guttmann A J and Jensen I 2022 Self-avoiding walks and polygons crossing a domain on the square and hexagonal lattices Journal of Physics A: Mathematical and Theoretical 55 012345, (33pp) ; arXiv:2208.06744, Aug 2022.
  • D. E. Knuth, 'Things A Computer Scientist Rarely Talks About,' CSLI Publications, Stanford, CA, 2001, pages 27-28.
  • D. E. Knuth, The Art of Computer Programming, Section 7.1.4.
  • Shin-ichi Minato, The power of enumeration - BDD/ZDD-based algorithms for tackling combinatorial explosion, Chapter 3 of Applications of Zero-Suppressed Decision Diagrams, ed. T. Satsoa and J. T. Butler, Morgan & Claypool Publishers, 2014
  • Shin-ichi Minato, Counting by ZDD, Encyclopedia of Algorithms, 2014, pp. 1-6.
  • Netnews group rec.puzzles, Frequently Asked Questions (FAQ) file. (Science Section).

Crossrefs

Main diagonal of A064298.

Programs

  • Python
    # Using graphillion
    from graphillion import GraphSet
    import graphillion.tutorial as tl
    def A007764(n):
        if n == 1: return 1
        universe = tl.grid(n - 1, n - 1)
        GraphSet.set_universe(universe)
        start, goal = 1, n * n
        paths = GraphSet.paths(start, goal)
        return paths.len()
    print([A007764(n) for n in range(1, 10)])  # Seiichi Manyama, Mar 21 2020

Extensions

Computed to n=12 by John Van Rosendale in 1981
Extended to n=13 by Don Knuth, Dec 07 1995
Extended to n=20 by Mireille Bousquet-Mélou, A. J. Guttmann and I. Jensen
Extended to n=22 using ZDD technique based on Knuth's The Art of Computer Programming (exercise 225 in 7.1.4) by H. Iwashita, J. Kawahara, and S. Minato, Sep 18 2012
Extended to n=25 using state space compression (with rank/unrank) and dynamic programming (based in I. Jensen) by Ruben Grønning Spaans, Feb 22 2013
Extended to n=26 by Hiroaki Iwashita, Apr 11 2013
Extended to n=27 by Hiroaki Iwashita, Nov 18 2013

A375236 Numbers k such that (21^k - 2^k)/19 is prime.

Original entry on oeis.org

2, 3, 353, 751, 9587
Offset: 1

Views

Author

Robert Price, Aug 06 2024

Keywords

Comments

The definition implies that k must be a prime.
a(6) > 10^5.

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[100]], PrimeQ[(21^# - 2^#)/19] &]

A005266 a(1)=3, b(n) = Product_{k=1..n} a(k), a(n+1) is the largest prime factor of (b(n)-1).

Original entry on oeis.org

3, 2, 5, 29, 79, 68729, 3739, 6221191, 157170297801581, 70724343608203457341903, 46316297682014731387158877659877, 78592684042614093322289223662773, 181891012640244955605725966274974474087, 547275580337664165337990140111772164867508038795347198579326533639132704344301831464707648235639448747816483406685904347568344407941
Offset: 1

Views

Author

Keywords

Comments

Suggested by Euclid's proof that there are infinitely many primes.
a(15) requires completing the factorization: 13 * 67 * 14479 * 167197 * 924769 * 2688244927 * 888838110930755119 * 14372541055015356634061816579965403 * C211 where C211=6609133306626483634448666494646737799624640616060730302142187545405582531010390290502001156883917023202671554510633460047901459959959325342475132778791495112937562941066523907603281586796876335607258627832127303. - Sean A. Irvine, Nov 10 2009

References

  • R. K. Guy and R. Nowakowski, Discovering primes with Euclid, Delta (Waukesha), Vol. 5, pp. 49-63, 1975.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • S. S. Wagstaff, Jr., Computing Euclid's primes, Bull. Institute Combin. Applications, 8 (1993), 23-32.

Crossrefs

Essentially the same as A084599.

Programs

  • Maple
    with(numtheory):
    a:= proc(n) option remember;
          `if`(n=1, 3, max(factorset(mul(a(i), i=1..n-1)-1)[]))
        end:
    seq(a(n), n=1..10);  # Alois P. Heinz, Sep 26 2013
  • Mathematica
    a[0] = 3; a[n_] := a[n] = Block[{p = Times @@ (a[#] & /@ Range[0, n - 1]) - 1}, FactorInteger[p][[-1, 1]]]; Array[a, 13] (* Robert G. Wilson v, Sep 26 2013 *)

Extensions

a(14) from Joe K. Crump (joecr(AT)carolina.rr.com), Jul 26 2000
Previous Showing 71-80 of 9099 results. Next