Skip to content

A butterfly curve sketch drawn with p5.js for practice with parametric equations in creative programming.

License

Notifications You must be signed in to change notification settings

lexiortiz/butterfly-curve

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

butterfly-curve

A butterfly curve sketch drawn with p5.js for practice with parametric equations in creative programming.

The butterfly curve is an aesthetically pleasing transcendental plane curve and one of my favorite mathematical equations to turn into code. It took time for me to convert the equations into Javascript and then again with the p5.js library, but overall this exercise was fairly simple!

Butterfly Curve Equations

To learn more about the butterfly curve, visit Wikipedia and MathWorld. These informative sites helped me a bunch, but there were moments when I needed additonal help and had to research furthur. In these moments, I ran to The Coding Train and watched a few resourceful videos on the specific problems I was facing. There are so many helpful tutorials to choose from, but I found these couple videos to help me the most with this project: Polar Coordinates and Mathematical Rose Patterns

Finally, I was playing around with 3D shapes when I accidently developed the look of a gradient background by using a torus shape and enlarging it. I love the use of the torus with the butterfly sketch!

A screenshot of the Butterfly Curve and Gradient Background

See the Pen Butterfly Curve by Lexi ♡ (@huesofheart) on CodePen.

About

A butterfly curve sketch drawn with p5.js for practice with parametric equations in creative programming.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published