### Design principle

The goal of designing DEG is to maximize detection windows for discriminating SNVs by suppressing the detection signals for spurious targets through the transformation of the quantitative relationship between detection signals and target concentrations. To quantitatively describe the detection window, we introduce a Robustness Factor (RF) that is defined as the ratio of concentrations between a spurious and a correct target generating the same level of detection signal, RF = [T]spurious/[T]correct (Fig. 2b). As such, the greater the RF value, the wider the detection window. Although DEG acts on dsDNA, the detection of single-stranded DNA (ssDNA) can also be considered as a special case of DEG, where the concentrations of DNA Equalizer Probes (DEPs) approach infinite.

The workflow and principle of DEG are illustrated in Fig. 2. A double-stranded input AB produces a single-stranded target A and its complementary sequence B through a rapid heating at 95 °C and then snap cooling to 0 °C in a thermal protocol. B is then consumed by DEPs that are of the identical sequences with A forming three-stranded complex BCD (Fig. 2b). The yield (η) of A is thus determined quantitatively by the concentration of DEPs. When the concentration of AB is less than those of DEPs, A is the predominant product, although a competition exists between A and DEPs for hybridizing to B (Fig. 2c). When the concentration of AB is greater than those of DEPs, unconsumed B will rehybridize with A in the renaturation process (Fig. 2d). Therefore, a maximum yield exists when the concentration of AB equals to those of DEPs. Finally, net A is quantified using a toehold-exchange reporter which is designed to be sensitive to SNVs. As each DEP is designed to only contain the sequence of either the toehold domain or the branch migration domain of the reporter, no fluorescence signal can be produced in the absence of the target (Fig. S15). Through DEG, a conventional sigmoid detection curve of hybridization probes is transformed into an asymmetric unimodal one (Fig. 2d).

Comparing to existing strategies via manipulation of energy barriers of frustrating probs, transformation of the quantitative relationship between detection signals and target concentrations from a sigmodal function to an assymetric unimodal one offers three distinct advantages. First, the transformation only suppresses detection signals at higher concentration end. As such, it allows the dramatic expansion of detection windows without compromising the sensitivity at the lower concentration end (Fig. S6). Second, the manipulation of detection window is user-definable and can be achieved at any target concentration. In principle, correct and spurious targets achieve maximum yields simultaneously in DEG, both of which are governed by the concentration of DEPs. As such, a detection window is definable and tunable by simply altering the concentration of DEPs. Moreover, the detection signal for a correct target remains to be much higher than that of a spurious one throughout concentration ranges (RF = ∞ , Fig. 2e right), whereas the detection window for a conventional probe is much narrower (Fig. 2e. left, Fig. S6). Third, as detection signals for the spurious target are significantly suppressed, discrimination factor (DF) is significantly enhanced through a wide concentration range (Fig. 2e right). At molecular level, B serves as a molecular sink that competitively consumes A regardless the identity or the position of the mutation, which is significantly different from existing strategies harnessing molecular sinks or reservoirs36,37 that are designed specifically for known mutations. To quantitatively simulate and predict the effectiveness of DEG for expanding the detection window and for improving sequence selectivity, a theoretical model was established and detailed in the next section.

### Theoretical model

Here, a mathematical model was introduced to quantitatively profile DEG by taking all possible reactions into consideration (Fig. 3a). To derive the yield of each DNA species in this reaction network as a function of both sequence design (ΔΔG0) and equalizer probe concentrations, a set of eight equilibrium equations need to be solved. However, we found that these equations were coupled to one another, which was mathematically difficult to solve. Therefore, a stoichiometric matrix RM was introduced to help simplify the calculation (Fig. 3a), where the first four rows were ranked to be essential (details in Supplementary Information section S2.4). This essential set of equilibrium equations was then solved by a numerical approach, where distributions of A and AB were solved as a function of the target concentration and plotted in Fig. 3c.

Fig. 3: Theoretical model of DNA Equalizer Gate (DEG).

