On Saturday, May 12, 2012 4:01:11 PM UTC-4, Johan Grönqvist wrote:
>
> 2012-05-12 21:54, raman kurdi skrev: 
> > Hi, 
> > I need a command which separate the components of points. For example 
> > let P=(2,4). 
> > I need the first component of this point. 
> > Could you please help me? 
> > 
>
> sage: P=(2,4) 
> sage: P[0] 
> 2 
> sage: P[1] 
> 4 
>
>
>

Just to make it clear, you are really taking items from a "Python tuple". 
 If you are talking about actual "points" in the graphical sense, you'd 
need to do something else.

sage: P = point((2,3))
sage: p = P[0]
sage: p.xdata
[2.0]
 

-- 
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

Reply via email to