/-
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.
-/importFormalConjecturesUtil
Riesel Problem
Riesel problem: let $k=2n-1$; then $a(n)$ is the smallest $m \ge 1$ such that
$k \cdot 2^m-1$ is prime, or $-1$ if no such prime exists.
The primary defining sequence a.
Riesel problem: let $k=2n-1$; then $a(n)$ is the smallest $m \ge 1$ such that
$k \cdot 2^m-1$ is prime, or $-1$ if no such prime exists.
noncomputabledefa(n:ℕ):ℤ:=ifn=0then0-- Use classical choice to find the minimum, or return -1 if no such prime exists.elseifh:∃m,m≠0∧((2*n-1)*2^m-1).PrimethenNat.findhelse-1All goals completed! 🐙@[categorytest,AMS11]theorema_1:a1=2:=a_of_isLeast<|by⊢ IsLeast{m|m≠0∧Nat.Prime((2*1-1)*2^m-1)}2decideAll goals completed! 🐙@[categorytest,AMS11]theorema_2:a2=1:=a_of_isLeast<|by⊢ IsLeast{m|m≠0∧Nat.Prime((2*2-1)*2^m-1)}1decideAll goals completed! 🐙@[categorytest,AMS11]theorema_3:a3=2:=a_of_isLeast<|by⊢ IsLeast{m|m≠0∧Nat.Prime((2*3-1)*2^m-1)}2decideAll goals completed! 🐙@[categorytest,AMS11]theorema_4:a4=1:=a_of_isLeast<|by⊢ IsLeast{m|m≠0∧Nat.Prime((2*4-1)*2^m-1)}1decideAll goals completed! 🐙
It is conjectured that the integer $k = 509203$ is the smallest Riesel number,
that is, the first $n$ such that $a(n) = -1$ is $254602$.