English 中文(简体)
寻找这一小时间安排问题的数学解决办法
原标题:Looking for a mathematical solution to this small scheduling problem

我们有一份有其能力的房间清单和一份有与会人数的会议清单。 我们希望每次会议都有一个房间:

  1. A meeting can only be scheduled in a room with capacity equal to or greater than its attendance.
  2. If surplus rooms are present, meetings should be scheduled so that the largest possible room is left unscheduled.
  3. A meeting with a larger attendance should not be scheduled in a smaller room than a meeting with a smaller attendance.
  4. Obviously we should find out if it is impossible to schedule the given meetings in the given rooms.

我们能否有效地达成时间表? 单张通行证是冰冰,有些后track是ok,但我可以选择的唯一选择(粗略算法加上动态震.违反第3条)比我所希望的要慢。

这个问题并不容易。 阴线法至少有一个标准:

  1. 我们可以把每个名单从高到低的开始,从最大的会议室到最大的会议,只要有可能,我们就会找到解决办法,但我们将拥有尽可能小的房间,而不是最大的房间。 (审议定于200、30和20人会议室举行的10和15人会议的情况)

  2. 我们可以将会议清单从高到低,然后缩小,努力找到最小的房间,这样就足以遏制本次会议。 但有时会增加一个会议室,安排举行小型会议。 (在40和80人房间安排40和30人会议)

但是,解决这一相对简单的问题肯定有更好的办法。

最佳回答

难道你可以把两个名单从低到高,然后把每次会议放在一间(即最小的)足够大的房间里?

只要我能看到符合你的所有标准:

  1. Check
  2. This should follow directly from the fact that we always chose the smallest room possible
  3. Since we ve sorted the meeting from low attendance to high attendance, we ll never put a larger meeting in a smaller room.
  4. If we reach the end of the room list before reaching the end of the meetings list, it wasn t possible to find a schedule.

Edit回应您的评论:

我们有两个通行证。 首先是以上。 其后,如有任何会议离开,则进行如下工作:

通过会议室清单和未排定的会议清单,从最高到最低。

如果本次会议在本会议室举行: 留在该会议室(将先前在该会议室开会的会议列入未排定的会议清单(以最低地位维持这种顺序)。) 前往下次会议和名单上的会议室。

如果本次会议不宜在本会议室举行: 本次会议不能安排。 将会议从名单上删除,并尝试下一次会议(在同一会议室)。

在未排定的会议清单空出之前的复函。

问题回答

暂无回答




相关问题
Ruby parser in Java

The project I m doing is written in Java and parsers source code files. (Java src up to now). Now I d like to enable parsing Ruby code as well. Therefore I am looking for a parser in Java that parses ...

rails collection_select vs. select

collection_select and select Rails helpers: Which one should I use? I can t see a difference in both ways. Both helpers take a collection and generates options tags inside a select tag. Is there a ...

RubyCAS-Client question: Rails

I ve installed RubyCAS-Client version 2.1.0 as a plugin within a rails app. It s working, but I d like to remove the ?ticket= in the url. Is this possible?

Ordering a hash to xml: Rails

I m building an xml document from a hash. The xml attributes need to be in order. How can this be accomplished? hash.to_xml

multiple ruby extension modules under one directory

Can sources for discrete ruby extension modules live in the same directory, controlled by the same extconf.rb script? Background: I ve a project with two extension modules, foo.so and bar.so which ...

Text Editor for Ruby-on-Rails

guys which text editor is good for Rubyonrails? i m using Windows and i was using E-Texteditor but its not free n its expired now can anyone plese tell me any free texteditor? n which one is best an ...

热门标签