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-2 of 2 results.

A260581 Numbers n for which d(n+d(n)) > d(n), where d(n) is the number of divisors of n.

Original entry on oeis.org

1, 2, 7, 8, 9, 13, 14, 18, 19, 23, 25, 26, 31, 37, 38, 40, 43, 46, 47, 49, 50, 53, 61, 62, 67, 73, 74, 77, 79, 80, 83, 86, 88, 89, 94, 95, 97, 98, 99, 103, 104, 106, 108, 109, 113, 121, 122, 124, 127, 131, 132, 134, 136, 139, 143, 146, 148, 151, 152, 154, 156
Offset: 1

Views

Author

Vladimir Shevelev, Jul 29 2015

Keywords

Comments

Complement to the union of A175304 and A260577. All primes and their squares, except for 4 and the smaller members of pairs of twin primes (A001359), are in the sequence. If odd prime p is not the smaller member of a twin pair, then 2*p is in the sequence; if for prime p, 2*p+3 is neither prime nor square of prime, then 4*p is in the sequence; for prime p>7, 8*p is in the sequence; for every prime p, 2*p^2 is always in the sequence.

Examples

			8 is in the sequence since d(8+d(8)) = d(12)= 6 > d(8) = 4.
		

Crossrefs

Programs

  • Mathematica
    Select[Range@156,DivisorSigma[0,#+DivisorSigma[0,#]]>DivisorSigma[0,#]&] (* Ivan N. Ianakiev, Aug 13 2015 *)
  • PARI
    first(m)=my(v=vector(m),r=1);for(i=1,m,while(!(numdiv(r+numdiv(r)) > numdiv(r)),r++);v[i]=r;r++;);v; \\ Anders Hellström, Aug 16 2015
    
  • Perl
    use ntheory ":all"; my @A = grep { my $d=scalar(divisors($)); scalar(divisors($+$d)) > $d; } 1..100; say "@A"; # Dana Jacobsen, Apr 28 2017

A348337 For n >= 1; x = n, then iterate x --> x + d(x) until d(x + d(x)) >= d(x). a(n) gives the number of iteration steps where d(i) is the number of divisors of i, A000005(i).

Original entry on oeis.org

3, 2, 7, 1, 6, 5, 5, 4, 4, 4, 3, 3, 2, 3, 1, 1, 3, 2, 2, 1, 1, 3, 3, 1, 2, 2, 1, 1, 3, 1, 2, 1, 1, 3, 2, 1, 2, 2, 1, 2, 3, 1, 2, 3, 1, 3, 3, 1, 2, 2, 2, 1, 2, 1, 1, 1, 1, 3, 3, 6, 2, 2, 1, 1, 2, 1, 2, 1, 1, 2, 3, 5, 2, 2, 1, 1, 2, 1, 2, 2, 1, 3, 2, 4, 1, 2, 5, 4, 5, 1, 4, 4, 1, 4, 3, 3, 3, 3, 2, 1
Offset: 1

Views

Author

Ctibor O. Zizka, Oct 13 2021

Keywords

Comments

a(n) = 1 for n from A260577.

Examples

			n = 1; x(1) = 1 + d(1) = 2, d(1 + d(1)) >= d(1) thus x(2) = 2 + d(2) = 4, d(2 + d(2)) >= d(2) thus x(3) = 4 + d(4) = 7, d(4 + d(4)) < d(4), stop. a(1) = 3.
		

Crossrefs

Programs

  • Mathematica
    d[n_] := DivisorSigma[0, n]; x[n_] := n + d[n]; a[n_] := Length@ NestWhileList[x, n, d[#] <= d[x[#]] &]; Array[a, 100] (* Amiram Eldar, Oct 15 2021 *)
Showing 1-2 of 2 results.