[sage-support] anomolous behavior in notebook
In the notebook, starting a block with '%octave' does not produce a result. This has been consistent throughout all releases of sage 2.* The behavior is consistent on MacOS and Ubuntu Linux. A sample session showing this is: sage: from math import * sage: sin(1) 0.8414709848078965 sage: gp.sin(1) 0.8414709848078965066525023216 sage: octave.sin(1) 0.841471 sage: %gp sage: sin(1) 0.8414709848078965066525023216 sage: %octave sage: sin(1) sage: 3+2 5 sage: quit Exited sage process David Galant --~--~-~--~~~---~--~~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/ -~--~~~~--~~--~--~---
[sage-support] Re: anomolous behavior in notebook
On Oct 28, 8:27 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: Hello David, > In the notebook, starting a block with '%octave' does not produce a > result. > This has been consistent throughout all releases of sage 2.* > The behavior is consistent on MacOS and Ubuntu Linux. > A sample session showing this is: > > sage: from math import * > sage: sin(1) > 0.8414709848078965 > sage: gp.sin(1) > 0.8414709848078965066525023216 > sage: octave.sin(1) > 0.841471 > sage: %gp > sage: sin(1) > 0.8414709848078965066525023216 > sage: %octave > sage: sin(1) > > sage: 3+2 > 5 > sage: quit > Exited sage process > That looks like a bug to me and I can reproduce this strange behavior. I opened ticket a ticket for this - see http://www.sagetrac.org/sage_trac/ticket/1019 > David Galant Cheers, Michael --~--~-~--~~~---~--~~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/ -~--~~~~--~~--~--~---
[sage-support] Re: bug in permutations?
Mike: Since your Permutations does things correctly, I wonder if permutations should be (a) renamed permutations_gap or something, or (b) a "WARNING: this GAP wrapper is deprecated in favor of Permutations" (or something like that) should be printed on it's use? At the very least, maybe (c) the docstring for permutations should point to Permutations? For example, I remembered that you had reworked the combinatorial functions and thought permutations was yours at first. On 10/27/07, Mike Hansen <[EMAIL PROTECTED]> wrote: > > Hello, > > My new(er) Permutations combinatorial class should handle things correctly. > > sage: MS = MatrixSpace(QQ, 2, 2) > sage: A = MS([1,2,3,4]) > sage: Permutations(A.rows()).list() > [[(1, 2), (3, 4)], [(3, 4), (1, 2)]] > sage: MS = MatrixSpace(GF(2),2,2) > sage: A = MS([1,2,3,4]) > sage: Permutations(A.rows()).list() > [[(1, 0), (1, 0)]] > > --Mike > > > On 10/27/07, David Joyner <[EMAIL PROTECTED]> wrote: > > > > Hi: > > Either a bug in combinat.py's permutations, or an indication that > > it needs to be rewritten. (permutations is a GAP wrapper which > > I might have written, so should probably fix ...) > > > > - David Joyner > > > > > > sage: MS = MatrixSpace(QQ,2,2) > > sage: A = MS([1,2,3,4]) > > sage: permutations(A.rows()) > > [[(3, 4), (1, 2)], [(1, 2), (3, 4)]] > > sage: > > sage: MS = MatrixSpace(GF(2),2,2) > > sage: A = MS([1,2,3,4]) > > sage: permutations(A.rows()) > > --- > > Traceback (most recent call last) > > > > /Users/wdj/sagefiles/sage-2.8.2/ in () > > > > /Users/wdj/sagefiles/sage-2.8.2/local/lib/python2.5/site-packages/sage/combinat/combinat.py > > in permutations(mset) > >1552 > >1553 """ > > -> 1554 ans=gap.eval("PermutationsList(%s)"%mset) > >1555 return eval(ans) > >1556 > > > > /Users/wdj/sagefiles/sage-2.8.2/local/lib/python2.5/site-packages/sage/interfaces/gap.py > > in eval(self, x, newlines, strip) > > 301 if len(x) == 0 or x[len(x) - 1] != ';': > > 302 x += ';' > > --> 303 s = Expect.eval(self, x) > > 304 if newlines: > > 305 return s > > > > /Users/wdj/sagefiles/sage-2.8.2/local/lib/python2.5/site-packages/sage/interfaces/expect.py > > in eval(self, code, strip, **kwds) > > 648 code = code.strip() > > 649 try: > > --> 650 return '\n'.join([self._eval_line(L, **kwds) for L > > in code.split('\n') if L != '']) > > 651 except KeyboardInterrupt: > > 652 # DO NOT CATCH KeyboardInterrupt, as it is being caught > > > > /Users/wdj/sagefiles/sage-2.8.2/local/lib/python2.5/site-packages/sage/interfaces/gap.py > > in _eval_line(self, line, allow_use_file, wait_for_prompt) > > 502 return '' > > 503 else: > > --> 504 raise RuntimeError, message > > 505 > > 506 except KeyboardInterrupt: > > > > : Gap produced error output > > Permutation: must be a positive integer (not a integer) > > > >executing PermutationsList([(1, 0), (1, 0)]); > > > > > > > > > > > --~--~-~--~~~---~--~~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/ -~--~~~~--~~--~--~---
[sage-support] Re: bug in permutations?
On Oct 28, 2007, at 03:39 , David Joyner wrote: > > Mike: > Since your Permutations does things correctly, I wonder if > permutations should be (a) renamed permutations_gap > or something, or (b) a "WARNING: this GAP wrapper is > deprecated in favor of Permutations" (or something like that) > should be printed on it's use? At the very least, maybe (c) the > docstring > for permutations should point to Permutations? > For example, I remembered that you had reworked the > combinatorial functions and thought permutations was > yours at first. Please: no printed "deprecated" warnings. Anything would be better than that. OK, not anything, but printed warnings are not much help, and can be really annoying. How many people have seen this on Unix/Linux systems warning: this program uses gets(), which is unsafe. and have no clue what they should do about it (or what 'unsafe' means? Is my bank account about to be emptied?)? Justin -- Justin C. Walker, Curmudgeon-At-Large Director Institute for the Enhancement of the Director's Income "Weaseling out of things is what separates us from the animals. Well, except the weasel." - Homer J Simpson --~--~-~--~~~---~--~~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/ -~--~~~~--~~--~--~---
[sage-support] Re: bug in permutations?
On 10/28/07, Justin C. Walker <[EMAIL PROTECTED]> wrote: > Please: no printed "deprecated" warnings. Anything would be better > than that. +2 -- I very strongly agree with this. In fact, I think the best thing to do would be just get rid of entirely calling Gap via pexpect to create all permutations of an object. BIG NEWS FLASH: Using pseudo-tty's is slow and should be avoided when other options are available. It allows us to very quickly get lots of functionality, whilst not reinventing the wheel. But it's not panacea. -- William --~--~-~--~~~---~--~~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/ -~--~~~~--~~--~--~---
[sage-support] Re: [sage-devel] Sage 2.8.10 is released
On 10/28/07, Carl Witty <[EMAIL PROTECTED]> wrote: > > Sage 2.8.10 has been released. Download from > http://sagemath.org/download.html or upgrade with "sage -upgrade", as > usual. > > This release includes updated spkg's prepared by Robert Bradshaw and > Carl Witty, and patches created by Carl Witty, William Stein, Jaap > Spies, Joel Mohler, Robert Miller, David Joyner, Mike Hansen, Jason > Grout, Craig Citro, Nils Bruin, Robert Bradshaw, Martin Albrecht, and > Michael Abshoff (listed in REVERSE alphabetical order, so that I get > to be FIRST. Hah! Take that, Mr. Abshoff and Mr. Albrecht!) There is also a nice list of changes and tickets here: http://sagemath.org/announce/sage-2.8.10.txt This is also the second release that I did almost none of the work on, which is a great thing :-) Michael Abshoff will be the release manager for the next release (2.8.11), which is due out on Friday. -- William --~--~-~--~~~---~--~~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/ -~--~~~~--~~--~--~---
[sage-support] side effect problem of numpy.dot with Integer and QQ arrays.
In sage, the arguments of numpy.dot can be changed when they shouldn't. The following illustrates the problem: import numpy as npy # With sage.rings.integer.Integer: x = npy.array([1]) print x # [1] npy.dot(x, npy.array([0])) print x # [0] # This also happens with QQ arrays, but not # with any of the finite fields I tried. y = MatrixSpace(QQ,2).identity_matrix().numpy() print y # [[1 0] [0 1]] npy.dot(y, npy.array(VectorSpace(QQ,2).basis()[0])) print y # [[1 0] [0 0]] I am using SAGE version 2.8.7. Explanations and workarounds are appreciated. Manny --~--~-~--~~~---~--~~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/ -~--~~~~--~~--~--~---