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 30 results. Next

A048441 Take the first n numbers written in base 9, concatenate them, then convert from base 9 to base 10.

Original entry on oeis.org

1, 11, 102, 922, 8303, 74733, 672604, 6053444, 490328973, 39716646823, 3217048392674, 260580919806606, 21107054504335099, 1709671414851143033, 138483384602942585688, 11217154152838349440744, 908589486379906304700281, 73595748396772410680722779
Offset: 1

Views

Author

Patrick De Geest, May 15 1999

Keywords

Comments

The first two primes in this sequence occur for n = 2 (a(2) = 11) and n = 14 (a(14) = 1709671414851143033) (email from Kurt Foster, Oct 24 2015). - N. J. A. Sloane, Oct 25 2015

Examples

			a(9) = (1)(2)(3)(4)(5)(6)(7)(8)(10) = 1234567810_9 = 490328973.
		

Crossrefs

Concatenation of first n numbers in other bases: 2: A047778, 3: A048435, 4: A048436, 5: A048437, 6: A048438, 7: A048439, 8: A048440, 9: this sequence, 10: A007908, 11: A048442, 12: A048443, 13: A048444, 14: A048445, 15: A048446, 16: A048447.

Programs

  • Magma
    [n eq 1 select 1 else Self(n-1)*9^(1+Ilog(9, n))+n: n in [1..20]]; // Vincenzo Librandi, Dec 30 2012
  • Mathematica
    If[STARTPOINT==1, n={}, n=Flatten[IntegerDigits[Range[STARTPOINT-1], 9]]]; Table[AppendTo[n, IntegerDigits[w, 9]]; n=Flatten[n]; FromDigits[n, 9], {w, STARTPOINT, ENDPOINT}] (* Dylan Hamilton, Aug 11 2010 *)
    f[n_]:= FromDigits[Flatten@IntegerDigits[Range@n, 9], 9]; Array[f, 20] (* Vincenzo Librandi, Dec 30 2012 *)
  • PARI
    { cuo=0;
    for(ixp=1, 18,
    casi = ixp; cvst=0;
    while(casi != 0,
    cvd = casi%9; cvst=10*cvst + cvd + 1; casi = (casi - cvd) / 9 );
    while(cvst !=0, ptch = cvst%10;
    cuo=cuo*9+ptch-1; cvst = (cvst - ptch) / 10 ); print1(cuo, ", "))}
    \\ Douglas Latimer, Apr 27 2012
    

Extensions

More terms from Douglas Latimer, May 10 2012

A048442 Take the first n numbers written in base 11, concatenate them, then convert from base 11 to base 10.

Original entry on oeis.org

1, 13, 146, 1610, 17715, 194871, 2143588, 23579476, 259374245, 2853116705, 345227121316, 41772481679248, 5054470283189021, 611590904265871555, 74002499416170458170, 8954302429356625438586, 1083470593952151678068923, 131099941868210353046339701
Offset: 1

Views

Author

Patrick De Geest, May 15 1999

Keywords

Examples

			a(11) = (1)(2)(3)(4)(5)(6)(7)(8)(9)(A)(10) = 123456789A10_11 = 345227121316.
		

Crossrefs

Cf. A014881.
Concatenation of first n numbers in other bases: 2: A047778, 3: A048435, 4: A048436, 5: A048437, 6: A048438, 7: A048439, 8: A048440, 9: A048441, 10: A007908, 11: this sequence, 12: A048443, 13: A048444, 14: A048445, 15: A048446, 16: A048447.

Programs

  • Magma
    [n eq 1 select 1 else Self(n-1) * 11^(1+Ilog(11, n)) + n: n in [1..20]]; // Vincenzo Librandi, Dec 30 2012
  • Mathematica
    If[STARTPOINT==1, n={}, n=Flatten[IntegerDigits[Range[STARTPOINT-1], 11]]]; Table[AppendTo[n, IntegerDigits[w, 11]]; n=Flatten[n]; FromDigits[n, 11], {w, STARTPOINT, ENDPOINT}] (* Dylan Hamilton, Aug 11 2010 *)
    f[n_]:= FromDigits[Flatten@IntegerDigits[Range@n, 11], 11]; Array[f, 20] (* Vincenzo Librandi, Dec 30 2012 *)
  • PARI
    { cuo=0;
    for(ixp=1, 18, casi = ixp; cvst=0;
    while(casi != 0,
    cvd = casi%11; cvst=100*cvst + cvd + 1; casi = (casi - cvd) / 11 );
    while(cvst !=0, ptch = cvst%100;
    cuo=cuo*11+ptch-1; cvst = (cvst - ptch) / 100 ); print1(cuo, ", "))}
    \\ Douglas Latimer, May 09 2012
    

