4+1 ThingS

I bet you didn't know were turing-complete

what is turing-completenesss?

  • tl;dr: "Turing-complete" means something's at least as powerful as a Turing Machine
  • A Turing Machine is a model of computation - given any algorithm, one can construct a TM to compute that algorithm.
  • Equivalent to the lambda calculus (Church-Turing Thesis)
  • TM : Assembly :: Lamba Calculus : Lisp
  • (and ultimately, assembly and Lisp are precisely as powerful as one another)
  • Any programming language is going to be Turing-complete (even so-called Turing Tarpits. even SQL!)
  • But those are boring...

html5 and css3

  • Near & dear to our heart as webdevs
  • http://jsfiddle.net/Camilo/eQyBa/
  • can implement the Rule 110 Cellular Automaton, which is TC (about which more later)
  • despite being a declarative markup language, declarations interact just enough

 

http://my-codeworks.com/blog/2015/css3-proven-to-be-turing-complete

cellular automata

  • Might be familiar from AoC...
  • Grid of cells, on/off
  • State at step N+1 for a cell is determined by the state of cells in the original cell's neighborhood (usually 'adjacent', sometimes 'orthogonally adjacent', according to some rule

game of life

  • One of the most famous cellular automata (and TC), although not the simplest TC cellular automaton
  • TC implemented on Game of Life is definitely a party (more, plus details)
  • Other class of CAs referred to by integer rules coding for binary instructions about what to do next

rule 110

curr: 111 110 101 100 011 010 001 000
new: 0 1 1 0 1 1 1 0
  • Winds up generating highly-ordered systems, neither totally ordered nor totally chaotic, that are provably Turing-Complete (proof)

 

 

https://en.wikipedia.org/wiki/Rule_110

Magic the gathering

  • It is actually possible, working entirely within the constraints of card rules, using creatures as the tape, hacking card text w/ Artificial Evolution, to implement a Turing Machine using Magic cards.
  • It's pretty ludicrous.

honorable mentions

just the x86 'mov' instruction

  • It has been alleged that the x86 instruction set is baroque and overcomplicated...
  • ...but it's possible to implement a transport-triggered architecture just by taking advantage of promiscuous addressing modes of x86 mov (proof)

and finally...

believe it or not,

PHP

also

javascript

(no srsly)

4+1 Things I Bet You Didn't Know Were Turing-Complete

By Jon Cantwell

4+1 Things I Bet You Didn't Know Were Turing-Complete

  • 1,355