a Schematic illustration of all possible elemental reactions occurring in the DEG. b Linearization of the complex reaction network in DEG into 0 = RM·Reactant to extract the independent equations, where RM is the stoichiometric matrix and Reactant represents DNA species. The rank of RM was determined to be 4, indicating that four independent equilibrium equations need to be solved. As such, reactions [i – iv] were chosen to build mathematical model. c In silico prediction of the yields of A and AB as a function of the concentration of dsDNA target without performing the probability correction. d Schematic illustration of the need for probability correction when [AB] > [DEPs]. As each DEP binding is an independent event, the multiplicity rule was applied here. When [AB] ≤ [DEPs], the probability that two DEPs bind to the same B is 100%. However, when [AB] > [DEPs], the probability becomes dependent on the ratio between the initial concentrations of AB and DEPs, where Probability = ([DEPs]0/[AB]0)2. e In silico prediction of the yields of A and AB as a function of the concentration of dsDNA target with the probability correction.

The thermodynamic-driven model successfully predicted the distribution of A and AB at the concentration range, where [AB] > [DEPs] (Fig. 3c). However, it failed to simulate the thermodynamic behavior of DEG when [AB] ≤ [DEPs]. We found that a probability function that took the possible distributions of DEPs on B was necessary to correctly reflect the final equilibrium distribution of each DNA species (Fig. 3d and Fig. S5). Mathematically, the probability for the successful formation of a BCD complex is ([DEPs]0/[AB]0)2 (Fig. 3d). The combination of the thermodynamic-driven model with probability correction leads to a characteristic asymmetric unimodal curve (Fig. 3e), which was also confirmed experimentally (details in the next section).

### In silico prediction and experimental validation

Using our theoretical model, η, DF, and RF were firstly quantitatively profiled in silico against three critical factors in DEG, including the target concentration, the sequence design (ΔΔG0), and the detection window defined by DEPs. The detection of ssDNA may also be described in our model by setting the concentration of DEPs to be infinite, where the yield for producing A is 100%. Simulation results in Fig. 4 depict the theoretical transitions from the detection of ssDNA ([DEPs] = ∞) to the detection dsDNA with varying concentrations of DEPs at 50, 100, 200, and 500 nM. Unlike conventional frustrating probes (toehold exchange or molecular beacon) where η is saturated beyond a certain target concentration (Fig. 4a), a maximum η exists in DEG at a single target concentration that is defined exclusively by DEP ([T]max = [DEPs]) and is sequence-independent (Fig. 4b). The simulation results also reveal a significant expansion of the detection window where highly specific discrimination of single nucleotide mutations can be achieved (Fig. 4d). The level of improved DF is also definable by the concentration of DEP (Fig. 4d). As η for high concentrations of SNVs has been suppressed exclusively, a remarkable transition of RF is observed from finite values (Fig. 4e) to infinite (Fig. 4f).

Fig. 4: Simulation results of DNA Equalizer Gate (DEG).

In silico prediction of the reaction yield as a function of both target concentration and ΔΔG0 for classic toehold-exchange (a) and DEG of varying DEP concentrations at 50, 100, 200, and 500 nM (b). The classic toehold-exchange can be considered as a special case of DEG, where [DEPs] = ∞. Maximum yields exist for DEG, where [AB] = [DEPs]. Yields of spurious targets are significantly suppressed across wide concentration ranges, which can help improve the specificity and expand the detection window. In silico prediction of discrimination factors for classic toehold-exchange (c) and DEGs (d). The detection window for discriminating SNVs is tunable by altering the concentrations of DEPs. In silico prediction of robustness factors for classic toehold-exchange (e) and DEGs (f). The use of DEG dramatically increases RF values from a finite value to infinite.

