cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-8 of 8 results.

A048691 a(n) = d(n^2), where d(k) = A000005(k) is the number of divisors of k.

Original entry on oeis.org

1, 3, 3, 5, 3, 9, 3, 7, 5, 9, 3, 15, 3, 9, 9, 9, 3, 15, 3, 15, 9, 9, 3, 21, 5, 9, 7, 15, 3, 27, 3, 11, 9, 9, 9, 25, 3, 9, 9, 21, 3, 27, 3, 15, 15, 9, 3, 27, 5, 15, 9, 15, 3, 21, 9, 21, 9, 9, 3, 45, 3, 9, 15, 13, 9, 27, 3, 15, 9, 27, 3, 35, 3, 9, 15, 15, 9, 27, 3, 27
Offset: 1

Views

Author

Keywords

Comments

Inverse Moebius transform of A034444: Sum_{d|n} 2^omega(d), where omega(n) = A001221(n) is the number of distinct primes dividing n.
Number of elements in the set {(x,y): x|n, y|n, gcd(x,y)=1}.
Number of elements in the set {(x,y): lcm(x,y)=n}.
Also gives total number of positive integral solutions (x,y), order being taken into account, to the optical or parallel resistor equation 1/x + 1/y = 1/n. Indeed, writing the latter as X*Y=N, with X=x-n, Y=y-n, N=n^2, the one-to-one correspondence between solutions (X, Y) and (x, y) is obvious, so that clearly, the solution pairs (x, y) are tau(N)=tau(n^2) in number. - Lekraj Beedassy, May 31 2002
Number of ordered pairs of positive integers (a,c) such that n^2 - ac = 0. Therefore number of quadratic equations of the form ax^2 + 2nx + c = 0 where a,n,c are positive integers and each equation has two equal (rational) roots, -n/a. (If a and c are positive integers, but, instead, the coefficient of x is odd, it is impossible for the equation to have equal roots.) - Rick L. Shepherd, Jun 19 2005
Problem A1 on the 21st Putnam competition in 1960 (see John Scholes link) asked for the number of pairs of positive integers (x,y) such that xy/(x+y) = n: the answer is a(n); for n = 4, the a(4) = 5 solutions (x,y) are (5,20), (6,12), (8,8), (12,6), (20,5). - Bernard Schott, Feb 12 2023
Numbers k such that a(k)/d(k) is an integer are in A217584 and the corresponding quotients are in A339055. - Bernard Schott, Feb 15 2023

References

  • A. M. Gleason et al., The William Lowell Putnam Mathematical Competitions, Problems & Solutions:1938-1960 Soln. to Prob. 1 1960, p. 516, MAA, 1980.
  • Ross Honsberger, More Mathematical Morsels, Morsel 43, pp. 232-3, DMA No. 10 MAA, 1991.
  • Loren C. Larson, Problem-Solving Through Problems, Prob. 3.3.7, p. 102, Springer 1983.
  • Alfred S. Posamentier and Charles T. Salkind, Challenging Problems in Algebra, Prob. 9-9 pp. 143 Dover NY, 1988.
  • D. O. Shklarsky et al., The USSR Olympiad Problem Book, Soln. to Prob. 123, pp. 28, 217-8, Dover NY.
  • Wacław Sierpiński, Elementary Theory of Numbers, pp. 71-2, Elsevier, North Holland, 1988.
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, page 91.
  • Charles W. Trigg, Mathematical Quickies, Question 194, pp. 53, 168, Dover, 1985.

Crossrefs

Partial sums give A061503.
For similar LCM sequences, see A070919, A070920, A070921.
For the earliest occurrence of 2n-1 see A016017.

Programs

Formula

a(n) = A000005(A000290(n)).
tau(n^2) = Sum_{d|n} mu(n/d)*tau(d)^2, where mu(n) = A008683(n), cf. A061391.
Multiplicative with a(p^e) = 2e+1. - Vladeta Jovovic, Jul 23 2001
Also a(n) = Sum_{d|n} (tau(d)*moebius(n/d)^2), Dirichlet convolution of A000005 and A008966. - Benoit Cloitre, Sep 08 2002
a(n) = A055205(n) + A000005(n). - Reinhard Zumkeller, Dec 08 2009
Dirichlet g.f.: (zeta(s))^3/zeta(2s). - R. J. Mathar, Feb 11 2011
a(n) = Sum_{d|n} 2^omega(d). Inverse Mobius transform of A034444. - Enrique Pérez Herrero, Apr 14 2012
G.f.: Sum_{k>=1} 2^omega(k)*x^k/(1 - x^k). - Ilya Gutkovskiy, Mar 10 2018
Sum_{k=1..n} a(k) ~ n*(6/Pi^2)*(log(n)^2/2 + log(n)*(3*gamma - 1) + 1 - 3*gamma + 3*gamma^2 - 3*gamma_1 + (2 - 6*gamma - 2*log(n))*zeta'(2)/zeta(2) + (2*zeta'(2)/zeta(2))^2 - 2*zeta''(2)/zeta(2)), where gamma is Euler's constant (A001620) and gamma_1 is the first Stieltjes constant (A082633). - Amiram Eldar, Jan 26 2023

