• No results found

BRM Code with One Overlap

In document Coding for Information Storage (Page 159-166)

Bounded Rank Modulation

9.4 BRM Code with One Overlap

We now consider the general BRM code with one overlap,C(n, m, D, 1), which does not have the additional constraint of codeCI(n, m, D, 1).

In this case, the cell levels of a block,{c01,· · · , c0m}, can be any setQ such that Q ⊆ [1, D]and

|Q| =m. The labeled graph H generated is not deterministic in general. However, we are able to find a deterministic graphG that is equivalent to H (Lemma 2.1 in [MRS01]). Here is an example.

Example 9.6 The labeled graph H of C(n, 2, 4, 1) is shown in Figure 9.3 (a). This is not de-terministic since state 1 has 3 outgoing edges labeled 12. Let G be the deterministic represen-tation of C, then the states V(G) are subsets of V(H). And for u, v ∈ V(G), u →l v if ∀ j ∈ v, ∃ i ∈ u and i →l j. So the resulting graph G is as shown in Figure 9.3 (b). States {2}, {3}, {1, 3}, etc., have only outgoing edges, so their capacities are 0. Therefore the ir-reducible component of G maximizing λ(Ai) is as in Figure 9.3 (c). By (9.1)we can then get cap(C(n, 2, 4, 1)) =log λ(Ai) =0.8791>cap(CI(n, 2, 4, 1)) =0.6942.

Figure 9.3: Labeled graphs forC(n, 2, 4, 1). (a) Labeled graph; (b) deterministic graph; (c) irre-ducible graph.

In general, suppose the deterministic graphG representsC(n, 2, D, 1), andAiis the adjacency matrix for the irreducible component ofG that has the largest eigenvalue. Then λ(Ai)is the largest positive root of−xD +2xD1−1 = 0. Comparing cap(CI) andcap(C), we have Figure 9.4.

It can be seen thatcap(C) tends to1 faster than cap(CI), since it makes better use of the levels provided.

2 4 6 8 10 12 14 16 18 20

Figure 9.4: Capacity forC. The solid and dashed lines show capacity forCI andC, respectively.

Permutation

Figure 9.5: (a) Encoder and (b) decoder for BRM codes

The construction in the above example can be naturally extended to the casem>2.

Encoders and decoders for BRM codes can be constructed as in Figure 9.5. In the encoding process, the input information sequence(x0, x1, . . .)is first encoded into a permutation sequence, (P0, P1, . . .), satisfying the maximum cell-level constraint, which is further mapped to a cell-level sequence,(c1, c2, . . .). At last, the cell-level sequence is programmed into flash memory. And the decoder reverses this process by reading the cell levels, forming a permutation sequence, and at last retrieving the information.

• Permutation encoder/decoder

Let C be a constrained system with a representationG, and p,q be positive integers. The q-th power of C, Cq, is represented by the labeled graph Gq, with the same set of states as G and edges/labelings corresponding to paths/labelings of lengthq in G. A finite-state encoder with rate p : q is a lossless labeled graph H such that H ⊆ Gq and each state ofH has out-degree 2p. We

can then assign2pinput tags (orp binary information bits) to the outgoing edges of each state. An encoder is (m,a)-sliding-block decodable if thei-th input tag in an input tag sequence is uniquely de-termined by theq-block labeling sequence Piqm, Piqm+1, . . . , Piq, . . . , Piq+a. The following theorem states that the capacity of any constrained system is always achievable [MRS01].

Theorem 9.7 LetC(n, m, D, v)be a constrained system and p/q < (m−v)cap(C(n, m, D, v)) for positive integers p and q. Then there exists a sliding-block decodable finite-state encoder with ratep : q and permutation encoding rate p/(q(m−v)).

Theorem 9.7 can be proved by explicit constructions of encoders, such as the state-splitting algorithm [MRS01]. And a sliding-block decoder is essentially a mapping from (m+a+1) q-block labelings to ap-block binary input tag. Notice in the decoding process, decoding delay and error propagation is controlled withinm+a+1 q-blocks, which depends on the construction of the encoder/decoder.

After deleting States3 and 4, and some edges from the graph, we get a finite-state encoder in Figure 9.4 (a), which has out-degree 2p = 8 for each state, and each labeling block has size q = 4.

