Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #27 Mar 29 2019 03:03:39
%S 0,1,3,5,7,10,11,11,20,15,23,30,34,38,43,48,52,43,60,53,69,41,59,82,
%T 80,90,95,71,106,83,65,110,130,135,134,145,146,146,157,165,150,177,
%U 174,179,159,179,209,202,210,173,224,200,125,238,238,254
%N Difference between average of two consecutive odd primes and the sum of all prime factors of the average.
%C Sequence starts with the 2nd prime because the average of the first two primes is not an integer.
%H Conner L. Delahanty, <a href="/A251364/b251364.txt">Table of n, a(n) for n = 1..20000</a>
%F a(n) = ((prime(n+1) + prime(n+2))/2) - (sopfr((prime(n+1) + prime(n+2))/2)), where sopfr is A001414, the sum of primes dividing n (with repetition).
%e For n = 1, the average of prime(2) and prime(3) is 4. The prime factors of 4 are 2 and 2. 4 - (2 + 2) = 0.
%e For n = 2, the average of prime(3) and prime(4) is 6. The prime factors of 6 are 2 and 3. 6 - (2 + 3) = 1.
%e For n = 3, the average of prime(4) and prime(5) is 9. The prime factors of 9 are 3 and 3. 9 - (3 + 3) = 3.
%e For n = 4, the average of prime(5) and prime(6) is 12. The prime factors of 12 are 2, 2, and 3. 12 - (2 + 2 + 3) = 5.
%t f[{a_, b_}] := Table[a, {b}]; g[n_] := Block[{d = (Prime[n + 1] + Prime[n])/2}, d - Plus @@ Flatten[f /@ FactorInteger@ d]]; Table[g@ n, {n, 2, 57}] (* _Michael De Vlieger_, Mar 25 2015 *)
%Y Cf. A000040 (primes), A001414 (sopfr).
%K nonn,easy
%O 1,3
%A _Conner L. Delahanty_, Mar 20 2015