#18269: A new structure for experimentation on decoding: communication channels
-------------------------+-------------------------------------------------
       Reporter:         |        Owner:
  dlucas                 |       Status:  needs_work
           Type:         |    Milestone:  sage-6.7
  enhancement            |   Resolution:
       Priority:  major  |    Merged in:
      Component:         |    Reviewers:
  coding theory          |  Work issues:
       Keywords:         |       Commit:
        Authors:         |  874deac06298703bc9cd9d8354302830739d6089
Report Upstream:  N/A    |     Stopgaps:
         Branch:         |
  u/dlucas/channels      |
   Dependencies:         |
-------------------------+-------------------------------------------------

Comment (by dlucas):

 I did some changes, as stated by commit messages above.

 Some remarks:

 - I kept `tuple_to_integer` because the user can pass either an integer or
 an interval as `number_errors` parameter for the channels. If the user
 passes an integer, then `randint` won't work. Of course it is possible to
 do the check anytime you call `number_errors` (if integer, return it, else
 do a randint and return the result) but it's rather tedious. Especially
 because it's something that will be used by a some channels. I think it's
 easier to call a single method rather than copying the `if` statement each
 time. Maybe `tuple_to_integer` is not really a good name though.

 - `random_error_vector(n, F, error_positions)` returns a vector of length
 `n` over `F` with `0`s in every position except those listed in
 `error_positions`. Because of this, calling `vect = [F.random_element()
 for _ in range(n)]` in `random_error_vector` does not really fit, because
 it will create a vector with non-controlled zero positions, so we'll need
 to set all positions except those into `error_positions` afterwards. I
 think create a zero vector of size `n` and add random values at some
 positions is better.

 - I did not change the documentation, nor the catalog stuff (see comment
 4). If you think that Channels are actually more linked to codes than to
 anything else, I can make some changes.

 David

--
Ticket URL: <http://trac.sagemath.org/ticket/18269#comment:7>
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 http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to