I notice that people are testing IM with the Lanczos filter for enlargement. If no filter is specified, IM will use the Mitchell filter for enlargement (perhaps for a good reason).
To understand IM’s behaviour when resizing a pair of white-black pixels, I suggest you use HDRI and observe the pixel values. For example (Windows CMD syntax):
f:\web\im>%IMG7%magick xc:White xc:Black +append -resize "16x1^!" txt:
# ImageMagick pixel enumeration: 16,1,65535,srgb
0,0: (69721.6,69721.6,69721.6) #FFFFFFFFFFFF srgb(106.388%,106.388%,106.388%)
1,0: (68462.7,68462.7,68462.7) #FFFFFFFFFFFF srgb(104.467%,104.467%,104.467%)
2,0: (66456.8,66456.8,66456.8) #FFFFFFFFFFFF srgb(101.407%,101.407%,101.407%)
3,0: (63554.5,63554.5,63554.5) #F842F842F842 srgb(96.9779%,96.9779%,96.9779%)
4,0: (59317.6,59317.6,59317.6) #E7B6E7B6E7B6 srgb(90.5129%,90.5129%,90.5129%)
5,0: (53055.6,53055.6,53055.6) #CF40CF40CF40 srgb(80.9576%,80.9576%,80.9576%)
6,0: (45430.5,45430.5,45430.5) #B177B177B177 srgb(69.3225%,69.3225%,69.3225%)
7,0: (37066.6,37066.6,37066.6) #90CB90CB90CB srgb(56.56%,56.56%,56.56%)
8,0: (28468.4,28468.4,28468.4) #6F346F346F34 srgb(43.44%,43.44%,43.44%)
9,0: (20104.5,20104.5,20104.5) #4E884E884E88 srgb(30.6775%,30.6775%,30.6775%)
10,0: (12479.4,12479.4,12479.4) #30BF30BF30BF srgb(19.0424%,19.0424%,19.0424%)
11,0: (6217.39,6217.39,6217.39) #184918491849 srgb(9.48713%,9.48713%,9.48713%)
12,0: (1980.54,1980.54,1980.54) #07BD07BD07BD srgb(3.02212%,3.02212%,3.02212%)
13,0: (-921.814,-921.814,-921.814) #000000000000 srgb(-1.4066%,-1.4066%,-1.4066%)
14,0: (-2927.69,-2927.69,-2927.69) #000000000000 srgb(-4.46737%,-4.46737%,-4.46737%)
15,0: (-4186.58,-4186.58,-4186.58) #000000000000 srgb(-6.38832%,-6.38832%,-6.38832%)
Notice that the percentage values range from -6% to +106%. We have ringing. “-filter Lanczos” gives worse ringing. “-filter cubic” gives no ringing.