>
> >   The example may sound contrived, but it does arise in practice, and was
> a
> > headache to debug.
> >
>
> Well there must be an end to it, right? Every assumption is about
> symbols. Every symbol x that depends in any way on another symbol y
> has y in its free_symbols. In fact any exrpession has all symbols it
> depends on (recursively) in its free_symbols. Hence it would be enough
> to pull all assumptions involving any free symbols into the hash
> computation.
>
> Right? [If not then one point in the above chain of argument must be
> wrong; this is very well possible :-)]


  x may not depend on y if the right assumptions exist on y, and x is
simplified. What you're suggesting may work if the hash is computed before
the simplification occurs, but then you're bringing information about the
equation into the hash before the equation is dealt with (and as Aaron
points out, this could have some performance issues).

  But back to my original suggestion -- can anyone see something wrong with
flushing the cache after a sympy command is invoked? The reason this has
potential for solving the problem is because the assumptions aren't apt to
changing while sympy is computing a result (only in between commands). This
means the gruntz can still do its thing with the cache, etc.

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To post to this group, send email to sympy@googlegroups.com.
To unsubscribe from this group, send email to 
sympy+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sympy?hl=en.

Reply via email to