[sage-devel] Re: Fwd: fricas-1.0.6.p0.spkg

2009-06-26 Thread maxthemouse

I am have been looking into the many errors reported in trac #6318
(http://trac.sagemath.org/sage_trac/ticket/6318). Most seem to be due
to only one problem, namely passing Sage symbolic expressions. This
has been mentioned elsewhere: 
http://groups.google.com/group/sage-devel/browse_thread/thread/7e3b729d6bb58a36#


A fricas specific thing seems to cause two errors. The returned type
is different in fricas than from axiom in some cases.

example 1:
sage: a = axiom('Fraction Integer')
sage: print a
Fraction Integer

sage: b = fricas('Fraction Integer')
sage: print b
Fraction(Integer)

When the type is one word like 'Integer' they give the same string.

example 2:
sage: two = fricas(2)
sage: two.comma(3)
[2,3]
sage: two.comma(3,4)
[2,3,4]
sage: _.type()
Tuple(PositiveInteger)   expected result is Tuple
PositiveInteger

There is a specific line in the type() method of
axiom.PanAxiomElement that evaluates self.name() and receives a string
from axiom or fricas which contains the type information. I am
guessing that it is also used to make the print string. The change
breaks the tests. Is the change intentional or accidental? Someone
from fricas will have to say.

I hope this helps.

Cheers,
Adam
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to 
sage-devel-unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-devel] Re: Fwd: fricas-1.0.6.p0.spkg

2009-06-26 Thread William Stein

On Fri, Jun 26, 2009 at 4:14 PM, maxthemouseadamwebb_...@yahoo.com wrote:

 I am have been looking into the many errors reported in trac #6318
 (http://trac.sagemath.org/sage_trac/ticket/6318). Most seem to be due
 to only one problem, namely passing Sage symbolic expressions. This
 has been mentioned elsewhere: 
 http://groups.google.com/group/sage-devel/browse_thread/thread/7e3b729d6bb58a36#


 A fricas specific thing seems to cause two errors. The returned type
 is different in fricas than from axiom in some cases.

 example 1:
 sage: a = axiom('Fraction Integer')
 sage: print a
 Fraction Integer

 sage: b = fricas('Fraction Integer')
 sage: print b
 Fraction(Integer)

 When the type is one word like 'Integer' they give the same string.

 example 2:
 sage: two = fricas(2)
 sage: two.comma(3)
 [2,3]
 sage: two.comma(3,4)
 [2,3,4]
 sage: _.type()
 Tuple(PositiveInteger)       expected result is Tuple
 PositiveInteger

 There is a specific line in the type() method of
 axiom.PanAxiomElement that evaluates self.name() and receives a string
 from axiom or fricas which contains the type information. I am
 guessing that it is also used to make the print string. The change
 breaks the tests. Is the change intentional or accidental? Someone
 from fricas will have to say.

Then you should join the fricas-devel mailing list and send this
message there too:

fricas-devel fricas-de...@googlegroups.com,

I would, but it's important that you see the response, of course.


 I hope this helps.

 Cheers,
 Adam
 




-- 
William Stein
Associate Professor of Mathematics
University of Washington
http://wstein.org

--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to 
sage-devel-unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-devel] Re: Fwd: fricas-1.0.6.p0.spkg

2009-06-19 Thread William Stein