Extensions

Additional comments from Vladeta Jovovic, Apr 29 2001

A007018 a(n) = a(n-1)^2 + a(n-1), a(0)=1.

Original entry on oeis.org

1, 2, 6, 42, 1806, 3263442, 10650056950806, 113423713055421844361000442, 12864938683278671740537145998360961546653259485195806
Offset: 0

Views

Author

Keywords

Comments

Number of ordered trees having nodes of outdegree 0,1,2 and such that all leaves are at level n. Example: a(2)=6 because, denoting by I a path of length 2 and by Y a Y-shaped tree with 3 edges, we have I, Y, I*I, I*Y, Y*I, Y*Y, where * denotes identification of the roots. - Emeric Deutsch, Oct 31 2002
Equivalently, the number of acyclic digraphs (dags) that unravel to a perfect binary tree of height n. - Nachum Dershowitz, Jul 03 2022
a(n) has at least n different prime factors. [Saidak]
Subsequence of squarefree numbers (A005117). - Reinhard Zumkeller, Nov 15 2004 [This has been questioned, see MathOverflow link. - Charles R Greathouse IV, Mar 30 2015]
For prime factors see A007996.
Curtiss shows that if the reciprocal sum of the multiset S = {x_1, x_2, ..., x_n} is 1, then max(S) <= a(n). - Charles R Greathouse IV, Feb 28 2007
The number of reduced ZBDDs for Boolean functions of n variables in which there is no zero sink. (ZBDDs are "zero-suppressed binary decision diagrams.") For example, a(2)=6 because of the 2-variable functions whose truth tables are 1000, 1010, 1011, 1100, 1110, 1111. - Don Knuth, Jun 04 2007
Using the methods of Aho and Sloane, Fibonacci Quarterly 11 (1973), 429-437, it is easy to show that a(n) is the integer just a tiny bit below the real number theta^{2^n}-1/2, where theta =~ 1.597910218 is the exponential of the rapidly convergent series Sum_{n>=0} log(1+1/a_n)/2^{n+1}. For example, theta^32 - 1/2 =~ 3263442.0000000383. - Don Knuth, Jun 04 2007 [Corrected by Darryl K. Nester, Jun 19 2017]
The next term has 209 digits. - Harvey P. Dale, Sep 07 2011
Urquhart shows that a(n) is the minimum size of a tableau refutation of the clauses of the complete binary tree of depth n, see pp. 432-434. - Charles R Greathouse IV, Jan 04 2013
For any positive a(0), the sequence a(n) = a(n-1) * (a(n-1) + 1) gives a constructive proof that there exists integers with at least n distinct prime factors, e.g. a(n). As a corollary, this gives a constructive proof of Euclid's theorem stating that there are an infinity of primes. - Daniel Forgues, Mar 03 2017
Lower bound for A100016 (with equality for the first 5 terms), where a(n)+1 is replaced by nextprime(a(n)). - M. F. Hasler, May 20 2019

References

  • R. Honsberger, Mathematical Gems III, M.A.A., 1985, p. 94.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Lower bound for A100016.
Row sums of A122888.

