1 Introduction

1.1 Need for an autocatalytic and isothermal WPCR protocol

A primary challenge in nanoscience is the design of synthetic molecular devices that run autonomously (meaning that the program executes without any external mediation over multiple work cycles) and programmable (meaning that the machine’s behavior can be modified without completely redesigning the system). In the last few years, the idea of constructing complex devices at the molecular scale using synthetic materials, such as synthetic DNA, has gone from theoretical concept to experimental reality. One such autonomous molecular computing device is called a Whiplash PCR (WPCR) machine (Hagiya et al. 1999), equivalent to a restricted class of finite automata (namely those that can be represented as a directed acyclic graph). In this machine, the current state is encoded at the 3′ end of a DNA single strand while the remainder of the strand encodes the state transition rules. The original machine works as follows: using appropriate thermal cycles, the current state anneals to the correct transition rule and, next, a polymerase extends the 3′ end of the strand to copy the next state from the encoded transition rule. The only limitation of this system is that it can execute only a single step before it requires significant environmental changes (thermal cycles) to continue the computation. This paper presents a protocol that converts a WPCR system into an autonomous computing device, thus eliminating the need for external mediation to enable further steps. This capability is important if we wish to use these machines outside fully equipped laboratories.

1.2 Importance of locally programmable molecular computation

Although existing autonomous molecular computing devices e.g., DNA based tiling assembly (Winfree et al. 1998) and restriction enzyme based automata (Benenson et al. 2001) are computationally quite powerful (Soloveichik and Winfree 2005), they are not capable of executing distinct programs in parallel. In contrast, many complex molecular mechanisms found in the cell are more flexible and can perform a diverse set of tasks simultaneously. Whiplash PCR (Matsuda and Yamamura 2002; Nishikawa and Hagiya 1999; Rose et al. 2001; Winfree 1998b; Hagiya et al. 1999; Sakamoto et al. 1999) allows parallel execution because each machine holds its own program and thus multiple, distinct molecular programs can run simultaneously in the same reaction tube.

1.3 Engineering DNA for biomolecular computation

Before we discuss how DNA can be the building block of a WPCR machine, we must introduce some of the primary methods by which DNA can be engineered and used in the correct execution of a WPCR machine. The three primary techniques are hybridization, strand displacement and polymerization.

DNA Hybridization is the process of combining two complementary, single-stranded DNA molecules into double-stranded molecule. DNA (and RNA) can bind to their complements under normal conditions or by when the strand mixture is cooled. Simple hybridization has been used to make a large variety of complex structures such as tiles and lattices (Mathieu et al. 2005; Shih et al. 2004; Goodman et al. 2004). The opposite of hybridization is dehybridization. The latter can be achieved by heating the solution mixture.

Polymerized chain reaction (PCR) is a common method for amplifying a target DNA molecule, which can be a single gene or merely part of it (Fig. 2). Through PCR, a small amount of DNA can be amplified several times and the richness and the fidelity of the product facilitates many applications, such as detecting hereditary diseases, identifying bacterial species, cloning genes, DNA computing and many others. A recent paper used DNA polymerase ϕ29 to power a nano-transport device (Sahu et al. 2008).

Branch migration or strand displacement is the process by which a single, invading DNA strand extends its partial pairing with its complementary strand as it displaces a resident strand from a DNA duplex (Fig. 2).

1.4 Previous methods for WPCR computing devices and their limitations

Hagiya et al. (1999) first proposed and experimentally demonstrated (only for a limited number of steps) a WPCR machine. It was not easy to increase the number of steps because of a phenomenon called back-annealing (also known as back-hybridization), where a hairpin with a longer double stranded (ds) DNA region is preferentially formed over one with a shorter ds-DNA region. Sakamoto et al. (1999) suggested a modified protocol where successive transitions were carried on at the same temperature, thus preventing back-hybridization. They also proposed a protocol for preventing out-of-frame annealing which happens because portions of two adjacent sequences constitute the sequences complimentary to a third state sequence. However, this work did not significantly increase the number of steps the WPCR machine could execute before stalling at an intermediate step. Later, Rose et al. (2001) proposed a scheme using targeted PNA 2/DNA triplex formation. This triplex region destabilized the hairpin structure, thus preventing back-hybridization. Although this protocol can be isothermal, it is not autocatalytic. Further, it has been not yet been implemented and its role in increasing the number of steps a WPCR machine can execute before stalling is not clear. Two recent papers by Rose et al. (2006; Komiya et al. 2008) proposed and experimentally demonstrated isothermal (no thermal cycling required) conditions for the functioning of a WPCR machine using strand displacement techniques. However, one still needs to add a rule protection strand after each polymerization step to drive the computation forward. Hence if we wish to overcome this problem and also allow flexibility of applications, we need to design an autocatalytic (a system that reactivates itself) and isothermal (no thermal cycles required) protocol for WPCR that would allow the machine to compute for a reasonable number of steps before succumbing to back-hybridization in places other than a laboratory.

1.5 Our contribution

Our main contribution in this paper is the design of a WPCR machine that eliminates the need for any other external mediation and, thus, the resultant machine is isothermal, autocatalytic and capable of preventing back-hybridization. By isothermal we mean that the temperature of the reaction mixture is constant throughout computation. However, our design requires an additional preparation stage which precedes the computation stage and this step is not isothermal. This protocol is also in contrast with the definition of isothermal by Sakamoto et al. (1999) who defined isothermal as a design where the denaturation of the previous state and annealing of the next state occur at the same temperature. This design still needs external thermal control for multiple state transitions. By autocatalytic, we mean that, once the protein enzyme is introduced in the solution, it drives computing on its own. This protocol can again be contrasted against the protocol for PNA-mediated WPCR (Rose et al. 2001) where, after each polymerization step, the mixture needs to be washed by bis-PNA. Recall that back-hybridization is an event where the WPCR machine stalls because the 3′ end of the strand binds to the previous transition rule in preference to the new transition rule (also the correct one) since the former is energetically more stable. Several protocols have been proposed (Sakamoto et al. 1999; Rose et al. 2001, 2006; Komiya et al. 2008) to prevent back-hybridization. However, to the best of our knowledge, there exists no WPCR protocol that is both isothermal and autocatalytic and capable of preventing back-hybridization simultaneously. Our isothermal and reactivating protocol is partially inspired by our previous work where we used a combination of DNA polymerization and strand displacement events to minimize errors in computational tile assembly (Majumder et al. 2008).

The key idea in our design of an isothermal, reactivating WPCR (IR-WPCR) machine is to use primer extension of a secondary strand to dehybridize the 3′ end of the WPCR strand after the next state is copied to it. Thus, the 3′ end of the WPCR strand is now free to bind to the complement of the new current state. This action essentially eliminates the thermal cycling required by the original WPCR machine to execute a state transition. We give three versions of IR-WPCR: (1) a protocol where a state transition rule is no longer available for computation after the next state is copied (Sect. 3), (2) a protocol in which a rule can be made “reusable” by using an auxiliary strand that restores the original state of the secondary primer (Sect. 4) and finally (3) a protocol that allows reuse of transition rules while preventing back-hybridization (Sect. 5). The protocol presented in Sect. 5 is the most significant protocol in this paper: isothermal reactivating WPCR where the states are reusable and yet it is capable of preventing back-hybridization using a type of WPCR that we call folding WPCR. A primary assumption in all the above-mentioned protocols is that the concentration of the WPCR strand is such that two or more copies of WPCR strands do not interact among each other. We also prove that this machine is computationally equivalent to the original WPCR machine (Sect. 6). We further compute the state transition rate for an IR-WPCR machine and the probability of preventing back-hybridization at every step (Sect. 7). We also estimate the rate at which states are made reusable in the reusable rule protocol. Additionally, we present a DNA sequence design of a 3 state IR-WPCR machine and an experimental verification plan (Sect. 8). It should be remembered, however, that this example is meant to demonstrate the isothermal and autocatalytic aspects of the protocol and not the computational power of a WPCR device.

