%I #26 Jun 18 2021 12:37:13
%S 6,14,38,42,57,65,70,93,106,114,118,138,154,158,182,186,190,205,210,
%T 217,218,222,266,277,281,285,309,326
%N Complement of A344378 in A172186.
%C Terms belong to A172186 but not to A344378. Even though a(n)*(a(n)+1)*(2*a(n)+1) is squarefree, Sum_{j=1..a(n)} j^(2k) always has a prime divisor which is smaller than 2*a(n)+3, whatever k. For the integers m such that m*(m+1)*(2*m+1) is nonsquarefree, Sum_{j=1..m} j^(2k) always has a prime divisor which is smaller than 2*m+3, whatever k, because it is divisible by any prime p such that p^2 divides m*(m+1)*(2*m+1).
%H René Gy, <a href="https://math.stackexchange.com/q/4122583/130022">When the sum of the first n consecutive even (2k>0) powers is a prime number?</a>, Math StackExchange.
%e 14 belongs to the sequence, because it is squarefree, and 1+2^(2k)+3^(2k)+4^(2k)+5^(2k)+6^(2k)+7^(2k)+8^(2k)+9^(2k)+10^(2k)+11^(2k)+12^(2k)+13^(2k)+14^(2k)is always divisible by 29 when 14 does not divide k, and when 14 divides k, it is divisible by 13 or by 7.
%t lim = 330; listq = {};
%t Do[M = (Transpose[FactorInteger[m (m + 1) (2 m + 1)]][[1]] - 1)/2;
%t L = 1; Do[L = LCM[L, j], {j, M}];
%t list = Select[Range[m-1], PrimeQ[#] && Mod[L, (# - 1)/2] == 0 &];
%t Do[If[ Mod[Quotient[m, p] - Mod[m, p], p] == 0,
%t AppendTo[listq, m]], {p, list}]
%t , {m, Select[Range[lim],
%t SquareFreeQ[# (# + 1) (2 # + 1)] &]}]; DeleteDuplicates[listq]
%Y Cf. A172186, A344378.
%K nonn,more
%O 1,1
%A _René Gy_, May 16 2021