A106856 Primes of the form x^2 + xy + 2y^2, with x and y nonnegative.
2, 11, 23, 37, 43, 53, 71, 79, 107, 109, 127, 137, 149, 151, 163, 193, 197, 211, 233, 239, 263, 281, 317, 331, 337, 373, 389, 401, 421, 431, 443, 463, 487, 491, 499, 541, 547, 557, 569, 599, 613, 617, 641, 653, 659, 673, 683, 739, 743, 751, 757, 809, 821
Offset: 1
A000124 Central polygonal numbers (the Lazy Caterer's sequence): n(n+1)/2 + 1; or, maximal number of pieces formed when slicing a pancake with n cuts.
1, 2, 4, 7, 11, 16, 22, 29, 37, 46, 56, 67, 79, 92, 106, 121, 137, 154, 172, 191, 211, 232, 254, 277, 301, 326, 352, 379, 407, 436, 466, 497, 529, 562, 596, 631, 667, 704, 742, 781, 821, 862, 904, 947, 991, 1036, 1082, 1129, 1177, 1226, 1276, 1327, 1379
Offset: 0
Comments
These are Hogben's central polygonal numbers with the (two-dimensional) symbol
2
.P
1 n
The first line cuts the pancake into 2 pieces. For n > 1, the n-th line crosses every earlier line (avoids parallelism) and also avoids every previous line intersection, thus increasing the number of pieces by n. For 16 lines, for example, the number of pieces is 2 + 2 + 3 + 4 + 5 + ... + 16 = 137. These are the triangular numbers plus 1 (cf. A000217).
m = (n-1)(n-2)/2 + 1 is also the smallest number of edges such that all graphs with n nodes and m edges are connected. - Keith Briggs, May 14 2004
Also maximal number of grandchildren of a binary vector of length n+2. E.g., a binary vector of length 6 can produce at most 11 different vectors when 2 bits are deleted.
This is also the order dimension of the (strong) Bruhat order on the finite Coxeter group B_{n+1}. - Nathan Reading (reading(AT)math.umn.edu), Mar 07 2002
Number of 132- and 321-avoiding permutations of {1,2,...,n+1}. - Emeric Deutsch, Mar 14 2002
For n >= 1 a(n) is the number of terms in the expansion of (x+y)*(x^2+y^2)*(x^3+y^3)*...*(x^n+y^n). - Yuval Dekel (dekelyuval(AT)hotmail.com), Jul 28 2003
Also the number of terms in (1)(x+1)(x^2+x+1)...(x^n+...+x+1); see A000140.
Narayana transform (analog of the binomial transform) of vector [1, 1, 0, 0, 0, ...] = A000124; using the infinite lower Narayana triangle of A001263 (as a matrix), N; then N * [1, 1, 0, 0, 0, ...] = A000124. - Gary W. Adamson, Apr 28 2005
Number of interval subsets of {1, 2, 3, ..., n} (cf. A002662). - Jose Luis Arregui (arregui(AT)unizar.es), Jun 27 2006
Define a number of straight lines in the plane to be in general arrangement when (1) no two lines are parallel, (2) there is no point common to three lines. Then these are the maximal numbers of regions defined by n straight lines in general arrangement in the plane. - Peter C. Heinig (algorithms(AT)gmx.de), Oct 19 2006
Note that a(n) = a(n-1) + A000027(n-1). This has the following geometrical interpretation: Suppose there are already n-1 lines in general arrangement, thus defining the maximal number of regions in the plane obtainable by n-1 lines and now one more line is added in general arrangement. Then it will cut each of the n-1 lines and acquire intersection points which are in general arrangement. (See the comments on A000027 for general arrangement with points.) These points on the new line define the maximal number of regions in 1-space definable by n-1 points, hence this is A000027(n-1), where for A000027 an offset of 0 is assumed, that is, A000027(n-1) = (n+1)-1 = n. Each of these regions acts as a dividing wall, thereby creating as many new regions in addition to the a(n-1) regions already there, hence a(n) = a(n-1) + A000027(n-1). Cf. the comments on A000125 for an analogous interpretation. - Peter C. Heinig (algorithms(AT)gmx.de), Oct 19 2006
When constructing a zonohedron, one zone at a time, out of (up to) 3-d non-intersecting parallelepipeds, the n-th element of this sequence is the number of edges in the n-th zone added with the n-th "layer" of parallelepipeds. (Verified up to 10-zone zonohedron, the enneacontahedron.) E.g., adding the 10th zone to the enneacontahedron requires 46 parallel edges (edges in the 10th zone) by looking directly at a 5-valence vertex and counting visible vertices. - Shel Kaphan, Feb 16 2006
Binomial transform of (1, 1, 1, 0, 0, 0, ...) and inverse binomial transform of A072863: (1, 3, 9, 26, 72, 192, ...). - Gary W. Adamson, Oct 15 2007
If Y is a 2-subset of an n-set X then, for n >= 3, a(n-3) is the number of (n-2)-subsets of X which do not have exactly one element in common with Y. - Milan Janjic, Dec 28 2007
Equals row sums of triangle A144328. - Gary W. Adamson, Sep 18 2008
It appears that a(n) is the number of distinct values among the fractions F(i+1)/F(j+1) as j ranges from 1 to n and, for each fixed j, i ranges from 1 to j, where F(i) denotes the i-th Fibonacci number. - John W. Layman, Dec 02 2008
a(n) is the number of subsets of {1,2,...,n} that contain at most two elements. - Geoffrey Critzer, Mar 10 2009
For n >= 2, a(n) gives the number of sets of subsets A_1, A_2, ..., A_n of n = {1, 2, ..., n} such that Meet_{i = 1..n} A_i is empty and Sum_{j in [n]} (|Meet{i = 1..n, i != j} A_i|) is a maximum. - Srikanth K S, Oct 22 2009
The numbers along the left edge of Floyd's triangle. - Paul Muljadi, Jan 25 2010
Let A be the Hessenberg matrix of order n, defined by: A[1,j] = A[i,i]:=1, A[i,i-1] = -1, and A[i,j] = 0 otherwise. Then, for n >= 1, a(n-1) = (-1)^(n-1)*coeff(charpoly(A,x),x). - Milan Janjic, Jan 24 2010
Also the number of deck entries of Euler's ship. See the Meijer-Nepveu link. - Johannes W. Meijer, Jun 21 2010
(1 + x^2 + x^3 + x^4 + x^5 + ...)*(1 + 2x + 3x^2 + 4x^3 + 5x^4 + ...) = (1 + 2x + 4x^2 + 7x^3 + 11x^4 + ...). - Gary W. Adamson, Jul 27 2010
The number of length n binary words that have no 0-digits between any pair of consecutive 1-digits. - Jeffrey Liese, Dec 23 2010
Let b(0) = b(1) = 1; b(n) = max(b(n-1)+n-1, b(n-2)+n-2) then a(n) = b(n+1). - Yalcin Aktar, Jul 28 2011
Also number of triangular numbers so far, for n > 0: a(n) = a(n-1) + Sum(A010054(a(k)): 0 <= k < n), see also A097602, A131073. - Reinhard Zumkeller, Nov 15 2012
Also number of distinct sums of 1 through n where each of those can be + or -. E.g., {1+2,1-2,-1+2,-1-2} = {3,-1,1,-3} and a(2) = 4. - Toby Gottfried, Nov 17 2011
This sequence is complete because the sum of the first n terms is always greater than or equal to a(n+1)-1. Consequently, any nonnegative number can be written as a sum of distinct terms of this sequence. See A204009, A072638. - Frank M Jackson, Jan 09 2012
The sequence is the number of distinct sums of subsets of the nonnegative integers, and its first differences are the positive integers. See A208531 for similar results for the squares. - John W. Layman, Feb 28 2012
Apparently the number of Dyck paths of semilength n+1 in which the sum of the first and second ascents add to n+1. - David Scambler, Apr 22 2013
Without 1 and 2, a(n) equals the terminus of the n-th partial sum of sequence 1, 1, 2. Explanation: 1st partial sums of 1, 1, 2 are 1, 2, 4; 2nd partial sums are 1, 3, 7; 3rd partial sums are 1, 4, 11; 4th partial sums are 1, 5, 16, etc. - Bob Selcoe, Jul 04 2013
Equivalently, numbers of the form 2*m^2+m+1, where m = 0, -1, 1, -2, 2, -3, 3, ... . - Bruno Berselli, Apr 08 2014
For n >= 2: quasi-triangular numbers; the almost-triangular numbers being A000096(n), n >= 2. Note that 2 is simultaneously almost-triangular and quasi-triangular. - Daniel Forgues, Apr 21 2015
n points in general position determine "n choose 2" lines, so A055503(n) <= a(n(n-1)/2). If n > 3, the lines are not in general position and so A055503(n) < a(n(n-1)/2). - Jonathan Sondow, Dec 01 2015
The digital root is period 9 (1, 2, 4, 7, 2, 7, 4, 2, 1), also the digital roots of centered 10-gonal numbers (A062786), for n > 0, A133292. - Peter M. Chema, Sep 15 2016
For n >= 0, a(n) is the number of weakly unimodal sequences of length n over the alphabet {1, 2}. - Armend Shabani, Mar 10 2017
From Eric M. Schmidt, Jul 17 2017: (Start)
Number of sequences (e(1), ..., e(n+1)), 0 <= e(i) < i, such that there is no triple i < j < k with e(i) < e(j) != e(k). [Martinez and Savage, 2.4]
Number of sequences (e(1), ..., e(n+1)), 0 <= e(i) < i, such that there is no triple i < j < k with e(i) < e(j) and e(i) < e(k). [Martinez and Savage, 2.4]
Number of sequences (e(1), ..., e(n+1)), 0 <= e(i) < i, such that there is no triple i < j < k with e(i) >= e(j) != e(k). [Martinez and Savage, 2.4]
(End)
Numbers m such that 8m - 7 is a square. - Bruce J. Nicholson, Jul 24 2017
From Klaus Purath, Jan 29 2020: (Start)
The odd prime factors != 7 occur in an interval of p successive terms either never or exactly twice, while 7 always occurs only once. If a prime factor p appears in a(n) and a(m) within such an interval, then n + m == -1 (mod p). When 7 divides a(n), then 2*n == -1 (mod 7). a(n) is never divisible by the prime numbers given in A003625.
While all prime factors p != 7 can occur to any power, a(n) is never divisible by 7^2. The prime factors are given in A045373. The prime terms of this sequence are given in A055469.
(End)
From Roger Ford, May 10 2021: (Start)
a(n-1) is the greatest sum of arch lengths for the top arches of a semi-meander with n arches. An arch length is the number of arches covered + 1.
/\ The top arch has a length of 3. /\ The top arch has a length of 3.
/ \ Both bottom arches have a //\\ The middle arch has a length of 2.
//\/\\ length of 1. ///\\\ The bottom arch has a length of 1.
Example: for n = 4, a(4-1) = a(3) = 7 /\
//\\
/\ ///\\\ 1 + 3 + 2 + 1 = 7. (End)
a(n+1) is the a(n)-th smallest positive integer that has not yet appeared in the sequence. - Matthew Malone, Aug 26 2021
For n> 0, let the n-dimensional cube {0,1}^n be, provided with the Hamming distance, d. Given an element x in {0,1}^n, a(n) is the number of elements y in {0,1}^n such that d(x, y) <= 2. Example: n = 4. (0,0,0,0), (1,0,0,0), (0,1,0,0), (0,0,1,0), (0,0,0,1), (0,0,1,1), (0,1,0,1), (0,1,1,0), (1,0,0,1), (1,0,1,0), (1,1,0,0) are at distance <= 2 from (0,0,0,0), so a(4) = 11. - Yosu Yurramendi, Dec 10 2021
a(n) is the sum of the first three entries of row n of Pascal's triangle. - Daniel T. Martin, Apr 13 2022
a(n-1) is the number of Grassmannian permutations that avoid a pattern, sigma, where sigma is a pattern of size 3 with exactly one descent. For example, sigma is one of the patterns, {132, 213, 231, 312}. - Jessica A. Tomasko, Sep 14 2022
a(n+4) is the number of ways to tile an equilateral triangle of side length 2*n with smaller equilateral triangles of side length n and side length 1. For example, with n=2, there are 22 ways to tile an equilateral triangle of side length 4 with smaller ones of sides 2 and 1, including the one tiling with sixteen triangles of sides 1 and the one tiling with four triangles of sides 2. - Ahmed ElKhatib and Greg Dresden, Aug 19 2024
Define a "hatpin" to be the planar graph consisting of a distinguished point (called the "head") and a semi-infinite line from that point. The maximum number of regions than can be formed by drawing n hatpins is a(n-1). See link for the case n = 4. - N. J. A. Sloane, Jun 25 2025
Examples
a(3) = 7 because the 132- and 321-avoiding permutations of {1, 2, 3, 4} are 1234, 2134, 3124, 2314, 4123, 3412, 2341. G.f. = 1 + 2*x + 4*x^2 + 7*x^3 + 11*x^4 + 16*x^5 + 22*x^6 + 29*x^7 + ...
References
- Robert B. Banks, Slicing Pizzas, Racing Turtles and Further Adventures in Applied Mathematics, Princeton Univ. Press, 1999. See p. 24.
- Louis Comtet, Advanced Combinatorics, Reidel, 1974, p. 72, Problem 2.
- John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See p. 80.
- Henry Ernest Dudeney, Amusements in Mathematics, Nelson, London, 1917, page 177.
- Derrick Niederman, Number Freak, From 1 to 200 The Hidden Language of Numbers Revealed, A Perigee Book, NY, 2009, p. 83.
- Michel Rigo, Formal Languages, Automata and Numeration Systems, 2 vols., Wiley, 2014. Mentions this sequence - see "List of Sequences" in Vol. 2.
- Alain M. Robert, A Course in p-adic Analysis, Springer-Verlag, 2000; p. 213.
- N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
- N. J. A. Sloane, On single-deletion-correcting codes, in Codes and Designs (Columbus, OH, 2000), 273-291, Ohio State Univ. Math. Res. Inst. Publ., 10, de Gruyter, Berlin, 2002.
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- David Wells, The Penguin Dictionary of Curious and Interesting Numbers. Penguin Books, NY, 1986, Revised edition 1987. See p. 98.
- William Allen Whitworth, DCC Exercises in Choice and Chance, Stechert, NY, 1945, p. 30.
- Akiva M. Yaglom and Isaak M. Yaglom, Challenging Mathematical Problems with Elementary Solutions. Vol. I. Combinatorial Analysis and Probability Theory. New York: Dover Publications, Inc., 1987, p. 13, #44 (First published: San Francisco: Holden-Day, Inc., 1964).
Links
- T. D. Noe, Table of n, a(n) for n = 0..1000
- David Applegate and N. J. A. Sloane, The Gift Exchange Problem, arXiv:0907.0513 [math.CO], 2009.
- Jean-Luc Baril, Classical sequences revisited with permutations avoiding dotted pattern, Electronic Journal of Combinatorics, 18 (2011), #P178.
- Jean-Luc Baril and Céline Moreira Dos Santos, Pizza-cutter's problem and Hamiltonian path, Mathematics Magazine (2019) Vol. 88, No. 1, 1-9.
- Jean-Luc Baril, Sergey Kirgizov, and Vincent Vajnovszki, Descent distribution on Catalan words avoiding a pattern of length at most three, arXiv:1803.06706 [math.CO], 2018.
- Jean-Luc Baril, Toufik Mansour, and Armen Petrossian, Equivalence classes of permutations modulo excedances, preprint, Journal of Combinatorics, Volume 5 (2014) Number 4.
- Jean-Luc Baril and Armen Petrossian, Equivalence classes of permutations modulo descents and left-to-right maxima, preprint, Pure Mathematics and Applications, Volume 25, Issue 1 (Sep 2015).
- Andrew M. Baxter and Lara K. Pudwell, Ascent sequences avoiding pairs of patterns, preprint, The Electronic Journal of Combinatorics, Volume 22, Issue 1 (2015) Paper #P1.58.
- Christian Bean, Anders Claesson, and Henning Ulfarsson, Simultaneous Avoidance of a Vincular and a Covincular Pattern of Length 3, arXiv preprint arXiv:1512.03226 [math.CO], 2017.
- Henry Bottomley, Illustration of initial terms.
- Alexander Burstein and Toufik Mansour, Words restricted by 3-letter generalized multipermutation patterns, arXiv:math/0112281 [math.CO], 2001.
- Alexander Burstein and Toufik Mansour, Words restricted by 3-letter generalized multipermutation patterns, Annals. Combin., 7 (2003), 1-14.
- Yurii S. Bystryk, Vitalii L. Denysenko, and Volodymyr I. Ostryk, Lune and Lens Sequences, ResearchGate preprint, 2024. See pp. 45, 56.
- Peter M. Chema, Illustration of first 22 terms as corners of a double square spiral with digital root.
- David Coles, Triangle Puzzle.
- M. L. Cornelius, Variations on a geometric progression, Mathematics in School, 4 (No. 3, May 1975), p. 32. (Annotated scanned copy)
- Tom Crawford, 22 Slices of Pizza with Six Cuts, Tom Rocks Maths video (2022)
- Robert Dawson, On Some Sequences Related to Sums of Powers, J. Int. Seq., Vol. 21 (2018), Article 18.7.6.
- Karl Dilcher and Kenneth B. Stolarsky, Nonlinear recurrences related to Chebyshev polynomials, The Ramanujan Journal, 2014, Online Oct. 2014, pp. 1-23. See Cor. 5.
- Igor Dolinka, James East, and Robert D. Gray, Motzkin monoids and partial Brauer monoids, Journal of Algebra, volume 471, February 2017, pages 251-298. Also preprint arXiv:1512.02279 [math.GR], 2015. See Table 5.
- Matthew England, Russell Bradford, and James H. Davenport, Cylindrical algebraic decomposition with equational constraints, Journal of Symbolic Computation, Vol. 100 (2020), pp. 38-71; arXiv preprint, arXiv:1903.08999 [cs.SC], 2019.
- J. B. Gil and J. Tomasko, Restricted Grassmannian permutations, ECA 2:4 (2022) Article S4PP6.
- Sahir Gill, Bounds for Region Containing All Zeros of a Complex Polynomial, International Journal of Mathematical Analysis (2018), Vol. 12, No. 7, 325-333.
- Richard K. Guy, Letter to N. J. A. Sloane.
- Guo-Niu Han, Enumeration of Standard Puzzles. [Cached copy]
- M. F. Hasler, Interactive illustration of A000124. [Sep 06 2017: The user can choose the slices to make, but the program can suggest a set of n slices which should yield the maximum number of pieces. For n slices this obviously requires 2n endpoints, or 2n+1 if they are equally spaced, so if there are not enough "blobs", their number is accordingly increased. This is the distinction between "draw" (done when you change the slices or number of blobs by hand) and "suggest" (propose a new set of slices).]
- Phillip Tomas Heikoop, Dimensions of Matrix Subalgebras, Bachelor's Thesis, Worcester Polytechnic Institute, Massachusetts, 2019.
- Cheyne Homberger, Patterns in Permutations and Involutions: A Structural and Enumerative Approach, arXiv preprint 1410.2657 [math.CO], 2014.
- Cheyne Homberger and Vincent Vatter, On the effective and automatic enumeration of polynomial permutation classes, Journal of Symbolic Computation, Vol. 76 (2016), pp. 84-96; arXiv preprint, arXiv:1308.4946 [math.CO], 2013-2015.
- Lancelot Hogben, Choice and Chance by Cardpack and Chessboard, Vol. 1, Max Parrish and Co, London, 1950, p. 22.
- INRIA Algorithms Project, Encyclopedia of Combinatorial Structures 386
- Milan Janjic, Two Enumerative Functions.
- Milan Janjic, Hessenberg Matrices and Integer Sequences, J. Int. Seq. 13 (2010) # 10.7.8.
- Myrto Kallipoliti, Robin Sulzgruber, and Eleni Tzanaki, Patterns in Shi tableaux and Dyck paths, arXiv:2006.06949 [math.CO], 2020.
- Clark Kimberling, Complementary Equations, Journal of Integer Sequences, Vol. 10 (2007), Article 07.1.4.
- Clark Kimberling and John E. Brown, Partial Complements and Transposable Dispersions, J. Integer Seqs., Vol. 7, 2004.
- Thomas Langley, Jeffrey Liese, and Jeffrey Remmel, Generating Functions for Wilf Equivalence Under Generalized Factor Order, J. Int. Seq. 14 (2011) # 11.4.2.
- Kyu-Hwan Lee and Se-jin Oh, Catalan triangle numbers and binomial coefficients, arXiv:1601.06685 [math.CO], 2016-2017.
- Derek Levin, Lara Pudwell, Manda Riehl and Andrew Sandberg, Pattern Avoidance on k-ary Heaps, Slides of Talk, 2014.
- D. A. Lind, On a class of nonlinear binomial sums, Fib. Quart., 3 (1965), 292-298.
- Jim Loy, Triangle Puzzle.
- Toufik Mansour, Permutations avoiding a set of patterns from S_3 and a pattern from S_4, arXiv:math/9909019 [math.CO], 1999.
- Megan A. Martinez and Carla D. Savage, Patterns in Inversion Sequences II: Inversion Sequences Avoiding Triples of Relations, arXiv:1609.08106 [math.CO], 2016-2018.
- Johannes W. Meijer and Manuel Nepveu, Euler's ship on the Pentagonal Sea, Acta Nova, Volume 4, No.1, December 2008. pp. 176-187.
- Markus Moll, On a family of random noble means substitutions, Dr. Math. Dissertation, Universität Bielefeld, 2013, arXiv:1312.5136 [math.DS], 2013.
- Permutation Pattern Avoidance Library (PermPAL), Av(123,231)
- Simon Plouffe, Approximations de séries génératrices et quelques conjectures, Dissertation, Université du Québec à Montréal, 1992; arXiv:0911.4975 [math.NT], 2009.
- Simon Plouffe, 1031 Generating Functions, Appendix to Thesis, Montreal, 1992
- Derek J. Price, Some unusual series occurring in n-dimensional geometry, Math. Gaz., Vol. 30, No. 290 (1946), pp. 149-150.
- Lara Pudwell and Andrew Baxter, Ascent sequences avoiding pairs of patterns, 2014.
- Franck Ramaharo, Enumerating the states of the twist knot, arXiv:1712.06543 [math.CO], 2017.
- Franck Ramaharo and Fanja Rakotondrajao, A state enumeration of the foil knot, arXiv:1712.04026 [math.CO], 2017.
- Franck Ramaharo, A generating polynomial for the two-bridge knot with Conway's notation C(n,r), arXiv:1902.08989 [math.CO], 2019.
- Nathan Reading, On the structure of Bruhat Order, Ph.D. dissertation, University of Minnesota, April 2002.
- Nathan Reading, Order Dimension, Strong Bruhat Order and Lattice Properties for Posets.
- Nathan Reading, Order Dimension, Strong Bruhat Order and Lattice Properties for Posets, Order, Vol. 19, no. 1 (2002), 73-100.
- Herman P. Robinson, Letter to N. J. A. Sloane, Aug 16 1971, with attachments.
- Rodica Simion and Frank W. Schmidt, Restricted permutations, European J. Combin., 6, 383-406, 1985; see Example 3.5.
- N. J. A. Sloane, Four hatpins can divide the plane into a(3) = 7 regions.
- N. J. A. Sloane, On single-deletion-correcting codes, 2002.
- N. J. A. Sloane, "A Handbook of Integer Sequences" Fifty Years Later, arXiv:2301.03149 [math.NT], 2023, p. 1.
- Andrew James Turner and Julian Francis Miller, Recurrent Cartesian Genetic Programming Applied to Famous Mathematical Sequences, 2014.
- Eric Weisstein's World of Mathematics, Circle Division by Lines.
- Eric Weisstein's World of Mathematics, Plane Division by Lines.
- Thomas Wieder, The number of certain k-combinations of an n-set, Applied Mathematics Electronic Notes, Vol. 8 (2008), pp. 45-52.
- Wikipedia, Floyd's triangle.
- Index entries for "core" sequences.
- Index entries for sequences related to centered polygonal numbers.
- Index entries for linear recurrences with constant coefficients, signature (3,-3,1).
Crossrefs
Cf. A000096 (Maximal number of pieces that can be obtained by cutting an annulus with n cuts, for n >= 1).
Cf. A002061, A002522, A016028, A055503, A072863, A144328, A177862, A263883, A000127, A005408, A006261, A016813, A058331, A080856, A086514, A161701, A161702, A161703, A161704, A161706, A161707, A161708, A161710, A161711, A161712, A161713, A161715, A051601, A228918.
A row of the array in A386478.
Programs
-
GAP
List([0..60],n->n*(n+1)/2+1); # Muniru A Asiru, Apr 11 2018
-
Haskell
a000124 = (+ 1) . a000217 -- Reinhard Zumkeller, Oct 04 2012, Nov 15 2011
-
Magma
[n: n in [0..1500] | IsSquare(8*n-7)]; // Vincenzo Librandi, Apr 16 2014
-
Maple
A000124 := n-> n*(n+1)/2+1;
-
Mathematica
FoldList[#1 + #2 &, 1, Range@ 50] (* Robert G. Wilson v, Feb 02 2011 *) Accumulate[Range[0, 60]] + 1 (* Harvey P. Dale, Mar 12 2013 *) Select[Range[2000], IntegerQ[Sqrt[8 # - 7]] &] (* Vincenzo Librandi, Apr 16 2014 *) Table[PolygonalNumber[n] + 1, {n, 0, 52}] (* Michael De Vlieger, Jun 30 2016, Version 10.4 *) LinearRecurrence[{3, -3, 1}, {1, 2, 4}, 53] (* Jean-François Alcover, Sep 23 2017 *)
-
PARI
{a(n) = (n^2 + n) / 2 + 1}; /* Michael Somos, Sep 04 2006 */
-
Python
def a(n): return n*(n+1)//2 + 1 print([a(n) for n in range(53)]) # Michael S. Branicky, Aug 26 2021
-
Scala
(1 to 52).scanLeft(1)( + ) // Alonso del Arte, Feb 24 2019
Formula
G.f.: (1 - x + x^2)/(1 - x)^3. - Simon Plouffe in his 1992 dissertation
a(n) = A108561(n+3, 2). - Reinhard Zumkeller, Jun 10 2005
G.f.: (1 - x^6)/((1 - x)^2*(1 - x^2)*(1 - x^3)). a(n) = a(-1 - n) for all n in Z. - Michael Somos, Sep 04 2006
Euler transform of length 6 sequence [ 2, 1, 1, 0, 0, -1]. - Michael Somos, Sep 04 2006
a(n+3) = 3*a(n+2) - 3*a(n+1) + a(n) and a(1) = 1, a(2) = 2, a(3) = 4. - Artur Jasinski, Oct 21 2008
a(n) = A000217(n) + 1.
a(n) = a(n-1) + n. E.g.f.:(1 + x + x^2/2)*exp(x). - Geoffrey Critzer, Mar 10 2009
a(n) = Sum_{k = 0..n + 1} binomial(n+1, 2(k - n)). - Paul Barry, Aug 29 2004
a(n) = binomial(n+2, 1) - 2*binomial(n+1, 1) + binomial(n+2, 2). - Zerinvary Lajos, May 12 2006
From Thomas Wieder, Feb 25 2009: (Start)
a(n) = Sum_{l_1 = 0..n + 1} Sum_{l_2 = 0..n}...Sum_{l_i = 0..n - i}...Sum_{l_n = 0..1} delta(l_1, l_2, ..., l_i, ..., l_n) where delta(l_1, l_2, ..., l_i, ..., l_n) = 0 if any l_i != l_(i+1) and l_(i+1) != 0 and delta(l_1, l_2, ..., l_i, ..., l_n) = 1 otherwise. (End)
a(n) = A034856(n+1) - A005843(n) = A000217(n) + A005408(n) - A005843(n). - Jaroslav Krizek, Sep 05 2009
a(n) = 2*a(n-1) - a(n-2) + 1. - Eric Werley, Jun 27 2011
E.g.f.: exp(x)*(1+x+(x^2)/2) = Q(0); Q(k) = 1+x/(1-x/(2+x-4/(2+x*(k+1)/Q(k+1)))); (continued fraction). - Sergei N. Gladkovskii, Nov 21 2011
a(n) = A014132(n, 1) for n > 0. - Reinhard Zumkeller, Dec 12 2012
a(n) = 1 + floor(n/2) + ceiling(n^2/2) = 1 + A004526(n) + A000982(n). - Wesley Ivan Hurt, Jun 14 2013
a(n) = A228074(n+1, n). - Reinhard Zumkeller, Aug 15 2013
For n > 0: A228446(a(n)) = 3. - Reinhard Zumkeller, Mar 12 2014
From Ilya Gutkovskiy, Jun 29 2016: (Start)
Dirichlet g.f.: (zeta(s-2) + zeta(s-1) + 2*zeta(s))/2.
Sum_{n >= 0} 1/a(n) = 2*Pi*tanh(sqrt(7)*Pi/2)/sqrt(7) = A226985. (End)
a(n) = (n+1)^2 - A000096(n). - Anton Zakharov, Jun 29 2016
a(n) = A101321(1, n). - R. J. Mathar, Jul 28 2016
a(n) = 2*a(n-1) - binomial(n-1, 2) and a(0) = 1. - Armend Shabani, Mar 10 2017
From Klaus Purath, Jan 29 2020: (Start)
a(n) = (Sum_{i=n-2..n+2} A000217(i))/5.
a(n) = (Sum_{i=n-2..n+2} A002378(i))/10.
a(n) = (Sum_{i=n..n+2} A002061(i)+1)/6.
a(n) = (Sum_{i=n-1..n+2} A000290(i)+2)/8.
a(n) = A060533(n-1) + 10, n > 5.
a(n) = (A002378(n) + 2)/2.
a(n) = A152948(n+2) - 1.
a(n) = A152950(n+1) - 2.
(End)
Sum_{n>=0} (-1)^n/a(n) = A228918. - Amiram Eldar, Nov 20 2020
From Amiram Eldar, Feb 17 2021: (Start)
Product_{n>=0} (1 + 1/a(n)) = cosh(sqrt(15)*Pi/2)*sech(sqrt(7)*Pi/2).
Product_{n>=1} (1 - 1/a(n)) = 2*Pi*sech(sqrt(7)*Pi/2). (End)
a((n^2-3n+6)/2) + a((n^2-n+4)/2) = a(n^2-2n+6)/2. - Charlie Marion, Feb 14 2023
A191017 Primes with Kronecker symbol (p|14) = 1.
3, 5, 13, 19, 23, 59, 61, 71, 79, 83, 101, 113, 127, 131, 137, 139, 151, 157, 173, 181, 191, 193, 227, 229, 233, 239, 251, 263, 269, 281, 283, 293, 307, 337, 349, 359, 397, 401, 419, 431, 449, 457, 461, 463, 467, 487, 509, 523, 563, 569, 587, 599, 617, 619
Offset: 1
Comments
Originally incorrectly named "Primes that are squares mod 14", which is sequence A045373. - M. F. Hasler, Jan 15 2016
Conjecture: primes congruent to {1, 3, 5, 9, 13, 15, 19, 23, 25, 27, 39, 45} mod 56. - Vincenzo Librandi, Jun 22 2016
From Jianing Song, Nov 21 2019: (Start)
Rational primes that decompose in the field Q(sqrt(-14)).
These are primes p such that either one of (a) p == 1, 2, 4 (mod 7), p == 1, 7 (mod 8) or (b) p == 3, 5, 6 (mod 7), p == 3, 5 (mod 8) holds. So the conjecture above is correct. (End)
Links
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
Programs
-
Magma
[p: p in PrimesUpTo(619) | KroneckerSymbol(p, 14) eq 1]; // Vincenzo Librandi, Sep 11 2012
-
Mathematica
Select[Prime[Range[200]], JacobiSymbol[#,14]==1&]
-
PARI
is(p)=kronecker(p, 14)==1&&isprime(p) \\ Michel Marcus, Jun 23 2016 after A191032
Extensions
Definition corrected (following an observation by David Broadhurst) by M. F. Hasler, Jan 15 2016
A090348 Norms of prime elements in the ring of integers of Q(sqrt(-7)).
2, 7, 9, 11, 23, 25, 29, 37, 43, 53, 67, 71, 79, 107, 109, 113, 127, 137, 149, 151, 163, 169, 179, 191, 193, 197, 211, 233, 239, 263, 277, 281, 289, 317, 331, 337, 347, 359, 361, 373, 379, 389, 401, 421, 431, 443, 449, 457, 463, 487, 491, 499
Offset: 0
Comments
References
- A. Frohlich and M. J. Taylor, Algebraic number theory, Cambridge studies in advanced mathematics, no. 27, Cambridge University Press, 1991.
A033207 Primes of the form x^2 + 7*y^2.
7, 11, 23, 29, 37, 43, 53, 67, 71, 79, 107, 109, 113, 127, 137, 149, 151, 163, 179, 191, 193, 197, 211, 233, 239, 263, 277, 281, 317, 331, 337, 347, 359, 373, 379, 389, 401, 421, 431, 443, 449, 457, 463, 487, 491
Offset: 1
Comments
Except for a(1) = 7, these are the primes which can be written in the form a^2 + 7*b^2 with a > 0 and b > 0. - V. Raman, Sep 08 2012
These are the primes p for which p^3 - 1 is divisible by 7, with two exceptions: p = 2 is not in the sequence even though 2^3 - 1 is divisible by 7, and p = 7 is in the sequence even though 7^3 - 1 is not divisible by 7. Except for p = 7, if p^3 - 1 is not divisible by 7, it is congruent to 5 (mod 7). - Richard R. Forberg, Jun 03 2013
References
- David A. Cox, "Primes of the Form x^2 + n y^2", Wiley, 1989.
Links
- Ray Chandler, Table of n, a(n) for n = 1..10000 (first 1000 terms from T. D. Noe)
- Sushma Palimar and B. R. Shankar, Mersenne Primes in Real Quadratic Fields, Journal of Integer Sequences, Vol. 15 (2012), #12.5.6.
- N. J. A. Sloane et al., Binary Quadratic Forms and OEIS (Index to related sequences, programs, references)
Programs
-
Mathematica
QuadPrimes2[1, 0, 7, 10000] (* see A106856 *)
-
PARI
is(n)=kronecker(n,7)>=0 && isprime(n) && n>2 \\ Charles R Greathouse IV, Nov 19 2012
Formula
Primes congruent to {1, 7, 9, 11, 15, 23, 25} (mod 28). - T. D. Noe, Apr 29 2008
A373751 Array read by ascending antidiagonals: p is a term of row A(n) if and only if p is a prime and p is a quadratic residue modulo prime(n).
2, 3, 3, 5, 7, 5, 2, 11, 13, 7, 3, 7, 19, 19, 11, 3, 5, 11, 29, 31, 13, 2, 13, 11, 23, 31, 37, 17, 5, 13, 17, 23, 29, 41, 43, 19, 2, 7, 17, 23, 31, 37, 59, 61, 23, 5, 3, 11, 19, 29, 37, 43, 61, 67, 29, 2, 7, 13, 17, 43, 43, 47, 53, 71, 73, 31, 3, 5, 13, 23, 19, 47, 53, 53, 67, 79, 79, 37
Offset: 1
Comments
p is a term of A(n) <=> p is prime and there exists an integer q such that q^2 is congruent to p modulo prime(n).
Examples
Note that the cross-references are hints, not assertions about identity. . [ n] [ p] [ 1] [ 2] [ 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, ... A000040 [ 2] [ 3] [ 3, 7, 13, 19, 31, 37, 43, 61, 67, 73, ... A007645 [ 3] [ 5] [ 5, 11, 19, 29, 31, 41, 59, 61, 71, 79, ... A038872 [ 4] [ 7] [ 2, 7, 11, 23, 29, 37, 43, 53, 67, 71, ... A045373 [ 5] [11] [ 3, 5, 11, 23, 31, 37, 47, 53, 59, 67, ... A056874 [ 6] [13] [ 3, 13, 17, 23, 29, 43, 53, 61, 79, 101, .. A038883 [ 7] [17] [ 2, 13, 17, 19, 43, 47, 53, 59, 67, 83, ... A038889 [ 8] [19] [ 5, 7, 11, 17, 19, 23, 43, 47, 61, 73, ... A106863 [ 9] [23] [ 2, 3, 13, 23, 29, 31, 41, 47, 59, 71, ... A296932 [10] [29] [ 5, 7, 13, 23, 29, 53, 59, 67, 71, 83, ... A038901 [11] [31] [ 2, 5, 7, 19, 31, 41, 47, 59, 67, 71, ... A267481 [12] [37] [ 3, 7, 11, 37, 41, 47, 53, 67, 71, 73, ... A038913 [13] [41] [ 2, 5, 23, 31, 37, 41, 43, 59, 61, 73, ... A038919 [14] [43] [11, 13, 17, 23, 31, 41, 43, 47, 53, 59, ... A106891 [15] [47] [ 2, 3, 7, 17, 37, 47, 53, 59, 61, 71, ... A267601 [16] [53] [ 7, 11, 13, 17, 29, 37, 43, 47, 53, 59, ... A038901 [17] [59] [ 3, 5, 7, 17, 19, 29, 41, 53, 59, 71, ... A374156 [18] [61] [ 3, 5, 13, 19, 41, 47, 61, 73, 83, 97, ... A038941 [19] [67] [17, 19, 23, 29, 37, 47, 59, 67, 71, 73, ... A106933 [20] [71] [ 2, 3, 5, 19, 29, 37, 43, 71, 73, 79, ... [21] [73] [ 2, 3, 19, 23, 37, 41, 61, 67, 71, 73, ... A038957 [22] [79] [ 2, 5, 11, 13, 19, 23, 31, 67, 73, 79, ... [23] [83] [ 3, 7, 11, 17, 23, 29, 31, 37, 41, 59, ... [24] [89] [ 2, 5, 11, 17, 47, 53, 67, 71, 73, 79, ... A038977 [25] [97] [ 2, 3, 11, 31, 43, 47, 53, 61, 73, 79, ... A038987 . Prime(n) is a term of row n because for all n >= 1, n is a quadratic residue mod n.
Links
- Robert G. Wilson v, Table of n, a(n) for n = 1..10011 (the first 141 antidiagonals, flattened).
Crossrefs
Programs
-
Maple
A := proc(n, len) local c, L, a; a := 2; c := 0; L := NULL; while c < len do if NumberTheory:-QuadraticResidue(a, n) = 1 and isprime(a) then L := L,a; c := c + 1 fi; a := a + 1 od; [L] end: seq(print(A(ithprime(n), 10)), n = 1..25);
-
Mathematica
f[m_, n_] := Block[{p = Prime@ m}, Union[ Join[{p}, Select[ Prime@ Range@ 22, JacobiSymbol[#, If[m > 1, p, 1]] == 1 &]]]][[n]]; Table[f[n, m -n +1], {m, 12}, {n, m, 1, -1}] (* To read the array by descending antidiagonals, just exchange the first argument with the second in the function "f" called by the "Table"; i.e., Table[ f[m -n +1, n], {m, 12}, {n, m, 1, -1}] *)
-
PARI
A373751_row(n, LIM=99)={ my(q=prime(n)); [p | p <- primes([1,LIM]), issquare( Mod(p, q))] } \\ M. F. Hasler, Jun 29 2024
-
SageMath
# The function 'is_quadratic_residue' is defined in A373748. def A373751_row(n, len): return [a for a in range(len) if is_quadratic_residue(a, n) and is_prime(a)] for p in prime_range(99): print([p], A373751_row(p, 100))
A045386 Primes congruent to {1, 2, 4} mod 7.
2, 11, 23, 29, 37, 43, 53, 67, 71, 79, 107, 109, 113, 127, 137, 149, 151, 163, 179, 191, 193, 197, 211, 233, 239, 263, 277, 281, 317, 331, 337, 347, 359, 373, 379, 389, 401, 421, 431, 443, 449, 457, 463, 487, 491, 499, 541, 547, 557, 569, 571, 599, 613, 617, 631, 641, 653, 659, 673
Offset: 1
Comments
Rational primes that decompose in the field Q(sqrt(-7)). - N. J. A. Sloane, Dec 25 2017
All these primes can be represented by the binary quadratic form x^2 + xy + 2y^2. - Alonso del Arte, Jun 13 2014. Indeed, apart from the fact that 7 is missing, this appears to coincide with A045373. - N. J. A. Sloane, Jun 14 2014
References
- Şaban Alaca & Kenneth S. Williams, Introductory Algebraic Number Theory. Cambridge: Cambridge University Press (2004) p. 48, Theorem 2.5.4.
Links
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
- N. J. A. Sloane et al., Binary Quadratic Forms and OEIS (Index to related sequences, programs, references)
- Index to sequences related to decomposition of primes in quadratic fields
Programs
-
Magma
[p: p in PrimesUpTo(600) | p mod 7 in [1, 2, 4]]; // Vincenzo Librandi, Aug 11 2012
-
Mathematica
Select[Prime[Range[300]], MemberQ[{1, 2, 4}, Mod[#, 7]] &] (* Vincenzo Librandi, Aug 11 2012 *)
A118680 Numerator of determinant of n X n matrix with M(i,j) = (i+1)/i if i=j otherwise 1.
2, 2, 7, 11, 2, 11, 29, 37, 23, 1, 67, 79, 23, 53, 11, 137, 1, 43, 191, 211, 29, 127, 277, 43, 163, 1, 379, 37, 109, 233, 71, 23, 281, 149, 631, 1, 1, 53, 71, 821, 431, 113, 947, 991, 1, 541, 1129, 107, 613, 1
Offset: 1
Comments
Some a(n) are equal to 1 (n=10,17,26,36,37,45..). It appears that all other a(n) are primes congruent to {0, 1, 2, 4} mod 7 - A045373.
Links
- Vincenzo Librandi, Table of n, a(n) for n = 1..10000
Crossrefs
Cf. A045373.
Programs
-
Mathematica
Numerator[Table[ Det[ DiagonalMatrix[ Table[ 1/i, {i, 1, n} ] ] + 1 ], {n, 1, 80} ]] Table[Numerator[(1+n(n+1)/2)/n! ],{n,1,100}]
Formula
a(n) = Numerator[Det[ DiagonalMatrix[ Table[ 1/i, {i, 1, n} ] ] + 1 ]].
a(n) = Numerator[ (1 + Sum[ k, {k,1,n} ]) /Product[ k, {k,1,n} ] ]. a(n) = Numerator[ (1 + n(n+1)/2) / n! ].
A267455 Primes which are a square (mod 39).
3, 13, 43, 61, 79, 103, 127, 139, 157, 181, 199, 211, 277, 283, 313, 337, 367, 373, 433, 439, 523, 547, 571, 601, 607, 673, 727, 751, 757, 823, 829, 859, 883, 907, 919, 937, 991, 997, 1039, 1063, 1069, 1093, 1117, 1153, 1171, 1213, 1231, 1249, 1291, 1297, 1303, 1327, 1381, 1429, 1447, 1453, 1459, 1483
Offset: 1
Comments
Motivated by the former (incorrect) definition of A191029.
Also, primes p which have Legendre symbols (p|3) = (p|13) = 1, together with 3 and 13.
Apparently this contains the 3 plus the elements of A139494. - R. J. Mathar, May 28 2025
Links
- Paolo Xausa, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
Join[{3, 13}, Select[Prime[Range[500]], JacobiSymbol[#, {3, 13}] == {1, 1} &]] (* Paolo Xausa, May 29 2025 *)
-
PARI
select(p->issquare(Mod(p,39))&&isprime(p),[1..1000])
A047351 Numbers that are congruent to {0, 1, 2, 4} mod 7.
0, 1, 2, 4, 7, 8, 9, 11, 14, 15, 16, 18, 21, 22, 23, 25, 28, 29, 30, 32, 35, 36, 37, 39, 42, 43, 44, 46, 49, 50, 51, 53, 56, 57, 58, 60, 63, 64, 65, 67, 70, 71, 72, 74, 77, 78, 79, 81, 84, 85, 86, 88, 91, 92, 93, 95, 98, 99, 100, 102, 105, 106, 107, 109, 112
Offset: 1
Comments
The set of values for m such that 7i+m is a perfect square (the quadratic residues of 7 including the trivial case of k*7). - Gary Detlefs, Mar 07 2010
The product of any two terms belongs to the sequence and therefore also a(n)^2, a(n)^3, a(n)^4 etc. - Bruno Berselli, Dec 03 2012
Links
- Daniel Starodubtsev, Table of n, a(n) for n = 1..10000
- Index entries for linear recurrences with constant coefficients, signature (1,0,0,1,-1).
Programs
-
Magma
[n : n in [0..150] | n mod 7 in [0, 1, 2, 4]]; // Wesley Ivan Hurt, Jun 01 2016
-
Maple
for i from 1 to 56 do if(i mod 4=0) then print(floor(7*i-3)/4)+1) else print(floor(7*i-3)/4)) fi od; # Gary Detlefs, Mar 07 2010 A047351:=n->n-3+(6*n+(2-I^(2*n))*(1-2*I^(n*(n+1)))+1)/8: seq(A047351(n), n=1..100); # Wesley Ivan Hurt, Jun 01 2016
-
Mathematica
Select[Range[0,100], MemberQ[{0,1,2,4}, Mod[#,7]]&] (* or *) LinearRecurrence[{1,0,0,1,-1}, {0,1,2,4,7}, 60] (* Harvey P. Dale, Jun 04 2013 *)
-
PARI
x='x+O('x^100); concat(0, Vec(x^2*(1+x+2*x^2+3*x^3)/((1+x)*(1+x^2)*(x-1)^2))) \\ Altug Alkan, Jun 02 2016
Formula
If n mod 4 = 0 then a(n) = floor((7*n-3)/4)+1, else a(n) = floor((7*n-3)/4). - Gary Detlefs, Mar 07 2010
G.f.: x^2*(1+x+2*x^2+3*x^3) / ( (1+x)*(1+x^2)*(x-1)^2 ). - R. J. Mathar, Dec 04 2011
a(n) = n-3+(6*n+(2-(-1)^n)(1-2*i^(n(n+1)))+1)/8, where i=sqrt(-1). - Bruno Berselli, Dec 03 2012
a(0)=0, a(1)=1, a(2)=2, a(3)=4, a(4)=7, a(n) = a(n-1) + a(n-4) - a(n-5) for n>5. - Harvey P. Dale, Jun 04 2013
E.g.f.: (12 + 3*sin(x) - cos(x) + (7*x - 10)*sinh(x) + (7*x - 11)*cosh(x))/4. - Ilya Gutkovskiy, Jun 02 2016
Comments
References
Links
Crossrefs
Programs
Mathematica
PARI
Extensions