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.

A195150 Number of divisors d of n such that d-1 does not divide n.

Original entry on oeis.org

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

Views

Author

Omar E. Pol, Sep 19 2011

Keywords

Comments

Define "subdivisor" of n to be the positive integer b such that b = d - 1, if d divides n and b does not divide n. For the list of subdivisors of n see A195153.
First occurrence of k is given in A173569. - Robert G. Wilson v, Sep 23 2011

Examples

			a(24) = 4 since the divisors of 24 are 1,2,3,4,6,8,12,24, so the subdivisors of 24 are 5,7,11,23 because 6-1 = 5, 8-1 = 7, 12-1 = 11 and 24-1 = 23. Note that the positive integers 1,2,3 are not subdivisors of 24 because they are divisors of 24.
		

Crossrefs

Programs

  • Haskell
    a195150 n = length [d | d <- [3..n], mod n d == 0, mod n (d-1) /= 0]
    -- Reinhard Zumkeller, Sep 23 2011
  • Mathematica
    f[n_] := Module[{d = Divisors[n]}, Length[Select[Rest[d-1], Mod[n, #] > 0 &]]]; Table[f[n], {n, 100}] (* T. D. Noe, Sep 22 2011 *)

Formula

a(n) = A137921(n) - 1. - Robert G. Wilson v, Sep 23 2001
Sum_{k=1..n} a(k) ~ n * (log(n) + 2*gamma - 3), where gamma is Euler's constant (A001620). - Amiram Eldar, Jan 18 2024

A195155 Number of divisors d of n such that d-1 also divides n or d-1 = 0.

Original entry on oeis.org

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

Views

Author

Omar E. Pol, Sep 19 2011

Keywords

Comments

First differs from A055874 at a(20).

Crossrefs

Programs

  • Maple
    with(numtheory):
    a:= n-> add(`if`(d=1 or irem(n, d-1)=0, 1, 0), d=divisors(n)):
    seq(a(n), n=1..200);  # Alois P. Heinz, Oct 17 2011
  • Mathematica
    d1[n_]:=Module[{d=Rest[Divisors[n]]},Count[d,?(Divisible[n,#-1]&)]+1]; Array[d1, 90] (* _Harvey P. Dale, Oct 31 2013 *)
  • Python
    from itertools import pairwise
    from sympy import divisors
    def A195155(n): return 1 if n&1 else 1+sum(1 for a, b in pairwise(divisors(n)) if a+1==b) # Chai Wah Wu, Jun 09 2025

Formula

a(n) = A000005(n) - A195150(n).
a(n) = 1 + A129308(n).
a(2n-1) = 1; a(2n) = 1 + A007862(n).
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = 2. - Amiram Eldar, Dec 31 2023
a(n) <= A038548(n) <= A000005(n). - Charles R Greathouse IV, Jun 09 2025
Showing 1-2 of 2 results.