I need an algorithm to find the optimally best (or at least a reasonably good) way to form 450 pairs.
I have 450 elements of class A, and 450 elements of class B. For each (a,b) pair I can calculate a fitness index . Every element must be paired to a different and vice versa. Brute-forcing this is unfeasible, because there are ways of pairing this shit up.
After calculating the fitness for every (a,b) pair I end up with a square matrix with 202500 pairings. This is easy to compute. Pairing the best fits first is not good, because the last ones are shit. Pairing the hardest-to-pair ones (the ones with the lowest best fit) first is slightly better in the long run, but last pairs are also shit. I also was able to reduce the problem to doing five 90A-90B pairings by sorting all elements using another fitness function, which significantly improved the results. If I could optimize these sub-pairings, that would be awesome, but checking possible pairing is still unreasonable.
What should I do? Is it feasible to solve this as an optimization problem, and if so, how would one do that?
I have 450 elements of class A, and 450 elements of class B. For each (a,b) pair I can calculate a fitness index . Every element must be paired to a different and vice versa. Brute-forcing this is unfeasible, because there are ways of pairing this shit up.
After calculating the fitness for every (a,b) pair I end up with a square matrix with 202500 pairings. This is easy to compute. Pairing the best fits first is not good, because the last ones are shit. Pairing the hardest-to-pair ones (the ones with the lowest best fit) first is slightly better in the long run, but last pairs are also shit. I also was able to reduce the problem to doing five 90A-90B pairings by sorting all elements using another fitness function, which significantly improved the results. If I could optimize these sub-pairings, that would be awesome, but checking possible pairing is still unreasonable.
What should I do? Is it feasible to solve this as an optimization problem, and if so, how would one do that?
