Opened 6 years ago

Closed 6 years ago

#20898 closed defect (fixed)

Syndrome decoder for a linear code sometimes sets wrong decoder type

Reported by: jsrn Owned by:
Priority: major Milestone: sage-7.3
Component: coding theory Keywords: linear code, syndrome, rd3
Cc: dlucas Merged in:
Authors: Clément Pernet Reviewers: Bruno Grenet
Report Upstream: N/A Work issues:
Branch: f152ea8 (Commits, GitHub, GitLab) Commit: f152ea833b7fb8be9831bf36175e6ed37e4eeca1
Dependencies: Stopgaps:

Status badges


There is a bug in how the decoder type is set for the syndrome decoder. Consider

sage: C = codes.HammingCode(GF(5), 3)
sage: D = C.decoder("Syndrome")
sage: C.minimum_distance()
sage: D.maximum_error_weight()
sage: D.decoder_type()
{'complete', 'hard-decision', 'might-error', 'unique'}

The last line should not have had "might-error" but instead should have had "always-succeed" and "minimum-distance".

Change History (5)

comment:1 Changed 6 years ago by cpernet

  • Branch set to u/cpernet/syndrome_decoder_type

comment:2 Changed 6 years ago by cpernet

  • Authors set to Clément Pernet
  • Commit set to d581d76152e369ec40e08254bafe61e1d34aa951
  • Keywords rd3 added
  • Status changed from new to needs_review

There was actually 2 bugs: the decoding_radius tested for this decision was not updated with the value found during the construction of the lookup table. Then some set.add needed to be changed.

I also added the ticket's code as a doctest.

Attached branch should fix the pb. Open for review.

New commits:

ffb9bdcfix 2 bugs: the updated max_error_weight was not tested + add->union
6f8bf3cNeed to get the result that union returns
d581d76add #20898 code as a doctest

comment:3 Changed 6 years ago by git

  • Commit changed from d581d76152e369ec40e08254bafe61e1d34aa951 to f152ea833b7fb8be9831bf36175e6ed37e4eeca1

Branch pushed to git repo; I updated commit sha1. New commits:

f152ea8replace union by update

comment:4 Changed 6 years ago by bruno

  • Reviewers set to Bruno Grenet
  • Status changed from needs_review to positive_review

Looks OK!

comment:5 Changed 6 years ago by vbraun

  • Branch changed from u/cpernet/syndrome_decoder_type to f152ea833b7fb8be9831bf36175e6ed37e4eeca1
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.