Actually, ex.is_real() queries the assumptions() data base, not the
GiNaC/Pynac info flags. Example:
var('test', domain='real')
print test.is_real()
forget()
print test.is_real()
Returns:
True
False
I think your proposal below would be great. Remove assume() from
variable creation, but get the information from Pynac and convert to
assumptions when calling maxima.
On 06/15/2017 08:17 AM, Ralf Stephan wrote:
The "more persistent domains() database" exists already in part as
GiNaC/Pynac info flags that are set in parallel to Maxima's
assumptions. They can be queried with ex.is_real() etc...What is not
saved in Pynac are less elementary assumptions like x>1, y+z==pi. Now
instead of caching all assumptions in a database (either Python or
C++) and sending to Maxima on demand in bulk, another possibility
could be, as you say, to just remove the assume calls on variable
creation because they are all elementary assumptions. Then when Maxima
needs them for integration, solving etc take the information from
Pynac and do assumes for just those variables that are needed. Am I
missing something?
On Wednesday, June 14, 2017 at 6:14:39 PM UTC+2, Stan wrote:
As mentioned in https://trac.sagemath.org/ticket/23138
<https://trac.sagemath.org/ticket/23138>, the assume() command
takes a lot of time, which is very annoying when defining a lot of
variables using var() including a domain information. var('x',
domain='real') passes the domain information to ginac and adds it
as an assumption to assumptions(), so that it can be considered by
maxima. However, since assumptions() can both store much more
information than just the domain information, and on the other
hand all the information is lost when someone executes forget(), I
am wondering if this code should not be removed from
src/sage/symbolic/ring.pyx, Lines 1017-1027, in favour of a more
persistent domains() database, which could be injected into
assumptions() by the user if needed. Any thoughts on this?
Cheers
Stan
--
You received this message because you are subscribed to a topic in the
Google Groups "sage-devel" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/sage-devel/-A8ZzSKvYsA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
sage-devel+unsubscr...@googlegroups.com
<mailto:sage-devel+unsubscr...@googlegroups.com>.
To post to this group, send email to sage-devel@googlegroups.com
<mailto:sage-devel@googlegroups.com>.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.
--
________________________________________
Stan Schymanski
Riedstrasse 60
8604 Volketswil
Schweiz
Ph: +41 (0)43 5420487
_________________________________________
--
You received this message because you are subscribed to the Google Groups
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.