I would define the span over the integers differently, using 
"span_of_basis" to make sure it uses the basis you specify:

sage: V = ZZ^2
sage: W = V.span_of_basis(R)
sage: W
Free module of degree 2 and rank 2 over Integer Ring
User basis matrix:
[1 3]
[1 0]
sage: W.coordinates([0,3])
[1, -1]

These constructions are not all implemented over Integers(15) (but the ZZ 
coordinates will work over Integers(15), if there is an integer solution).


On Friday, February 22, 2019 at 10:41:06 AM UTC-8, chandra chowdhury wrote:
>
>
> Hi,
>   I take two vectors as follows: 
>  R=[(1, 3), (1, 0)]
>
> Then I span it over integers like 
> R=(ZZ^2).span(R)
>
> It is clear that vector([0,3]) is in R. 
> I want to find corresponding coordinates i.e, 
> (1,-1). How can I find this using Sage? 
>
> Instead of integers, is it possible to span over the ring 
> Integers(15) and find the coordinates?
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.

Reply via email to