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.

A361197 a(n) is the number of equations in the set {x^2 + 2y^2 = n, 2x^2 + 3y^2 = n, ..., k*x^2 + (k+1)*y^2 = n, ..., n*x^2 + (n+1)*y^2 = n} which admit at least one nonnegative integer solution.

Original entry on oeis.org

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

Views

Author

Luca Onnis, Mar 04 2023

Keywords

Comments

Compared to the "linear" case given by A356770, the "quadratic" case given by this sequence has a more chaotic behavior.
a(n) >= 2 for all n > 1 since (n-1)*x^2 + n*y^2 = n and n*x^2 + (n+1)*y^2 = n always admit one integer solution (respectively (0,1) and (1,0)).
Conjecture: a(n) = 2 for infinitely many n.

Examples

			a(5) = 3. Consider the equations: x^2 + 2y^2 = 5, 2x^2 + 3y^2 = 5, 3x^2 + 4y^2 = 5, 4x^2 + 5y^2 = 5, 5x^2 + 6y^2 = 5. Only three of them admit at least one nonnegative integer solution, since 3x^2 + 4y^2 = 5 and x^2 + 2y^2 = 5 have no nonnegative integer solutions.
		

Crossrefs

Cf. A356770.

Programs

  • Mathematica
    b[m_] := m;
    f[n_] := Table[Dimensions[Solve[b[k]*x^2 + b[k + 1]*y^2 == n, {x, y}, NonNegativeIntegers]][[1]], {k, 1, n}];