#20198: `LinearCode(C)` for some code `C` should construct a code
-----------------------------------------+------------------------
       Reporter:  jsrn                   |        Owner:
           Type:  enhancement            |       Status:  new
       Priority:  major                  |    Milestone:  sage-7.1
      Component:  coding theory          |   Resolution:
       Keywords:  linear code, beginner  |    Merged in:
        Authors:                         |    Reviewers:
Report Upstream:  N/A                    |  Work issues:
         Branch:                         |       Commit:
   Dependencies:                         |     Stopgaps:
-----------------------------------------+------------------------
Description changed by jsrn:

Old description:

> With the recent sub-classing framework for linear codes, it is now often
> useful to recast a code from some family as a generic linear code, thus
> forgetting its structure, e.g.
>
> {{{
> sage: C = codes.GeneralizedReedSolomonCode(GF(23).list(), 12)
> sage: Chan = channels.StaticErrorRateChannel(GF(23)^7, 2)
> sage: %timeit C.decode(Chan(C.random_element()))
> <some short time>
> sage: C_dumb = LinearCode(C)
> sage: %timeit C.decode(Chan(C.random_element()))
> <loong time>
> }}}
>
> Except the above code doesn't work, since `LinearCode` expects a matrix,
> and can't understand a code as input.

New description:

 With the recent sub-classing framework for linear codes, it is now often
 useful to recast a code from some family as a generic linear code, thus
 forgetting its structure, e.g.

 {{{
 sage: C = codes.GeneralizedReedSolomonCode(GF(23).list(), 12)
 sage: Chan = channels.StaticErrorRateChannel(GF(23)^7, 2)
 sage: %timeit C.decode(Chan(C.random_element()))
 <some short time>
 sage: C_dumb = LinearCode(C)
 sage: %timeit C_dumb.decode(Chan(C_dumb.random_element()))
 <loong time>
 }}}

 Except the above code doesn't work, since `LinearCode` expects a matrix,
 and can't understand a code as input.

--

--
Ticket URL: <http://trac.sagemath.org/ticket/20198#comment:1>
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.

Reply via email to