found this while writing a patch with WP bug 10021:
Basically, the key optimization was that:
is tremendously slower than:
$('foo').sortable().sortable('option', 'connectWith', 'bar');
and by this, I'm really meaning slower by inordinate amounts of time. Like... by a factor of 5 in my case, with 15 placeholders.
I haven't looked into your code's specific, but I would assume you're running an O(n!) algorithm in there instead of an O(n).
The connectWidth option, when applied to an array of objects, should be ignored, and applied at the very end, once all of the array elements are instantiated. Else, it recursively jQueries the document for the needed elements, and does the same job n! times on the first element.
I'm pretty certain you've similar optimizations to do over in draggable and droppable, and possibly other areas.