Flooding algorithm: Difference between revisions

Content deleted Content added
m Grammar edit.
remove multiple issues template
 
(49 intermediate revisions by 32 users not shown)
Line 1:
{{Short description|Class of algorithms}}
[[Image:Flood.gif|right|thumb|flooding algorithm]]
{{Notability|date=January 2024}}
[[Image:FloodAck.gif|right|thumb|flooding algorithm with ack messages]]
A '''flooding algorithm''' is an [[algorithm]] for distributing material to every part of a [[Graph (discrete mathematics)|graph]]. The name derives from the concept of inundation by a [[flood]]. Flooding algorithms are used in [[Flooding (computer networking)|computer networking]] and [[Flood fill|graphics]]. Flooding algorithms are also useful for solving many mathematical problems, including [[maze]] problems and many problems in [[graph theory]].
 
Different flooding algorithms can be applied for different problems, and run with different [[time complexities]]. For example, the [[flood fill]] algorithm is a simple but relatively robust algorithm that works for intricate geometries and can determine which part of the (target) area that is [[Glossary of graph theory#Connectivity|connected]] to a given (source) node in a multi-dimensional [[Array data structure|array]], and is trivially generalized to arbitrary graph structures. If there instead are several source nodes, there are no obstructions in the geometry represented in the multi-dimensional array, and one wishes to segment the area based on which of the source nodes the target nodes are closest to, while the flood fill algorithm can still be used, the [[jump flooding algorithm]] is potentially much faster as it has a lower time complexity. Unlike the flood fill algorithm, however, the jump flooding algorithm cannot trivially be generalized to unstructured graphs.<ref>{{Cite web |title=What is Flooding Algorithm |url=https://www.igi-global.com/dictionary/flooding-algorithm/11267#:~:text=A%20flooding%20algorithm%20is%20an,part%20of%20some%20routing%20protocols. |website=IGI Global}}</ref><ref>{{Cite web |title=Flooding in Computer Networks |url=https://byjus.com/gate/flooding-in-computer-networks-notes/ |website=Byjus's Exam Prep}}</ref>
A '''flooding algorithm''' is an [[algorithm]] for distributing material to every part of a connected [[computer network|network]]. The name derives from the concept of inundation by a [[flood]].
 
== See also ==
Flooding algorithms are used in systems such as [[Usenet]] and [[peer-to-peer]] [[file sharing system]]s and as part of some [[routing protocol]]s, including [[Open Shortest Path First|OSPF]], [[DVMRP]], and those used in [[ad-hoc wireless network]]s.
* [[Flooding (computer networking)]]
* [[Water retention on mathematical surfaces]]
* [[floodFlood fill]]
* [[Graph traversal]]
* [[Spanning tree]]
* [[Spanning Tree Protocol]]
* [[Amnesiac flooding|Amnesiac Flooding]]
 
== References ==
There are several variants of flooding algorithm: most work roughly as follows.
{{reflist}}
#Each node acts as both a transmitter and a receiver.
#Each node tries to forward every message to every one of its neighbors except the source node.
This results in every message eventually being delivered to all reachable parts of the network.
 
== External links ==
Real-world flooding algorithms have to be more complex than this, since precautions have to be taken to avoid wasted duplicate deliveries and infinite loops, and to allow messages to eventually expire from the system.
* [https://arxiv.org/abs/1305.5756 Flooding edge or node weighted graphs, Fernand Meyer]
* [https://web.archive.org/web/20131211173036/http://users.eastlink.ca/~sharrywhite/Download.html Water Retention Utility]
 
[[Category:GraphFlooding algorithms| ]]
Flooding algorithms are also useful for solving many mathematical problems, including [[maze]] problems and many problems in [[graph theory]].
 
== Disadvantages of Flooding ==
There are several disadvantages with this approach to routing. It is very wasteful in terms of the networks total bandwidth. While a message may only have one destination it has to be sent to every host. This increases the maximum load placed upon the network.
 
Messages can also become duplicated in the network further increasing the load on the networks bandwidth as well as requiring an increase in processing complexity to disregard duplicate messages.
 
A variant of flooding called ''selective flooding'' partially addresses these issues by only sending packets to routers in the same direction.
 
== Advantages of Flooding ==
 
The main advantage of flooding the increased reliability provided by this routing method. Since the message will be sent at least once to every host it is almost guaranteed to reach its destination. In addition, the message will reach the host through the shortest possible path.
 
==See also==
* [[multicast]]
* [[flood fill]]
 
==Examples==
* [http://ricochet.wiki.sourceforge.net/ Ricochet] A flooding networking app written in Java
 
{{compu-network-stub}}
 
[[Category:Graph algorithms]]
[[de:Flooding-Algorithmus]]
[[it:Flooding]]
[[pt:Algoritmo de inundação]]