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 11-20 of 35 results. Next

A048985 Working in base 2, replace n with the concatenation of its prime divisors in increasing order (write answer in base 10).

Original entry on oeis.org

1, 2, 3, 10, 5, 11, 7, 42, 15, 21, 11, 43, 13, 23, 29, 170, 17, 47, 19, 85, 31, 43, 23, 171, 45, 45, 63, 87, 29, 93, 31, 682, 59, 81, 47, 175, 37, 83, 61, 341, 41, 95, 43, 171, 125, 87, 47, 683, 63, 173, 113, 173, 53, 191, 91, 343, 115, 93, 59, 349, 61, 95, 127, 2730
Offset: 1

Views

Author

Keywords

Examples

			15 = 3*5 -> 11.101 -> 11101 = 29, so a(15) = 29.
		

Crossrefs

Cf. A193652, A029744 (record values and where they occur).
Cf. A027746.

Programs

  • Haskell
    -- import Data.List (unfoldr)
    a048985 = foldr (\d v -> 2 * v + d) 0 . concatMap
       (unfoldr (\x -> if x == 0 then Nothing else Just $ swap $ divMod x 2))
       . reverse . a027746_row
    -- Reinhard Zumkeller, Jul 16 2012
    
  • Mathematica
    f[n_] := FromDigits[ Flatten[ IntegerDigits[ Flatten[ Table[ #1, {#2}] & @@@ FactorInteger@n], 2]], 2]; Array[f, 64] (* Robert G. Wilson v, Jun 02 2010 *)
  • Python
    from sympy import factorint
    def a(n):
        if n == 1: return 1
        return int("".join(bin(p)[2:]*e for p, e in factorint(n).items()), 2)
    print([a(n) for n in range(1, 65)]) # Michael S. Branicky, Oct 07 2022

Extensions

More terms from Sam Alexander (pink2001x(AT)hotmail.com) and Michel ten Voorde

A248915 Composite numbers which divide the concatenation of their prime factors, with multiplicity, in descending order.

Original entry on oeis.org

378, 12467, 95823, 10715274, 13485829, 111495095, 42002916561, 176685987695
Offset: 1

Views

Author

Paolo P. Lava, Oct 16 2014

Keywords

Comments

Prime numbers are not considered because they trivially satisfy the relation.
For terms in ascending order see A259047 and StackExchange link. [Paolo P. Lava, May 30 2019]
a(9) <= 3953318131772867. - Chai Wah Wu, Apr 12 2024
a(2), the bound for a(9) above, and larger terms may be found using an extension of Andersen's algorithm to arbitrary base and ordering (see links for an implementation and another term). - Michael S. Branicky, Apr 13 2024

Examples

			Prime factors of 378 are 2,3,3,3,7; concat(7,3,3,3,2) = 73332 and 73332/378 = 194.
		

Crossrefs

Programs

  • Maple
    with(numtheory); P:=proc(q) local a,b,c,d,j,k,n;
    for n from 1 to q do if not isprime(n) then a:=ifactors(n)[2]; b:=[]; d:=0;
    for k from 1 to nops(a) do b:=[op(b),a[k][1]]; od; b:=sort(b);
    for k from nops(a) by -1 to 1 do c:=1; while not b[k]=a[c][1] do c:=c+1; od;
    for j from 1 to a[c][2] do d:=10^(ilog10(b[k])+1)*d+b[k]; od; od;
    if type(d/n,integer) then print(n); fi;
    fi; od; end: P(10^9);
  • PARI
    isok(n) = {my(s = ""); my(f = factor(n)); forstep (i=#f~, 1, -1, for (k=1, f[i,2], s = concat(s, Str(f[i,1])))); (eval(s) % n) == 0;} \\ Michel Marcus, Jun 16 2015

Extensions

a(7)-a(8) from Giovanni Resta, Jun 16 2015

A006919 Write down all the prime divisors in previous term.

Original entry on oeis.org

8, 222, 2337, 31941, 33371313, 311123771, 7149317941, 22931219729, 112084656339, 3347911118189, 11613496501723, 97130517917327, 531832651281459, 3331113965338635107, 3331113965338635107
Offset: 1

Views

Author

Keywords

References

  • H. Jaleebi, personal communication.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A056938 (same for a(1)=49), A037271-A037276, A048985, A048986, A049065.

Programs

  • Mathematica
    g[ n_ ] := (x = n; d = {}; While[ FactorInteger[ x ] != {}, f = FactorInteger[ x, FactorComplete -> True ][ [ 1, 1 ] ]; x = x/f; AppendTo[ d, IntegerDigits[ f ] ] ]; FromDigits[ Flatten[ d ] ]); NestList[ g, 8, 15 ]
    NestList[FromDigits[Flatten[IntegerDigits/@(Table[First[#],{Last[#]}]& /@ FactorInteger[#])]]&,8,15] (* Harvey P. Dale, Dec 04 2011 *)
  • PARI
    first(N, a=8)=vector(N,i,if(i>1,a=A037276(a),a)) \\ M. F. Hasler, Oct 07 2022

Formula

a(n+1) = A037276(a(n)), a(1) = 8. - M. F. Hasler, Oct 07 2022

Extensions

More terms from Robert G. Wilson v, Sep 05 2000, who remarks that sequence stabilizes at 13th term with a prime.

A073646 Least number formed by concatenating the prime factors of n in base 10.

Original entry on oeis.org

1, 2, 3, 22, 5, 23, 7, 222, 33, 25, 11, 223, 13, 27, 35, 2222, 17, 233, 19, 225, 37, 112, 23, 2223, 55, 132, 333, 227, 29, 235, 31, 22222, 113, 172, 57, 2233, 37, 192, 133, 2225, 41, 237, 43, 1122, 335, 223, 47, 22223, 77, 255, 173, 1322, 53, 2333, 115, 2227
Offset: 1

Views

Author

Reinhard Zumkeller, Aug 29 2002

Keywords

Comments

a(n)<=A037276(n) for all n and a(n)=A037276(n) for n<22, a(22) = a(2*11) = 112 <> A037276(22) = 211.

Examples

			a(6) = a(2*3) = 23 < 32; a(66) = a(2*3*11) = 1123 < 1132 < 2113 < 2311 < 3112 < 3211.
		

Crossrefs

Different from A037276. Cf. A084797.

Programs

  • Haskell
    import Data.List (sort)
    a073646 :: Integer -> Integer
    a073646 = read . concat . sort . map show . a027746_row
    -- Reinhard Zumkeller, Jul 13 2013
  • Mathematica
    con[n_, k_] := Nest[Join[{#}, {n}] &, n, k - 1]; Table[Min[FromDigits /@ Flatten /@ IntegerDigits[Permutations[Flatten[con @@@ FactorInteger[n]]]]], {n, 56}] (* Jayanta Basu, Jul 04 2013 *)

Formula

Sort {A027746(n,k): k=1..A001222(n)} lexicographically and concatenate. - Reinhard Zumkeller, Jul 13 2013

A106554 Concatenation of the two prime divisors of a semiprime, smallest divisor first.

Original entry on oeis.org

22, 23, 33, 25, 27, 35, 37, 211, 55, 213, 311, 217, 57, 219, 313, 223, 77, 317, 511, 319, 229, 231, 513, 323, 237, 711, 241, 517, 243, 329, 713, 331, 247, 519, 253, 337, 523, 259, 717, 1111, 261, 341, 343, 719, 267, 347, 271, 1113
Offset: 1

Views

Author

Eric Angelini, May 09 2005

Keywords

Comments

Concatenation of the divisors starting with the largest one leads to another sequence.

Examples

			First semiprime is 4; 4 is 2*2 -> 22.
Second semiprime is 6; 6 is 2*3 -> 23.
Third semiprime is 9; 9 is 3*3 -> 33.
Fourth semiprime is 10; 10 is 2*5 -> 25.
		

Crossrefs

Programs

  • Maple
    read("transforms") :
    A106554 := proc(n)
        A037276(A001358(n)) ;
    end proc: # R. J. Mathar, Oct 29 2012
  • Mathematica
    FromDigits@ Flatten[IntegerDigits@ Table[#1, {#2}] & @@@ FactorInteger@ #] & /@ Select[Range@ 144, PrimeOmega@ # == 2 &] (* Michael De Vlieger, Oct 01 2015 *)
  • PARI
    do(x)=my(v=List()); forprime(p=2, sqrt(x), forprime(q=p, x\p, listput(v, [p*q, eval(Str(p, q))]))); Vec(apply(u->u[2], vecsort(v, 1))) \\ Charles R Greathouse IV, Sep 30 2015

Formula

a(n) = A037276(A001358(n)). - R. J. Mathar, Oct 29 2012

Extensions

More terms from Reinhard Zumkeller, May 19 2005
Data corrected by Giovanni Teofilatto and Altug Alkan, Oct 01 2015

A340592 a(n) is the concatenation of the prime factors (with multiplicity) of n mod n.

Original entry on oeis.org

0, 0, 2, 0, 5, 0, 6, 6, 5, 0, 7, 0, 13, 5, 14, 0, 17, 0, 5, 16, 13, 0, 15, 5, 5, 9, 3, 0, 25, 0, 14, 14, 13, 22, 1, 0, 29, 1, 25, 0, 27, 0, 11, 20, 39, 0, 47, 28, 5, 11, 29, 0, 11, 16, 43, 34, 55, 0, 15, 0, 45, 22, 14, 58, 1, 0, 41, 47, 47, 0, 57, 0, 15, 55, 15, 18, 51, 0, 65, 12, 77, 0, 53, 7
Offset: 2

Views

Author

J. M. Bergot and Robert Israel, Jan 12 2021

Keywords

Comments

a(n) = 0 if n is prime.
The first composite n for which a(n)=0 is 28749. Are there others?
There are no other composite n terms for which a(n)=0 up to 5 million. - Harvey P. Dale, Jul 17 2023

Examples

			For n = 20 = 2*2*5, a(20) = 225 mod 20 = 5.
		

Crossrefs

Programs

  • Maple
    dcat:= proc(L) local i,x;
      x:= L[-1];
      for i from nops(L)-1 to 1 by -1 do
        x:= 10^(1+ilog10(x))*L[i]+x
      od;
      x
    end proc:
    f:= proc(n) local F;
      F:= sort(ifactors(n)[2],(a,b) -> a[1] < b[1]);
      dcat(map(t -> t[1]$t[2], F)) mod n;
    end proc:
    map(f, [$2..100]);
  • Mathematica
    Table[Mod[FromDigits[Flatten[IntegerDigits/@Table[#[[1]],#[[2]]]&/@FactorInteger[n]]],n],{n,2,100}] (* Harvey P. Dale, Jul 17 2023 *)
  • Python
    from sympy import factorint
    def a(n):
        if n == 1: return 0
        return int("".join(str(f) for f in factorint(n, multiple=True)))%n
    print([a(n) for n in range(2, 86)]) # Michael S. Branicky, Jan 18 2022

Formula

a(n) = A037276(n) mod n.

A251360 Numbers k such that k is the concatenation of prime factors of pi(k), in increasing order.

Original entry on oeis.org

1117, 2163, 2537, 5137, 222926801
Offset: 1

Views

Author

Jahangeer Kholdi, Dec 01 2014

Keywords

Comments

Numbers k such that k = A037276(A000720(k)).
Conjecture: numbers k such that k = A084317(A000720(k)). - Chai Wah Wu, Apr 04 2018
a(6) > 10^12 if exists. - Max Alekseyev, May 16 2025

Examples

			1117 is in the sequence since pi(1117) = 11*17,
2163 is in the sequence since pi(2163) = 2*163,
2537 is in the sequence since pi(2537) = 2*5*37,
and 5137 is in the sequence since pi(5137) = 5*137.
		

Crossrefs

Programs

  • Mathematica
    a251360[n_Integer] := Select[Range[n], # == FromDigits[Flatten@IntegerDigits[First@ Transpose@ FactorInteger[PrimePi[#]]]] &]; a251360[10^5] (* Michael De Vlieger, Dec 03 2014 *)
  • Python
    from sympy import prime, factorint
    A251360_list, p = [], 3
    for n in range(2,10**6):
        q, fn = prime(n+1), factorint(n)
        m = int(''.join(str(d)*fn[d] for d in sorted(fn)))
        if p <= m < q:
            A251360_list.append(m)
        p = q # Chai Wah Wu, Dec 10 2014, corrected Apr 04 2018

Extensions

a(5) from Chai Wah Wu, Dec 10 2014

A343156 Starting at n, a(n) = number of iterations of the map x -> A084317(x) (concatenate distinct prime factors of x) required to reach a prime, or -1 if no prime is ever reached.

Original entry on oeis.org

0, 0, 1, 0, 1, 0, 1, 1, 2, 0, 1, 0, 2, 4, 1, 0, 1, 0, 2, 1, 1, 0, 1, 1, 4, 1, 2, 0, 2, 0, 1, 1, 5, 3, 1, 0, 2, 1, 2, 0, 2, 0, 1, 4, 1, 0, 1, 1, 2, 1, 4, 0, 1, 2, 2, 2, 1, 0, 2, 0, 3, 1, 1, 3, 1, 0, 5, 3, 1, 0, 1, 0, 2, 4, 2, 2, 2, 0, 2, 1, 1, 0, 2, 3, 2, 3, 1, 0, 2, 64, 1, 1, 2, 4, 1, 0, 2, 1, 2
Offset: 2

Views

Author

N. J. A. Sloane, Apr 07 2021

Keywords

Comments

Judging by the behavior of similar sequences, it is likely that almost all values of a(n) are -1. n = 407 (see A343157) seems to be the first open case.

Examples

			10 = 2*5 -> 25 = 5^2 -> 5, prime, taking two steps, so a(10)=2.
a(91) = 64: see A084319.
		

References

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

Crossrefs

See A343158 for when k first appears.

A371696 Composite numbers that divide the reverse of the concatenation of their ascending order prime factors, with repetition.

Original entry on oeis.org

26, 38, 46, 378, 26579, 84941, 178838, 30791466, 39373022, 56405502, 227501395, 904085931, 1657827142
Offset: 1

Views

Author

Scott R. Shannon, Apr 03 2024

Keywords

Comments

a(14) > 10^10, if it exists. - Daniel Suteu, Apr 28 2024

Examples

			26 is a term as 26 = 2 * 13 = "213" which is reverse is "312", and 312 is divisible by 26.
227501395 is a term as 227501395 = 5 * 11 * 17 * 23 * 71 * 149 = "511172371149" which in reverse is "941173271115", and 941173271115 is divisible by 227501395.
		

Crossrefs

Programs

  • Python
    from itertools import count, islice
    from sympy import isprime, factorint
    def ok(k): return not isprime(k) and int("".join(str(p)[::-1]*e for p, e in list(factorint(k).items())[::-1]))%k == 0
    def agen(): yield from filter(ok, count(4))
    print(list(islice(agen(), 7))) # Michael S. Branicky, Apr 13 2024
    
  • Python
    from itertools import count, islice
    from sympy import factorint
    def A371696_gen(startvalue=4): # generator of terms >= startvalue
        for n in count(max(startvalue,4)):
            f = factorint(n)
            if sum(f.values()) > 1:
                c = 0
                for p in sorted(f,reverse=True):
                    a = pow(10,len(s:=str(p)),n)
                    q = int(s[::-1])
                    for _ in range(f[p]):
                        c = (c*a+q)%n
                if not c:
                    yield n
    A371696_list = list(islice(A371696_gen(),6)) # Chai Wah Wu, Apr 13 2024

Extensions

a(13) from Daniel Suteu, Apr 28 2024

A038526 Concatenation of prime factors of n-th Fibonacci number.

Original entry on oeis.org

2, 3, 5, 222, 13, 37, 217, 511, 89, 222233, 233, 1329, 2561, 3747, 1597, 2221719, 37113, 351141, 213421, 89199, 28657, 2222233723, 553001, 233521, 21753109, 31329281, 514229, 2225113161, 5572417, 37472207, 28919801, 15973571, 513141961, 22223331719107, 731492221
Offset: 3

Views

Author

Keywords

Programs

  • Maple
    A055642 := proc(n) if n =0 then 1 ; else ilog10(n)+1 ; fi ; end: catDigs := proc(L) local a,k,i ; a := 0 ; for i from 1 to nops(L) do a := a*10^A055642(L[i])+L[i] ; od ; end: A037276 := proc(n) local L,i,ifs,j ; if n = 1 then 0 else ifs := ifactors(n)[2] ; L := [] ; for i in ifs do for j from 1 to op(2,i) do L := [op(L),op(1,i)] ; od: od: catDigs(L) ; fi ; end: A038526 := proc(n) A037276(combinat[fibonacci](n)) ; end: seq(A038526(n),n=3..20) ; # R. J. Mathar, Oct 12 2007
    # second Maple program:
    F:= n-> (<<0|1>, <1|1>>^n)[1, 2]:
    a:= n-> parse(cat(sort(map(i-> i[1]$i[2], ifactors(F(n))[2]))[])):
    seq(a(n), n=3..40);  # Alois P. Heinz, Aug 17 2018

Formula

a(n) = A037276(A000045(n)). - R. J. Mathar, Oct 12 2007

Extensions

Edited by Charles R Greathouse IV, Apr 27 2010
Previous Showing 11-20 of 35 results. Next