SWITCHES, Generative Pen Plotter Art

Switches 1


I imagined a grid of connected single pole single throw switches.  Each switch has a metal contact, the contacts could be connected in one of two ways, with the free end of contact on the right or on the left side as shown in the picture (think of switch installed either forwards or reversed):


Furthermore, the switches can be open (left) or closed (right):


I wrote a python program to create the switches and randomly set the direction of the switches and randomly have the switches open or. closed.  Then, I looked to find the biggest 3 groups of contiguous areas in the grid, which are composed of multiple switches and I colored them red, blue and yellow, whereas the remainder of the switches are drawn in black.  Furthermore, I add a dot to one end of the switches in the top three groups.  This project used some new programming elements in my learning python, I used dictionaries and sets for the first time in python.  I created my first python classes.  I used simple aspects of graph theory to define the contiguous areas.  I plotted some of the outputs on 9x12 paper with my sovol so-1 pen plotter.  It was interesting to see the complex patterns that emerged from this grid of switches. 

Here is the script from my google drive: switches.py

Be warned, that due to my amazing coding skills ;) 😂 with the fastest algorithms 😂 in the design of this artwork, it takes a couple of minutes to run to generate the output files.

Switches 2




Disclaimer

The author does not make any warranties about the completeness, reliability and accuracy of this information. Any action you take upon the information on this site is strictly at your own risk, and the author will not be held liable for any losses and damages in connection with the use of this information. 

  

Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

Comments