GithubHelp home page GithubHelp logo

auxon / mandelb0t Goto Github PK

View Code? Open in Web Editor NEW

This project forked from brobin/mandelb0t

1.0 1.0 1.0 296 KB

:fireworks: Twitter bot that generates an image of the Mandelbrot set

License: BSD 2-Clause "Simplified" License

Python 100.00%

mandelb0t's Introduction

mandelb0t

Mandelb0t is a Twitter bot that generates an image of the Mandelbrot set and posts it to Twitter! Currently it functions as a cron job, running every two hours. Eventually I plan to host it somewhere where it can continuously run and interact with other Twitter users.

####Follow @mandelb0t on Twitter!

Mandelbrot Set

The Mandelbrot Set is a mathematical representation of complex numbers that when rendered can create beautiful images.

Thanks to Andrew Lewis for the optimized code for generating the mandelbrot set.

Coloring of the set

I slightly modified the generation of colors so they are random. First I randomly choose a base color in RBG (three numbers between 0 and 255). Then, I average each componenet of each color with another random number to generate 64 unique colors.

There are 256 layers in this rendering of the mandelbrot set, so each color is repeated once every 64 layers. Additionally, I added another factor to alternate between dark and light colors, making each layer more distinguishable.

This algorithm makes it so that there are 64*256^3 (1,073,741,824) possible color combinations for the mandelbrot set, essentially making each one completely unique.

Examples!

Here are a couple of my favorites so far.

Purple

Blue

mandelb0t's People

Contributors

brobin avatar

Stargazers

Richard Anthony Hein avatar

Watchers

James Cloos avatar

Forkers

callandgus

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.