Andrica's Conjecture

2 ビュー (過去 30 日間)
Jesús Zambrano
Jesús Zambrano 2024 年 12 月 15 日
編集済み: Torsten 2024 年 12 月 15 日
I'd like to get a simple MATLAB code showing the Andrica's conjecture.
More about it can be found here: Andrica's conjecture - Wikipedia

採用された回答

Torsten
Torsten 2024 年 12 月 15 日
編集済み: Torsten 2024 年 12 月 15 日
Use
nthprime(1:n+1)
to generate the vector of the first n+1 prime numbers.
The rest should be simple.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeDiscrete Math についてさらに検索

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by