A pseudorandom binary sequence (PRBS) is a binary sequence that, while generated with a deterministic algorithm, is difficult to predict and exhibits statistical behavior similar to a truly random sequence. PRBS are used in telecommunication, encryption, simulation, correlation technique and time-of-flight spectroscopy.
A binary sequence (BS) is a sequence a 0 , … , a N − 1 of N bits, i.e.
a j ∈ { 0 , 1 } for
j = 0 , 1 , . . . , N − 1 .
A BS consists of m = ∑ a j ones and N − m zeros.
A BS is a pseudorandom binary sequence (PRBS) if its autocorrelation function, given by
C ( v ) = ∑ j = 0 N − 1 a j a j + v has only two values:
C ( v ) = { m , if v ≡ 0 ( mod N ) m c , otherwise where
c = m − 1 N − 1 is called the duty cycle of the PRBS, similar to the duty cycle of a continuous time signal. For a maximum length sequence, where N = 2 k − 1 , the duty cycle is 1/2.
A PRBS is 'pseudorandom', because, although it is in fact deterministic, it seems to be random in a sense that the value of an a j element is independent of the values of any of the other elements, similar to real random sequences.
A PRBS can be stretched to infinity by repeating it after N elements, but it will then be cyclical and thus non-random. In contrast, truly random sequence sources, such as sequences generated by radioactive decay or by white noise, are infinite (no pre-determined end or cycle-period). However, as a result of this predictability, PRBS signals can be used as reproducible patterns (for example, signals used in testing telecommunications signal paths).
Pseudorandom binary sequences can be generated using linear feedback shift registers.
Some common sequence generating polynomials are
PRBS7 =
x 7 + x 6 + 1 PRBS9 =
x 9 + x 5 + 1 PRBS11 =
x 11 + x 9 + 1 PRBS15 =
x 15 + x 14 + 1 PRBS20 =
x 20 + x 3 + 1 PRBS23 =
x 23 + x 18 + 1 PRBS31 =
x 31 + x 28 + 1 An example of generating a "PRBS-7" sequence can be expressed in C as
In this particular case, "PRBS-7" has a repetition period of 127 bits.
The PRBSk or PRBS-k notation (such as "PRBS7" or "PRBS-7") gives an indication of the size of the sequence. N = 2 k − 1 is the maximum number of bits that be in the sequence. The k indicates the size of a unique word of data in the sequence. If you segment the N bits of data into every possible word of length k, you will be able to list every possible combination of 0s and 1s for a k-bit binary word, with the exception of the all-0s word. For example, PRBS3 = "1011100" could be generated from x 3 + x 2 + 1 . If you take every sequential group of three bit words in the PRBS3 sequence (wrapping around to the beginning for the last few three-bit words), you will find the following 7 words:
"
1011100" → 101 "1
011100" → 011 "10
11100" → 111 "101
1100" → 110 "1011
100" → 100 "
10111
00" → 001 (requires wrap) "
101110
0" → 010 (requires wrap)
Those 7 words are all of the 2 k − 1 = 2 3 − 1 = 7 possible non-zero 3-bit binary words, not in numeric order. The same holds true for any PRBSk, not just PRBS3.