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.

A179707 Semiprimes p*q such that 2^p mod q == 2^q mod p.

Original entry on oeis.org

4, 9, 25, 49, 121, 169, 289, 341, 361, 529, 731, 841, 961, 1333, 1369, 1387, 1681, 1727, 1849, 2047, 2209, 2701, 2809, 3277, 3481, 3503, 3721, 3763, 4033, 4369, 4489, 4681, 5041, 5329, 5461, 6241, 6889, 7921, 7957, 8321, 9409, 9509, 10201, 10261, 10609, 10669, 11449, 11881
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jan 10 2011

Keywords

Comments

The square of every prime is here, as are the semiprimes in A179839.

Examples

			341 is a term because 341 = 11*31 and 2^11 mod 31 = 2^31 mod 11.
		

Crossrefs

Programs

  • Mathematica
    fQ[n_] := Block[{fi = Flatten[ Table[ First@ #, {Last@ #}] & /@ FactorInteger@ n]}, Length@ fi == 2 && PowerMod[2, fi[[2]], fi[[1]]] == PowerMod[2, fi[[1]], fi[[2]]]]; Select[ Range@ 12000, fQ]
    With[{nn=50},Take[Union[Times@@@Select[Tuples[Prime[Range[2nn]],2], PowerMod[ 2,#[[1]],#[[2]]]==PowerMod[2,#[[2]],#[[1]]]&]],nn]] (* Harvey P. Dale, Sep 03 2015 *)