Talk:Billiard ball machine

From Esolang
Jump to navigation Jump to search

Since the quantum gate, and the others, are very hard, or impossible, to express as a deterministic machine, how about this syntax?

feyman: |000><00| + |100><01| + |001><10| + |110><11|.
del: |><0| + |><1|.
id: |0><0| + |1><1|.
main: feyman[0:2] # feyman[2:4] # (del @ 4)[4:8]
   -> |1><| @ 2 # (id @ 6)[0:6].

Where

  • "#" would be parallelizing (concatenating) two or more gates.
  • "->" would send the result to another gate expression.
  • "+" would be the union of two or more gates.
  • "@" would be replication of a gate.
  • "[a:b]" would extract billiard balls from specific indices of the implicit input argument.
  • other algebraic expressions would express the relative probability of the matching gates in a union, possibly with complex values.

This would allow for simple input/output trough the main gate, though imaginary probability values need to be handled in some way. --MizardX 13:22, 24 November 2008 (UTC)