Example #1
0
void p3()
{
    struct flowNetwork * fN =createGraph();
    maximizeFlowNetwork(fN, 0, 8);
    printAdjMat(fN->adjMatrix);
    deleteFlowNetwork(fN);
}
Example #2
0
void p2(){
    struct flowNetwork * fN =createGraph();
    int i;
    breadthFirstPathSearch(fN, 0, 8);
    printf("Parent Array after Path Search: \n");
    for (i=0; i<NODES; i++) {
        printf("%d ", fN->parent[i]);
    }
    printf("\n");
    deleteFlowNetwork(fN);
}
Example #3
0
void p1(){
    struct flowNetwork * fN =createGraph();
    int i;
    printAdjMat(fN->adjMatrix);
    printf("Parent Array: ");
    for (i=0; i<NODES; i++) {
        printf("%d ", fN->parent[i]);
    }
    printf("\nVisited Nodes Array: ");
    for (i=0; i<NODES; i++) {
        printf("%d ", fN->visitedNodes[i]);
    }
    printf("\n");
    deleteFlowNetwork(fN);
}