numtheory(deprecated)/nearestp - Maple Help

numtheory(deprecated)

 nearestp
 the nearby lattice point problem

 Calling Sequence nearestp(B, alpha)

Parameters

 B - list of lists of real numbers (the basis of the lattice) alpha - list of real numbers (a given point)

Description

 • Important: The numtheory package has been deprecated.  Use the superseding command NumberTheory[NearestLatticePoint] instead.
 • In the lattice given by the basis B, the nearestp command returns a vector w that is near the vector alpha. The vector w will be a nearest vector to alpha in the lattice in the following sense:
 There is a constant K depending only on n, the dimension of the lattice, such that for every other vector u in the lattice given by B,

 |w - alpha| <= C_n |u - alpha|.

 • The output of the nearestp command is of the form:

$C=[{c}_{1},\mathrm{...},{c}_{n}].$

 which is a list of integers such that

$w={c}_{1}{b}_{1}+\mathrm{...}+{c}_{n}{b}_{n}.$

 • The command with(numtheory,nearestp) allows the use of the abbreviated form of this command.

Examples

Important: The numtheory package has been deprecated.  Use the superseding command NumberTheory[NearestLatticePoint] instead.

 > $\mathrm{with}\left(\mathrm{numtheory}\right):$
 > $B≔\left[\left[{2}^{\frac{1}{3}},0,0\right],\left[{ⅇ}^{2},1,0\right],\left[0,\mathrm{Pi}\cdot 100,1\right]\right]$
 ${B}{≔}\left[\left[{{2}}^{{1}}{{3}}}{,}{0}{,}{0}\right]{,}\left[{{ⅇ}}^{{2}}{,}{1}{,}{0}\right]{,}\left[{0}{,}{100}{}{\mathrm{\pi }}{,}{1}\right]\right]$ (1)
 > $\mathrm{alp}≔\left[7.01,8.01,\mathrm{gamma}\right]$
 ${\mathrm{alp}}{≔}\left[{7.01}{,}{8.01}{,}{\mathrm{\gamma }}\right]$ (2)
 > $\mathrm{nearestp}\left(B,\mathrm{alp}\right)$
 $\left[{-36}{,}{7}{,}{0}\right]$ (3)
 > $b≔\left[\left[-\frac{127230625}{746351104},1,0\right],\left[\frac{90325}{71691},0,0\right],\left[-\frac{726529225}{1119526656},\frac{477}{2995},1\right]\right]$
 ${b}{≔}\left[\left[{-}\frac{{127230625}}{{746351104}}{,}{1}{,}{0}\right]{,}\left[\frac{{90325}}{{71691}}{,}{0}{,}{0}\right]{,}\left[{-}\frac{{726529225}}{{1119526656}}{,}\frac{{477}}{{2995}}{,}{1}\right]\right]$ (4)
 > $\mathrm{blp}≔\left[71.01,18.01,{\mathrm{Pi}}^{4}\right]$
 ${\mathrm{blp}}{≔}\left[{71.01}{,}{18.01}{,}{{\mathrm{\pi }}}^{{4}}\right]$ (5)
 > $\mathrm{nearestp}\left(b,\mathrm{blp}\right)$
 $\left[{2}{,}{107}{,}{97}\right]$ (6)