betaFeedback

WorksComputer Science

Probabilistic GC-Constraints for Composite DNA

Abstract

This paper addresses the challenge of encoding biochemical GC-content constraints in composite DNA-based data storage. Previous deterministic models impose high rate penalties by avoiding any possibility for a strand to fall outside the allowed range. To account for the stochastic nature of composite DNA, we introduce an εε-probabilistic constraint framework, and derive capacity bounds for global constraints using composition types and for local sliding-window constraints via finite-state Markov chains. Furthermore, we propose a capacity-achieving multi-type enumerative encoder.

Introduction

In today’s information-driven world, efficiently storing large amounts of data for long periods is a significant challenge. DNA-based data storage has recently emerged as a promising solution for this [1, 2]. It takes advantage of the natural ability of DNA molecules to encode vast amounts of information in an extremely compact form.

The classical approach to storing information in DNA, without error correction, maps a binary alphabet {0,1}\{0,1\} to the four nucleotides {A,C,G,T}\{A,C,G,T\}, thereby encoding information directly into DNA sequences. However, commonly used DNA synthesis does not produce only a single copy of the sequence. Instead, the synthesis process inherently generates multiple copies of the same strand [3]. Many DNA-based data storage schemes treat this multiplicity primarily as redundancy for error correction, which reduces the effective information density per synthesized position [1, 4].

Composite DNA has been proposed as an alternative encoding strategy to exploit the many-copy nature of DNA synthesis [4]. In composite DNA, each position in a DNA strand represents a probabilistic composition of nucleotides instead of encoding a single, fixed base. Specifically, a composite symbol at position ii can be represented as a tuple (pA,pC,pG,pT)(p_A,p_C,p_G,p_T), where each pxp_x denotes the relative proportion of nucleotide x∈{A,C,G,T}x \in\{A,C,G,T\} and pA+pC+pG+pT=1p_A+p_C+p_G+p_T=1. Figure 1 illustrates a side-by-side comparison of classical and composite DNA encoding schemes, highlighting the structural differences between the two approaches.

Classical and composite DNA encoding schemes

Figure 1. Classical (left) and composite (right) DNA encoding schemes.

While composite DNA offers gains in theoretical information density, it also introduces fundamental challenges to ensure that synthesized sequences satisfy essential biochemical constraints. To secure reliable chemical processing,

DNA sequences must avoid extreme variations in GC content. Excessively GC-rich or AT-rich sequences suffer from skewed melting temperatures, leading to amplification bias, non-uniform read coverage, and sequence dropout [5, 6, 7].

As in traditional optical recording and communication systems, where physical channel properties restrict allowable sequences, constrained coding provides a general information-theoretic framework for accommodating these biochemical limits [8]. Rather than generating arbitrary sequences and blindly discarding unsuitable ones, this approach ensures that digital data is mapped directly and exclusively to valid, biologically compliant strands.

In classical DNA storage, constraint evaluation is deterministic. The transition to composite symbols introduces a different problem: the physical nucleotide sequence obtained during synthesis is probabilistic. Despite this, constrained coding for composite DNA remains relatively underexplored. Recently, Nguyen et al. [9] investigated both run-length-limited (RLL) and global GC-content constraints in composite DNA, calculating constrained capacities for small composite alphabets using adjacency matrices. Their capacity evaluations and subsequent code constructions relied on a strict, worst-case deterministic framework utilizing sequence replacement and Knuth’s algorithm. A theoretical analysis of RLL coding was presented in [10, 11].

A critical limitation of existing deterministic approaches is that enforcing zero-tolerance compliance against worst-case realizations introduces high rate penalties. In this paper, we shift to a probabilistic constraint. This shift is justified by the physical and informational realities unique to the stochastic nature of composite DNA.

By allowing a controlled probability of constraint violation (denoted by ϵ\epsilon), we are able to expand the admissible code space. In this work, we develop a comprehensive framework for the analysis and encoding of composite DNA sequences subject to ϵ\epsilon-probabilistic GC constraints. We determine the capacity and propose an efficient multi-type arithmetic indexing scheme that achieves it. The remainder of this paper details the constraint formulations (§ 2), capacity formulations and analysis (Section III), and the proposed encoding scheme (Section IV). Proofs and examples are deferred to the appendix; short sketches are given for the main theorems.

Model and Preliminaries

Composite DNA Representation and Probability Bins

The base alphabet for composite DNA consists of the four base nucleotides X={A,C,G,T}\mathcal{X} = \{\mathrm{A}, \mathrm{C}, \mathrm{G}, \mathrm{T}\} [4].

Definition 1 (Composite DNA Symbol). A composite DNA symbol SS over the alphabet X\mathcal{X} is defined by the integer counts

S=(nA,nC,nG,nT),∑x∈Xnx=k.S = (n_{\mathrm{A}}, n_{\mathrm{C}}, n_{\mathrm{G}}, n_{\mathrm{T}}), \qquad\sum_{x \in\mathcal{X}} n_x = k.

where kk is called the resolution parameter and nxn_x represents the count of nucleotide xx used to form the composite symbol. Equivalently, SS represents an empirical distribution pS(x)=nx/kp_S(x) = n_x/k over X\mathcal{X}. We denote the set of all composite symbols with resolution kk as the composite alphabet Ak\mathcal{A}_k.

The size of the composite alphabet is ∣Ak∣=(k+33)|\mathcal{A}_k| = \binom{k+3}{3}. For the synthesis, a composite sequence S=[S1,…,Sn]\mathbf{S} = [S_1, \ldots, S_n] is fed to the synthesizer. For each of the multiple synthesized strands, at position ii, a nucleotide is chosen at random according to the distribution given by SiS_i. We emphasize that the synthesis process does not provide control over which specific strand receives which nucleotide. Only the overall composition of nucleotides at each position is specified by the composite symbol. As a result, each nucleotide at position ii in a strand can be viewed as an independent realization drawn from the distribution associated with SiS_i.

Assume we sequence MM strands from the pool of a synthesized composite DNA sequence of length nn. We represent the mm-th strand as

Dm=[Dm,1,Dm,2,…,Dm,n]∈Xn,m∈{1,…,M}.\mathbf{D}_m = [D_{m,1}, D_{m,2}, \ldots, D_{m,n}] \in\mathcal{X}^n,\quad m \in\{1,\ldots,M\}.

where Dm,iD_{m,i} denotes the nucleotide of strand mm at position ii. In this view, the array of MM strands is the M×nM \times n matrix D\mathbf{D} whose mm-th row is Dm\mathbf{D}_m. Note that each Dm,iD_{m,i} is a realization of a random variable over the distribution given by SiS_i. To evaluate sequences efficiently, we group symbols by their intrinsic GC probability mass as follows.

Definition 2 (Probability-Mass Binning). For a resolution parameter kk, the GC probability mass is defined as q(S)=pS(G)+pS(C)q(S) = p_S(\mathrm{G}) + p_S(\mathrm{C}). As it takes discrete values in {0,1k,…,1}\{0,\frac{1}{k},\ldots,1\}, we partition Ak\mathcal{A}_k into k+1k+1 disjoint probability bins Q={B0,…,Bk}\mathcal{Q} = \{B_0,\ldots,B_k\}, where all symbols in bin BiB_i share the same GC probability mass, meaning Bi={S∈Ak:q(S)=ik}B_i = \{S \in\mathcal{A}_k : q(S) = \frac{i}{k}\}.

The cardinality of each bin is determined by the number of ways to independently partition ii elements into the {G,C}\{\mathrm{G},\mathrm{C}\} bases and k−ik-i elements into the {A,T}\{\mathrm{A},\mathrm{T}\} bases, yielding

