Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!tut.cis.ohio-state.edu!ucbvax!van-bc!ubc-cs!phillips From: phillips@cs.ubc.ca (George Phillips) Newsgroups: comp.theory.cell-automata Subject: wireworld patterns Summary: memory,AND,OR,NOT,XOR,crossover,pulsars Message-ID: <6743@ubc-cs.UUCP> Date: 12 Feb 90 05:02:06 GMT Sender: news@cs.ubc.ca Reply-To: phillips@cs.ubc.ca (George Phillips) Organization: UBC Department of Computer Science, Vancouver, B.C., Canada Lines: 210 Here are some of the wireworld patterns I've developed. A quick legend: '=' wire ' ' or '.' space '#' electron head '-' electron tail I avoid using spaces since they may get converted to tabs and my stupid programs would fail. Sometimes I'll stick in single tails ('-') just to indicate where a pulse might be. Not all of the patterns work, but I'll try and comment on what should do what. I suppose I should have put these in a shar file, but that would have made commentary difficult so you'll just have to hand edit them. ..................==.... .................=..=...... ................===..======#-============. ................=.=. .................=.=...................... .................=.=.....===-=====-====#-. ...==============.===...=................ ...................=...=................. ....============....=#-.................... ................=-#.......................... ................=..=.................... .................==................... A six-cycle memory cell. It is about to remember a 1 and then a 0 and then go back to 1 after a couple cycles. It has a small bug in that the "write 0" line causes a single, spurious pulse on the output, but that could be eliminated fairly easily. ........= =================== ........= ........= ........= ........= A much improved "OR" gate (output going down): ..-...#.................................................................. .#==.-==.......======-#.......-#====-#==...............=.....=........... ..=...=................=................=.............=.=...=.=.......... ..=.=.=...............===..............===............=.#...#.=.......... .=.===.=.............=.=................=..............-.=.=.-........... .=..=..=..............=.========......==.=======.........=.=............. .=..=..=.............==..............=.=...............=.=.=.=........... .=..=..=.............==..............=.-.....-#====-#====...====#-=====-. .=..=..=............=..=..............#.....=..........=.=.=.=..........= .=..=..=.............#-.....................=............=.=............= ............................................=...........=...=...........= ............................................=...........=.=.=...........= ......................==....................=............===............# .....===-#====-#==-#===.==.=................-.............=.............- ......................==..=.=...............=.............=.............= .........................==..=========....................=.............= ......................==.=................................=.............. .....====-#====-===-#==.=.................................=.............. ......................==..................................=.............. ..........................................................=.............. In the above file we have a couple of NOT gates (top middle), an XOR gate (bottom left) and a NAND gate (right). The inelegant part of these NOT and NAND gates is that they have internal clocks -- a pulse arriving must be in sync with the internal clock or the gate will fail to function. I don't believe this can be helped, but an OR gate only requires that the incoming pulses be in sync, which is seems to be a much nicer property. On the other hand, the NAND gate does have a certain visual appeal. ............................................................................. ............=.==...........................................==................ ...........===..=.........................................=..=............... .........==.=.=.=..................====-#=====..........==..===.............. ........=.....=.=.................=...........=........=.....=..==........... =====-#=..==.=..=..=.========......=====#-====.====-#==..==.=.==..=.......... .........#..=..======...................................#..=.....========.... =====-#=..-=.=..=..=.==-...........-====#-====.====-#==..-=.=.==..=.......... ........=.....=.=....=..#.........#...........=........=.....=..==.....===... .........==.=.=.=.....==...........===========..........==..===.....=.=...... ...........===..=.........................................=..=...=======..... ............=.==......................=....................==...=...=.=...... ........===.........................=.=........................=......==..... .......=...=.======..............=======.................======.......=...... .......=..===..............-=====...=.=.................=........===..=...... .......#...=......................==..==...............=........=...=.=...... ........#==......................=..=.=.......-#====-#=.........=..===....... ................................=..===..........................=...=........ ................................=...=...............-#====-#=...====......... .............................#======.........................===............. On the left is an AND gate and on the right is a NAND gate being fed test patterns. The AND gate on the left is unfortunate: internally clocked and is really only A & B = ~(~A | ~B). Happily, I found a non-clocked AND gate (bottom right). The key is the "H" pattern near the output -- it does that actually ANDing. But 2 '1' pulses break the gate, so the one signal must be multiplied into 2 electrons (by the G) with the second electron stopping any out of control oscillations. .-...-.......==.....................#..........=...........................#. #=#.#.=..-..=..-.....................====....===#.......................===== .=...=..#.=.#..#.......#.............====...=..=....#......==.....==...=...=. .=.=.=...=..-..=..#...===............====...=..=...====...=..=...=..=..=..=.. =.===.=..=...==..==-...=.=....#......====...=..=....=..=..=.==#..=..=...==... =..=..=..=.=.=....=.....=....===.....=..=..#===.=..=.==....=.=....===#....=.. =..=..=.=.===.=...=.....=....===.....=..=...=...=..=.......=.....=..=.....=.. =..=..=.=..=..=...=.....=...==.==....=..=.......=..=......=.=.=.=.=.......=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.....=...===...=......=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.....=....=....=......=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=......=...=...=.......=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. =..=..=.=..=..=...=.....=..=.=.=.=...=..=.......=..=.......=..=..=........=.. Some pulsars of rates from 3 to 9. To make it a bit tougher, I decided that I would have to make the pulsars get their initial electron from an outside wire rather than having an electron in the loop from creation. A little junction which I call an "injector" accomplishes this. Notice that the rate 5 pulsar is really a rate 10 pulsar with 2 electrons. I don't think it is possible to build a loop which takes 5 generations to traverse. .==========-#==========...........=====-#=========........................ =......................=.........=................=....................... =......................=...=.....=................=....................... =......................====.=....=................=....................... =......................=....=....=...............===...................... =.....................===...=....=...............=.=...................... =.....................=.=..=......==========#-....=....................... .#-....................=..===....................===...................... ....................==.=...=....................=.=....................... ..===========-#======.=.===.=======.........==.=...=...................... .=................=.==.=...........=....=-#==.===...==============........ .=................=....=...........=...=....==.=.=........................ .=...............=...=.=...........=...=..........=....................... .=...............=.====............=...=...........=...................... .=................=..=.=...........=...=...........=...................... .#.....................=...............=...........=...................... ..-....................=...............=...........=...................... .......................=....===========............=...................... .......................=...=.......................=...................... .......................=....=#-........................................... Some attempts at wire crossing. The one on the left stops some pulses with diodes and splits an incoming pulse so that it suppresses the pulse which goes down the wrong wire. The one on the right uses injectors to send the puses in the "right" direction with diodes to stop the rest. Unfortunately, both have a rather high cycle time. .........................#................. ..........................=====............ ...............................=........... ......................=...=====............ .....................=.=.=................. .....................=.#.=.=.==............ ......................-...===..#............ .....................===.=.=.=-............ ......................=..=.................. .........======-#=====.==.==.===...===.... ........=................=..=...=.=....... ........=...........-=.=.=.===..=.=....... ........=..........#..===...-....=.......... ........=...........==.=.=.#.=.............. ........=................=.=.=.............. ........=................=..=............... ........=................=.................. ........=................=.................. ........=................=.................. .........=#-.............=.................. Another attempt at wire crossing. The idea was to use "power" to make the circuit faster. But I ended up with nothing faster than before and added internal clocking to boot :-(. .................................. ....................=====......... .................=.=.............. ................===............... ...............=.=.=.............. ...............=...=.............. ................=.=.==.=========.. ............==.=.=.=..=........... .#===========.=.=.=..===.......... -...........==.=.=.=..=........... ................=.=.==............ .................=................ ................=.=............... ................===............... .................#................ .................-................ .................=................ ..................=================#-= Another attempt at a wire crossing. A pulse from the right will send electrons slightly staggered to the top wire. They will then cancel each other. But the 2 electrons going to the right do not cancel each other and send an output to the right. Similarly for the input on the bottom. Diodes keep the other signals in check. A nice idea, but still the cycle time is large :-(. I should hope a better wire crossing can be constructed... -- George Phillips phillips@cs.ubc.ca {alberta,uw-beaver,uunet}!ubc-cs!phillips