Number Theory
====================

.. module:: sympy.ntheory.generate

Ntheory Class Reference
-----------------------
.. autoclass:: Sieve
   :members:

Ntheory Functions Reference
---------------------------

.. autofunction:: prime

.. autofunction:: primepi

.. autofunction:: nextprime

.. autofunction:: prevprime

.. autofunction:: primerange

.. autofunction:: randprime

.. autofunction:: primorial

.. autofunction:: cycle_length

.. module:: sympy.ntheory.factor_

.. autofunction:: smoothness

.. autofunction:: smoothness_p

.. autofunction:: trailing

.. autofunction:: multiplicity

.. autofunction:: perfect_power

.. autofunction:: pollard_rho

.. autofunction:: pollard_pm1

.. autofunction:: factorint

.. autofunction:: primefactors

.. autofunction:: divisors

.. autofunction:: divisor_count

.. autofunction:: totient

.. module:: sympy.ntheory.modular

.. autofunction:: symmetric_residue

.. autofunction:: crt

.. autofunction:: crt1

.. autofunction:: crt2

.. autofunction:: solve_congruence

.. module:: sympy.ntheory.multinomial

.. autofunction:: binomial_coefficients

.. autofunction:: binomial_coefficients_list

.. autofunction:: multinomial_coefficients

.. autofunction:: multinomial_coefficients_iterator

.. module:: sympy.ntheory.partitions_

.. autofunction:: npartitions

.. module:: sympy.ntheory.primetest

.. autofunction:: mr

.. autofunction:: isprime

.. module:: sympy.ntheory.residue_ntheory

.. autofunction:: n_order

.. autofunction:: is_primitive_root

.. autofunction:: is_quad_residue

.. autofunction:: legendre_symbol

.. autofunction:: jacobi_symbol
