login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Sums of two numbers that are both consecutive and squarefree.
1

%I #20 Feb 26 2024 01:20:10

%S 3,5,11,13,21,27,29,43,45,59,61,67,69,75,77,83,85,93,115,117,123,131,

%T 133,139,141,147,155,157,165,171,173,187,189,203,205,211,213,219,221,

%U 227,229,237,245,259,261,267,275,277,283,285,291,309,315,317,331

%N Sums of two numbers that are both consecutive and squarefree.

%C From _Robert Israel_, Nov 20 2017: (Start)

%C All terms == 3 or 5 (mod 8).

%C Odd numbers k such that (k-1)/2 and (k+1)/2 are both squarefree.

%C Intersection of 2*A005117+1 and 2*A005117-1. (End)

%C The asymptotic density of this sequence is (1/2) * Product_{p prime} (1 - 2/p^2) = A065474 / 2 = 0.161317049469... . - _Amiram Eldar_, Feb 26 2024

%H Robert Israel, <a href="/A295243/b295243.txt">Table of n, a(n) for n = 1..10000</a>

%F a(n) = 2*A007674(n) + 1. - _Amiram Eldar_, Feb 26 2024

%e a(3) = 11; 11 = 5 + 6, with 5, 6 consecutive and squarefree.

%p with(numtheory): a:=n->`if`(mobius(n)^2 = 1 and mobius(n+1)^2=1, 2*n+1, NULL): seq(a(n), n=1..300);

%t Total /@ Select[Partition[Range@ 166, 2, 1], AllTrue[#, SquareFreeQ] &] (* _Michael De Vlieger_, Nov 18 2017 *)

%o (PARI) lista(nn) = for (n=0, nn, if (issquarefree(n) && issquarefree(n+1), print1(2*n+1, ", "));); \\ _Michel Marcus_, Nov 19 2017

%Y Cf. A005117, A007674, A065474.

%K nonn

%O 1,1

%A _Wesley Ivan Hurt_, Nov 18 2017