On Fri, Jun 19, 2009 at 4:23 PM, Bill Pagebill.p...@newsynthesis.org wrote:

 -- Forwarded message --
 From: Adam Webb adamwebb_...@yahoo.com
 Date: Fri, Jun 19, 2009 at 5:55 AM
 Subject: fricas-1.0.6.p0.spkg
 To: bill.p...@newsynthesis.org



 Hi Bill,

 I threw together a Sage package. (fricas-1.0.6.p0.spkg,
 http://www.mediafire.com/file/whwmdzfimg2) The big change is that the
 new version of fricas does not install an 'axiom' script. This makes
 sense to me. I assume that if someone wanted to, they could install
 axiom into sage as an (separate) optional package. The install worked
 but there were a few errors that came up in testing. They seem to be
 related to expect.

 I found these running sage -t --optional fricas.py which gave the result:

There are many known failures in Sage's optional doctests.  I went
through and reported them all a few days ago as trac tickets.  There
were *already* tons with the Sage/Fricas interface:

http://trac.sagemath.org/sage_trac/ticket/6318

So maybe you aren't seeing new failures.


 ..
  traceback ommited
 .
 2 items had failures:
   2 of  21 in __main__.example_0
   2 of   8 in __main__.example_11
 ***Test Failed*** 4 failures.
 For whitespace errors, see the file
 /home/adamwebb/local/sage/tmp/.doctest_fricas.py
         [8.0 s]
 exit code: 1024

 --
 The following tests failed:


        sage -t --optional devel/sage-main/build/sage/interfaces/fricas.py

 from __main__.example_11

 sage: from sage.interfaces.fricas import __doctest_cleanup
 sage: a = FriCAS()
 sage: two = a(2)     #optional - fricas  =    gives error
 sage: a.is_running() #optional - fricas
 True
 sage: __doctest_cleanup()
 sage: a.is_running()
 False

 The traceback is:
 sage: from sage.interfaces.fricas import __doctest_cleanup
 sage: a = FriCAS()
 sage: two = a(2)
 ---
 TypeError                                 Traceback (most recent call last)

 /home/adamwebb/.sage/temp/haso220w/18889/_home_adamwebb__sage_init_sage_0.py
 in module()

 /home/adamwebb/local/sage/local/lib/python2.5/site-packages/sage/interfaces/expect.pyc
 in __call__(self, x, name)
   1024             return cls(self, x, name=name)
   1025         try:
 - 1026             return self._coerce_from_special_method(x)
   1027         except TypeError:
   1028             raise

 /home/adamwebb/local/sage/local/lib/python2.5/site-packages/sage/interfaces/expect.pyc
 in _coerce_from_special_method(self, x)
   1048             s = '_gp_'
   1049         try:
 - 1050             return (x.__getattribute__(s))(self)
   1051         except AttributeError:
   1052             return self(x._interface_init_())

 /home/adamwebb/local/sage/local/lib/python2.5/site-packages/sage/structure/sage_object.so
 in sage.structure.sage_object.SageObject._axiom_
 (sage/structure/sage_object.c:3875)()

 /home/adamwebb/local/sage/local/lib/python2.5/site-packages/sage/structure/sage_object.so
 in sage.structure.sage_object.SageObject._interface_
 (sage/structure/sage_object.c:2853)()

 /home/adamwebb/local/sage/local/lib/python2.5/site-packages/sage/interfaces/expect.pyc
 in __call__(self, x, name)
   1022
   1023         if isinstance(x, basestring):
 - 1024             return cls(self, x, name=name)
   1025         try:
   1026             return self._coerce_from_special_method(x)

 /home/adamwebb/local/sage/local/lib/python2.5/site-packages/sage/interfaces/expect.pyc
 in __init__(self, parent, value, is_name, name)
   1426             except (TypeError, KeyboardInterrupt, RuntimeError,
 ValueError), x:
   1427                 self._session_number = -1
 - 1428                 raise TypeError, x
   1429         self._session_number = parent._session_number
   1430

 TypeError: Unable to start axiom because the command 'axiom -nox
 -noclef' failed.

 From __main__.example_0

 sage: a = fricas(x+2); a
 ---
 TypeError                                 Traceback (most recent call last)

 /home/adamwebb/.sage/temp/haso220w/18889/_home_adamwebb__sage_init_sage_0.py
 in module()

 /home/adamwebb/local/sage/local/lib/python2.5/site-packages/sage/interfaces/expect.pyc
 in __call__(self, x, name)
   1024             return cls(self, x, name=name)
   1025         try:
 - 1026             return self._coerce_from_special_method(x)
   1027         except TypeError:
   1028             raise

 /home/adamwebb/local/sage/local/lib/python2.5/site-packages/sage/interfaces/expect.pyc
 in _coerce_from_special_method(self, x)
   1048             s = '_gp_'
   1049         try:
 - 1050             return (x.__getattribute__(s))(self)
   1051         except AttributeError:
   1052             return self(x._interface_init_())

 /home/adamwebb/local/sage/local/lib/python2.5/site-packages/sage/structure/sage_object.so
 in