Closed ryant26 closed 8 years ago
This goes with #3
Didn't make these signatures correctly when opened the issue.
double get_element(double*A, int row_size, int i, int j);
void set_element(double*A, int row_size, int i, int j, double value);
// The matrix argument would be just a pointer
// That is, it has not already been malloc'd
// mallocing the memory would be the job of create_matrix
void create_matrix(double ***matrix, int height, int width);
I did a quick and dirty implementation of this right in utilities.Needs some cleaning up and documentation but you can take a look at it if you are stuck at all.
Also this version of "init_edge_matrix" inserts the number of outgoing edges.
I apologize if you got very far on this, I didn't mean to step on your toes. But I pretty much had to implement this to move forward with testing the algorithm so I'm just going to close this.
The way we have worked with matrices in this class so far wont work well with MPI's communication functionality. We need to store the matrix in row major form (a way to store a matrix in 1 contiguous block of memory, that is, a single array).
The supporting operations we need for this are:
The utility to read in matrices would have to be adapted to use this.