I have a network I'm responsible for routing signals through. You can think of the network as a directed graph of nodes (hardware) but each edge is really a pipe capable of fitting a specific bandwidth, I can route signals to any index on that pipe and may have multiple signals of different 'size' going across the pipe. For what it's worth the signals are predetermined sizes and will not always be simple multiple of twos.
I know how to defragment a single 'pipe' easily enough. However, it's theoretically possible that I could have to move signals around across multiple pipes to create enough room to fit a new signal. In a trivial example I could have two edges from A to B with enough space to fit a signal of size '4' available, and a signal of size '8'. To fit the signal across I would have to move some signals from pipe 2 to 1 so that 1 is completely freed, living a full '8' slots available for my new signal to routed in.
How to detect and properly defragment these sort of cross-pipe issues?
Of course in the real world I may have to route signals through completely different devices, perhaps having signals take less-direct routes, to free up enough space for my new signal on any given pipe.
So in short across an entire system of these networks I want to
find a method to get a signal from input to destination in a crowded environment where I may have to move multiple signals to take a different path to their destination in order to free up sufficient space on a given pipe
figure out how to do the above with the minimum number of signals physically moved
have an approach that minimizes the need of running the above steps by minimizing fragmentation as much as possible.
This is a complicated series of requirements on their own, and I'm not looking for an answer on how to do it all, though such an answer is welcome.