#20087: `__call__(message)` on a linear code or encoder should return a
codeword.
-------------------------------------+-------------------------------------
Reporter: jsrn | Owner:
Type: enhancement | Status: needs_review
Priority: major | Milestone: sage-7.2
Component: coding theory | Resolution:
Keywords: beginner | Merged in:
Authors: David Lucas | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
u/dlucas/shortcut_to_encode | 872f5d79d4dc260c64ff1512aefaf796d6bc15a8
Dependencies: | Stopgaps:
-------------------------------------+-------------------------------------
Comment (by jsrn):
David, didn't you accidentally put the Encoder-related code on the GRS
encoder? It should be on the abstract class `Encoder`. Also, the check `if
m in self` should be `if m in self.code()` on the Encoder. And your doc-
test there doesn't test that method.
Replying to [comment:12 panda314]:
> Hi, Maybe the check of whether the vector passed is a codeword or not
can be done before passing it to the encode function. That way if a user
means to pass a codeword rather than the message, and passed th wrong
vector, he/she will be notified.
As far as I can see, the check in `LinearCode` *does* check for code
membership before passing it to the encoder.
--
Ticket URL: <http://trac.sagemath.org/ticket/20087#comment:13>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.