∣Bi∣=(i+1)(k−i+1).(1)|B_i| = (i+1)(k-i+1). \tag*{(1)}

GC-Constraint and the Probabilistic Shift

Let Imin⁡(S)\mathbb{I}_{\min}(S) and Imax⁡(S)\mathbb{I}_{\max}(S) be indicator functions representing the guaranteed minimum and potential maximum physical GC contributions of a composite symbol SS:

Imin⁡(S)={1,if q(S)=1,0,otherwise,Imax⁡(S)={1,if q(S)>0,0,otherwise.(2)\mathbb{I}_{\min}(S) = \begin{cases} 1, & \text{if } q(S)=1,\\ 0, & \text{otherwise} \end{cases} ,\qquad \mathbb{I}_{\max}(S) = \begin{cases} 1, & \text{if } q(S)>0,\\ 0, & \text{otherwise}. \end{cases} \tag*{(2)}

Using these indicator functions, we define the deterministic GC constraint as follows:

Definition 3 (Deterministic GC Constraint). Let S=[S1,…,Sn]∈Akn\mathbf{S} = [S_1,\ldots,S_n] \in\mathcal{A}_k^n. We say S\mathbf{S} complies with the deterministic GC constraint with limits α≤β∈[0,1]\alpha\le\beta\in[0,1] if

nα≤∑i=1nImin⁡(Si)and∑i=1nImax⁡(Si)≤nβ.(3)n\alpha\le\sum_{i=1}^{n} \mathbb{I}_{\min}(S_i)\quad\text{and}\quad\sum_{i=1}^{n} \mathbb{I}_{\max}(S_i) \le n\beta. \tag*{(3)}

We further say that S\mathbf{S} complies with the ww-windowed deterministic GC constraint with limits α≤β∈[0,1]\alpha\le\beta\in[0,1] if any subsequence S′=[Si,…,Si+w−1]\mathbf{S}' = [S_i,\ldots,S_{i+w-1}] for i∈{1,…,n−w+1}i \in\{1,\ldots,n-w+1\} complies with the deterministic GC constraint.

While strict deterministic constraints are necessary for classical DNA storage, applying this worst-case, zero-tolerance approach to composite DNA causes rate loss. This strictness ignores two practical realities of composite synthesis. (i) Random Chemistry & Redundancy: DNA synthesis is a random process that creates millions of copies of each sequence. A worst-case physical strand is a rare anomaly, not a guaranteed outcome. (ii) Isolated Failures: If a rare, highly biased strand does form and drop out, it is an isolated erasure. It does not corrupt the rest of the molecular pool and can potentially be recovered using suitable error correction codes. The following example illustrates why shifting to a probabilistic threshold is much more practical.

Example 4 (Pessimism of Deterministic Bounds). Let k=4k=4, and let the standard acceptable GC limits for a sequence of length n=10n=10 be α=0.4\alpha=0.4 and β=0.6\beta=0.6. This requires the physical strand to contain between 4 and 6 GC nucleotides. Consider a composite sequence S\mathbf{S} consisting of 4 pure G/C symbols (q(S)=1q(S)=1), 3 pure A/T symbols (q(S)=0q(S)=0), and 3 mixed symbols biased toward A/T (e.g., 3 adenines and 1 cytosine, yielding q=0.25q=0.25).

Under the deterministic framework, we evaluate the worst-case bounds. The 4 pure G/C symbols guarantee the lower bound (∑Imin⁡=4≥4\sum\mathbb{I}_{\min}=4 \ge4). However, the deterministic upper bound assumes all 3 mixed symbols will, in the worst case, manifest as cytosine. This yields a maximum potential weight of ∑Imax⁡=4+3=7\sum\mathbb{I}_{\max}=4+3=7. Since 7>67>6, the sequence S\mathbf{S} is rejected as invalid.

Analyzing the strand probabilistically reveals a different reality. As the pure symbols are fixed, the sequence only violates the upper bound if all three mixed symbols simultaneously manifest as cytosine. The probability of this single worst-case realization is (0.25)3=1/64≈0.016(0.25)^3 = 1/64 \approx0.016. This means that 98.4% of the millions of physical strands synthesized from this sequence will have exactly 4, 5, or 6 GC nucleotides, perfectly complying with the strict 40%–60% thermodynamic

requirements. Discarding this sequence represents a massive loss of coding capacity.

Allowing the sequence, on the other hand, would only slightly bias the composite pool. Therefore, the GC constraint is better evaluated probabilistically, setting the threshold on the probability ϵ\epsilon of violation rather than the worst-case realization.

For a given composite sequence S=[S1,…,Sn]∈Akn\mathbf{S} = [S_1,\ldots,S_n] \in\mathcal{A}_k^n, the physical manifestation of a G or C nucleotide at any position j∈{1,…,n}j \in\{1,\ldots,n\} is an independent Bernoulli trial.

Let Xj∼Bernoulli⁡(q(Sj))X_j \sim\operatorname{Bernoulli}(q(S_j)) represent the binary physical GC contribution of the jj-th symbol. The total physical GC count of the sequence is the sum of these independently distributed random variables, denoted as Y=∑j=1nXjY = \sum_{j=1}^n X_j. Consequently, YY follows a Poisson binomial distribution, allowing us to enforce a precise error tolerance ϵ∈[0,1)\epsilon\in[0,1).

Definition 5 (ϵ\epsilon-Probabilistic GC Constraint). Let S=[S1,…,Sn]∈Akn\mathbf{S} = [S_1,\ldots,S_n] \in\mathcal{A}_k^n be a composite sequence of length nn. Furthermore, let YY be the random variable depicting the total physical GC count of a DNA strand synthesized from S\mathbf{S}. We say S\mathbf{S} complies with the ϵ\epsilon-probabilistic GC constraint with limits α≤β∈[0,1]\alpha\le\beta\in[0,1] and error tolerance ϵ∈[0,1)\epsilon\in[0,1) if

Pr⁡(Y<nα)+Pr⁡(Y>nβ)≤ϵ.(4)\Pr(Y < n\alpha) + \Pr(Y > n\beta) \le\epsilon. \tag*{(4)}

We further say that S\mathbf{S} complies with the ww-windowed ϵ\epsilon-probabilistic GC constraint if any subsequence S′=[Si,…,Si+w−1]\mathbf{S}' = [S_i,\ldots,S_{i+w-1}] for i∈{1,…,n−w+1}i \in\{1,\ldots,n-w+1\} complies with the ϵ\epsilon-probabilistic GC constraint.

Remark 6 (Reduction to Deterministic Case). For a strict error tolerance of ϵ=0\epsilon= 0, the probabilistic approach exactly reduces to the deterministic worst-case baseline.

Capacity Formulations

Global Composition Types and Error Compliance

Evaluating the exact probability mass function (PMF) for every possible sequence individually is computationally intractable. We group sequences into composition types that all share the same Poisson binomial PMF.

Definition 7 (Sequence Type [12]). Given a sequence S∈Akn\mathbf{S} \in\mathcal{A}_k^n, we define the type of S\mathbf{S} as t(S)=(t0(S),…,tk(S))\mathbf{t}(\mathbf{S}) = (t_0(\mathbf{S}),\ldots,t_k(\mathbf{S})), where ti(S)t_i(\mathbf{S}) denotes the number of positions of S\mathbf{S} assigned to probability bin Bi\mathcal{B}_i as defined in Definition 2. Furthermore, given a vector t=(t0,…,tk)\mathbf{t} = (t_0,\ldots,t_k) such that ti≥0t_i \ge0 for all i∈{0,…,k}i \in\{0,\ldots,k\} and ∑i=0kti=n\sum_{i=0}^k t_i = n, we denote by

Tt={S∈Akn:t(S)=t}\mathcal{T}_{\mathbf{t}} = \{\mathbf{S} \in\mathcal{A}_k^n : \mathbf{t}(\mathbf{S}) = \mathbf{t}\}

the type-class of type t\mathbf{t}.

To compute the Poisson binomial distribution for a given type, we use the fact that the sum of independent discrete random variables has a PMF given by the discrete convolution of their individual PMFs [13]. For two independent discrete random variables AA and BB with PMFs ff and gg, the PMF of their sum is (f∗g)(z)=∑xf(x)g(z−x)(f * g)(z) = \sum_x f(x)g(z-x).

Proposition 8 (Exact PMF via Convolution). For a sequence of type t=(t0,…,tk)\mathbf{t} = (t_0,\ldots,t_k), let Yi∼Bin⁡(ti,i/k)Y_i \sim\operatorname{Bin}(t_i,i/k) denote the binomially distributed GC count contributed by the symbols in bin Bi\mathcal{B}_i, and let fif_i denote the PMF of YiY_i. Then the PMF of the total GC count Y=∑i=0kYiY = \sum_{i=0}^k Y_i is fY=f0∗f1∗⋯∗fkf_Y = f_0 * f_1 * \cdots* f_k.

Proposition 9 (Type-Dependent Compliance). For any two composite sequences S1,S2∈Tt\mathbf{S}_1,\mathbf{S}_2 \in\mathcal{T}_{\mathbf{t}}, S1\mathbf{S}_1 complies with the global ϵ\epsilon-probabilistic GC constraint if and only if S2\mathbf{S}_2 complies.

Because the violation probability is identical for all sequences within a given type-class, we can define the set of all probabilistically valid types. Let YtY_{\mathbf{t}} denote the Poisson binomial random variable associated with type t\mathbf{t}.

Definition 10 (Allowed Type Set). The set of all sequence types that satisfy the global ϵ\epsilon-probabilistic GC constraint is denoted as:

Pϵ={t:Pr⁡(Yt<nα)+Pr⁡(Yt>nβ)≤ϵ}.(5)\mathcal{P}_{\epsilon} = \{\mathbf{t} : \Pr(Y_{\mathbf{t}} < n\alpha) + \Pr(Y_{\mathbf{t}} > n\beta) \le\epsilon\}. \tag*{(5)}

Because probabilistic compliance depends only on a symbol’s GC probability q(S)q(S) rather than the specific nucleotide mixture of the symbol itself, the ϵ\epsilon-probabilistic GC constraint can be equivalently defined and evaluated over sequences of probability bins (e.g., Bi1,Bi2,…\mathcal{B}_{i_1},\mathcal{B}_{i_2},\ldots where Bij∈{B0,…,Bk}\mathcal{B}_{i_j} \in\{\mathcal{B}_0,\ldots,\mathcal{B}_k\}).

Proposition 11 (Type-Class Cardinality). For a given sequence type t=(t0,…,tk)\mathbf{t} = (t_0,\ldots,t_k), the total number of composite sequences in the type-class Tt\mathcal{T}_{\mathbf{t}} is given by:

∣Tt∣=n!∏i=0kti!∏i=0k∣Bi∣ti.(6)|\mathcal{T}_{\mathbf{t}}| = \frac{n!}{\prod_{i=0}^k t_i!}\prod_{i=0}^k |\mathcal{B}_i|^{t_i}. \tag*{(6)}

Definition 12. Let p\mathbf{p} be a condition on vectors over Akn\mathcal{A}_k^n and let Vp⊆Akn\mathcal{V}_{\mathbf{p}} \subseteq\mathcal{A}_k^n be the set of all vectors fulfilling that condition. Then we define the capacity for codes constrained by p\mathbf{p} as

Cp=lim⁡n→∞log⁡2∣Vp∣n.(7)C_{\mathbf{p}} = \lim_{n\to\infty}\frac{\log_2 |\mathcal{V}_{\mathbf{p}}|}{n}. \tag*{(7)}

Global GC Capacity

Theorem 13 (Global Probabilistic GC Capacity). Given a resolution parameter kk and an error tolerance ϵ\epsilon, let pt=(t0/n,…,tk/n)\mathbf{p}_{\mathbf{t}} = (t_0/n,\ldots,t_k/n) denote the empirical bin distribution of type t\mathbf{t} with entropy H(pt)=−∑i=0ktinlog⁡2tinH(\mathbf{p}_{\mathbf{t}}) = -\sum_{i=0}^k \frac{t_i}{n}\log_2\frac{t_i}{n}, where 0log⁡20=00\log_2 0 = 0, and let

F(t)=H(pt)+∑i=0ktinlog⁡2∣Bi∣.F(\mathbf{t}) = H(\mathbf{p}_{\mathbf{t}}) + \sum_{i=0}^k \frac{t_i}{n}\log_2 |\mathcal{B}_i|.

Then the global ϵ\epsilon-probabilistic GC constrained capacity is

Cglobal-GC(ϵ)=lim⁡n→∞1nlog⁡2(∑t∈Pϵn!∏i=0kti!∏i=0k∣Bi∣ti)=lim⁡n→∞max⁡t∈PϵF(t),(8)\begin{aligned} C_{\mathrm{global\text{-}GC}}(\epsilon) = \lim_{n\to\infty}\frac{1}{n}\log_2\left(\sum_{\mathbf{t}\in\mathcal{P}_{\epsilon}}\frac{n!}{\prod_{i=0}^k t_i!}\prod_{i=0}^k|\mathcal{B}_i|^{t_i}\right) \\ &= \lim_{n\to\infty}\max_{\mathbf{t}\in\mathcal{P}_{\epsilon}} F(\mathbf{t}), \tag*{(8)} \end{aligned}

where Pϵ\mathcal{P}_{\epsilon} is the allowed type set for length nn, provided that Pϵ≠∅\mathcal{P}_{\epsilon} \ne\varnothing and the limit exists.

Proof sketch. The set Vglobal-GC\mathcal{V}_{\mathrm{global\text{-}GC}} of valid sequences is the disjoint union of the type-classes Tt\mathcal{T}_{\mathbf{t}}, t∈Pϵ\mathbf{t} \in\mathcal{P}_{\epsilon}. Each has size 2nF(t)2^{nF(\mathbf{t})} up to a polynomial factor, and there are polynomially many types [12]. ∎

Note that F(t)F(\mathbf{t}) is the entropy of the distribution over Ak\mathcal{A}_k that assigns mass ti/nt_i/n to bin BiB_i and is uniform within each bin. Hence F(t)≤log⁡2∣Ak∣F(\mathbf{t}) \le\log_2|\mathcal{A}_k|, with equality if and only if ti/n=∣Bi∣/∣Ak∣t_i/n = |B_i|/|\mathcal{A}_k| for all ii.

Remark 14 (Asymptotic Independence of ϵ\epsilon). Let μ(p)=∑i=0kpiik\mu(\mathbf{p}) = \sum_{i=0}^{k} p_i \frac{i}{k} denote the expected GC fraction of a sequence with bin distribution p\mathbf{p}. Using Chebyshev’s inequality (see Appendix A), for α<β\alpha< \beta and any fixed ϵ∈(0,1)\epsilon\in(0,1), the capacity does not depend on ϵ\epsilon:

Cglobal−GC(ϵ)=max⁡p: α≤μ(p)≤β(H(p)+∑i=0kpilog⁡2∣Bi∣).C_{\mathrm{global-GC}}(\epsilon) = \max_{\mathbf{p}:\,\alpha\le\mu(\mathbf{p}) \le\beta} \left( H(\mathbf{p}) + \sum_{i=0}^{k} p_i \log_2 |B_i| \right).

In particular, since ∣Bi∣=∣Bk−i∣|B_i| = |B_{k-i}|, the unconstrained maximizer pi=∣Bi∣/∣Ak∣p_i = |B_i|/|\mathcal{A}_k| satisfies μ(p)=12\mu(\mathbf{p}) = \frac{1}{2}, and thus Cglobal−GC(ϵ)=log⁡2∣Ak∣C_{\mathrm{global-GC}}(\epsilon) = \log_2|\mathcal{A}_k| whenever α≤12≤β\alpha\le\frac{1}{2} \le\beta. This does not hold for the deterministic case ϵ=0\epsilon= 0, see Corollary 18 in Appendix B.

Sliding-Window GC Capacity

When the GC-content constraint is enforced locally over a sliding window of length w<nw < n, sequence validity depends on overlapping windows. Under the ϵ\epsilon-probabilistic constraint, the probability distribution of the GC count depends on the probability bins of the symbols within each window. We therefore model the constrained sequence as a finite-state Markov chain, where each state stores the recent history needed to determine whether the next window is admissible. An example is given in Appendix § 4.

Theorem 15 (Probabilistic Sliding-Window GC Capacity). Let G(V,E)G(V,E) be a directed graph whose vertices VV are the set of all (w−1)(w-1)-tuples of probability-mass bins BiB_i, i∈{0,…,k}i \in\{0,\ldots,k\}. An edge from a vertex s=(b1,…,bw−1)s=(b_1,\ldots,b_{w-1}) to a vertex s′=(b1′,…,bw−1′)s'=(b'_1,\ldots,b'_{w-1}) exists if the following two conditions hold: (i) (b2,…,bw−1)=(b1′,…,bw−2′)(b_2,\ldots,b_{w-1})=(b'_1,\ldots,b'_{w-2}), and (ii) the ww-tuple (b1,…,bw−1,bw−1′)(b_1,\ldots,b_{w-1},b'_{w-1}) satisfies the ϵ\epsilon-probabilistic GC constraint. Each valid edge corresponding to the appended bin BjB_j is assigned weight ∣Bj∣|B_j|. Let TϵT_\epsilon denote the resulting weighted transition matrix and let vϵ(w)(s)v_\epsilon^{(w)}(s) count the valid length-ww composite sequences whose last w−1w-1 bins equal ss, i.e., vϵ(w)=uTϵ\mathbf{v}_\epsilon^{(w)}=\mathbf{u}T_\epsilon with u(s)=∏j=1w−1∣Bbj∣u(s)=\prod_{j=1}^{w-1}|B_{b_j}|. Then, for n≥wn \ge w, the number of elements in the set Vw-GC\mathcal{V}_{w\text{-GC}} of composite sequences fulfilling the ww-windowed ϵ\epsilon-probabilistic GC constraint is

∣Vw-GC∣=vϵ(w)Tϵn−w1T(9)|\mathcal{V}_{w\text{-GC}}| = \mathbf{v}_\epsilon^{(w)}T_\epsilon^{n-w}\mathbf{1}^{\mathsf{T}} \tag*{(9)}

and, if the largest absolute eigenvalue of TϵT_\epsilon is positive, i.e., λ(Tϵ)>0\lambda(T_\epsilon)>0, the corresponding capacity is

Cw-GC(ϵ)=lim⁡n→∞1nlog⁡2∣Vw-GC∣=log⁡2λ(Tϵ).(10)C_{w\text{-GC}}(\epsilon) = \lim_{n\to\infty}\frac{1}{n}\log_2|\mathcal{V}_{w\text{-GC}}| = \log_2\lambda(T_\epsilon). \tag*{(10)}

Proof sketch. Valid sequences correspond to weighted walks in GG, and the growth rate of Tϵn−wT_\epsilon^{n-w} is λ(Tϵ)\lambda(T_\epsilon) by Gelfand’s formula.

Remark 16 (Role of ϵ\epsilon for Sliding Windows). For k=4k=4, α=0.4\alpha=0.4, and β=0.6\beta=0.6, evaluating λ(Tϵ)\lambda(T_\epsilon) gives normalized capacities Cw-GC(ϵ)/log⁡2∣A4∣≈0.629,0.629,0.770C_{w\text{-GC}}(\epsilon)/\log_2|\mathcal{A}_4| \approx0.629, 0.629, 0.770 for w=5w=5 and ϵ=0,0.05,0.2\epsilon=0,0.05,0.2, and Cw-GC(ϵ)/log⁡2∣A4∣≈0.674,0.678,0.839C_{w\text{-GC}}(\epsilon)/\log_2|\mathcal{A}_4| \approx0.674,0.678,0.839 for w=10w=10. In contrast to the global constraint (Remark 14), ϵ\epsilon determines the capacity, since the window length ww does not grow with nn. For small ϵ\epsilon, it coincides with the deterministic capacity, see Appendix B.

Analysis of Results

Figure 2 evaluates the global and sliding-window finite-length rates as a function of strand length for a resolution parameter of k=4k=4. The global rate increases with strand length and converges toward the unconstrained capacity if ϵ>0\epsilon>0. Conversely, the sliding-window rate strictly decreases as strand length grows since each newly appended symbol must simultaneously satisfy the GC bounds across multiple shifting, overlapping windows.

Global and sliding-window finite-length rates

Figure 2. Global and sliding-window finite-length rates as a function of strand length nn, for k=4k=4, α=0.40\alpha=0.40, and β=0.60\beta=0.60. The rates are shown for error tolerances ϵ∈{0,0.05,0.20}\epsilon\in\{0,0.05,0.20\} and sliding-window lengths w∈{5,10}w \in\{5,10\}. (SW: Sliding Window, Unc.: Unconstrained Limit)

Multi-Type Arithmetic Indexing for the Probabilistic GC-Constraint

To achieve the theoretical capacity limits derived in Section III-B for the global ϵ\epsilon-probabilistic GC constraint, we leverage the global composition types to implement a capacity-achieving multi-type arithmetic encoder.

Our approach adapts the arithmetic coding architecture used in constant-composition [14] and multi-composition [15] distribution matching. Our objective, however, is not to shape a distribution, but to use all sequences whose composition types belong to the probabilistically valid set Pϵ\mathcal{P}_\epsilon. We therefore utilize the multi-composition arithmetic coding framework as a capacity-achieving enumerative indexer.

To formalize this for the probabilistic GC constraint, we rely on standard interval-partitioning machinery [14, 15]. A binary input data sequence b\mathbf{b} of length m=⌊log⁡2∣Vglobal−GC∣⌋m=\lfloor\log_2|\mathcal{V}_{\mathrm{global-GC}}|\rfloor is converted into a target fraction 0≤d<10 \le d < 1 via its natural binary code (NBC) representation, d=NBC⁡(b)/2md = \operatorname{NBC}(\mathbf{b})/2^m. The arithmetic encoder recursively partitions this interval such that every valid composite sequence S∈Vglobal−GC\mathbf{S} \in\mathcal{V}_{\mathrm{global-GC}} corresponds to a disjoint subinterval I(S)I(\mathbf{S}) of strictly equal length 1/∣Vglobal−GC∣1/|\mathcal{V}_{\mathrm{global-GC}}|. This equal-length partitioning guarantees that the maximum number of messages can be uniquely mapped and recovered [14, 15].

Applying this continuous interval-partitioning to our discrete constrained channel requires two problem-specific ingredients: (i) a defined lexicographic ordering over our composite alphabet Ak\mathcal{A}_k to consistently assign interval boundaries, and (ii) a method to dynamically compute the conditional branching probability P(a∣S~)P(a|\widetilde{\mathbf{S}}) that a valid sequence continues with symbol a∈Aka \in\mathcal{A}_k, given an existing prefix S~\widetilde{\mathbf{S}}.

To maintain equal-length final intervals, the branching probability must exactly reflect the fraction of valid codewords that extend the current prefix. Specifically, let N(S~)N(\widetilde{\mathbf{S}}) represent the number of complete valid codewords that share the prefix S~\widetilde{\mathbf{S}}. The conditional probability of appending symbol aa is given by the ratio P(a∣S~)=N(S~a)/N(S~)P(a|\widetilde{\mathbf{S}}) = N(\widetilde{\mathbf{S}}a)/N(\widetilde{\mathbf{S}}) [15]. To compute this ratio dynamically without storing the massive multi-type codebook, we introduce the unified prefix-completion count.

Proposition 17 (Unified Prefix-Completion Count). Let S~\widetilde{\mathbf{S}} be a prefix of length ℓ\ell. For any allowed type t=(t0,…,tk)∈Pϵ\mathbf{t} = (t_0, \ldots, t_k) \in\mathcal{P}_{\epsilon}, let ci(S~)c_i(\widetilde{\mathbf{S}}) denote the number of symbols currently in S~\widetilde{\mathbf{S}} that belong to probability bin BiB_i. The remaining number of symbols required from bin BiB_i to complete type t\mathbf{t} is ti(S~)=ti−ci(S~)t_i(\widetilde{\mathbf{S}}) = t_i - c_i(\widetilde{\mathbf{S}}). The total number of valid length-nn sequences extending the prefix S~\widetilde{\mathbf{S}} is:

N(S~)=∑t∈PϵNt(S~),(11)N(\widetilde{\mathbf{S}}) = \sum_{\mathbf{t}\in\mathcal{P}_{\epsilon}} N_{\mathbf{t}}(\widetilde{\mathbf{S}}), \tag*{(11)}

where the per-type continuation count Nt(S~)N_{\mathbf{t}}(\widetilde{\mathbf{S}}) is given by the multinomial extension:

Nt(S~)={(n−ℓ)!∏i=0kti(S~)!∏i=0k∣Bi∣ti(S~),if ti(S~)≥0 for all i,0,otherwise.(12)N_{\mathbf{t}}(\widetilde{\mathbf{S}}) = \begin{cases} \dfrac{(n-\ell)!}{\prod_{i=0}^{k} t_i(\widetilde{\mathbf{S}})!} \prod_{i=0}^{k} |B_i|^{t_i(\widetilde{\mathbf{S}})}, & \text{if } t_i(\widetilde{\mathbf{S}}) \ge0 \text{ for all } i,\\ 0, & \text{otherwise.} \end{cases} \tag*{(12)}

Using the prefix-completion counts derived from Proposition 17, the encoder recursively narrows the initial interval [0,1)[0,1) around the target fraction dd. This symbol-by-symbol mapping process is formalized in Algorithm A. A worked example is given in Appendix § 4.

To decode the codeword, the receiver applies arithmetic compression on the received sequence c\mathbf{c} using the same branching model P(a∣S~)∝N(S~a)P(a|\widetilde{\mathbf{S}}) \propto N(\widetilde{\mathbf{S}}a). The decoder recursively partitions the interval II symbol by symbol to reconstruct the final valid sub-interval I(S)I(\mathbf{S}). Retrieving the original binary sequence b\mathbf{b} is performed by extracting the unique data point dd contained within I(S)I(\mathbf{S}), and reversing the binary mapping via NBC⁡−1\operatorname{NBC}^{-1} [15].

To measure the practical efficiency of this encoding scheme, we calculate its normalized achieved information rate, defined as the fraction of the unconstrained composite-symbol capacity achieved by the practical encoder:

ηenc=⌊log⁡2∣Vglobal−GC∣⌋nlog⁡2∣Ak∣.(13)\eta_{\mathrm{enc}} = \frac{\left\lfloor\log_2 |\mathcal{V}_{\mathrm{global-GC}}| \right\rfloor}{n\log_2 |\mathcal{A}_k|}. \tag*{(13)}
Algorithm A: Multi-Type Arithmetic-Indexing Encoder

Input: Binary message b, strand length n, allowed types Pε.
Output: Admissible composite codeword c.

1: d ← NBC(b)/2^m                         {Target fraction}
2: I ← [0, 1)                            {Current interval}
3: s ← ∅                                 {Initialize prefix}
4: for i = 1 to n do
5:     For each valid candidate a, compute multi-type paths:
6:     N(sa) = ∑_{t∈Pε} N_t(sa)
7:     Partition I into sub-intervals I_a proportional to N(sa).
8:     Select symbol a* whose sub-interval I_a* contains d.
9:     I ← I_a*                            {Update interval}
10:    s ← sa*                             {Append to prefix}
11: end for
12: return c ← s

As illustrated in Figure 3, the multi-type arithmetic indexing (MTAI) approach consistently converges to the theoretical GC-constrained channel capacity already at short strand lengths across all evaluated error tolerances ϵ\epsilon.

Capacity and coding efficiency comparison as a function of strand length

Figure 3. Capacity and coding efficiency comparison as a function of strand length nn, for k=4k = 4, α=0.40\alpha= 0.40, and β=0.60\beta= 0.60. Rates are shown for error tolerances ϵ∈{0,0.05,0.20}\epsilon\in\{0, 0.05, 0.20\}.

Conclusion

This paper introduced a probabilistic framework for GC-content constraints in composite DNA storage. By grouping composite symbols into probability bins, we formulated exact capacity bounds for global constraints using composition types, and for local sliding-window constraints via finite-state transfer matrices. Furthermore, we proposed a capacity-achieving multi-type enumerative encoder that efficiently utilizes this expanded code space by directly indexing the probabilistically valid codebook. Future work will explore adapting this arithmetic indexing scheme directly for sliding-window constraints.

Acknowledgements

The authors used the AI system Gemini (Google) to assist in improving the code for the simulations and generate the figures in this manuscript. All AI-generated content was checked for accuracy and revised by the authors, who take full responsibility for the content of this paper.

Proofs

Proof of Proposition 8. A type-tt sequence contains tit_i symbols from Bi\mathcal{B}_i. Their GC contributions are independent Bernoulli trials with success probability ik\frac{i}{k}, so Yi∼Bin⁡(ti,ik)Y_i \sim\operatorname{Bin}(t_i,\frac{i}{k}). Since the variables Y0,…,YkY_0,\ldots,Y_k are mutually independent and Y=∑i=0kYiY=\sum_{i=0}^{k}Y_i, the PMF of YY is the convolution of their individual PMFs [13].

Proof of Proposition 9. As established in Proposition 8, the exact Poisson binomial PMF of a sequence’s total physical GC count YY is determined entirely by the convolution of the binomial distributions associated with each probability bin. These binomial distributions depend exclusively on the bin counts (t0,…,tk)(t_0,\ldots,t_k) specified by the type tt. Since S1S_1 and S2S_2 belong to the same type-class Tt\mathcal{T}_t, their total GC counts are identically distributed. Consequently, their tail violation probabilities Pr⁡(Y<nα)+Pr⁡(Y>nβ)\Pr(Y<n\alpha)+\Pr(Y>n\beta) are exactly equal.

Proof of Proposition 11. Constructing a sequence of type tt is a two-step process. First, we must assign each of the nn sequence positions to one of the k+1k+1 probability bins such that exactly tit_i positions are assigned to bin Bi\mathcal{B}_i. The number of distinct ways to partition these positions is given by the multinomial coefficient n!∏i=0kti!\frac{n!}{\prod_{i=0}^{k}t_i!}.

Second, for each of the tit_i positions assigned to bin Bi\mathcal{B}_i, we must select a specific composite symbol from that bin. Since there are ∣Bi∣|\mathcal{B}_i| distinct symbols in bin Bi\mathcal{B}_i, there are ∣Bi∣ti|\mathcal{B}_i|^{t_i} possible symbol combinations for those positions and the proposition follows.

Proof of Theorem 13. Let Vglobal-GC\mathcal{V}_{\mathrm{global\text{-}GC}} denote the set of valid sequences satisfying the global probabilistic GC constraint. A sequence satisfies the constraint if and only if its type belongs to Pϵ\mathcal{P}_{\epsilon}. Consequently, Vglobal-GC\mathcal{V}_{\mathrm{global\text{-}GC}} forms the disjoint union of valid type-classes, Vglobal-GC=⋃t∈PϵTt\mathcal{V}_{\mathrm{global\text{-}GC}}=\bigcup_{t\in\mathcal{P}_{\epsilon}}\mathcal{T}_t. We obtain the total number of valid sequences ∣Vglobal-GC∣|\mathcal{V}_{\mathrm{global\text{-}GC}}| by summing their cardinalities via Proposition 11.

From [12 Theorem 11.1.3], applied to the sequence of probability bins over an alphabet of size k+1k+1, we know that

1(n+1)k+12nH(pt)≤n!∏i=0kti!≤2nH(pt).\frac{1}{(n+1)^{k+1}}2^{nH(\mathbf{p}_t)}\leq\frac{n!}{\prod_{i=0}^{k}t_i!}\leq2^{nH(\mathbf{p}_t)}.

Since ∏i=0k∣Bi∣ti=2n∑i=0ktinlog⁡2∣Bi∣\prod_{i=0}^{k}|\mathcal{B}_i|^{t_i}=2^{n\sum_{i=0}^{k}\frac{t_i}{n}\log_2|\mathcal{B}_i|}, Proposition 11 gives

1(n+1)k+12nF(t)≤∣Tt∣≤2nF(t).\frac{1}{(n+1)^{k+1}}2^{nF(t)}\leq|\mathcal{T}_t|\leq2^{nF(t)}.

Let Fn∗=max⁡t∈PϵF(t)F_n^*=\max_{t\in\mathcal{P}_{\epsilon}}F(t). As the number of types is at most (n+1)k+1(n+1)^{k+1} [12 Theorem 11.1.1], we have

1(n+1)k+12nFn∗≤∣Vglobal-GC∣≤(n+1)k+12nFn∗.\frac{1}{(n+1)^{k+1}}2^{nF_n^*}\leq|\mathcal{V}_{\mathrm{global\text{-}GC}}|\leq(n+1)^{k+1}2^{nF_n^*}.

Taking 1nlog⁡2(⋅)\frac{1}{n}\log_2(\cdot), both bounds differ from Fn∗F_n^* by at most (k+1)log⁡2(n+1)n→0\frac{(k+1)\log_2(n+1)}{n}\to0 as n→∞n\to\infty, which proves the claim.

Proof of Remark 14. The Poisson binomial variable YtY_t has mean nμ(pt)n\mu(\mathbf{p}_t) and variance at most n/4n/4. By Chebyshev’s inequality, every type with

α+12nϵ≤μ(pt)≤β−12nϵ\alpha+\frac{1}{2\sqrt{n\epsilon}}\leq\mu(\mathbf{p}_t)\leq\beta-\frac{1}{2\sqrt{n\epsilon}}

belongs to Pϵ\mathcal{P}_{\epsilon}, while for any fixed δ>0\delta>0 and sufficiently large nn, no type with μ(pt)<α−δ\mu(\mathbf{p}_t)<\alpha-\delta or μ(pt)>β+δ\mu(\mathbf{p}_t)>\beta+\delta does. Since FF is continuous, the claim follows from Theorem 13.

Proof of Theorem 15. By construction, νϵ(w)\nu_{\epsilon}^{(w)} counts valid length-ww sequences, while TϵT_{\epsilon} extends them through valid weighted transitions, with each transition weight accounting for the number of composite symbols in the appended bin. Hence

∣Vw-GC∣=νϵ(w)Tϵn−w1T.|\mathcal{V}_{w\text{-}\mathrm{GC}}|=\nu_{\epsilon}^{(w)}T_{\epsilon}^{n-w}\mathbf{1}^{\mathsf{T}}.

Since sequences shorter than ww are unconstrained, every length-(w−1)(w-1) prefix is valid, which gives νϵ(w)=uTϵ\nu_{\epsilon}^{(w)}=uT_{\epsilon}. Let m=n−w+1m=n-w+1 and let σm=1Tϵm1T\sigma_m=\mathbf{1}T_{\epsilon}^{m}\mathbf{1}^{\mathsf{T}} be the sum of all entries of TϵmT_{\epsilon}^{m}. As 1≤u(s)≤∣Ak∣w−11\leq u(s)\leq|\mathcal{A}_k|^{w-1} for all ss, we have σm≤∣Vw-GC∣≤∣Ak∣w−1σm\sigma_m\leq|\mathcal{V}_{w\text{-}\mathrm{GC}}|\leq|\mathcal{A}_k|^{w-1}\sigma_m. Since TϵT_{\epsilon} is nonnegative, ∥Tϵm∥∞≤σm≤(k+1)w−1∥Tϵm∥∞\|T_{\epsilon}^{m}\|_{\infty}\leq\sigma_m\leq(k+1)^{w-1}\|T_{\epsilon}^{m}\|_{\infty}, where ∥⋅∥∞\|\cdot\|_{\infty} is the maximum row sum and (k+1)w−1(k+1)^{w-1} is the number of states. By Gelfand’s formula, ∥Tϵm∥∞1/m→λ(Tϵ)\|T_{\epsilon}^{m}\|_{\infty}^{1/m}\to\lambda(T_{\epsilon}), and since ∣Ak∣w−1|\mathcal{A}_k|^{w-1} and (k+1)w−1(k+1)^{w-1} do not depend on nn, we obtain 1nlog⁡2∣Vw-GC∣→log⁡2λ(Tϵ)\frac{1}{n}\log_2|\mathcal{V}_{w\text{-}\mathrm{GC}}|\to\log_2\lambda(T_{\epsilon}).

Proof of Proposition 17. Because the type-classes of the allowed types in Pϵ\mathcal{P}_{\epsilon} are mutually disjoint, the total number of valid extensions N(S~)\mathcal{N}(\widetilde{S}) is exactly the sum of the extensions belonging to each valid type, N(S~)=∑t∈PϵNt(S~)\mathcal{N}(\widetilde{S})=\sum_{t\in\mathcal{P}_{\epsilon}}\mathcal{N}_t(\widetilde{S}).

To evaluate the extensions for a specific type tt, observe that the prefix S~\widetilde{S} of length ℓ\ell has already consumed ci(S~)c_i(\widetilde{S}) symbols from each bin Bi\mathcal{B}_i. Therefore, completing a sequence of exactly type tt requires filling the remaining n−ℓn-\ell positions such that exactly ti(S~)=ti−ci(S~)t_i(\widetilde{S})=t_i-c_i(\widetilde{S}) positions are assigned to bin Bi\mathcal{B}_i for every i∈{0,…,k}i\in\{0,\ldots,k\}.

If ti(S~)≤0t_i(\widetilde{S})\leq0 for any bin, the prefix has already exceeded the allowed count for that type, yielding 00 valid extensions. Otherwise, applying the combinatorial logic established in Proposition 11 to the remaining n−ℓn-\ell positions yields the product of the multinomial partition coefficient (n−ℓ)!∏i=0kti(S~)!\frac{(n-\ell)!}{\prod_{i=0}^{k}t_i(\widetilde{S})!} and the independent symbol combinations ∏i=0k∣Bi∣ti(S~)\prod_{i=0}^{k}|\mathcal{B}_i|^{t_i(\widetilde{S})}.

Deterministic Baseline Capacities

Corollary 18 (Deterministic Global GC Capacity). Let k≥2k\geq2, α≤β\alpha\leq\beta, and let mk=∣Ak∣−2(k+1)m_k=|\mathcal{A}_k|-2(k+1) denote the number of mixed symbols, i.e., symbols in B1,…,Bk−1\mathcal{B}_1,\ldots,\mathcal{B}_{k-1}. With pm=1−p0−pkp_m=1-p_0-p_k, define

G(p0,pk)=H(p0,pk,pm)+(p0+pk)log⁡2(k+1)+pmlog⁡2mk.(14)G(p_0,p_k)=H(p_0,p_k,p_m)+(p_0+p_k)\log_2(k+1)+p_m\log_2m_k. \tag*{(14)}

For ϵ=0\epsilon=0, the capacity is

Cglobal-GC(0)=max⁡p0≥1−β, pk≥α,p0+pk≤1G(p0,pk).(15)C_{\mathrm{global\text{-}GC}}(0)=\max_{\substack{p_0\geq1-\beta,\ p_k\geq\alpha,\\p_0+p_k\leq1}}G(p_0,p_k). \tag*{(15)}

If αk+1≥β−αmk\frac{\alpha}{k+1} \ge\frac{\beta-\alpha}{m_k} and 1−βk+1≥β−αmk\frac{1-\beta}{k+1} \ge\frac{\beta-\alpha}{m_k}, the maximum is attained at the boundary, i.e., Cglobal-GC(0)=G(1−β,α)C_{\mathrm{global\text{-}GC}}(0) = G(1-\beta,\alpha).

Proof. Since every symbol in Bk\mathcal{B}_k always and every symbol in B1,…,Bk−1\mathcal{B}_1,\ldots,\mathcal{B}_{k-1} possibly manifests as G or C, the smallest and largest values of YtY_t with nonzero probability are tkt_k and n−t0n-t_0. Hence, P0={t:tk≥nα, t0≥n(1−β)}\mathcal{P}_0 = \{t:t_k \ge n\alpha,\ t_0 \ge n(1-\beta)\}, in accordance with Definition 3. The constraint does not distinguish between the bins B1,…,Bk−1\mathcal{B}_1,\ldots,\mathcal{B}_{k-1}, so for a fixed total mass 1−p0−pk1-p_0-p_k on these bins, FF is maximized by the uniform distribution over all mkm_k mixed symbols. Together with ∣B0∣=∣Bk∣=k+1|\mathcal{B}_0|=|\mathcal{B}_k|=k+1 and the continuity of FF, Theorem 13 yields (14). The objective is the entropy of a distribution over Ak\mathcal{A}_k that is uniform within the pure A/T, pure G/C, and mixed symbols, and is therefore concave. At p0=1−βp_0=1-\beta, pk=αp_k=\alpha, the stated conditions require the per-symbol probability of both constrained groups to be at least that of the mixed symbols, which is exactly the Karush–Kuhn–Tucker condition for both constraints to be active.

For example, for k=4k=4, α=0.4\alpha=0.4 and β=0.6\beta=0.6, the conditions hold and Cglobal-GC(0)≈4.31C_{\mathrm{global\text{-}GC}}(0)\approx4.31 bits, i.e., 84% of log⁡2∣A4∣\log_2|\mathcal{A}_4|, whereas Cglobal-GC(ϵ)=log⁡2∣A4∣C_{\mathrm{global\text{-}GC}}(\epsilon)=\log_2|\mathcal{A}_4| for every ϵ>0\epsilon>0 by Remark 14.

Corollary 19 (Deterministic Worst-Case Baseline). Under the deterministic baseline (ϵ=0\epsilon=0), intermediate probabilities are irrelevant: a window is admissible if and only if it contains at least wαw\alpha pure G/C symbols and at most wβw\beta *symbols that are not pure A/T. It is therefore sufficient to partition the composite alphabet into three bins: pure A/T BAT=B0\mathcal{B}_{AT}=\mathcal{B}_0, pure G/C BGC=Bk\mathcal{B}_{GC}=\mathcal{B}_k, and mixed Bmix=⋃i=1k−1Bi\mathcal{B}_{\mathrm{mix}}=\bigcup_{i=1}^{k-1}\mathcal{B}_i with ∣Bmix∣=mk|\mathcal{B}_{\mathrm{mix}}|=m_k as in Corollary 18. The state space reduces to 3w−13^{w-1} states, and Cw-GC(0)=log⁡2λ(T0)C_{w\text{-}GC}(0)=\log_2\lambda(T_0), where T0T_0 is the weighted transition matrix over this 3-bin partition.

Note that Tϵ=T0T_\epsilon=T_0 whenever ϵ\epsilon is smaller than the smallest nonzero violation probability of any length-ww window, in which case the probabilistic and deterministic sliding-window capacities coincide. For the parameters of Remark 16 and w=5w=5, this minimum is 1/161/16, attained, e.g., by a window with one symbol from B0\mathcal{B}_0, two from B1\mathcal{B}_1, and two from B4\mathcal{B}_4. Hence, ϵ=0.05\epsilon=0.05 yields the same capacity as ϵ=0\epsilon=0.

Examples

Intuitively, as the window shifts by one position, the oldest symbol leaves the window and a new symbol enters. The state therefore records the overlapping portion between consecutive windows, while each transition corresponds to appending a new probability bin. A transition is allowed whenever the resulting window satisfies the local ϵ\epsilon-probabilistic GC constraint.

Example 20. Figure 4 illustrates the state transitions for a window of length w=3w=3 using an alphabet partitioned into three bins. Because w=3w=3, each state is defined by a length-2 sequence of bins (representing the w−1w-1 overlap). If the system is currently in state (b1,b1)(b_1,b_1), appending a new bin creates a temporary length-3 window. The transition is

State transition logic for a sliding-window constraint

Figure 4. State transition logic for a sliding-window constraint with w=3w=3 and three probability bins (b1,b2,b3)(b_1,b_2,b_3). From the current state (b1,b1)(b_1,b_1), appending a new bin creates a length-3 window. Only the addition of b2b_2 satisfies the GC constraint, permitting a valid transition to the next overlapping state (b1,b2)(b_1,b_2).

permitted if and only if this resulting window satisfies the ϵ\epsilon-probabilistic GC bounds. Assume that appending b1b_1 or b3b_3 violates the constraint, while appending b2b_2 forms a valid window. Consequently, the oldest bin is discarded, and the system successfully transitions to the new state (b1,b2)(b_1,b_2).

Intuitively, this process can be viewed as a dynamic dictionary lookup. Imagine all probabilistically valid composite sequences sorted lexicographically and laid out uniformly across a continuous line from 0 to 1. A binary message simply acts as a specific coordinate on this line. Instead of generating and storing this massive dictionary beforehand, the encoder constructs the target sequence symbol by symbol, recursively narrowing its search window based on the proportion of valid sequences that remain. Figure 5 visualizes the interval partitioning logic described in Section IV.

Figure 5. Conceptual tree and interval partitioning of the Multi-Type Arithmetic Encoder. Extending the prefix by one additional step (s=q1qj)(s=q_1q_j) recursively subdivides the corresponding sub-interval Ia1I_{a_1} proportional to the multi-type continuation counts N(a1aj)N(a_1a_j).

Example 21 (Multi-Type Encoding Trace). To illustrate the

step-by-step mechanics of Algorithm A, consider a simplified scenario where not all possible compositions are present and the ϵ\epsilon-probabilistic constraint allows exactly two valid composition types for a strand of length n=3n = 3: Pϵ={t1,t2}\mathcal{P}_{\epsilon} = \{t_1, t_2\}, where t1=(1,1,1)t_1 = (1, 1, 1) and t2=(2,1,0)t_2 = (2, 1, 0).

As shown in Figure 6, the composite alphabet is partitioned into three probability bins (B0,B1,B2B_0, B_1, B_2) containing 2, 2, and 3 symbols, respectively. Note that this is a toy example: the bin sizes are chosen for illustration and do not correspond to a full composite alphabet AkA_k, for which ∣Bi∣=(i+1)(k−i+1)|B_i| = (i+1)(k-i+1) would hold.

A numerical trace of the multi-type arithmetic encoder

Figure 6. A numerical trace of the multi-type arithmetic encoder for a target fraction d=0.1875d = 0.1875.

By Proposition 11, we evaluate the cardinality of each allowed type-class:

  • ∣Tt1∣=3!1!1!1!(211)(211)(311)=72|\mathcal{T}_{t_1}| = \frac{3!}{1!1!1!}\binom{2^1}{1}\binom{2^1}{1}\binom{3^1}{1} = 72 sequences.

  • ∣Tt2∣=3!2!1!0!(222)(211)(300)=24|\mathcal{T}_{t_2}| = \frac{3!}{2!1!0!}\binom{2^2}{2}\binom{2^1}{1}\binom{3^0}{0} = 24 sequences.

The total valid codebook size is N(∅)=72+24=96N(\varnothing) = 72 + 24 = 96 valid sequences. Thus, the encoder can map m=⌊log⁡2(96)⌋=6m = \lfloor\log_2(96) \rfloor= 6 bits.

Suppose we wish to encode the binary message b=001100\mathbf{b} = 001100. The target fraction is computed as d=NBC⁡(001100)/26=12/64=18/96=0.1875d = \operatorname{NBC}(001100)/2^6 = 12/64 = 18/96 = 0.1875.

The encoder initializes the interval [0,1)[0,1) and evaluates the candidate symbols for the first position. For candidate a1∈B0a_1 \in B_0, we must compute the unified prefix-completion count N(a1)N(a_1) by summing the continuations from both types via Proposition 17:

  • For t1t_1, the remaining requirement is (0,1,1)(0,1,1). The continuations are Nt1(a1)=2!0!1!1!(200)(211)(311)=12N_{t_1}(a_1) = \frac{2!}{0!1!1!}\binom{2^0}{0}\binom{2^1}{1}\binom{3^1}{1} = 12.

  • For t2t_2, the remaining requirement is (1,1,0)(1,1,0). The continuations are Nt2(a1)=2!1!1!0!(211)(211)(300)=8N_{t_2}(a_1) = \frac{2!}{1!1!0!}\binom{2^1}{1}\binom{2^1}{1}\binom{3^0}{0} = 8.

Thus, the total valid continuations are N(a1)=12+8=20N(a_1) = 12 + 8 = 20.

The corresponding interval width for a1a_1 is proportional to this sum: P(a1∣∅)=20/96P(a_1 \mid\varnothing) = 20/96. Because our target fraction d=18/96d = 18/96 falls within the sub-interval [0,20/96)[0,20/96), the encoder successfully selects a1a_1. This process recurses, dynamically pruning types when their requirements drop below zero, until the final length-3 codeword is isolated.

References

  1. [1]G. M. Church, Y. Gao, and S. Kosuri, “Next-generation digital information storage in dna,” Science, vol. 337, no. 6102, pp. 1628–1628, 2012. [Online]. Available: https://www.science.org/doi/abs/10.1126/science.1226355pubmed.ncbi.nlm.nih.gov/22903519
  2. [2]N. Goldman, P. Bertone, S. Chen, C. Dessimoz, E. M. LeProust, B. Sipos, and E. Birney, “Towards practical, high-capacity, low-maintenance information storage in synthesized dna,” Nature, vol. 494, no. 7435, pp. 77–80, 2013. [Online]. Available: https://doi.org/10.1038/nature11875
  3. [3]O. Sabary, A. Yucovich, G. Shapira, and E. Yaakobi, “Reconstruction algorithms for dna-storage systems,” Scientific Reports, vol. 14, no. 1, p. 1951, 2024.DOI
  4. [4]L. Anavy, I. Vaknin, O. Atar, R. Amit, and Z. Yakhini, “Data storage in dna with fewer synthesis cycles using composite dna letters,” Nature Biotechnology, vol. 37, no. 10, pp. 1229–1236, 2019. [Online]. Available: https://doi.org/10.1038/s41587-019-0240-x
  5. [5]Y. Erlich and D. Zielinski, “Dna fountain enables a robust and efficient storage architecture,” Science, vol. 355, no. 6328, pp. 950–954, 2017.DOI
  6. [6]R. Heckel, G. Mikutis, and R. N. Grass, “A characterization of the dna data storage channel,” Scientific Reports, vol. 9, no. 1, p. 9663, 2019.DOI
  7. [7]S. H. T. Yazdi, H. M. Kiah, E. Garcia-Ruiz, J. Ma, H. Zhao, and O. Milenkovic, “Dna-based storage: Trends and methods,” IEEE Transactions on Molecular, Biological, and Multi-Scale Communications, vol. 1, no. 3, pp. 230–248, 2016.arxiv.org/abs/1507.01611
  8. [8]K. A. S. Immink, P. H. Siegel, and J. K. Wolf, Codes for digital recorders (invited paper). IEEE Press, 2000, p. 216–255.
  9. [9]T. T. Nguyen, C. Wang, K. Cai, Y. Zhang, and Z. Yakhini, “Constrained coding for composite dna: Channel capacity and efficient constructions,” in 2025 IEEE International Symposium on Information Theory (ISIT), 2025, pp. 1–6.arxiv.org/abs/2501.10645
  10. [10]F. Walter and Y. Yehezkeally, “Coding for strand breaks in composite dna,” in 2025 IEEE International Symposium on Information Theory (ISIT), 2025, pp. 1–6.DOI
  11. [11]D. H. Dang and S. Kim, “A theoretical framework for run-length-limited coding in composite dna,” IEEE Transactions on Molecular, Biological, and Multi-Scale Communications, 2026.DOI
  12. [12]T. M. Cover, Elements of information theory. John Wiley & Sons, 1999.
  13. [13]C. M. Grinstead and J. Laurie Snell, “Sums of Discrete Random Variables,” sep 13 2025, [Online; accessed 2026-09-15].
  14. [14]P. Schulte and G. Böcherer, “Constant composition distribution matching,” IEEE Transactions on Information Theory, vol. 62, no. 1, pp. 430–434, 2016.
  15. [15]M. Pikus and W. Xu, “Arithmetic coding based multi-composition codes for bit-level distribution matching,” in 2019 IEEE Wireless Communications and Networking Conference (WCNC), 2019, pp. 1–6.arxiv.org/abs/1904.01819

Paper details

vlnc:W_xkv4nafe
Version
v1 · latest
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 0

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

  • Computer Science

Gemini (multiple versions)

View statement
Looking for related papers…
Contents