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

A135437 Primes with a twin Carmichael number: primes p such that p-2 or p+2 are Carmichael numbers.

Original entry on oeis.org

563, 1103, 2467, 2819, 6599, 29339, 41039, 52631, 62743, 172079, 188459, 278543, 340559, 488879, 656599, 656603, 670031, 1033667, 1909003, 2100899, 3146219, 5048999, 6049679, 8719307, 10024559, 10402559, 10877579, 11119103, 12261059, 14913989, 15247619
Offset: 1

Views

Author

Pierre CAMI, Dec 14 2007, corrected Jun 22 2008; Sep 17 2008

Keywords

Examples

			563 is in the sequence since it is a prime number, and 563 - 2 = 561 is a Carmichael number.
1103 is in the sequence since it is a prime number, and 1103 + 2 = 1105 is a Carmichael number.
		

Crossrefs

Programs

  • Mathematica
    s = {}; carmichaelQ[n_] := CompositeQ[n] && Divisible[n - 1, CarmichaelLambda[n]]; Do[If[carmichaelQ[n], If[PrimeQ[n - 2], AppendTo[s, n - 2]]; If[PrimeQ[n + 2], AppendTo[s, n + 2]]], {n, 10^6}]; s (* Amiram Eldar, Jul 07 2019 *)

A290692 Carmichael numbers of the form p - 2 where p is a prime number.

Original entry on oeis.org

561, 2465, 656601, 1909001, 174352641, 230996949, 275283401, 939947009, 1534274841, 3264820001, 5860426881, 6025532241, 25536531021, 36709177121, 53388707681, 54519328481, 56222911361, 101536702401, 105528976961, 180481509681, 196866607601, 239862350001, 329245587161, 347469383801, 347511324161
Offset: 1

Views

Author

Altug Alkan, Aug 09 2017

Keywords

Comments

Rotkiewicz mentioned the first six terms of this sequence at the end of page 59 of his article (Links section). But his list includes 2821 and 46657 (2823 = 3 * 941 and 46659 = 3 * 103 * 151), which should not be there.
Carmichael numbers of the form p + 2 where p is a prime number are 1105, 2821, 6601, 29341, 41041, 52633, ... (see also A272754 for corresponding prime numbers).

Crossrefs

Programs

  • Maple
    # Using data file from Richard Pinch
    infile:= "carmichael-16": Res:= NULL;
    do
      S:= readline(infile);
      if S = 0 then break fi;
      L:= sscanf(S,"%d");
      if nops(L) <> 1 then break fi;
      if isprime(L[1]+2) then Res:= Res, L[1]; fi
    od:
    Res; # Robert Israel, Jun 03 2019
  • Mathematica
    Cases[Range[1, 10^7, 2], n_ /; And[Mod[n, CarmichaelLambda@ n] == 1, ! PrimeQ@ n, PrimeQ[n + 2]]] (* Michael De Vlieger, Aug 09 2017, after Artur Jasinski at A002997 *)
  • PARI
    isA002997(n) = {my(f); bittest(n, 0) && !for(i=1, #f=factor(n)~, (f[2, i]==1 && n%(f[1, i]-1)==1)||return) && #f>1}
    isok(n) = isprime(n+2) && isA002997(n)

Extensions

More terms from Robert Israel, Jun 03 2019

A308086 Carmichael numbers c such that c-4, c-2 and c+2 are primes.

Original entry on oeis.org

656601, 11512252145095521, 35151891169379601, 89283676825965441, 209606994019068801, 584047819872236721, 627126355430628801, 1107574117930742001, 1152431453119654401, 2990125943388676401, 6919232969930803761
Offset: 1

Views

Author

Rick L. Shepherd, May 11 2019

Keywords

Comments

Subsequence of A287591 (Carmichael numbers that are arithmetic means of cousin primes). Calculated from Amiram Eldar's table in that sequence. The Carmichael numbers here are contained within intervals defined by prime triples of the form (p, p+2, p+6); therefore, for each term, four consecutive odd numbers are prime, prime, Carmichael number (divisible by 3), then prime. None of the terms of A287591 available so far are contained within intervals defined by prime triplets of the form (p, p+4, p+6). Is that possible? If so, is it also possible for a Carmichael number to be immediately preceded and succeeded by twin primes, i.e., to be "contained" in a prime quadruplet? (Such Carmichael numbers would necessarily be multiples of 15.)

Examples

			656601 = 3*11*101*197 is a term because 656597 and 656599 are twin primes, 656601 is a Carmichael number, and 656603 is also a prime.
		

Crossrefs

Extensions

More terms from Amiram Eldar, Jul 02 2019
Showing 1-3 of 3 results.