/- Copyright 2026 The Formal Conjectures Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. -/ module public import FormalConjecturesUtil

Determinant of Hankel matrix of the first $2n-1$ prime numbers

The determinant of the $n \times n$ Hankel matrix whose entries are the first $2n-1$ prime numbers. The matrix $M$ has entries $M_{i, j} = p_{i+j}$ for $i, j \in {0, \dots, n-1}$, where $p_k = \mathrm{Nat.nth;Nat.Prime} (k)$ is the $k$-th prime starting at $p_0=2$. $a(0)=1$ by convention.

References:

@[expose] public sectionnamespace OeisA24356

The determinant of the $n \times n$ Hankel matrix of primes.

noncomputable def a (n : ) : := Matrix.det (Matrix.of fun (i j : Fin n) (Nat.nth Nat.Prime (i.val + j.val) : ))

Value of the sequence a at 0.

@[category test, AMS 11] theorem a_0 : a 0 = 1 := a 0 = 1 All goals completed! 🐙

Value of the sequence a at 1.

@[category test, AMS 11] theorem a_1 : a 1 = 2 := a 1 = 2 All goals completed! 🐙

Value of the sequence a at 2.

@[category test, AMS 11] theorem a_2 : a 2 = 1 := a 2 = 1 All goals completed! 🐙

Value of the sequence a at 4. This records the zero whose uniqueness is conjectured below.

hp13:Nat.Prime 13hp17:Nat.Prime 17h5:Nat.nth Nat.Prime 5 = 13h6:Nat.nth Nat.Prime 6 = 17hM:(Matrix.of fun i j (Nat.nth Nat.Prime (i + j))) = !![2, 3, 5, 7; 3, 5, 7, 11; 5, 7, 11, 13; 7, 11, 13, 17]!![2, 3, 5, 7; 3, 5, 7, 11; 5, 7, 11, 13; 7, 11, 13, 17].det = 0 hp13:Nat.Prime 13hp17:Nat.Prime 17h5:Nat.nth Nat.Prime 5 = 13h6:Nat.nth Nat.Prime 6 = 17hM:(Matrix.of fun i j (Nat.nth Nat.Prime (i + j))) = !![2, 3, 5, 7; 3, 5, 7, 11; 5, 7, 11, 13; 7, 11, 13, 17]!![2, 3, 5, 7; 3, 5, 7, 11; 5, 7, 11, 13; 7, 11, 13, 17].mulVec ![6, -3, -2, 1] = 0hp13:Nat.Prime 13hp17:Nat.Prime 17h5:Nat.nth Nat.Prime 5 = 13h6:Nat.nth Nat.Prime 6 = 17hM:(Matrix.of fun i j (Nat.nth Nat.Prime (i + j))) = !![2, 3, 5, 7; 3, 5, 7, 11; 5, 7, 11, 13; 7, 11, 13, 17]![6, -3, -2, 1] 0 nonZeroDivisors hp13:Nat.Prime 13hp17:Nat.Prime 17h5:Nat.nth Nat.Prime 5 = 13h6:Nat.nth Nat.Prime 6 = 17hM:(Matrix.of fun i j (Nat.nth Nat.Prime (i + j))) = !![2, 3, 5, 7; 3, 5, 7, 11; 5, 7, 11, 13; 7, 11, 13, 17]!![2, 3, 5, 7; 3, 5, 7, 11; 5, 7, 11, 13; 7, 11, 13, 17].mulVec ![6, -3, -2, 1] = 0 All goals completed! 🐙 hp13:Nat.Prime 13hp17:Nat.Prime 17h5:Nat.nth Nat.Prime 5 = 13h6:Nat.nth Nat.Prime 6 = 17hM:(Matrix.of fun i j (Nat.nth Nat.Prime (i + j))) = !![2, 3, 5, 7; 3, 5, 7, 11; 5, 7, 11, 13; 7, 11, 13, 17]![6, -3, -2, 1] 0 nonZeroDivisors All goals completed! 🐙

"I conjecture that $a(4)$ is the only zero. - Jon Perry, Mar 22 2004"

Stated as a biconditional: the claim that $a(4)$ is the only zero asserts both that $a(4) = 0$ and that no other index vanishes. A bare implication a n = 0 → n = 4 would be satisfied vacuously by a sequence with no zero at all. The existence direction is certified by a_4; the uniqueness direction is the open part.

@[category research open, AMS 11 15] theorem conjecture : n : , a n = 0 n = 4 := (n : ), a n = 0 n = 4 All goals completed! 🐙end OeisA24356