GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Main page
  • Contents
  • Current events
  • Random article
  • About Wikipedia
  • Contact us
  • Help
  • Learn to edit
  • Community portal
  • Recent changes
  • Upload file
  • Special pages
  • Search
  • Donate

This view

  • Original page
  • New address

GeezerVison is showing en.wikipedia.org — Nearest-neighbor interpolation - Wikipedia

Nearest neighbor interpolation (blue lines) in one dimension on a (uniform) dataset (red points)
Nearest neighbor interpolation on a uniform 2D grid (black points). Each colored cell indicates the area in which all the points have the black point in the cell as their nearest black point.

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 dimensions.

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.[1] The algorithm is very simple to implement and is commonly used (usually along with mipmapping) in real-time 3D rendering[2] to select color values for a 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 neighbor interpolation, by assigning the function value at the given point to all the points inside the cell.[3] The figures on the right side show by color the shape of the cells.

Comparison of Nearest-neighbor interpolation with some 1- and 2-dimensional interpolations.
Black and red/yellow/green/blue dots correspond to the interpolated point and neighbouring samples, respectively.
Their heights above the ground correspond to their values.
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

  1. ↑ Thévenaz, Philippe; Blu, Philippe; Unser, Philippe (2000). "Image Interpolation and Resampling". Handbook of Medical Imaging. Academic Press. p. 405. doi:10.1016/b978-012077790-7/50030-8. ISBN 978-0-12-077790-7.
  2. ↑ Pfister, HANSPETER (2005). "Hardware-Accelerated Volume Rendering". In Charles D. Hansen and Chris R. Johnson (ed.). The Visualization Handbook. Elsevier. p. 233. doi:10.1016/b978-012387582-2/50013-7. ISBN 978-0-12-387582-2.
  3. ↑ Hartmann, K.; Krois, J.; Rudolph, A. (2023). "Statistics and Geodata Analysis using R (SOGA-R)". Department of Earth Sciences, Freie Universität Berlin. Retrieved 2024-11-14.
Stub icon

This applied mathematics–related article is a stub. You can help Wikipedia by adding missing information.

  • v
  • t
  • e
Retrieved from "https://en.wikipedia.org/w/index.php?title=Nearest-neighbor_interpolation&oldid=1279884208"
Categories:
  • Interpolation
  • Multivariate interpolation
  • Texture filtering
  • Applied mathematics stubs
Hidden categories:
  • Articles with short description
  • Short description is different from Wikidata
  • All stub articles
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.