Skip to content

danquan/matrix-expo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

46 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Matrix Exponential with Pthreads

Chương trình song song tích hai ma trận $A, B: A\times B$.

Yêu cầu:

Các ý tưởng nhân ma trận đa luồng

pthreads_1.cpp

  • Chỉ có master đọc

$p + 1$ threads thì chia ra làm $p$ phần dọc hoặc ngang tùy ý:

                    00000000000000
                    00000000000000
                    11111111111111
                    11111111111111
                    ...
                    pppppppppppppp
                    pppppppppppppp

Mỗi threads sẽ tính một phần như đã chia; tổng độ phức tạp:

  • Thời gian: $O(\frac{n^3}{p})$
  • File pthreads_1.1.cpp là cách cài đặt khác của phương án này

About

Concurrent/Parallel Matrix Exponential

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors