Главная » Просмотр файлов » Distributed Algorithms. Nancy A. Lynch (1993)

Distributed Algorithms. Nancy A. Lynch (1993) (811416), страница 48

Файл №811416 Distributed Algorithms. Nancy A. Lynch (1993) (Distributed Algorithms. Nancy A. Lynch (1993).pdf) 48 страницаDistributed Algorithms. Nancy A. Lynch (1993) (811416) страница 482020-08-25СтудИзба
Просмтор этого файла доступен только зарегистрированным пользователям. Но у нас супер быстрая регистрация: достаточно только электронной почты!

Текст из файла (страница 48)

At any point in the algorithm, each of a collection of fragments may independentlyand concurrently nd its own minimum-weight outgoing edge (MWOE), knowing that allsuch edges found must be included in the unique MST. (Note that if the edge weights werenot distinct, the fragments couldn't carry out this choice independently, since it would bepossible for them to form a cycle.)This was the basis of the synchronous algorithm. It worked in synchronous levels, wherein each level, all fragments found their MWOE's and combined using these, to form at mosthalf as many fragments.If we try to run the given synchronous algorithm in an asynchronous network, we seesome problems.Diculty 1: In the synchronous case, when a node queries a neighbor to see if it is in thesame fragment, it knows that the neighbor node is up-to-date, at the same level.

Therefore,if the neighbor has a distinct fragment id, then this fact implies that the neighbor is not inthe same fragment. But in the asynchronous setting, it could be the case that the neighborhas not yet heard that it is in the same fragment.Diculty 2: The synchronous algorithm achieves a message cost of O(n log n + E ), basedon a balanced construction of the fragments. Asynchronously, there is danger of constructing the fragments in an unbalanced way, leading to many more messages. The number ofmessages sent by a fragment to nd its MWOE will be proportional to the number of nodesin the fragment.

Under certain circumstances, one might imagine the algorithm proceedingby having one large fragment that picks up a single node at a time, each time requiring (f )messages, where f is the number of nodes in the fragment (see Figure 19.2) . In such asituation, the algorithm would require (n2) messages to be sent overall.242Figure 19.2: How do we avoid a big fragment growing by one node at a time?19.2.4 The Gallager-Humblet-Spira Algorithm: OutlineThese diculties lead us to re-think the algorithm to modify it for use in an asynchronousnetwork.

Luckily, the basic ideas are the same. The algorithm we shall see below is byGallager-Humblet-Spira. They focus on keeping the number of messages as small as possible,and manage to achieve the same O((n log n) + E ) message bound as in the synchronousalgorithm.Before we continue, let us make a few preliminary remarks. First, consider the questionwhether this is the minimum bound possible. Note that, at least for some graphs (e.g., rings),the n log n term is necessary | it comes from the lower bound on the number of messagesfor leader election that we saw in Burns' theorem.

What about the E term? This seemsessential. In a work by Awerbuch-Goldreich-Peleg-Vainish, they show that the number ofbits of communication must be at least (E log n). If we assume that each message containsonly a constant number of id's, then this means that the number of messages is (E ). Ifthe messages are allowed to be of arbitrary size, however, then it can be shown that O(n)messages suce.Another thing we would like to say about the Gallager-Humblet-Spira algorithm is thatnot only is it interesting, but it is also extremely clever: as presented in their paper, it isabout two pages of tight, modular code, and there is a good reason for just about every linein the algorithm.

In fact, only one or two tiny optimizations have been advanced over theoriginal algorithm. The algorithm has been proven correct via some rather dicult formalproofs (see WelchLL88]) and it has been referenced and elaborated upon quite often insubsequent research.

It has become a sort of test case for algorithm proof techniques.As in the synchronous algorithm we saw earlier, the central idea of the Gallager-HumbletSpira algorithm is that nodes form themselves into collections | i.e., fragments | of increasing size. (Initially, all nodes are considered to be in singleton fragments.) Each fragmentis itself connected by edges that form a MST for the nodes in the fragment. Within anyfragment, nodes cooperate in a distributed algorithm to nd the MWOE for the entire fragment (that is, the minimum weight edge that leads to a node outside the fragment). The243strategy for accomplishing this involves broadcasting over the edges of the fragment, askingeach node separately for its own MWOE leading outside the fragment.