Extensions

1 more term from Douglas Latimer, May 10 2012

A048443 Take the first n numbers written in base 12, concatenate them, then convert from base 12 to base 10.

Original entry on oeis.org

1, 14, 171, 2056, 24677, 296130, 3553567, 42642812, 511713753, 6140565046, 73686780563, 10610896401084, 1527969081756109, 220027547772879710, 31683966879294678255, 4562491230618433668736, 656998737209054448298001, 94607818158103840554912162
Offset: 1

Views

Author

Patrick De Geest, May 15 1999

Keywords

Examples

			a(12) = (1)(2)(3)(4)(5)(6)(7)(8)(9)(A)(B)(10) = 123456789AB10_12 = 10610896401084.
		

Crossrefs

Cf. A014882.
Concatenation of first n numbers in other bases: 2: A047778, 3: A048435, 4: A048436, 5: A048437, 6: A048438, 7: A048439, 8: A048440, 9: A048441, 10: A007908, 11: A048442, 12: this sequence, 13: A048444, 14: A048445, 15: A048446, 16: A048447.

Programs

  • Magma
    [n eq 1 select 1 else Self(n-1)*12^(1+Ilog(12, n))+n: n in [1..20]]; // Vincenzo Librandi, Dec 30 2012
  • Mathematica
    If[STARTPOINT==1, n={}, n=Flatten[IntegerDigits[Range[STARTPOINT-1], 12]]]; Table[AppendTo[n, IntegerDigits[w, 12]]; n=Flatten[n]; FromDigits[n, 12], {w, STARTPOINT, ENDPOINT}] (* Dylan Hamilton, Aug 11 2010 *)
    f[n_]:= FromDigits[Flatten@IntegerDigits[Range@n, 12], 12]; Array[f, 20] (* Vincenzo Librandi, Dec 30 2012 *)

A048444 Take the first n numbers written in base 13, concatenate them, then convert from base 13 to base 10.

Original entry on oeis.org

1, 15, 198, 2578, 33519, 435753, 5664796, 73642356, 957350637, 12445558291, 161792257794, 2103299351334, 355457590375459, 60072332773452585, 10152224238713486880, 1715725896342579282736, 289957676481895898782401, 49002847325440406894225787
Offset: 1

Views

Author

Patrick De Geest, May 15 1999

Keywords

Comments

No primes in the first 31000 terms. - Giovanni Resta, Jun 08 2018

Examples

			a(12) = (1)(2)(3)(4)(5)(6)(7)(8)(9)(A)(B)(C) = 123456789ABC_13 = 2103299351334.
		

Crossrefs

Cf. A014896.
Concatenation of first n numbers in other bases: 2: A047778, 3: A048435, 4: A048436, 5: A048437, 6: A048438, 7: A048439, 8: A048440, 9: A048441, 10: A007908, 11: A048442, 12: A048443, 13: this sequence, 14: A048445, 15: A048446, 16: A048447.

Programs

  • Magma
    [n eq 1 select 1 else Self(n-1)*13^(1+Ilog(13, n))+n: n in [1..20]]; // Vincenzo Librandi, Dec 30 2012
  • Mathematica
    If[STARTPOINT==1, n={}, n=Flatten[IntegerDigits[Range[STARTPOINT-1], 13]]]; Table[AppendTo[n, IntegerDigits[w, 13]]; n=Flatten[n]; FromDigits[n, 13], {w, STARTPOINT, ENDPOINT}] (* Dylan Hamilton, Aug 11 2010 *)
    f[n_]:= FromDigits[Flatten@IntegerDigits[Range@n, 13], 13]; Array[f, 20] (* Vincenzo Librandi, Dec 30 2012 *)

A048445 Take the first n numbers written in base 14, concatenate them, then convert from base 14 to base 10.

Original entry on oeis.org

1, 16, 227, 3182, 44553, 623748, 8732479, 122254714, 1711566005, 23961924080, 335466937131, 4696537119846, 65751519677857, 12887297856859986, 2525910379944557271, 495078434469133225132, 97035373155950112125889, 19018933138566221976674262, 3727710895158979507428155371
Offset: 1