1.6 Organization of the paper

In Sect. 1, we briefly described a WPCR machine and its role as a autonomous and programmable molecular device. In particular, we discussed the advantages of the ability of a WPCR device to hold programs in the device itself. Furthermore, we discussed some of the previous approaches for realizing the concept of a WPCR machine and their shortcomings. In Sect. 2, we briefly describe the original Whiplash PCR machine and subsequently in Sect. 3 we present an isothermal and autocatalytic WPCR system. However, the protocol presented in Sect. 3 does not allow transition rules to take part in computation once the next state is copied from that site. Hence in Sect. 4 we discuss another protocol where we can make a transition rule reusable using an additional strand displacement operation. Yet this protocol is not suitable for preventing back-hybridization. Thus in Sect. 5 we describe a protocol for handling back-hybridization without change in temperature. Next in Sect. 6 we prove how an IR-WPCR machine capable of preventing back-hybridization can simulate a restricted class of finite state automata. In Sect. 7 we present a continuous time Markov Chain model for the working of an IR-WPCR machine and estimated the rate of state transition and the likelihood of preventing back-hybridization in each computational step. In Sect. 8 we propose a DNA design of a 3 state machine and describe how a reusable rule WPCR device can implement it. Finally, in Sect. 9 we conclude the paper with a summary of our contributions and future directions.

2 Original Whiplash PCR system

In the original WPCR machine, the transition table is encoded on a single stranded DNA, W as \( S-a_{1}-b_{1}-S-a_{2}-b_{2}-{\cdots}-S-a_{n}-b_{n}\) where each pair a i  − b i represents the transition from state a i to state b i . Here and in the rest of the paper, any symbol s encodes for a DNA sequence and s* encodes for its complementary sequence. The stopper sequence S isolates one state transition rule from another. The 3′ end of the same strand encodes the current state. For the description of the rest of the protocol, refer to Fig. 1. We represent the stopper sequence S as a black square in the figure. Without loss of generality (w.l.o.g.), let us assume that the current state of the machine is \(a_{i}^{\ast}\). Following the transition table, a i can transition to b i . Once \(a_{i}^{\ast}\) hybridizes with a i (Fig. 1: State S1) in W, polymerase extends the 3′ end of W to copy b i (Fig. 1: State S3). The polymerase halts after transcribing the bases complementary to b i because of S which is generally implemented by emitting one of the bases in the solution. Using appropriate thermal cycling, W is then denatured. Consequently, it loses the hairpin structure (Fig. 1: State S4). Once the mixture is cooled, the 3′ end of newly extended W (now bearing \(b_{i}^{\ast}\) as the current state) hybridizes with another section of itself which encodes the appropriate transition rule (in this rule a j  = b i is the current state and b j is the next state; Fig. 1: State S5). Although input is not part of the description of the WPCR machine, it has been suggested that input be provided as part of the initial state and the encoding of the transition table updated to include inputs in the manner \(S-a_{i}-I_{i}-b_{i}\) for the ith transition rule.

Fig. 1
figure 1

Schematic of the protocol for the original Whiplash PCR machine: S1: initial state of the WPCR strand W with current state being \(a_i^{\ast}.\) S2: polymerase binds to the 3′ end of W (bearing the current state). S3: next state \(b_i^{\ast}\) is copied at the head of W by primer extension. S4: the mixture is heated so that W loses its hairpin structure. S5: the solution is cooled so that the head of W can bind to the new current state \(b_i^{\ast}=a_j^{\ast}\) encoded at the 3′ end of the strand and the whole state transition repeats again beginning with State S2

As mentioned in Sect. 1, back-hybridization is a serious limitation of the original Whiplash PCR system. Recall that back-hybridization refers to the phenomenon where a longer hairpin is preferentially formed over a shorter hairpin. As a result, the machine instead of binding to a rewrite rule whose current state matches with the new current state of the machine (also the next state of the previous rewrite rule) favorably binds to the rewrite rule from the previous step and, hence, it is stuck in this particular transition, since there are no new states to copy. This phenomenon has been illustrated in Fig. 4.

3 IR-WPCR machine with non-reusable rules

In IR-WPCR with non-reusable rules, computation comprises of the following steps after the 3′ end of W binds to current state in rule R i : (a) as with the original WPCR protocol, copying the next state at the 3′ end of the WPCR strand W, (b) dislodging a secondary primer sequence P i , which is specific to the transition rule R i from its initial position triggered by the primer extension on W, (c) subsequent hybridization of P i to its final position in rule R i and (d) dislodging of 3′ end of W by primer extension of P i , allowing the 3′ end of W to bind to the new transition rule. Observe that (b) and (d) act like a logical toggle switch allowing for an isothermal, autocatalytic reaction.

In this version of WPCR, each rule is encoded as a 7-tuple \( < x_{i},y_{i},z_{i},a_{i},b_{i},w_{i},y_{i} > \) where a i still represents the current state and \(b_{i}w_{i}y_{i}\) represents the next state where the b i in IR-WPCR is not the same as b i in the original WPCR strand. Rather, the original b i is now divided into 3 subsequences b i , w i and y i . The other regions in this tuple are required for destabilizing the 3′ end of the strand once the next state is copied at the end of it. In this machine, the transition table with n rules is encoded on a single stranded DNA as \(S-x_{1}-y_{1}-z_{1}-a_{1}-b_{1}-w_{1}-y_{1}-{\cdots}-S-x_{i}-y_{i}-z_{i}-a_{i}-b_{i}-w_{i}-y_{i}-{\cdots}-S-x_{n}-y_{n}-z_{n}-a_{n}-b_{n}-w_{n}-y_{n}.\) The 3′ end of the single strand still encodes the current state as in original WPCR. We also tether the transition table portion of W to another stable nanostructure to prevent formation of any undesired secondary structure (Figs. 2, 3). The latter is mostly a double stranded DNA intercepted by sections of DNA that is bound to each transition rule. Since the rigidity of a double-stranded DNA is well known we use this particular nanostructure as a support in our designs.

Fig. 2
figure 2

Left: branch migration; Right: extension of primer strand bound to the template by DNA polymerase

Fig. 3
figure 3

Complete WPCR Strand for isothermal and autocatalytic program execution (Rule R i on focus). Although details are provided in this figure, the emphasis is on the layout of the overall strand. In particular, note that most of the strand representing the transition rules is stabilized using a supporting DNA nanostructure and only the current state of the machine is allowed to freely bind to an appropriate rewrite rule using a lag region W

3.1 Computing with a non-reusable rule IR-WPCR strand

Suppose we have the single strand in the form shown in Fig. 3 prior to the addition of polymerase. In Sect. 2, we will discuss how we can obtain this particular secondary structure. W.l.o.g we will assume that the 3′ end of the single strand encodes for the complement of the current state a i in rule R i . For clarity, we will refer to a figure that focuses only on the events at R i (Figs. 4, 5).