The notation u x3/P4 v means the 4-block labeling P4 is assigned the binary input tag x3. For convenience, we denote the permutation(1, 2)by1, and(2, 1)by0 in the labeling. After merging the States1 and 6, it is further simplified as in Figure 9.4 (b).

Let State1 be the initial state for the encoding. Divide the input binary information bits into blocks of3, and for any x3i = (x3i, x3i+1, x3i+2), encode it as the corresponding4-block labeling, Pi4= (P4i, P4i+1, P4i+2, P4i+3).

Notice that in the encoding process, each 4-block labeling corresponds to only one input tag, independent of starting state. Therefore, we can construct a(0, 0)-sliding-block decoder: for each

2 1 5

Figure 9.6: Rate3 : 4 finite-state encoder forC(n, 2, 4, 1). (a) Labeled subgraph with out-degree8, and (b) simplified encoder.

received permutation blockPi4 decode it to the unique information blockxi3 = (x3i, x3i+1, x3i+2), which equals to(P4i+1, P4i+2, P4i+3)ifP4i 6=P4i+1and equals to(P4i+3, P4i+3, P4i+3), otherwise.

• Cell-level encoder/decoder

Before programming into flash memories, we must first encode the permutation sequence(P0, P2, . . .)into a cell-level sequence (c1, c2, . . .), such that it induces this permutation sequence and does not exceed the maximum level. The following construction provides such an encoding. Let Pi = (ai1, ai2, . . . , aim)and denoteci(m1)+jbycij, fori≥ 0, j= 1, 2, . . . , m. Then for BRM codes

Fori≥1,

One can check that if a permutation sequence satisfies the constraints forC(n, 2, D, 1), i.e., there are at most D−1 zeros (or ones) between any two successive ones (or zeros), then the generated cell-level sequence realizes this sequence and has cell levels in[1, D].

We now show that Construction 9.9 generates a cell-level realization for each codeword in BRM code. are left to show thatC ranges between 1 and D.

Assume(d01, d02, . . . , d0m1, . . . , dn1, dn2, . . . , dnm1, dn1+1)is an arbitrary realization ofP and 1 ≤ dij ≤ D for j =1, . . . , m−1, i= 0, 1, . . . , n. For ci1,i=0, 1, . . . , n−1, we will prove a stronger condition:

ai1 ≤ci1≤ di1, aim1≤ ci1, if ai1 <aim

di1≤ ci1≤ai1+D−m, c11 ≤aim1+D−m, if ai1> aim

(9.6)

The inequalities containing aim1 are not considered when i = 0. Notice the cell-level sequence (di1, . . . , dim1, di1+1)induces(ai1, . . . , aim1, aim). Hence, for1 ≤ j, k ≤ m such that aij ≥ aik, we have

aij−aik ≤dij−dik (9.7)

Letaij = ai1, aik =1, and aij = m, aik =ai1, and we get

a1i ≤di1≤ai1+D−m (9.8)

Similarly, since(di11, . . . , dim11, di1)induces(ai11, . . . , aim11, aim1), we haveaim1 ≤ di1 ≤aim1+ D−m. Suppose (9.6) holds, then 1 ≤ ai1 ≤ ci1 ≤ ai1+D−m ≤ D and 1 ≤ aim1 ≤ ci1 ≤ aim1+D−m ≤ D. And by (9.5), either 1 ≤ aij = ai1+aij−ai1 ≤ cij = ci1+aij −ai1 ≤ (ai1+D−m) +aij−ai1= aij+D−m≤ D or 1≤ aij ≤cij =ci1+1+aij−aim ≤ aij+D−m≤ D, which would complete the proof.

we will prove (9.6) by induction. For the base case(i=0), if a01 <a0m, thenc01=a01≤ d01. And ifa01 > a0m, thend01 ≤ a01+D−m= c01. Now suppose (9.6) holds fori−1 ≥0. If ai11 < aim1 andai1< aim, then by induction,

ai11≤ci11≤ di11, aim2≤ ci11 (9.9)

Now either aim1

(9.9)

≤ ci11+aim1−ai11 ≤ ai1 = c1i

(9.8)

≤ di1 or ai1 ≤ ci11+aim1−ai11 = ci1

(9.9)

≤ di11+aim1−ai11

(9.7)

≤ di1andaim1

(9.9)

