[sage-support] Re: Polynomial Problem

2009-01-21 Thread Jason Grout
Robert Bradshaw wrote: > On Dec 29, 2008, at 4:47 PM, William Stein wrote: > >> On Mon, Dec 29, 2008 at 4:34 PM, Robert Bradshaw >> wrote: >>> +1 to (deprecating then removing) removing X.list(), and replacing it >>> with X.entries(). >> Very good point. We *must* remember to make X.list() use

[sage-support] Re: Polynomial Problem

2008-12-29 Thread Robert Bradshaw
On Dec 29, 2008, at 4:47 PM, William Stein wrote: > > On Mon, Dec 29, 2008 at 4:34 PM, Robert Bradshaw > wrote: >> >> +1 to (deprecating then removing) removing X.list(), and replacing it >> with X.entries(). > > Very good point. We *must* remember to make X.list() use the > deprecation warning

[sage-support] Re: Polynomial Problem

2008-12-29 Thread William Stein
On Mon, Dec 29, 2008 at 4:34 PM, Robert Bradshaw wrote: > > +1 to (deprecating then removing) removing X.list(), and replacing it > with X.entries(). Very good point. We *must* remember to make X.list() use the deprecation warning system, and only remove it after 6 months. Could you make a tra

[sage-support] Re: Polynomial Problem

2008-12-29 Thread Robert Bradshaw
On Dec 29, 2008, at 4:15 PM, William Stein wrote: > On Mon, Dec 29, 2008 at 2:43 PM, Justin Walker wrote: >> >> On Dec 29, 2008, at 5:23 PM, John Cremona wrote: >> >>> >>> Maybe I missed the point here but after >> >> The point was a minor one... >> >>> R.=QQ[] >>> M=matrix(R,1,2,[x1+x2,x1*x2])

[sage-support] Re: Polynomial Problem

2008-12-29 Thread William Stein
On Mon, Dec 29, 2008 at 2:43 PM, Justin Walker wrote: > > > On Dec 29, 2008, at 5:23 PM, John Cremona wrote: > >> >> Maybe I missed the point here but after > > The point was a minor one... > >> R.=QQ[] >> M=matrix(R,1,2,[x1+x2,x1*x2]) >> >> you can get at the entries like this: >> sage: M[0,0] >

[sage-support] Re: Polynomial Problem

2008-12-29 Thread Justin Walker
On Dec 29, 2008, at 5:23 PM, John Cremona wrote: > > Maybe I missed the point here but after The point was a minor one... > R.=QQ[] > M=matrix(R,1,2,[x1+x2,x1*x2]) > > you can get at the entries like this: > sage: M[0,0] > x1 + x2 > sage: M[0,1] > x1*x2 For the OP, it was surprising that "lis

[sage-support] Re: Polynomial Problem

2008-12-29 Thread John Cremona
Maybe I missed the point here but after R.=QQ[] M=matrix(R,1,2,[x1+x2,x1*x2]) you can get at the entries like this: sage: M[0,0] x1 + x2 sage: M[0,1] x1*x2 where the only non-obvious thing to a mathematician is that the row/col indices start at at 0. The list() discussion seems separate to me.

[sage-support] Re: Polynomial Problem

2008-12-29 Thread Justin Walker
On Dec 29, 2008, at 4:53 PM, Robert Bradshaw wrote: > > On Dec 29, 2008, at 1:38 PM, Justin Walker wrote: > >> On Dec 29, 2008, at 3:32 PM, Santanu Sarkar wrote: >> >>> I write a program in SAGE as follows: >>> R.=QQ[] >>> M=matrix(R,1,2,[x1+x2,x1*x2]) >>> may i do following steps to extract poly

[sage-support] Re: Polynomial Problem

2008-12-29 Thread Robert Bradshaw
On Dec 29, 2008, at 1:38 PM, Justin Walker wrote: > On Dec 29, 2008, at 3:32 PM, Santanu Sarkar wrote: > >> I write a program in SAGE as follows: >> R.=QQ[] >> M=matrix(R,1,2,[x1+x2,x1*x2]) >> may i do following steps to extract polynomials from matrix? >> 1) x = list(M) >> 2) f1 = x[0] >> 3) f2

[sage-support] Re: Polynomial Problem

2008-12-29 Thread Justin Walker
On Dec 29, 2008, at 3:32 PM, Santanu Sarkar wrote: > I write a program in SAGE as follows: > R.=QQ[] > M=matrix(R,1,2,[x1+x2,x1*x2]) > may i do following steps to extract polynomials from matrix? > 1) x = list(M) > 2) f1 = x[0] > 3) f2 = x[1] > is f1 & f2 are polynomials? > if not how i can get