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.

Showing 1-1 of 1 results.

A289257 Terms k of A006521 such that 2*k is a term of A124240.

Original entry on oeis.org

1, 3, 9, 27, 81, 171, 243, 513, 729, 1539, 2187, 3249, 4617, 6561, 9747, 13203, 13851, 19683, 29241, 39609, 41553, 59049, 61731, 87723, 118827, 124659, 177147, 185193, 250857, 263169, 356481, 373977, 531441, 555579, 752571, 789507, 1063611, 1069443, 1121931, 1172889, 1594323, 1666737
Offset: 1

Views

Author

Michel Marcus, Jun 29 2017

Keywords

Comments

Novák numbers n that are 2n Novák-Carmichael. See Kalmynin link.

Crossrefs

Programs

  • Mathematica
    Reap[Do[If[PowerMod[2, n, n]+1 == n && Divisible[2n, CarmichaelLambda[2n]], Print[n]; Sow[n]], {n, 2 10^6}]][[2, 1]] (* Jean-François Alcover, Sep 25 2018 *)
  • PARI
    isnov(n) = Mod(2, n)^n==-1; \\ A006521
    isnovcar(n) = n%lcm(znstar(n)[2])==0; \\ A124240
    isok(n) = isnov(n) && isnovcar(2*n);
    
  • Python
    from itertools import count, islice
    from sympy.ntheory.factor_ import reduced_totient
    def A289257gen(): return filter(lambda n:2*n % reduced_totient(2*n) == 0 and pow(2,n,n)==n-1, count(1))
    A289257_list = list(islice(A289257gen(),20)) # Chai Wah Wu, Dec 11 2021
Showing 1-1 of 1 results.