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.

Previous Showing 21-23 of 23 results.

A343158 a(n) is the smallest m such that A343156(m) = n, or -1 if no such m exists.

Original entry on oeis.org

2, 4, 10, 35, 15, 34, 190, 290, 303, 395, 130, 465, 553, 265, 195, 663, 218, 582, 481, 858, 714, 418, 345, 530, 382, 1771, 1207, 2098, 3890, 1426, 2090, 4834, 4618, 627, 2321, 2163, 326, 866, 3302, 1298, 3886, 3094, 1086, 6130, 4807, 3646, 5181, 905, 3945, 5753
Offset: 0

Views

Author

N. J. A. Sloane, Apr 07 2021

Keywords

Examples

			2 takes 0 steps to reach a prime, so a(0) = 2.
10 -> 25 -> 5 takes 2 steps to reach a prime (and no smaller number takes that many steps), so a(2) = 10.
35 -> 57 -> 319 -> 1129 takes 3 steps to reach a prime (and no smaller number takes that many steps), so a(3) = 35.
		

References

  • Eric Angelini, W. Edwin Clark, Hans Havermann, Frank Stevenson, Allan C. Wechsler, and others, Postings to Math Fun mailing list, April 2021.

Crossrefs

Programs

  • PARI
    is(m, n) = my(k=m); for(i=1, n, if(isprime(k), return(0), k=eval(concat(apply(t->Str(t), factor(k)[, 1]~))))); isprime(k);
    a(n) = for(m=2, oo, if(is(m, n), return(m))); \\ Jinyuan Wang, Jul 16 2022

Extensions

a(32)-a(42) from Hans Havermann, Apr 07 2021
a(43)-a(48) from Hans Havermann, Apr 08 2021
a(49) from Jinyuan Wang, Jul 16 2022

A287637 a(n) = A249125(n)/concatenation of prime factors of A249125(n).

Original entry on oeis.org

2, 4, 3, 8, 5, 9, 16, 7, 2, 32, 27, 4, 11, 25, 64, 13, 8, 81, 10, 128, 17, 49, 19, 16, 20, 256, 23, 125, 243, 32, 29, 31, 40, 512, 50, 121, 37, 64, 41, 43, 80, 1024, 729, 169, 47, 343, 100, 53, 625, 128, 59, 61, 160, 2048, 67, 289, 200, 71, 73, 79, 250, 256
Offset: 1

Views

Author

Michel Lagneau, May 28 2017

Keywords

Comments

The squares of the sequence are, in increasing order: 4, 9, 16, 25, 49, 64, 81, 100, 121, 169, 256, 289, 361, 400, 625, 729, 1024, 4096,... including the squares of the prime numbers.
The numbers p^n, p prime and n = 1, 2, 3, 4,... are in the sequence.
The twin primes (a(m), a(m+1)) of the sequence are (29, 31), (41, 43), (59, 61), (71, 73), (101, 103), (107, 109), (137, 139),...
The numbers whose prime factors are 2 and 5 (A033846) are in the sequence.

Examples

			a(9)=2 because A249125(9) = 50 and the concatenation of the prime factors of 50 is 25. Hence, 50/25 = 2.
		

Crossrefs

Programs

  • Maple
    with(numtheory):
    for n from 2 to 10000 do:
      if type(n,prime)=false
       then
        x:=factorset(n):n0:=nops(x):
        d:=sum('length(x[i])', 'i'=1..n0):
        l:=sum('x[i]*10^sum('length(x[j])', 'j'=i+1..n0)', 'i'=1..n0):
        z:=n/l:
         if floor(z)=z
          then
          printf(`%d, `,z):
          else
         fi:
       fi:
    od:
  • Mathematica
    cf[n_] := FromDigits@ Flatten[ IntegerDigits /@ First /@ FactorInteger@n]; Reap[ Do[If[ CompositeQ[n] && IntegerQ[rz = n/cf[n]], Sow[rz]], {n, 6400}]][[2, 1]] (* Giovanni Resta, May 29 2017 *)

A342999 a(n) is always followed by the concatenation of a(n)'s distinct prime factors in increasing order. If this concatenation is already in the sequence, a(n+1) is the smallest term not yet present.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 23, 7, 8, 9, 10, 25, 11, 12, 13, 14, 27, 15, 35, 57, 319, 1129, 16, 17, 18, 19, 20, 21, 37, 22, 211, 24, 26, 213, 371, 753, 3251, 28, 29, 30, 235, 547, 31, 32, 33, 311, 34, 217, 731, 1743, 3783, 31397, 36, 38, 219, 373, 39, 313, 40, 41, 42, 237, 379, 43, 44, 45, 46, 223, 47
Offset: 1

Views

Author

Eric Angelini and Carole Dubois, Apr 02 2021

Keywords

Comments

This is a permutation of the positive terms.

Examples

			a(6) is not = 5, though the only prime factor of a(5) is precisely 5; but as 5 is already in the sequence we must take a(6) = 6, the smallest term not yet present in the sequence.
a(7) = 23 as the prime factors of a(6) = 6 are 2 and 3, which, concatenated in increasing order, give 23;
a(8) is not = 23, though the only prime factor of a(7) is precisely 23; but as 23 is already in the sequence we must take a(8) = 7, the smallest term not yet present in the sequence; etc.
		

Crossrefs

Cf. A084317 (concatenation of the prime factors of n, in increasing order), A037276 (replace n with the concatenation of its prime factors in increasing order).

Programs

  • Mathematica
    a[1]=1;a[n_]:=a[n]=(g=FromDigits@Flatten[IntegerDigits@*First/@FactorInteger@a[n-1]];If[FreeQ[k=Array[a,n-1],g],g,Min@Complement[Range@Max[k+1],k]])
    Array[a,100] (* Giorgos Kalogeropoulos, Apr 02 2021 *)
  • Python
    from sympy import primefactors
    def aupton(terms):
      alst, aset = [1, 2], {1, 2}
      while len(alst) < terms:
        an = int("".join(map(str, primefactors(alst[-1]))))
        if an in aset:
          an = 1
          while an in aset: an += 1
        alst.append(an); aset.add(an)
      return alst[:terms]
    print(aupton(100)) # Michael S. Branicky, Apr 02 2021
Previous Showing 21-23 of 23 results.