Content deleted Content added
replace 2D example with SVG version |
Citation bot (talk | contribs) Added isbn. | Use this bot. Report bugs. | Suggested by Dominic3203 | Category:Interpolation | #UCB_Category 27/59 |
||
(21 intermediate revisions by 12 users not shown) | |||
Line 1:
{{short description|Method of multivariate interpolation}}
[[Image:Piecewise_constant.svg|right|thumb|Nearest neighbor interpolation (blue lines) in one dimension on a (uniform) dataset (red points)
[[Image:
'''Nearest-neighbor interpolation''' (also known as '''proximal interpolation''' or, in some contexts, '''point sampling''') is a simple method of [[multivariate interpolation]] in one or more [[dimension]]s.
[[Interpolation]] is the problem of approximating the value of a function for a non-given point in some space when given the value of that function in points around (neighboring) that point. The nearest neighbor algorithm selects the value of the nearest point and does not consider the values of neighboring points at all, yielding a piecewise-constant interpolant.<ref>{{cite book |last1=Thévenaz |first1=Philippe |last2=Blu |first2=Philippe |last3=Unser |first3=Philippe |year=2000 |chapter=Image Interpolation and Resampling |title=Handbook of Medical Imaging |page=405 |publisher=Academic Press |doi=10.1016/b978-012077790-7/50030-8|isbn=978-0-12-077790-7 }}</ref> The algorithm is very simple to implement and is commonly used (usually along with [[mipmap|mipmapping]]) in [[Real-time computing|real-time]] [[3D rendering]]<ref>{{cite book |last=Pfister |first=HANSPETER |year=2005 |chapter=Hardware-Accelerated Volume Rendering |editor=Charles D. Hansen and Chris R. Johnson |title=The Visualization Handbook |page=233 |publisher=Elsevier |doi=10.1016/b978-012387582-2/50013-7|isbn=978-0-12-387582-2 }}</ref> to select color values for a [[texture filtering|textured]] surface.
==Connection to Voronoi diagram==
For a given set of points in space, a [[Voronoi diagram]] is a decomposition of space into cells, one for each given point, so that anywhere in space, the closest given point is inside the cell. This is equivalent to nearest
{{comparison_of_1D_and_2D_interpolation.svg|left}}
[[Image:Coloured_Voronoi_2D.svg|none|thumb|This [[Voronoi diagram]] is an example of nearest neighbor interpolation of a random set of points (black dots) in 2D.]]
{{-}}
==See also==
* [[Interpolation]]
* [[Natural neighbor interpolation]]
* [[Image scaling]]
* [[Nearest neighbor search]]
* [[Nearest neighbor smoothing]]
* [[Zero-order hold]]
* [[Rounding]]
==References==
{{Reflist}}
[[Category:Interpolation]]
|