

A157449


Difference between n and the sum of its divisors except 1 and itself.


2



2, 3, 2, 5, 1, 7, 2, 6, 3, 11, 3, 13, 5, 7, 2, 17, 2, 19, 1, 11, 9, 23, 11, 20, 11, 15, 1, 29, 11, 31, 2, 19, 15, 23, 18, 37, 17, 23, 9, 41, 11, 43, 5, 13, 21, 47, 27, 42, 8, 31, 7, 53, 11, 39, 7, 35, 27, 59, 47, 61, 29, 23, 2
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

2,1


COMMENTS

a(n) = n  k where k is the sum of the divisors of n excluding 1 and n itself. The initial value for n is 2.
Evidently a(n) = n iff n is prime (A000040). Moreover a(n) = 1 iff n is perfect (A000396).
A value of 0 indicates a quasiperfect number, although no such number is known.  Felix Fröhlich, Jul 14 2014


LINKS

F. Guidi, Table of n, a(n) for n=2,...,100001
Wikipedia, Quasiperfect number  Felix Fröhlich, Jul 14 2014


FORMULA

a(n) = (2*n+1)A000203(n).  Felix Fröhlich, Jul 14 2014


EXAMPLE

The divisors of 10 are 1, 2, 5 and 10, so a(10) = 10  (2 + 5) = 3.


MATHEMATICA

Table[2n+1DivisorSigma[1, n], {n, 70}] (* Harvey P. Dale, Jul 22 2013 *)


PROG

(PARI) for(n=2, 1e2, a=2*n+1; b=sigma(n); print1(ab, ", ")) \\ Felix Fröhlich, Jul 14 2014


CROSSREFS

Cf. A000040, A000396.
Sequence in context: A164880 A267068 A242947 * A053139 A127705 A124386
Adjacent sequences: A157446 A157447 A157448 * A157450 A157451 A157452


KEYWORD

sign


AUTHOR

Ferruccio Guidi (fguidi(AT)cs.unibo.it), Mar 01 2009


STATUS

approved



