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

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A123327 a(n) = A000203(n) + A004125(n). 4
1, 3, 5, 8, 10, 15, 16, 23, 25, 31, 34, 45, 42, 55, 60, 67, 69, 86, 84, 103, 102, 113, 122, 145, 134, 154, 165, 180, 181, 210, 199, 230, 232, 251, 266, 289, 271, 308, 325, 348, 339, 380, 369, 412, 417, 430, 451, 498, 471, 513, 521, 552, 559, 612, 601, 640, 633 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Another definition for this sequence: Let M be the matrix defined in A111490. Sequence gives M(1,1), M(1,2) + M(2,2), M(1,3) + M(2,3) + M(3,3), etc., i.e. a(n)= Sum_{i=1..n} M(i,n).
Proof from Hartmut F. W. Hoft, Feb 02 2014 that the two definitions agree: (Start)
For all n>=1 the following simplifications hold for the partial sums of the two sequences:
sum[1..n] a(k) = sum[1..n] A000203(k) + sum[1..n] A004125(k)
= A024916(n) + sum[1..n] A004125(k)
= n^2 + sum[1..n-1] A004125(k)
= sum[1..n] A123327(k).
An inductive argument then shows that the two definitions agree.
(End)
LINKS
FORMULA
a(n) = A000290(n) - A024916(n-1), n > 1. - Omar E. Pol, Jan 29 2014
EXAMPLE
1(=1+0), 3(=3+0), 5(=4+1), 8(=7+1), 10(=6+4), 15(=12+3), 16(=8+8), etc.
PROG
(Python)
from math import isqrt
def A123327(n): return n**2+((s:=isqrt(n-1))**2*(s+1)-sum((q:=(n-1)//k)*((k<<1)+q+1) for k in range(1, s+1))>>1) # Chai Wah Wu, Oct 22 2023
CROSSREFS
Sequence in context: A088937 A295362 A162383 * A024679 A187973 A190488
KEYWORD
easy,nonn
AUTHOR
EXTENSIONS
Corrected (83 replaced by 103) by R. J. Mathar, May 21 2010
Edited by N. J. A. Sloane, Feb 02 2014, merging A162383 from Juri-Stepan Gerasimov with the present sequence. Thanks to Omar E. Pol for noticing the duplication.
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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 30 10:03 EDT 2024. Contains 375532 sequences. (Running on oeis4.)