Fig. 4
figure 4

Back-hybridization: transition from state a3 to state a4 happens as usual but for the next transition a4 to a5, the 3′ end of the machine preferentially binds with the old transition rule. This is because \(a_{3}^{\ast}\) along with \(a_{4}^{\ast}\) at the 3′ end of the machine has a longer hybridization region when bound with rewrite rule \(a_3 \rightarrow a_4 \) compared to when only \(a_{4}^{\ast}\) binds with the current state of the rewrite rule \(a_4 \rightarrow a_5. \) Consequently, the machine is stuck in state a4

Fig. 5
figure 5

Evaluation stage for non-reusable rules IR-WPCR protocol with the focus being only on the transition rule R i to which the current state is hybridized: S1 WPCR strand W with protection strand P i encoded as \((x_ip_iy_i)^{\ast}\) partially hybridized with rule R i . Also the 3′ end of W, bearing the current state \(a_i^{\ast}\) is hybridized to a i of R i . S2: polymerase binds to the 3′ end of W. S3: polymerase extends \(a_i^{\ast}\) to copy b i w i y i , thus displacing \(w_i^{\ast}y_i^{\ast}\) of P i from w i y i of rule R i located further away from x i in R i . S4: \(y_i^{\ast}\) of P i binds to y i located next to x i in R i . S5: polymerase binds with the 3′ end of P i . S6: 3′ end of P i is extended by the polymerase to copy z i a i b i w i y i , thus displacing 3′ end of W which has the new current state a j  = b i w i y i . S7: 3′ end of W bearing a * j binds to the a j in rule R j and the process repeats starting with the polymerase binding to the 3′ end of W as shown in State S2

Once \(a_{i}^{\ast}\) binds to a i in R i (Fig. 5: State S1) in presence of polymerase (Fig. 5: State S2), the next state b i w i y i is copied at the 3′ end of W, thus dehybridizing the \((w_{i}y_{i})^{\ast}\) portion of the protection strand P i encoded as \(({x_{i}p_{i}w_{i}y_{i}})^{\ast}\) (Fig. 5: State S3). The \(y_{i}^{\ast}\) portion of P i is now free to hybridize with the y i portion on the rule R i that is closer to x i (Fig. 5: State S4). The 3′ end of P i , in presence of polymerase (Fig. 5: State S5), then extends up to the stopper sequence S (shown in black filled squares in the figure), thus displacing the 3′ end of W (Fig. 5: State S6). This rule site is now completely unavailable for further hybridization and hence this protocol is called non-reusable rules IR-WPCR. The new current state \(a_{j}^{\ast}=(b_{i}w_{i}y_{i})^{\ast}\) at the 3′ end of W then binds to a j which is the current state for transition rule R j (Fig. 5: State S7). At this stage, the next state transition begins with the polymerase binding to the head (3′ end) of W, encoding the current state \(a_{j}^{\ast}\) (Fig. 5: State S2). Hence the state machine operates without thermal cycles and uses only polymerase to facilitate denaturation of the 3′ of W from the old rule. Moreover, each rule allows copying of next state exactly once and hence we call this machine non-reusable rule IR-WPCR machine.

3.2 Preparing a non-reusable rule IR-WPCR strand for computation

This section will describe how to obtain the secondary structure of the WPCR strand W as shown in Fig. 3. In order to ensure that the hairpin structure is stable, we tether the single strand with another nanostructure which has extended ds-DNA regions. For clarity, we again focus only on rule R i for the description of the preparation stage (Fig. 6). We can use either a simple or a multi-step complex preparation protocol to ensure that each rule in W is properly “protected”.

Fig. 6
figure 6

Complex preparation protocol with respect to only rule R i : S1 WPCR strand W tethered to support (not shown in the Figure). S2: \((y_iz_ic_i)^{\ast}\) is added to the solution. One copy binds to the y i near x i and another binds to y i further away from it. S3: the copy of \((y_iz_ic_i)^{\ast}\) that binds to the y i in R i further away from x i is removed by the addition of y i z i . The duplex thus formed is then removed from the solution using magnetic beads (not shown here). S4: Protection strand P i encoded as \((x_ip_iw_iy_i)^{\ast}\) is introduced and it hybridizes with the x i and free w i y i of rule R i . S5: the copy of \((y_iz_ic_i)^{\ast}\) that is bound to the y i in R i nearer to x i is removed by the addition of y i q i z i . Here too, the duplex is later removed using magnetic beads

In the simple preparation protocol, once we have guaranteed that the secondary structure of W is that of a hairpin, we directly introduce the protection strands P i for each rule R i into the solution. Since the \(w_{i}y_{i}\) section is longer than the y i region near x i for each R i the protection strand for R i acquires the configuration shown in Fig. 5: State S1 with high probability. For more guaranteed hybridization of the protection strand with its corresponding transition rules, one may adhere to the complex preparation protocol which is presented in the following paragraph.

The Complex preparation protocol (Fig. 6) comprises of the following steps: once W is tethered to the supporting nanostructure, strand \((y_{i}z_{i}c_{i})^{\ast}\) is added to the solution and the resultant nanostructure is shown in Fig. 6 (State S2). However, in order to attain the state shown in Fig. 5: State S1, we need to remove the copy of \((y_{i}z_{i}c_{i})^{\ast}\) that is bound to y i further away from x i for each rule R i . Hence we add y i z i for each rule R i and the toehold z i in y i z i facilitates the displacement of \((y_iz_ic_i)^{\ast}\) (Fig. 6: State S3). If y i z i is biotin labeled, then we can easily remove it from the solution using streptavidin coated magnetic beads. This protocol ensures that \((y_{i}z_{i}c_{i})^{\ast}\) that is bound to y i further away from x i is permanently removed from the solution and would not interfere with the final desired secondary structure of W. In the second last step of this protocol we add the protection strand P i encoded as \((x_{i}p_{i}w_{i}y_{i})^{\ast}\) and when it is partially hybridized to W, the latter looks like the one shown in Fig. 6 (State S4). Once P i is in the desired location we add y i z i c i to remove \((y_iz_ic_i)^{\ast}\) hybridized with the y i region near x i by strand displacement using c i as the toehold (Fig. 6: State S5). By including a biotin in y i z i c i the double stranded complex can be easily removed from the solution using streptavidin coated magnetic beads. It is important to add y i z i c i after P i so that the latter does not hybridize with y i closer to x i . If it does so then as soon as polymerase is added, P i will be extended, making that particular rule completely unavailable even before it can take part in the computation. Consequently, we have W in the desired state (Fig. 3), ready to start computing as soon as polymerase is added.

3.2.1 Benefits and limitations

The non-reusable rule IR-WPCR machine works very well for reducing back-hybridization since each rule can only be used once and is concealed thereafter. Consequently the 3′ end of the WPCR machine cannot hybridize with the old rule and is forced to bind with the correct transition rule, thus preventing back-hybridization. However, inability to reuse a transition rule restricts the computational power of the machine.

The only limitation of this machine is that a rule can only be used once. One way to avoid this problem is to have several redundant copies of each transition rule encoded in W. However, we propose a more elegant solution to address this problem of a rule reusability using strand displacement in Sect. 4.

4 IR-WPCR machine with reusable rules

