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-10 of 6193 results. Next

A161409 Number of reduced words of length n in the Weyl group E_6 on 6 generators and order 51840.

Original entry on oeis.org

1, 6, 20, 50, 105, 195, 329, 514, 754, 1048, 1389, 1765, 2159, 2549, 2911, 3222, 3461, 3611, 3662, 3611, 3461, 3222, 2911, 2549, 2159, 1765, 1389, 1048, 754, 514, 329, 195, 105, 50, 20, 6, 1
Offset: 0

Views

Author

John Cannon and N. J. A. Sloane, Nov 29 2009

Keywords

Examples

			Coxeter matrix:
. [1 2 3 2 2 2]
. [2 1 2 3 2 2]
. [3 2 1 3 2 2]
. [2 3 3 1 3 2]
. [2 2 2 3 1 3]
. [2 2 2 2 3 1]
		

References

  • N. Bourbaki, Groupes et algèbres de Lie, Chap. 4, 5, 6. (The group is defined in Planche V.)
  • J. E. Humphreys, Reflection Groups and Coxeter Groups, Cambridge, 1990. See under Poincaré polynomial.

Crossrefs

Programs

  • Magma
    G := CoxeterGroup(GrpFPCox, "E6");
    f := GrowthFunction(G);
    Coefficients(PolynomialRing(IntegerRing())!f);
    // Corrected by Klaus Brockhaus, Feb 12 2010
  • Mathematica
    CoefficientList[Series[((1-x^2) (1-x^5) (1-x^6) (1-x^8) (1-x^9) (1-x^12))/(1-x)^6,{x,0,40}],x] (* Harvey P. Dale, Aug 17 2011 *)

Formula

G.f.: f(2)f(5)f(6)f(8)f(9)f(12)/f(1)^6 where f(k) = 1-x^k.

A316667 Squares visited by a knight moving on a spirally numbered board always to the lowest available unvisited square.

Original entry on oeis.org

1, 10, 3, 6, 9, 4, 7, 2, 5, 8, 11, 14, 29, 32, 15, 12, 27, 24, 45, 20, 23, 44, 41, 18, 35, 38, 19, 16, 33, 30, 53, 26, 47, 22, 43, 70, 21, 40, 17, 34, 13, 28, 25, 46, 75, 42, 69, 104, 37, 62, 95, 58, 55, 86, 51, 48, 77, 114, 73, 108, 151, 68, 103, 64, 67, 36
Offset: 1

Views

Author

Daniël Karssen, Jul 10 2018, following a suggestion from N. J. A. Sloane, Jul 09 2018

Keywords

Comments

Board is numbered with the square spiral:
.
17--16--15--14--13 .
| | .
18 5---4---3 12 .
| | | | .
19 6 1---2 11 .
| | | .
20 7---8---9--10 .
| .
21--22--23--24--25--26
.
This sequence is finite: At step 2016, square 2084 is visited, after which there are no unvisited squares within one knight move.

Crossrefs

Cf. A316328 (same starting at 0), A329022 (same with diamond-shaped spiral), A316588 (variant on board with x,y >= 0).
Cf. A326924 (choose square closest to the origin), A328908 (using taxicab distance), A328909 (using sup norm); A323808, A323809.
The (x,y) coordinates of square k are (A174344(k), A274923(k)).

Programs

Formula

a(n) = A316328(n-1) + 1.

A005188 Armstrong (or pluperfect, or Plus Perfect, or narcissistic) numbers: m-digit positive numbers equal to sum of the m-th powers of their digits.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 153, 370, 371, 407, 1634, 8208, 9474, 54748, 92727, 93084, 548834, 1741725, 4210818, 9800817, 9926315, 24678050, 24678051, 88593477, 146511208, 472335975, 534494836, 912985153, 4679307774, 32164049650, 32164049651
Offset: 1

Views

Author

Keywords

Comments

A finite sequence, the 88th and last term being 115132219018763992565095597973971522401.
Let k = d_1 d_2 ... d_n in base 10; then k is in the sequence iff k = Sum_{i=1..n} d_i^n.
These are the fixed points in the "Recurring Digital Invariant Variant" described in A151543.
a(15) = A229381(3) = 8208 is the "Simpsons' narcissistic number".
If a(n) is a multiple of 10, then a(n+1) = a(n) + 1, and if a(n) == 1 (mod 10) then a(n-1) = a(n) - 1 except for n = 1, cf. Examples. - M. F. Hasler, Oct 18 2018
Named after Michael Frederick Armstrong (1941-2020), who used these numbers in his computing class at the University of Rochester in the mid 1960's. - Amiram Eldar, Mar 09 2024

