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.

A336378 Numbers k such that gcd(k, prime(k-1) + prime(k+1)) = 1.

Original entry on oeis.org

2, 3, 7, 13, 17, 19, 23, 27, 29, 31, 37, 41, 43, 45, 47, 49, 53, 55, 59, 61, 63, 65, 67, 69, 71, 73, 77, 79, 81, 83, 85, 89, 91, 93, 95, 97, 101, 103, 107, 109, 111, 113, 117, 119, 121, 125, 127, 131, 133, 135, 137, 139, 141, 143, 145, 147, 149, 151, 157
Offset: 1

Views

Author

Clark Kimberling, Oct 06 2020

Keywords

Examples

			In the following table, p(k) = A000040(k) = prime(k).
  k    p(k)   p(k-1)+p(k+1)   gcd
  2     3          7           1
  3     5         10           1
  4     7         16           4
  5    11         20           5
  6    13         28           2
2 and 3 are in this sequence; 4 and 5 are in A336379; 3 and 5 are in A336380; 7 and 11 are in A336381.
		

Crossrefs

Programs

  • Mathematica
    p[n_] := Prime[n];
    u = Select[Range[2, 200], GCD[#, p[# - 1] + p[# + 1]] == 1 &]  (* A336378 *)
    v = Select[Range[2, 200], GCD[#, p[# - 1] + p[# + 1]] > 1 &]   (* A336379 *)
    Prime[u]  (* A336380 *)
    Prime[v]  (* A336381 *)

Extensions

Offset corrected by Mohammed Yaseen, Jul 16 2023