diff --git a/serial/serial_gs_pagerank_functions.c b/serial/serial_gs_pagerank_functions.c index 8a94121..88d6d4d 100644 --- a/serial/serial_gs_pagerank_functions.c +++ b/serial/serial_gs_pagerank_functions.c @@ -17,10 +17,20 @@ int pagerank(double ***transitionMatrix, double **pagerankVector, Parameters par double delta, *vectorDifference = (double *) malloc(parameters.numberOfPages * sizeof(double)), *previousPagerankVector = (double *) malloc(parameters.numberOfPages * sizeof(double)), - *convergedPagerankVector = (double *) malloc(parameters.numberOfPages * sizeof(double)); + *convergedPagerankVector = (double *) malloc(parameters.numberOfPages * sizeof(double)), + **linksFromConvergedPages = (double **) malloc(parameters.numberOfPages * sizeof(double *)), + *linksFromConvergedPagesPagerankVector = (double *) malloc(parameters.numberOfPages * sizeof(double)); + bool *converganceMatrix = (bool *) malloc(parameters.numberOfPages * sizeof(bool)); for (int i=0; i