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.

A216731 Primes p > 3 such that there is no power of 3 in the open interval (2p, 3p).

Original entry on oeis.org

5, 7, 17, 19, 23, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 367, 373, 379, 383, 389, 397, 401, 409, 419, 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503, 509
Offset: 1

Views

Author

N. J. A. Sloane, Sep 17 2012

Keywords

Comments

Is this (apart from 2) the subset of primes in A134026? - R. J. Mathar, Sep 17 2012

Programs

  • Maple
    isA216731 := proc(n)
        if isprime(n) then
            floor(log[3](2*n)) = floor(log[3](3*n)) ;
        else
            false;
        end if;
    end proc:
    for n from 2 to 250 do
        p := ithprime(n) ;
        if isA216731(p) then
            printf("%d,",p) ;
        end if;
    end do: # R. J. Mathar, Sep 17 2012
  • Mathematica
    isA216731[n_] := If[PrimeQ[n], Floor[Log[3, 2*n]] == Floor[Log[3, 3*n]], False]; Reap[For[n = 2, n <= 100, n++, p = Prime[n]; If[isA216731[p], Print[p]; Sow[p]]]][[2, 1]] (* Jean-François Alcover, Mar 06 2014, after R. J. Mathar *)

Extensions

Name corrected by Robert Israel, May 11 2025