o
    ¦ƒðjò	  ã                   @   s\   d dl mZ d dlmZ G dd„ deƒZG dd„ deƒZG dd„ deƒZG d	d
„ d
eƒZdS )é    )Ú	Predicate)Ú
Dispatcherc                   @   ó    e Zd ZdZdZeddd�ZdS )ÚPrimePredicateaÇ  
    Prime number predicate.

    Explanation
    ===========

    ``ask(Q.prime(x))`` is true iff ``x`` is a natural number greater
    than 1 that has no positive divisors other than ``1`` and the
    number itself.

    Examples
    ========

    >>> from sympy import Q, ask
    >>> ask(Q.prime(0))
    False
    >>> ask(Q.prime(1))
    False
    >>> ask(Q.prime(2))
    True
    >>> ask(Q.prime(20))
    False
    >>> ask(Q.prime(-3))
    False

    ÚprimeÚPrimeHandlerzÙ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.©ÚdocN©Ú__name__Ú
__module__Ú__qualname__Ú__doc__Únamer   Úhandler© r   r   ú¦/tmp/claude-1000/-var-www-html-academy/3f42efd1-c2b7-4d08-9b05-30d86bb35479/scratchpad/piper/venv/lib/python3.10/site-packages/sympy/assumptions/predicates/ntheory.pyr      s    
þr   c                   @   r   )ÚCompositePredicatea³  
    Composite number predicate.

    Explanation
    ===========

    ``ask(Q.composite(x))`` is true iff ``x`` is a positive integer and has
    at least one positive divisor other than ``1`` and the number itself.

    Examples
    ========

    >>> from sympy import Q, ask
    >>> ask(Q.composite(0))
    False
    >>> ask(Q.composite(1))
    False
    >>> ask(Q.composite(2))
    False
    >>> ask(Q.composite(20))
    True

    Ú	compositeÚCompositeHandlerzHandler for key 'composite'.r   Nr
   r   r   r   r   r   *   ó    r   c                   @   r   )ÚEvenPredicateaY  
    Even number predicate.

    Explanation
    ===========

    ``ask(Q.even(x))`` is true iff ``x`` belongs to the set of even
    integers.

    Examples
    ========

    >>> from sympy import Q, ask, pi
    >>> ask(Q.even(0))
    True
    >>> ask(Q.even(2))
    True
    >>> ask(Q.even(3))
    False
    >>> ask(Q.even(pi))
    False

    ÚevenÚEvenHandlerzHandler for key 'even'.r   Nr
   r   r   r   r   r   F   r   r   c                   @   r   )ÚOddPredicateaN  
    Odd number predicate.

    Explanation
    ===========

    ``ask(Q.odd(x))`` is true iff ``x`` belongs to the set of odd numbers.

    Examples
    ========

    >>> from sympy import Q, ask, pi
    >>> ask(Q.odd(0))
    False
    >>> ask(Q.odd(2))
    False
    >>> ask(Q.odd(3))
    True
    >>> ask(Q.odd(pi))
    False

    ÚoddÚ
OddHandlerzHHandler for key 'odd'. Test that an expression represents an odd number.r   Nr
   r   r   r   r   r   b   s    
þr   N)Úsympy.assumptionsr   Úsympy.multipledispatchr   r   r   r   r   r   r   r   r   Ú<module>   s    %