ArticlesProjectsWeeklyCredentialsAbout
neural-networksmcculloch-pittsneurosciencefoundationsboolean-logicthreshold-neurons

The Thinking Machine Chronicles #0005: The First Artificial Neuron: McCulloch and Pitts Describe a Logical Brain

·10 min read
Cajal's drawings of the human cerebral cortex, 1899, the biological inspiration for the McCulloch-Pitts neuron model

Santiago Ramón y Cajal's drawings of the human cerebral cortex, 1899, the biological structure that McCulloch and Pitts abstracted into a logical neuron. Public domain, via Wikimedia Commons.

The Thinking Machine Chronicles · Era I: Foundations (1936–1949)

The World in 1943

By December 1943, the tide of the war had turned, though the cost was staggering beyond comprehension. The Soviet Union's victory at Stalingrad in February had marked the Wehrmacht's first catastrophic strategic defeat; the battle consumed more lives in five months than the entire United States lost across the whole war. Allied forces had landed in Sicily in July and Italy in September; Italy surrendered and switched sides, leaving German forces to fight a grinding defensive campaign up the peninsula. The Tehran Conference of late November brought Roosevelt, Churchill, and Stalin together for the first time, hammering out the timing of a cross-Channel invasion that would come the following June. In the Pacific, American island-hopping campaigns were purchasing every atoll at horrifying cost, pushing inexorably toward Japan's home islands. Penicillin, mass-produced for the first time by Pfizer in Brooklyn, was reaching Allied wounded in North Africa and Italy,the first antibiotic at industrial scale, saving limbs and lives that would have been lost a year earlier. The United States had transformed itself into the "arsenal of democracy," its industrial output now exceeding all Axis powers combined. The world that would emerge from this war, bipolar, nuclear-armed, reshaped by radar, computing, and synthetic materials,was already taking form.

Against this backdrop of industrial-scale war, two men in Chicago were pursuing what appeared to be the most impractical question imaginable: whether the human brain could be rigorously described as a logical machine. Warren McCulloch was a 45-year-old neurophysiologist who had spent twenty years mapping the brain's electrical activity, driven by an obsession he had carried since medical school, What is a number, that a man may know it, and a man, that he may know a number? Walter Pitts was 20 years old: a prodigy who had mastered Greek, Latin, and symbolic logic by age twelve, run away from an abusive home in Detroit at fifteen, and been discovered sleeping rough near the University of Chicago by McCulloch, who promptly took him in. Pitts had read Bertrand Russell's Principia Mathematica the way others read novels. Together they were the most improbable collaboration in the history of science.

The First Artificial Neuron: McCulloch and Pitts Describe a Logical Brain

The paper they published that December, A Logical Calculus of the Ideas Immanent in Nervous Activity,is one of the most influential four pages in the history of science. It did nothing less than propose a mathematical model of thought.


The Problem: Can the Brain Be Formalised?

McCulloch had been obsessed since medical school with a single question: What is a number, that a man may know it, and a man, that he may know a number? This is not a neurological question on its face. It is a philosophical one, the question of how a biological organ made of wet tissue running on chemistry can perform operations that look like logic.

The answer he and Pitts proposed was both simple and revolutionary: a neuron is a threshold gate.

In their model, a neuron:

  • Receives signals from other neurons along dendrites (inputs)
  • Some inputs are excitatory (they push the neuron toward firing)
  • Some inputs are inhibitory (they prevent firing regardless of excitation)
  • The neuron fires (outputs 1) if and only if the sum of excitatory inputs meets or exceeds a threshold θ, and no inhibitory input is active

This is the McCulloch-Pitts neuron, and it is a Boolean function.


The Formal Model

Let x1,x2,,xnx_1, x_2, \ldots, x_n be the binary inputs to a neuron (xi{0,1}x_i \in \{0, 1\}). Partition them into excitatory set EE and inhibitory set II. The neuron fires at time t+1t+1 if:

