把人分成小组的最大的满意 [英] Divide people into teams for most satisfaction

查看:135
本文介绍了把人分成小组的最大的满意的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

只是一个好奇的问题。还记得在课堂groupwork当教授会分裂人成一定数量的群体( N )?

我的一些教授将采取的列表 N 人一个人想与和 N 人1没有按工作'T想从每个学生的作业,然后神奇地变成组 N ,学生应该是匹配的人,他们preFER,避免与人合作,他们不要preFER。

要我这个算法听起来很像一个背包问题,但我想我会问周围约你的方式来这样的问题会。

修改:发现的一个ACM文章描述的东西完全一样,我的问题。阅读似曾相识第二段。

解决方案

要我来说,它听起来更像是某种集团问题。

我看问题的方法,我会设置以下图表

  • 在顶点将是学生
  • 两名学生将通过边缘连接,如果这两种以下的事情抱:
    1. 在至少一个两学生想要与另一个工作。
    2. 无两个学生不希望与另一个工作。

有那么划分图分成大小为n派系的问题。 (假设学生的数量是被n整除)

如果这是不可能的,我可能让上边缘滑的第一个约束,并且有两个人,只要他们都没有明确地说,他们不希望与另一个工作。之间的边

作为一种方法,有效地解决这个问题,我不知道,但是这应该有希望让你更接近一些深入的问题。

Just a curiosity question. Remember when in class groupwork the professor would divide people up into groups of a certain number (n)?

Some of my professors would take a list of n people one wants to work with and n people one doesn't want to work with from each student, and then magically turn out groups of n where students would be matched up with people they prefer and avoid working with people they don't prefer.

To me this algorithm sounds a lot like a Knapsack problem, but I thought I would ask around about what your approach to this sort of problem would be.

EDIT: Found an ACM article describing something exactly like my question. Read the second paragraph for deja vu.

解决方案

To me it sounds more like some sort of clique problem.

The way I see the problem, I'd set up the following graph:

  • Vertices would be the students
  • Two students would be connected by an edge if both of these following things hold:

    1. At least one of the two students wants to work with the other one.
    2. None of the two students doesn't want to work with the other one.

It is then a matter of partitioning the graph into cliques of size n. (Assuming the number of students is divisible by n)

If this was not possible, I'd probably let the first constraint on the edges slip, and have edges between two people as long as neither of them explicitly says that they don't want to work with the other one.

As for an approach to solving this efficiently, I have no idea, but this should hopefully get you closer to some insight into the problem.

这篇关于把人分成小组的最大的满意的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