Examples

			153 = 1^3 + 5^3 + 3^3,
8208 = 8^4 + 2^4 + 0^4 + 8^4,
4210818 = 4^7 + 2^7 + 1^7 + 0^7 + 8^7 + 1^7 + 8^7.
The eight terms 370, 24678050, 32164049650, 4338281769391370, 3706907995955475988644380, 19008174136254279995012734740, 186709961001538790100634132976990 and 115132219018763992565095597973971522400 end in a digit zero, therefore their successor a(n) + 1 is the next term a(n+1). This also yields the last term of the sequence. The initial a(1) = 1 is the only term ending in a digit 1 not preceded by a(n) - 1. - _M. F. Hasler_, Oct 18 2018
		

References

  • Jean-Marie De Koninck, Ces nombres qui nous fascinent, Entry 88, pp. 30-31, Ellipses, Paris 2008.
  • Lionel E. Deimel, Jr. and Michael T. Jones, Finding Pluperfect Digital Invariants: Techniques, Results and Observations, J. Rec. Math., 14 (1981), 87-108.
  • Jean-Pierre Lamoitier, Fifty Basic Exercises. SYBEX Inc., 1981.
  • Clifford A. Pickover, A Passion for Mathematics, Wiley, 2005; see p. 68.
  • Alfred S. Posamentier, Numbers: Their Tales, Types, and Treasures, Prometheus Books, 2015, pp. 242-244.
  • Joe Roberts, The Lure of the Integers, The Mathematical Association of America, 1992, page 36.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Similar to but different from A023052.
Cf. A151543.
Cf. A010343 to A010354 (bases 4 to 9). - R. J. Mathar, Jun 28 2009