To address the limitation of a non-reusable rule IR-WPCR machine, this section describes a protocol that uses an additional strand A i to displace P i after primer extension. Refer to Fig. 7 for the description of the protocol with respect to transition rule R i . This protocol comprises of the same steps: (a)–(d) as the non-reusable rule IR-WPCR protocol (See Sect. 3). Additionally it has a final step (e) where an auxiliary strand A i (present in the reaction mixture) changes the secondary structure of P i . This strand A i can partially hybridize with the extended section of P i and force P i to return to its original “protection” state, permitting further computation using this transition rule. In a manner, the rule is “reset” after the state transition takes place. Hence this protocol is called reusable rule IR-WPCR. In the following section we describe how a state transition occurs in this new protocol. The preparation stage for this protocol is basically the same as that of non-reusable rules IR-WPCR (See Sect. 2). The only addition is that the auxiliary strands are present in the solution before the polymerase is introduced.

Fig. 7
figure 7

Evaluation Stage in reusable rule IR-WPCR with the focus being only on the transition rule to which the current state is hybridized: S1: WPCR strand W with protection strand P i encoded as \((x_ip_iy_i)^{\ast}\) partially hybridized with rule R i . Also the 3′ end of W, bearing the current state a * i is hybridized to a i of R i . S2: polymerase binds to the 3′ end of W. S3: Polymerase extends a * i to copy b i w i y i , thus displacing \((w_iy_i)^{\ast}\) of P i from w i y i of rule R i located further away from x i in R i . S4: \(y_i^{\ast}\) of P i binds to y i located next to x i in R i . S5: Polymerase binds with the 3′ end of P i . S6: 3′ end of P i is extended by the polymerase to copy z i a i b i w i y i , thus displacing 3′ end of W which has the new current state a j  = b i w i y i . S7: A i encoded \((w_{i}y_{i}z_{i}a_{i}b_{i})\) present in the solution displaces \((w_{i}y_{i}z_{i}a_{i}b_{i})^{\ast}\) region of the protection strand P i so that the configuration of the latter can be reset. S8: 3′ end of W bearing a * j binds to the a j in rule R j and the process repeats again starting with the polymerase binding to the 3′ end of W as shown in State S2

4.1 Computing with a reusable rule IR-WPCR strand

The first part of evaluation is the same as that in non-reusable rules IR-WPCR protocol (Fig. 7(Right): State S1–State S6). However, unlike the other protocol, in this method, the solution additionally contains a large concentration of A i , which is encoded as \(w_{i}y_{i}z_{i}a_{i}b_{i}.\) Once P i is extended, its \(w_{i}^{\ast}\) region is used as a toehold by A i to displace the former. However, the \((w_{i}y_{i})^{\ast}\) portion at the end of extended P i is still free to hybridize with its complementary region on R i (Fig. 7(Right): State S7). This step ensures that secondary structure of P i is “reset” enabling R i to participate in computation again. The last stage of evaluation is the same as in non-reusable rule IR-WPCR where the new state corresponds to \(b_iw_iy_i=a_j\) for some j and hence the 3′ end of the WPCR strand W binds to rule R j (Fig. 7(Right): State S8).

This additional step of resetting the transition rule adds a number of new behaviors to the computation. For example, after each state transition, the portion on P i between the ends hybridized with R i has an additional ds-DNA region encoded as \(w_iy_iz_ia_ib_i\). In other words, P i becomes longer each time R i is used. Moreover, note that a copy of A i is consumed each time R i is used so the solution must have an excess of A i . However, at the beginning of the program execution, each P i binds with R i in W in preference to A i since x i as well as w i y i hybridization in P i R i complex is much more favorable than just w i y i hybridization in P i A i complex. P i must also contain a stopper sequence to prevent P i from being extended in an undesired direction.

4.1.1 Benefits and limitations

A reusable rule IR-WPCR machine is computationally equivalent to the original WPCR machine. Consequently, reusable rules IR-WPCR machines suffers from all the limitations of the original WPCR, such as back-hybridization and out-of-frame annealing. Consequently, previously mentioned protocols (Sakamoto et al. 1999; Rose et al. 2001) to avoid these problems (e.g., PNA mediation for back-hybridization) can be incorporated into our system at the expense of losing full autonomy. However, in the following section we describe a relatively more complex IR-WPCR machine that can reuse its rules and still prevent back-hybridization.

5 Reusable rule IR-WPCR machine that prevents back-annealing using folding WPCR

5.1 Folding Whiplash PCR system

Folding WPCR using thermal cycling is a novel technique for preventing back-annealing while computing with a WPCR machine. It also serves as an important step for understanding the relatively complicated IR-WPCR machine with reusable states that prevents back-hybridization using folding WPCR. Refer to Fig. 8 for the rest of the discussion about folding WPCR. The current state for the ith transition is still a i and the next state is b i . However, the encoding of a transition rule in this protocol is \(a_{i}x(a_{i})^{\ast}b_{i}S(b_{i})^{\ast}a_{i}S.\) When cooled, in each transition rule, the \((a_{i})^{\ast}b_{i}S(b_{i})^{\ast}a_{i}\) section forms a hairpin loop. Thus only the current state of each transition rule is available for binding with the 3′ end of the machine. This is the primary trick to preventing back-hybridization. Since the rest of the transition is always hidden in a tight hairpin loop, the machine cannot preferentially form longer step loops over shorter ones as is the case with the original protocol. The detailed protocol for folding WPCR is as follows: (i) without loss of generality, let us assume that the 3′ end of the machine encodes \(a_{i}^{\ast}\). When the system is cooled, it binds to the current state of rule R i . (ii) Polymerase next binds to this end. With high strand displacement capability, it opens up the stem loop and copies the encoding on the rule until the first stopper sequence S. (iii) When heated, the strand denatures and 3′ end of the strand bears \((a_{i})^{\ast}x^{\ast}a_{i}(b_{i})^{\ast}.\) (iv) When cooled, \((a_{i})^{\ast}x^{\ast}a_{i}\) part of it, forms a stem loop and 3′ end now has only \((b_{i})^{\ast}\) available for binding. This encodes for the next current state a j which preferentially binds to rule R j and not R i as in the original protocol where the 3′ end bore \((a_{i}b_{i})^{\ast}\) and hybridized with rule R i , since longer the hybridization, the more stable is the secondary structure. On the contrary, in the folding WPCR protocol, neither \((a_{i})^{\ast}\) is available at the 3′ end of WPCR strand nor b i in rule R i , since each is hidden in a stable hairpin loop. It should be remembered that the next state b i , in each rule R i is available only when it is copied to the 3′ end of the WPCR strand. For the remainder of the time it remains hidden in a stem loop. Hence, neither b i from R i nor \(a_i^{\ast}\) from the 3′ end of the strand is available to facilitate the hybridization of rule R i with two successive encodings of the current states (\(a_i^{\ast}\) and \(a_j^{\ast}\)) at the 3′ end of the WPCR strand W. Consequently this technique prevents back-hybridization.

Fig. 8
figure 8