The experimentally measured η, DF, and RF at varying concentrations of a synthetic dsDNA target are plotted in Fig. 5 for comparison with those predicted in silico. Experimental validation and optimization are detailed in Supplementary materials section S3 (Figs. S10S16). A correction of $${\mathrm{{\Delta}}}G_{rxn}^0$$ by +1.58 kcal/mol was found to significantly improve the agreement between experimental observation and in silico prediction (Fig. S7). η and DF at a specific target concentration were calculated directly using fluorescence readout from the reporter. Consistent with in silico prediction, maximum η were observed for both correct and spurious targets, which was defined strictly by the concentration of DEP (Fig. 5a). As theoretically predicted, η for the spurious target is significantly suppressed by DEG. As a result, improved DF was also observed, which also agreed well with simulation (Fig. 5b). RF was measured indirectly by first fitting a calibration curve using a non-linear model and then calculated according to the definition (S2.2, eq. S8, Fig. S8). Again, infinite RF was determined across wide concentration ranges (Fig. 5c). The effectiveness and flexibility of DEG were further verified experimentally against varying types and locations of single nucleotide mutations (Fig. 5d, e), varying length of dsDNA targets (Fig. S17S19), and finally nine sets of clinically important SNVs (Fig. S31S33). DEG works well for all sets of targets except when mutation occurs at the very edge of the dsDNA (Fig. 5e).

Fig. 5: Experimental validation of DNA Equalizer Gate (DEG).

a Experimentally determined yields (Exp) plotted against target concentrations for DEGs with varying DEP concentrations and compared to simulation (Sim). The classic toehold-exchange can be considered as a special case of DEG, where [DEPs] = ∞. Individual replicates (n = 2) are shown as dots. b Experimentally determined discrimination factors using a pair of synthetic correct and spurious targets (ΔΔG0 = 2.29 kcal/mol) plotted against target concentrations and compared to those predicted in silico. c Robustness factor plotted against target concentrations and compared to in silico prediction. d Schematic illustration of sequences of the target and DEPs. Single-nucleotide mutations were made to the target at positions 1, 6, 14, and 17. e Experimentally determined yields plotted against target concentrations for correct and spurious targets carrying mutations at four designated positions. Individual replicates (n = 2) are shown as circles. All experiments were run at 37 °C in 1 × PBS buffer with 1 mM Mg2+ and 20 nM of toehold-exchange beacons. Source data are available in the Source Data file.

### Integration of DEG with PCR

A practically applicable DNA hybridization probe shall compatible with commonly used nucleic acid amplification techniques, such as PCR. As DEG acts directly on dsDNA, it is an ideal probe for analyzing dsDNA amplicons. Therefore, we next verified the adaptivity of DEG to PCR. As a proof-of-principle, a set of four DEPs were designed for a representative 87 bp dsDNA amplicon (Fig. 6a), which was shown to be fully compatible with DEG (Fig. 6b, S37 and S38). To avoid potential cross-reactions, two outer DEPs were designed intentionally to be identical as the PCR primers (Fig. 6c and Fig. S36).

Fig. 6: Integration of DNA Equalizer Gate (DEG) with polymerase chain reaction (PCR).

a Schematic illustration of analyzing dsDNA using a 4-DEP design. b Experimental validation of the 4-DEP design for the detection of an 87 bp dsDNA as a mimic of PCR amplicon. The concentration of outer DEPs was fixed at 500 nM and that of inner DEPs was set to be 200 nM. Individual replicates (n = 2) are shown as circles. c Schematic illustration of DEG-PCR using a 4-DEP design. The outer two DEPs (red and black) are designed to be identical with PCR primers. d Real-time monitoring of DEG-PCR using a toehold-exchange reporter. A wide detection window was achieved, where as low as 10 aM of correct template could be clearly discriminated from 1 pM spurious target containing a single nucleotide mutation. e Schematic illustration of the asymmetric PCR followed by the detection using a toehold-exchange reporter. f Real-time monitoring the detection of asymmetric PCR amplicon revealing a much narrower detection window than DEG-PCR, where correct discrimination could be made only above 1 fM. Source data are available in the Source Data file.

