login
This site is supported by donations to The OEIS Foundation.

 

Logo

Thanks to everyone who made a donation during our annual appeal!
To see the list of donors, or make a donation, see the OEIS Foundation home page.

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A048050 Chowla's function: sum of divisors of n except 1 and n. 73
0, 0, 0, 2, 0, 5, 0, 6, 3, 7, 0, 15, 0, 9, 8, 14, 0, 20, 0, 21, 10, 13, 0, 35, 5, 15, 12, 27, 0, 41, 0, 30, 14, 19, 12, 54, 0, 21, 16, 49, 0, 53, 0, 39, 32, 25, 0, 75, 7, 42, 20, 45, 0, 65, 16, 63, 22, 31, 0, 107, 0, 33, 40, 62, 18, 77, 0, 57, 26, 73, 0, 122, 0, 39, 48, 63, 18, 89 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,4

COMMENTS

a(n) = 0 if and only if n is a noncomposite number (Cf. A008578). - Omar E. Pol, Jul 31 2012

If n is semiprime, a(n) = A008472(n). - Wesley Ivan Hurt, Aug 22 2013

If n = p*q where p and q are distinct primes then a(n) = p+q.

If k,m > 1 are coprime, then a(k*m) = a(k)*a(m) + (m+1)*a(k) + (k+1)*a(m) + k + m. - Robert Israel, Apr 28 2015

LINKS

T. D. Noe, Table of n, a(n) for n = 1..10000

M. Lal and A. Forbes, A note on Chowla's function, Math. Comp., 25 (1971), 923-925.

FORMULA

a(n) = A000203(n) - A065475(n).

a(n) = A001065(n)-1, n>1.

For n>1: a(n) = sum(A027750(n,k): k=2..A000005(n)-1). - Reinhard Zumkeller, Feb 09 2013

a(n) = A000203(n)-n-1, n>1. - Wesley Ivan Hurt, Aug 22 2013

G.f.: Sum_{k>=2} k*x^(2*k)/(1 - x^k). - Ilya Gutkovskiy, Jan 22 2017

EXAMPLE

Divisors of 20 are 1,2,4,5,10,20, so a(20)=2+4+5+10=21.

MAPLE

A048050 := proc(n) if n > 1 then numtheory[sigma](n)-1-n ; else 0; end if; end proc:

MATHEMATICA

f[n_]:=Plus@@Divisors[n]-n-1; Table[f[n], {n, 100}] (*Vladimir Joseph Stephan Orlovsky, Sep 13 2009*)

Join[{0}, DivisorSigma[1, #]-#-1&/@Range[2, 80]] (* Harvey P. Dale, Feb 25 2015 *)

PROG

(MAGMA) A048050:=func< n | n eq 1 or IsPrime(n) select 0 else &+[ a: a in Divisors(n) | a ne 1 and a ne n ] >; [ A048050(n): n in [1..100] ]; // Klaus Brockhaus, Mar 04 2011

(PARI) a(n)=if(n>1, sigma(n)-n-1, 0) \\ Charles R Greathouse IV, Nov 20 2012

(Haskell)

a048050 1 = 0

a048050 n = (subtract 1) $ sum $ a027751_row n

-- Reinhard Zumkeller, Feb 09 2013

(Python)

from sympy import divisors

def a(n): return sum(divisors(n)[1:-1]) # Indranil Ghosh, Apr 26 2017

CROSSREFS

Cf. A000203, A001065, A000593, A002954, A048995, A007956, A048671, A182936.

Cf. A057533, A005276, A027751.

Sequence in context: A104755 A242690 A054013 * A078153 A104035 A196409

Adjacent sequences:  A048047 A048048 A048049 * A048051 A048052 A048053

KEYWORD

nonn,nice,easy

AUTHOR

N. J. A. Sloane

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified January 17 19:58 EST 2019. Contains 319251 sequences. (Running on oeis4.)