≤ ci11−ai11+aim1 = ci1. Therefore, (9.6) holds for ci1 in this case. Ifai11 > aim1 andai1 < aim, then by (9.8) either aim1 ≤ ai1 = ci1 ≤ di1 or ai1 ≤ aim1 = ci1 ≤ di1. Therefore, (9.6) holds in this case, too. And we can prove by similar arguments that (9.6) is true for the other two cases, thus complete this proof.

The cell-level decoder is an m-sorter that orders every m-cell-level tuple associated with the permutations. The complexity ism log m.

• Flash programming/reading

To avoid over-programming, the programming of a cell-level sequence into flash memories is operated from the lowest to the highest rank. Such a programming method will lead to a delay ofn in the worst case. However, since for BRM code with one overlap, onlyci1,i≥0 are contained in two permutations, we only need to obtain correct ordering for{ci1, ci1+1}and{ci1, ci2, . . . , cim1, ci1+1}, for alli ≥ 0. And ordering of other sets of cell levels are not used in the code. Construction 9.11 follows the above idea and has smaller delay thann, for n sufficiently long.

Construction 9.11 we first define a writing operation forci1, denoted byOp(i), as follows.

1. Ifi ≥1, compare ci1andci11. Ifci1 < c1i1, write into flash{cij1|j= 2, . . . , m−1, cij1 <

ci1}from low to high level. Otherwise, write{cij1|j=2, . . . , m−1, ci11<cij1< ci1}from low to high level.

2. If ci1 < ci1+1, write into flash {cij|j = 2, . . . , m−1, cij < ci1}from low to high level. If ci1> ci1+1, write{cij|j=2, . . . , m−1, ci1+1 <cij < c1i}from low to high level.

3. Writeci1so that it has a higher charge level than all the cells written in steps 1 and 2.

4. If i ≥ 1, and ci1 > ci11, then write{cij1|j = 2, . . . , m−1, cij1 > c1i}from low to high level. And ifci1>ci1+1, write into flash{cij|j=2, . . . , m−1, cij > ci1}from low to high level.

In steps 1, 2, and 4, the only requirement is that the charge level of each programmed cell is higher than the previously written one.

Now starting from i= 0, if ci1 < ci1+1, doOp(i), and updatei with i+1. Otherwise, find the smalleste≥1, such that ci1+e<ci1+e+1, doOp(i+e), Op(i+e−1), . . . , Op(i), and then update i with i+e+1.

The above procedure clearly realizes the given permutation sequence, and moreover has a worst-case delay D(m−1). In the worst case,ci1 = D, ci1+1 = D−1, . . . , ci1+D1 = 1, and ci11 <

ci21 < D, for some i ≥ 1, hence one has to receive ci21, . . . , cim11, ci1, . . . , cim1, . . . , ci1+D1 to writeci2.

For BRM code with permutations of size2, the programming process reduces to operations on ci1only, fori≥0, with maximum delay D.

Flash reading can be simply realized by sequentially reading off cell charge levels from flash.

Notice that both the cell-level encoder and flash programming has rate 1, so the BRM code encoder has rate p/(q(m−v))by Theorem 9.7, which can be arbitrarily close to the capacity.

We will now give an example of the complete encoding/decoding process for BRM code C(n, 2, 4, 1). The encoder has rate0.75 in this example.

Example 9.12 Encoding: suppose the information sequence is(x0. . . x11. . .) =

(001 100 000 010 . . .). Then following Example 9.8, the encoded permutation sequence is (P0. . . P15) = (1001 0100 1110 1010 . . .), and the state transition in the finite-state encoder is state1 → 1 → 2 → 1 → 1. Using Construction 9.9, we get the encoded cell-level sequence (c1. . . c16. . .) = (1 431 41 431 2 3 41 41 4 . . .). And at last it can be programmed into flash in the order: (c1, c4, c3, c2, c6, c5, c9, c8, c7, c10, c11, c13, c12, c15, c14. . .).

Decoding: assume we are to decode the flash cells programmed above. First read the cells sequentially and then compare ci+1 and ci+2, fori ≥ 0. Decode Pi as1 if ci+1 < ci+2, as 0 if ci+1 > ci+2. Thus we get (P0. . . P15) = (1001 0100 1110 1010 . . .), and by the decoding scheme in Example9.8, we get(x0. . . x11. . .) = (001 100 000 010 . . .).

In document Coding for Information Storage (Page 159-166)