Schematic of the protocol for the folding Whiplash PCR machine: S1: initial state of the WPCR strand W. S2: the solution is heated such that the next state in each rule hidden in a hairpin loop with current state of the machine being a * i . S3: polymerase binds to the 3′ end of W (bearing the current state). S4: next state \(b_i^{\ast}\) is copied at the head of W by primer extension and hairpin loop is opened. S5: the mixture is heated so that W loses its hairpin structure (It may even open up the individual hairpin loops in each rule, not shown here). S6: the solution is cooled so that the head of W can bind to the new current state \(b_i^{\ast}\,=\,a_j^{\ast}\) encoded at the 3′ end of the strand and the whole state transition repeats again beginning with State S2. Note that the next state in each rule is hidden in a stem loop as is the old current state encoded at the 3′ end of the WPCR strand. These two stem loop formations are key to preventing back-hybridization in this protocol

5.2 Reusable rule IR-WPCR machine that prevents back-hybridization using folding WPCR

Refer to Fig. 9 for the reusable rule IR-WPCR machine that uses folding WPCR to prevent back-hybridization.Footnote 1 In the previously mentioned reusable rule IR-WPCR machine, recall that for rule R i , the current state is a i while the next state is \(b_{i}w_{i}y_{i}.\) However, in the reusable rule IR-WPCR machine that also uses folding WPCR to prevent back-hybridization, the state encoding is \(x_{i}y_{i}z_{i}a_{i}x(a_{i})^{\ast}b_{i}w_{i}y_{i}S(b_{i})^{\ast}a_{i}.\) Under suitable temperature, \((a_{i})^{\ast}b_{i}w_{i}y_{i}S(b_{i})^{\ast}a_{i}\) forms a stem loop and the protection strand P i hybridizes with x i and w i y i . W.l.o.g., assume that the current state is a i and thus the 3′ end of the WPCR strand binds to rule R i . When the polymerase binds to the 3′ end of the WPCR strand, it opens up the stem loop hiding part of the next state encoding in this rule. The 3′ end of the WPCR strand is extended as far as the first stopper sequence in rule R i . This event, in turn, displaces the 3′ end of the protection strand P i . The latter now binds to its second best match in rule R i namely y i . Polymerase now binds to the 3′ end of P i and extends it to displace the 3′ end of the WPCR strand (this end has the new current state of the machine, \(b_{i}w_{i}y_{i}\) encoded in it). This event marks the completion of a state transition. An auxiliary strand already in solution, then resets rule R i to its original configuration. However, the only difference between this protocol and the reusable rule IR-WPCR machine that cannot prevent back-hybridization is that the former uses folding WPCR to minimize back-annealing. In other words, at the end of any state transition (say R i for instance), the 3′ end of the WPCR strand not only has \((b_iw_iy_i)^{\ast}\) encoded in it, but also has \((a_{i})^{\ast}xa_{i}\) preceding the \((b_iw_iy_i)^{\ast}\) encoding. This \((a_{i})^{\ast}xa_{i}\) encoding folds into a loop and hides the previous current state \((a_{i})^{\ast}.\) Similarly, in rule R i , b i portion of the next state \(b_{i}w_{i}y_{i}\) is hidden in a loop after being copied at the 3′ end of the WPCR strand and w i y i of the same next state is bound to P i . The simultaneous unavailability of previous current state at the 3′ end of W and the next state in the previously copied rule R i prevents longer stem loop formation (between the 3′ end of the WPCR strand and the previous rule R i ) and encourages the 3′ end of the WPCR strand to bind with rule R j instead, thus minimizing back-hybridization.

Fig. 9
figure 9

Evaluation Stage for reusable rule IR-WPCR protocol that prevents back-hybridization using folding PCR with the focus being only on the transition rule R i to which the current state is hybridized: S1: WPCR strand W with protection strand P i encoded as (x i p i y i )* partially hybridized with rule R i . Also the 3′ end of W, bearing the current state a * i is hybridized to a i of R i . S2: the temperature of the solution is such that the b i part of the next state \(b_{i}w_{i}y_{i}\) forms part of a stem loop. S3: polymerase binds to the 3′ end of W. S4: polymerase extends a * i to copy b i w i y i , thus displacing \(w_i^{\ast}y_i^{\ast}\) of P i from w i y i of rule R i located further away from x i in R i . Furthermore it opens the stem loop in which part of the next state was hidden. S5: \(y_i^{\ast}\) of P i binds to y i located next to x i in R i . Polymerase binds with the 3′ end of P i . S6: 3′ end of P i is extended by the polymerase to copy \(z_ia_ix(a_{i})^{\ast}b_iw_iy_i,\) thus displacing 3′ end of W which has the new current state a j  = b i w i y i . S7: A i encoded \((w_{i}y_{i}z_{i}a_{i}xa_{i}^{\ast}b_{i})\) present in the solution displaces \((w_{i}y_{i}z_{i}a_{i}xa_{i}^{\ast}b_{i})^{\ast}\) region of the extended protection strand P i so that the configuration of the latter can be reset. Furthermore, at the 3′ end of the WPCR strand the old state a i forms part of a hairpin loop \((a_{i})^{\ast}x^{\ast}a_{i}\) because of the solution temperature. S8: The next state of R i is reset to its stem loop configuration as well. Additionally, 3′ end of W bearing \(a_j^{\ast}\) binds to the a j in rule R j . At this stage, the process repeats starting with the polymerase binding to the 3′ end of W as shown in State S2

6 Simulation of a finite state automata by a reusable rule IR-WPCR that prevents back-hybridization using folding WPCR

In this section we first present a proof by induction on the computational capability of the original WPCR machine since it is the simplest case. Next we show that the isothermal reactivating WPCR machine with reusable states that prevents back-hybridization using folding WPCR is computationally equivalent to the original WPCR machine. Combining these two results we can show that isothermal reactivating WPCR machine with reusable states that prevents back-hybridization using folding WPCR can simulate a restricted class of finite state machine. This restricted class of finite state machines refers to those machines that can be represented as a directed acyclic graph. In other words, input string is of finite length and, for each input, each state is visited at most once. One important application of such a finite state machine could be in molecular disease detection systems. With the disease symptoms representing inputs to the automata, the accept state of the machine will be the one that detects all the symptoms in sequence (meaning the finite state automaton computes the conjunction of all the symptoms present).

Lemma

A WPCR machine with n transition rules can simulate a finite state machine\(M = (Q, {\Upsigma,}{\delta,}q_0)\)where\(Q = \{ a_1, b_1, \ldots, a_i, b_j, \ldots, a_j, b_j, \ldots, a_n, b_n\}\)is the set of states, \(\Upsigma = \{\epsilon\} \)is the input set, q0 = {a1} is the start state and\(\delta =\{ (a_1, b_1), \ldots, (a_i, b_i), \ldots, (a_j, b_j), \ldots, (a_n, b_n)\}\)is the set of transition functions and |δ| = n.Footnote 2

Proof

Since computation takes place by DNA hybridization, x* is the complement of x and they indicate the same state. The transition table is encoded in a single strand of DNA as \(a_1b_1Sa_2b_2S\ldots Sa_nb_n,\) where S indicates the separator between two states. Since the only input is the empty string ε, we neither have included it in the encoding of the transition rules or at the 3′ end of the WPCR strand that encodes the current state of the machine. We will do induction on the number of transitions, k, the machine has undergone.\(\square\)

Base case

