Register machine
Definition
Let . A register machine (counter machine) with registers is a finite sequence of instructions of the following three kinds, where and .
- : add to and go to instruction .
- : if , go to instruction ; otherwise subtract from and go to instruction .
- : stop.
A configuration is a pair of an instruction number and a vector of register contents. Here is the set of natural numbers. A run starts at instruction and performs the instructions in turn until it reaches , if ever. The machine computes the partial function , for , that takes to the final content of . Here the run starts with for and all other registers , and is undefined when the run does not halt.
Remarks
Example: the program , , , , computes . Instructions and move the units of into . Then instructions and move the units of into , and the run halts with . Non-example: an instruction that sets to in one step is not allowed, since only the three kinds above exist. Multiplication must be programmed as repeated addition. The functions computed by register machines are exactly the partial recursive functions. Two registers already suffice for universality, when inputs and outputs are suitably encoded, for example as . Other register machine models allow more instructions, such as copying or indirect addressing.
Reading path
To understand this page from the ground up, read these 4 pages in order. The foundations come first.
Show the path as a graph
- no evidence level
- Natural numbers object
- Primitive recursive function concept
- General recursive function definition
- Register machine definition
Further reading
About this page
| Tag | BSPVYC28BY |
|---|---|
| URI | m2://BSPVYC28BY |
| Kind | definition |
| Writing | W0 stub |
| MSC | 68Q04, 03D10 |
| Defines | Register machine |
| Uses | Natural numbers, General recursive function |
| Changed | 3 November 2026 |
Markdown · JSON · Edit on GitHub
What this page needs for W1
- a source with a locator (0 of 1)
The writing levels say how complete the text of a page is. They do not measure its truth.
What links here
No page links to this page yet.