N理论

与数论相关的键的处理程序:素数、偶数、奇数等。

class sympy.assumptions.handlers.ntheory.AskOddHandler[源代码]

Handler for key 'odd'. Test that an expression represents an odd number.

class sympy.assumptions.handlers.ntheory.AskPrimeHandler[源代码]

Handler for key 'prime'.

解释

Test that an expression represents a prime number. When the expression is an exact number, the result (when True) is subject to the limitations of isprime() which is used to return the result.

static Pow(expr, assumptions)[源代码]

整数**整数->!质数