Rank the list elements in terms of distance, Computer Engineering

Assignment Help:

Q. Rank the list elements in terms of distance?

Rank the list elements in terms of distance from each to last element in given linear linked list.

A parallel algorithm for this problem is given below. The algorithm presumes there are p number of processors.

Algorithm:

Processor j, 0≤ j

if next[j]=j then 

rank[j]=0

else rank[j] =1

endif

while rank[next[first]]≠0 Processor j, 0≤ j

rank[j]=rank[j]+rank[next[j]]

next[j]=next[next[j]]

endwhile

The working of above algorithm is explained by the diagram below:

1844_Rank the list elements in terms of distance.png

Figure: Finding rank of elements


Related Discussions:- Rank the list elements in terms of distance

How and what data is collected - weather simulation, How and what data is c...

How and what data is collected - Weather simulation -  Sensors measure pressure, relative humidity, temperature and wind speed and wind direction -  Sensors are placed in w

What happens if a function module runs in an update task, What happens if a...

What happens if a function module runs in an update task? The system performs the module processing asynchronously.  Instead of carrying out the call immediately, the system w

What is busy hour traffic, Busy hour traffic is the (A)  maximum avera...

Busy hour traffic is the (A)  maximum average simultaneous traffic. (B)  traffic during peak hour. (C)  traffic when all subscribers are engaged. (D)  the durat

Two layer artificial neural networks, Two Layer Artificial Neural Networks:...

Two Layer Artificial Neural Networks: However decision trees are whenever powerful they are as a simple representation scheme. Whereas graphical on the surface that they can b

What is race-around problem and how can you rectify this, What is Race-arou...

What is Race-around problem? How can you rectify this? The clock pulse which remains into the 1 state whereas both J and K are equal to 1 will reason the output to complement a

Differentiate between the serial port and parallel port, Question: (a) ...

Question: (a) Provide types of computer systems and briefly describe each one. (b) With the help of example, explain the difference between open source software, freeware a

Differentiate between static and dynamic step loops, Differentiate between ...

Differentiate between static and dynamic step loops. Step loops fall into two classes: Static and Dynamic.  Static step loops have a fixed size that cannot be changed at runti

Basics of caches - computer architecture, Basics of Caches: "The cache...

Basics of Caches: "The caches are situated on basis of blocks, the shortest amount of data which may be copied between 2 adjacent levels at a time. "If requested data by th

Define the concept of encapsulation of OOA, Encapsulation of OOA Encap...

Encapsulation of OOA Encapsulation separates the interface of an abstraction from its implementation. By taking the above example i.e. of a car, we can now categorize them as:

Design a xnor gate and define its work, N number of XNOR gates is linked in...

N number of XNOR gates is linked in series that is the N inputs (A0, A1, A2......) are specified in the subsequently way: A0 and A1 to first XNOR gate and A2 and O/P of First XNOR

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