I wrote some code, which works. It takes the upstream sync rates of all the modems, picks the slowest and sets an exceptional modem loading factor on that one, and a different modem loading factor on the others. It now calculated what that for-the-slowest exceptional modem loading factor is (k_min). The value calculated depends on how close the slowest sync rate is to the rest, how bunched up or spread apart the sync rates are. The further the min is away from the rest, the lower the calculated k_min value is.
The function I have used to determine k_min, the modem loading factor of the slowest line, is a linear function y= max( min_clamp, min( max_clamp, y2+m * x )) where x is the size of the gap between the min sync speed rate and the mean of the other speed rates and y2, m, min_clamp and max_clamp are constants. All the sync values used in the calculation are pre-scaled to max=1.0 because the values don’t matter only the ‘closeness’ of the bunching.
I have some problems with this though. I don’t know what ‘far away enough from the rest’ means, the fuzzy boundary between close and not close. At some separation, I want to pick that as ‘well separated’ and set the function up so that at some particular x, y=k_min( x ) = y1 where y1 is some constant set by experience and scenario testing.
I have had line 3 down to 250kbps but at least it’s managing at 419 Kbps now while the rest are 525, 499, 499 kbps so that shows the separation. The min is ‘x’ away from the rest there and I rescale the sync rates so that sync rate=525 maps to a max x=1.0. Now the modem loading factor that they all use apart from the slowest is 0.95 and the slowest should be y = k_min = 0.7 in the setup that I have tested. If the slowest line gets better then that 0.7 is allowed to rise to become closer to 0.95. However how fast? and what happens if it gets even worse? Clamping of the allowed output value keeps it under control so it cannot go further below 0.7 which is only sensible.
I don’t take any account of the other values’ distribution in detail - if there is a second sync rate that is only just a small amount above the minimum, then that information is not used. Worst of all, if several values are equal to the min, then I don’t handle that case properly. I have no idea what to do any way. Set them all to the same value ? Split the total, so that say if there were two minimum equal values then set the y = 0.95 - (0.95 - 0.7) / n_min where n_min = 2?