k = 1. \(a_1^{\ast}\) is encoded at the 3′ end of the WPCR strand which represents the current state of the machine. Recall that the machine has n transition (a1, b1), (a2, b2) … (a n , b n ) encoded as a1b1Sa2b2S... a n b n S at the 5′ end of the WPCR strand. S is a stopper sequence that is essential for the biochemical implementation of a state transition using polymerase. It is also a separator for two adjacent state transition encodings as we have mentioned before. The solution is cooled and since \((a_1)^ {\ast}\) is complement to the current state a1 of the transition rule (a1, b1), it hybridizes with it, thus forming a stem loop. A polymerase present in solution next extends \((a_1)^{\ast}\) to copy the next state b1 from the transition rule and stops because of the presence of S, the stopper sequence. The solution is then heated, so that the strand is denatured. This marks the end of the state transition (a1, b1) since the 3′ end of the WPCR strand now bear \((b_1)^{\ast},\) the new current state.

Hypothesis

Assume that the machine has undergone km transitions. At the end of it, the current state of the machine is a i . We will now show how it can simulate the \((m+1)^{st}\) transition.

Induction

The 3′ end of the WPCR strand encodes for the current state a i in the form of (a i )*. When the solution is cooled, it binds to the current state a i of transition rule (a i , b i ) encoded as a i b i S. Next, in presence of polymerase, it is extended to copy only the next state b i and none of the encoding beyond it because of S. The solution when heated, the hairpin is converted into a single strand without any secondary structure. This marks the end of the (m + 1)st state transition with the new current state b i encoded at the 3′ end of the WPCR strand as \((b_i)^{\ast}.\) \(\square\)

Lemma

A reusable rule IR-WPCR machine that prevents back-hybridization using folding WPCR is computationally equivalent to the original WPCR machine that uses thermal cycling to execute a state transition.

Proof

The approach for this proof involves showing that a state transition in a reusable rule IR-WPCR machine that prevents back-hybridization using folding WPCR, say machine M 1 can be simulated by the original WPCR machine, say M 2 and vice versa. In other words, we prove that when M 2 with current state encoding \((a_i)^{\ast}\) undergoes state transition a i to b i (rule R i ), M 1 undergoes the transition a i (current state in rule R i ) to b i w i y i (next state in rule R i ). The other direction holds as well. Recall that in machine M 2 rule R i is encoded as a i b i S while in M 1, it is \(x_{i}y_{i}z_{i}a_{i}x(a_{i})^{\ast}b_{i}w_{i}y_{i}S(b_{i})^{\ast}a_{i}.\) The difference in next state encoding arises from the fact that M 1 and M 2 use two very different protocols for executing a state transition.

While in M 2, the main driving force is polymerase and thermal cycling, M 1 is mostly driven by strand displacement along with polymerization. Hence, when we cool the solution with M 2 in it, the 3′ end of the WPCR strand binds to a i in rule R i . However, there is no external mediation involved in the running of M 1, once the polymerase is introduced in the solution containing M 1. In fact, we maintain the temperature of this solution such that 3′ end of M 1 bearing \(a_{i}^{\ast}\) can bind to a i in rule R i . The next step is the same in the program execution with both machines when polymerase binds to the 3′ end of each machine. However, in the extension phase, while in M 2, b i is copied directly at the 3′ end of the strand, in M 1, the next state is hidden in a hairpin loop and a polymerase with good strand displacement capability is needed in order to open the stem loop and copy the next state b i w i y i . Some additional sequences are copied too, such as \(x^{\ast}a_{i}.\) These sequences near the 3′ end of M 1 are essential for preventing back-hybridization that is a major drawback with M 2. We will discuss this difference shortly.

In the context of highlighting the differences in the two protocols, once the next state is copied, M 2 depends on external energy such as heating to denature the strand so that the automaton can execute the next computational step (next state transition). On the other hand, in M 1, the protection strand P i of R i is displaced from its w i y i binding with R i when the next state b i w i y i is copied and it binds to the second best complementary sequences y i adjacent to x i in the same rule. Polymerase next binds to P i ’s 3′ end and extends it to the first stopper sequence S, thus displacing the 3′ end of M 1. Hence the 3′ end of the WPCR strand is now free to take part in the next state transition. Additionally to ensure that the transition rule R i is reusable, the extended protection strand P i is reset to its original configuration using an auxiliary strand A i encoded as \(w_iy_{i}z_{i}a_{i}x(a_{i})^{\ast}b_{i}.\)

At this time, b i of the next state b i w i y i can be concealed in a stem loop to prevent back-hybridization. The next state b i w i y i remains hidden at all times except for when it is copied. Now recall that there was some additional sequences at the 3′ end of the strand namely, \(x^{\ast}a_{i}\) from state transition R i . This along with the previous current state (a i )* forms a tight loop, thus hiding \(a_{i}^{\ast}\) and preventing back-annealing in M 1. Back-hybridization, however, is very a common occurrence in the running of M 2 since after state transition R i , \((a_ib_i)^{\ast}\) encoded at the 3′ end of M 2, hybridizing with transition rule R i , is energetically much more favorable than simply \((b_i)^{\ast}\) binding with a j  = b i , the current state of transition rule R j (this is also the expected transition). However, with M 1, \((a_i)^{\ast}\) at the 3′ end of the strand is hidden in a hairpin loop while b i in rule R i is also concealed in a distinct stem loop. Additionally w i y i that encodes for the rest of the next state of rule R i is bound to the protection strand P i and hence the probability of a back-hybridization event is almost negligible.\(\square\)

Theorem

A reusable rule IR-WPCR machine that prevents back-hybridization using folding WPCR can simulate any finite state automata that is implementable by the original machine.

Proof

Combining the above two lemmas we can show that a reusable rule IR-WPCR machine that prevents back-hybridization using folding WPCR can simulate the same restricted class of finite state machines as the original WPCR machine.\(\square\)

7 Probabilistic analysis of IR-WPCR protocol

For the analysis of the stochastic behavior of a IR-WPCR machine, we describe the steps involved in a rate transition diagram. Based on this continuous time Markov Chain in Fig. 10, we can then compute the state transition probability and rate. We can also compute the probability and rate of “resetting” a state. We first need to explain all the rates shown in the Markov Chain.

Fig. 10
figure 10

Continuous time Markov Chain for rule R i in the reusable rules IR-WPCR protocol that prevents back-hybridization using folding WPCR

7.1 Rate of polymerization

In Fig. 10, r poly corresponds to the rate at which the next state of length l 1 bases is copied and \(r^{\prime}_{poly}\) corresponds to the effective rate at which P i (l 2 bases) is extended. If the polymerase can extend N bases bases/sec, then \(r_{poly}=\frac{N_{bases}}{l_1}\) while \(r^{\prime}_{poly}=\frac{N_{bases}}{l_2}.\) r wait is the mean DNA polymerase and strand encounter rate, given by \(r_{wait}=\frac{N_{poly}}{N_{strands}}v_t\) where N poly is the number of units of polymerase in the solution and N strands corresponds to the total number of strands (each P i (corresponding to R i ) in a W and each A i (corresponding to R i ) in the solution count for a separate strand). Additionally \(v_t=\frac{1} {\frac{1}{r_{poly}}+\frac{1} {r_{poly}}}\) denotes the mean number of distinct extensions/sec by 1 unit of polymerase under optimal conditions using excess target and primer (Rose et al. 2001). Furthermore, r exo (or r exo for P i ) is the effective rate of exonuclease activity. It is generally very small and is given by \(r_{exo}=\frac{k_{exo}} {l_1}\frac{N_{poly}}{V}\) and \(r^{\prime}_{exo}=\frac{k_{exo}} {l_2}\frac{N_{poly}}{V}\) where k exo for ϕ29 (our chosen polymerase) can be calculated from primer extension experiments (Saturno et al. 1995). Here, V is the total volume of the solution. Since target/primer is in excess, the exonuclease activity is limited by the concentration of the polymerase.