Once all these edgeshave been found, the minimal edge among them will be selected as an edge to include in the(eventual) MST.Once an MWOE for a fragment is found, a message may be sent out over that edge tothe fragment on the other side. The two fragments may then combine into a new, largerfragment. The new fragment then nds its own MWOE, and the entire process is repeateduntil all the nodes in the graph have combined themselves into one giant fragment (whoseedges are the nal MST).This is not the whole story, of course there are still some problems to overcome. First,how does a node know which of its edges lead outside its current fragment? A node infragment F can communicate over an outgoing edge, but the node at the other end needssome way of telling whether it too is in F . We will therefore need some way of namingfragments so that two nodes can determine whether they are in the same fragment.

But theissue is still more complicated: it may be, for example, that the other node (at the end of theapparently outgoing edge) is in F but hasn't learned this fact yet, because of communicationdelays. Thus, some sort of overall synchronization process is needed|some sort of strategythat ensures that nodes won't search for outgoing edges until all nodes in the fragment havebeen informed of their current fragment.And there is also the second problem, discussed above, of the unbalanced merging behavior causing excessive message cost. This second problem should suggest a \balanced-treealgorithm" solution: that is, the diculty derives from the merging of data structures thatare very unequal in size. The strategy that we will use, therefore, is to merge fragments ofroughly equal size.

Intuitively, if we can keep merging fragments of nearly equal size, we cankeep the number of total messages to O(n log n).The trick we will use to keep the fragments at similar sizes is to associate a level numberwith each fragment. We will ensure that if level (F ) = l for a given fragment F , then thenumber of nodes in F is greater than or equal to 2l.

Initially, all fragments are just singletonnodes at level 0. When two fragments at level l are merged together, the result is a newfragment at level l + 1. (This preserves the condition for level numbers: if two fragments ofsize at least 2l are merged, the result is a new fragment of size at least 2l+1.)So far, this may look similar to the way the level numbers were used in the synchronousalgorithm, but it will actually be somewhat dierent. E.g., in the synchronous case, we couldmerge some arbitrary number of level l fragments to get a new level l + 1 fragment.The level numbers, as it turns out, will not only be useful in keeping things balanced,but they will also provide some identier-like information helping to tell nodes whether they244are in the same fragment.19.2.5 In More DetailThere are two ways of combining fragments.1.

Merging. This combining rule is applied when we have two fragments F and F 0 withthe same level and the same minimum-weight outgoing edge:level (F ) = level (F 0) = lMWOE(F ) = MWOE(F 0)The result of a merge is a new fragment at a level of l + 1.2. Absorbing. There is another case to consider. It might be that some nodes are forminginto huge fragments via merging, but isolated nodes (or small fragments) are laggingbehind at a low level. In this case, the small fragments may be absorbed into thelarger ones without determining the MWOE of the large fragment.

Specically, therule for absorbing is that if two fragments F and F 0 satisfy level (F ) < level (F 0), andthe MWOE(F ) leads to F 0, then F can be absorbed into F 0 by combining them alongMWOE(F ). The larger fragment formed is still at the level of F 0. In a sense, we don'twant to think of this as a \new" fragment, but rather as an augmented version of F 0.These two combining strategies are illustrated (in a rough way) by Figure 19.3. It isworth stressing the fact that level(F ) < level(F 0) does not imply that fragment F is smallerthan F 0 in fact, it could be larger. (Thus, the illustration of F as a \small" fragment inFigure 19.3 is meant only to suggest the typical case.)Level numbers also serve, as mentioned above, as identifying information for fragments.For fragments of level 1 or greater, however, the specic fragment identier is the core edgeof the fragment.

The core edge is the edge along which the merge operation resulting in thecurrent fragment level took place. (Since level numbers for fragments are only incrementedby merge operations, any fragment of level 1 or greater must have had its level numberincremented by some previous merge along an edge.) The core edge also serves as the sitewhere the processing for the fragment originates and where information from the nodes ofthe fragment is collected.To summarize the way in which core edges are identied for fragments: For a merge operation, core is the common MWOE of the two combining fragments. For an absorb operation, core is the core edge of the fragment with the larger levelnumber.245' $' $& %& %'& $%F-F0F -F0Figure 19.3: Two fragments combine by merging a fragment absorbs itself into anotherNote that identifying a fragment by its core edge depends on the assumption that alledges have unique identiers.

