A129493 Composite numbers k such that 3^k mod k is a power of 3.
6, 10, 12, 14, 18, 22, 24, 26, 30, 33, 34, 36, 38, 39, 46, 51, 54, 56, 57, 58, 62, 63, 66, 69, 72, 74, 78, 82, 86, 87, 90, 91, 92, 93, 94, 99, 104, 106, 108, 111, 112, 116, 117, 118, 120, 121, 122, 123, 124, 129, 132, 134, 135, 141, 142, 144, 146, 148, 154, 158, 159
Offset: 1
Examples
14 is a member of the sequence since 3^14 mod 14 = 9.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Programs
-
Magma
[k:k in [2..160]| not IsPrime(k) and not IsZero(a) and (PrimeDivisors(a) eq [3]) where a is 3^k mod k ]; // Marius A. Burtea, Dec 04 2019
-
Maple
filter:= proc(n) local k; if isprime(n) then return false fi; k:= 3 &^ n mod n; k > 1 and k = 3^padic:-ordp(k,3) end proc: select(filter, [$4..1000]); # Robert Israel, Dec 03 2019
-
Mathematica
Select[Range@ 161, IntegerQ@ Log[3, PowerMod[3, #, # ]] &]
Comments