Шаблон:Convert/L100km
Testcases of L100km vs L/100 km | |
---|---|
L100km (this subtemplate) | L/100km (the standard subtemplate) |
0,78 L/100 km (0 mpg-imp; 0 mpg-US) | 0.78 L/100 км (360 mpg‑imp; 300 mpg‑US) |
1 L/100 km (0 mpg-imp; 0 mpg-US) | 1 L/100 км (280 mpg‑imp; 240 mpg‑US) |
3 L/100 km (0 mpg-imp; 0 mpg-US) | 3 L/100 км (94 mpg‑imp; 78 mpg‑US) |
7,8 L/100 km (0 mpg-imp; 0 mpg-US) | 7.8 L/100 км (36 mpg‑imp; 30 mpg‑US) |
10 L/100 km (0 mpg-imp; 0 mpg-US) | 10 L/100 км (28 mpg‑imp; 24 mpg‑US) |
30 L/100 km (0 mpg-imp; 0 mpg-US) | 30 L/100 км (9.4 mpg‑imp; 7.8 mpg‑US) |
78 L/100 km (0 mpg-imp; 0 mpg-US) | 78 L/100 км (3.6 mpg‑imp; 3.0 mpg‑US) |
100 L/100 km (0 mpg-imp; 0 mpg-US) | 100 L/100 км (2.8 mpg‑imp; 2.4 mpg‑US) |
0.0000521 mpg-imp (0 L/100 km) | 0.0000521 mpg‑imp (5,420,000 L/100 км) |
0.000521 mpg-imp (0 L/100 km) | 0.000521 mpg‑imp (542,000 L/100 км) |
0.00521 mpg-imp (0 L/100 km) | 0.00521 mpg‑imp (54,200 L/100 км) |
0.0521 mpg-imp (0 L/100 km) | 0.0521 mpg‑imp (5,420 L/100 км) |
0.521 mpg-imp (0 L/100 km) | 0.521 mpg‑imp (542 L/100 км) |
1 mpg-imp (0 L/100 km) | 1 mpg‑imp (280 L/100 км) |
3 mpg-imp (0 L/100 km) | 3 mpg‑imp (94 L/100 км) |
5.21 mpg-imp (0 L/100 km) | 5.21 mpg‑imp (54.2 L/100 км) |
10 mpg-imp (0 L/100 km) | 10 mpg‑imp (28 L/100 км) |
30 mpg-imp (0 L/100 km) | 30 mpg‑imp (9.4 L/100 км) |
52.1 mpg-imp (0 L/100 km) | 52.1 mpg‑imp (5.42 L/100 км) |
100 mpg-imp (0 L/100 km) | 100 mpg‑imp (2.8 L/100 км) |
521 mpg-imp (0 L/100 km) | 521 mpg‑imp (0.542 L/100 км) |
0.00004338 mpg-US (0 L/100 km) | 0.00004338 mpg‑US (5,422,000 L/100 км) |
0.0004338 mpg-US (0 L/100 km) | 0.0004338 mpg‑US (542,200 L/100 км) |
0.004338 mpg-US (0 L/100 km) | 0.004338 mpg‑US (54,220 L/100 км) |
0.04338 mpg-US (0 L/100 km) | 0.04338 mpg‑US (5,422 L/100 км) |
0.4338 mpg-US (0 L/100 km) | 0.4338 mpg‑US (542.2 L/100 км) |
1 mpg-US (0 L/100 km) | 1 mpg‑US (240 L/100 км) |
3 mpg-US (0 L/100 km) | 3 mpg‑US (78 L/100 км) |
4.338 mpg-US (0 L/100 km) | 4.338 mpg‑US (54.22 L/100 км) |
10 mpg-US (0 L/100 km) | 10 mpg‑US (24 L/100 км) |
30 mpg-US (0 L/100 km) | 30 mpg‑US (7.8 L/100 км) |
43.38 mpg-US (0 L/100 km) | 43.38 mpg‑US (5.422 L/100 км) |
100 mpg-US (0 L/100 km) | 100 mpg‑US (2.4 L/100 км) |
433.8 mpg-US (0 L/100 km) | 433.8 mpg‑US (0.5422 L/100 км) |
Note how, according to this subtemplate, miles per gallon (whether imperial or US) are proportional to litres per hundred kilometres. This, of course, is not true. The standard subtemplate gives the correct conversion (rounded either two sig figs or to the same number as the input, whichever is greater). Thus it converts 7.8 L/100 km correctly to 36 mpg-imp or 30 mpg-US (this was the number chosen to work with) but fails for any number much greater or less. Similarly the conversions from 0.00521 mpg-imp or 0.004338 mpg-US to L/100 km are about right but choose much different numbers and it doesn't work.
The problem is that there is no inversion being carried out. Convert II (the Oct 2007 - present version) needs the {{{d}}}F
and the i=i
for these volume (of fuel) per distance to work. i=i
says invert but only works with F
display subtemplates.
Hence this template will be taken out of service. I'm moving it into the L/100 km sandbox for testing as a subtemplate to function with Convert III (a new version currently under construction).