Results in Fig. 6d demonstrate that the DEG-PCR is both highly sensitive and specific. As low as 1 aM synthetic DNA templates were detectable. More importantly, fluorescence signal for 1 pM spurious template containing a single nucleotide mutation is significantly suppressed using DEG, which is much lower than that of 10 aM of the correct template (Fig. 6d). By contrast, a much narrower detection window (above 1 fM) was observed when asymmetric PCR was used to generate detectable ssDNA amplicon followed by the readout using the same toehold-exchange reporter (Figs. 6e, f and S39).

### Clinical validation of DEG-PCR

We finally employed DEG-PCR for the diagnosis of soil-transmitted helminth (STH) infections with clinical samples collected from school-age children living in highly endemic rural areas in Honduras. STH infections are global health issue, affecting more than 1.5 billion world’s population38. The extensive drug usage (e.g., Albendazole) for treating STH infections in endemic countries or regions has created issues of drug resistance39,40. As such, an ideal diagnostic test for STH infection shall allow simultaneous detection of STH infection and screen for drug resistance (D.R.).

Thus motivated, we employed DEG-PCR for the detection of STH infections, meanwhile screening for drug resistance in the same assay (Fig. 7a). Two fluorescence reporters were designed to test codon 196 to 203 and codon 206 to 213 of the β-tubulin gene of Trichuris trichiura (Fig. 7b). A single-nucleotide A to T mutation at the 200th codon of β-tubulin is a well-established genetic variant for drug-resistance screening (Fig. S40)40. The toehold-exchange reporter testing this domain (codon 196 to 203) was thus designed to be highly sensitive to this SNV by including a 5-nt reverse toehold, whereas no reverse toehold was designed for the reporter targeting codon 206 to 213. The two reporters were labeled with spectrally distinct fluorescent dye (FAM and Cy5) and thus operated simultaneously in solution (Figs. S41 and S42). Synthetic DNA standards of varying concentrations and 13 clinical TT samples with negative resistance were first tested using the dual-channel DEG-PCR (Figs. S4346) and plotted in Fig. 7c, where three regions (error eclipse with 99% confidence) were definable representing positive infection and positive resistance (D.R.+), positive infection but negative resistance (D.R.‒), and no detectable infection (N.C.). Six clinical parasitic specimens expelled by patients who received Albendazole treatment in Honduras were tested and found to be TT positive but no drug resistance (Fig. 7d). Two clinical Ascaris worm specimens serving as negative control were also tested and found to be TT negative. All results were consistent with diagnostic tests using microscopy (Kato-Katz), post-PCR gel analysis (Fig. S47) and DNA sequencing (Fig. S48).

Fig. 7: Application of DEG-PCR to analyzing clinical parasitic worm samples.

a A typical workflow for analyzing parasitic worm (Trichuris trichiura, TT) specimens collected from stool samples of school-age children in the rural areas of Honduras followed by the detection using DEG-PCR. b Simultaneous detection of parasitic infection and screening for drug-resistance was achieved using a dual-channel design (FAM- and Cy5-Reporter). PCR primers were designed to amplify nucleotide 1246-1333 in the β-tubulin gene, containing the 200th codon. A single nucleotide A to T mutation of this codon is a hotspot for drug resistance screening. A toehold-exchange reporter (FAM-reporter, green duplex) labeled with FAM was used to discriminate this point mutation, whereas a strand-displacement reporter with no reverse toehold (Cy5-reporter, red duplex) was employed to detect a conservative region near codon 200. Experimental tests of the dual-channel DEG-PCR using synthetic DNA standards (blue and red dots) and 13 (D.R.‒) clinical samples (green circles) as a training set (c) and 8 unknown clinical parasitic worm samples (d). Test results are classified into three areas defining the positive infection and drug resistance (D.R.+), positive infection and no drug resistance (D.R.‒), and negative infection (N.C.). Error eclipses with 99% confidence interval and 2-degrees of freedom (two fluorescence channels) were used to define D.R.+ and D.R.‒. Eight clinical worm specimens including six Trichuris trichiura worms (TT-1 to TT-6) and two A. lumbricoides worms (AL, as negative controls) were tested and plotted in (d). Source data are available in the Source Data file.

Source