Frequencies of prime gaps
Version 1.0 (1.09 KB) by
Nicolas Douillet
Function to compute and display the cumulated frequencies of gaps between consecutive prime numbers
Once downloaded, typewrite 'help frequencies_of_prime_gaps' in Matlab console for support.
To benefit from the file documentation attached, be sure to download the files, not to just copy and paste them.
Input
- delta : an even integer >= 2, the choosen gap;
- N : the integer upper limit to sample the vector of primes. N > 3;
Output
- ff : the frequency of delta on the range |[2; N]|;
Exemple below : ff = frequencies_of_prime_gaps(2,101);
Please don't forget to rate if this code helped you to explore gaps between prime numbers ;-). Thanks you !
Cite As
Nicolas Douillet (2024). Frequencies of prime gaps (https://github.com/NicolasDouillet/frequencies_of_prime_gaps/releases/tag/v1.0), GitHub. Retrieved .
MATLAB Release Compatibility
Created with
R2019b
Compatible with any release
Platform Compatibility
Windows macOS LinuxTags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
Version | Published | Release Notes | |
---|---|---|---|
1.0 |
To view or report issues in this GitHub add-on, visit the GitHub Repository.
To view or report issues in this GitHub add-on, visit the GitHub Repository.