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.

A318874 Number of divisors d of n for which 2*phi(d) > d.

This page as a plain text file.
%I A318874 #14 Jul 08 2024 10:40:54
%S A318874 1,1,2,1,2,2,2,1,3,2,2,2,2,2,4,1,2,3,2,2,4,2,2,2,3,2,4,2,2,4,2,1,4,2,
%T A318874 4,3,2,2,4,2,2,4,2,2,6,2,2,2,3,3,4,2,2,4,4,2,4,2,2,4,2,2,6,1,4,4,2,2,
%U A318874 4,4,2,3,2,2,6,2,4,4,2,2,5,2,2,4,4,2,4,2,2,6,4,2,4,2,4,2,2,3,6,3,2,4,2,2,7
%N A318874 Number of divisors d of n for which 2*phi(d) > d.
%H A318874 Antti Karttunen, <a href="/A318874/b318874.txt">Table of n, a(n) for n = 1..65537</a>
%F A318874 a(n) = Sum_{d|n} [A083254(d) > 0].
%F A318874 For all n >= 1, a(n) + A318875(n) + A007814(n) = A000005(n).
%e A318874 n = 105 has eight divisors: [1, 3, 5, 7, 15, 21, 35, 105]. When A083254 is applied to them, we obtain [1, 1, 3, 5, 1, 3, 13, -9], and seven of these numbers are positive, thus a(105) = 7.
%p A318874 A318874 := n -> nops(select(d -> (2*numtheory:-phi(d)) > d, divisors(n))):
%p A318874 seq(A318874(n), n=1..99); # _Peter Luschny_, Sep 05 2018
%t A318874 A318874[n_] := DivisorSum[n, 1 &, 2*EulerPhi[#] > # &];
%t A318874 Array[A318874, 100] (* _Paolo Xausa_, Jul 08 2024 *)
%o A318874 (PARI) A318874(n) = sumdiv(n,d,(2*eulerphi(d))>d);
%Y A318874 Cf. A000010, A083254, A318875, A318876, A318878.
%Y A318874 Differs from A001227 for the first time at n=105, where a(105) = 7, while A001227(105) = 8.
%K A318874 nonn
%O A318874 1,3
%A A318874 _Antti Karttunen_, Sep 05 2018