Programs

  • Haskell
    a007018 n = a007018_list !! n
    a007018_list = iterate a002378 1  -- Reinhard Zumkeller, Dec 18 2013
    
  • Magma
    [n eq 1 select 1 else Self(n-1)^2 + Self(n-1): n in [1..10]]; // Vincenzo Librandi, May 19 2015
    
  • Maple
    A007018 := proc(n)
        option remember;
        local aprev;
        if n = 0 then
            1;
        else
            aprev := procname(n-1) ;
            aprev*(aprev+1) ;
        end if;
    end proc: # R. J. Mathar, May 06 2016
  • Mathematica
    FoldList[#^2 + #1 &, 1, Range@ 8] (* Robert G. Wilson v, Jun 16 2011 *)
    NestList[#^2 + #&, 1, 10] (* Harvey P. Dale, Sep 07 2011 *)
  • Maxima
    a[1]:1$
    a[n]:=(a[n-1] + (a[n-1]^2))$
    A007018(n):=a[n]$
    makelist(A007018(n),n,1,10); /* Martin Ettl, Nov 08 2012 */
    
  • PARI
    a(n)=if(n>0,my(x=a(n-1));x^2+x,1) \\ Edited by M. F. Hasler, May 20 2019 and Jason Yuen, Mar 01 2025
    
  • Python
    from itertools import islice
    def A007018_gen(): # generator of terms
        a = 1
        while True:
            yield a
            a *= a+1
    A007018_list = list(islice(A007018_gen(),9)) # Chai Wah Wu, Mar 19 2024

Formula

a(n) = A000058(n)-1 = A000058(n-1)^2 - A000058(n-1) = 1/(1-Sum_{jA000058(j)) where A000058 is Sylvester's sequence. - Henry Bottomley, Jul 23 2001
a(n) = floor(c^(2^n)) where c = A077125 = 1.597910218031873178338070118157... - Benoit Cloitre, Nov 06 2002
a(1)=1, a(n) = Product_{k=1..n-1} (a(k)+1). - Benoit Cloitre, Sep 13 2003
a(n) = A139145(2^(n+1) - 1). - Reinhard Zumkeller, Apr 10 2008
If an (additional) initial 1 is inserted, a(n) = Sum_{kFranklin T. Adams-Watters, Jun 11 2009
a(n+1) = a(n)-th oblong (or promic, pronic, or heteromecic) numbers (A002378). a(n+1) = A002378(a(n)) = A002378(a(n-1)) * (A002378(a(n-1)) + 1). - Jaroslav Krizek, Sep 13 2009
a(n) = A053631(n)/2. - Martin Ettl, Nov 08 2012
Sum_{n>=0} (-1)^n/a(n) = A118227. - Amiram Eldar, Oct 29 2020
Sum_{n>=0} 1/a(n) = A371321. - Amiram Eldar, Mar 19 2024

A063647 Number of ways to write 1/n as a difference of exactly 2 unit fractions.

Original entry on oeis.org

0, 1, 1, 2, 1, 4, 1, 3, 2, 4, 1, 7, 1, 4, 4, 4, 1, 7, 1, 7, 4, 4, 1, 10, 2, 4, 3, 7, 1, 13, 1, 5, 4, 4, 4, 12, 1, 4, 4, 10, 1, 13, 1, 7, 7, 4, 1, 13, 2, 7, 4, 7, 1, 10, 4, 10, 4, 4, 1, 22, 1, 4, 7, 6, 4, 13, 1, 7, 4, 13, 1, 17, 1, 4, 7, 7, 4, 13, 1, 13, 4, 4, 1, 22, 4, 4, 4, 10, 1, 22, 4, 7, 4, 4, 4
Offset: 1

Views

Author

Henry Bottomley, Jul 23 2001

Keywords

Comments

Also number of ways to write 1/n as sum of exactly two distinct unit fractions. - Thomas L. York, Jan 11 2014
Also number of positive integers m such that 1/n + 1/m is a unit fraction. - Jon E. Schoenfield, Apr 17 2018
If 1/n = 1/b - 1/c then n = bc/(c-b) and 1/n = 1/(2n-b) + 1/(c+2n) (though it is also the case that 1/n = 1/(2n) + 1/(2n) equivalent to b = c = 0).
Also number of divisors of n^2 less than n. - Vladeta Jovovic, Aug 13 2001
Number of elements in the set {(x,y): x|n, y|n, xVladeta Jovovic, May 03 2002
Also number of positive integers of the form k*n/(k+n). - Benoit Cloitre, Jan 04 2002
This is similar to A062799, having the same first 29 terms. But they are different sequences.
If A001221(n) = omega(n) <= 2, then a(n) = A062799(n); if A001221(n) > 2, then a(n) > A062799(n). - Matthew Vandermast, Aug 25 2004
Number of r X s integer-sided rectangles such that r + s = 4n, r < s and (s - r) | (s * r). - Wesley Ivan Hurt, Apr 24 2020
Also number of integer-sided right triangles with 2n as a leg. Equivalent to the even indices of A046079. - Nathaniel C Beckman, May 14 2020; Jun 26 2020
a(n) is the number of positive integers k such that k+n divides k*n. - Thomas Ordowski, Dec 02 2024

Examples

			a(10) = 4 since 1/10 = 1/5 - 1/10 = 1/6 - 1/15 = 1/8 - 1/40 = 1/9 - 1/90.
a(12) = 7: the divisors of 12 are 1, 2, 3, 4, 6 and 12 and the decompositions are (1, 2), (1, 3), (1, 4), (1, 6), (1, 12), (2, 3), (3, 4).
		

Crossrefs

First twenty-nine terms identical to those of A062799.

Programs

  • Magma
    [(NumberOfDivisors(n^2)-1)/2 : n in [1..100]]; // Vincenzo Librandi, Apr 18 2018
  • Mathematica
    Table[(Length[Divisors[n^2]] - 1)/2, {n, 1, 100}]
    (DivisorSigma[0,Range[100]^2]-1)/2 (* Harvey P. Dale, Apr 15 2013 *)
  • PARI
    for(n=1,100,print1(sum(i=1,n^2,if((n*i)%(i+n),0,1)),","))
    
  • PARI
    a(n)=numdiv(n^2)\2 \\ Charles R Greathouse IV, Oct 03 2016
    

Formula

a(n) = (tau(n^2)-1)/2.
a(n) = A018892(n)-1. If n = (p1^a1)(p2^a2)...(pt^at), a(n) = ((2*a1+1)(2*a2+1)...(2*at+1)-1)/2.
If n is prime a(n)=1. Conjecture: (1/n)*Sum_{i=1..n} a(i) = C*log(n)*log(log(n)) + o(log(n)) with C=0.7... [The conjecture is false. See the plot and the asymptotic formula below. - Amiram Eldar, Oct 03 2024]
Bisection of A046079. - Lekraj Beedassy, Jul 09 2004
a(n) = Sum_{i=1..2*n-1} (1 - ceiling(i*(4*n-i)/(4*n-2*i)) + floor(i*(4*n-i)/(4*n-2*i))). - Wesley Ivan Hurt, Apr 24 2020
Sum_{k=1..n} a(k) ~ (n/(2*zeta(2)))*(log(n)^2/2 + log(n)*(3*gamma - 1) + 1 - 3*gamma + 3*gamma^2 - 3*gamma_1 - zeta(2) + (2 - 6*gamma - 2*log(n))*zeta'(2)/zeta(2) + (2*zeta'(2)/zeta(2))^2 - 2*zeta''(2)/zeta(2)), where gamma is Euler's constant (A001620) and gamma_1 is the first Stieltjes constant (A082633). - Amiram Eldar, Oct 03 2024

A191973 Irregular triangle read by rows: row n consists of n and the positive integers m where m-n divides m*n.

Original entry on oeis.org

1, 2, 1, 2, 3, 4, 6, 2, 3, 4, 6, 12, 2, 3, 4, 5, 6, 8, 12, 20, 4, 5, 6, 10, 30, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 15, 18, 24, 42, 6, 7, 8, 14, 56, 4, 6, 7, 8, 9, 10, 12, 16, 24, 40, 72, 6, 8, 9, 10, 12, 18, 36, 90, 5, 6, 8, 9, 10, 11, 12, 14, 15, 20, 30, 35, 60
Offset: 1

Views

Author

Nathaniel Johnston, Jun 22 2011

Keywords

Comments

The maximum term of the n-th row is n*(n+1). The minimum term of the n-th row seems to be A063428(n) if n>=2. The length of row n is A146564(n) + 1.

Examples

			The triangle begins:
1 2
1 2 3 4  6
2 3 4 6  12
2 3 4 5  6  8  12 20
4 5 6 10 30
2 3 4 5  6  7  8  9  10 12 15 18 24 42
6 7 8 14 56
...
		

Crossrefs

Cf. A162821 (row 30), A162822 (row 36), A162823 (row 42), A162824 (row 48), A162825 (row 60), A127730.

Programs

  • Maple
    for n from 1 to 10 do for m from 1 to n*(n+1) do if(n=m or m*n mod (m-n) = 0)then printf("%d, ",m): fi: od: od:

A243046 Number of solutions to k*n/(k+n) = x and k*n/(k-n) = y for integers x and y and natural number k.

Original entry on oeis.org

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

Views

Author

Derek Orr, May 29 2014

Keywords

Comments

Question: Is there any direct formula for this sequence? Cf. for example A146564. - Antti Karttunen, Feb 18 2023

Examples

			6*k/(k-6) and 6*k/(k+6) are integers for k = 3 (-6 and 2, respectively) and k = 12 (12 and 4, respectively). Thus a(6) = 2.
		

Crossrefs

Cf. A063647, A146564, A243017, A243045, A243047 (positions of 0's), A360120 (their characteristic function).

Programs

  • PARI
    A243046(n) = sum(k=1, n*(n+1), (k!=n && !((k*n)%(k+n)) && !((k*n)%(k-n)))); \\ [improved by Antti Karttunen, Feb 18 2023]

Formula

a(n) <= A063647(n), a(n) <= A146564(n). - Antti Karttunen, Feb 18 2023

A152492 a(n) = number of integers of the form (n*k)^2/(k^2 - n^2).

Original entry on oeis.org

0, 0, 1, 1, 0, 2, 0, 1, 1, 1, 0, 8, 0, 0, 4, 1, 0, 2, 0, 4, 3, 0, 0, 9, 0, 0, 1, 2, 0, 7, 0, 1, 2, 0, 1, 8, 0, 0, 1, 4, 0, 5, 0, 1, 5, 0, 0, 9, 0, 1, 1, 1, 0, 2, 1, 4, 1, 0, 0, 23, 0, 0, 3, 1, 1, 4, 0, 1, 1, 2, 0, 10, 0, 0, 4, 1, 0, 4, 0, 4, 1, 0, 0, 17, 0, 0, 1, 1, 0, 8
Offset: 1

Views

Author

Ctibor O. Zizka, Dec 06 2008

Keywords

Comments

k needs to be checked only up through n^2+1 since beyond this n^2 < (n*k)^2/(k^2 - n^2) < n^2 + 1 and thus can't be an integer. - Micah Manary, Aug 27 2022

Crossrefs

Programs

  • PARI
    a(n) = sum(k=1, n^2+1, if (k!=n, denominator((n*k)^2/(k^2 - n^2))==1)); \\ Michel Marcus, Oct 28 2022

Extensions

More terms from Micah Manary, Aug 07 2022

A152491 Numbers n such that 1/c = 1/n + 1/S(n). c, n positive integers (A000027(n)), S(n) sum of digits of n (A007953(n)).

Original entry on oeis.org

2, 4, 6, 8, 18, 72
Offset: 1

Views

Author

Ctibor O. Zizka, Dec 06 2008

Keywords

Comments

A000027(n)*A007953(n)/(A000027(n)+A007953(n))= c, c positive integer.
No further term < 10000000. - Michel Marcus, Jun 02 2013
For a given n let x be the minimal natural number such that n*x/(n+x)=c. I conjecture: from a certain n onward, x>S(n) for all n. Thus there is no other solution bigger than 72, and this sequence is finite. - Ctibor O. Zizka, Sep 13 2015
Sequence is complete. To prove it, let s denote the sum of digits of n and observe that 1/c - 1/s = 1/n is equivalent to (s-c)/(c*s) = 1/n. Hence we must have s > c and c*s >= n, otherwise the denominators cannot match. But if n is greater than, say, 1000, it is easy to see that s^2 < n and this implies c*s < n, since c < s. - Giovanni Resta, Sep 13 2015

Crossrefs

Programs

  • PARI
    lista(nn) = {for (n=1, nn, digs = Vec(Str(n)); sn = sum(i=1, #digs, eval(digs[i])); if (type(1/(1/n+1/sn)) == "t_INT", print1(n, ", ")););} \\ Michel Marcus, Jun 02 2013

A153193 a(n) is the number of integers of the form n*(n+1)*k / (k - n*(n+1)) where k is an integer >= 1.

Original entry on oeis.org

4, 13, 22, 22, 40, 40, 31, 52, 67, 40, 67, 67, 40, 121, 121, 40, 67, 67, 67, 202, 121, 40, 94, 157, 67, 94, 157, 67, 121, 121, 49, 148, 121, 121, 337, 112, 40, 121, 283, 94, 121, 121, 67, 337, 202, 40, 121, 202, 112, 202, 202, 67, 94, 283, 283, 283, 121, 40
Offset: 1

Views

Author

Ctibor O. Zizka, Dec 20 2008

Keywords

Comments

1/n - 1/(n+1) - 1/k = 1/c where c is an integer, k >= 1.

Examples

			The a(1)=4 integers of the form n*(n+1)*k/(k - n*(n+1)) = 1*(1+1)*k/(k - 1*(1+1)) = 2*k/(k-2) occur at
  k=1: 2*1/(1-2) = -2,
  k=3: 2*3/(3-2) =  6,
  k=4: 2*4/(4-2) =  4, and
  k=6: 2*6/(6-2) =  3.
		

Crossrefs

Programs

  • Maple
    f:= proc(n) local D;
       D:= numtheory:-divisors((n*(n+1))^2);
       nops(D) + nops(select(`<=`,D,n*(n+1)-1))
    end proc:
    map(f, [$1..100]); # Robert Israel, Oct 21 2024

Extensions

a(13)-a(58) from Jon E. Schoenfield, Mar 15 2022
Showing 1-8 of 8 results.