[sage-support] Re: Galois Groups of Number Fields

2010-05-25 Thread Simon King
Hi Lisa, On May 24, 7:46 pm, Lisa Berger rlb...@gmail.com wrote: Is there a way for us to get SAGE to give us the elements of the Gal group of a number field as automorphisms? I think it works like this: sage: P.x = QQ[] sage: K.z = NumberField(x^3+x^1+1) sage: G = K.galois_group(names='t')

[sage-support] Re: Galois Groups of Number Fields

2010-05-25 Thread Simon King
PS: On May 24, 7:46 pm, Lisa Berger rlb...@gmail.com wrote: ... Using the galois_group(type=pari)---we get the Pari group. However, when we use galois_group(),  we get an error message. I just noticed that you use the option type=pari. I don't know if that used to work in the past (it is not

[sage-support] Real exponential of a matrix (rotations with sine/cosine)

2010-05-25 Thread Laurent
Hi all I'm trying to exponentiate the small antisymmetric matrix (infinitesimal rotation of angle x). Following the ideas of the thread «How does one define a real variable», I try the following : sage : var('x') sage: assume(x,'real') sage : X=matrix([ [0,1],[-1,0] ]) sage: R=exp(x*X)

[sage-support] Re: Real exponential of a matrix (rotations with sine/cosine)

2010-05-25 Thread Simon King
Hi Laurent, I don't know if this is the most elegant method, but one could transform the matrix into a list, apply the simplification to the list elements (Python list comprehension), and transform back into a 2x2 matrix: sage: R.parent()([(t.real_part()+t.imag_part()).simplify_full() for t in

Re: [sage-support] Re: Real exponential of a matrix (rotations with sine/cosine)

2010-05-25 Thread Laurent
sage: R.parent()([(t.real_part()+t.imag_part()).simplify_full() for t in R.list()]) Workshop fine ! Many Thanks. Can I be picky ? The following does not work : sage: a=4 sage: a.parent()(a.list()) I quite understand why, and it has no importance for the problem I'm currently

Re: [sage-support] Real exponential of a matrix (rotations with sine/cosine)

2010-05-25 Thread Mike Hansen
Hello, On Tue, May 25, 2010 at 8:11 AM, Laurent moky.m...@gmail.com wrote: By the way, the following works : sage : a=R[0][0] sage: (a.real_part()+a.imag_part()).simplify_full() cos(x) How can automatize it ? Is it a way to perform this simplification to each element of the matrix at once

[sage-support] Re: Real exponential of a matrix (rotations with sine/cosine)

2010-05-25 Thread Simon King
On May 25, 4:35 pm, Laurent moky.m...@gmail.com wrote: Can I be picky ? Sure, but I can be picky as well :D The following does not work : sage: a=4 4 is not a matrix. Anyway, I guess Mike's suggestion is better (I wasn't aware of the apply_map method). Cheers, Simon -- To post to this

[sage-support] Re: Windows Installation

2010-05-25 Thread palkar
Hi, I am also facing the same problem. I am using the Windows Vista OS and the same version of the Virtual Box. Also I am trying to install the version 4.3 of the sage virtual box image On opening the ovf file I find a lot of references to vmware.com as follows

[sage-support] solving linear systems

2010-05-25 Thread VictorMiller
I have a sage program which involves a lot of calculations of the form: solve for x, Ax = b, where A is an integral matrix and x and b are column vectors. A is an integer matrix, but the solution (if it exists) for x might be rational. Actually I want more than this: I want to also determine

[sage-support] Problem getting contour plot of complex magnitude

2010-05-25 Thread Rhys Ulerich
Hi, I'm trying to get a contour plot of the magnitude of a complex function. Simple, non-complex things like contour_plot(abs(x+y), (x, -3, 3), (y, -3, 3)) work as I expect in the 4.4.2 notebook interface. However, when I change that to read contour_plot(abs(x+I*y), (x, -3, 3), (y, -3, 3))

[sage-support] Retrieving xy data from implicit plots

2010-05-25 Thread jbeorse
Hi, I am trying to retrieve the xy coordinates of an implicit plot, but I am having trouble. I am able to do this with regular 2d plots without a problem like this: p = plot(...) for r in p: X = numpy.array(r.xdata) Y = numpy.array(r.ydata) ... With an implicit plot I can retrieve

[sage-support] Re: Loading ABC triples: How to read *.gz files?

2010-05-25 Thread Rolandb
Tnx! Just for others (and maybe for the manual): import gzip F = get_remote_file(http://abcathome.com/data/triples_sofar.gz;) input_file = gzip.open(F, 'rb') all_data = input_file.read() Roland On 24 mei, 21:58, Jason Grout jason-s...@creativetrax.com wrote: On 05/24/2010 02:36 PM, Rolandb