login
A235796
2*n - 1 - sigma(n).
12
0, 0, 1, 0, 3, -1, 5, 0, 4, 1, 9, -5, 11, 3, 5, 0, 15, -4, 17, -3, 9, 7, 21, -13, 18, 9, 13, -1, 27, -13, 29, 0, 17, 13, 21, -20, 35, 15, 21, -11, 39, -13, 41, 3, 11, 19, 45, -29, 40, 6, 29, 5, 51, -13, 37, -9, 33, 25, 57, -49, 59, 27, 21, 0, 45, -13, 65, 9, 41
OFFSET
1,5
COMMENTS
Partial sums give A004125.
Also 0 together with A120444.
It appears that a(n) = 0 iff n is a power of 2.
Numbers n with a(n) = 0 are called "almost perfect", "least deficient" or "slightly defective" numbers. See A000079. - Robert Israel, Jul 22 2014
a(n) = n - 2 iff n is prime.
a(n) = -1 iff n is a perfect number.
Also the alternating row sums of A239446. - Omar E. Pol, Jul 21 2014
REFERENCES
R. K. Guy, Unsolved Problems in Number Theory, 3rd Edition, Springer, New York, 2004.
FORMULA
a(n) = A005408(n-1) - A000203(n).
a(n) = -1 - A033880(n). - Michel Marcus, Jan 27 2014
a(n) = n - 1 - A001065(n). - Omar E. Pol, Jan 29 2014
a(n) = A033879(n) - 1. - Omar E. Pol, Jan 30 2014
a(n) = 2*n - 2 - A039653(n). - Omar E. Pol, Jan 31 2014
a(n) = (-1)*A237588(n). - Omar E. Pol, Feb 23 2014
a(n) = 2*n - A088580(n). - Omar E. Pol, Mar 23 2014
EXAMPLE
. The positive The sum of
n odd numbers divisors of n. a(n)
1 1 1 0
2 3 3 0
3 5 4 1
4 7 7 0
5 9 6 3
6 11 12 -1
7 13 8 5
8 15 15 0
9 17 13 4
10 19 18 1
...
MATHEMATICA
Table[2n-1-DivisorSigma[1, n], {n, 70}] (* Harvey P. Dale, Jul 11 2014 *)
PROG
(PARI) vector(100, n, (2*n-1)-sigma(n)) \\ Colin Barker, Jan 27 2014
(Magma) [2*n-1-SumOfDivisors(n): n in [1..100]]; // Vincenzo Librandi, Feb 25 2014
KEYWORD
sign
AUTHOR
Omar E. Pol, Jan 25 2014
STATUS
approved