Function: nextprime
Section: number_theoretical
C-Name: gnextprime
Prototype: G
Help: nextprime(x): smallest pseudoprime >= x.
Description:
 (int):int        nextprime($1)
 (gen):gen        gnextprime($1)
Doc: finds the smallest pseudoprime (see
 \tet{ispseudoprime}) greater than or equal to $x$. $x$ can be of any real
 type. Note that if $x$ is a pseudoprime, this function returns $x$ and not
 the smallest pseudoprime strictly larger than $x$. To rigorously prove that
 the result is prime, use \kbd{isprime}.
 The function accepts vector/matrices arguments, and is then applied
 componentwise.
Variant: For a scalar $x$,
 \fun{long}{nextprime}{GEN n} is also available.
