Library for drawing spirographs in Python
Project description
spyrograph: elegant mathematics and geometries
What is it?
spyrograph is a lightweight Python package that provides an expressive and flexible set of tools for drawing beautiful mathematically driven art. With just a few lines of easy-to-read code you can start analyzing, visualizing, and exploring elegant mathematics
Table of Contents
:key: Key features
- Expressive and consistent syntax
- Robust underlying mathematics
- Beginner and expert friendly
numpy
is the only required third-party installation- Clear visualizations and animations
- Flexible to a wide range of usecases
- Lightweight, just plug and play
:computer: Installation
pip
Install the latest stable release from PyPI using
$ pip3 install spyrograph
or clone the development version from GitHub with
$ git clone https://github.com/chris-greening/spyrograph.git
:seedling: Quickstart
spyrograph
is designed to be expressive and easy-to-use - simply import spyrograph
and jump right into drawing elegant, complex shapes in just a few lines of code!
from spyrograph import Hypotrochoid
# Trace a hypotrochoid from 0 to 2pi where
# the fixed circle radius is 300, rolling circle
# radius is 200, and the distance from the rolling
# circle is 100
hypotrochoid = Hypotrochoid(
R=300,
r=200,
d=100,
thetas=np.arange(0, 2*np.pi, .1)
)
hypotrochoid.trace(
show_circles=True,
frame_pause=.05,
circle_color="grey"
)
:pray: Contributing
All contributions, bug reports, bug fixes, documentation improvements, enhancements, and ideas are welcome!
Feel free to open an Issue, check out existing Issues, or start a discussion.
Beginners to open source are highly encouraged to participate and ask questions if you're unsure what to do/where to start
:newspaper: Blog posts
Check out the official website for the latest blog posts on the project!
- Draw beautiful geometric visualizations with Python and spyrograph
- Configuring the trace method to explore stunning spirographs in Python
- Creating a range of hypotrochoids with the create_range method
- Plotting beautiful spirographs with matplotlib and spyrograph
- Drawing cycloids with a specific number of cusps using spyrograph
- Scaling trochoid’s and cycloid’s input parameters with the spyrograph scale method
- Spyrograph is looking for beginners to open source to contribute!
- Creating mesmerizing spirograph animations with Python and Spyrograph
- Adding a boomerang effect to our spirograph animations
- Tracing multiple shapes on the same screen with Spyrograph
- Customizing the origin of our geometric visualizations using Python and Spyrograph
- Unlock the power of method chaining for elegant and efficient Spyrograph transformations
:books: Documentation
The official documentation can be found on Read The Docs
:credit_card: License
This library operates under the MIT license.
:grey_question: Support
Reach out to me if you want to connect or have any questions and I will do my best to get back to you
- Email:
- Twitter:
- Personal contact form:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for spyrograph-0.29.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8083f3c98e5c69a91c173c71fc7e57f761b8e8ad56a055f5e0e866f4988ed1d3 |
|
MD5 | b357eb28785b5c168005bc11eea5d31b |
|
BLAKE2b-256 | e3fe2e20eb53f29cddce6710311a01bb697a9c87eefc96820d5877d51eb72ac1 |