Concept

Raster — where it appears

A grid of sampled values, each of which is a place with a size rather than a point, and which cannot be reprojected without inventing values. Reprojecting one invents values, because the output cells do not sit on the input cells and something has to be read between them.

Named by 7 essays across 2 fields — each of them below, with the objects they name alongside it.

A raster warped to Lambert azimuthal equal-area and back, nearest against bilinear. The left panel is the field the raster carries — a smooth analytic function, so that the error of an interpolation is the interpolation's error and not a photograph's history. The other panels are what is left after warping into Lambert azimuthal equal-area and back to Equirectangular, shown as the difference from the original at six times the contrast. Nothing moved: the coordinates go through the maps exactly. What is lost is that a target pixel's centre does not fall on a source pixel's centre, so a value has to be invented for it. Bilinear is closer to the field — RMS 0.0022 against 0.0212 — and has given up 0.63 per cent of its variance to get there. The panels are drawn at 48 by 32 cells; the measurement is made at the same resolution.

Reprojecting a raster invents values

Moving a picture from one projection to another moves no coordinate — the maps are exact both ways. What is lost is that a target cell's centre does not land on a source cell's centre, so a value has to be made up for it, and the making-up has an order of convergence: 1.00 for nearest, 1.98 for bilinear, 2.93 for a cubic, measured by refining the grid.

applied · Dataset
The same kernels, across an edge. Each kernel measured over the same five rasters as the smooth measurement, on a field that carries a step across a tilted line instead of a smooth function. The solid lines are the edge and the faint ones the smooth field. The orders on the smooth field are nearest 1.00, bilinear 1.98, cubic 2.93; across the edge they are nearest 0.78, bilinear 0.58, cubic 0.60 — within a factor of 1.33 of one another, and the fastest of them belongs to nearest-neighbour, which does no interpolating at all. The ranking a smooth field establishes does not survive a discontinuity, and a real raster is mostly edges.

An edge has no order of convergence

On a smooth field the three resampling kernels converge at orders 1, 2 and 3 and the choice is obvious. Across a discontinuity they converge at 0.78, 0.58 and 0.60 — within a factor of 1.4 of each other, in an order that puts nearest-neighbour first, and a real raster is mostly edges.

applied · Dataset
The convergence order across an edge, against the edge's own orientation. Each curve is one kernel, fitted the same way as every other convergence order on this site: the root-mean-square error against the grid spacing, in logs, over five refinements. At 27° they read 0.78, 0.58, 0.60, which is the measurement already published here — and 27° is one point. Turn the edge onto a parallel and the curves collapse, and the nearest-neighbour one goes negative, which is the fit's way of saying the error is not falling at all. A single number for "the order across an edge" is a number about the edge that was measured.

One edge is not an edge

The three resampling kernels were measured across a discontinuity and came out at 0.78, 0.58 and 0.60 — one straight edge at 27° to the graticule. Across thirteen edges the same kernels span 0.19 to 0.87, the ranking between them reverses, and for an edge lying along a parallel the error does not fall with refinement at all.

applied · Dataset
Give the edge a width and the kernels get their orders back. Every edge this collection has resampled across has been exactly discontinuous, which is not what a sensor produces: a footprint, an atmosphere and a lens all smooth a boundary over a cell or two before anything is resampled. Convolving the edge with a Gaussian of stated width and refitting gives 1.23, 1.97 and 3.60 at one degree of blur, against 0.78, 0.58 and 0.60 with no blur at all. The blur is held fixed in degrees while the grid refines, which is what happens to a real sensor's data as its resolution improves.

A real edge has a width

Thirteen edges were measured and every one of them was exactly discontinuous, which no sensor has ever produced. Convolving them with a point-spread function of one degree — a cell or two — takes the three kernels from 0.78, 0.58 and 0.60 back to 1.23, 1.97 and 3.60, and takes the edge along a parallel, which converged at −1.49, up to 1.92 for bilinear and 3.73 for cubic.

applied · Dataset
A legend saying "illuminated from 315°" is true at one longitude. A hillshade's azimuth is measured from the top of the sheet, because the shading is computed on the projected raster. The top of the sheet is grid north, so the compass bearing the light comes from is the declared azimuth plus the meridian convergence, and that varies across the sheet. On a conic it swings by 55.3 degrees over eighty degrees of longitude. On a cylindrical projection in its normal aspect it does not swing at all, which is the flat line — the only case the legend is right everywhere.

The light comes from a page direction

A hillshade's illumination azimuth is declared from the top of the sheet, and the top of the sheet is grid north. On a conic the light therefore swings 52.6° across eighty degrees of longitude, and 72.8 per cent of the sheet is shaded differently from what the legend claims.

distortion · Gradient
Conformality helps and does not save it. The proportion of a stated terrain whose plan curvature changes sign when it is read off a grid in each projection. A conformal map turns every direction through the same angle, so the contour and the slope line stay perpendicular and the sign ought to survive — and it mostly does, at 0.30 per cent against 13.3. It is not zero, and the term that flips it is the gradient of the scale factor: the curvature of a curve under a conformal map is (κ − ∂ₙ log λ)/λ, and Mercator's λ has a gradient.

The curvature of a field is not the curvature of its picture

Whether a place is a spur or a hollow is the sign of a second derivative, and every automatic terrain classification is built on it. Read off an equal-area grid, that sign is wrong on 13.25 per cent of a sheet — and conformality reduces it to 0.30 per cent without removing it.

distortion · Gradient
One map, two samples, two answers. The same Miller cylindrical projection carrying two sets of sample points of the same size. On the left the points are uniform over the SPHERE — equal ground area between them, which is what every mean in this collection integrates against. On the right they are uniform over the PAGE, which is what a raster, a pixel loop or any figure that walks its own canvas produces. The right-hand set crowds where the map stretches, and the mean angular deformation it returns is 18.0° against the left-hand set's 7.2°.

The sample was drawn on the page

Every mean in this collection integrates over the sphere, because that is where the ground is. A raster, a pixel loop and any figure that walks its own canvas integrate over the page instead, and the difference is exactly the covariance between the quantity being measured and the map's own area distortion — 7.2° of mean angular deformation on Miller becoming 18.0°.

distortion · Sampling

Named alongside it

The objects these essays reach for when they reach for this one.

ResamplingConvergence orderDiscontinuityToleranceWarpAliasingInterpolationInterpolation kernelOrientationPage frameQuantisationRefinement

All concepts