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.

A230494 Number of ways to write n = x^2 + y (x, y >= 0) with 2*y^2 - 1 prime.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Oct 20 2013

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 1. Moreover, if n > 1 is not among 2, 69, 76, then there are positive integers x and y such that x^2 + y is equal to n and 2*y^2 - 1 is prime.
(ii) Any integer n > 1 can be written as x*(x+1)/2 + y with 2*y^2 - 1 prime, where x and y are nonnegative integers. Moreover, if n is not equal to 2 or 15, then we may require additionally that x and y are both positive.
We have verified the conjecture for n up to 2*10^7.
Both conjectures verified for n up to 10^9. - Mauro Fiorentini, Aug 08 2023
See also A230351 and A230493 for similar conjectures.

Examples

			a(9) = 1 since 9 = 1^2 + 8 with 2*8^2 - 1 = 127 prime.
a(69) = 1 since 69 = 0^2 + 69 with 2*69^2 - 1 = 9521 prime.
a(76) = 1 since 76 = 0^2 + 76 with 2*76^2 - 1 = 11551 prime.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Sum[If[PrimeQ[2(n-x^2)^2-1],1,0],{x,0,Sqrt[n]}]
    Table[a[n],{n,1,100}]