sorting circuit along with odd-even merging circuit, Computer Networking

Assignment Help:

As we previously know, the merge sort algorithm needs two circuits, i.e. one for merging and second for sorting the sequences. Thus, the sorting circuit has been derived from the above-discussed merging circuit. The useful steps followed by the circuit are given below:

i) The given input series of length n is separated into two sub-sequences of length n/2 each.

ii) The two sub series are recursively sorted.

iii) The two sorted sub series are merged (n/2,n/2) using a merging circuit in order to finally get the sorted series of length n.

Now, let us take an instance for sorting the n numbers say 4,2,10,12 8,7,6,9. The circuit of sorting + merging given series is illustrated in Figure.

Analysis of Merge Sort

i)          The width of the sorting + merging circuit is equivalent to the maximum number of devices needs in a stage is O (n/2). As in the above figure the maximum number of devices for a given stage is 4 which is n/2or8/2.

ii)      The circuit has two sorting circuits for sorting series of length n/2 and after that one merging circuit for merging of the two sorted sub series (see stage 4th in the above figure). Let the functions Tm and Ts denote the time complexity of merging and sorting in terms of its depth.

The Ts can be calculated as follows: Ts (n) =Ts (n/2) + Tm (n/2) Ts (n) =Ts (n/2) + log (n/2),

Thus, Ts (n) is equal to O(log2 n).

640_Sorting + Merging Circuit.png

                                                                   Sorting + Merging Circuit


Related Discussions:- sorting circuit along with odd-even merging circuit

Write a descriptive note on rmonv2, Question 1 What does the SNMP access p...

Question 1 What does the SNMP access policy represent? Question 2 Does there exist any formal functional specification for SNMPv1 management? Question 3 In the con

Explain about line coding, Q. Explain about line coding? Line Coding ...

Q. Explain about line coding? Line Coding  Procedure of converting binary data to a digital signal DC Components  Residual dc (direct-current) components or

CLIENT SERVER BLACKJACK, So for this project, we’re going to make a game. ...

So for this project, we’re going to make a game. This game will make use of a server to join two clients together for a modified game of Blackjack.

Dijkstra algorithms - network layer and routing , Dijkstra Algorithms T...

Dijkstra Algorithms To calculate its  routing  table  each router applies an algorithm  called  the dijkstra algorithm to its  state database. The dijkstra algorithm  calculate

Describe in a generic manner the packet of ipsec, Can you describe in a gen...

Can you describe in a generic manner the packet of IPSec

The cut-through switching technique work, How does the cut-through switchin...

How does the cut-through switching technique work? Ans) Cut-Through switching copies only the destination address which is the first 6 bytes after the =frame preamble into its b

What is usage of sequence number in reliable transmission, What is usage of...

What is usage of Sequence Number in Reliable Transmission? The protocol specifies that frames need to be numbered. This is done by using sequence numbers. A field is added to t

Describe differential manchester, Q. Describe Differential Manchester? ...

Q. Describe Differential Manchester? - Inversion at middle of bit interval is utilized for synchronization - Presence or else absence of additional transition at beginning o

Wait protocol in parallel programming , Wait protocol The wait protoco...

Wait protocol The wait protocol is used for resolving the conflicts, which arise due to number of multiprocessors demanding the same resource. There are two types of wait prot

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd