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

A286366 Compound filter: a(n) = 2*A286365(n) + floor(A072400(n)/4).

Original entry on oeis.org

4, 6, 8, 4, 13, 11, 9, 6, 28, 14, 8, 8, 13, 11, 21, 4, 12, 30, 8, 13, 65, 11, 9, 11, 40, 14, 116, 9, 13, 23, 9, 6, 64, 14, 20, 28, 13, 11, 21, 14, 12, 66, 8, 8, 49, 11, 9, 8, 28, 42, 20, 13, 13, 119, 21, 11, 64, 14, 8, 21, 13, 11, 269, 4, 84, 66, 8, 12, 65, 23, 9, 30, 12, 14, 56, 8, 65, 23, 9, 13, 484, 14, 8, 65, 85, 11, 21, 11, 12, 50, 20, 9, 65, 11, 21, 11
Offset: 1

Views

Author

Antti Karttunen, May 08 2017

Keywords

Comments

Each term of this sequence contains, in addition to the information contained in A286365 (which packs the values of A286361(n) and A286363(n) and parity of the exponent of the highest power of 2 dividing n) also the bit-2 of A072400(n) (its third least significant bit), which is here stored as the least significant bit of a(n). Note that the whole A072400(n) can be recovered based on the other information contained in a(n). Together all this information is enough - by Lagrange's "Four Squares theorem" - to determine what is the least number of squares that add up to n. Thus it follows that for all i, j: a(i) = a(j) => A002828(i) = A002828(j).
A286369 is similar, but without the parity of the 2-adic value present.

Crossrefs

Programs

  • Python
    from sympy import factorint
    from operator import mul
    def P(n):
        f = factorint(n)
        return sorted([f[i] for i in f])
    def a046523(n):
        x=1
        while True:
            if P(n) == P(x): return x
            else: x+=1
    def A(n, k):
        f = factorint(n)
        return 1 if n == 1 else reduce(mul, [1 if i%4==k else i**f[i] for i in f])
    def T(n, m): return ((n + m)**2 - n - 3*m + 2)/2
    def a286364(n): return T(a046523(n/A(n, 1)), a046523(n/A(n, 3)))
    def a007814(n): return 1 + bin(n - 1)[2:].count("1") - bin(n)[2:].count("1")
    def a286365(n): return 2*a286364(n) + a007814(n)%2
    def a072400(n): return int(str(int(''.join(map(str, digits(n, 4)[1:]))[::-1]))[::-1], 4)%8
    def a(n): return 2*a286365(n) + int(a072400(n)/4) # Indranil Ghosh, May 09 2017
  • Scheme
    (define (A286366 n) (+ (* 2 (A286365 n)) (floor->exact (/ (A072400 n) 4))))
    

Formula

a(n) = 2*A286365(n) + floor(A072400(n)/4).

A286361 Least number with the same prime signature as {the largest divisor of n with only prime factors of the form 4k+1} has: a(n) = A046523(A170818(n)).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 1, 1, 2, 1, 1, 2, 1, 2, 1, 2, 1, 1, 2, 1, 1, 1, 1, 4, 2, 1, 1, 2, 2, 1, 1, 1, 2, 2, 1, 2, 1, 2, 2, 2, 1, 1, 1, 2, 1, 1, 1, 1, 4, 2, 2, 2, 1, 2, 1, 1, 2, 1, 2, 2, 1, 1, 1, 6, 1, 1, 2, 1, 2, 1, 1, 2, 2, 4, 1, 1, 2, 1, 2, 1, 2, 1, 1, 6, 1, 2, 1, 2, 2, 2, 1, 1, 1, 2, 1, 2, 1, 1, 4, 2, 2, 1, 2, 2, 2, 1, 1, 2, 2, 2, 1, 2, 1, 2, 2, 2, 1, 2, 2
Offset: 1

Views

Author

Antti Karttunen, May 08 2017

Keywords

Crossrefs

Differs from A063014 for the first time at n=25, where a(25) = 4, while A063014(25) = 3.

