login
a(n) = 2^(c-1) mod c^2, where c is the n-th composite number.
3

%I #14 Feb 27 2018 12:31:10

%S 8,32,0,13,12,32,156,184,0,176,288,319,464,320,341,496,40,64,212,0,

%T 301,308,9,1040,952,472,1088,1544,800,391,508,2048,1191,1312,922,2608,

%U 284,2359,1920,688,1800,3488,2668,2524,0,2291,428,144,3109,2612,1472,2888

%N a(n) = 2^(c-1) mod c^2, where c is the n-th composite number.

%C a(n) = 0 iff c is a term of A000079 > 4.

%C Composites c where a(n) = 1 could be called "Wieferich pseudoprimes". Do any such composites exist?

%C A necessary condition for c to be a "Wieferich pseudoprime" would be that it is a term of both A001567 and A270833 (see comments in A240719).

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

%p map(c -> 2&^(c-1) mod c^2, remove(isprime, [$4..1000])); # _Robert Israel_, Feb 27 2018

%t composite[n_Integer] := FixedPoint[n + PrimePi@ # + 1 &, n + PrimePi@ n + 1]; Array[With[{c = composite@ #}, Mod[2^(c - 1), c^2]] &, 52] (* _Michael De Vlieger_, Jan 31 2018, composite function by _Robert G. Wilson v_ at A066277 *)

%o (PARI) forcomposite(c=1, 200, print1(lift(Mod(2, c^2)^(c-1)), ", "))

%Y Cf. A000079, A001220, A001567, A240719, A270833, A298945, A298946.

%K nonn

%O 1,1

%A _Felix Fröhlich_, Jan 30 2018