Характеристики

Тип файла
PDF-файл
Размер
2,41 Mb
Тип материала
Высшее учебное заведение

Список файлов книги

Свежие статьи
Популярно сейчас
Почему делать на заказ в разы дороже, чем купить готовую учебную работу на СтудИзбе? Наши учебные работы продаются каждый год, тогда как большинство заказов выполняются с нуля. Найдите подходящий учебный материал на СтудИзбе!
Ответы на популярные вопросы
Да! Наши авторы собирают и выкладывают те работы, которые сдаются в Вашем учебном заведении ежегодно и уже проверены преподавателями.
Да! У нас любой человек может выложить любую учебную работу и зарабатывать на её продажах! Но каждый учебный материал публикуется только после тщательной проверки администрацией.
Вернём деньги! А если быть более точными, то автору даётся немного времени на исправление, а если не исправит или выйдет время, то вернём деньги в полном объёме!
Да! На равне с готовыми студенческими работами у нас продаются услуги. Цены на услуги видны сразу, то есть Вам нужно только указать параметры и сразу можно оплачивать.
Отзывы студентов
Ставлю 10/10
Все нравится, очень удобный сайт, помогает в учебе. Кроме этого, можно заработать самому, выставляя готовые учебные материалы на продажу здесь. Рейтинги и отзывы на преподавателей очень помогают сориентироваться в начале нового семестра. Спасибо за такую функцию. Ставлю максимальную оценку.
Лучшая платформа для успешной сдачи сессии
Познакомился со СтудИзбой благодаря своему другу, очень нравится интерфейс, количество доступных файлов, цена, в общем, все прекрасно. Даже сам продаю какие-то свои работы.
Студизба ван лав ❤
Очень офигенный сайт для студентов. Много полезных учебных материалов. Пользуюсь студизбой с октября 2021 года. Серьёзных нареканий нет. Хотелось бы, что бы ввели подписочную модель и сделали материалы дешевле 300 рублей в рамках подписки бесплатными.
Отличный сайт
Лично меня всё устраивает - и покупка, и продажа; и цены, и возможность предпросмотра куска файла, и обилие бесплатных файлов (в подборках по авторам, читай, ВУЗам и факультетам). Есть определённые баги, но всё решаемо, да и администраторы реагируют в течение суток.
Маленький отзыв о большом помощнике!
Студизба спасает в те моменты, когда сроки горят, а работ накопилось достаточно. Довольно удобный сайт с простой навигацией и огромным количеством материалов.
Студ. Изба как крупнейший сборник работ для студентов
Тут дофига бывает всего полезного. Печально, что бывают предметы по которым даже одного бесплатного решения нет, но это скорее вопрос к студентам. В остальном всё здорово.
Спасательный островок
Если уже не успеваешь разобраться или застрял на каком-то задание поможет тебе быстро и недорого решить твою проблему.
Всё и так отлично
Всё очень удобно. Особенно круто, что есть система бонусов и можно выводить остатки денег. Очень много качественных бесплатных файлов.
Отзыв о системе "Студизба"
Отличная платформа для распространения работ, востребованных студентами. Хорошо налаженная и качественная работа сайта, огромная база заданий и аудитория.
Отличный помощник
Отличный сайт с кучей полезных файлов, позволяющий найти много методичек / учебников / отзывов о вузах и преподователях.
Отлично помогает студентам в любой момент для решения трудных и незамедлительных задач
Хотелось бы больше конкретной информации о преподавателях. А так в принципе хороший сайт, всегда им пользуюсь и ни разу не было желания прекратить. Хороший сайт для помощи студентам, удобный и приятный интерфейс. Из недостатков можно выделить только отсутствия небольшого количества файлов.
Спасибо за шикарный сайт
Великолепный сайт на котором студент за не большие деньги может найти помощь с дз, проектами курсовыми, лабораторными, а также узнать отзывы на преподавателей и бесплатно скачать пособия.
Популярные преподаватели
Добавляйте материалы
и зарабатывайте!
Продажи идут автоматически
6418
Авторов
на СтудИзбе
307
Средний доход
с одного платного файла
Обучение Подробнее