Reader Level:
Articles

Synchronization in Parallel threads

By Paul Abraham on July 02, 2001
The Threads makes us able to run multitasks at a time. In fact Computers (John von Neumann Architecture) don't execute the tasks parallel .The OS gives threads permission (depend on thread priority) to work on CPU. The sufficient degree of parallelism keeps the CPU busy and it is efficient.
  • 0
  • 0
  • 13251
Download Files:
 

The Threads makes us  able to run multitasks at a time. In fact  Computers (John von Neumann Architecture)  don't  execute  the tasks parallel. The OS gives threads permission  (depend on thread priority)  to work on CPU. The sufficient degree of parallelism keeps the CPU busy  and it is efficient.

Now, let us look  a   simple mathematical problem:

We want  calculate the Integral from the function  f(x) =  x*x +exp(x). using  trapezoid formula. We will use different threads to calculate the integral from partial  functions  f1(x) = x*x  and f2(x) = exp(x). After the calculation we will add the values together.

This article is tested on RTM by Zhanbo Sun.

Paul Abraham

Paul Abraham is a software developer who designs and develops multi-shop systems. He has received his Diplom-degree in mathematics (major) and computer science (minor) from the FernUniversität Hagen Germany and his main ... Read more

COMMENT USING

Trending up