1. Introduction
In 1986, Chris Langton proposed an artificial life on square lattice
[
1,
2,
3,
4,
5] where each vertex is either to-right (white) or to-left (black). An
ant, represented by an arrow in
Figure 1, travels along edges with unit speed and four possible directions. It turns to either right or left, corresponding to the vertex’s white or black color it is heading and switches the color simultaneously. Since then, it is one of the most widely studied cellular automata in many fields, for example, discrete propagation kinetics [
6,
7,
8], Lorentz lattice gas [
9,
10,
11], particle diffusion dynamics [
12,
13], computational complexity [
14,
15,
16], emergent dynamics [
17,
18], and cryptography [
19,
20,
21,
22,
23].
This paper’s motivation is the following chaotic trajectory of Langton’s ant. Placed on the all-white vertices, the ant stays within
area for about 10,000 moves unpredictably, and then it suddenly starts dancing a
highway of 104 steps drawn in
Figure 2 and moving diagonally in speed
[
13]. After decades of exploration, this phenomenon has been taking place with no exception, giving rise to a famous conjecture—the highway must eventually appear regardless of any initial configuration with finite support. If so, the ant’s long-run behavior is predictable except for reflection and transposition. Grosfils, Boon, Cohen, and Bunimovich [
12] developed diffusion dynamics proving the highway conjecture and measuring the diffusion speed on triangular lattice. Meanwhile, Gajardo, Moreira, and Goles (GMG, [
14]) constructed a finite configuration to evaluate a given boolean circuit. We note that these theoretical results fundamentally affected the related fields. For example, suppose that Langton’s ant is a particle system where a finite initial configuration and its consequent macroscopic quantities are the only observables. If highway conjecture holds, macroscopic observables are fixed constants regardless of the initial state. In any case, they must have some calculation from the initial finite configuration since the system is deterministic. GMG demonstrates that calculus PSPACE-hard if macroscopic quantities rely on an ant’s microscopic behavior called reachability.
This paper aims to strengthen GMG in both computational complexity and highway conjecture. Computational complexity measures time and space (memory) that modern computers, that is, Turing machines, must spend for solving a given computational problem (see computational complexity textbooks, for example, Reference [
24]). GMG proved that the ant’s trajectory could simulate any computation spending a polynomial (
for some constant
) time for any bit-length
n instance. GMG constructed a boolean circuit evaluator since circuit evaluation is a PTIME -complete problem, that is, simulating any polynomial-time calculation. Similarly, QCNF is a PSPACE -complete problem to execute any polynomial-space computation [
25]. QCNF evaluates a given Conjunctive Normal Form (CNF) with bounded quantifiers. For example, QCNF evaluates
TRUE, since for any
{TRUE, FALSE}, there exists
{TRUE, FALSE}, making the 2-term 2-variable CNF
TRUE. PSPACE-complete problems take exponential time for any known algorithms, although P ≠ PSPACE is merely a conjecture. We note that GMG constructed a universal Turing machine but using an infinite number of black vertices for the initial configuration.
This paper aims to obtain the first result that the ant’s trajectory is unpredictable, even for a macroscopic measurement [
3]. Let
. For a coloring
with black vertices in only
, let
be the number of vertices in
that the ant starting from the origin will visit after
T steps. We call
microscopic field, while
macroscopic one. If highway conjecture holds, we have
for
. However, we do not even know
, that is, the ant may visit almost all vertices for some
. The only known previous result is
, that is, the ant’s trajectory must always be unbounded [
10]. Although
measures
-order convergence rather than more accurate
N-order one required in highway conjecture, its impact is substantial on the related fields. For example, if
, mathematical analysis may have a chance to prove highway conjecture on square lattice, as they have done in triangular lattice [
9,
12] and one-dimensional lattice [
7,
12]. If
, cryptographic applications [
19,
20,
21,
22,
23] may find finite configurations producing infinitely long pseudo-random bits generated by the ant’s trajectory.
This paper will show that
is hard to approximate on a
twisted torus. A torus is the standard boundary condition to extend a coloring
on
to
by
for
. Long-run computer simulation of square lattice cellular automata usually takes this topology [
19,
20,
22]. An
h-twist (
-pitch) of the torus is
. It appears in related models, for example, square-lattice Ising models (Langton’s ant is a typical one) [
26,
27]. When
,
may occur even under highway emergence, as described in
Figure 3. For this specific case, we can prove the following theorem.
Theorem 1. On ±11-twist torus, it is PSPACE hard to distinguish between
It states that modern computers cannot predict whether the ant on the twisted torus will ever visit almost all vertices or nearly none of them, even under the promise that either of these cases must occur. Notice that
is a time-independent measurement, counting the ever visiting vertices. Our proof will measure the
period that an initial configuration of the cellular automaton appears again, too. Any closed loop of Langton’s ant’s propagating configurations must contain the initial one [
6]. Let
be the period of Langton’s ant on
with an initial coloring
on
. Let
.
Theorem 2. On ±11-twist torus, it is PSPACE hard to distinguish between and .
Consequently, no computer-aided analysis can calculate Langton’s ant’s macroscopic quantities from an initial finite configuration in polynomial time, unless P = PSPACE. We note that even under the (twisted) tours’s boundary condition, Lorentz lattice gas can measure the ant’s diffusion speed for triangular lattice [
9], particle diffusion dynamics can do it for both triangular and one-dimensional lattices [
12], and discrete propagation kinetics the diffusion speed or period of the ant’s rules for one-dimensional lattice [
7]. Theorem 2 indicates that these currently known methods cannot measure them for square lattice.
A Proof Outline
Figure 4 reduces QCNF to Langton’s ant problem of distinguishment between
and
. It maps a given QCNF instance
, say
for a sufficiently large
to encode it on
, to a coloring
on microscopic field. The ant starting from the
port (i.e., edge)
S of TURN-A gate walks along a line and gets into the
chip (a collection of gates) at the entrance port
I. The ant evaluates
and gets out from either the exit port F if it is FALSE or T if it is TRUE. In the former case, the ant reaches TURN-B gate. Since each TURN gate
reverses the ant (i.e., putting the ant on the same port in the opposite direction), it must repeat a closed-loop between TURN-A and TURN-B gates due to
time-reversibility; the reversed ant must travel back and rewind all steps it has taken in the time-reversing order. This loop holds the ant on microscopic field and thus makes a reduction
. Similarly, the latter case induces another loop between TURN-A and TURN-C gates, passing through Hamiltonian-tour gate on the way, which drives the ant to visit almost all vertices in macroscopic field. It yields
, where
. Since these TURN gates take binary states flipping at the ant’s every visit, the ant travels
Figure 3’s Hamiltonian-tour four times until revisiting the initial configuration. Each Hamiltonian-tour consists of
rounds of length-
diagonals, taking
time since the ant’s speed is
[
13].
Our previous paper [
15] has already provided a coloring for the
chip to evaluate a QCNF formula
, but using
gray vertices at which the ant goes straight without changing the color [
10]. Since it has permitted only a single gray vertex at each TURN gate and nowhere else, we are enough to exhibit only a new TURN gate with no gray vertex. However, open square lattice topology prohibits it because it tessellates the vertices of
into chess-board symmetry of
-polarity: Every H-vertex (resp. V-vertex) permits the ant to come Horizontally (resp. Vertically) and go vertically (resp. horizontally). Even-twist torus preserves
-polarity, but odd-twist torus breaks it. If the ant living in odd-twist torus travels around vertically and comes back to the initial place, it can visit the world where every vertex possesses the opposite polarity.
Figure 5 realizes a TURN gate in virtue of this polarity switching phenomenon. The ant enters at the port
S, passing through FL (FLipper) gate, and reaching HW (HighWay) gate. The ant gets on
Figure 2’s highway and travels towards a
away destination place in a diagonal direction. The odd-twist torus’s topology brings the ant to a new world possessing the same address but the opposite polarity. Accordingly, after getting off the highway, the ant passes through the FL gate again and gets out the TURN gate from the same port
S that it has entered but in the opposite direction.
A Hamiltonian-tour gate to visit almost all vertices is easy to realize: Let the ant get on a highway at the entrance port I of top-left
in
Figure 4. It brings the ant to a Hamiltonian tour along screwing diagonals of
Figure 3: Each diagonal transports the ant by a horizontal and vertical distance
N, bringing it back to the same address but a horizontal displacement
due to the twisted torus topology. This gap number 11 fits the highway width, providing an exhaustive, mutually exclusive vertex cover. The highway must assume white color of the underlying vertices, so it remains at most
vertices inside microscopic field unvisited.
Figure 6 paves gates along the border between microscopic and macroscopic fields to generate consecutive multiple highways H
1, H
2, …, H
4 surrounding the
chip. The ant must pass through all these highways in order: It gets on each H
i at the entrance port
I of
Figure 6 placed in
Figure 4’s left H
i, making a trip to the right H
i, getting off there at the exit port
, and walking along a line guiding to the next left H
i+1’s entrance port.
We follow an analysis of Reference [
16] in making efficient embedding of
Figure 4’s cellular automaton to the square lattice, although it allowed using gray color freely in CROSS gates. Reference [
15] prohibits it there, but their CROSS gate was large and complex. This paper will maintain the efficiency of Reference [
16] by providing a new construction of CROSS gate having size 9 × 9 in
Figure 7.
2. Gates
A
gate is a coloring on a limited lattice area for embedding the corresponding part of
Figure 4’s cellular automaton to square lattice. This section describes the necessary gates composing all parts of
Figure 4. These gates must endure repeated usage under contamination by the ant’s passage. Time reversibility of Langton’s ant recovers the initial state: The ant passes a gate by
, that is, entering at
I, staying inside the gate for a while, and finally exiting at
O, changing the gate’s state
. After that, the ant placed on
, the same port
O but the opposite direction, must proceed as
and changes the gate’s state as
. We say that the ant’s inverse trip must charge the dry gate for the next passage.
Figure 8,
Figure 9,
Figure 10,
Figure 11 and
Figure 12 display gates and their state diagrams called Straight PATH, Bending PATH, JOIN (called CONJ in Reference [
15]), S&P (Switch and Pass), and SWitch (SW in short), respectively. These state diagrams are Mealy machines outputting ant’s tracks when state transitions occur. When
occurs, the ant must travel from
I to
O inside the gate along the
track (a series of the ant’s moves to either the Left (L) or Right (R) directions). We write it as
or
. For example, PATH can stretch upwards by alternating
Figure 8 with its H&D (H-symmetry and Dual, that is, flipping Horizontally and swapping C ↔ D),
I[PATH]
O[PATH] →
I[H&D PATH]
O[H&D PATH] →
I[PATH]
O[PATH] →⋯, forming a width-2 line, possibly bending to right by
Figure 9. It can stretch and turn by 90 degrees to arbitrary directions by taking the symmetric and dual figures. PATH, S&P, and JOIN have the same configurations as Reference [
15]. Differences from Reference [
15] are parsing a S&T (Switch and Turn) gate in Reference [
15] into three gates (SW, HW, FL) in
Figure 5, providing a new TURN gate with no gray-color vertex, and a new CROSS gate having a much smaller size.
2.1. Turns
Figure 12,
Figure 13 and
Figure 14 present configurations of SW, FL, and HW, respectively. Any automatic method can check the correctness of these configurations. In
Figure 14, the ant gets in HW at the entrance port
I, passing through
for highway generation, riding on a highway propagation
, and getting out of it at the exit port
and walking away along a path starting from
.
Figure 15 paves consecutive highways where each HW attaches an SW (horizontally flipped
Figure 12) to share HW’s right-most two vertices with SW’s left-most ones. In this manner,
Figure 4 paves the
k TURNs (
and
with
there) for the
k variables of
.
Lemma 1. Every visit of the ant to Figure 5 induces , accompanied by (resp. ) at each odd (resp. even) time visit. Proof. In each odd time visit to
Figure 5, the ant gets in from the entrance port
S, travels along
, and exits from the
S it has entered but in the opposite direction. Here, the ant at
can get into the FL gate from the exit port
since the ant lives in the opposite polarity world before and after taking the HW trip. Each even time visit induces the reversed travel
. Observe that the SW’s state has transited as claimed. □
4. Hardness of Approximation for Langton’s Ant
We say that a function has a deterministic or non-deterministic computation of t-time and s-space if it has that kind of Turing machine T halting in t steps by using s walk-tape cells such that . A language has a closed QCNF expression if there exists a sequence of closed QCNF expressions such that ; a closed QCNF is a QCNF with all k variables quantified. CNF’s size sums the numbers of variables in the terms; QCNF’s size is its CNF’s size.
Theorem 3 ([
25]).
Let s be any integer larger than the number of input bits. Any language having a non-deterministic computation using s space admits a closed QCNF representation of size for some universal constant . The next theorem demonstrates Theorems 1 and 2 by a reduction from the above theorem.
Theorem 4. Let and . A given closed QBF Φ of size is transformable by a deterministic computation of time and space to a coloring on of h-twist torus , such that if FALSE then and , else and .
Proof. Lemmas 2 and 3 embed the
chip to
for
in the claimed time and space due to VR embedding algorithms [
28,
29]. A previous paper [
15] proved that if
is TRUE (resp. FALSE), then the ant getting in
’s entrance port
I must get out from the exit port
T (resp.
F). As explained by
Figure 4 in
Section 1, if
is TRUE, the ant repeats
. The ant visits only
vertices of the
chip plus
of each HW gate for the
k variables of
, yielding
. The ant switches the vaiables’ values for
times since each of the four trips between TURN-A and TURN-B may consult at most
bit patterns to evaluate QCNF. Switching a variable takes at most
steps for tripping HW in the TURN gate. Between them, the ant travels the same polarity, so each S&P, SW, and CROSS gate allow twice passages, and the other gates only once (see their state diagrams). Since the
chip contains at most
gates and
total path length,
.
If
is FALSE,
. Here,
(
in
Figure 4) is the number of
Figure 6’s HW gates surrounding the
chip, one of which (
in
Figure 4) becomes a Hamiltonian tour. Consequently,
, and
. An upper bound of
is the Hamiltonian tour time-bound
plus the
’s evaluation
.
The only difference between
Figure 4’s cellular automaton and the previous one in Reference [
15] is parsing each
k S&T gate inside
Figure 22 and
Figure 23 to
Figure 5’s (SW, HW, FL) gates, and moving out both HW and SW to the outside but remaining the FL there. Observe that the SW gate entails three lines connecting
I[SW]–
[JOIN],
F[SW]-
[CROSS], and
T[SW]–
[CROSS], and the HW gate two lines
I[HW]–
[FL] and
[FL]–
[HW]. Each of these lines incurs 2 additional cross gates for preserving planarity through moving-out their gates outside of the
k-times cascaded
Figure 22 and
Figure 23. Consequently, our cellular automaton may conttain
more cross gates than that in Lemma 2. The above analysis still holds even suffering this cross-gate incrementation. □
5. Conclusions
We have shown that it is PSPACE hard to predict whether the ant residing in
h-twist torus will visit almost all vertices or nearly none of them, for
. We have embedded a closed QCNF
to
of the twisted torus
and measured the following quantities by dividing
and taking the limit
. If
is TRUE, then the density of ever visiting vertices is 1, and the period is
. Otherwise, both are 0. The same argument proves the following result for any odd number
. Let
. If
is TRUE, then the density is
, and the period is
since we have
Figure 24’s screwing highway inserting
spaces between
jth and
th diagonals for every
. For example, for
,
Figure 24 paves two consecutive screw highways
and
by
Figure 6. For
, we can prove that the ant’s reachability problem is PSPACE hard, since
Figure 5’s TURN makes [
15]’s PSPACE completeness proof valid. However, we have not yet found any non-zero density trajectory of Langton’s ant for
. For every even number
h, particularly the standard torus
, Langton’s ant’s known computational complexity is only the PTIME-hardness of Gajardo, Moreira, and Goles [
14]. Proving PSPACE-hardness for even-twist torus is wide open.