Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Search: a011557 -id:a011557
     Sort: relevance | references | number | modified | created      Format: long | short | data
First differences of 10^n (A011557).
+20
68
9, 90, 900, 9000, 90000, 900000, 9000000, 90000000, 900000000, 9000000000, 90000000000, 900000000000, 9000000000000, 90000000000000, 900000000000000, 9000000000000000, 90000000000000000, 900000000000000000, 9000000000000000000, 90000000000000000000
OFFSET
1,1
COMMENTS
For n >=1, a(n) is equal to the number of functions f:{1,2...,n}->{1,2,...,10} such that for a fixed x in {1,2,...,n} and a fixed y in {1,2,...,10} we have f(x)<>y. - Aleksandar M. Janjic and Milan Janjic, Mar 27 2007
For n >= 1, a(n) is the number of n-digit positive integers. - Geoffrey Critzer, Apr 23 2009
REFERENCES
A. H. Beiler, Recreations in the Theory of Numbers, Dover, N.Y., 1964, pp. 194-196.
Miklos Bona, Introduction to Enumerative Combinatorics, McGraw-Hill, 2007, p. 8.
FORMULA
a(n) = 9*10^(n-1), n >= 1.
From Stefano Spezia, Jun 03 2021: (Start)
O.g.f.: 9*x/(1 - 10*x).
E.g.f.: 9*(exp(10*x) - 1)/10.
a(n) = 10*a(n-1) for n > 1. (End)
MATHEMATICA
q = 10; Join[{a = 1}, Table[If[n == 0, a = q * a - 1, a = q * a], {n, 0, 25}]] (* Vladimir Joseph Stephan Orlovsky, Jul 11 2011 *)
Differences[10^Range[0, 19]] (* Alonso del Arte, Feb 23 2015 *)
PROG
(PARI) a(n)=9*10^(n-1) \\ Charles R Greathouse IV, Sep 24 2015
CROSSREFS
Cf. A011557.
KEYWORD
easy,nonn
AUTHOR
Barry E. Williams, Feb 03 2000
EXTENSIONS
Deleted erroneous term a(0)=1. - N. J. A. Sloane, Apr 02 2015
STATUS
approved
Number of partitions of n into powers of 10 (cf. A011557).
+20
11
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10
OFFSET
0,11
COMMENTS
A179052 and A008592 give record values and where they occur.
FORMULA
a(n) = A133880(n) for n < 90; a(n) = A132272(n) for n < 100.
a(10^n) = A145513(n).
a(10*n) = A179052(n).
A179052(n) = a(A008592(n));
a(n) = p(n,1) where p(n,k) = if k<=n then p(10*[(n-k)/10],k)+p(n,10*k) else 0^n.
G.f.: Product_{k>=0} 1/(1 - x^(10^k)). - Ilya Gutkovskiy, Jul 26 2017
EXAMPLE
a(19) = #{10 + 9x1, 19x1} = 2;
a(20) = #{10 + 10, 10 + 10x1, 20x1} = 3;
a(21) = #{10 + 10 + 1, 10 + 11x1, 21x1} = 3.
MATHEMATICA
terms = 10001;
CoefficientList[Product[1/(1 - x^(10^k)) + O[x]^terms,
{k, 0, Log[10, terms] // Ceiling}], x]
(* Jean-François Alcover, Dec 12 2021, after Ilya Gutkovskiy *)
PROG
(Haskell)
a179051 = p 1 where
p _ 0 = 1
p k m = if m < k then 0 else p k (m - k) + p (k * 10) m
-- Reinhard Zumkeller, Feb 05 2012
CROSSREFS
Number of partitions of n into powers of b: A018819 (b=2), A062051 (b=3).
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Jun 27 2010
STATUS
approved
a(n) = 1, 7, A011557*(period 6: repeat 10, 13, 31, 49, 70, 97).
+20
1
1, 7, 10, 13, 31, 49, 70, 97, 100, 130, 310, 490, 700, 970, 1000, 1300, 3100, 4900, 7000, 9700, 10000, 13000, 31000, 49000, 70000, 97000, 100000, 130000, 310000, 490000, 700000, 970000, 1000000, 1300000, 3100000, 4900000, 7000000, 9700000, 10000000
OFFSET
1,2
FORMULA
G.f.: x*(10*x^2+13*x^3+31*x^4+49*x^5+60*x^6+27*x^7+1+7*x)/(1-10*x^6).
a(n) = 10^floor((n-3)/6)*(45+8*cos((n-2)*Pi)+25*cos((n-2)*Pi/3)+19*cos(2*(n-2)*Pi/3)-4*sqrt(3)*(4*sin((n-2)*Pi/3)+sin(2*(n-2)*Pi/3))) for n>2. - Wesley Ivan Hurt, Jun 18 2016
MAPLE
A178508:=n->10^floor((n-3)/6)*(45+8*cos((n-2)*Pi)+25*cos((n-2)*Pi/3)+19*cos(2*(n-2)*Pi/3)-4*sqrt(3)*(4*sin((n-2)*Pi/3)+sin(2*(n-2)*Pi/3))): 1, 7, seq(A178508(n), n=3..50); # Wesley Ivan Hurt, Jun 18 2016
MATHEMATICA
Join[{1, 7}, Flatten[Table[10^n {10, 13, 31, 49, 70, 97}, {n, 0, 6}]]] (* or *) Join[{1, 7}, LinearRecurrence[{0, 0, 0, 0, 0, 10}, {10, 13, 31, 49, 70, 97}, 50]] (* Harvey P. Dale, Nov 19 2013 *)
PROG
(PARI) a=[1, 7, 10, 13, 31, 49, 70, 97]; for(i=1, 99, a=concat(a, 10*a[#a-5])); a \\ Charles R Greathouse IV, Jun 01 2011
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Paul Curtz, May 29 2010
EXTENSIONS
Dissassociated with sums-of-squares sequences by R. J. Mathar, Jun 07 2010
STATUS
approved
Smallest k such that A011557(n)//k//rev is prime, where rev is the string of digits of A011557(n) reversed (retaining any leading zeros) and // denotes concatenation.
+20
1
0, 3, 3, 3, 5, 8, 29, 5, 8, 15, 3, 21, 8, 3, 21, 3, 8, 18, 20, 92, 110, 51, 102, 6, 57, 23, 5, 114, 8, 32, 41, 6, 236, 6, 39, 60, 110, 62, 36, 17, 53, 21, 161, 41, 159, 57, 137, 42, 83, 114, 126, 80, 30, 36, 278, 107, 425, 111, 68, 68, 95, 29, 8, 53, 426, 48
OFFSET
0,2
COMMENTS
Is a(n) = 0 for any n > 0? If such an n exists, that n is a term of A000079 (cf. Greathouse, 2010).
All terms are congruent to 0 or 2 modulo 3, since if k is congruent to 1 modulo 3, 1000...0//k//00...01 is divisible by 3 and thus not prime.
a(n) <= A100026(n-1) with equality when a(n) is a palindrome. - Michel Marcus, Sep 11 2015
LINKS
C. R. Greathouse IV, Primes of form 10^k + 1?, Physics Forums (message from Apr 6, 2010).
EXAMPLE
a(1) = 3, because 10001, 10101, and 10201 are composite and 10301 is prime.
a(6) = 29, because 29 is the smallest k such that 1000000//k//0000001 is prime. The decimal expansion of that prime is 1000000290000001.
MATHEMATICA
Table[k = 0; d = IntegerDigits[10^n]; While[! PrimeQ@ FromDigits@ Join[d, IntegerDigits@ k, Reverse@ d], k++]; k, {n, 0, 65}] (* Michael De Vlieger, Aug 26 2015 *)
PROG
(PARI) a(n) = x=10^n; k=0; while(!ispseudoprime(eval(Str(x, k, concat(Vecrev(Str(x)))))), k++); k
(Perl) use ntheory ":all"; for my $n (0..50) { my($t, $c)=(0); $t++ while $c=1 . 0 x $n . $t . 0 x $n . 1, !is_prob_prime($c); say "$n $t"; } # Dana Jacobsen, Oct 02 2015
KEYWORD
nonn,base
AUTHOR
Felix Fröhlich, Aug 23 2015
STATUS
approved
Numbers covering A000027: a(n) = (1, 1, 2, 5) * A011557(n).
+20
0
1, 1, 2, 5, 10, 10, 20, 50, 100, 100, 200, 500, 1000, 1000, 2000, 5000, 10000, 10000, 20000, 50000, 100000, 100000, 200000, 500000, 1000000, 1000000, 2000000, 5000000, 10000000, 10000000, 20000000, 50000000
OFFSET
1,3
COMMENTS
3=1+2, 4=1+1+2, 6=1+5, 7=2+5, 8=1+2+5, 9=1+1+2+5, 11=1+10, 12=2+10, 13=1+2+10.
a(n) is used only once. Like weights.
FORMULA
a(1)=1, a(2)=1, a(3)=2, a(4)=5, a(n)=10*a(n-4). G.f.: x*(1+x+2*x^2+5*x^3)/(1-10*x^4). [Colin Barker, Jan 25 2012]
MATHEMATICA
LinearRecurrence[{0, 0, 0, 10}, {1, 1, 2, 5}, 40] (* Harvey P. Dale, Jan 21 2019 *)
PROG
(PARI) a(n)=10^(n\4)*[1/2, 1, 1, 2][n%4+1] \\ Charles R Greathouse IV, Dec 21 2011
KEYWORD
nonn,easy
AUTHOR
Paul Curtz, Aug 22 2011
STATUS
approved
The squares: a(n) = n^2.
(Formerly M3356 N1350)
+10
3263
0, 1, 4, 9, 16, 25, 36, 49, 64, 81, 100, 121, 144, 169, 196, 225, 256, 289, 324, 361, 400, 441, 484, 529, 576, 625, 676, 729, 784, 841, 900, 961, 1024, 1089, 1156, 1225, 1296, 1369, 1444, 1521, 1600, 1681, 1764, 1849, 1936, 2025, 2116, 2209, 2304, 2401, 2500
OFFSET
0,3
COMMENTS
To test if a number is a square, see Cohen, p. 40. - N. J. A. Sloane, Jun 19 2011
Zero followed by partial sums of A005408 (odd numbers). - Jeremy Gardiner, Aug 13 2002
Begin with n, add the next number, subtract the previous number and so on ending with subtracting a 1: a(n) = n + (n+1) - (n-1) + (n+2) - (n-2) + (n+3) - (n-3) + ... + (2n-1) - 1 = n^2. - Amarnath Murthy, Mar 24 2004
Sum of two consecutive triangular numbers A000217. - Lekraj Beedassy, May 14 2004
Numbers with an odd number of divisors: {d(n^2) = A048691(n); for the first occurrence of 2n + 1 divisors, see A071571(n)}. - Lekraj Beedassy, Jun 30 2004
See also A000037.
First sequence ever computed by electronic computer, on EDSAC, May 06 1949 (see Renwick link). - Russ Cox, Apr 20 2006
Numbers k such that the imaginary quadratic field Q(sqrt(-k)) has four units. - Marc LeBrun, Apr 12 2006
For n > 0: number of divisors of (n-1)th power of any squarefree semiprime: a(n) = A000005(A006881(k)^(n-1)); a(n) = A000005(A000400(n-1)) = A000005(A011557(n-1)) = A000005(A001023(n-1)) = A000005(A001024(n-1)). - Reinhard Zumkeller, Mar 04 2007
If a 2-set Y and an (n-2)-set Z are disjoint subsets of an n-set X then a(n-2) is the number of 3-subsets of X intersecting both Y and Z. - Milan Janjic, Sep 19 2007
Numbers a such that a^1/2 + b^1/2 = c^1/2 and a^2 + b = c. - Cino Hilliard, Feb 07 2008 (this comment needs clarification, Joerg Arndt, Sep 12 2013)
Numbers k such that the geometric mean of the divisors of k is an integer. - Ctibor O. Zizka, Jun 26 2008
Equals row sums of triangle A143470. Example: 36 = sum of row 6 terms: (23 + 7 + 3 + 1 + 1 + 1). - Gary W. Adamson, Aug 17 2008
Equals row sums of triangles A143595 and A056944. - Gary W. Adamson, Aug 26 2008
Number of divisors of 6^(n-1) for n > 0. - J. Lowell, Aug 30 2008
Denominators of Lyman spectrum of hydrogen atom. Numerators are A005563. A000290-A005563 = A000012. - Paul Curtz, Nov 06 2008
a(n) is the number of all partitions of the sum 2^2 + 2^2 + ... + 2^2, (n-1) times, into powers of 2. - Valentin Bakoev, Mar 03 2009
a(n) is the maximal number of squares that can be 'on' in an n X n board so that all the squares turn 'off' after applying the operation: in any 2 X 2 sub-board, a square turns from 'on' to 'off' if the other three are off. - Srikanth K S, Jun 25 2009
Zero together with the numbers k such that 2 is the number of perfect partitions of k. - Juri-Stepan Gerasimov, Sep 26 2009
Totally multiplicative sequence with a(p) = p^2 for prime p. - Jaroslav Krizek, Nov 01 2009
Satisfies A(x)/A(x^2), A(x) = A173277: (1, 4, 13, 32, 74, ...). - Gary W. Adamson, Feb 14 2010
Positive members are the integers with an odd number of odd divisors and an even number of even divisors. See also A120349, A120359, A181792, A181793, A181795. - Matthew Vandermast, Nov 14 2010
Besides the first term, this sequence is the denominator of Pi^2/6 = 1 + 1/4 + 1/9 + 1/16 + 1/25 + 1/36 + ... . - Mohammad K. Azarian, Nov 01 2011
Partial sums give A000330. - Omar E. Pol, Jan 12 2013
Drmota, Mauduit, and Rivat proved that the Thue-Morse sequence along the squares is normal; see A228039. - Jonathan Sondow, Sep 03 2013
a(n) can be decomposed into the sum of the four numbers [binomial(n, 1) + binomial(n, 2) + binomial(n-1, 1) + binomial(n-1, 2)] which form a "square" in Pascal's Triangle A007318, or the sum of the two numbers [binomial(n, 2) + binomial(n+1, 2)], or the difference of the two numbers [binomial(n+2, 3) - binomial(n, 3)]. - John Molokach, Sep 26 2013
In terms of triangular tiling, the number of equilateral triangles with side length 1 inside an equilateral triangle with side length n. - K. G. Stier, Oct 30 2013
Number of positive roots in the root systems of type B_n and C_n (when n > 1). - Tom Edgar, Nov 05 2013
Squares of squares (fourth powers) are also called biquadratic numbers: A000583. - M. F. Hasler, Dec 29 2013
For n > 0, a(n) is the largest integer k such that k^2 + n is a multiple of k + n. More generally, for m > 0 and n > 0, the largest integer k such that k^(2*m) + n is a multiple of k + n is given by k = n^(2*m). - Derek Orr, Sep 03 2014
For n > 0, a(n) is the number of compositions of n + 5 into n parts avoiding the part 2. - Milan Janjic, Jan 07 2016
a(n), for n >= 3, is also the number of all connected subtrees of a cycle graph, having n vertices. - Viktar Karatchenia, Mar 02 2016
On every sequence of natural continuous numbers with an even number of elements, the summatory of the second half of the sequence minus the summatory of the first half of the sequence is always a square. Example: Sequence from 61 to 70 has an even number of elements (10). Then 61 + 62 + 63 + 64 + 65 = 315; 66 + 67 + 68 + 69 + 70 = 340; 340 - 315 = 25. (n/2)^2 for n = number of elements. - César Aguilera, Jun 20 2016
On every sequence of natural continuous numbers from n^2 to (n+1)^2, the sum of the differences of pairs of elements of the two halves in every combination possible is always (n+1)^2. - César Aguilera, Jun 24 2016
Suppose two circles with radius 1 are tangent to each other as well as to a line not passing through the point of tangency. Create a third circle tangent to both circles as well as the line. If this process is continued, a(n) for n > 0 is the reciprocals of the radii of the circles, beginning with the largest circle. - Melvin Peralta, Aug 18 2016
Does not satisfy Benford's law [Ross, 2012]. - N. J. A. Sloane, Feb 08 2017
Numerators of the solution to the generalization of the Feynman triangle problem, with an offset of 2. If each vertex of a triangle is joined to the point (1/p) along the opposite side (measured say clockwise), then the area of the inner triangle formed by these lines is equal to (p - 2)^2/(p^2 - p + 1) times the area of the original triangle, p > 2. For example, when p = 3, the ratio of the areas is 1/7. The denominators of the ratio of the areas is given by A002061. [Cook & Wood, 2004] - Joe Marasco, Feb 20 2017
Equals row sums of triangle A004737, n >= 1. - Martin Michael Musatov, Nov 07 2017
Right-hand side of the binomial coefficient identity Sum_{k = 0..n} (-1)^(n+k+1)*binomial(n,k)*binomial(n + k,k)*(n - k) = n^2. - Peter Bala, Jan 12 2022
Conjecture: For n>0, min{k such that there exist subsets A,B of {0,1,2,...,a(n)-1} such that |A|=|B|=k and A+B contains {0,1,2,...,a(n)-1}} = n. - Michael Chu, Mar 09 2022
Number of 3-permutations of n elements avoiding the patterns 132, 213, 321. See Bonichon and Sun. - Michel Marcus, Aug 20 2022
Number of intercalates in cyclic Latin squares of order 2n (cyclic Latin squares of odd order do not have intercalates). - Eduard I. Vatutin, Feb 15 2024
REFERENCES
G. L. Alexanderson et al., The William Lowell Putnam Mathematical Competition, Problems and Solutions: 1965-1984, "December 1967 Problem B4(a)", pp. 8(157) MAA Washington DC 1985.
T. M. Apostol, Introduction to Analytic Number Theory, Springer-Verlag, 1976, page 2.
Albert H. Beiler, Recreations in the theory of numbers, New York, Dover, (2nd ed.) 1966. See Chapter XV, pp. 135-167.
R. P. Burn & A. Chetwynd, A Cascade Of Numbers, "The prison door problem" Problem 4 pp. 5-7; 79-80 Arnold London 1996.
H. Cohen, A Course in Computational Algebraic Number Theory, Springer, 1996, p. 40.
E. Deza and M. M. Deza, Figurate numbers, World Scientific Publishing (2012), p. 6.
M. Gardner, Time Travel and Other Mathematical Bewilderments, Chapter 6 pp. 71-2, W. H. Freeman NY 1988.
Granino A. Korn and Theresa M. Korn, Mathematical Handbook for Scientists and Engineers, McGraw-Hill Book Company, New York (1968), p. 982.
Jan Gullberg, Mathematics from the Birth of Numbers, W. W. Norton & Co., NY & London, 1997, §8.1 Terminology and §8.6 Figurate Numbers, pp. 264, 290-291.
Alfred S. Posamentier, The Art of Problem Solving, Section 2.4 "The Long Cell Block" pp. 10-1; 12; 156-7 Corwin Press Thousand Oaks CA 1996.
Michel Rigo, Formal Languages, Automata and Numeration Systems, 2 vols., Wiley, 2014. Mentions this sequence - see "List of Sequences" in Vol. 2.
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).
J. K. Strayer, Elementary Number Theory, Exercise Set 3.3 Problems 32, 33, p. 88, PWS Publishing Co. Boston MA 1996.
C. W. Trigg, Mathematical Quickies, "The Lucky Prisoners" Problem 141 pp. 40, 141, Dover NY 1985.
R. Vakil, A Mathematical Mosaic, "The Painted Lockers" pp. 127;134 Brendan Kelly Burlington Ontario 1996.
David Wells, The Penguin Dictionary of Curious and Interesting Numbers. Penguin Books, NY, 1986, Revised edition 1987. See p. 123.
LINKS
Valentin P. Bakoev, Algorithmic approach to counting of certain types m-ary partitions, Discrete Mathematics, 275 (2004) pp. 17-41.
Stefano Barbero, Umberto Cerruti, and Nadir Murru, Transforming Recurrent Sequences by Using the Binomial and Invert Operators, J. Int. Seq. 13 (2010) # 10.7.7, section 4.4.
Anicius Manlius Severinus Boethius, De institutione arithmetica libri duo, Book 2, sections 10-12.
Nicolas Bonichon and Pierre-Jean Morel, Baxter d-permutations and other pattern avoiding classes, arXiv:2202.12677 [math.CO], 2022.
R. J. Cook and G. V. Wood, Feynman's Triangle, Mathematical Gazette, 88:299-302 (2004).
John Derbyshire, Monkeys and Doors.
Michael Drmota, Christian Mauduit, and Joël Rivat, The Thue-Morse Sequence Along The Squares is Normal, Abstract, ÖMG-DMV Congress, 2013.
Ralph Greenberg, Math for Poets.
Guo-Niu Han, Enumeration of Standard Puzzles. [Cached copy]
Milan Janjić, On Restricted Ternary Words and Insets, arXiv:1905.04465 [math.CO], 2019.
L. B. W. Jolley, Summation of Series, Dover, 1961.
Sameen Ahmed Khan, Sums of the powers of reciprocals of polygonal numbers, Int'l J. of Appl. Math. (2020) Vol. 33, No. 2, 265-282.
Clark Kimberling, Complementary Equations, Journal of Integer Sequences, Vol. 10 (2007), Article 07.1.4.
Hyun Kwang Kim, On Regular Polytope Numbers, Proc. Amer. Math. Soc., 131 (2002), 65-75.
J. H. McKay, The William Lowell Putnam Mathematical Competition, Problem B4(a), The American Mathematical Monthly, vol. 75, no. 7, 1968, pp. 732-739.
Ed Pegg, Jr., Sequence Pictures, Math Games column, Dec 08 2003.
Ed Pegg, Jr., Sequence Pictures, Math Games column, Dec 08 2003 [Cached copy, with permission (pdf only)].
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; arXiv:0911.4975 [math.NT], 2009.
Yash Puri and Thomas Ward, Arithmetic and growth of periodic orbits, J. Integer Seqs., Vol. 4 (2001), #01.2.1.
Franck Ramaharo, A generating polynomial for the pretzel knot, arXiv:1805.10680 [math.CO], 2018.
William S. Renwick, The start of the EDSAC log.
Luis Manuel Rivera, Integer sequences and k-commuting permutations, arXiv preprint arXiv:1406.3081 [math.CO], 2014.
Kenneth A. Ross, First Digits of Squares and Cubes, Math. Mag. 85 (2012) 36-42.
James A. Sellers, Partitions Excluding Specific Polygonal Numbers As Parts, Journal of Integer Sequences, Vol. 7 (2004), Article 04.2.4.
Nathan Sun, On d-permutations and Pattern Avoidance Classes, arXiv:2208.08506 [math.CO], 2022.
Eric Weisstein's World of Mathematics, Square Number.
Eric Weisstein's World of Mathematics, Unit.
Eric Weisstein's World of Mathematics, Wiener Index.
FORMULA
G.f.: x*(1 + x) / (1 - x)^3.
E.g.f.: exp(x)*(x + x^2).
Dirichlet g.f.: zeta(s-2).
a(n) = a(-n).
Multiplicative with a(p^e) = p^(2*e). - David W. Wilson, Aug 01 2001
Sum of all matrix elements M(i, j) = 2*i/(i+j) (i, j = 1..n). a(n) = Sum_{i = 1..n} Sum_{j = 1..n} 2*i/(i + j). - Alexander Adamchuk, Oct 24 2004
a(0) = 0, a(1) = 1, a(n) = 2*a(n-1) - a(n-2) + 2. - Miklos Kristof, Mar 09 2005
From Pierre CAMI, Oct 22 2006: (Start)
a(n) is the sum of the odd numbers from 1 to 2*n - 1.
a(0) = 0, a(1) = 1, then a(n) = a(n-1) + 2*n - 1. (End)
For n > 0: a(n) = A130064(n)*A130065(n). - Reinhard Zumkeller, May 05 2007
a(n) = Sum_{k = 1..n} A002024(n, k). - Reinhard Zumkeller, Jun 24 2007
Left edge of the triangle in A132111: a(n) = A132111(n, 0). - Reinhard Zumkeller, Aug 10 2007
Binomial transform of [1, 3, 2, 0, 0, 0, ...]. - Gary W. Adamson, Nov 21 2007
a(n) = binomial(n+1, 2) + binomial(n, 2).
This sequence could be derived from the following general formula (cf. A001286, A000330): n*(n+1)*...*(n+k)*(n + (n+1) + ... + (n+k))/((k+2)!*(k+1)/2) at k = 0. Indeed, using the formula for the sum of the arithmetic progression (n + (n+1) + ... + (n+k)) = (2*n + k)*(k + 1)/2 the general formula could be rewritten as: n*(n+1)*...*(n+k)*(2*n+k)/(k+2)! so for k = 0 above general formula degenerates to n*(2*n + 0)/(0 + 2) = n^2. - Alexander R. Povolotsky, May 18 2008
From a(4) recurrence formula a(n+3) = 3*a(n+2) - 3*a(n+1) + a(n) and a(1) = 1, a(2) = 4, a(3) = 9. - Artur Jasinski, Oct 21 2008
The recurrence a(n+3) = 3*a(n+2) - 3*a(n+1) + a(n) is satisfied by all k-gonal sequences from a(3), with a(0) = 0, a(1) = 1, a(2) = k. - Jaume Oliver Lafont, Nov 18 2008
a(n) = floor(n*(n+1)*(Sum_{i = 1..n} 1/(n*(n+1)))). - Ctibor O. Zizka, Mar 07 2009
Product_{i >= 2} 1 - 2/a(i) = -sin(A063448)/A063448. - R. J. Mathar, Mar 12 2009
a(n) = A002378(n-1) + n. - Jaroslav Krizek, Jun 14 2009
a(n) = n*A005408(n-1) - (Sum_{i = 1..n-2} A005408(i)) - (n-1) = n*A005408(n-1) - a(n-1) - (n-1). - Bruno Berselli, May 04 2010
a(n) == 1 (mod n+1). - Bruno Berselli, Jun 03 2010
a(n) = a(n-1) + a(n-2) - a(n-3) + 4, n > 2. - Gary Detlefs, Sep 07 2010
a(n+1) = Integral_{x >= 0} exp(-x)/( (Pn(x)*exp(-x)*Ei(x) - Qn(x))^2 +(Pi*exp(-x)*Pn(x))^2 ), with Pn the Laguerre polynomial of order n and Qn the secondary Laguerre polynomial defined by Qn(x) = Integral_{t >= 0} (Pn(x) - Pn(t))*exp(-t)/(x-t). - Groux Roland, Dec 08 2010
Euler transform of length-2 sequence [4, -1]. - Michael Somos, Feb 12 2011
A162395(n) = -(-1)^n * a(n). - Michael Somos, Mar 19 2011
a(n) = A004201(A000217(n)); A007606(a(n)) = A000384(n); A007607(a(n)) = A001105(n). - Reinhard Zumkeller, Feb 12 2011
Sum_{n >= 1} 1/a(n)^k = (2*Pi)^k*B_k/(2*k!) = zeta(2*k) with Bernoulli numbers B_k = -1, 1/6, 1/30, 1/42, ... for k >= 0. See A019673, A195055/10 etc. [Jolley eq 319].
Sum_{n>=1} (-1)^(n+1)/a(n)^k = 2^(k-1)*Pi^k*(1-1/2^(k-1))*B_k/k! [Jolley eq 320] with B_k as above.
A007968(a(n)) = 0. - Reinhard Zumkeller, Jun 18 2011
A071974(a(n)) = n; A071975(a(n)) = 1. - Reinhard Zumkeller, Jul 10 2011
a(n) = A199332(2*n - 1, n). - Reinhard Zumkeller, Nov 23 2011
For n >= 1, a(n) = Sum_{d|n} phi(d)*psi(d), where phi is A000010 and psi is A001615. - Enrique Pérez Herrero, Feb 29 2012
a(n) = A000217(n^2) - A000217(n^2 - 1), for n > 0. - Ivan N. Ianakiev, May 30 2012
a(n) = (A000217(n) + A000326(n))/2. - Omar E. Pol, Jan 11 2013
a(n) = A162610(n, n) = A209297(n, n) for n > 0. - Reinhard Zumkeller, Jan 19 2013
a(A000217(n)) = Sum_{i = 1..n} Sum_{j = 1..n} i*j, for n > 0. - Ivan N. Ianakiev, Apr 20 2013
a(n) = A133280(A000217(n)). - Ivan N. Ianakiev, Aug 13 2013
a(2*a(n)+2*n+1) = a(2*a(n)+2*n) + a(2*n+1). - Vladimir Shevelev, Jan 24 2014
a(n+1) = Sum_{t1+2*t2+...+n*tn = n} (-1)^(n+t1+t2+...+tn)*multinomial(t1+t2 +...+tn,t1,t2,...,tn)*4^(t1)*7^(t2)*8^(t3+...+tn). - Mircea Merca, Feb 27 2014
a(n) = floor(1/(1-cos(1/n)))/2 = floor(1/(1-n*sin(1/n)))/6, n > 0. - Clark Kimberling, Oct 08 2014
a(n) = ceiling(Sum_{k >= 1} log(k)/k^(1+1/n)) = -Zeta'[1+1/n]. Thus any exponent greater than 1 applied to k yields convergence. The fractional portion declines from A073002 = 0.93754... at n = 1 and converges slowly to 0.9271841545163232... for large n. - Richard R. Forberg, Dec 24 2014
a(n) = Sum_{j = 1..n} Sum_{i = 1..n} ceiling((i + j - n + 1)/3). - Wesley Ivan Hurt, Mar 12 2015
a(n) = Product_{j = 1..n-1} 2 - 2*cos(2*j*Pi/n). - Michel Marcus, Jul 24 2015
From Ilya Gutkovskiy, Jun 21 2016: (Start)
Product_{n >= 1} (1 + 1/a(n)) = sinh(Pi)/Pi = A156648.
Sum_{n >= 0} 1/a(n!) = BesselI(0, 2) = A070910. (End)
a(n) = A028338(n, n-1), n >= 1 (second diagonal). - Wolfdieter Lang, Jul 21 2017
For n >= 1, a(n) = Sum_{d|n} sigma_2(d)*mu(n/d) = Sum_{d|n} A001157(d)*A008683(n/d). - Ridouane Oudra, Apr 15 2021
a(n) = Sum_{i = 1..2*n-1} ceiling(n - i/2). - Stefano Spezia, Apr 16 2021
From Richard L. Ollerton, May 09 2021: (Start) For n >= 1,
a(n) = Sum_{k=1..n} psi(n/gcd(n,k)).
a(n) = Sum_{k=1..n} psi(gcd(n,k))*phi(gcd(n,k))/phi(n/gcd(n,k)).
a(n) = Sum_{k=1..n} sigma_2(n/gcd(n,k))*mu(gcd(n,k))/phi(n/gcd(n,k)).
a(n) = Sum_{k=1..n} sigma_2(gcd(n,k))*mu(n/gcd(n,k))/phi(n/gcd(n,k)). (End)
a(n) = (A005449(n) + A000326(n))/3. - Klaus Purath, May 13 2021
Let T(n) = A000217(n), then a(T(n)) + a(T(n+1)) = T(a(n+1)). - Charlie Marion, Jun 27 2022
a(n) = Sum_{k=1..n} sigma_1(k) + Sum_{i=1..n} (n mod i). - Vadim Kataev, Dec 07 2022
a(n^2) + a(n^2+1) + ... + a(n^2+n) + 4*A000537(n) = a(n^2+n+1) + ... + a(n^2+2n). In general, if P(k,n) = the n-th k-gonal number, then P(2k,n^2) + P(2k,n^2+1) + ... + P(2k,n^2+n) + 4*(k-1)*A000537(n) = P(2k,n^2+n+1) + ... + P(2k,n^2+2n). - Charlie Marion, Apr 26 2024
Sum_{n>=1} 1/a(n) = A013661. - Alois P. Heinz, Oct 19 2024
a(n) = 1 + 3^3*((n-1)/(n+1))^2 + 5^3*((n-1)*(n-2)/((n+1)*(n+2)))^2 + 7^3*((n-1)*(n-2)*(n-3)/((n+1)*(n+2)*(n+3)))^2 + ... for n >= 1. - Peter Bala, Dec 09 2024
EXAMPLE
For n = 8, a(8) = 8 * 15 - (1 + 3 + 5 + 7 + 9 + 11 + 13) - 7 = 8 * 15 - 49 - 7 = 64. - Bruno Berselli, May 04 2010
G.f. = x + 4*x^2 + 9*x^3 + 16*x^4 + 25*x^5 + 36*x^6 + 49*x^7 + 64*x^8 + 81*x^9 + ...
a(4) = 16. For n = 4 vertices, the cycle graph C4 is A-B-C-D-A. The subtrees are: 4 singles: A, B, C, D; 4 pairs: A-B, BC, C-D, A-D; 4 triples: A-B-C, B-C-D, C-D-A, D-A-B; 4 quads: A-B-C-D, B-C-D-A, C-D-A-B, D-A-B-C; 4 + 4 + 4 + 4 = 16. - Viktar Karatchenia, Mar 02 2016
MAPLE
A000290 := n->n^2; seq(A000290(n), n=0..50);
A000290 := -(1+z)/(z-1)^3; # Simon Plouffe, in his 1992 dissertation, for sequence starting at a(1)
MATHEMATICA
Array[#^2 &, 51, 0] (* Robert G. Wilson v, Aug 01 2014 *)
LinearRecurrence[{3, -3, 1}, {0, 1, 4}, 60] (* Vincenzo Librandi, Jul 24 2015 *)
CoefficientList[Series[-(x^2 + x)/(x - 1)^3, {x, 0, 50}], x] (* Robert G. Wilson v, Jul 23 2018 *)
Range[0, 99]^2 (* Alonso del Arte, Nov 21 2019 *)
PROG
(Magma) [ n^2 : n in [0..1000]];
(PARI) {a(n) = n^2};
(PARI) b000290(maxn)=for(n=0, maxn, print(n, " ", n^2); ) \\ Anatoly E. Voevudko, Nov 11 2015
(Haskell)
a000290 = (^ 2)
a000290_list = scanl (+) 0 [1, 3..] -- Reinhard Zumkeller, Apr 06 2012
(Maxima) A000290(n):=n^2$ makelist(A000290(n), n, 0, 30); /* Martin Ettl, Oct 25 2012 */
(Scheme) (define (A000290 n) (* n n)) ;; Antti Karttunen, Oct 06 2017
(Scala) (0 to 59).map(n => n * n) // Alonso del Arte, Oct 07 2019
(Python) # See Hobson link
(Python)
def A000290(n): return n**2 # Chai Wah Wu, Nov 13 2022
CROSSREFS
Cf. A092205, A128200, A005408, A128201, A002522, A005563, A008865, A059100, A143051, A143470, A143595, A056944, A001157 (inverse Möbius transform), A001788 (binomial transform), A228039, A001105, A004159, A159918, A173277, A095794, A162395, A186646 (Pisano periods), A028338 (2nd diagonal).
A row or column of A132191.
This sequence is related to partitions of 2^n into powers of 2, as it is shown in A002577. So A002577 connects the squares and A000447. - Valentin Bakoev, Mar 03 2009
Boustrophedon transforms: A000697, A000745.
Cf. A342819.
Cf. A013661.
KEYWORD
nonn,core,easy,nice,mult
EXTENSIONS
Incorrect comment and example removed by Joerg Arndt, Mar 11 2010
STATUS
approved
Powers of 2: a(n) = 2^n.
(Formerly M1129 N0432)
+10
3232
1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 4096, 8192, 16384, 32768, 65536, 131072, 262144, 524288, 1048576, 2097152, 4194304, 8388608, 16777216, 33554432, 67108864, 134217728, 268435456, 536870912, 1073741824, 2147483648, 4294967296, 8589934592
OFFSET
0,2
COMMENTS
2^0 = 1 is the only odd power of 2.
Number of subsets of an n-set.
There are 2^(n-1) compositions (ordered partitions) of n (see for example Riordan). This is the unlabeled analog of the preferential labelings sequence A000670.
This is also the number of weakly unimodal permutations of 1..n + 1, that is, permutations with exactly one local maximum. E.g., a(4) = 16: 12345, 12354, 12453, 12543, 13452, 13542, 14532 and 15432 and their reversals. - Jon Perry, Jul 27 2003 [Proof: see next line! See also A087783.]
Proof: n must appear somewhere and there are 2^(n-1) possible choices for the subset that precedes it. These must appear in increasing order and the rest must follow n in decreasing order. QED. - N. J. A. Sloane, Oct 26 2003
a(n+1) is the smallest number that is not the sum of any number of (distinct) earlier terms.
Same as Pisot sequences E(1, 2), L(1, 2), P(1, 2), T(1, 2). See A008776 for definitions of Pisot sequences.
With initial 1 omitted, same as Pisot sequences E(2, 4), L(2, 4), P(2, 4), T(2, 4). - David W. Wilson
Not the sum of two or more consecutive numbers. - Lekraj Beedassy, May 14 2004
Least deficient or near-perfect numbers (i.e., n such that sigma(n) = A000203(n) = 2n - 1). - Lekraj Beedassy, Jun 03 2004. [Comment from Max Alekseyev, Jan 26 2005: All the powers of 2 are least deficient numbers but it is not known if there exists a least deficient number that is not a power of 2.]
Almost-perfect numbers referred to as least deficient or slightly defective (Singh 1997) numbers. Does "near-perfect numbers" refer to both almost-perfect numbers (sigma(n) = 2n - 1) and quasi-perfect numbers (sigma(n) = 2n + 1)? There are no known quasi-perfect or least abundant or slightly excessive (Singh 1997) numbers.
The sum of the numbers in the n-th row of Pascal's triangle; the sum of the coefficients of x in the expansion of (x+1)^n.
The Collatz conjecture (the hailstone sequence will eventually reach the number 1, regardless of which positive integer is chosen initially) may be restated as (the hailstone sequence will eventually reach a power of 2, regardless of which positive integer is chosen initially).
The only hailstone sequence which doesn't rebound (except "on the ground"). - Alexandre Wajnberg, Jan 29 2005
With p(n) as the number of integer partitions of n, p(i) is the number of parts of the i-th partition of n, d(i) is the number of different parts of the i-th partition of n, m(i,j) is the multiplicity of the j-th part of the i-th partition of n, one has: a(n) = Sum_{i = 1..p(n)} (p(i)! / (Product_{j=1..d(i)} m(i,j)!)). - Thomas Wieder, May 18 2005
The number of binary relations on an n-element set that are both symmetric and antisymmetric. Also the number of binary relations on an n-element set that are symmetric, antisymmetric and transitive.
The first differences are the sequence itself. - Alexandre Wajnberg and Eric Angelini, Sep 07 2005
a(n) is the largest number with shortest addition chain involving n additions. - David W. Wilson, Apr 23 2006
Beginning with a(1) = 0, numbers not equal to the sum of previous distinct natural numbers. - Giovanni Teofilatto, Aug 06 2006
For n >= 1, a(n) is equal to the number of functions f:{1, 2, ..., n} -> {1, 2} such that for a fixed x in {1, 2, ..., n} and a fixed y in {1, 2} we have f(x) != y. - Aleksandar M. Janjic and Milan Janjic, Mar 27 2007
Let P(A) be the power set of an n-element set A. Then a(n) is the number of pairs of elements {x,y} of P(A) for which x = y. - Ross La Haye, Jan 09 2008
a(n) is the number of different ways to run up a staircase with n steps, taking steps of sizes 1, 2, 3, ... and r (r <= n), where the order IS important and there is no restriction on the number or the size of each step taken. - Mohammad K. Azarian, May 21 2008
a(n) is the number of permutations on [n+1] such that every initial segment is an interval of integers. Example: a(3) counts 1234, 2134, 2314, 2341, 3214, 3241, 3421, 4321. The map "p -> ascents of p" is a bijection from these permutations to subsets of [n]. An ascent of a permutation p is a position i such that p(i) < p(i+1). The permutations shown map to 123, 23, 13, 12, 3, 2, 1 and the empty set respectively. - David Callan, Jul 25 2008
2^(n-1) is the largest number having n divisors (in the sense of A077569); A005179(n) is the smallest. - T. D. Noe, Sep 02 2008
a(n) appears to match the number of divisors of the modified primorials (excluding 2, 3 and 5). Very limited range examined, PARI example shown. - Bill McEachen, Oct 29 2008
Successive k such that phi(k)/k = 1/2, where phi is Euler's totient function. - Artur Jasinski, Nov 07 2008
A classical transform consists (for general a(n)) in swapping a(2n) and a(2n+1); examples for Jacobsthal A001045 and successive differences: A092808, A094359, A140505. a(n) = A000079 leads to 2, 1, 8, 4, 32, 16, ... = A135520. - Paul Curtz, Jan 05 2009
This is also the (L)-sieve transform of {2, 4, 6, 8, ..., 2n, ...} = A005843. (See A152009 for the definition of the (L)-sieve transform.) - John W. Layman, Jan 23 2009
a(n) = a(n-1)-th even natural number (A005843) for n > 1. - Jaroslav Krizek, Apr 25 2009
For n >= 0, a(n) is the number of leaves in a complete binary tree of height n. For n > 0, a(n) is the number of nodes in an n-cube. - K.V.Iyer, May 04 2009
Permutations of n+1 elements where no element is more than one position right of its original place. For example, there are 4 such permutations of three elements: 123, 132, 213, and 312. The 8 such permutations of four elements are 1234, 1243, 1324, 1423, 2134, 2143, 3124, and 4123. - Joerg Arndt, Jun 24 2009
Catalan transform of A099087. - R. J. Mathar, Jun 29 2009
a(n) written in base 2: 1,10,100,1000,10000,..., i.e., (n+1) times 1, n times 0 (A011557(n)). - Jaroslav Krizek, Aug 02 2009
Or, phi(n) is equal to the number of perfect partitions of n. - Juri-Stepan Gerasimov, Oct 10 2009
These are the 2-smooth numbers, positive integers with no prime factors greater than 2. - Michael B. Porter, Oct 04 2009
A064614(a(n)) = A000244(n) and A064614(m) < A000244(n) for m < a(n). - Reinhard Zumkeller, Feb 08 2010
a(n) is the largest number m such that the number of steps of iterations of {r - (largest divisor d < r)} needed to reach 1 starting at r = m is equal to n. Example (a(5) = 32): 32 - 16 = 16; 16 - 8 = 8; 8 - 4 = 4; 4 - 2 = 2; 2 - 1 = 1; number 32 has 5 steps and is the largest such number. See A105017, A064097, A175125. - Jaroslav Krizek, Feb 15 2010
a(n) is the smallest proper multiple of a(n-1). - Dominick Cancilla, Aug 09 2010
The powers-of-2 triangle T(n, k), n >= 0 and 0 <= k <= n, begins with: {1}; {2, 4}; {8, 16, 32}; {64, 128, 256, 512}; ... . The first left hand diagonal T(n, 0) = A006125(n + 1), the first right hand diagonal T(n, n) = A036442(n + 1) and the center diagonal T(2*n, n) = A053765(n + 1). Some triangle sums, see A180662, are: Row1(n) = A122743(n), Row2(n) = A181174(n), Fi1(n) = A181175(n), Fi2(2*n) = A181175(2*n) and Fi2(2*n + 1) = 2*A181175(2*n + 1). - Johannes W. Meijer, Oct 10 2010
Records in the number of prime factors. - Juri-Stepan Gerasimov, Mar 12 2011
Row sums of A152538. - Gary W. Adamson, Dec 10 2008
A078719(a(n)) = 1; A006667(a(n)) = 0. - Reinhard Zumkeller, Oct 08 2011
The compositions of n in which each natural number is colored by one of p different colors are called p-colored compositions of n. For n>=1, a(n) equals the number of 2-colored compositions of n such that no adjacent parts have the same color. - Milan Janjic, Nov 17 2011
Equals A001405 convolved with its right-shifted variant: (1 + 2x + 4x^2 + ...) = (1 + x + 2x^2 + 3x^3 + 6x^4 + 10x^5 + ...) * (1 + x + x^2 + 2x^3 + 3x^4 + 6x^5 + ...). - Gary W. Adamson, Nov 23 2011
The number of odd-sized subsets of an n+1-set. For example, there are 2^3 odd-sized subsets of {1, 2, 3, 4}, namely {1}, {2}, {3}, {4}, {1, 2, 3}, {1, 2, 4}, {1, 3, 4}, and {2, 3, 4}. Also, note that 2^n = Sum_{k=1..floor((n+1)/2)} C(n+1, 2k-1). - Dennis P. Walsh, Dec 15 2011
a(n) is the number of 1's in any row of Pascal's triangle (mod 2) whose row number has exactly n 1's in its binary expansion (see A007318 and A047999). (The result of putting together A001316 and A000120.) - Marcus Jaiclin, Jan 31 2012
A204455(k) = 1 if and only if k is in this sequence. - Wolfdieter Lang, Feb 04 2012
For n>=1 apparently the number of distinct finite languages over a unary alphabet, whose minimum regular expression has alphabetic width n (verified up to n=17), see the Gruber/Lee/Shallit link. - Hermann Gruber, May 09 2012
First differences of A000225. - Omar E. Pol, Feb 19 2013
This is the lexicographically earliest sequence which contains no arithmetic progression of length 3. - Daniel E. Frohardt, Apr 03 2013
a(n-2) is the number of bipartitions of {1..n} (i.e., set partitions into two parts) such that 1 and 2 are not in the same subset. - Jon Perry, May 19 2013
Numbers n such that the n-th cyclotomic polynomial has a root mod 2; numbers n such that the n-th cyclotomic polynomial has an even number of odd coefficients. - Eric M. Schmidt, Jul 31 2013
More is known now about non-power-of-2 "Almost Perfect Numbers" as described in Dagal. - Jonathan Vos Post, Sep 01 2013
Number of symmetric Ferrers diagrams that fit into an n X n box. - Graham H. Hawkes, Oct 18 2013
Numbers n such that sigma(2n) = 2n + sigma(n). - Jahangeer Kholdi, Nov 23 2013
a(1), ..., a(floor(n/2)) are all values of permanent on set of square (0,1)-matrices of order n>=2 with row and column sums 2. - Vladimir Shevelev, Nov 26 2013
Numbers whose base-2 expansion has exactly one bit set to 1, and thus has base-2 sum of digits equal to one. - Stanislav Sykora, Nov 29 2013
A072219(a(n)) = 1. - Reinhard Zumkeller, Feb 20 2014
a(n) is the largest number k such that (k^n-2)/(k-2) is an integer (for n > 1); (k^a(n)+1)/(k+1) is never an integer (for k > 1 and n > 0). - Derek Orr, May 22 2014
If x = A083420(n), y = a(n+1) and z = A087289(n), then x^2 + 2*y^2 = z^2. - Vincenzo Librandi, Jun 09 2014
The mini-sequence b(n) = least number k > 0 such that 2^k ends in n identical digits is given by {1, 18, 39}. The repeating digits are {2, 4, 8} respectively. Note that these are consecutive powers of 2 (2^1, 2^2, 2^3), and these are the only powers of 2 (2^k, k > 0) that are only one digit. Further, this sequence is finite. The number of n-digit endings for a power of 2 with n or more digits id 4*5^(n-1). Thus, for b(4) to exist, one only needs to check exponents up to 4*5^3 = 500. Since b(4) does not exist, it is clear that no other number will exist. - Derek Orr, Jun 14 2014
The least number k > 0 such that 2^k ends in n consecutive decreasing digits is a 3-number sequence given by {1, 5, 25}. The consecutive decreasing digits are {2, 32, 432}. There are 100 different 3-digit endings for 2^k. There are no k-values such that 2^k ends in '987', '876', '765', '654', '543', '321', or '210'. The k-values for which 2^k ends in '432' are given by 25 mod 100. For k = 25 + 100*x, the digit immediately before the run of '432' is {4, 6, 8, 0, 2, 4, 6, 8, 0, 2, ...} for x = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, ...}, respectively. Thus, we see the digit before '432' will never be a 5. So, this sequence is complete. - Derek Orr, Jul 03 2014
a(n) is the number of permutations of length n avoiding both 231 and 321 in the classical sense which are breadth-first search reading words of increasing unary-binary trees. For more details, see the entry for permutations avoiding 231 at A245898. - Manda Riehl, Aug 05 2014
Numbers n such that sigma(n) = sigma(2n) - phi(4n). - Farideh Firoozbakht, Aug 14 2014
This is a B_2 sequence: for i < j, differences a(j) - a(i) are all distinct. Here 2*a(n) < a(n+1) + 1, so a(n) - a(0) < a(n+1) - a(n). - Thomas Ordowski, Sep 23 2014
a(n) counts n-walks (closed) on the graph G(1-vertex; 1-loop, 1-loop). - David Neil McGrath, Dec 11 2014
a(n-1) counts walks (closed) on the graph G(1-vertex; 1-loop, 2-loop, 3-loop, 4-loop, ...). - David Neil McGrath, Jan 01 2015
b(0) = 4; b(n+1) is the smallest number not in the sequence such that b(n+1) - Prod_{i=0..n} b(i) divides b(n+1) - Sum_{i=0..n} b(i). Then b(n) = a(n) for n > 2. - Derek Orr, Jan 15 2015
a(n) counts the permutations of length n+2 whose first element is 2 such that the permutation has exactly one descent. - Ran Pan, Apr 17 2015
a(0)-a(30) appear, with a(26)-a(30) in error, in tablet M 08613 (see CDLI link) from the Old Babylonian period (c. 1900-1600 BC). - Charles R Greathouse IV, Sep 03 2015
Subsequence of A028982 (the squares or twice squares sequence). - Timothy L. Tiffin, Jul 18 2016
A000120(a(n)) = 1. A000265(a(n)) = 1. A000593(a(n)) = 1. - Juri-Stepan Gerasimov, Aug 16 2016
Number of monotone maps f : [0..n] -> [0..n] which are order-increasing (i <= f(i)) and idempotent (f(f(i)) = f(i)). In other words, monads on the n-th ordinal (seen as a posetal category). Any monad f determines a subset of [0..n] that contains n, by considering its set of monad algebras = fixed points { i | f(i) = i }. Conversely, any subset S of [0..n] containing n determines a monad on [0..n], by the function i |-> min { j | i <= j, j in S }. - Noam Zeilberger, Dec 11 2016
Consider n points lying on a circle. Then for n>=2 a(n-2) gives the number of ways to connect two adjacent points with nonintersecting chords. - Anton Zakharov, Dec 31 2016
Satisfies Benford's law [Diaconis, 1977; Berger-Hill, 2017] - N. J. A. Sloane, Feb 07 2017
Also the number of independent vertex sets and vertex covers in the n-empty graph. - Eric W. Weisstein, Sep 21 2017
Also the number of maximum cliques in the n-halved cube graph for n > 4. - Eric W. Weisstein, Dec 04 2017
Number of pairs of compositions of n corresponding to a seaweed algebra of index n-1. - Nick Mayers, Jun 25 2018
The multiplicative group of integers modulo a(n) is cyclic if and only if n = 0, 1, 2. For n >= 3, it is a product of two cyclic groups. - Jianing Song, Jun 27 2018
k^n is the determinant of n X n matrix M_(i, j) = binomial(k + i + j - 2, j) - binomial(i+j-2, j), in this case k=2. - Tony Foster III, May 12 2019
Solutions to the equation Phi(2n + 2*Phi(2n)) = 2n. - M. Farrokhi D. G., Jan 03 2020
a(n-1) is the number of subsets of {1,2,...,n} which have an element that is the size of the set. For example, for n = 4, a(3) = 8 and the subsets are {1}, {1,2}, {2,3}, {2,4}, {1,2,3}, {1,3,4}, {2,3,4}, {1,2,3,4}. - Enrique Navarrete, Nov 21 2020
a(n) is the number of self-inverse (n+1)-order permutations with 231-avoiding. E.g., a(3) = 8: [1234, 1243, 1324, 1432, 2134, 2143, 3214, 4321]. - Yuchun Ji, Feb 26 2021
For any fixed k > 0, a(n) is the number of ways to tile a strip of length n+1 with tiles of length 1, 2, ... k, where the tile of length k can be black or white, with the restriction that the first tile cannot be black. - Greg Dresden and Bora Bursalı, Aug 31 2023
REFERENCES
Milton Abramowitz and Irene A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 1016.
Mohammad K. Azarian, A Generalization of the Climbing Stairs Problem, Mathematics and Computer Education Journal, Vol. 31, No. 1, pp. 24-28, Winter 1997.
Jan Gullberg, Mathematics from the Birth of Numbers, W. W. Norton & Co., NY & London, 1997, §4.5 Logarithms and §8.1 Terminology, pp. 150, 264.
Paul J. Nahin, An Imaginary Tale: The Story of sqrt(-1), Princeton University Press, Princeton, NJ. 1998, pp. 69-70.
J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 124.
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).
V. E. Tarakanov, Combinatorial problems on binary matrices, Combin. Analysis, MSU, 5 (1980), 4-15. (Russian)
S. Wolfram, A New Kind of Science, Wolfram Media, 2002; p. 55.
LINKS
Milton Abramowitz and Irene A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards, Applied Math. Series 55, Tenth Printing, 1972 [alternative scanned copy].
Juan S. Auli and Sergi Elizalde, Wilf equivalences between vincular patterns in inversion sequences, arXiv:2003.11533 [math.CO], 2020.
Paul Barry, A Catalan Transform and Related Transformations on Integer Sequences, Journal of Integer Sequences, Vol. 8 (2005), Article 05.4.5.
Jonathan Beagley and Lara Pudwell, Colorful Tilings and Permutations, Journal of Integer Sequences, Vol. 24 (2021), Article 21.10.4.
Arno Berger and Theodore P. Hill, What is Benford's Law?, Notices, Amer. Math. Soc., 64:2 (2017), 132-134.
Tobias Boege and Thomas Kahle, Construction Methods for Gaussoids, arXiv:1902.11260 [math.CO], 2019.
Anicius Manlius Severinus Boethius, De arithmetica, Book 1, section 9.
Peter J. Cameron, Sequences realized by oligomorphic permutation groups, J. Integ. Seqs. Vol. 3 (2000), #00.1.5.
Peter J. Cameron, Notes on Counting, Peter Cameron's Blog, 15/05/2017.
CDLI, M 08613.
Giulio Cerbai, Anders Claesson, and Luca Ferrari, Stack sorting with restricted stacks, arXiv:1907.08142 [cs.DS], 2019.
V. Coll, M. Hyatt, C. Magnant, and H. Wang, Meander graphs and Frobenius seaweed Lie algebras II, Journal of Generalized Lie Theory and Applications 9 (1) (2015) 227.
M. Coons and H. Winning, Powers of Two Modulo Powers of Three, J. Int. Seq. 18 (2015) # 15.6.1.
Keneth Adrian P. Dagal and Jose Arnaldo B. Dris, A Criterion for Almost Perfect Numbers in Terms of the Abundancy Index, arXiv:1308.6767v1 [math.NT], Aug 14 2013.
V. Dergachev and A. Kirillov, Index of Lie algebras of seaweed type, J. Lie Theory 10 (2) (2000) 331-343.
Persi Diaconis, The distribution of leading digits and uniform distribution mod 1, Ann. Probability, 5, 1977, 72--81.
David Eppstein, Making Change in 2048, arXiv:1804.07396 [cs.DM], 2018.
P. Flajolet and R. Sedgewick, Analytic Combinatorics, 2009; see page 18
Joël Gay and Vincent Pilaud, The weak order on Weyl posets, arXiv:1804.06572 [math.CO], 2018.
Daniele A. Gewurz and Francesca Merola, Sequences realized as Parker vectors of oligomorphic permutation groups, J. Integer Seqs., Vol. 6, 2003.
Hermann Gruber, Jonathan Lee and Jeffrey Shallit, Enumerating regular expressions and their languages, arXiv:1204.4982v1 [cs.FL], 2012.
Marcus Jaiclin, et al. Pascal's Triangle, Mod 2,3,5
J. W. Layman, The Hankel Transform and Some of its Properties, J. Integer Sequences, 4 (2001), #01.1.5.
P. A. MacMahon, Memoir on the Theory of the Compositions of Numbers, Phil. Trans. Royal Soc. London A, 184 (1893), 835-901.
Augustine O. Munagi, Integer Compositions and Higher-Order Conjugation, J. Int. Seq., Vol. 21 (2018), Article 18.8.5.
R. Ondrejka, Exact values of 2^n, n=1(1)4000, Math. Comp., 23 (1969), 456.
G. Pfeiffer, Counting Transitive Relations, Journal of Integer Sequences, Vol. 7 (2004), Article 04.3.2.
Shingo Saito, Tatsushi Tanaka, and Noriko Wakabayashi, Combinatorial Remarks on the Cyclic Sum Formula for Multiple Zeta Values, J. Int. Seq. 14 (2011) # 11.2.4, Table 1.
Michael Z. Spivey and Laura L. Steil, The k-Binomial Transforms and the Hankel Transform, Journal of Integer Sequences, Vol. 9 (2006), Article 06.1.1.
J. Tanton, A Dozen Questions about the Powers of Two, Math Horizons, Vol. 8, pp. 5-10, September 2001.
G. Villemin's Almanac of Numbers, Puissances de 2
Eric Weisstein's World of Mathematics, Abundance
Eric Weisstein's World of Mathematics, Binomial Sums
Eric Weisstein's World of Mathematics, Binomial Transform
Eric Weisstein's World of Mathematics, Hailstone Number (Collatz Problem)
Eric Weisstein's World of Mathematics, Composition
Eric Weisstein's World of Mathematics, Elementary Cellular Automaton
Eric Weisstein's World of Mathematics, Empty Graph
Eric Weisstein's World of Mathematics, Erf
Eric Weisstein's World of Mathematics, Fractional Part
Eric Weisstein's World of Mathematics, Halved Cube Graph
Eric Weisstein's World of Mathematics, Hypercube
Eric Weisstein's World of Mathematics, Independent Vertex Set
Eric Weisstein's World of Mathematics, Least Deficient Number
Eric Weisstein's World of Mathematics, Maximum Clique
Eric Weisstein's World of Mathematics, PowerFractional Parts
Eric Weisstein's World of Mathematics, Subset
Eric Weisstein's World of Mathematics, Vertex Cover
FORMULA
a(n) = 2^n.
a(0) = 1; a(n) = 2*a(n-1).
G.f.: 1/(1 - 2*x).
E.g.f.: exp(2*x).
a(n)= Sum_{k = 0..n} binomial(n, k).
a(n) is the number of occurrences of n in A000523. a(n) = A001045(n) + A001045(n+1). a(n) = 1 + Sum_{k = 0..(n - 1)} a(k). The Hankel transform of this sequence gives A000007 = [1, 0, 0, 0, 0, 0, ...]. - Philippe Deléham, Feb 25 2004
n such that phi(n) = n/2, for n > 1, where phi is Euler's totient (A000010). - Lekraj Beedassy, Sep 07 2004
a(n + 1) = a(n) XOR 3*a(n) where XOR is the binary exclusive OR operator. - Philippe Deléham, Jun 19 2005
a(n) = StirlingS2(n + 1, 2) + 1. - Ross La Haye, Jan 09 2008
a(n+2) = 6a(n+1) - 8a(n), n = 1, 2, 3, ... with a(1) = 1, a(2) = 2. - Yosu Yurramendi, Aug 06 2008
a(n) = ka(n-1) + (4 - 2k)a(n-2) for any integer k and n > 1, with a(0) = 1, a(1) = 2. - Jaume Oliver Lafont, Dec 05 2008
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. - Thomas Wieder, Feb 25 2009
a(0) = 1, a(1) = 2; a(n) = a(n-1)^2/a(n-2), n >= 2. - Jaume Oliver Lafont, Sep 22 2009
a(n) = A173786(n, n)/2 = A173787(n + 1, n). - Reinhard Zumkeller, Feb 28 2010
If p[i] = i - 1 and if A is the Hessenberg matrix of order n defined by: A[i, j] = p[j - i + 1], (i <= j), A[i, j] = -1, (i = j + 1), and A[i, j] = 0 otherwise. Then, for n >= 1, a(n-1) = det A. - Milan Janjic, May 02 2010
If p[i] = Fibonacci(i-2) and if A is the Hessenberg matrix of order n defined by: A[i, j] = p[j - i + 1], (i <= j), A[i, j] = -1, (i = j + 1), and A[i, j] = 0 otherwise. Then, for n >= 2, a(n-2) = det A. - Milan Janjic, May 08 2010
The sum of reciprocals, 1/1 + 1/2 + 1/4 + 1/8 + ... + 1/(2^n) + ... = 2. - Mohammad K. Azarian, Dec 29 2010
a(n) = 2*A001045(n) + A078008(n) = 3*A001045(n) + (-1)^n. - Paul Barry, Feb 20 2003
a(n) = A118654(n, 2).
a(n) = A140740(n+1, 1).
a(n) = A131577(n) + A011782(n) = A024495(n) + A131708(n) + A024493(n) = A000749(n) + A038503(n) + A038504(n) + A038505(n) = A139761(n) + A139748(n) + A139714(n) + A133476(n) + A139398(n). - Paul Curtz, Jul 25 2011
a(n) = row sums of A007318. - Susanne Wienand, Oct 21 2011
a(n) = Hypergeometric([-n], [], -1). - Peter Luschny, Nov 01 2011
G.f.: A(x) = B(x)/x, B(x) satisfies B(B(x)) = x/(1 - x)^2. - Vladimir Kruchinin, Nov 10 2011
a(n) = Sum_{k = 0..n} A201730(n, k)*(-1)^k. - Philippe Deléham, Dec 06 2011
2^n = Sum_{k = 1..floor((n+1)/2)} C(n+1, 2k-1). - Dennis P. Walsh, Dec 15 2011
A209229(a(n)) = 1. - Reinhard Zumkeller, Mar 07 2012
A001227(a(n)) = 1. - Reinhard Zumkeller, May 01 2012
Sum_{n >= 1} mobius(n)/a(n) = 0.1020113348178103647430363939318... - R. J. Mathar, Aug 12 2012
E.g.f.: 1 + 2*x/(U(0) - x) where U(k) = 6*k + 1 + x^2/(6*k+3 + x^2/(6*k + 5 + x^2/U(k+1) )); (continued fraction, 3-step). - Sergei N. Gladkovskii, Dec 04 2012
a(n) = det(|s(i+2,j)|, 1 <= i,j <= n), where s(n,k) are Stirling numbers of the first kind. - Mircea Merca, Apr 04 2013
a(n) = det(|ps(i+1,j)|, 1 <= i,j <= n), where ps(n,k) are Legendre-Stirling numbers of the first kind (A129467). - Mircea Merca, Apr 06 2013
G.f.: W(0), where W(k) = 1 + 2*x*(k+1)/(1 - 2*x*(k+1)/( 2*x*(k+2) + 1/W(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Aug 28 2013
a(n-1) = Sum_{t_1 + 2*t_2 + ... + n*t_n = n} multinomial(t_1 + t_2 + ... + t_n; t_1, t_2, ..., t_n). - Mircea Merca, Dec 06 2013
Construct the power matrix T(n,j) = [A^*j]*[S^*(j-1)] where A(n)=(1,1,1,...) and S(n)=(0,1,0,0,...) (where * is convolution operation). Then a(n-1) = Sum_{j=1..n} T(n,j). - David Neil McGrath, Jan 01 2015
a(n) = A000005(A002110(n)). - Ivan N. Ianakiev, May 23 2016
From Ilya Gutkovskiy, Jul 18 2016: (Start)
Exponential convolution of A000012 with themselves.
a(n) = Sum_{k=0..n} A011782(k).
Sum_{n>=0} a(n)/n! = exp(2) = A072334.
Sum_{n>=0} (-1)^n*a(n)/n! = exp(-2) = A092553. (End)
G.f.: (r(x) * r(x^2) * r(x^4) * r(x^8) * ...) where r(x) = A090129(x) = (1 + 2x + 2x^2 + 4x^3 + 8x^4 + ...). - Gary W. Adamson, Sep 13 2016
a(n) = A000045(n + 1) + A000045(n) + Sum_{k = 0..n - 2} A000045(k + 1)*2^(n - 2 - k). - Melvin Peralta, Dec 22 2017
a(n) = 7*A077020(n)^2 + A077021(n)^2, n>=3. - Ralf Steiner, Aug 08 2021
a(n)= n + 1 + Sum_{k=3..n+1} (2*k-5)*J(n+2-k), where Jacobsthal number J(n) = A001045(n). - Michael A. Allen, Jan 12 2022
Integral_{x=0..Pi} cos(x)^n*cos(n*x) dx = Pi/a(n) (see Nahin, pp. 69-70). - Stefano Spezia, May 17 2023
EXAMPLE
There are 2^3 = 8 subsets of a 3-element set {1,2,3}, namely { -, 1, 2, 3, 12, 13, 23, 123 }.
MAPLE
A000079 := n->2^n; [ seq(2^n, n=0..50) ];
isA000079 := proc(n)
local fs;
fs := numtheory[factorset](n) ;
if n = 1 then
true ;
elif nops(fs) <> 1 then
false;
elif op(1, fs) = 2 then
true;
else
false ;
end if;
end proc: # R. J. Mathar, Jan 09 2017
MATHEMATICA
Table[2^n, {n, 0, 50}]
2^Range[0, 50] (* Wesley Ivan Hurt, Jun 14 2014 *)
LinearRecurrence[{2}, {2}, {0, 20}] (* Eric W. Weisstein, Sep 21 2017 *)
CoefficientList[Series[1/(1 - 2 x), {x, 0, 20}], x] (* Eric W. Weisstein, Sep 21 2017 *)
NestList[2# &, 1, 40] (* Harvey P. Dale, Oct 07 2019 *)
PROG
(PARI) A000079(n)=2^n \\ Edited by M. F. Hasler, Aug 27 2014
(PARI) unimodal(n)=local(x, d, um, umc); umc=0; for (c=0, n!-1, x=numtoperm(n, c); d=0; um=1; for (j=2, n, if (x[j]<x[j-1], d=1); if (x[j]>x[j-1] && d==1, um=0); if (um==0, break)); if (um==1, print(x)); umc+=um); umc
(Haskell)
a000079 = (2 ^)
a000079_list = iterate (* 2) 1
-- Reinhard Zumkeller, Jan 22 2014, Mar 05 2012, Dec 29 2011
(Maxima) A000079(n):=2^n$ makelist(A000079(n), n, 0, 30); /* Martin Ettl, Nov 05 2012 */
(Magma) [2^n: n in [0..40]]; // Vincenzo Librandi, Feb 17 2014
(Magma) [n le 2 select n else 5*Self(n-1)-6*Self(n-2): n in [1..40]]; // Vincenzo Librandi, Feb 17 2014
(Scheme) (define (A000079 n) (expt 2 n)) ;; Antti Karttunen, Mar 21 2017
(Scala) (List.fill(20)(2: BigInt)).scanLeft(1: BigInt)(_ * _) // Alonso del Arte, Jan 16 2020
(Python)
def a(n): return 1<<n
print([a(n) for n in range(34)]) # Michael S. Branicky, Jul 28 2022
CROSSREFS
This is the Hankel transform (see A001906 for the definition) of A000984, A002426, A026375, A026387, A026569, A026585, A026671 and A032351. - John W. Layman, Jul 31 2000
Euler transform of A001037, A209406 (multisets), inverse binomial transform of A000244, binomial transform of A000012.
Complement of A057716.
Boustrophedon transforms: A000734, A000752.
Range of values of A006519, A007875, A011782, A030001, A034444, A037445, A053644, and A054243.
Cf. A018900, A014311, A014312, A014313, A023688, A023689, A023690, A023691 (sum of 2, ..., 9 distinct powers of 2).
Cf. A090129.
The following are parallel families: A000079 (2^n), A004094 (2^n reversed), A028909 (2^n sorted up), A028910 (2^n sorted down), A036447 (double and reverse), A057615 (double and sort up), A263451 (double and sort down); A000244 (3^n), A004167 (3^n reversed), A321540 (3^n sorted up), A321539 (3^n sorted down), A163632 (triple and reverse), A321542 (triple and sort up), A321541 (triple and sort down).
KEYWORD
nonn,core,easy,nice
EXTENSIONS
Clarified a comment T. D. Noe, Aug 30 2009
Edited by Daniel Forgues, May 12 2010
Incorrect comment deleted by Matthew Vandermast, May 17 2014
Comment corrected to match offset by Geoffrey Critzer, Nov 28 2014
STATUS
approved
Repunits: (10^n - 1)/9. Often denoted by R_n.
+10
1180
0, 1, 11, 111, 1111, 11111, 111111, 1111111, 11111111, 111111111, 1111111111, 11111111111, 111111111111, 1111111111111, 11111111111111, 111111111111111, 1111111111111111, 11111111111111111, 111111111111111111, 1111111111111111111, 11111111111111111111
OFFSET
0,3
COMMENTS
R_n is a string of n 1's.
Base-4 representation of Jacobsthal bisection sequence A002450. E.g., a(4)= 1111 because A002450(4)= 85 (in base 10) = 64 + 16 + 4 + 1 = 1*(4^3) + 1*(4^2) + 1*(4^1) + 1. - Paul Barry, Mar 12 2004
Except for the first two terms, these numbers cannot be perfect squares, because x^2 != 11 (mod 100). - Zak Seidov, Dec 05 2008
For n >= 0: a(n) = (A000225(n) written in base 2). - Jaroslav Krizek, Jul 27 2009, edited by M. F. Hasler, Jul 03 2020
Let A be the Hessenberg matrix of order n, defined by: A[1,j]=1, A[i,i]:=10, (i>1), A[i,i-1]=-1, and A[i,j]=0 otherwise. Then, for n>=1, a(n)=det(A). - Milan Janjic, Feb 21 2010
Except 0, 1 and 11, all these integers are Brazilian numbers, A125134. - Bernard Schott, Dec 24 2012
Numbers n such that 11...111 = R_n = (10^n - 1)/9 is prime are in A004023. - Bernard Schott, Dec 24 2012
The terms 0 and 1 are the only squares in this sequence, as a(n) == 3 (mod 4) for n>=2. - Nehul Yadav, Sep 26 2013
For n>=2 the multiplicative order of 10 modulo the a(n) is n. - Robert G. Wilson v, Aug 20 2014
The above is a special case of the statement that the order of z modulo (z^n-1)/(z-1) is n, here for z=10. - Joerg Arndt, Aug 21 2014
From Peter Bala, Sep 20 2015: (Start)
Let d be a divisor of a(n). Let m*d be any multiple of d. Split the decimal expansion of m*d into 2 blocks of contiguous digits a and b, so we have m*d = 10^k*a + b for some k, where 0 <= k < number of decimal digits of m*d. Then d divides a^n - (-b)^n (see McGough). For example, 271 divides a(5) and we find 2^5 + 71^5 = 11*73*271*8291 and 27^5 + 1^5 = 2^2*7*31*61*271 are both divisible by 271. Similarly, 4*271 = 1084 and 10^5 + 84^5 = 2^5*31*47*271*331 while 108^5 + 4^5 = 2^12*7*31*61*271 are again both divisible by 271. (End)
Starting with the second term this sequence is the binary representation of the n-th iteration of the Rule 220 and 252 elementary cellular automaton starting with a single ON (black) cell. - Robert Price, Feb 21 2016
If p > 5 is a prime, then p divides a(p-1). - Thomas Ordowski, Apr 10 2016
0, 1 and 11 are only terms that are of the form x^2 + y^2 + z^2 where x, y, z are integers. In other words, a(n) is a member of A004215 for all n > 2. - Altug Alkan, May 08 2016
Except for the initial terms, the binary representation of the x-axis, from the left edge to the origin, of the n-th stage of growth of the two-dimensional cellular automaton defined by "Rule 737", based on the 5-celled von Neumann neighborhood, initialized with a single black (ON) cell at stage zero. - Robert Price, Mar 17 2017
The term "repunit" was coined by Albert H. Beiler in 1964. - Amiram Eldar, Nov 13 2020
q-integers for q = 10. - John Keith, Apr 12 2021
Binomial transform of A001019 with leading zero. - Jules Beauchamp, Jan 04 2022
REFERENCES
Albert H. Beiler, Recreations in the Theory of Numbers: The Queen of Mathematics Entertains, New York: Dover Publications, 1964, chapter XI, p. 83.
David Wells, The Penguin Dictionary of Curious and Interesting Numbers, Penguin Books, 1987, pp. 197-198.
Samuel Yates, Peculiar Properties of Repunits, J. Recr. Math. 2, 139-146, 1969.
Samuel Yates, Prime Divisors of Repunits, J. Recr. Math. 8, 33-38, 1975.
LINKS
Eudes Antonio Costa and Fernando Soares Carvalho, On repunit polynomials sequence, Braz. Elec. J. Math. (2024). See pp. 2, 15.
Dmytro S. Inosov and Emil Vlasák, Cryptarithmically unique terms in integer sequences, arXiv:2410.21427 [math.NT], 2024. See pp. 3, 18.
W. M. Snyder, Factoring Repunits, Am. Math. Monthly, Vol. 89, No. 7 (1982), pp. 462-466.
Amelia Carolina Sparavigna, On Repunits, Politecnico di Torino (Italy, 2019).
Amelia Carolina Sparavigna, Composition Operations of Generalized Entropies Applied to the Study of Numbers, International Journal of Sciences (2019) Vol. 8, No. 4, 87-92.
Amelia Carolina Sparavigna, Some Groupoids and their Representations by Means of Integer Sequences, International Journal of Sciences (2019) Vol. 8, No. 10.
Eudes Antonio Costa, Douglas Catulio Santos, Paula Maria Machado Cruz Catarino, and Elen Viviani Pereira Spreafico, On Gaussian and Quaternion Repunit Numbers, Rev. Mat. UFOP (Brazil, 2024) Vol. 2. See p. 2.
Eudes Antonio Costa, Paula Maria Machado Cruz Catarino, and Douglas Catulio Santos, A Study of the Symmetry of the Tricomplex Repunit Sequence with Repunit Sequence, Symmetry (2024) Vol. 17, No. 1, 28.
Eric Weisstein's World of Mathematics, Repunit.
Eric Weisstein's World of Mathematics, Demlo Number.
Eric Weisstein's World of Mathematics, Elementary Cellular Automaton.
Wikipedia, Repunit.
Amin Witno, A Family of Sequences Generating Smith Numbers, J. Int. Seq. 16 (2013) #13.4.6.
Stephen Wolfram, A New Kind of Science.
Samuel Yates, The Mystique of Repunits, Math. Mag., Vol. 51, No. 1 (1978), pp. 22-28.
FORMULA
a(n) = 10*a(n-1) + 1, a(0)=0.
a(n) = A000042(n) for n >= 1.
Second binomial transform of Jacobsthal trisection A001045(3n)/3 (A015565). - Paul Barry, Mar 24 2004
G.f.: x/((1-10*x)*(1-x)). Regarded as base b numbers, g.f. x/((1-b*x)*(1-x)). - Franklin T. Adams-Watters, Jun 15 2006
a(n) = 11*a(n-1) - 10*a(n-2), a(0)=0, a(1)=1. - Lekraj Beedassy, Jun 07 2006
a(n) = A125118(n,9) for n>8. - Reinhard Zumkeller, Nov 21 2006
a(n) = A075412(n)/A002283(n). - Reinhard Zumkeller, May 31 2010
a(n) = a(n-1) + 10^(n-1) with a(0)=0. - Vincenzo Librandi, Jul 22 2010
a(n) = A242614(n,A242622(n)). - Reinhard Zumkeller, Jul 17 2014
E.g.f.: (exp(9*x) - 1)*exp(x)/9. - Ilya Gutkovskiy, May 11 2016
a(n) = Sum_{k=0..n-1} 10^k. - Torlach Rush, Nov 03 2020
Sum_{n>=1} 1/a(n) = A065444. - Amiram Eldar, Nov 13 2020
MAPLE
seq((10^k - 1)/9, k=0..30); # Wesley Ivan Hurt, Sep 28 2013
MATHEMATICA
Table[(10^n - 1)/9, {n, 0, 19}] (* Alonso del Arte, Nov 15 2011 *)
Join[{0}, Table[FromDigits[PadRight[{}, n, 1]], {n, 20}]] (* Harvey P. Dale, Mar 04 2012 *)
PROG
(PARI) a(n)=(10^n-1)/9; \\ Michael B. Porter, Oct 26 2009
(PARI) x='x+O('x^99); concat(0, Vec(x/((1-10*x)*(1-x)))) \\ Altug Alkan, Apr 10 2016
(Sage) [lucas_number1(n, 11, 10) for n in range(21)] # Zerinvary Lajos, Apr 27 2009
(Haskell)
a002275 = (`div` 9) . subtract 1 . (10 ^)
a002275_list = iterate ((+ 1) . (* 10)) 0
-- Reinhard Zumkeller, Jul 05 2013, Feb 05 2012
(Maxima)
a[0]:0$
a[1]:1$
a[n]:=11*a[n-1]-10*a[n-2]$
A002275(n):=a[n]$
makelist(A002275(n), n, 0, 30); /* Martin Ettl, Nov 05 2012 */
(Magma) [(10^n-1)/9: n in [0..25]]; // Vincenzo Librandi, Nov 06 2014
(Python)
print([(10**n-1)//9 for n in range(100)]) # Michael S. Branicky, Apr 30 2022
CROSSREFS
Partial sums of 10^n (A011557). Factors: A003020, A067063.
Bisections give A099814, A100706.
Numbers having multiplicative digital roots 0-9: A034048, A002275, A034049, A034050, A034051, A034052, A034053, A034054, A034055, A034056.
KEYWORD
easy,nonn,nice,core,changed
STATUS
approved
The characteristic function of {0}: a(n) = 0^n.
(Formerly M0002)
+10
1058
1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
OFFSET
0,1
COMMENTS
Changing the offset to 1 gives the arithmetical function a(1) = 1, a(n) = 0 for n > 1, the identity function for Dirichlet multiplication (see Apostol). - N. J. A. Sloane
Changing the offset to 1 makes this the decimal expansion of 1. - N. J. A. Sloane, Nov 13 2014
Hankel transform (see A001906 for definition) of A000007 (powers of 0), A000012 (powers of 1), A000079 (powers of 2), A000244 (powers of 3), A000302 (powers of 4), A000351 (powers of 5), A000400 (powers of 6), A000420 (powers of 7), A001018 (powers of 8), A001019 (powers of 9), A011557 (powers of 10), A001020 (powers of 11), etc. - Philippe Deléham, Jul 07 2005
This is the identity sequence with respect to convolution. - David W. Wilson, Oct 30 2006
a(A000004(n)) = 1; a(A000027(n)) = 0. - Reinhard Zumkeller, Oct 12 2008
The alternating sum of the n-th row of Pascal's triangle gives the characteristic function of 0, a(n) = 0^n. - Daniel Forgues, May 25 2010
The number of maximal self-avoiding walks from the NW to SW corners of a 1 X n grid. - Sean A. Irvine, Nov 19 2010
Historically there has been some disagreement as to whether 0^0 = 1. Graphing x^0 seems to support that conclusion, but graphing 0^x instead suggests that 0^0 = 0. Euler and Knuth have argued in favor of 0^0 = 1. For some calculators, 0^0 triggers an error, while in Mathematica, 0^0 is Indeterminate. - Alonso del Arte, Nov 15 2011
Another consequence of changing the offset to 1 is that then this sequence can be described as the sum of Moebius mu(d) for the divisors d of n. - Alonso del Arte, Nov 28 2011
With the convention 0^0 = 1, 0^n = 0 for n > 0, the sequence a(n) = 0^|n-k|, which equals 1 when n = k and is 0 for n >= 0, has g.f. x^k. A000007 is the case k = 0. - George F. Johnson, Mar 08 2013
A fixed point of the run length transform. - Chai Wah Wu, Oct 21 2016
REFERENCES
T. M. Apostol, Introduction to Analytic Number Theory, Springer-Verlag, 1976, page 30.
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
S. Wolfram, A New Kind of Science, Wolfram Media, 2002; p. 55.
LINKS
Paul Barry, A Catalan Transform and Related Transformations on Integer Sequences, Journal of Integer Sequences, Vol. 8 (2005), Article 05.4.5.
Paul Barry, A Note on a Family of Generalized Pascal Matrices Defined by Riordan Arrays, Journal of Integer Sequences, 16 (2013), #13.5.4.
Daniele A. Gewurz and Francesca Merola, Sequences realized as Parker vectors of oligomorphic permutation groups, J. Integer Seqs., Vol. 6, 2003.
Donald E. Knuth, Two notes on notation, arXiv:math/9205211 [math.HO], 1992. See page 6 on 0^0.
Robert Price, Comments on A000007, Jan 27 2016
Eric Weisstein's World of Mathematics, Elementary Cellular Automaton
FORMULA
Multiplicative with a(p^e) = 0. - David W. Wilson, Sep 01 2001
a(n) = floor(1/(n + 1)). - Franz Vrabec, Aug 24 2005
As a function of Bernoulli numbers (cf. A027641: (1, -1/2, 1/6, 0, -1/30, ...)), triangle A074909 (the beheaded Pascal's triangle) * B_n as a vector = [1, 0, 0, 0, 0, ...]. - Gary W. Adamson, Mar 05 2012
a(n) = Sum_{k = 0..n} exp(2*Pi*i*k/(n+1)) is the sum of the (n+1)th roots of unity. - Franz Vrabec, Nov 09 2012
a(n) = (1-(-1)^(2^n))/2. - Luce ETIENNE, May 05 2015
a(n) = 1 - A057427(n). - Alois P. Heinz, Jan 20 2016
From Ilya Gutkovskiy, Sep 02 2016: (Start)
Binomial transform of A033999.
Inverse binomial transform of A000012. (End)
MAPLE
A000007 := proc(n) if n = 0 then 1 else 0 fi end: seq(A000007(n), n=0..20);
spec := [A, {A=Z} ]: seq(combstruct[count](spec, size=n+1), n=0..20);
MATHEMATICA
Table[If[n == 0, 1, 0], {n, 0, 99}]
Table[Boole[n == 0], {n, 0, 99}] (* Michael Somos, Aug 25 2012 *)
Join[{1}, LinearRecurrence[{1}, {0}, 102]] (* Ray Chandler, Jul 30 2015 *)
PadRight[{1}, 120, 0] (* Harvey P. Dale, Jul 18 2024 *)
PROG
(PARI) {a(n) = !n};
(Magma) [1] cat [0:n in [1..100]]; // Sergei Haller, Dec 21 2006
(Haskell)
a000007 = (0 ^)
a000007_list = 1 : repeat 0
-- Reinhard Zumkeller, May 07 2012, Mar 27 2012
(Python)
def A000007(n): return int(n==0) # Chai Wah Wu, Feb 04 2022
CROSSREFS
Characteristic function of {g}: this sequence (g = 0), A063524 (g = 1), A185012 (g = 2), A185013 (g = 3), A185014 (g = 4), A185015 (g = 5), A185016 (g = 6), A185017 (g = 7). - Jason Kimberley, Oct 14 2011
Characteristic function of multiples of g: this sequence (g = 0), A000012 (g = 1), A059841 (g = 2), A079978 (g = 3), A121262 (g = 4), A079998 (g = 5), A079979 (g = 6), A082784 (g = 7). - Jason Kimberley, Oct 14 2011
KEYWORD
core,nonn,mult,cons,easy
STATUS
approved
Product of decimal digits of n.
+10
303
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 0, 3, 6, 9, 12, 15, 18, 21, 24, 27, 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 0, 5, 10, 15, 20, 25, 30, 35, 40, 45, 0, 6, 12, 18, 24, 30, 36, 42, 48, 54, 0, 7, 14, 21, 28, 35, 42, 49, 56, 63, 0, 8, 16, 24, 32, 40, 48, 56, 64, 72, 0, 9, 18, 27, 36, 45, 54, 63, 72, 81, 0, 0, 0, 0, 0, 0, 0, 0
OFFSET
0,3
COMMENTS
Moebius transform of A093811(n). a(n) = A093811(n) * A008683(n), where operation * denotes Dirichlet convolution, namely b(n) * c(n) = Sum_{d|n} b(d) * c(n/d). Simultaneously holds Dirichlet multiplication: a(n) * A000012(n) = A093811(n). - Jaroslav Krizek, Mar 22 2009
Apart from the 0's, all terms are in A002473. Further, for all m in A002473 there is some n such that a(n) = m, see A096867. - Charles R Greathouse IV, Sep 29 2013
a(n) = 0 asymptotically almost surely, namely for all n except for the set of numbers without digit '0'; this set is of density zero, since it is less and less probable to have no '0' as the number of digits of n grows. (See also A054054.) - M. F. Hasler, Oct 11 2015
LINKS
Rigoberto Flórez, Robinson A. Higuita and Antara Mukherjee, Alternating Sums in the Hosoya Polynomial Triangle, Article 14.9.5 Journal of Integer Sequences, Vol. 17 (2014).
Florentin Smarandache, Only Problems, Not Solutions!.
FORMULA
A000035(a(A014261(n))) = 1. - Reinhard Zumkeller, Nov 30 2007
a(n) = abs(A187844(n)). - Reinhard Zumkeller, Mar 14 2011
a(n) > 0 if and only if A054054(n) > 0. a(n) = d in {1, ..., 9} if n = (10^k - 1)/9 + (d - 1)*10^m = A002275(k) + (d - 1)*A011557(m) for some k > m >= 0. The statement holds with "if and only if" for d in {1, 2, 3, 5, 7}. For d = 4, 6, 8 or 9, one has a(n) = d if n = (10^k - 1)/9 + (a - 1)*10^m + (b - 1)*10^p with integers k > m > p >= 0 and a, b > 0 such that d = a*b. - M. F. Hasler, Oct 11 2015
From Robert Israel, May 17 2016: (Start)
G.f.: Sum_{n >= 0} Product_{j = 0..n} Sum_{k = 1..9} k*x^(k*10^j).
G.f. satisfies A(x) = (x + 2*x^2 + ... + 9*x^9)*(1 + A(x^10)). (End)
a(n) <= 9^(1 + log_10(n/9)). - Lucas A. Brown, Jun 22 2023
MAPLE
A007954 := proc(n::integer)
if n = 0 then
0;
else
mul( d, d=convert(n, base, 10)) ;
end if;
end proc: # R. J. Mathar, Oct 02 2019
MATHEMATICA
Array[Times @@ IntegerDigits@ # &, 108, 0] (* Robert G. Wilson v, Mar 15 2011 *)
PROG
(PARI) A007954(n)= { local(resul = n % 10); n \= 10; while( n > 0, resul *= n %10; n \= 10; ); return(resul); } \\ R. J. Mathar, May 23 2006, edited by M. F. Hasler, Apr 23 2015
(PARI) A007954(n)=prod(i=1, #n=Vecsmall(Str(n)), n[i]-48) \\ (...eval(Vec(...)), n[i]) is about 50% slower; (...digits(n)...) about 6% slower. \\ M. F. Hasler, Dec 06 2009
(PARI) a(n)=if(n, factorback(digits(n)), 0) \\ Charles R Greathouse IV, Apr 14 2020
(Haskell)
a007954 n | n < 10 = n
| otherwise = m * a007954 n' where (n', m) = divMod n 10
-- Reinhard Zumkeller, Oct 26 2012, Mar 14 2011
(Magma) [0] cat [&*Intseq(n): n in [1..110]]; // Vincenzo Librandi, Jan 03 2020
(Scala) (0 to 99).map(_.toString.toCharArray.map(_ - 48).scanRight(1)(_ * _).head) // Alonso del Arte, Apr 14 2020
(Python)
from math import prod
def a(n): return prod(map(int, str(n)))
print([a(n) for n in range(108)]) # Michael S. Branicky, Jan 16 2022
CROSSREFS
Cf. A031347 (different from A035930), A007953, A007602, A010888, A093811, A008683, A000012, A061076 (partial sums), A230099.
Cf. A051802 (ignoring zeros).
KEYWORD
nonn,base,easy,nice,hear
AUTHOR
R. Muller
EXTENSIONS
Error in term 25 corrected, Nov 15 1995
STATUS
approved

Search completed in 0.202 seconds