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

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

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

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

Since we are assuming that the edges have unique weights,the weights could be the identiers.We now want to show that this strategy, of having fragments merge together and absorbthemselves into larger fragments, will in fact suce to combine all fragments into a MST forthe entire graph.Claim 1 If we start from an initial situation in which each fragment consists of a singlenode, and we apply any possible sequence of merge and absorb steps, then there is alwayssome applicable step to take until the result is a single fragment containing all the nodes.Proof: We want to show that no matter what conguration we arrive at in the course ofthe algorithm, there is always some merge or absorb step that can be taken.One way to see that this is true is to look at all the current fragments at some stagein the running algorithm.

Each of these fragments will identify its MWOE leading to someother fragment. If we view the fragments as vertices in a \fragment-graph," and draw theMWOE for each fragment, we get a directed graph with an equal number of vertices andedges (see Figure 19.4). Since we have k nodes and k edges (for some k), such a directedgraph must have a cycle and because the edges have distinct weights, only cycles of size2 (i.e., cycles involving two fragments) may exist. Such a 2-cycle represents two fragmentsthat share a single MWOE.Now, it must be the case that the two fragments in any 2-cycle can be combined. If thetwo fragments in the cycle have the same level number, a merge operation can take placeotherwise, the fragment with the smaller level number can absorb itself into the fragment246 -?--Figure 19.4: A collection of fragments and their minimum-weight outgoing edges.with the larger one.Let's return to the question of how the MWOE is found for a given fragment.

The basicstrategy is as follows. Each node in the fragment is nds its own MWOE leading outsidethe fragment then the information from each node is collected at a selected process, whichtakes the minimum of all the edges suggested by the individual nodes.This seems straightforward, but it re-opens the question of how a node knows that agiven edge is outgoing|that is, that the node at the other end of the edge lies outside thecurrent fragment. Suppose we have a node p that \looks across" an edge e to a node q atthe other end. How can p know if q is in a dierent fragment or not?A fragment name (or identier) may be thought of as a pair (core level ). If q's fragmentname is the same as p's, then p certainly knows that q is in the same fragment as itself.However, if q's fragment name is dierent from that of p, then it is still possible that q andp are indeed in the same fragment, but that q has not yet been informed of that fact.

Thatis to say, q's information regarding its own current fragment may be out of date.However, there is an important fact to note: if q's fragment name has a core unequal tothat of p, and it has a level value at least as high as p, then q can't be in the fragment thatp is in currently, and never will be. This is so because in the course of the algorithm, a nodewill only be in one fragment at any particular level.

Thus, we have a general rule that qcan use in telling p whether both are in the same fragment: if the value of (core level ) forq is the same as that of p then they are in the same fragment, and if the value for core isdierent for q and the value of level is at least as large as that of p then they are in dierentfragments.The upshot of this is that MWOE(p) can be determined only if level (q) level (p). If qhas a lower level than p, it simply delays answering p until its own level is at least as greatas p's.247q '&q $%F p- q F0Figure 19.5: Fragment F absorbs itself into F 0 while F 0 is still searching for its own MWOE.However, notice that we now have to reconsider the progress argument, since this extraprecondition may cause progress to be blocked.

Since a fragment can be delayed in ndingits MWOE (since some individual nodes within the fragment are being delayed), we mightask whether it is possible for the algorithm to reach a state in which neither a merge orabsorb operation is possible. To see that this is not the case, we use essentially the sameargument as before, but this time we only consider those MWOE's found by fragmentswith the lowest level in the graph (call this level l).

These succeed in all their individualMWOE(p) calculations, so succeed in determining their MWOE for the entire fragment.Then the argument is as before: If any fragment at level l nds a MWOE to a higher-levelfragment, then an absorb operation is possible and if every fragment at the level l has aMWOE to some other fragment at level l, then we must have a 2-cycle between two fragmentsat level l, and a merge operation is possible. So again, even with the new preconditions, weconclude that the algorithm must make progress until the complete MST is found.Getting back to the algorithm, each fragment F will nd its overall MWOE by taking aminimum of the MWOE for each node in the fragment. This will be done by a \broadcastconvergecast" algorithm starting from the core, emanating outward, and then collecting allinformation back at the core.This leads to yet another question: what happens if a \small" fragment F gets absorbedinto a larger one F 0 while F 0 is still in the course of looking for its own MWOE?There are two cases to consider (consult Figure 19.5 for the labeling of nodes).