Programs

  • Python
    from sympy import factorint
    from operator import mul
    def P(n):
        f = factorint(n)
        return sorted([f[i] for i in f])
    def a046523(n):
        x=1
        while True:
            if P(n) == P(x): return x
            else: x+=1
    def a072438(n):
        f = factorint(n)
        return 1 if n == 1 else reduce(mul, [1 if i%4==1 else i**f[i] for i in f])
    def a(n): return a046523(n/a072438(n)) # Indranil Ghosh, May 09 2017
  • Scheme
    (define (A286361 n) (A046523 (A170818 n)))
    

Formula

a(n) = A046523(A170818(n)).
a(n) = A286363(A267099(n)).

A286363 Least number with the same prime signature as {the largest divisor of n with only prime factors of the form 4k+3} has: a(n) = A046523(A097706(n)).

Original entry on oeis.org

1, 1, 2, 1, 1, 2, 2, 1, 4, 1, 2, 2, 1, 2, 2, 1, 1, 4, 2, 1, 6, 2, 2, 2, 1, 1, 8, 2, 1, 2, 2, 1, 6, 1, 2, 4, 1, 2, 2, 1, 1, 6, 2, 2, 4, 2, 2, 2, 4, 1, 2, 1, 1, 8, 2, 2, 6, 1, 2, 2, 1, 2, 12, 1, 1, 6, 2, 1, 6, 2, 2, 4, 1, 1, 2, 2, 6, 2, 2, 1, 16, 1, 2, 6, 1, 2, 2, 2, 1, 4, 2, 2, 6, 2, 2, 2, 1, 4, 12, 1, 1, 2, 2, 1, 6, 1, 2, 8, 1, 2, 2, 2, 1, 6, 2, 1, 4, 2, 2, 2
Offset: 1

Views

Author

Antti Karttunen, May 08 2017

Keywords

Crossrefs

Programs

  • Python
    from sympy import factorint
    from operator import mul
    def P(n):
        f = factorint(n)
        return sorted([f[i] for i in f])
    def a046523(n):
        x=1
        while True:
            if P(n) == P(x): return x
            else: x+=1
    def a072436(n):
        f = factorint(n)
        return 1 if n == 1 else reduce(mul, [1 if i%4==3 else i**f[i] for i in f])
    def a(n): return a046523(n/a072436(n)) # Indranil Ghosh, May 09 2017
  • Scheme
    (define (A286363 n) (A046523 (A097706 n)))
    

Formula

a(n) = A046523(A097706(n)).
a(n) = A286361(A267099(n)).

A286364 Compound filter: a(n) = P(A286361(n), A286363(n)), where P(n,k) is sequence A000027 used as a pairing function.

Original entry on oeis.org

1, 1, 2, 1, 3, 2, 2, 1, 7, 3, 2, 2, 3, 2, 5, 1, 3, 7, 2, 3, 16, 2, 2, 2, 10, 3, 29, 2, 3, 5, 2, 1, 16, 3, 5, 7, 3, 2, 5, 3, 3, 16, 2, 2, 12, 2, 2, 2, 7, 10, 5, 3, 3, 29, 5, 2, 16, 3, 2, 5, 3, 2, 67, 1, 21, 16, 2, 3, 16, 5, 2, 7, 3, 3, 14, 2, 16, 5, 2, 3, 121, 3, 2, 16, 21, 2, 5, 2, 3, 12, 5, 2, 16, 2, 5, 2, 3, 7, 67, 10, 3, 5, 2, 3, 23, 3, 2, 29, 3, 5, 5, 2, 3
Offset: 1

Views

Author

Antti Karttunen, May 08 2017

Keywords

Comments

This sequence packs the values of A286361(n) and A286363(n) to a single value with the pairing function A000027. These two components essentially give the prime signature of 4k+1 part and the prime signature of 4k+3 part, and they can be accessed from a(n) with functions A002260 and A004736. For example, A004431 lists all such numbers that the first component is larger than one and the second component is a perfect square.

Crossrefs

Programs

  • Python
    from sympy import factorint
    from operator import mul
    def P(n):
        f = factorint(n)
        return sorted([f[i] for i in f])
    def a046523(n):
        x=1
        while True:
            if P(n) == P(x): return x
            else: x+=1
    def A(n, k):
        f = factorint(n)
        return 1 if n == 1 else reduce(mul, [1 if i%4==k else i**f[i] for i in f])
    def T(n, m): return ((n + m)**2 - n - 3*m + 2)/2
    def a(n): return T(a046523(n/A(n, 1)), a046523(n/A(n, 3))) # Indranil Ghosh, May 09 2017
  • Scheme
    (define (A286364 n) (* (/ 1 2) (+ (expt (+ (A286361 n) (A286363 n)) 2) (- (A286361 n)) (- (* 3 (A286363 n))) 2)))
    

