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

A281066 Concatenation R(n)R(n-1)R(n-2)...R(2)R(1) read mod n, where R(x) is the digit-reversal of x (with leading zeros not omitted).

Original entry on oeis.org

0, 1, 0, 1, 1, 3, 3, 1, 0, 1, 4, 9, 5, 7, 6, 1, 6, 9, 17, 1, 15, 15, 19, 9, 21, 1, 18, 13, 28, 21, 26, 17, 15, 3, 16, 9, 30, 3, 15, 1, 1, 33, 10, 37, 36, 43, 22, 33, 19, 21, 48, 45, 2, 45, 26, 49, 27, 33, 33, 21, 48, 25, 36, 49, 36, 15, 22, 5, 27, 11, 42, 9, 2, 73, 21, 17, 59, 57, 5, 1
Offset: 1

Views

Author

Robert G. Wilson v, Jan 14 2017

Keywords

Examples

			a(13) = 31211101987654321 (mod 13) = 5.
		

Crossrefs

Programs

  • Mathematica
    f[n_] := Mod[ FromDigits@ Fold[ Join[ Reverse@ IntegerDigits@#2, #1] &, {}, Range@ n], n]; Array[f, 80]
  • PARI
    a(n) = my(s = ""); forstep (k=n,1,-1, sk = digits(k); forstep (j=#sk, 1, -1, s = concat(s, sk[j]))); eval(s) % n; \\ Michel Marcus, Jan 28 2017
  • Python
    def A281066(n):
        s=""
        for i in range(n, 0, -1):
            s+=str(i)[::-1]
        return int(s)%n # Indranil Ghosh, Jan 28 2017
    

Formula

a(n) = A138793(n) (mod n).

A280987 {Concatenation n, n-1, n-2, ...3,2,1} mod sigma(n).

Original entry on oeis.org

0, 0, 1, 2, 3, 9, 1, 6, 4, 1, 9, 21, 1, 9, 9, 16, 9, 24, 1, 33, 17, 1, 9, 21, 0, 9, 1, 41, 21, 33, 17, 6, 33, 19, 33, 25, 25, 21, 1, 1, 33, 81, 17, 21, 45, 1, 33, 85, 49, 69, 57, 77, 27, 81, 1, 81, 1, 1, 21, 57, 59, 81, 33, 60, 21, 33, 45, 51, 81, 1, 9, 66, 41, 9, 97, 1, 81, 81, 1, 57, 117, 73, 33, 145
Offset: 1

Views

Author

Indranil Ghosh, Jan 12 2017

Keywords

Examples

			For n = 11, A000422(n) mod sigma(n) = 1110987654321 mod 12 = 9. S0 a(11) = 9.
		

Crossrefs

Programs

  • Mathematica
    Table[Mod[FromDigits[Flatten[IntegerDigits/@Range[n,1,-1]]],DivisorSigma[ 1,n]],{n,90}] (* Harvey P. Dale, Jul 01 2020 *)
  • Python
    def sigma(n):
        s=0
        for i in range(1,n+1):
            if n%i==0:
                s+=i
        return s
    def C(n):
        s=""
        for i in range(n,0,-1):
            s+=str(i)
        return int(s)
    for i in range(1,101):
        print(i, C(i)%sigma(i))
    
  • Python
    from sympy import divisor_sigma
    def A280987(n): return int(''.join(map(str, range(n, 0, -1)))) % divisor_sigma(n) # David Radcliffe, Aug 08 2025

Formula

a(n) = A000422(n) mod A000203(n).

A281190 Concatenation of the reversed digits of numbers from 1 to n, mod n.

Original entry on oeis.org

0, 0, 0, 2, 0, 0, 5, 6, 0, 1, 6, 9, 3, 1, 6, 9, 5, 9, 1, 2, 18, 6, 12, 18, 2, 6, 18, 26, 7, 3, 20, 27, 6, 3, 28, 27, 7, 19, 12, 24, 4, 24, 12, 28, 9, 8, 42, 12, 22, 5, 3, 45, 41, 45, 50, 45, 45, 23, 16, 6, 6, 54, 27, 30, 61, 6, 37, 30, 21, 67, 47, 63, 52, 67, 57, 19, 28, 15, 58, 28, 72, 22, 56, 24, 83, 34, 3, 72, 72, 9, 85, 69, 57
Offset: 1

Views

Author

Robert G. Wilson v, Jan 16 2017

Keywords

Comments

Note that leading zeros are not omitted when numbers are reversed. - N. J. A. Sloane, Jan 23 2017

Examples

			a(13) = A138957(13) mod 13 == 12345678901112131 mod 13 == 3.
		

Crossrefs

Programs

  • Mathematica
    f[n_] := Mod[ Fold[#1*10^IntegerLength@#2 + FromDigits@ Reverse@ IntegerDigits@#2 &, 0, Range@ n], n]; Array[f, 105]
  • PARI
    a(n) = my(s = ""); for (k=1, n, sk = digits(k); forstep (j=#sk, 1, -1, s = concat(s, sk[j]))); eval(s) % n; \\ Michel Marcus, Jan 28 2017
  • Python
    def A281190(n):
        s=""
        for i in range(1,n+1):
            s+=str(i)[::-1]
        return int(s)%n # Indranil Ghosh, Jan 28 2017
    

Formula

a(n) = A138957(n) mod n.
Showing 1-3 of 3 results.