Supposerst that the minimum edge leading outside the fragment F 0, has not yet been determined.In this case, we search for a MWOE for the newly-augmented fragment F 0 in F as well (thereis no reason it cannot be there).On the other hand, suppose MWOE(F 0) has already been found at the time that Fabsorbs itself into F 0. In that event, the MWOE for q cannot possibly be e, since the only248way that the MWOE for q could be known is for that edge to lead to a fragment with a levelat least as great as F 0, and we know that the level of F is smaller than that of F 0. Moreover,the fact that the MWOE for q is not e implies that the MWOE for the entire fragmentF 0 cannot possibly be in F .

This is true because e is the MWOE for fragment F , andthus there can be no edges leading out of F with a smaller cost than the already-discoveredMWOE for node q. Thus, we conclude that if MWOE(F 0) is already known at the time theabsorb operation takes place, then fragment F 0 needn't look for its overall MWOE amongthe newly-absorbed nodes. (This is fortunate, since if F 0 did in fact have to look for itsMWOE among the new nodes, it could be too late: by the time the absorb operation takesplace, q might have already reported its own MWOE, and fragment F 0 might already bedeciding on an overall MWOE without knowing about the newly-absorbed nodes.)19.2.6 A Summary of the Code in the GHS AlgorithmWe have described intuitively the major ideas of the Gallager-Humblet-Spira algorithm thisexplanation above should be sucient to guide the reader through the code presented intheir original paper.Although the actual code in the paper is dense and complicated, the possibility of anunderstandable high-level description turns out to be fairly typical for communications algorithms.

In fact, the high-level description that we have seen can serve as a basis for acorrectness proof for the algorithm, using simulations.The following message types are employed in the actual code: INITIATE messages are broadcast outward on the edges of a fragment to tell nodes tostart nding their MWOE. REPORT messages are the messages that carry the MWOE information back in.(These are the convergecast response to the INITIATE broadcast messages.) TEST messages are sent out by nodes when they search for their own MWOE. ACCEPT and REJECT messages are sent in response to TEST messages from nodesthey inform the testing node whether the responding node is in a dierent fragment(ACCEPT) or is in the same fragment (REJECT).

CHANGE-ROOT is a message sent toward a fragment's MWOE once that edge isfound. The purpose of this message is to change the root of the (merging or currentlybeing-absorbed) fragment to the appropriate new root.249 CONNECT messages are sent across an edge when a fragment combines with another.In the case of a merge operation, CONNECT messages are sent both ways along theedge between the merging fragments in the case of an absorb operation, a CONNECTmessage is sent by the \smaller" fragment along its MWOE toward the \larger" fragment.In a bit more detail, INITIATE messages emanate outward from the designated \coreedge" to all the nodes of the fragment these INITIATE messages not only signal the nodesto look for their own MWOE (if that edge has not yet been found), but they also carryinformation about the fragment identity (the core edge and level number of the fragment).As for the TEST-ACCEPT-REJECT protocol: there's a little bookkeeping that nodes haveto do.

Every node, in order to avoid sending out redundant messages testing and re-testingedges, keeps a list of its incident edges in the order of weights. The nodes classify theseincident edges in one of three categories: Branch edges are those edges designated as part of the building spanning tree. Basic edges are those edges that the node doesn't know anything about yet | theymay yet end up in the spanning tree.

(Initially, of course, all the node's edges areclassied as basic.) Rejected edges are edges that cannot be in the spanning tree (i.e., they lead to anothernode within the same fragment).A fragment node searching for its MWOE need only send messages along basic edges.The node tries each basic edge in order, lowest weight to highest. The protocol that thenode follows is to send a TEST message with the fragment level-number and core-edge(represented by the unique weight of the core edge). The recipient of the TEST messagethen checks if its own identity is the same as the TESTer if so, it sends back a REJECTmessage. If the recipient's identity (core edge) is dierent and its level is greater than orequal to that of the TESTer, it sends back an ACCEPT message.

Finally, if the recipienthas a dierent identity from the TESTer but has a lower level number, it delays respondinguntil such time as it can send back a denite REJECT or ACCEPT.So each node nds the MWOE if it exists. All of this information is sent back to thenodes incident on the core edge via REPORT messages, who determine the MWOE for theentire fragment. A CHANGEROOT message is then sent back towards the MWOE, and theendpoint node sends a CONNECT message out over the MWOE.When two CONNECT messages cross, this is the signal that a merge operation is takingplace.

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

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

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

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