Formula

a(n) = (1/2)*(2+((A286361(n)+A286363(n))^2) - A286361(n) - 3*A286363(n)).
Other identities. For all n >= 1:
a(A267099(n)) = A038722(a(n)).

A286362 Compound filter: a(n) = P(A089309(n), A046523(n)), where P(n,k) is sequence A000027 used as a pairing function.

Original entry on oeis.org

1, 2, 5, 7, 2, 23, 9, 29, 7, 16, 5, 80, 2, 31, 40, 121, 2, 67, 5, 67, 16, 23, 9, 302, 7, 16, 38, 94, 2, 532, 20, 497, 16, 16, 23, 631, 2, 23, 31, 277, 2, 436, 5, 80, 67, 31, 14, 1178, 7, 67, 23, 67, 2, 302, 31, 328, 16, 16, 5, 1957, 2, 50, 142, 2017, 16, 436, 5, 67, 16, 467, 9, 2557, 2, 16, 80, 80, 16, 499, 14, 1129, 121, 16, 5, 1771, 16, 23, 31, 302, 2, 1771
Offset: 1

Views

Author

Antti Karttunen, May 08 2017

Keywords

Comments

For all odd i, odd j: a(i) = a(j) <=> A286251(i) = A286251(j).

Crossrefs

Programs

Formula

a(n) = (1/2)*(2 + ((A089309(n)+A046523(n))^2) - A089309(n) - 3*A046523(n)).

A286367 Compound filter: a(n) = P(A001511(n), A286364(n)), where P(n,k) is sequence A000027 used as a pairing function.

Original entry on oeis.org

1, 3, 2, 6, 4, 5, 2, 10, 22, 8, 2, 9, 4, 5, 11, 15, 4, 30, 2, 13, 121, 5, 2, 14, 46, 8, 407, 9, 4, 17, 2, 21, 121, 8, 11, 39, 4, 5, 11, 19, 4, 138, 2, 9, 67, 5, 2, 20, 22, 57, 11, 13, 4, 437, 11, 14, 121, 8, 2, 24, 4, 5, 2212, 28, 211, 138, 2, 13, 121, 17, 2, 49, 4, 8, 92, 9, 121, 17, 2, 26, 7261, 8, 2, 156, 211, 5, 11, 14, 4, 80, 11, 9, 121, 5, 11, 27, 4, 30
Offset: 1

Views

Author

Antti Karttunen, May 08 2017

Keywords

Comments

This sequence contains, in addition to the information contained in A286364 (which packs the values of A286361(n) and A286363(n) to a single value with the pairing function A000027), also the highest power of 2 dividing n. Note that this is more information than A286365, as it stores only the parity of the exponent of 2.
For all i, j: a(i) = a(j) => A286161(i) = A286161(j).

Crossrefs

Programs

  • Python
    from sympy import factorint
    from operator import mul
    def P(n):
        f = factorint(n)
        return sorted([f[i] for i in f])
    def a046523(n):
        x=1
        while True:
            if P(n) == P(x): return x
            else: x+=1
    def A(n, k):
        f = factorint(n)
        return 1 if n == 1 else reduce(mul, [1 if i%4==k else i**f[i] for i in f])
    def T(n, m): return ((n + m)**2 - n - 3*m + 2)/2
    def a286364(n): return T(a046523(n/A(n, 1)), a046523(n/A(n, 3)))
    def a001511(n): return 2 + bin(n - 1)[2:].count("1") - bin(n)[2:].count("1")
    def a(n): return T(a001511(n), a286364(n)) # Indranil Ghosh, May 09 2017
  • Scheme
    (define (A286367 n) (* (/ 1 2) (+ (expt (+ (A001511 n) (A286364 n)) 2) (- (A001511 n)) (- (* 3 (A286364 n))) 2)))
    

Formula

a(n) = (1/2)*(2 + ((A001511(n)+A286364(n))^2) - A001511(n) - 3*A286364(n)).
Showing 1-6 of 6 results.