Views

Author

Patrick De Geest, May 15 1999

Keywords

Examples

			a(14) = (1)(2)(3)(4)(5)(6)(7)(8)(9)(A)(B)(C)(D)(10) = 123456789ABCD10_14 = 12887297856859986.
		

Crossrefs

Cf. A014897.
Concatenation of first n numbers in other bases: 2: A047778, 3: A048435, 4: A048436, 5: A048437, 6: A048438, 7: A048439, 8: A048440, 9: A048441, 10: A007908, 11: A048442, 12: A048443, 13: A048444, 14: this sequence, 15: A048446, 16: A048447.

Programs

  • Magma
    [n eq 1 select 1 else Self(n-1)*14^(1+Ilog(14, n))+n: n in [1..20]]; // Vincenzo Librandi, Dec 30 2012
  • Mathematica
    If[STARTPOINT==1, n={}, n=Flatten[IntegerDigits[Range[STARTPOINT-1], 14]]]; Table[AppendTo[n, IntegerDigits[w, 14]]; n=Flatten[n]; FromDigits[n, 14], {w, STARTPOINT, ENDPOINT}] (* Dylan Hamilton, Aug 11 2010 *)
    f[n_]:= FromDigits[Flatten@IntegerDigits[Range@n, 14], 14]; Array[f, 20] (* Vincenzo Librandi, Dec 30 2012 *)

A048446 Take the first n numbers written in base 15, concatenate them, then convert from base 15 to base 10.

Original entry on oeis.org

1, 17, 258, 3874, 58115, 871731, 13075972, 196139588, 2942093829, 44131407445, 661971111686, 9929566675302, 148943500129543, 2234152501943159, 502684312937210790, 113103970410872427766, 25448393342446296247367, 5725888502050416655657593, 1288324912961343747522958444
Offset: 1

Views

Author

Patrick De Geest, May 15 1999

Keywords

Examples

			a(14) = (1)(2)(3)(4)(5)(6)(7)(8)(9)(A)(B)(C)(D)(E) = 123456789ABCDE_15 = 2234152501943159.
		

Crossrefs

Cf. A014898.
Concatenation of first n numbers in other bases: 2: A047778, 3: A048435, 4: A048436, 5: A048437, 6: A048438, 7: A048439, 8: A048440, 9: A048441, 10: A007908, 11: A048442, 12: A048443, 13: A048444, 14: A048445, 15: this sequence, 16: A048447.

Programs

  • Magma
    [n eq 1 select 1 else Self(n-1) * 15^(1+Ilog(15, n)) + n: n in [1..20]]; // Vincenzo Librandi, Dec 30 2012
  • Mathematica
    If[STARTPOINT==1, n={}, n=Flatten[IntegerDigits[Range[STARTPOINT-1], 15]]]; Table[AppendTo[n, IntegerDigits[w, 15]]; n=Flatten[n]; FromDigits[n, 15], {w, STARTPOINT, ENDPOINT}] (* Dylan Hamilton, Aug 11 2010 *)
    f[n_]:= FromDigits[Flatten@IntegerDigits[Range@n, 15], 15]; Array[f, 20] (* Vincenzo Librandi, Dec 30 2012 *)

A066716 Decimal expansion of the binary Champernowne constant 0.862240125868... whose binary expansion is the concatenation of 1, 2, 3, ... written in binary.

Original entry on oeis.org

8, 6, 2, 2, 4, 0, 1, 2, 5, 8, 6, 8, 0, 5, 4, 5, 7, 1, 5, 5, 7, 7, 9, 0, 2, 8, 3, 2, 4, 9, 3, 9, 4, 5, 7, 8, 5, 6, 5, 7, 6, 4, 7, 4, 2, 7, 6, 8, 2, 9, 9, 0, 9, 4, 5, 1, 6, 0, 7, 1, 2, 1, 4, 5, 5, 7, 3, 0, 6, 7, 4, 0, 5, 9, 0, 5, 1, 6, 4, 5, 8, 0, 4, 2, 0, 3, 8, 4, 4, 1, 4, 3, 8, 6, 1, 8, 1, 3, 3, 4
Offset: 0

Views

Author

Robert G. Wilson v, Jan 14 2002

Keywords

Comments

