Excercises_GeorgMandl/BSP_3_2to7/main.cpp
2025-12-04 19:04:13 +01:00

29 lines
760 B
C++

#include "bsp_3_lib_bench.h"
#include <iostream>
using namespace std;
int main()
{
benchmark_A(25*1e7,50);
benchmark_A_cblas(25*1e7,50);
benchmark_A_kahan(25*1e7,50);
benchmark_A_norm(25*1e7,50);
benchmark_B(8000,8000,400);
benchmark_B_column(8000,8000,400);
benchmark_B_cblas(8000,8000,400);
benchmark_C(4000,4000,4000,1);
benchmark_C_cblas(4000,4000,4000,10);
benchmark_D(1e4,1e5,15);
cout << "Solving system of linear equations\n";
vector<int> nrhsvec{1,2,4,8,16,32};
for(size_t i=0; i<nrhsvec.size(); ++i)
{
int nrhs = nrhsvec[i];
solver(5000,nrhs);
}
// the time for solving the system does not really depend on the number of the right hand sides
return 0;
}