From 1aaa4028c8911a995d4e6089bd62f1b686c17d88 Mon Sep 17 00:00:00 2001 From: mtzikara Date: Wed, 3 Oct 2018 10:50:28 +0200 Subject: [PATCH] Delete serial_gs_pagerank.c --- serial/serial_gs_pagerank.c | 42 ------------------------------------- 1 file changed, 42 deletions(-) delete mode 100644 serial/serial_gs_pagerank.c diff --git a/serial/serial_gs_pagerank.c b/serial/serial_gs_pagerank.c deleted file mode 100644 index ccf25d1..0000000 --- a/serial/serial_gs_pagerank.c +++ /dev/null @@ -1,42 +0,0 @@ -#include - -#include "serial_gs_pagerank_functions.h" - -struct timeval startwtime, endwtime; - -int main(int argc, char **argv) { - CsrSparseMatrix transitionMatrix = initCsrSparseMatrix(); - double *pagerankVector; - bool convergenceStatus; - Parameters parameters; - - parseArguments(argc, argv, ¶meters); - - initialize(&transitionMatrix, &pagerankVector, ¶meters); - - // Starts wall-clock timer - gettimeofday (&startwtime, NULL); - - int iterations = pagerank(&transitionMatrix, &pagerankVector, - &convergenceStatus, parameters); - if (parameters.verbose) { - printf(ANSI_COLOR_YELLOW "\n----- RESULTS -----\n" ANSI_COLOR_RESET); - if (convergenceStatus) { - printf(ANSI_COLOR_GREEN "Pagerank converged after %d iterations!\n" \ - ANSI_COLOR_RESET, iterations); - } else { - printf(ANSI_COLOR_RED "Pagerank did not converge after max number of" \ - " iterations (%d) was reached!\n" ANSI_COLOR_RESET, iterations); - } - } - - // Stops wall-clock timer - gettimeofday (&endwtime, NULL); - double seq_time = (double)((endwtime.tv_usec - startwtime.tv_usec)/1.0e6 + - endwtime.tv_sec - startwtime.tv_sec); - printf("%s wall clock time = %f\n","Pagerank (Gauss-Seidel method), serial implementation", - seq_time); - - free(pagerankVector); - destroyCsrSparseMatrix(&transitionMatrix); -}