1 / 24

Modeling networks as graphs

Modeling networks as graphs. By Sudheer kovi. Topics Covered are:. 1)Network Protocols. Stop-and-Wait Alternating Bit Protocol Sliding Window Protocol Transmission Control Protocol 2)Modeling Networks as Graphs.

errol
Download Presentation

Modeling networks as graphs

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Modeling networks as graphs • By • Sudheer kovi

  2. Topics Covered are: • 1)Network Protocols. • Stop-and-Wait • Alternating Bit Protocol • Sliding Window Protocol • Transmission Control Protocol • 2)Modeling Networks as Graphs.

  3. Network?It is a process of inter connection, it can be both connection oriented or wireless.The Need for Networks?Transferring data from one end to the other, either in the form of signals or packets of data.

  4. Network protocols • The job of a network is to enable efficient and reliable communication between hosts, and these protocols are mainly designed for solving the problems like Error control, Flow control, Bandwidth limitation.

  5. Error control : while transmitting the data the messages can be lost, corrupted or reordered. Flow control : Incompatibility between the sending and receiving hosts, the receiving host may not be able to process messages as fast as the sending host can send them. Bandwidth limitation : Limitation on the speed in which data is being transferred, if its more or less than the required bandwidth data could be lost.

  6. To solve these problems acknowledgement is one of the finest solution, protocol stack is the best way to explain this. • HTTP,SMPT • TCP,UDP • IP • ETHERNET • WIRES,CABLES • RADIO FREQUENCY

  7. STOP-AND-WAIT • Automatic Repeat request (ARQ), is an error control method, and it is a part of stop and wait flow control protocol. • If error is detected by receiver, it discards the frame and send a negative ACK (NAK), causing sender to re-send the frame. • In case a frame never got to receiver, sender has a timer, where each time a frame is sent, timer is set. • If no ACK or NAK is received during timeout period, it re-sends the frame.

  8. Stop-and-wait • Suppose timeout and sender retransmits a frame but receiver actually received the previous transmission receiver has duplicated copies.

  9. A B • Frame 0 • ACK • Frame 1 • ACK • Frame 2 • Timeout • Frame 2 • ACK • Frame 3 • Timeout ACK • Frame 3 • ACK B receive the Duplicate • Frame

  10. ALTERNATING BIT protocol • The Alternating Bit Protocol doesn’t add arbitrary subscripts. • It add a single control bit to each data message and to each ACK. • In this if the sender sends the data D0 to receiver it sends the ACK1 indicating that the sender next data message should be D1. • To avoid receiving and accepting two copies of same frame, frames and ACKs are alternatively labeled 0 or 1: ACK1 for D0, ACK0 for D1 • The Alternating Bit Protocol does not solve all error control problems.

  11. Alternating bit protocol SENDER D0 D0 D1 ACK1 ACK 1 ACK1 D0 D0 ACK 1 RECEIVER

  12. SLIDING WINDOW PROTOCOL • The sliding window protocol can solve wasted bandwidth problems by using more sophisticated ARQ technique. • In sliding window protocol sequence number is assigned to the messages that sender sends to receiver. • The sliding window protocol begins by choosing a window size W. • Data messages are initially entered into a FIFO queue, and the sequence number is assigned, that is maintained by the sender. • Sliding window protocol is used sending messages on the internet. • The message that have been send are shown in the sender’s queue with dark shade.

  13. SLIDING WINDOW PROTOCOL • Same in the receiver side the received messages are seen with the dark shade. • In this it will not wait for the ACK of message ‘n’ before sending the message n+1 • The Sliding window protocol cannot be modeled as a finite state machine because of the need to store the message sequence number.

  14. 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 3 3 3 3 4 4 4 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5 5 6 6 6 6 6 6 6 6 6 6 7 7 7 7 7 7 7 7 7 7 8 8 8 8 8 8 8 8 8 8 9 9 9 9 9 9 9 9 9 9 10 10 10 10 10 10 10 10 10 10 11 11 11 11 11 11 11 11 11 11 12 12 12 12 12 12 12 12 12 12 13 13 13 13 13 13 13 13 13 13 14 14 14 14 14 14 14 14 14 14 SENDER RECEIVER 0 1 2 A3 3 4 5 6 A4

  15. TRANSMISSION CONTROL PROTOCOL • In the internet protocol stack, the transport layer sits immediately below the application layer. • Transmission Control Protocol is the most widely used Internet protocol Web, HTTP, SMPT, FTP, and Telnet. • TCP is a two way, reliable, byte stream oriented end-to-end protocol. • TCP connection is established by a three step handshake procedure: one host initiates the connection, and the other acknowledges it, and the originator then confirms the acknowledgement. • In TCP ones connection is open then data can be transmitted between the two hosts until the connection is closed.

  16. TRANSMISSION CONTROL PROTOCOL • In this a connection progress through a series of states during its lifetime. • The states are : LISTEN, SYN-SEND, SYN-RECEIVED, ESTABLISHED, FIN-WAIT-1, FIN-WAIT-2, CLOSED-WAIT, CLOSING, LAST-ACK,TIME-WAIT, and CLOSED. • CLOSED represents the state when there is no Transmission Control Block. • The transition in the below diagram has a label of the form <event> / <action>.

  17. CLOSED Active OPEN Create TCB snd SYN CLOSE Delete TCB Passive OPEN create TCB CLOSE Delete TCB LISTEN rcv SYN sen SYN, ACK SEND SND SYN SYN RCVD SYN SENT Rcv SYN, ACK sen ACK rcv ACK of SYN x ESTEB CLOSE snd FIN CLOSE snd FIN rcv FIN snd ACK FIN WAIT-1 CLOSED WAIT CLOSE sen FIN rcv FIN snd ACK rcv ACK of FIN x CLOSING LAST ACK FIN WAIT-2 rcv ACK of FIN x rcv ACK of FIN x Timeout = 2MSL Delete TCB TIME WAIT CLOSED rcv FIN snd ACK

  18. MODELING NETWORKS AS GRAPHS • In this we generally model a network to a graph, in which processors correspond to vertices and links to edges by doing so we can solve many problems associated to it. • Let g be a undirected graph with vertices V an edges U . • Edges corresponds to laying cables between two vertices. • One of the efficient technique to find the minimum spanning tree, we use kruskal’s algorithm. • Consider spanning tree T where T(G)-subset of edges of G. Where T has no cycles, G is connected to every other vertex using just the edges in T.

  19. Modeling networks as graphs • In this we have 2ways to determine efficient path. • Shortest Path • Eulerian Circuit

  20. Modeling networks as graphs • Shortest-Path : • Given a weighted graph and two vertices u and v, we want to find a path of minimum total weight between u and v. Length of a path is the sum of the weights of its edges. • G is an unweighted, undirected graph. • Where u and v are Vertices in G. • k ≥ 0, there exists a path from u to v whose length is at most k.

  21. MODELING NETWORKS AS GRAPHS • Example: • Shortest path between ‘S’ and ‘T’ 2 23 3 9 s 18 14 6 2 6 4 19 30 11 5 15 5 6 16 20 t 7 44

  22. MODELING NETWORKS AS GRAPHS • EULERIAN CIRCUIT: • The shortest way to traverse all the links in a network is via an Eulerian Circuit. • We check the network to verify that all links are working properly. • It describe the network as a graph G. • Where vertices corresponds to network nodes. • Edges corresponds to network links. • Where vertex cover C of a graph G with vertices v, and edges E is a subset of v. • In this every edge E touches at least one vertices in C.

  23. references • Automata, Computability and Complexity : theory and application by Rich, Elaine. • http://en.wikipedia.org/wiki/Sliding_window_protocol • users.ecs.soton.ac.uk/sqc/EL336/CNL-5.pdf

  24. Thank you

More Related