
// NodeArcCon.h

#ifndef NODE_ARC_CON_H
	#define NODE_ARC_CON_H

	// Static vars
	const int EXAMPLE = 3;	// example type used for setting up problem

	// Main line fns
	int main(int argc, char **argv);
	int NodeArcConnectivity(void);

	// Node-Arc tour building fns
	int BuildTour(int **A_mat, int nrows, int ncols, int *node_vec, int n_nodes, int *tour_vec);
	int CheckRepeatedEntries(int *tour, int ncols);
	int FindBranchNodes(int **A, int i, int ncols, int *branch_node_vec, int &n_branch_nodes);
	int FindCurrentTourPosition(int *tour_vec, int ncols);
	int NumberOfOnes(int **A, int row, int ncols);

	// Setup vectors and matrices fns
	void ResetTourVector(int *tour_vec, int *in_tour_vec, int ncols);
	int SetProblemDimensions(int &nrows, int &ncols);
	int SetupConnectivityMatrix(int **matrix, int nrows, int ncols);
	int DetermineInitialNodeVector(int **A, int nrows, int ncols, int *node_vec, int &n_nodes);
	int SetupInitialTourVector(int *tour_vec, int ncols);
	void SaveTourVector(int *tour_vec, int ncols);
	
	// Printing fns
	int PrintMatrix(int **M, int nrows, int ncols);
	int PrintVector(int *v, int ncols);

#endif

// eof
