Main Content

bchnumerr

Number of correctable errors for BCH code

Description

example

T = bchnumerr(N) returns all the possible combinations of message length, K, and number of correctable errors, T, for a BCH code of codeword length, N.

example

T = bchnumerr(N, K) returns the number of correctable errors, T, for an (N, K) BCH code.

Examples

collapse all

Calculate the possible message length combinations for a BCH code word length of 15.

T = bchnumerr(15)
T = 3×3

    15    11     1
    15     7     2
    15     5     3

Calculate the number of correctable errors for BCH code 15,11

T = bchnumerr(15,11)
T = 1

Input Arguments

collapse all

Codeword length, specified as an integer scalar. N must have the form 2m-1 for some integer, m, between 3 and 16.

Example: 15

Data Types: double

Message length, specified as an integer scalar. N and K must produce a narrow-sense BCH code.

Example: 11

Data Types: double

Output Arguments

collapse all

Number of correctable errors, returned as a scalar or matrix value.

bchnumerr(N) returns a matrix with three columns. The first column lists N, the second column lists K, and the third column lists T.

bchnumerr(N,K) returns a scalar, which represents the number of correctable errors for the BCH code.

Version History

Introduced before R2006a