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.

A376756 Number of pairs 0 <= x <= y <= n-1 such that x^2 + x*y + y^2 == 0 (mod n).

Original entry on oeis.org

1, 1, 3, 3, 1, 3, 7, 3, 6, 1, 1, 9, 13, 7, 3, 10, 1, 6, 19, 3, 21, 1, 1, 9, 15, 13, 18, 27, 1, 3, 31, 10, 3, 1, 7, 21, 37, 19, 39, 3, 1, 21, 43, 3, 6, 1, 1, 30, 70, 15, 3, 51, 1, 18, 1, 27, 57, 1, 1, 9, 61, 31, 60, 36, 13, 3, 67, 3, 3, 7, 1, 21, 73, 37, 45, 75, 7, 39, 79, 10, 45, 1, 1, 81, 1, 43, 3, 3, 1, 6, 163, 3, 93, 1, 19, 30, 97
Offset: 1

Views

Author

Tom Duff and N. J. A. Sloane, Oct 06 2024

Keywords

Crossrefs

Programs

  • Python
    def A376756(n):
        c = 0
        for x in range(n):
            z = x**2%n
            for y in range(x,n):
                if not (z+y*(x+y))%n:
                    c += 1
        return c # Chai Wah Wu, Oct 06 2024