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

A280642 Numbers k such that k^3 has an odd number of digits and the middle digit is 2.

Original entry on oeis.org

5, 9, 103, 113, 133, 146, 151, 154, 165, 180, 198, 202, 470, 473, 493, 496, 504, 507, 521, 531, 538, 542, 566, 569, 581, 591, 593, 599, 612, 618, 620, 650, 654, 673, 681, 686, 703, 711, 715, 728, 729, 732, 740, 779, 801, 829, 841, 850, 855, 856, 857, 858, 874
Offset: 1

Views

Author

Lars Blomberg, Jan 07 2017

Keywords

Comments

The sequence of cubes starts: 125, 729, 1092727, 1442897, 2352637, 3112136, 3442951, 3652264, ...

Examples

			5^3 = 1(2)5, 180^3 = 583(2)000, 618^3 = 2360(2)9032.
		

Crossrefs

See A279420-A279429 for a k^2 version.
See A279430-A279431 for a k^2 version in base 2.

Programs

  • Mathematica
    a[n_]:=Part[IntegerDigits[n],(Length[IntegerDigits[n]]+1)/2];
    Select[Range[0,874],OddQ[Length[IntegerDigits[#^3]]] && a[#^3]==2 &] (* Indranil Ghosh, Mar 06 2017 *)
  • PARI
    isok(k) = my(d=digits(k^3)); (#d%2 == 1) && (d[#d\2 +1] == 2);
    for(k=0, 874, if(isok(k)==1, print1(k, ", "))); \\ Indranil Ghosh, Mar 06 2017
    
  • Python
    i=0
    j=1
    while i<=874:
        n=str(i**3)
        l=len(n)
        if l%2 and n[(l-1)//2]=="2":
            print(str(i), end=', ')
            j+=1
        i+=1 # Indranil Ghosh, Mar 06 2017

A280644 Numbers k such that k^3 has an odd number of digits and the middle digit is 4.

Original entry on oeis.org

7, 104, 112, 140, 143, 158, 166, 186, 188, 195, 465, 467, 490, 541, 558, 572, 595, 598, 604, 605, 606, 607, 613, 616, 622, 625, 630, 634, 635, 640, 643, 647, 653, 667, 675, 679, 687, 702, 712, 718, 720, 727, 734, 738, 759, 764, 783, 787, 802, 810, 815, 818
Offset: 1

Views

Author

Lars Blomberg, Jan 07 2017

Keywords

Comments

The sequence of cubes starts: 343, 1124864, 1404928, 2744000, 2924207, 3944312, 4574296, 6434856, ...

Examples

			7^3 = 3(4)3, 195^3 = 741(4)875, 640^3 = 2621(4)4000
		

Crossrefs

See A279420-A279429 for a k^2 version.
See A279430-A279431 for a k^2 version in base 2.

Programs

  • Mathematica
    Select[Range[1000],OddQ[IntegerLength[#^3]]&&NumberDigit[#^3,(IntegerLength[ #^3]-1)/2]==4&] (* Harvey P. Dale, Aug 12 2021 *)
Showing 1-2 of 2 results.