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-2 of 2 results.

A064077 Greater of odd twin prime powers (lesser = A064076).

Original entry on oeis.org

5, 7, 9, 11, 13, 19, 25, 27, 29, 31, 43, 49, 61, 73, 81, 83, 103, 109, 127, 139, 151, 169, 181, 193, 199, 229, 241, 243, 271, 283, 313, 349, 361, 421, 433, 463, 523, 571, 601, 619, 643, 661, 729, 811, 823, 829, 841, 859, 883, 1021, 1033, 1051, 1063, 1093, 1153
Offset: 1

Views

Author

Reinhard Zumkeller, Sep 01 2001

Keywords

Comments

A006512 is a proper subsequence of this sequence (as A001359 is of A064076).

Examples

			a(16) = 83^1 and 83 - 1 = 81 = 3^4 = A064076(16); a(20) = 139^1 and 139 - 2 = 137^1 = A064077(20).
		

Crossrefs

Programs

  • Mathematica
    Select[Partition[Select[Range[1, 1200, 2], PrimePowerQ], 2, 1], Differences[#] == {2} &][[;; , 2]] (* Amiram Eldar, Mar 19 2025 *)

Formula

a(n) = A064076(n) + 2. - Amiram Eldar, Mar 19 2025

A120431 Numbers k such that k and k+2 are prime powers.

Original entry on oeis.org

1, 2, 3, 5, 7, 9, 11, 17, 23, 25, 27, 29, 41, 47, 59, 71, 79, 81, 101, 107, 125, 137, 149, 167, 179, 191, 197, 227, 239, 241, 269, 281, 311, 347, 359, 419, 431, 461, 521, 569, 599, 617, 641, 659, 727, 809, 821, 827, 839, 857, 881, 1019, 1031, 1049, 1061, 1091
Offset: 1

Views

Author

Greg Huber, Jul 13 2006

Keywords

Comments

Twin prime powers, a generalization of the twin primes. The twin primes are a subsequence.
From Daniel Forgues, Aug 17 2009: (Start)
Numbers k such that k + (0, 2) is a prime power pair.
k + (0, 2m), m >= 1, being an admissible pattern for prime pairs has high density.
k + (0, 2m-1), m >= 1, being a non-admissible pattern for prime pairs, has low density [the only possible pairs are (2^a - 2m-1, 2^a) or (2^a, 2^a + 2m-1), a >= 0.] (End)

Examples

			a(5) = 7 since the 5th pair of twin prime powers is (7,9), while the first four pairs are (1,3), (2,4), (3,5) and (5,7).
		

Crossrefs

Programs

  • Magma
    [1] cat [n: n in [2..1200] | IsPrimePower(n) and IsPrimePower(n+2)]; // Vincenzo Librandi, Nov 03 2018
  • Maple
    isppow := proc(n) local pf; pf := ifactors(n)[2]; if nops(pf) = 1 or n =1 then true; else false; fi; end; isA120431 := proc(n) RETURN (isppow(n) and isppow(n+2)); end; for n from 1 to 1500 do if isA120431(n) then printf("%d, ",n); fi; od; # R. J. Mathar, Dec 16 2006
  • Mathematica
    Join[{1}, Select[Range[1100], And@@PrimePowerQ/@{#, # + 2} &]] (* Vincenzo Librandi, Nov 03 2018 *)
  • PARI
    is(n)=if(n<4,return(n>0)); isprimepower(n) && isprimepower(n+2) \\ Charles R Greathouse IV, Apr 24 2015
    

Formula

a(n) = A064076(n-2) for n >= 3. - Georg Fischer, Nov 02 2018

Extensions

More terms from R. J. Mathar, Dec 16 2006
Showing 1-2 of 2 results.