人月神话沟通路径真的是n^2吗?

发布于 2024-07-30 05:44:57 字数 234 浏览 10 评论 0原文

是不是更接近于:

n * (n - 1) / 2

上面的公式是这个中学数学小组问题的答案:

“你在一个房间里有 n 个人,他们都与其他人握手了多少次?”

这是否也适用于软件项目中进行通信的人数?

免责声明

我还没有读过这本书,但我见过其他地方引用的n^2公式。

Wouldn't it be closer to:

n * (n - 1) / 2

The above formula is the answer to this middle school Math-team problem:

"You have n people in a room and they all shake hands with everyone else. How many handshakes took place?"

Wouldn't this also apply to the number of people communicating within a software project?

Disclaimer

I haven't read the book (yet), but I've seen the n^2 formula referenced elsewhere.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(6

友欢 2024-08-06 05:44:58

你是对的。 然而,虽然我自己没有读过这本书,但听起来他们试图给出一个增长顺序,而不是一个确切的数字。 n * (n-1) / 2 是一个以 O(n^2) 增长的函数。 请参阅Big-O 表示法

You are correct. However, while I have not read this book myself, it sounds like they are attempting to give a growth order, not an exact number. n * (n-1) / 2 is a function that grows as O(n^2). See Big-O Notation.

还在原地等你 2024-08-06 05:44:58

神话般的人月指的是整体算法效率,通过接近无穷大的行为来衡量。

n*(n-1)/2 = O(n^2)

The mythical man month refers to overall algorithmic efficiency, as measured by the behavior near infinity.

n*(n-1)/2 = O(n^2)

月亮坠入山谷 2024-08-06 05:44:58

我认为区别在于握手只发生一次并且对双方都有影响。 与队友的沟通可以由任何一个人发起,因此您最终会计算路径两次,每个发起者一次。

根据我的个人经验,有些人(我刚刚决定将他们称为 UberCommunicators)可以将这个因素提高另一个数量级,仅仅是因为与他们沟通的固有成本。 它们往往极其冗长,无法简明地陈述要点,而且通常很难继续完成任务。 获得有用的对话需要长时间的反复努力。

I think the difference is that shaking hands occurs once and counts for both people. Communicating with teammates can be initiated from either person, so you end up counting the paths twice, once for each initiator.

In my personal experience, there are certain people (who I've just decided to call UberCommunicators) that can increase the factor by another order of magnitude simply due to the inherent costs of communicating with them. They tend to be extremely verbose, unable to state a concise point, and generally difficult to keep on task. Getting a useful dialog requires repeated efforts over an extended period of time.

凶凌 2024-08-06 05:44:58

我认为你对此分析过度了。 神话般的人月并不是一本像《21 天学会如何编程 Ruby》那样的计算机书籍。 这是一本关于团队如何互动的商业书籍。 因此,它把人当作人,而不是机器。 这意味着近似和启发法才是当今的主流,而不是算法和精度。

请(请,请,请)记住将您的队友视为人类,而不仅仅是另一台计算机。 这将带来更愉快的工作环境和更好的项目。

I think you're overanalysing this. The mythical man month is not a computer book like Learn How to Program Ruby in 21 Days. It's a business book on how teams interact. As such, it treats people as people, not as machines. Which means that approximations and heuristics are the order of the day, not algorithms and precision.

Please (please, please, please) remember to treat your team mates as human beings and not as just another computer. It will make for a more pleasant work environment and a better project.

孤檠 2024-08-06 05:44:58

我不记得这本书到底讲了什么,所以把我的书从书架上拿了下来。 您可能会很高兴地了解到,在第 2 章(这也是这本书的名字的文章)中,布鲁克斯实际上确实说通信路径的数量是 n(n - 1)/2,与您所说的相符。 因此,正如其他人所说,我怀疑 n^2“引用”只是 O(n) 表示法的简化。

I didn't remember exactly what the book says, so pulled my copy off the shelf. You may be happy to learn that in chapter 2 - which is also the essay which gave the book its name - Brooks actually does says that the number of communications paths is n(n - 1)/2, matching what you said. So, as others have said, I suspect that the n^2 "quote" is just a simplification along the lines of O(n) notation.

滥情稳全场 2024-08-06 05:44:57

如果您读过这本书,您就不会问这个问题。 它实际上是这样说的:

如果一个项目有 n 个工作人员,则可能有 (n^2-n)/2 个接口进行通信,并且可能有几乎2^n 个团队,其中必须进行协调。

对于那些玩家庭游戏的人来说,这是在第 7 章中,在大型编程项目中的组织标题下。

所以答案是你是对的,但这也是书上说的。

If you had read the book, you wouldn't have asked the question. Here's what it actually says:

If there are n workers on a project, there are (n^2-n)/2 interfaces across which there may be communication, and there are potentially almost 2^n teams within which coordination must occur.

For those playing the home game, this is in Chapter 7, under the heading Organization in the Large Programming Project.

So the answer is that you are right, but that's what the book says too.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文