cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A057246 s=0; d is divisor of n [here d <= n/d]; if gcd(d,n/d)=1 or gcd(d,n/d)=d then s=s+d+(n/d); [if d=n/d then s=s+d]: The sequence contains composite n for which s = 2*n.

This page as a plain text file.
%I A057246 #24 Jan 09 2024 12:04:00
%S A057246 6,28,6966,15066
%N A057246 s=0; d is divisor of n [here d <= n/d]; if gcd(d,n/d)=1 or gcd(d,n/d)=d then s=s+d+(n/d); [if d=n/d then s=s+d]: The sequence contains composite n for which s = 2*n.
%C A057246 s(n) is a vaguely unitary analog of A060866. - _R. J. Mathar_, Oct 24 2011
%C A057246 No more terms up to 10^9. - _Michel Marcus_, Feb 24 2016
%e A057246 a(2)=28, gcd(1,28)=gcd(4,28/4)=1, gcd(2,28/2)=2, 1+28+4+7+2+14=56. 56-28=28.
%t A057246 f[ n_Integer ] := (ds = Divisors[ n ]; sq = N[ Sqrt[ n ] ]; l = 1; While[ ds[[ l ] ] <= sq, l++ ]; l = l - 1; ds = Take[ ds, l ]; s = 1; k = 2; While[ k <= l, If[ GCD[ ds[[ k ] ], n/ds[[ k ] ] ] == 1 || GCD[ ds[[ k ] ], n/ds[[ k ] ] ] == ds[[ k ] ], s = s + ds[[ k ] ] + n/ds[[ k ] ] ]; k++ ]; If[ ds[[ -1 ] ] == n/ds[[ -1 ] ], s = s - d ]; s) Do[ If[ ! PrimeQ[ n ] && f[ n ] == n, Print[ n ] ], {n, 2, 33429000} ] (* _Robert G. Wilson v_, Nov 09 2000 *)
%o A057246 (PARI) is(n)=my(s,g);fordiv(n,d,if(d^2<n&&((g=gcd(d,n/d))==1||g==d),s+=d+n/d));g=sqrtint(n);if(n==g^2,s+=g);s==n+n \\ _Charles R Greathouse IV_, Oct 23 2011
%K A057246 more,nonn
%O A057246 1,1
%A A057246 _Naohiro Nomoto_, Sep 21 2000