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.

A137924 a(n) = the largest divisor of A002808(n) that is coprime to n. (A002808(n) = the n-th composite.)

Original entry on oeis.org

4, 3, 8, 9, 2, 1, 2, 15, 16, 9, 20, 7, 22, 3, 1, 13, 27, 7, 30, 1, 11, 17, 35, 1, 38, 3, 40, 3, 44, 1, 46, 3, 49, 25, 51, 13, 54, 55, 56, 57, 58, 5, 62, 63, 64, 65, 66, 17, 69, 7, 8, 37, 75, 19, 7, 39, 80, 81, 82, 7, 85, 43, 29, 11, 18, 91, 92, 93, 94, 19, 96, 49, 99, 25, 34, 13, 15, 53
Offset: 1

Views

Author

Leroy Quet, Feb 23 2008

Keywords

Comments

a(n) = A002808(n) for n in A073258. - Robert Israel, Dec 20 2023

Examples

			The 12th composite is 21. The divisors of 21 are 1,3,7,21. The divisors of 21 that are coprime to 12 are 1 and 7. 7 is the largest of these; so a(12) = 7.
		

Crossrefs

Programs

  • Maple
    A002808 := proc(n) option remember ; local a; if n = 1 then 4; else for a from A002808(n-1)+1 do if not isprime(a) then RETURN(a) ; fi ; od: fi ; end: A137924 := proc(n) local dvs,d ; dvs := sort(convert(numtheory[divisors](A002808(n)),list),`>`) ; for d in dvs do if gcd(d,n) = 1 then RETURN(d) ; fi ; od: end: seq(A137924(n),n=1..80) ; # R. J. Mathar, Mar 03 2008
  • Mathematica
    a = {}; c = 4; For[n = 1, n < 80, n++, AppendTo[a, Select[Divisors[c], GCD[ #, n] == 1 &][[ -1]]]; If[PrimeQ[c + 1], c = c + 2, c = c + 1]]; a (* Stefan Steinerberger, Mar 09 2008 *)

Extensions

More terms from R. J. Mathar and Stefan Steinerberger, Mar 03 2008

A073257 Smallest k such that gcd(c(k),k) = gcd(A002808(k),k) = A064814(k) = n.

Original entry on oeis.org

1, 2, 12, 20, 5, 6, 7, 64, 234, 50, 55, 24, 26, 28, 30, 32, 629, 1008, 209, 220, 231, 1012, 506, 168, 425, 182, 189, 2716, 2204, 1080, 93, 96, 99, 2176, 105, 4428, 1369, 5586, 1755, 1800, 6109, 2478, 2279, 3916, 5760, 644, 4606, 1920, 1960, 10250, 2040, 2444
Offset: 1

Views

Author

Labos Elemer, Jul 22 2002

Keywords

Examples

			50th composite is 70, gcd(50,70)=10 appears first here, a(10)=50.
		

Crossrefs

Programs

  • Mathematica
    f[x_] := FixedPoint[x+PrimePi[ # ]+1&, x] t=Table[0, {100}]; Do[s=GCD[f[n], n]; If[s<101&&t[[s]]==0, t[[s]]=n], {n, 1, 100000}]; t

Formula

a(n) = min{x: gcd(c(x), x)=n}, where c(x) is the x-th composite number.

A334880 Numbers k such that gcd(k, k-th composite number) > 1.

Original entry on oeis.org

2, 5, 6, 7, 10, 12, 14, 15, 16, 18, 20, 21, 22, 24, 26, 28, 30, 32, 34, 36, 42, 48, 50, 51, 52, 54, 55, 56, 60, 62, 63, 64, 65, 70, 72, 74, 75, 76, 77, 78, 80, 81, 82, 93, 96, 98, 99, 102, 104, 105, 110, 112, 114, 120, 122, 124, 126, 128, 130, 132, 138, 148
Offset: 1

Views

Author

Clark Kimberling, Jul 17 2020

Keywords

Examples

			In the following table, c(k) = A002808(k) = k-th composite number.
  k     c(k)   gcd(k, c(k))
  1      4         1
  2      6         2
  3      8         1
  4      9         1
  5     10         5
  6     12         6
2, 5, 6 are in this sequence, and 1,3,4 are in A073258.
		

Crossrefs

Cf. A002808, A064814, A073258 (complement), A336323.

Programs

  • Mathematica
    c = Select[Range[2, 150], ! PrimeQ[#] &]; (* A002808 *)
    Select[Range[Length[c]], GCD[c[[#]], #] > 1 &]  (* A334880 *)
    Module[{nn=200,cmps,len},cmps=Select[Range[nn],CompositeQ];len=Length[ cmps];Select[Thread[{Range[len],cmps}],GCD@@#>1&]][[All,1]] (* Harvey P. Dale, Sep 20 2020 *)
  • PARI
    lista(nn) = {my(n=0, list=List()); forcomposite (c=1, nn, n++; if (gcd(n, c) > 1, listput(list, n))); Vec(list);} \\ Michel Marcus, Jul 19 2020
Showing 1-3 of 3 results.