The OEIS is supported by the many generous donors to the OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A349680 a(n) = Sum_{k=1..n} (n-k)^c(n/k), where c(n) = 1 - ceiling(n) + floor(n). 1
 0, 1, 3, 6, 7, 14, 11, 21, 20, 28, 19, 50, 23, 42, 47, 60, 31, 81, 35, 92, 69, 70, 43, 148, 66, 84, 91, 134, 55, 190, 59, 155, 113, 112, 123, 260, 71, 126, 135, 262, 79, 274, 83, 218, 231, 154, 91, 394, 136, 251, 179, 260, 103, 358, 199, 376, 201, 196, 115, 600, 119, 210, 331 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,3 COMMENTS For all k from 1 to n, add (n-k) if k|n, otherwise add 1 (see example). LINKS Antti Karttunen, Table of n, a(n) for n = 1..20000 FORMULA a(n) = n + (n-1)*A000005(n) - A000203(n). - Chai Wah Wu, Nov 25 2021 a(p) = 2p-3 for primes p. - Wesley Ivan Hurt, Nov 28 2021 EXAMPLE a(8) = 21, since for k = 1..8, we have: (8-1) + (8-2) + 1 + (8-4) + 1 + 1 + 1 + (8-8) = 21. MATHEMATICA Table[Sum[(n - k)^(1 - Ceiling[n/k] + Floor[n/k]), {k, n}], {n, 100}] PROG (PARI) a(n) = sum(k=1, n, if (n % k, 1, n-k)); \\ Michel Marcus, Nov 25 2021 (Python) from sympy import divisor_sigma def A349680(n): return n+(n-1)*divisor_sigma(n, 0)-divisor_sigma(n, 1) # Chai Wah Wu, Nov 25 2021 CROSSREFS Cf. A000005 (tau), A000203 (sigma). Sequence in context: A245394 A137473 A303604 * A255683 A127307 A099403 Adjacent sequences:  A349677 A349678 A349679 * A349681 A349682 A349683 KEYWORD nonn AUTHOR Wesley Ivan Hurt, Nov 24 2021 STATUS approved

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

Last modified August 17 15:14 EDT 2022. Contains 356189 sequences. (Running on oeis4.)