On a different point, when approximating a "brickwall" frequency spectrum an 'equiripple' pattern is generally considered desirable, and this will lead to a different kernel than the Lanczos approach does.
I don't really claim that Lanczos interpolation as presented is the "best" 2D interpolation there is. It is definitely popular though, and I couldn't find a source explaining how it is derived, so I thought it'd be an interesting topic for a blog post.
The blog is a thing of beauty.
Cubic interpolation is not included in the showcase since it is a family of filters rather than a single filter — most cubic filters used in practice end up looking similar to Lánczos, although probably a bit less sharp but with less ringing.
It's interesting to compare Lánczos (and other) resampling algorithms in digital imaging with what's known as K-factor (aka K-rating)—a measurement in analog television for rating image quality. There are interesting similarities between the two.
An image is an image whether it's generated digitally or by analog means, so it's only to be expected that ways of measuring image quality between these two systems would have some things in common. That's done by comparing the output signal with the original image but it's not as straightforward as it seems as human perception and subjectivity get in the way.
As per article we've seen Lánczos, (sync, (sin x)/x) resampling quality is better than say nearest neighbour, Mitchell, triangle, etc. but the problem of human subjectivity remains as it's often difficult to compare image quality visually and or consistently. Analog television has long had methods of objectively evaluating images without the human factor and again the solution is mathematical, and as I'll show it has some interesting parallels with Lánczos resampling.
To determine image quality/K-factor of a television transmission system an electronic test signal replaces the subjective image and it's measured for distortion products after it exits the system. The mathematical parameters of this test signal are carefully defined to detect distortions and artifacts that are most noticeable to the human eye.
The test signal consists of a sine-squared pulse of specified duration followed by bar (a square wave with a transient response the same as the pulse). The K-factor is determined by measuring the deviation in the pulse and bar risetimes together with generated artifacts such as ringing and under and or overshoot. As the Pulse & Bar is a precision test signal input/output comparisons aren't necessary, thus a single measurement simplifies testing.
For those interested see BBC Monograph 58 'Sine-squared Pulse and Bar Testing in Colour Television'. 1965. PDF https://www.bbc.co.uk/rd/publications/bbc_monograph_58
Unfortunately, this ref. is behind a firewall: Macdiarmid, I.F. and Phillips, B. 'A Pulse & Bar Waveform Generator for Testing Television Links.' Proc I.E.E. Vol. 105, Part B, p.) 440. 1958.
Indeed. What a fascinating and delightful memoir of a life in science! (I am envious of his ability to extemporize so flawlessly, in English, no less, which he says he acquired quite deliberately only after 1931, at age 38.)
I had a Hungarian physicist friend who unfortunately is now deceased who I used to rib over the brilliance of these Hungarian scientists. I'd ask him "what's in the water over there, what magic potion were they on?" and he'd just shrug his shoulders and say something like "I think it's the education system".
I can't say I was fully satisfied with his answers (although as I've just learned from the video on his life, Lánczos himself adds support for Hungary's strong education system).
When one lists the many remarkable achievements of these exceptionally gifted individuals it really does seem they're aliens from another world: https://en.wikipedia.org/wiki/The_Martians_(scientists)
:-)