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

A132726 Triangle read by rows: T(n,k) = length of period in decimal representation of k/n, 1<=k<=n.

Original entry on oeis.org

0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 6, 6, 6, 6, 6, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 0, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 0, 6, 6, 6, 6, 6, 6, 0, 6, 6, 6, 6, 6, 6, 0
Offset: 1

Views

Author

Reinhard Zumkeller, Aug 27 2007

Keywords

Comments

T(n,1) = A051626(n); T(n,n) = 0;
T(n,k) = T(1,k/A050873(n,k));
T(n,k) = T(n,A132740(k)), 1<=k<=n;
T(A003592(n),k) = 0, 1<=k<=A003592(n).

A173484 a(n) = the smallest number ending in n+1 zeros divisible by n.

Original entry on oeis.org

100, 1000, 30000, 100000, 1000000, 30000000, 700000000, 1000000000, 90000000000, 100000000000, 11000000000000, 30000000000000, 1300000000000000, 7000000000000000, 30000000000000000
Offset: 1

Views

Author

Jaroslav Krizek, Mar 04 2010

Keywords

Comments

Crossrefs

Cf. A132740.

Programs

  • Maple
    f:= n -> 10^(n+1)*n/2^padic:-ordp(n,2)/5^padic:-ordp(n,5):
    map(f, [$1..30]); # Robert Israel, Jun 28 2018

Formula

a(n) = 10^(n+1)*A132740(n). - Robert Israel, Jun 28 2018

A370757 a(n) is the least k > 0 such that 1/n and 1/k have equivalent repeating decimal digits.

Original entry on oeis.org

1, 1, 3, 1, 1, 6, 7, 1, 9, 1, 11, 3, 13, 7, 6, 1, 17, 18, 19, 1, 21, 22, 23, 6, 1, 26, 27, 7, 29, 3, 31, 1, 33, 17, 7, 36, 37, 19, 39, 1, 41, 42, 43, 44, 45, 23, 47, 3, 49, 1, 51, 13, 53, 54, 55, 7, 57, 29, 59, 6, 61, 31, 63, 1, 26, 66, 67, 17, 69, 7, 71, 72
Offset: 1

Views

Author

Rémy Sigrist, Feb 29 2024

Keywords

Comments

In other words, a(n) is the least k > 0 such that the fractional parts of (10^i)/n and (10^j)/k are equal for some integers i, j.
a(n) is not always a divisor of n. For example, a(65) = 26 is not a divisor of 65. - David A. Corneth, Mar 01 2024

Examples

			The first terms, alongside the decimal expansion of 1/n with its repeating decimal digits in parentheses, are:
  n   a(n)  1/n
  --  ----  -----------
   1     1  1.(0)
   2     1  0.5(0)
   3     3  0.(3)
   4     1  0.25(0)
   5     1  0.2(0)
   6     6  0.1(6)
   7     7  0.(142857)
   8     1  0.125(0)
   9     9  0.(1)
  10     1  0.1(0)
  11    11  0.(09)
  12     3  0.08(3)
  13    13  0.(076923)
  14     7  0.07(142857)
  15     6  0.0(6)
		

Crossrefs

Cf. A000265 (base-2 analog), A038502 (base-3 analog), A132739 (base-5 analog), A242603 (base-7 analog).