7.2 Rate of hybridization

For hybridization events, the rates r 1f , r 2f , r 3f , r 4f and r 5f are not concentration dependent since all the components are part of the same nanostructure. Hence \(r_{if} \propto \sqrt{hl_i}\) where hl i is the length of the hybridization segment (Hames and Higgins, 1995) for i = 1, 2, 3, 4, 5 under optimal conditions, thus neglecting effect of temperature and salt concentration. The rate of dehybridization r ib (r 1b , r 2b , r 3b , r 4b , r 5b ) is given by \(k_{fe}^{-G_{se_i}}\) where \(G_{se_i}=(\frac{4000}{T}-11)hl_i \) (T is the temperature of the solution in K) and k f is the forward rate constant (Winfree 1998a).

7.3 Rate of strand displacement

Finally, for estimating r fdispl and r bdispl we model strand displacement as a 1D random walk. After the toehold hybridization, let G denote the free energy of the 3 strand complex, G l the free energy after one base pair migration to the left and G r the same for migration to the right. Moreover, let \({\Updelta}G_r=G_r-G\) and \({\Updelta}G_l=G_l-G\) where the change in free energy can be computed from the nearest neighbor model. If p r and p l are the probability for right and left directional migration, then \(p_r \propto exp(\frac{-\Updelta G_r} {RT})\) and \(p_l \propto exp(\frac{-\Updelta G_l}{RT}).\) Further, the mean time for a single base migration is about 100 μ sec (Thompson et al. 1976). Hence, \(r_{fdispl}=\frac{10000} {\sum_{i=1}^{l_{fdispl}}\frac{p_{r_i}}{p_{r_i}+p_{l_i}}}\) and \(r_{bdispl}=\frac{10000} {\sum_{i=1}^{l_{bdispl}}\frac{p_{l_i}} {p_{r_i}+p_{l_i}}}\) where l fdispl and l bdispl denote the number of bases displaced in the forward and backward direction respectively. Observe that A i displaces P i to the right at this rate and thus r fdispl corresponds to the forward rate of displacement.

7.4 Likelihood and rate of a state transition

Suppose we assume that the polymerase binding at the 3′ end of the WPCR strand hybridized with a transition rule R marks the beginning of a state transition while the 3′ end of the WPCR strand binding to another transition rule R′ whose current state is identical to the next state of R marks the end of a single state transition. Then based on the Markov Chain in Fig. 10, the probability of a state transition is given by \(\left(\frac{r_{poly}} {r_{poly}+r_{wait}}\right)\cdot\left(\frac{r_{1f}} {r_{1f}+r_{exo}}\right)\cdot\left(\frac{r^{\prime}_{poly}} {r_{wait}+r_{1b}}\right)\cdot\left(\frac{r_{2f}} {r_{2f}+r^{\prime}_{exo}}\right)\cdot\left(\frac{r_{5f}} {r_{5f}+r_{2b}}\right)\) and the rate of state transition, given that 3′ end of W is bound to a i in R i and the polymerase is bound at the end of it, is given by \(r_{poly}\left(\frac{r_{1f}} {r_{1f}+r_{exo}}\right)\cdot\left(\frac{r^{\prime}_{poly}} {r_{wait}+r_{1b}}\right)\cdot\left(\frac{r_{2f}} {r_{2f}+r^{\prime}_{exo}}\right)\cdot\left(\frac{r_{5f}} {r_{5f}+r_{2b}}\right).\) Given that polymerization is a much faster than hybridization, the rate of state transition is really limited by the r wait parameter which in turn, is dependent on the relative concentration of the strands and the enzymes. Hence it is possible to increase rate of state transition by decreasing the concentration of polymerase. As Sahu et al. (2008) observed that incubating the sample containing cargo on a DNA track with polymerase at 30°C for 30 min was more than sufficient for the enzyme to drive the cargo on the circular track several times.

A rule is “reset” only if the protected strand is set back to its old configuration after the next state is copied from the rule. The probability that a state will be reset or made reusable after participating in the computation is given by \(\left(\frac{r_{poly}} {r_{poly}+r_{wait}}\right)\cdot\left(\frac{r_{1f}} {r_{1f}+r_{exo}}\right)\cdot\left(\frac{r^{\prime}_{poly}} {r_{wait}+r_{1b}}\right)\cdot\left(\frac{r_{3f}} {r_{3f}+r^{\prime}_{exo}}\right)\cdot\left(\frac{r_{fdispl}} {r_{fdispl}+r_{3b}}\right)\) while the corresponding rate is \(r_{poly}\left(\frac{r_{1f}} {r_{1f}+r_{exo}}\right)\cdot\left(\frac{r^{\prime}_{poly}} {r_{wait}+r_{1b}}\right)\cdot\left(\frac{r_{3f}} {r_{3f}+r^{\prime}_{exo}}\right)\cdot\left(\frac{r_{fdispl}} {r_{fdispl}+r_{3b}}\right).\) The rate limiting step in reseting a rule is the strand displacement operation and its rate can be biased by manipulating the toehold length (meaning length of w i in each rule R i ).

7.5 Likelihood of preventing back-hybridization

Recall that a back-hybridization is an event where the old current state, say a at the 3′ end of the WPCR strand paired with the next state b copied from the rule R (with a as the current state and b as the next state) binds to R in preference to rule R′ which has b as the new current state since the first hybridization is energetically more favorable than the second hybridization. The probability of preventing back-hybridization in a reusable rule IR-WPCR machine that uses folding WPCR to prevent back-hybridization, is a function of two independent events: (1) the old current state (a) forming a stem loop at the 3′ end of the WPCR strand at the conclusion of a state transition and (2) the next state (b) in the rule that was just executed (R) hiding in another hairpin loop at the same time. Now the probability of the old current state forming a stem loop at the 3′ end of the WPCR strand at the end of a state transition is \(p_{1} = \left(\frac{r_{poly}} {r_{poly}+r_{wait}}\right)\cdot\left(\frac{r_{1f}} {r_{1f}+r_{exo}}\right)\cdot\left(\frac{r^{\prime}_{poly}} {r_{wait}+r_{1b}}\right)\cdot\left(\frac{r_{2f}} {r_{2f}+r^{\prime}_{exo}}\right)\) while the probability of the next state in the rule that was just executed to also hide in another hairpin loop at the end of the state transition is \(p_{2} = \left(\frac{r_{poly}} {r_{poly}+r_{wait}}\right)\cdot\left(\frac{r_{1f}} {r_{1f}+r_{exo}}\right)\cdot\left(\frac{r^{\prime}_{poly}} {r_{wait}+r_{1b}}\right)\cdot\left(\frac{r_{3f}} {r_{3f}+r^{\prime}_{exo}}\right)\cdot\left(\frac{r_{fdispl}} {r_{fdispl}+r_{3b}}\right)\cdot\left(\frac{r_{4f}} {r_{bdispl}+r_{4f}}\right).\) Hence the probability of preventing back-hybridization after a state transition is \(p = p_{1}\cdot p_{2}.\) Consequently, the probability of a back-hybridization event is 1−p. While the likelihood of preventing back-hybridization is dependent on the rate of a polymerase binding with the WPCR machine, the rate limiting step in this phenomenon is really the strand displacement operation that releases the next state in a rewrite rule and allows it to be hidden in a stem–loop. Furthermore, observe that the first four terms of the probability of a state transition appear in the expression for p 1 while the first three terms of the same expression appear in the expression for p 2. Thus the probability of preventing back-hybridization is approximately proportional to the square of the probability of a state transition. In other words, when the likelihood of a state transition increases, the likelihood of a back-hybridization event decreases and vice versa.