A theorem of Copeland & Erdős proves that this constant is 2-normal. - Charles R Greathouse IV, Feb 06 2015
This constant is transcendental. Note that this result is nontrivial: it is not a corollary of the result of Masaaki Amou saying that the base-b Champernowne constant has irrationality measure b, because the Thue-Siegel-Roth theorem only guarantees that a number with irrationality measure greater than 2 is transcendental. However, it is already stated in Masaaki Amou's paper that K. Mahler proved that the base-b Champernowne constant is transcendental for all b. - Jianing Song, Sep 27 2023

Examples

			0.8622401258680545715577902832493945785657647427682990945160712145573067405905...
		

Crossrefs

Cf. A030302 (binary digits), A030190 (same with initial 0), A030303 (indices of 1's), A007088, A047778 (concatenate binary 1..n).
Cf. A066717 (continued fraction), A365238 (reciprocal).
Cf. A100125 (Sum n/2^(n^2)).
Cf. A033307.

Programs

  • Mathematica
    a = {}; Do[a = Append[a, IntegerDigits[n, 2]], {n, 1, 100} ]; RealDigits[ N[ FromDigits[ {Flatten[a], 0}, 2], 100]]
    First[RealDigits[ChampernowneNumber[2], 10, 100]] (* Paolo Xausa, Jun 12 2024 *)
  • PARI
    my(s=0.); forstep(n=default(realprecision),1,-1,s=(s+n)>>#binary(n)); s \\ Charles R Greathouse IV, Feb 06 2015, corrected by M. F. Hasler, Mar 22 2017
    
  • PARI
    s=0;sum(n=1,31,n*.5^s+=logint(n,2)+1) \\ Accurate to 0.5^s. The sum up to n=31 is enough for standard precision of 38 digits. - M. F. Hasler, Mar 22 2017

Formula

The "binary" Champernowne constant is the number whose base-2 expansion is the concatenation of the binary representations of the integers, 0.(1)(10)(11)(100)(101)(110)(111)(1000)..., cf. A030302.

Extensions

Leading zero removed, offset adjusted, and keyword:cons added by R. J. Mathar, Mar 04 2010
Name edited by M. F. Hasler, Oct 26 2019

A058935 Concatenation of first n binary numbers.

Original entry on oeis.org

0, 1, 110, 11011, 11011100, 11011100101, 11011100101110, 11011100101110111, 110111001011101111000, 1101110010111011110001001, 11011100101110111100010011010, 110111001011101111000100110101011, 1101110010111011110001001101010111100
Offset: 0

Views

Author

Henry Bottomley, Jan 12 2001

Keywords

Comments

If the terms are read as decimal numbers, which of them are primes? For example, a(5) = 11011100101 = 1193*9229757 is not a prime. - N. J. A. Sloane, Feb 17 2023
Answer: a(231) is the first prime term when read as a decimal number; a(15) is the first when read as a binary number. - Michael S. Branicky, Feb 17 2023

Crossrefs

Cf. A047778 for this converted to decimal, A001855 (offset) for number of digits.
Cf. A066716: binary Champernowne constant, A030302: binary digits, A030190: same with initial 0, A030303: indices of 1's, A007088.
Other bases: A117640 (4), A007908 (10).

Programs

  • Mathematica
    FromDigits /@ Flatten /@ Rest[FoldList[Append, {}, IntegerDigits[Range[10], 2]]] (* Eric W. Weisstein, Nov 04 2015 *)
  • Python
    from itertools import count, islice
    def agen(s=""): yield from (int(s:=s+bin(n)[2:]) for n in count(0))
    print(list(islice(agen(), 13))) # Michael S. Branicky, Feb 17 2023
    
  • Python
    from functools import reduce
    def A058935(n): return int(bin(reduce(lambda i,j:(i<Chai Wah Wu, Feb 26 2023

Formula

a(n) = a(n-1)*10^A029837(n) + A007088(n).

A098780 First n numbers in binary representation concatenated in reverse order.

Original entry on oeis.org

1, 5, 29, 157, 1437, 13725, 128413, 1176989, 20051357, 355595677, 6261175709, 109340390813, 1896046785949, 32682372363677, 560447953696157, 9567647208437149, 315812421869630877, 10692105963331253661
Offset: 1

Views

Author

Reinhard Zumkeller, Oct 04 2004

Keywords

Examples

			a(4) = (4 3 2 1) -> (100 11 10 1) -> 10011101 -> 157.
		

Crossrefs

Programs

  • Mathematica
    Table[FromDigits[Flatten[IntegerDigits[#,2]&/@Reverse[Range[n]]],2],{n,20}] (* Harvey P. Dale, Sep 10 2019 *)
  • Python
    def A098780(n):
        s=""
        for i in range(n,0,-1):
            s+=bin(i)[2:]
        return int(s,2) # Indranil Ghosh, Jan 28 2017
    
  • Python
    from functools import reduce
    def A098780(n): return reduce(lambda i,j:(i<Chai Wah Wu, Feb 26 2023

Formula

a(n) = n*A000079(A070939(a(n-1))) + a(n-1); a(1) = 1.
a(n) = n*2^(1 + floor(log_2(a(n-1)))) + a(n-1); a(1) = 1.

Extensions

Typo in data corrected by D. S. McNeil, Aug 20 2010

A117127 Concatenate the first n positive integers written in binary (with each integer written so the most significant 1 is on the left and the concatenated string is from left to right). a(n) is the number of times n written in binary appears in the concatenated string.

Original entry on oeis.org

1, 1, 2, 1, 2, 3, 3, 1, 2, 1, 4, 3, 4, 5, 4, 1, 2, 2, 3, 2, 3, 2, 7, 3, 4, 4, 6, 6, 5, 7, 5, 1, 2, 2, 3, 1, 4, 3, 4, 2, 4, 2, 5, 2, 4, 4, 9, 3, 4, 5, 5, 4, 6, 4, 9, 6, 6, 6, 7, 9, 6, 9, 6, 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 5, 2, 6, 4, 5, 2, 4, 3, 6, 3, 5, 4, 7, 2, 5, 4, 7, 3, 7, 5, 11, 3, 4, 5, 5, 4, 7, 5, 7, 4
Offset: 1

Views

Author

Leroy Quet, Apr 20 2006

Keywords

Comments

See also A047778, concatenation of first n numbers in binary. - Jonathan Vos Post, Apr 21 2006
Note that these counts reflect the pattern overlapping case. - Diana L. Mecum, Aug 06 2008
First occurrence of n: 1, 3, 6, 11, 14, 27, 23, 107, 47, 119, 95, 111, 191, 239, 223, 1007, 767, 447, 1535, 991, 895, 959, 3519, 1791, 1983, 1919, 3583, 7159, 7871, 3839, 14327, 16063, 8063, 7679, 7935, 15839, ??, 15359, 16127, 15871, ..., ; limit of search = 25000. - Robert G. Wilson v, Aug 30 2008

Examples

			The first 13 positive integers written in binary and concatenated is
11011100101110111100010011010101111001101.
13 in binary, which is 1101, appears 4 times in the concatenated string, starting at positions (reading from left to right) 1, 12, 25 and 38.
The last occurrence of 1101 is the integer 13 itself converted to binary and added to the end of the concatenated string, of course. So a(13) = 4.
		

Crossrefs

Programs

  • Maple
    A007088 := proc(n) convert(n,base,2) ; ListTools[Reverse](%) ; end:
    A058935 := proc(n) local i,a ; if n = 0 then RETURN([0]) ; else a := [] ; for i from 1 to n do a := [op(a),op(A007088(i))] ; od: fi ; end:
    A117127 := proc(n) local a058935,strtL,endL,nL,a ; nL := A007088(n) ; a058935 := A058935(n) ; a := 0 ; for strtL from 1 to nops(a058935) do for endL from strtL to nops(a058935) do if verify[sublist]( nL, [op(strtL..endL, a058935)] ) then a := a+1 ; fi ; od: od ; RETURN(a) ; end: for n from 1 to 80 do printf("%d, ",A117127(n)) ; od: # R. J. Mathar, Jan 23 2008
  • Mathematica
    a[n_] := StringCount[ ToString@ FromDigits@ Flatten@ IntegerDigits[ Range@n, 2], ToString@ FromDigits@ IntegerDigits[n, 2], Overlaps -> True]; Array[a, 105] (* Robert G. Wilson v, Aug 30 2008 *)
    fc[n_]:=Module[{idn2=IntegerDigits[n,2],len},len=Length[idn2];Count[ Partition[ Flatten[Table[IntegerDigits[i,2],{i,n}]],len,1],idn2]]; Array[fc,110] (* Harvey P. Dale, Dec 16 2011 *)

Extensions

More terms from R. J. Mathar, Jan 23 2008
Terms 81 through 2000 from Diana L. Mecum, Aug 06 2008
Previous Showing 11-20 of 30 results. Next