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-10 of 19 results. Next

A333236 Largest digit in the decimal expansion of 1/n.

Original entry on oeis.org

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

Views

Author

Andrew Slattery, Mar 12 2020

Keywords

Examples

			a(50) = 2 because the largest digit in 1/50 = 0.02 is 2.
		

Crossrefs

Cf. A333237 (a(n) = 9), A333402 (a(n) = 1).

Programs

  • Mathematica
    a[n_] := Max@RealDigits[1/n][[1]]; Array[a, 88] (* Giovanni Resta, Mar 12 2020 *)
  • Python
    from sympy import n_order, multiplicity
    def A333236(n):
        m2, m5 = multiplicity(2,n), multiplicity(5,n)
        return int(max(str(10**(max(m2,m5)+n_order(10,n//2**m2//5**m5))//n))) # Chai Wah Wu, Feb 07 2022

Formula

a(n) = max_{i=0..n} (floor(10^i/n) mod 10).
a(10*n) = a(n) and a(n) = n iff n = 1, 3, 6. - Bernard Schott, Mar 19 2020

Extensions

More terms from Giovanni Resta, Mar 12 2020

A333402 Numbers m such that the largest digit in the decimal expansion of 1/m is 1.

Original entry on oeis.org

1, 9, 10, 90, 99, 100, 900, 909, 990, 999, 1000, 9000, 9009, 9090, 9900, 9990, 9999, 10000, 90000, 90009, 90090, 90900, 90909, 99000, 99900, 99990, 99999, 100000, 900000, 900009, 900090, 900900, 909000, 909090, 990000, 990099, 999000, 999900, 999990, 999999, 1000000
Offset: 1

Views

Author

Bernard Schott, Mar 19 2020

Keywords

Comments

If m is a term, 10*m is also a term.
If m is a term then m has only digits {1}, {9}, {1,0} or {9,0} in its decimal representation, but this is not sufficient to be a term (see examples).
Some subsequences below (not exhaustive, see crossrefs):
m = 10^k, k >= 0, hence m is in A011557 = {1, 10, 100, 1000, 10000, ...};
m = 9*10^k, k >= 0, hence m is in A052268 = {9, 90, 900, 9000, 90000, ...};
m = 10^k-1, k >= 1, hence m is in A002283 = {9, 99, 999, 9999, 99999, ...};
m = 9*(10^k+1), k >= 1, hence m is in 9*A000533 = {99, 909, 9009, 90009, ...};
m = 9+100*(100^k-1)/11, k >= 0, hence m is in 9*A094028 = {9, 909, 90909, 9090909, ...}.

Examples

			As 1/101 = 0.009900990099..., 101 is not a term.
As 1/909 = 0.001100110011..., 909 is a term.
As 1/9099 = 0.000109902187..., 9099 is not a term.
As 1/9999 = 0.000100010001..., 9999 is also a term.
		

Crossrefs

Cf. A333236, A333237 (similar, with 9).
Subsequences: A002283, A011557, A052268.
Subsequences: 9*A000533, 9*A094028, 9*A135577, 9*A261544, 9*A330135.

Programs

  • Mathematica
    Select[Range[10^4], Max @ RealDigits[1/#][[1]] == 1 &] (* Amiram Eldar, Mar 19 2020 *)
  • Python
    from itertools import count, islice
    def A333402_gen(startvalue=1): # generator of terms >= startvalue
        for m in count(max(startvalue,1)):
            k = 1
            while k <= m:
                k *= 10
            rset = {0}
            while True:
                k, r = divmod(k, m)
                if max(str(k)) > '1':
                    break
                else:
                    if r in rset:
                        yield m
                        break
                rset.add(r)
                k = r
                while k <= m:
                    k *= 10
    A333402_list = list(islice(A333402_gen(),30)) # Chai Wah Wu, Feb 17 2022

Formula

A333236(a(n))= 1.

Extensions

More terms from Jinyuan Wang, Mar 19 2020

A341383 Numbers m such that the largest digit in the decimal expansion of 1/m is 2.

Original entry on oeis.org

5, 45, 50, 450, 495, 500, 819, 825, 4500, 4545, 4950, 4995, 5000, 8190, 8250, 8325, 45000, 45045, 45450, 47619, 49500, 49950, 49995, 50000, 81819, 81900, 82500, 83250, 83325, 89109, 450000, 450045, 450450, 454500, 454545, 476190, 495000, 499500, 499950, 499995, 500000
Offset: 1

Views

Author

Bernard Schott, Feb 10 2021

Keywords

Comments

If m is a term, 10*m is also a term.
5 is the only prime up to 2.6*10^8 (comments in A333237).
Some subsequences: {45, 4545, 454545, ...}, {45045, 45045045, 45045045045, ...}, {45, 495, 4995, 49995, ...}, {819, 81819, 8181819, ...}, {825, 8325, 83325, 833325...}, ...
The subsequence of terms where 1/m has only digits {0,2} is m = 5*A333402 = 5, 45, 50, etc. A333402 is those t where 1/t has only digits {0,1}, so that 1/(5*t) = 2*(1/t)*(1/10) has digits {0,2}, starting from 1/5 = 0.2. These m are also A333402/2 of the even terms from A333402, since A333402 (like here) is self-similar in that the multiples of 10, divided by 10, are the sequence itself. - Kevin Ryde, Feb 13 2021

Examples

			As 1/45 = 0.0202020202..., 45 is a term.
As 1/825 = 0.0012121212121212...., 825 is a term.
As 1/47619 = 0.000021000021000021..., 47619 is a term.
As 1/4545045 = 0.000000220019824..., 4545045 is not a term.
		

Crossrefs

Cf. A333236.
Similar with largest digit k: A333402 (k=1), A333237 (k=9).
Subsequence: A093143 \ {1}.
Decimal expansion: A021499 (1/495), A021823 (1/819).

Programs

  • Mathematica
    Select[Range[10^5], Max[RealDigits[1/#][[1]]] == 2 &] (* Amiram Eldar, Feb 10 2021 *)
  • Python
    from itertools import count, islice
    from sympy import n_order, multiplicity
    def A341383_gen(startvalue=1): # generator of terms >= startvalue
        for m in count(max(startvalue,1)):
            m2, m5 = multiplicity(2,m), multiplicity(5,m)
            if max(str(10**(max(m2,m5)+n_order(10,m//2**m2//5**m5))//m)) == '2':
                yield m
    A341383_list = list(islice(A341383_gen(),10)) # Chai Wah Wu, Feb 07 2022

Extensions

Missing terms added by Amiram Eldar, Feb 10 2021

A353441 Integers m such that the decimal expansion of 1/m contains the digit 5.

Original entry on oeis.org

2, 4, 7, 8, 14, 16, 17, 18, 19, 20, 22, 23, 26, 28, 29, 31, 32, 34, 35, 38, 39, 40, 42, 43, 46, 47, 49, 51, 53, 54, 56, 57, 58, 59, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 74, 76, 78, 79, 80, 81, 82, 83, 85, 86, 87, 89, 92, 93, 94, 95, 97, 98, 102, 103, 104, 105, 106, 107, 108, 109
Offset: 1

Views

Author

Keywords

Comments

If m is a term, 10*m is also a term, so terms with no trailing zeros are all primitive terms.

Examples

			m = 7 is a term since 1/7 = 0.142857142857...
m = 22 is a term since 1/22 = 0.04545454545... (here, 5 is the largest digit).
m = 132 is a term since 1/693 = 0.00757575... (here, 5 is the smallest digit).
		

Crossrefs

A351471 (largest digit=5) and A352159 (smallest digit=5) are subsequences.
Similar with digit k: A352154 (k=0), A353437 (k=1), A353438 (k=2), A353439 (k=3), A353440 (k=4), this sequence (k=5), A353442 (k=6), A353443 (k=7), A353444 (k=8), A333237 (k=9).
Complement of A362579.

Programs

  • Maple
    filter:= proc(n) local q;
      q:= NumberTheory:-RepeatingDecimal(1/n);
      member(5,RepeatingPart(q)) or member(5, NonRepeatingPart(q))
    end proc:
    select(filter, [$1..200]); # Robert Israel, Apr 25 2023
  • Mathematica
    f[n_] := Union[ Flatten[ RealDigits[ 1/n][[1]] ]]; Select[ Range@ 125, MemberQ[f@#, 5] &]
  • Python
    from itertools import count, islice
    from sympy import multiplicity, n_order
    def A353441_gen(startvalue=1): # generator of terms >= startvalue
        for a in count(max(startvalue,1)):
            m2, m5 = (~a&a-1).bit_length(), multiplicity(5,a)
            k, m = 10**max(m2,m5), 10**n_order(10,a//(1<A353441_list = list(islice(A353441_gen(),20)) # Chai Wah Wu, May 01 2023

A350814 Numbers m such that the largest digit in the decimal expansion of 1/m is 3.

Original entry on oeis.org

3, 30, 33, 75, 300, 303, 330, 333, 429, 750, 813, 3000, 3003, 3030, 3125, 3300, 3330, 3333, 4290, 4329, 7500, 7575, 8130, 30000, 30003, 30030, 30300, 30303, 31250, 33000, 33300, 33330, 33333, 42900, 43290, 46875, 75000, 75075, 75750, 76923, 81103, 81300, 300000
Offset: 1

Views

Author

Bernard Schott, Jan 30 2022

Keywords

Comments

If m is a term, 10*m is also a term.
3 is the only prime up to 2.6*10^8 (see comments in A333237).
Some subsequences:
{3, 30, 300, ...} = A093138 \ {1}.
{3, 33, 333, ...} = A002277 \ {0}.
{3, 33, 303, 3003, ...} = 3 * A000533.
{3, 303, 30303, 3030303, ...} = 3 * A094028.

Examples

			As 1/33 = 0.0303030303..., 33 is a term.
As 1/75 = 0.0133333333..., 75 is a term.
As 1/429 = 0.002331002331002331..., 429 is a term.
		

Crossrefs

Similar with largest digit k: A333402 (k=1), A341383 (k=2), A333237 (k=9).
Subsequences: A002277 \ {0}, A093138 \ {1}.
Decimal expansion: A010701 (1/3), A010674 (1/33).

Programs

  • Mathematica
    Select[Range[10^5], Max[RealDigits[1/#][[1]]] == 3 &] (* Amiram Eldar, Jan 30 2022 *)
  • Python
    from fractions import Fraction
    from itertools import count, islice
    from sympy import n_order, multiplicity
    def repeating_decimals_expr(f, digits_only=False):
        """ returns repeating decimals of Fraction f as the string aaa.bbb[ccc].
            returns only digits if digits_only=True.
        """
        a, b = f.as_integer_ratio()
        m2, m5 = multiplicity(2,b), multiplicity(5,b)
        r = max(m2,m5)
        k, m = 10**r, 10**n_order(10,b//2**m2//5**m5)-1
        c = k*a//b
        s = str(c).zfill(r)
        if digits_only:
            return s+str(m*k*a//b-c*m)
        else:
            w = len(s)-r
            return s[:w]+'.'+s[w:]+'['+str(m*k*a//b-c*m)+']'
    def A350814_gen(startvalue=1): # generator of terms >= startvalue
        return filter(lambda m:max(repeating_decimals_expr(Fraction(1,m),digits_only=True)) == '3',count(max(startvalue,1)))
    A350814_list = list(islice(A350814_gen(),10)) # Chai Wah Wu, Feb 07 2022

Extensions

More terms from Amiram Eldar, Jan 30 2022

A353437 Integers m such that the decimal expansion of 1/m contains the digit 1.

Original entry on oeis.org

1, 6, 7, 8, 9, 10, 14, 17, 19, 21, 23, 24, 26, 28, 29, 31, 32, 34, 35, 38, 39, 43, 46, 47, 49, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100
Offset: 1

Views

Author

Keywords

Comments

If m is a term, 10*m is also a term, so terms with no trailing zeros are all primitive terms.

Examples

			m = 7 is a term since 1/7 = 0.142857142857... (here, 1 is the smallest digit).
m = 17 is a term since 1/17 = 0.05882352941176470588235294117647...
m = 99 is a term since 1/99 = 0.0101010101... (here, 1 is the largest digit).
		

Crossrefs

A333402 (largest digit=1) and A352155 (smallest digit=1) are subsequences.
Similar with digit k: A352154 (k=0), this sequence (k=1), A353438 (k=2), A353439 (k=3), A353440 (k=4), A353441 (k=5), A353442 (k=6), A353443 (k=7), A353444 (k=8), A333237 (k=9).

Programs

  • Mathematica
    f[n_] := Union[ Flatten[ RealDigits[ 1/n][[1]] ]]; Select[ Range@ 125, MemberQ[f@#, 1] &]

A353438 Integers m such that the decimal expansion of 1/m contains the digit 2.

Original entry on oeis.org

4, 5, 7, 8, 13, 14, 16, 17, 19, 23, 28, 29, 31, 32, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 56, 57, 58, 59, 61, 62, 64, 67, 68, 69, 70, 71, 76, 77, 78, 79, 80, 81, 82, 83, 85, 86, 87, 89, 92, 93, 94, 95, 97, 98, 102, 103, 105, 106, 107, 108, 109
Offset: 1

Views

Author

Keywords

Comments

If m is a term, 10*m is also a term, so terms with no trailing zeros are all primitive terms.

Examples

			m = 8 is a term since 1/8 = 0.125.
m = 44 is a term since 1/44 = 0.022727272727... (here, 2 is the smallest digit).
m = 495 is a term since 1/495 = 0.002020202... (here, 2 is the largest digit).
		

Crossrefs

A341383 (largest digit=2) and A352156 (smallest digit=2) are subsequences.
Similar with digit k: A352154 (k=0), A353437 (k=1), this sequence (k=2), A353439 (k=3), A353440 (k=4), A353441 (k=5), A353442 (k=6), A353443 (k=7), A353444 (k=8), A333237 (k=9).

Programs

  • Mathematica
    f[n_] := Union[ Flatten[ RealDigits[ 1/n][[1]] ]]; Select[ Range@ 125, MemberQ[f@#, 2] &]

A353439 Integers m such that the decimal expansion of 1/m contains the digit 3.

Original entry on oeis.org

3, 12, 13, 17, 19, 23, 26, 27, 28, 29, 30, 31, 32, 33, 34, 38, 41, 42, 43, 46, 47, 48, 49, 51, 52, 53, 57, 58, 59, 61, 62, 63, 65, 67, 68, 69, 71, 72, 73, 74, 75, 76, 81, 83, 85, 87, 88, 89, 92, 93, 94, 95, 97, 98, 102, 103, 104, 105, 106, 107, 109, 113, 114, 115, 116
Offset: 1

Views

Author

Keywords

Comments

If m is a term, 10*m is also a term, so terms with no trailing zeros are all primitive terms.

Examples

			m = 12 is a term since 1/12 = 0.083333333333... (here, 3 is the smallest digit).
m = 13 is a term since 1/13 = 0.076923076923...
m = 75 is a term since 1/15 = 0.013333333333... (here, 3 is the largest digit).
		

Crossrefs

A350814 (largest digit=3) and A352157 (smallest digit=3) are subsequences.
Similar with digit k: A352154 (k=0), A353437 (k=1), A353438 (k=2), this sequence (k=3), A353440 (k=4), A353441 (k=5), A353442 (k=6), A353443 (k=7), A353444 (k=8), A333237 (k=9).

Programs

  • Mathematica
    f[n_] := Union[ Flatten[ RealDigits[ 1/n][[1]] ]]; Select[ Range@ 125, MemberQ[f@#, 3] &]

A353440 Integers m such that the decimal expansion of 1/m contains the digit 4.

Original entry on oeis.org

7, 14, 17, 19, 21, 22, 23, 24, 25, 26, 28, 29, 31, 34, 35, 38, 39, 41, 43, 46, 47, 49, 51, 53, 56, 57, 58, 59, 61, 62, 65, 67, 68, 69, 70, 71, 76, 79, 81, 83, 84, 85, 86, 87, 89, 92, 93, 94, 95, 96, 97, 98, 102, 103, 104, 106, 107, 109, 112, 113, 114, 115, 116, 117, 118
Offset: 1

Views

Author

Keywords

Comments

If m is a term, 10*m is also a term, so terms with no trailing zeros are all primitive terms.

Examples

			m = 14 is a term since 1/14 = 0.0714285714285...
m = 22 is a term since 1/22 = 0.04545454545... (here, 4 is the smallest digit).
m = 693 is a term since 1/693 = 0.001443001443... (here, 4 is the largest digit).
		

Crossrefs

A351470 (largest digit=4) and A352158 (smallest digit=4) are subsequences.
Similar with digit k: A352154 (k=0), A353437 (k=1), A353438 (k=2), A353439 (k=3), this sequence (k=4), A353441 (k=5), A353442 (k=6), A353443 (k=7), A353444 (k=8), A333237 (k=9).

Programs

  • Mathematica
    f[n_] := Union[ Flatten[ RealDigits[ 1/n][[1]] ]]; Select[ Range@ 125, MemberQ[f@#, 4] &]

A353442 Integers m such that the decimal expansion of 1/m contains the digit 6.

Original entry on oeis.org

6, 13, 15, 16, 17, 19, 21, 23, 24, 26, 29, 31, 34, 38, 39, 46, 47, 49, 51, 52, 53, 57, 58, 59, 60, 61, 62, 64, 65, 68, 69, 71, 73, 76, 79, 81, 83, 84, 85, 86, 87, 88, 89, 92, 93, 94, 95, 96, 97, 98, 102, 103, 104, 106, 107, 109, 113, 114, 115, 116, 118, 119, 121, 122, 124, 126
Offset: 1

Views

Author

Keywords

Comments

If m is a term, 10*m is also a term, so terms with no trailing zeros are all primitive terms.

Examples

			m = 6 is a term since 1/6 = 0.16666666666...
m = 13 is a term since 1/13 = 0.076923076923...
m = 103125 is a term since 1/103125 = 0.00000969696...
		

Crossrefs

A351472 (largest digit=6) and A352160 (smallest digit=6) are subsequences.
Similar with digit k: A352154 (k=0), A353437 (k=1), A353438 (k=2), A353439 (k=3), A353440 (k=4), A353441 (k=5), this sequence (k=6), A353443 (k=7), A353444 (k=8), A333237 (k=9).

Programs

  • Mathematica
    f[n_] := Union[ Flatten[ RealDigits[ 1/n][[1]] ]]; Select[ Range@ 150, MemberQ[f@#, 6] &]
Showing 1-10 of 19 results. Next