LDPC decoding returning nonsense on any input

I am trying to encode and decode some examples using LDPC codes as preparation for my Bachelor's thesis.
I have the following example in mind:
https://hastebin.com/evexavaqug.sql
Here is my MATLAB Code to encode and then decode:
ldpcEncoder = comm.LDPCEncoder(sparse(H)); % Set up using own parity check matrix
ldpcDecoder = comm.LDPCDecoder(sparse(H)); % Set up using own parity check matrix
encData = ldpcEncoder(msg) % Encode
errData = encData;
errData(5) = 1; % Introduce error
decEncData = ldpcDecoder(encData) % Just to test
decErrData = ldpcDecoder(errData) % Actual error decode
The script successfully encodes msg (I can verify on paper and with my own Java program).
My problem is, that the decoder doesn't work. Even ldpcDecoder(encData) returns nonsense (in this case: [0 0 0 0 1 0]').
I also noticed that the decoder uses its full 50 iterations (the default max value) and then returns this nonsense.
The actual error decode returns a null vector, which is also incorrect, as it should return msg like the "test error decoding", where I am feeding in the correct message.
Am I doing something wrong here or is the function broken? My Java Program can successfully decode the same data and so can I on paper.

 채택된 답변

Nico Mexis
Nico Mexis 2020년 9월 20일

2 개 추천

I found the solution to my problem:
The LDPC decoder expects LLR (log likelihood ratio) values.
Therefore, the binary vector needs to be converted beforehand by using the following formula:
where is the i-th message bit and is the chance of a bitflip occuring.

댓글 수: 1

[Repeating the above, because for some reason Nico's images are nearly invisible:]
I found the solution to my problem:
The LDPC decoder expects LLR (log likelihood ratio) values.
Therefore, the binary vector needs to be converted beforehand by using the following formula:
where is the i-th message bit and is the chance of a bitflip occuring.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 AI for Wireless에 대해 자세히 알아보기

제품

릴리스

R2020a

태그

질문:

2020년 9월 19일

댓글:

2020년 9월 20일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by