Also refine in not mentioned in simplify:
/sympy/simplify$ grep -r refine *

But on the other hand assumptions are mentioned in docstrings but they do
not refer actually to the assumption module:
  55        This function will also work fine with assumptions:
  56
  57        >>> k = Symbol('k', negative=True)
  58        >>> fraction(x * y**k)
  59        (x, y**(-k))

What is the relation between those. Why both of them exists (assumption.py
and is_something flags)?

On 7 December 2011 20:36, [email protected] <
[email protected]> wrote:

> How should assumptions be used? More precisely why the following code does
> what it does
>
> In [18]: global_assumptions.clear()
>
> In [19]: x = Symbol('x', positive=True)
>
> In [20]: ask(Q.positive(x)) # Why does it return None?
>
> In [21]: x > 0
> Out[21]: True
>
> In [22]: global_assumptions # It's empty but I already declared x as
> positive
> Out[22]: AssumptionsContext()
>
> In [23]: ask(Q.positive(x))
>
> In [24]: global_assumptions.add(Q.positive(x))
>
> In [25]: ask(Q.positive(x))
> Out[25]: True
>
> Why setting a symbol to positive does not create a global assumption? What
> are assumption used for actually when there are all the is_something flags?
>

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

Reply via email to