computation

Definition

Register Machine

A register machine with registers consists of 3 components:

where:

  • : stored states in registers
  • : storage commands
  • : test commands

The content of the th register is denoted as .

Semantics:

  • : (add)
  • : (subtract)
  • : Is ?

Properties

Turing-completeness

Register machines are Turing-complete and thus computation-equivalent to Turing machines.

Minimality

Already 2-RMs - modulo suitable encodings of inputs and outputs as single numbers - are computationally universal.

Relation to Modern Computer Models

RMs can be generalised quite directly to realistic formal models of modern computers (e.g. the Random Access Machine, where memory areas have to be addressed explicitly).

Program

Definition

Register Machine Program

A program of a register machine with registers consists of a start token and a finite set of instructions:

  • Function instruction: read as : do then goto
  • Test instruction: read as : if then goto else goto

is called the label of the instruction, and and are jump labels . Jump labels that are not labels of any instruction are called end labels. Labels are unique.

Link to original