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.

A338930 Numbers k such that Sum_{d | k} (d^2 mod k) is prime.

This page as a plain text file.
%I A338930 #16 Dec 31 2021 11:50:57
%S A338930 8,16,18,21,39,45,55,57,93,98,99,100,111,119,129,144,153,162,183,203,
%T A338930 205,219,231,237,245,261,273,291,309,341,355,377,381,413,417,429,471,
%U A338930 481,484,489,505,511,513,517,543,583,603,609,629,637,639,651,655,669,676,687,689,697,707,722,723,731
%N A338930 Numbers k such that Sum_{d | k} (d^2 mod k) is prime.
%C A338930 Terms that are even are in A028982.
%H A338930 Robert Israel, <a href="/A338930/b338930.txt">Table of n, a(n) for n = 1..10000</a>
%e A338930 a(3) = 18 is in the sequence because Sum_{d|18} (d^2 mod 18) =  (1^2 mod 18) + (2^2 mod 18) + (3^2 mod 18) + (6^2 mod 18) + (9^2 mod 18) + (18^2 mod 18) = 1 + 4 + 9 + 0 + 9 + 0 = 23 is prime.
%p A338930 filter:= proc(n) local t;
%p A338930   isprime(add(t^2 mod n, t = numtheory:-divisors(n)))
%p A338930 end proc:
%p A338930 select(filter, [$1..1000]);
%t A338930 Select[Range[800],PrimeQ[Total[PowerMod[Divisors[#],2,#]]]&] (* _Harvey P. Dale_, Dec 31 2021 *)
%o A338930 (PARI) isok(m) = isprime(sumdiv(m, d, lift(Mod(d, m)^2))); \\ _Michel Marcus_, Nov 16 2020
%Y A338930 Cf. A028982.
%K A338930 nonn
%O A338930 1,1
%A A338930 _J. M. Bergot_ and _Robert Israel_, Nov 16 2020