Programs

  • PARI
    \\ See Links section.
    
  • Python
    from itertools import count
    from sympy import multiplicity, n_order
    def A370757(n):
        m2, m5 = (~n & n-1).bit_length(), multiplicity(5,n)
        r = max(m2,m5)
        w, m = 10**r, 10**(t:=n_order(10,n2) if (n2:=(n>>m2)//5**m5)>1 else 1)-1
        c = w//n
        s = str(m*w//n-c*m).zfill(t)
        l = len(s)
        for k in count(1):
            m2, m5 = (~k & k-1).bit_length(), multiplicity(5,k)
            r = max(m2,m5)
            w, m = 10**r, 10**(t:=n_order(10,k2) if (k2:=(k>>m2)//5**m5)>1 else 1)-1
            c = w//k
            if any(s[i:]+s[:i] == str(m*w//k-c*m).zfill(t) for i in range(l)):
                return k # Chai Wah Wu, Mar 03 2024

Formula

a(n) = 1 iff n belongs to A003592.
a(10*n) = a(n).
A007732(a(n)) = A007732(n).

A245570 Rectangular array A read by (upward) antidiagonals: A(n,k) = n/gcd(n,10^k), n,k >= 1.

Original entry on oeis.org

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

Views

Author

L. Edson Jeffery, Jul 25 2014

Keywords

Comments

Columns of A converge to A132740.

Examples

			Array A begins:
  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, ...
  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, ...
  3, 3, 3, 3, 3, 3, 3, 3, 3, 3, ...
  2, 1, 1, 1, 1, 1, 1, 1, 1, 1, ...
  1, 1, 1, 1, 1, 1, 1, 1, 1, 1, ...
  3, 3, 3, 3, 3, 3, 3, 3, 3, 3, ...
  7, 7, 7, 7, 7, 7, 7, 7, 7, 7, ...
  4, 2, 1, 1, 1, 1, 1, 1, 1, 1, ...
  9, 9, 9, 9, 9, 9, 9, 9, 9, 9, ...
  ...
		

Crossrefs

Cf. A132740.

Programs

  • Mathematica
    Grid[Table[n/GCD[n, 10^k], {n, 12}, {k, 12}]] (* Array *)
    Flatten[Table[(n - k + 1)/GCD[n - k + 1, 10^k], {n, 13}, {k, n}]] (* Array antidiagonals flattened *)

A357756 a(n) is the least k > 0 such that A007953(n*k) equals A007953((n*k)^2), where A007953 is the sum of the digits.

Original entry on oeis.org

1, 1, 5, 3, 25, 2, 3, 27, 62, 1, 1, 5, 15, 27, 128, 3, 31, 17, 1, 1, 5, 9, 9, 2, 75, 4, 18, 7, 64, 5, 3, 16, 56, 3, 85, 17, 5, 27, 5, 9, 25, 9, 45, 13, 27, 1, 1, 27, 66, 54, 2, 9, 9, 18, 22, 1, 32, 15, 25, 135, 3, 18, 8, 3, 28, 9, 3, 43, 47, 72, 27, 8, 25, 126, 27
Offset: 0

Views

Author

Thomas Scheuerle, Oct 12 2022

Keywords

Comments

A task in the German competition "Bundeswettbewerb Mathematik 2021" was to prove that for each positive integer n there exists a k such that A007953(n*k) = A007953((n*k)^2).
One of the proposed proofs uses the argument that numbers of the form m = (10^x-1)*(10^y) will have the desired property A007953(m) = A007953(m^2). Thus we need to prove that we can find for all n a k, x and y such that n*k = (10^x-1)*(10^y). Let n be of the form b*2^c*5^d with b odd and not divisible by 5, then we know that y = max(c, d). From Euler's totient theorem we know that 10^x-1 will be divisible by e if x = A000010(e) where A000010 is Euler's totient function. See the formula section for the corresponding resulting k.
a(n) will never be divisible by 10.
If n is divisible by 3 but not by 9, then a(n) is divisible by 3. - Robert Israel, Oct 13 2022

Crossrefs

Programs

  • Maple
    f:= proc(n) local k;
       for k from 1 do if sd(n*k) = sd((n*k)^2) then return k fi od
    end proc:
    map(f, [$1..100]); # Robert Israel, Oct 13 2022
  • PARI
    a(n) = {my(k = 1); while(sumdigits(n*k)!=sumdigits((n*k)^2),k++);k}
    
  • Python
    def sd(n): return sum(map(int, str(n)))
    def a(n):
        k = 1
        while not sd(n*k) == sd((n*k)**2): k += 1
        return k
    print([a(n) for n in range(75)]) # Michael S. Branicky, Oct 13 2022

Formula

a(A058369(n)) = 1.
a(a(n)) <= n.
a(n) <= A132740(n)*A060284(A132740(n))*10^A051628(n)/n.
or a(n) <= (10^A000010(A132740(n))-1)*10^A051628(n)/n.
Previous Showing 11-15 of 15 results.