8 DNA design of IR-WPCR computing on a 3 state machine

In this section we provide a concrete example of the execution of the IR-WPCR protocol on a 3 state machine to illustrate the concept of a IR-WPCR machine further. We also describe how one can verify computation on this machine using gel electrophoresis and Fluorescence Resonance Energy Transfer (FRET) method. For clarity and simplicity, we will describe the protocol for only reusable rule IR-WPCR but has no capability to prevent back-hybridization. We have also not included the supporting nanostructure for the machine in the following description.

8.1 Encoding of the WPCR strand

Suppose we have a 3 state machine: \(s_1\longrightarrow s_2 \longrightarrow s_3.\) Thus we have to encode only two transition rules viz. \(s_1\longrightarrow s_2\) and \(s_2 \longrightarrow s_3\) in the WPCR strand W \((x_1-y_1-z_1-a_1-b_1-w_1-y_1-S-x_2-y_2-z_2-a_2-b_2-w_2-y_2-S-S^{\prime}-a_1^{\ast}).\) Here S (6 bases) is the stopper sequence and S′ is the spacer sequence that allows W to form a hairpin structure easily. Observe that a 1 is the encoding for state s 1, while b 1 − w 1 − y 1 (or a 2) is the encoding for s 2 and finally b 2 − w 2 − y 2 is the encoding for s 3. Two (s 2 and s 3) out of three states are used for priming and, hence, each state comprises of at least 15 bases.

We use polymerase ϕ29 to drive the computing, because of its excellent strand displacement capability (Sahu et al. 2008). However, it has to be used in very low concentration because of its high fidelity in higher concentrations. Further, if any state is used as a molecular beacon (Tyagi and Kramer 1996) for FRET experiments (e.g., b 2 w 2 y 2) the length has to be at least 24 bases. Besides W, we need to consider P 1’s DNA design. P 1 binds to the x 1 and w 1 y 1 of rule R 1 \((s_1\longrightarrow s_2)\) before extension and, hence, at least three bases are necessary for each section to ensure stable hybridization. It should be remembered that, since R 2 \((s_2\longrightarrow s_3)\) is the last transition rule visited by the hairpin, it is not necessary to include P 2 or A 2 for R 2. The resultant compact hairpin structure of W is more suitable for gel analysis.

We can perform two distinct experiments E 1 and E 2 to verify whether both state transitions are executed. This is essential because, in IR-WPCR protocols, once the polymerase is added to the solution, in theory, the reaction goes to completion. Thus, it is not easy to probe the state of W after every state transition. Hence, E 1 corresponds to the experiment when W encodes \(s_1\longrightarrow s_2\) as well as \(s_2 \longrightarrow s_3\) while, in E 2, W encodes only \(s_1\longrightarrow s_2.\) Since we have only a three state machine these experiments together allow us to study the secondary structure of W in solution. It should be noted that for E 2 we do not need either P 1 or A 1 since s2 is the final state for this experiment. Sequences designed using sequence symmetry minimization (Seeman 1990) for E 1 and E 2 are shown in Fig. 11.

Fig. 11
figure 11

DNA Sequences for experiments E 1 and E 2

8.2 Preparing the WPCR strand for computation

For experiment E 1 in order to ensure that W attains the secondary structure appropriate for IR-WPCR computing, we adopt the simple preparation protocol. We add P 1 to W and anneal the mixture to 30°C so that W can attain the hairpin structure and P 1 can bind to rule R 1. Auxiliary strand A 1 is added in the next step. W is now ready to compute as soon as ϕ29 is added to the solution. For experiment E 2 we only need to anneal W to 30°C and add the polymerase to initiate computation.

8.3 Verification of computation with gel electrophoresis

Once very low concentration (about 0.05 μM) of ϕ29 is added to the solution at 30°C, the resultant mixture is ready to be analyzed in about 30 min. A 10% native PAGE can be used to determine the size of the final product (W). For experiment E 1, the auxiliary strand A 1 forms a separate band. We can compare it with the sizes of the WPCR strand prior to both state transitions. Ideally we should see a heavier band because at the end of computation, we have an extended P 1 hybridized to A 1 while still being hybridized to R 1 in W. For experiment E 2, the distinction may be less prominent since this experiment neither involves A 1 or P 1. Hence, gel analysis may not be quite conclusive. Information obtained from FRET analysis for both experiments may be more useful.

8.4 Verification of computation with FRET analysis

To perform FRET analysis, we use the molecular beacon (Tyagi and Kramer 1996) technique. For E 1 we use an extended b 2 w 2 y 2 region (about 24 bases in length) that is bound to a single strand B 1 encoded as \(h(b_2w_2y_2)^{\ast}h^{\ast}.\) There is a fluorophore and a quencher at the two ends of B 1. h and h* are complementary to each other and each is about 6 bases long. The idea of this molecular beacon is that, when W copies the next state in R 2, it will displace B 1. Consequently, B 1 is released and the h portion of B 1 binds to its h* portion, resulting in a hairpin. As a result, there is a detectable drop in fluorescence signal. Similarly for E 2, the molecular beacon B 2 \((h(b_1w_1y_1)^{\ast}h^{\ast})\) is hybridized to b 1 w 1 y 1 region of R 1 in W. Here too, as soon as the next state in R 1 is copied by ϕ29, B 2 is released, forms a hairpin and the existing fluorescence is quenched.

9 Conclusion

In summary, WPCR is an useful model of computation for running distinct programs in parallel. In other words, the significance of WPCR computation lies in the fact that while other forms of autonomous molecular computing such as tiling assembly (Winfree et al. 1998) or Benenson automata (Benenson et al. 2001) operate based on global rules, it is possible to execute multiple WPCR machines, each holding its own distinct program, in parallel. However, existing protocols are not isothermal and autocatalytic at the same time, thus limiting the number of steps a WPCR machine can execute as well as its flexibility. In this paper, we presented three distinct isothermal and autocatalytic protocols for computing with WPCR. The key idea is to use strand displacement and polymerization of a secondary priming sequence to dehybridize the 3′ of the WPCR strand once the next state is copied eliminating the need for a thermal cycle. Another important aspect of one of our protocols (reusable rule IR-WPCR that can prevent back-hybridization) is that it is capable of minimizing back-annealing events. This is a major problem with the original WPCR machine since it limits the program execution to only a few steps. However, folding WPCR protocol that is part of this reusable rule IR-WPCR protocol, in theory, can eliminate back-annealing completely, thus enabling uninterrupted program execution on a IR-WPCR machine. Furthermore, the rules in this machine are reusable after next states are copied from them, thus making it computationally equivalent to the original WPCR machine. Additionally, the protocol is isothermal and autocatalytic, making it readily usable in a wide variety of applications in diverse environments. One immediate future direction is to verify with laboratory experiments and computer simulation the proposed design of the 3 state machine (Sect. 8) and compare the yields with that of the original WPCR implementation (Sakamoto et al. 1999; Hagiya et al. 1999).