Prime numbers spirals
Version 1.1 (3.18 KB) by
Nicolas Douillet
Functions to display prime numbers spiral and prime squares spiral. Also check primes sum and prime squares spiral length.
Input N is an integer scalar, N > 3.
Once downloaded, typewrite 'help pnumbers_spiral' and/or 'help pnumber_squares_spiral' in Matlab console for support.
To benefit from the file documentation attached, be sure to download the file, not to just copy and paste it.
Please don't forget to rate if this code helped you. Thanks ! ;-)
Cite As
Nicolas Douillet (2024). Prime numbers spirals (https://www.mathworks.com/matlabcentral/fileexchange/156916-prime-numbers-spirals), MATLAB Central File Exchange. 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.