The project is the course project of Parallel Computing 2018 Autumn in Nanjing University. The requirement of it is to implement the serial and parallel Java programs of several sort algorithms like Quicksort, Enumsort and Mergesort. What's more, it's necessary to compare the running time of these programs and analyze the advantage, bottleneck and drawback of parallel algorithms. Here, I implement the above algorithms and try different ways of implementation of the same algorithm.
The input dataset is stored in random.txt
with 30000 unordered integers ranging from -50000 to 50000, seperated by blank space. The six different algorithms seperately prints their outputs to order*.txt
where *
ranges from 1 to 6.
Thread
class andstart
,join
methodsRecursiveAction
,ForkJoinPool
classes andinvoke
,invokeAll
methodsExecutorService
,Future
classes andsubmit
,shutdown
methods
Here I implement Quicksort and MergeSort with different APIs.
- Since the project is build by Intellij IDEA, you can import it into your IJ or open it in IJ, and click
make project
orrun
. - I provide
ReadMe.txt
to describe the compiling and running command of the project.You can input$ bash run.sh