Updated 17 Oct 2019
This code take advantage of Hamid Naderi Yeganeh's wonderful parametric curves that describe oak and maple leaf shapes  and MATLAB's built-in Autumn colormap.
After using some randomization on the colors chosen within the colormap, the leaf coordinate, and leaf angle, we have ourrselves a nice little leaf pile generator! Why wait until Mid October when you can experience those beautiful few weeks all year round within the comfort of your MATLAB console?
 Hamid Naderi Yeganeh, Scientific American, March 16 2017, https://blogs.scientificamerican.com/guest-blog/how-to-draw-with-math/
Nathaniel Barlow (2023). leafpile (https://www.mathworks.com/matlabcentral/fileexchange/72880-leafpile), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform CompatibilityWindows macOS Linux
Inspired: leafpile3D -- minor mods
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.