Skip to content

Brain Wire

Clifford Bohm edited this page Jul 27, 2017 · 8 revisions

Wire Brains

Wire Brains are cellular automatons that approximate electrical current flowing through wires. Inputs are delivered to the wire brain by setting 'input' cells to a charged state. Some number of brain updates are run during which the charge radiates through the brain. Output cells are observed and determine the brain's output. The figure above shows a 2 dimensional (flat) wire brain with 2 inputs, 2 outputs, and 1 hidden node. Wire Brains are usually 3 dimensional (cubes or rectangles) which allows for more processing power and allows for more room for inputs, outputs, and hidden node connects.

*** While we have run a number of tests using Wire Brains, please note that the Wire Brain code is very experimental, and has not been rigorously tested. Use at your own risk.

Building Wire Brains

There are 3 ways to build a wire brain

build from genome using bitmap encoding
the genome is converted directly into a wire brain. A 1 in the genome translates to wire, and a 0 to empty space. This method is best used with genomes with alphabet size 2.
build from genome using wiregenes encoding
the genome is scanned for start codons which are converted into different types of wire genes
  • simpleWire - gene adds a straight line of wire (defined by a source and a direction) to the brain
  • squiggleWire - gene adds a "squggle" wire (defined by a source and a list of directions) to the brain
  • wormhole - gene adds a worm hole (defined by two locations) which connects 2 locations at if they were neighbors
build genome from a vector of bits(bool)
the vector is used to create the brain using a method like bitmap encoding.

Additional Options

allow negative charge
Wire brains can be setup to allow negative charges. In this case, inputs can deliver positive or negative change. To determine if a cell becomes changed, the charge of the neighbors is summed.
longer decay
take 2 or more brain updates to decay

Wire Brain Parameters

see settings file.

Wire Brain Variables

Wire Brains inherit the variables from Brains and have the following additional variables

  • width, depth, height - size of the brain
  • nodesAddresses, nodesNextAddresses - lists of which cells connect to the input and output nodes
  • allCells - list of the state of all cells in the brain
  • nextAllCells - used during a brain update
  • wireAddresses - list of addresses of cells which are not empty
  • neighbors - for every cell in wireAddresses, list of neighbors who are not empty.
  • connectionsCount - number of connections in the brain
Clone this wiki locally