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!)
A225867 a(n) = max_{2<=k<=(n-2)/2} sum_{d>1: d|n+k, k|n+d}1. 7

%I #21 Nov 25 2014 16:38:14

%S 3,2,2,3,4,1,3,3,4,4,3,2,4,3,4,4,6,2,3,4,4,4,4,2,5,3,3,6,6,4,4,4,6,4,

%T 4,2,4,5,6,5,8,2,3,4,4,6,4,3,6,6,4,6,8,2,5,5,6,4,4,4,6,4,6,8,9,2,4,5,

%U 4,5,6,6,8,4,4,6,8,3,4,6,6,8,6,3,5,4,8,6,10

%N a(n) = max_{2<=k<=(n-2)/2} sum_{d>1: d|n+k, k|n+d}1.

%H Peter J. C. Moses, <a href="/A225867/b225867.txt">Table of n, a(n) for n = 6..10005</a>

%p A225867 := proc(n)

%p local a,k,nd ;

%p a := 0 ;

%p for k from 2 to n/2-1 do

%p nd := 0 ;

%p for d in numtheory[divisors](n+k) minus {1} do

%p if modp(n+d,k) = 0 then

%p nd := nd+1;

%p end if;

%p end do:

%p a := max(a,nd) ;

%p end do:

%p a ;

%p end proc: # _R. J. Mathar_, Jul 04 2013

%t Table[Max[Map[Count[(n+Rest[Divisors[n+#]])/#,_Integer]&,Range[2,Floor[(n-2)/2]]]],{n,6,105}] (* _Peter J. C. Moses_, Jun 27 2013 *)

%o (PARI) a(n)=my(t); for(k=2,n\2-1, t=max(sumdiv(n+k,d,(n+d)%k==0 && d>1),t)); t \\ _Charles R Greathouse IV_, Nov 25 2014

%K nonn

%O 6,1

%A _Vladimir Shevelev_, May 18 2013

%E Extended from a(14) by _Peter J. C. Moses_, May 18 2013

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 April 24 07:22 EDT 2024. Contains 371922 sequences. (Running on oeis4.)