[sage-support] Questión about primitive element

2011-09-28 Thread Juan Grados
Hi How I will get a primite element ... F = GF(2) PRF. = PolynomialRing(F); print PRF Phi = PRF.quotient(z^4+z+1); Phi.primitive_element() . ? -- - Juan del Carmen Grados Vásquez Laboratório Nacional de Computação

[sage-support] Question About Primitive Element

2011-09-28 Thread juaninf
Hi How I will get a primite element ... F = GF(2) PRF. = PolynomialRing(F); print PRF Phi = PRF.quotient(z^4+z+1); Phi.primitive_element() . ? -- - Juan del Carmen Grados Vásquez Laboratório Nacional de Computação

Re: [sage-support] Question about Patterson Algorithm Implementation

2011-09-28 Thread D. S. McNeil
> This is definitely not a bug.   The definition of the _add_ method > absolutely demands that both inputs have exactly the same parent.  In > the above instance, the left hand input (=1) has parent ZZ, and the > right hand input (=SR(2)) has parent the symbolic ring. Yeah, I know that-- it's the

Re: [sage-support] Question about Patterson Algorithm Implementation

2011-09-28 Thread Juan Grados
Hi thanks for your answers, I used _inverter_, _mul_, _add_ etc, because apparently the implementation work fine but only "apparently", i think that the essencial problem is with _invert_ method, but now I used inverse_mod , but I dont where are the error, I implemented Berlekamp Algorithm too, fr

Re: [sage-support] Question about Patterson Algorithm Implementation

2011-09-28 Thread Juan Grados
in the end line print sigma.roots(), always give empty vector, here sigma.roots() should nonzero vector 2011/9/28 Juan Grados > Hi thanks for your answers, > > I used _inverter_, _mul_, _add_ etc, because apparently > the implementation work fine but only "apparently", > i think that the esse

[sage-support] Diagonalizing (symmetric) matrices with entries in a rational function field

2011-09-28 Thread flyingsquirrel
I have a symmetric matrix that I want to diagonalize, such as x y z y 0 xy z xy xyz x, y, z being variables, and the base field is CC (complex numbers). I typed in the following: R.=CC[] m=matrix(R,[[x,y,z],[y,0,x*y],[z,x*y,x*y*z]]) m.eigenvalues() and I get an error message (NotImple

[sage-support] Re: Diagonalizing (symmetric) matrices with entries in a rational function field

2011-09-28 Thread achrzesz
On Sep 28, 2:48 pm, flyingsquirrel wrote: > I have a symmetric matrix that I want to diagonalize, such as > > x   y   z > y   0   xy > z   xy xyz > > x, y, z being variables, and the base field is CC (complex numbers). I > typed in the following: > > R.=CC[] > m=matrix(R,[[x,y,z],[y,0,x*y],[z,x*

[sage-support] inverse function

2011-09-28 Thread globaljavaprogrammer
how can I use sage to compute the inverse of a function like f(x) = (x +1)^2? -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.

Re: [sage-support] inverse function

2011-09-28 Thread Minh Nguyen
Hi, On Thu, Sep 29, 2011 at 2:17 AM, globaljavaprogrammer wrote: > how can I use sage to compute the inverse of a function like f(x) = (x > +1)^2? sage: f = (x + 1)^2 sage: g = 1 / f sage: h = f^(-1) sage: f*g 1 sage: g*f 1 sage: f*h 1 sage: h*f 1 -- Regards Minh Van Nguyen -- To post to thi

[sage-support] Re: inverse function

2011-09-28 Thread kcrisman
On Sep 28, 12:49 pm, Minh Nguyen wrote: > Hi, > > On Thu, Sep 29, 2011 at 2:17 AM, globaljavaprogrammer > > wrote: > > how can I use sage to compute the inverse of a function like f(x) = (x > > +1)^2? > > sage: f = (x + 1)^2 But assuming he meant the function inverse, not the multiplicative in

[sage-support] Re: error: C preprocessor "/lib/cpp" fails sanity check (installing sage-4.7.1 from source)

2011-09-28 Thread jsymons
I succesfully compiled from sources sage-4.7.1 on Pardus 2011.1 x86_64 using only this repository http://packages.pardus.org.tr/pardus/2011.1/stable/x86_64/pisi-index.xml.xz and these upgrades FreeImage-devel is upgraded from 3.15.0-7-p11-x86_64 to 3.15.0-10-p11- x86_64 FreeImage is upgra

[sage-support] Re: reducing ideal wrt another ideal

2011-09-28 Thread john_perry_usm
Try this: sage: I3_red_I2 = R.ideal([p.reduce(I2gb) for p in I3gb]) regards john perry On Sep 28, 12:24 am, Vinay Wagh wrote: > Suppose I have two ideals I & J in k[X_1,\cdots,x_n], where k is a > field. How do I reduce an ideal I wrt ideal J. > > e.g. Singular provides me a command > > singula

Re: [sage-support] Question about Patterson Algorithm Implementation

2011-09-28 Thread Juan Grados
help please! 2011/9/28 Juan Grados > in the end line > > print sigma.roots(), > > always give empty vector, here sigma.roots() should nonzero vector > > 2011/9/28 Juan Grados > >> Hi thanks for your answers, >> >> I used _inverter_, _mul_, _add_ etc, because apparently >> the implementation wo

Re: [sage-support] Question about Patterson Algorithm Implementation

2011-09-28 Thread Juan Grados
Hi David, Yes I understand, but now I think that have a logic problem in algorithm, but I don't know where ... i "copying lines" from [Ict2011], ... 2011/9/28 David Joyner > On Wed, Sep 28, 2011 at 5:58 PM, Juan Grados wrote: > > help please! > > > They did seem to solve your problem, didn't

Re: [sage-support] Question about Patterson Algorithm Implementation

2011-09-28 Thread Juan Grados
I have already sent, but I dont answer ... because I expect please only if anyelse can help me iff a time ... 2011/9/28 David Joyner > On Wed, Sep 28, 2011 at 6:12 PM, Juan Grados wrote: > > Hi David, > > > > Yes I understand, but now I think that have a logic problem in algorithm, > > but I do

[sage-support] Re: reducing ideal wrt another ideal

2011-09-28 Thread VInay Wagh
Ah! Thanks a lot for this "trick" of iteration! Day by day I am learning new tricks with sage :-) By the way after seeing your reply I saw a mathematical "typo" in my code: I should reduce I3 modulo I2 and not the other way round :-) Anyways, I have already taken of in my main program. Thanks a l