Programs

  • Maple
    filter:= proc(k) local d;
    d:= 1 + ilog10(k);
    add(s^d, s=convert(k,base,10)) = k
    end proc:
    select(filter, [$1..10^6]); # Robert Israel, Jan 02 2015
  • Mathematica
    f[n_] := Plus @@ (IntegerDigits[n]^Floor[ Log[10, n] + 1]); Select[ Range[10^7], f[ # ] == # &] (* Robert G. Wilson v, May 04 2005 *)
    Select[Range[10^7],#==Total[IntegerDigits[#]^IntegerLength[#]]&] (* Harvey P. Dale, Sep 30 2011 *)
  • PARI
    is(n)=my(v=digits(n));sum(i=1,#v,v[i]^#v)==n \\ Charles R Greathouse IV, Nov 20 2012
    
  • PARI
    select( is_A005188(n)={n==vecsum([d^#n|d<-n=digits(n)])}, [0..9999]) \\ M. F. Hasler, Nov 18 2019
    
  • Python
    from itertools import combinations_with_replacement
    A005188_list = []
    for k in range(1,10):
        a = [i**k for i in range(10)]
        for b in combinations_with_replacement(range(10),k):
            x = sum(map(lambda y:a[y],b))
            if x > 0 and tuple(int(d) for d in sorted(str(x))) == b:
                A005188_list.append(x)
    A005188_list = sorted(A005188_list) # Chai Wah Wu, Aug 25 2015

Extensions

32164049651 from Amit Munje (amit.munje(AT)gmail.com), Oct 07 2006
In order to agree with the Definition, first comment modified by Jonathan Sondow, Jan 02 2015
Comment in name moved to comment section and links edited by M. F. Hasler, Oct 18 2018
"Positive" added to definition by N. J. A. Sloane, Nov 18 2019

A010926 Binomial coefficients C(10,n).

Original entry on oeis.org

1, 10, 45, 120, 210, 252, 210, 120, 45, 10, 1
Offset: 0

Views

Author

Keywords

Comments

Row 10 of A007318.

Crossrefs

Programs

A003678 Decimal expansion of the SI unit c (speed of light in vacuum), c = 299792458 meters/second.

Original entry on oeis.org

2, 9, 9, 7, 9, 2, 4, 5, 8
Offset: 9

Views

Author

Keywords

Comments

Since 1983, the speed of light has been defined to be exactly 299792458 m/s. - Ron Marcinski (ronmarcinski(AT)hotmail.com), Apr 18 2002
From Stanislav Sykora, Jun 16 2012: (Start)
General context: Within current metrological systems (SI + IAU definitions), several physics constants have been "assigned" immutable values. They thus became metrological reference points, no longer subject to experimental assessment. These should not be confused with "conventional" values of some empirical quantities (such as Josephson's constant) used in applied metrology, but not assigned, and therefore subject to possible future revisions.
Assigned metrological constants [before the inception of the 2019 SI, which introduced some changes, see below for references] and some of their combinations that appear in the OEIS include the speed of light (this sequence); magnetic permeability of vacuum (A019694); electric permittivity of vacuum (A081799); characteristic impedance of vacuum (A213610); standard gravity acceleration (A072915), standard atmosphere (A213611), Julian year (A213612), Gregorian year (A213613) and the light-year (A213614), all in basic SI units.
(End)
Prime factors of this number are 2^1, 7^1, 73^1, 293339^1. - John W. Nicholson, Jun 15 2014
c is also the speed of gravity. - Omar E. Pol, Jun 23 2017
In the 2019 SI system of units (see the second BIPM link, and A322415) one of the seven defining constants is c = 299792458 m/s. - Wolfdieter Lang, Feb 12 2019 [corrected by Ivan Panchenko, May 20 2019]

References

  • CRC Handbook for Chemistry and Physics, 75th edition, (1994-1995), Page 1-1.
  • H. J. Fischbeck and K. Fischbeck, Formulas. Facts and Constants, Springer-Verlag, NY, 2nd ed., 1987.
  • R. F. Fox and T. P. Hill, An exact value for Avogadro's number, American Scientist, 95 (No. 2, 2007), 104-107.
  • K. R. Lang, Astrophysical Data: Planets and Stars, Springer-Verlag, NY, 1991.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

More assigned constants: A003676 (h), A230458 (Δν_{Cs}), A081823 (e), A322578 (N_A), A070063 (k), A021687 (1/K_{cd}); A182999 (c^2), A183000 (c^3), A183001 (c^4), A019694, A081799, A213610, A072915, A213611, A213612, A213613, A213614.

Programs

Formula

c = 299792458 m/s (equals 299792.458 km/s).

A085823 Numbers in which all substrings are primes.

Original entry on oeis.org

2, 3, 5, 7, 23, 37, 53, 73, 373
Offset: 1

Views

Author

Zak Seidov, Jul 04 2003

Keywords

Comments

The definition implies that the number itself must be prime.
Apparently there are no such primes > 373.
From Jean-Marc Falcoz, Jan 11 2009: (Start)
This is correct.
There can't be any more terms, because they must necessarily be of the form
23737373733737... but the substring 237 is composite
or 273737373... but 273 is composite
or 5373737373... but 537 is composite
or 5737373737... but 573 is composite
or 37373737373... but 3737 is composite
or 7373737373... but 737 is composite
No other form is possible, otherwise, if the digit 2 or 5 is anywhere inside or at the end of the number, one substring-number is even or divisible by 5, and furthermore, there can't be twin digits, because one substring-number would then be divisible by 11.
Obviously, the digits 0, 1, 4, 6, 8, 9 can't appear anywhere in a term of the sequence. (End)
Subsequence of A024770 (right-truncatable primes), A068669 (noncomposite numbers in which all substrings are noncomposite). Supersequence of A202263 (primes in which all substrings and reversal substrings are primes). - Jaroslav Krizek, Jan 28 2012.
From Hieronymus Fischer, Apr 20 2012: (Start)
A more general definition is "Numbers such that all substrings of length <= 3 are primes". Proof: For numbers < 1000 this is plainly true. Suppose that there are such n >= 1000. We recognize that n must contain the string 373, as this is the only valid prime substring with the length 3. It follows, that there are substrings x37 or 73x, with any digit x. Evidently, neither x37 nor 73x are valid prime substrings, independent from the digit x. Thus, there is no number >= 1000 such that all substrings of length <= 3 are primes.
Also, numbers such that all substrings of length <= 2 are primes and the number of prime substrings of length = 3 is greater than m-3 for n <= 37373 and is greater than min(m-4,floor((m-1)/2) else; where m=floor(log_10(a(n)))+1 = number of digits. (End)

Examples

			Example : 373 is in the sequence, because 3, 7, 37, 73 and 373 are prime, but 733 is not in the sequence, because 33 is not prime.
		

Crossrefs

Programs

  • Mathematica
    Select[Prime@ Range[10^3], AllTrue[FromDigits /@ Rest@ Subsequences@ IntegerDigits@ #, PrimeQ] &] (* Michael De Vlieger, Jul 30 2018 *)

Extensions

Thanks to Mark Underwood for pointing out misprints in the first version of this sequence.
Edited by N. J. A. Sloane, Jun 20 2009 at the suggestion of Lekraj Beedassy

A018253 Divisors of 24.

Original entry on oeis.org

1, 2, 3, 4, 6, 8, 12, 24
Offset: 1

Views

Author

Keywords

Comments

The divisors of 24 greater than 1 are the only positive integers n with the property m^2 == 1 (mod n) for all integer m coprime to n. - Antonio G. Astudillo (afg_astudillo(AT)hotmail.com), Jun 10 2001
Numbers n for which all Dirichlet characters are real. - Benoit Cloitre, Apr 21 2002
These are the numbers n that are divisible by all numbers less than or equal to the square root of n. - Tanya Khovanova, Dec 10 2006 [For a proof, see the Tauvel paper in references. - Bernard Schott, Dec 20 2012]
Also, numbers n such that A160812(n) = 0. - Omar E. Pol, Jun 19 2009
It appears that these are the only positive integers n such that A160812(n) = 0. - Omar E. Pol, Nov 17 2009
24 is a highly composite number: A002182(6)=24. - Reinhard Zumkeller, Jun 21 2010
Chebolu points out that these are exactly the numbers for which the multiplication table of the integers mod n have 1s only on their diagonal, i.e., ab == 1 (mod n) implies a = b (mod n). - Charles R Greathouse IV, Jul 06 2011
It appears that 3, 4, 6, 8, 12, 24 (the divisors >= 3 of 24) are also the only numbers n whose proper non-divisors k are prime numbers if k = d-1 and d divides n. - Omar E. Pol, Sep 23 2011
About the last Pol's comment: I have searched to 10^7 and have found no other terms. - Robert G. Wilson v, Sep 23 2011
Sum_{i=1..8} A000005(a(i))^3 = (Sum_{i=1..8} A000005(a(i)))^2, see Kordemsky in References and Barbeau et al. in Links section. - Bruno Berselli, Dec 29 2014

Examples

			Square root of 12 = 3.46... and 1, 2 and 3 divide 12.
From the tenth comment: 1^3 + 2^3 + 2^3 + 3^3 + 4^3 + 4^3 + 6^3 + 8^3 = (1+2+2+3+4+4+6+8)^2 = 900. - _Bruno Berselli_, Dec 28 2014
		

References

  • Harvey Cohn, "Advanced Number Theory", Dover, chap.II, p. 38
  • Boris A. Kordemsky, The Moscow Puzzles: 359 Mathematical Recreations, C. Scribner's Sons (1972), Chapter XIII, Paragraph 349.
  • Patrick Tauvel, "Exercices d'algèbre générale et d'arithmétique", Dunod, 2004, exercice 70 page 368.

Crossrefs

Cf. A000005, A158649. - Bruno Berselli, Dec 29 2014
Cf. A303704 (with respect to Astudillo's 2001 comment above).

Programs

Formula

a(n) = A161710(n-1). - Reinhard Zumkeller, Jun 21 2009

A003173 Heegner numbers: imaginary quadratic fields with unique factorization (or class number 1).

Original entry on oeis.org

1, 2, 3, 7, 11, 19, 43, 67, 163
Offset: 1

Views

Author

Keywords

Comments

Could also be called Gauss numbers, since he discovered them. Heegner proved list is complete. - Artur Jasinski, Mar 21 2003
Numbers n such that Q(sqrt(-n)) has unique factorization into primes.
These are the squarefree values of n for which if some positive integer N can be written in the form (a/2)^2+n*(b/2)^2 for integers a and b, then every prime factor P of N which occurs to an odd power can also be written in the form (c/2)^2+n*(d/2)^2 for integers c and d. - V. Raman, Sep 17 2012, May 01 2013
Cases n = 1 and n = 2 correspond to the rings Z[i] (Gaussian integers) and Z[sqrt(-2)] = numbers of the form a + b*sqrt(-2), where a and b are integers. Other cases, satisfying a(n) == 3 (mod 4), correspond to the rings of numbers of the form (a/2) + (b/2)*sqrt(-a(n)), for integers a and b of the same parity. All these rings admit unique factorization. - V. Raman, Sep 17 2012, corrected by Eric M. Schmidt, Feb 17 2013
The Heegner numbers greater than 3 can also be found using the Kronecker symbol, as follows: A number k > 3 is a Heegner number if and only if s = Sum_{j = 1..k} j * (j|k) is prime, which happens to be negative, where (x|y) is the Kronecker symbol. Also note for these results s = -k. But if s = -k is used as the selection condition (instead of primality), then the cubes of {7, 11, 19, 43, 67, 163} are also selected, followed by these same numbers to 9th power (and presumably followed by the 27th or 81st power). - Richard R. Forberg, Jul 18 2016
Theorem: The ring of integers of the imaginary quadratic field Q(sqrt(-n)) is Euclidean iff n = 1, 2, 3, 7 and 11. (Otherwise, the ring of integers of the imaginary quadratic field Q(sqrt(-n)) is principal iff n is a term of this sequence) [Link Stark-Heegner theorem]. - Bernard Schott, Feb 07 2020
Named after the German high school teacher and radio engineer Kurt Heegner (1893-1965). - Amiram Eldar, Jun 15 2021

References

  • John H. Conway and Richard K. Guy, The Book of Numbers, Copernicus Press, NY, 1996, p. 224.
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers, 5th ed., Oxford Univ. Press, 1979, p. 213.
  • Wilfred W. J. Hulsbergen, Conjectures in Arithmetic Algebraic Geometry, Vieweg, 1994, p. 8.
  • Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See p. 143.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • Harold M. Stark, An Introduction to Number Theory. Markham, Chicago, 1970, p. 295.

Crossrefs

Cf. A003174, A005847 (for class number 2), A014602 (for discriminants of these fields), A048981, A263465.

Programs

  • Mathematica
    Union[ Select[ -NumberFieldDiscriminant[ Sqrt[-#]]& /@ Range[200], NumberFieldClassNumber[ Sqrt[-#]] == 1 & ] /. {4 -> 1, 8 -> 2}] (* Jean-François Alcover, Jan 04 2012 *)
    heegnerNums = {}; Do[s = Sum[j * KroneckerSymbol[j, k], {j, 1, k}]; If[PrimeQ[s], AppendTo[heegnerNums, {s, k}]], {k, 1, 10000}]; heegnerNums (* Richard R. Forberg, Jul 18 2016 *)
  • PARI
    select(n->qfbclassno(-n*if(n%4==3,1,4))==1, vector(200,i,i)) \\ Charles R Greathouse IV, Nov 20 2012

Formula

a(n) = A263465(n) = -A048981(6-n) for n <= 5. - Jonathan Sondow, May 28 2016

A024770 Right-truncatable primes: every prefix is prime.

Original entry on oeis.org

2, 3, 5, 7, 23, 29, 31, 37, 53, 59, 71, 73, 79, 233, 239, 293, 311, 313, 317, 373, 379, 593, 599, 719, 733, 739, 797, 2333, 2339, 2393, 2399, 2939, 3119, 3137, 3733, 3739, 3793, 3797, 5939, 7193, 7331, 7333, 7393, 23333, 23339, 23399, 23993, 29399, 31193
Offset: 1

Views

Author

Keywords

Comments

Primes in which repeatedly deleting the least significant digit gives a prime at every step until a single-digit prime remains. The sequence ends at a(83) = 73939133 = A023107(10).
The subsequence which consists of the following "chain" of consecutive right truncatable primes: 73939133, 7393913, 739391, 73939, 7393, 739, 73, 7 yields the largest sum, compared with other chains formed from subsets of this sequence: 73939133 + 7393913 + 739391 + 73939 + 7393 + 739 + 73 + 7 = 82154588. - Alexander R. Povolotsky, Jan 22 2008
Can also be seen as a table whose n-th row lists the n-digit terms; row lengths (0 for n >= 9) are given by A050986. The sequence can be constructed starting with the single-digit primes and appending, for each p in the list, the primes within 10*p and 10(p+1), formed by appending a digit to p. - M. F. Hasler, Nov 07 2018

References

  • Roozbeh Hazrat, Mathematica: A Problem-Centered Approach, Springer London 2010, pp. 86-89.
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, pages 112-113.

Crossrefs

Supersequence of A085823, A202263. Subsequence of A012883, A068669. - Jaroslav Krizek, Jan 28 2012
Supersequence of A239747.
Cf. A033664, A024785 (left-truncatable primes), A032437, A020994, A052023, A052024, A052025, A050986, A050987, A069866, A077390 (left-and-right-truncatable primes), A137812 (left-or-right truncatable primes), A254751, A254753.
Cf. A237600 for the base-16 analog.

Programs

  • Haskell
    import Data.List (inits)
    a024770 n = a024770_list !! (n-1)
    a024770_list = filter (\x ->
       all (== 1) $ map (a010051 . read) $ tail $ inits $ show x) a038618_list
    -- Reinhard Zumkeller, Nov 01 2011
    
  • Maple
    s:=[1,3,7,9]: a:=[[2],[3],[5],[7]]: l1:=1: l2:=4: do for j from l1 to l2 do for k from 1 to 4 do d:=[s[k],op(a[j])]: if(isprime(op(convert(d, base, 10, 10^nops(d)))))then a:=[op(a), d]: fi: od: od: l1:=l2+1: l2:=nops(a): if(l1>l2)then break: fi: od: seq(op(convert(a[j], base, 10, 10^nops(a[j]))),j=1..nops(a)); # Nathaniel Johnston, Jun 21 2011
  • Mathematica
    max = 100000; truncate[p_] := If[PrimeQ[q = Quotient[p, 10]], q, p]; ok[p_] := FixedPoint[ truncate, p] < 10; p = 1; A024770 = {}; While[ (p = NextPrime[p]) < max, If[ok[p], AppendTo[ A024770, p]]]; A024770 (* Jean-François Alcover, Nov 09 2011, after Pari *)
    eppQ[n_]:=AllTrue[FromDigits/@Table[Take[IntegerDigits[n],i],{i, IntegerLength[ n]-1}], PrimeQ]; Select[Prime[Range[3400]],eppQ] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Jan 14 2015 *)
  • PARI
    {fileO="b024770.txt";v=vector(100);v[1]=2;v[2]=3;v[3]=5;v[4]=7;j=4;j1=1; write(fileO,"1 2");write(fileO,"2 3");write(fileO,"3 5");write(fileO,"4 7"); until(0,if(j1>j,break);new=1;for(i=j1,j,if(new,j1=j+1;new=0);for(k=1,9, z=10*v[i]+k;if(isprime(z),j++;v[j]=z;write(fileO,j," ",z);))));} \\ Harry J. Smith, Sep 20 2008
    
  • PARI
    for(n=2, 31193, v=n; while(isprime(n), c=n; n=(c-lift(Mod(c, 10)))/10); if(n==0, print1(v, ", ")); n=v); \\ Arkadiusz Wesolowski, Mar 20 2014
    
  • PARI
    A024770=vector(9, n, p=concat(apply(t->primes([t, t+1]*10), if(n>1, p)))) \\ The list of n-digit terms, 1 <= n <= 9. Use concat(%) to "flatten" it. - M. F. Hasler, Nov 07 2018
    
  • Python
    from sympy import primerange
    p = lambda x: list(primerange(x, x+10)); A024770 = p(0); i=0
    while iA024770): A024770+=p(A024770[i]*10); i+=1 # M. F. Hasler, Mar 11 2020

A000926 Euler's "numerus idoneus" (or "numeri idonei", or idoneal, or suitable, or convenient numbers).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 15, 16, 18, 21, 22, 24, 25, 28, 30, 33, 37, 40, 42, 45, 48, 57, 58, 60, 70, 72, 78, 85, 88, 93, 102, 105, 112, 120, 130, 133, 165, 168, 177, 190, 210, 232, 240, 253, 273, 280, 312, 330, 345, 357, 385, 408, 462, 520, 760, 840, 1320, 1365, 1848
Offset: 1

Views

Author

Keywords

Comments

There are many equivalent definitions of these numbers. Based on Cox, Theorem 3.22 and Proposition 3.24 and a comment by Eric Rains (rains(AT)caltech.edu), we can say that a positive number n belongs to this sequence if and only if any of the following equivalent statements is true:
(1) Let m > 1 be an odd number relatively prime to n which can be written in the form x^2 + n*y^2 with x, y relatively prime. If the equation m = x^2 + n*y^2 has only one solution with x, y >= 0, then m is a prime number. [Euler]
(2) Every genus of quadratic forms of discriminant -4n consists of a single class. [Gauss]
(3) If a*x^2 + b*x*y + c*y^2 is a reduced quadratic form of discriminant -4n, then either b=0, a=b or a = c. [Cox]
(4) Two quadratic forms of discriminant -4n are equivalent if and only if they are properly equivalent. [Cox]
(5) The class group C(-4n) is isomorphic to (Z/2Z)^m for some integer m. [Cox]
(6) n is not of the form ab+ac+bc with 0 < a < b < c. (See proof in link below.) [Rains]
It is conjectured that the list given here is complete. Chowla showed that the list is finite and Weinberger showed that there is at most one further term.
If an additional term exists it is > 100000000. - Jud McCranie, Jun 27 2005
The terms shown are the union of {1,2,3,4,7}, A033266, A033267, A033268 and A033269 (corresponding to class numbers 1, 2, 4, 8 and 16 respectively).
Note that for n in this sequence, n+1 is either a prime, twice a prime, the square of a prime, 8 or 16. - T. D. Noe, Apr 08 2004. [This is a general theorem that is not hard to prove using genus theory. The "32" in the original comment was an error. - Tom Hagedorn (hagedorn(AT)tcnj.edu), Dec 29 2008]
Also numbers n such that for all primes p such that p is a quadratic residue (mod 4*n) and p-n is a quadratic residue (mod 4*n), p can be uniquely written into the form as x^2+n*y^2. - V. Raman, Nov 25 2013

References

  • Albert H. Beiler, Recreations in the theory of numbers, New York, Dover, (2nd ed.) 1966. See Table 97 at p. 272.
  • Z. I. Borevich and I. R. Shafarevich, Number Theory. Academic Press, NY, 1966, pp. 425-430.
  • David A. Cox, "Primes of the Form x^2 + n y^2", Wiley, 1989, Section 3.
  • J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 1848, p. 146, Ellipses, Paris 2008.
  • C. F. Gauss, Disquisitiones Arithmeticae, 1801. English translation: Yale University Press, New Haven, CT, 1966, Sections 329-334.
  • G. B. Mathews, Theory of Numbers, Chelsea, no date, p. 263.
  • Paulo Ribenboim, My Numbers, My Friends, Chapter 11, Springer-Verlag, NY, 2000.
  • Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See pp. 142-143.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, page 103.
  • A. Weil, Number theory: an approach through history; from Hammurapi to Legendre, Birkhäuser, Boston, 1984; see pp. 188, 219-226.

Crossrefs

Sequence A025052 is a subsequence.
Cf. A139642 (congruences for idoneal quadratic forms).

Programs

  • Mathematica
    noSol={}; Do[lim=Ceiling[(n-2)/3]; found=False; Do[If[n>a*b && Mod[n-a*b, a+b]==0 && Quotient[n-a*b, a+b]>b, found=True; Break[]], {a, 1, lim-1}, {b, a+1, lim}]; If[ !found, AppendTo[noSol, n]], {n, 10000}]; noSol (* T. D. Noe, Apr 08 2004 *)
  • PARI
    A000926(Nmax=1e9)={for(n=1,Nmax,for(a=1,sqrtint(n\3),for(b=a+1,(n-a)\(3*a+2),n-a<(2*a+1+b)*b & break;(n-a*b)%(a+b)==0 & next(3)));print1(n", "))} \\ M. F. Hasler, Dec 04 2007
    
  • PARI
    ok(n)=!#select(k->k<>2, quadclassunit(-4*n).cyc) \\ Andrew Howroyd, Jun 08 2018

Extensions

Edited by N. J. A. Sloane, Dec 07 2007
Showing 1-10 of 6193 results. Next