Changes

Jump to navigation Jump to search
Added some words on fit function.
Line 32: Line 32:  
Instead of adding all the cities, we could fit a line to the data of a few city points. The cumulative distance of the fit at a population ratio of 1, is then again the value we are looking for.
 
Instead of adding all the cities, we could fit a line to the data of a few city points. The cumulative distance of the fit at a population ratio of 1, is then again the value we are looking for.
   −
The function to fit must behave nicely with extrapolations. This excludes complex functions with many parameters. A simple linear of logarithmic function should be sufficient. A logarithmic function is preferred, as you expect that as smaller cities are added, the contribution to the distance is also smaller (not sure this logic is correct).
+
The function to fit must behave nicely with extrapolations. This excludes complex functions with many parameters. Or functions which behave not regular outside the fitted points (polynomials).
 +
 
 +
This leaves the following functions:
 +
* linear - results in average values;
 +
* logarithmic - results in smaller values;
 +
* power functions - results in larger values;
    
In the graph for Maroc a logarithmic function is used. The largest cities are not used in the fit calculation, as these ones seem not to follow the curve. They would bias the fit to much, when we use so few points. The fit will result in a transportation size of 419 km. Compare this to a maximum actual distance of about 1000 km.
 
In the graph for Maroc a logarithmic function is used. The largest cities are not used in the fit calculation, as these ones seem not to follow the curve. They would bias the fit to much, when we use so few points. The fit will result in a transportation size of 419 km. Compare this to a maximum actual distance of about 1000 km.
3,393

edits

Navigation menu