y(t+1)={1if iExi(t)θ and jIxj(t)=00otherwisey(t+1) = \begin{cases} 1 & \text{if } \sum_{i \in E} x_i(t) \geq \theta \text{ and } \sum_{j \in I} x_j(t) = 0 \\ 0 & \text{otherwise} \end{cases}

The inhibitory condition is absolute in the 1943 paper, any active inhibitory input silences the neuron regardless of how many excitatory inputs are firing. This is a strong model: in later formulations (and in real biology), inhibition is graded. But the absolute form is sufficient to prove the universality result.

Note the time index: y(t+1)y(t+1) depends on inputs at time tt. This is the unit delay, each neuron takes one timestep to respond. This is both biologically motivated (synaptic transmission takes time) and essential for building temporal logic.


Every Logic Gate from Neurons

With this model, McCulloch and Pitts showed that any Boolean function can be computed by some network of MP neurons. The constructions are elegant:

AND: Both inputs excitatory, threshold = 2. y=x1x2    y=[x1+x22]y = x_1 \wedge x_2 \iff y = [x_1 + x_2 \geq 2]

OR: Both inputs excitatory, threshold = 1. y=x1x2    y=[x1+x21]y = x_1 \vee x_2 \iff y = [x_1 + x_2 \geq 1]

NOT: Input xx inhibitory, constant bias excitatory, threshold = 1. y=¬x    fires when x=0y = \neg x \iff \text{fires when } x = 0

NAND (two layers): AND followed by NOT. This is universal, any Boolean function can be built from NAND gates, and therefore from MP neurons.

XOR (three layers, cannot be done in one neuron): XOR(a,b)=AND(OR(a,b),NAND(a,b))\text{XOR}(a,b) = \text{AND}(\text{OR}(a,b),\, \text{NAND}(a,b))

The fact that XOR requires multiple layers foreshadows the problem that would stall neural network research in the 1960s, but in 1943, McCulloch and Pitts had no notion of learning. Their networks were hand-designed for specific logical tasks. The question of learning the weights would not be properly addressed until Rosenblatt's perceptron in 1958.


Temporal Logic: Recognising Sequences

The unit delay opens the door to temporal computation. A McCulloch-Pitts network can detect patterns in a sequence of inputs over time. The state of neurons at time tt feeds the network at time t+1t+1, creating a form of memory.

Consider detecting the pattern 101 in a binary input stream. Three neurons suffice:

  • s0s_0: fires when current input is 1 (simple threshold 1)
  • s1s_1: fires when previous input was 1 AND current input is 0 (excitatory: s0s_0, inhibitory: xx)
  • s2s_2: fires when previous s1s_1 was firing AND current input is 1, detection!
s2(t+1)=[x(t)=1][s1(t)=1]s_2(t+1) = [x(t) = 1] \wedge [s_1(t) = 1]

Running this on the stream 1 0 1 1 0 1 0 0 1 0 1, the detector fires at t=2,5,10t = 2, 5, 10, exactly the positions where 101 ends. This is a finite-state automaton, implemented with three neurons.

McCulloch and Pitts proved this in full generality: any finite automaton can be simulated by a network of MP neurons. Since finite automata capture everything regular languages can express, this places MP networks in correspondence with the regular fragment of computation, a rich class that includes all pattern matching, sequential logic circuits, and bounded-memory algorithms.


The Universality Result

The deeper claim in the 1943 paper was influenced by Leibniz, Boole, and Turing in equal measure. McCulloch and Pitts knew about Turing's 1936 paper. They had absorbed Whitehead and Russell's Principia Mathematica. Their argument was:

  1. Any proposition in propositional calculus can be computed by some MP network.
  2. With recurrent connections and the unit delay, any finite-state transition function can be computed.
  3. Therefore, for any "psychon" (their term for a neural computation), there exists a network that computes it.

In modern terms: the class of functions computable by MP networks with recurrent connections and bounded memory is equivalent to the class of regular languages. With unbounded memory (external tape), the equivalence extends to Turing-complete computation. McCulloch and Pitts were claiming, in 1943, that the brain is a logical computer, that thought is computation.


The Code: MP Neuron Simulator

The code project implements the full MP model and verifies all five gates:

@dataclass
class MPNeuron:
    excitatory: List[int]
    inhibitory: List[int]
    threshold: float
    absolute_inhibition: bool = True

    def activate(self, inputs: List[int]) -> int:
        if self.absolute_inhibition:
            if any(inputs[i] for i in self.inhibitory):
                return 0
        excite_sum = sum(inputs[i] for i in self.excitatory)
        return 1 if excite_sum >= self.threshold else 0

AND, OR, NOT, NAND, all pass their truth tables. XOR requires three-layer composition. The sequence detector correctly identifies 101 at positions 2, 5, and 10 in a test stream.

The code also includes a contrast with the Rosenblatt perceptron (1958): same threshold decision, but with real-valued learned weights rather than hand-designed binary ones, the crucial difference that enabled supervised learning.

Paper: McCulloch, W.S. & Pitts, W. (1943). "A Logical Calculus of the Ideas Immanent in Nervous Activity." Bulletin of Mathematical Biophysics, 5(4), 115–133. Freely available via numerous archives. At four pages, it is one of the densest and most productive papers in the history of science.


Why It Mattered

The McCulloch-Pitts paper accomplished three things that echoed for decades:

1. It made the brain legible to mathematics. Before 1943, neurons were biological objects studied with microscopes and electrodes. After 1943, they were also mathematical objects, functions, automata, logical gates. This reframing made computational neuroscience possible.

2. It connected biology to logic. The paper was written in the formalism of Whitehead-Russell propositional calculus. It showed that the gap between thought and symbol manipulation might be bridgeable, that a brain doing cognition and a machine computing a function might be doing fundamentally the same thing.

3. It inspired every neural network that came after. Norbert Wiener read it and was inspired to found cybernetics. John von Neumann read it and cited it in his EDVAC report. Frank Rosenblatt read it and built the perceptron. Marvin Minsky read it as a teenager and set off toward MIT. The 1986 backpropagation revival connected directly to this original formalisation, just with learned weights instead of designed ones.

Walter Pitts died in 1969, aged 46, after burning most of his unpublished manuscripts. McCulloch died the same year, two months after Pitts. The two men who described the logical brain had between them suffered depression, alcoholism, institutional rejection, and the loss of colleagues who moved on to shinier things. Their paper survived them, compounding interest for eighty years.


What Came Next

McCulloch and Pitts had given the nervous system a mathematical description, neurons as gates, minds as automata. What they had not built was a machine fast enough to act like one. That would take vacuum tubes by the thousands, and the relentless urgency of wartime codebreaking. While their paper was being read in Chicago, at Bletchley Park engineers were constructing something that had never existed: a fully electronic, programmable computing machine called Colossus, built to crack the Lorenz cipher and kept secret for thirty years after the war ended. That story is next: The Thinking Machine Chronicles #0006: Colossus: The Secret Electronic Brain.


References

  1. McCulloch, W.S. & Pitts, W. (1943). "A Logical Calculus of the Ideas Immanent in Nervous Activity." Bulletin of Mathematical Biophysics, 5(4), 115–133.
  2. Minsky, M. (1967). Computation: Finite and Infinite Machines. Prentice-Hall. Ch. 1–3 on MP neurons.
  3. Anderson, J.A. & Rosenfeld, E. (eds.) (1988). Neurocomputing: Foundations of Research. MIT Press. Reprints the 1943 paper with commentary.
  4. Piccinini, G. (2004). "The First Computational Theory of Mind and Brain." Synthese, 141(2), 175–215.
  5. Conway, F. & Siegelman, J. (2005). Dark Hero of the Information Age: In Search of Norbert Wiener. Basic Books.