#16507: Better handling of subspace construction in pushout
--------------------------+------------------------------------
   Reporter:  pbruin      |            Owner:
       Type:  defect      |           Status:  new
   Priority:  minor       |        Milestone:  sage-6.3
  Component:  categories  |         Keywords:  pushout subspace
  Merged in:              |          Authors:  Peter Bruin
  Reviewers:              |  Report Upstream:  N/A
Work issues:              |           Branch:
     Commit:              |     Dependencies:
   Stopgaps:              |
--------------------------+------------------------------------
 When taking a pushout of two modules in the case where the construction of
 exactly one of them involves a subspace construction, the result does not
 have a coercion map from the other object:
 {{{
 sage: A = ZZ^2
 sage: V = span([[1, 2]], QQ)
 sage: P = sage.categories.pushout.pushout(A, V)
 sage: P
 Vector space of degree 2 and dimension 1 over Rational Field
 User basis matrix:
 [1 2]
 sage: P.has_coerce_map_from(A)
 False
 }}}
 The explanation is that for the other currently existing constructions
 `F`, the result `F(X)` of applying the construction to `X` has a coercion
 map ''from'' `X`, but for the subspace construction, `F(X)` only has a
 coercion map ''to'' `X`.

 This ticket addresses this by equipping the class `ConstructionFunctor`
 with an attribute `coercion_reversed`, which is `False` by default; if it
 is `True` for a construction `F`, then the pushout of two objects omits
 `F` in the case where (at a given step of constructing the pushout)
 exactly one of the two constructions is `F`.  Of course, we set
 `coercion_reversed = True` for the subspace construction.

 No change is necessary in the case where both constructions involve `F`,
 since this situation should be taken care of by `F.merge()`.  This is
 indeed true for the subspace construction, where `F.merge()` takes the sum
 of the two subspaces.

 The situation described above can be viewed as the case where one of the
 two constructions involves a "trivial" application of `F`, i.e. with the
 subspace equal to the whole space.  Hence we should interpret our
 situation as a case where the effect of `merge()` with one trivial
 argument is desired.

 In the above example, this strategy will cause `P` to be equal to `QQ^2`,
 as might be expected.

--
Ticket URL: <http://trac.sagemath.org/ticket/16507>
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