Skip to content

mlhoutel/Graphs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

97 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Version Language

Graphs


About The Project

This repository is used during the practice classes of "Graphe et algorithmes" course in IMT Atlantique.

This is a standard maven project so please use the according import option in your IDE (IntelliJ IDEA or Eclipse).

Built With

Exemple

Code

int[][] mat = GraphTools.generateValuedGraphData(10, true, false, true, false, 100001);
GraphTools.afficherMatrix(mat);

DirectedValuedGraph al = new DirectedValuedGraph(mat);

int From = 0;
int To = 9;

try {
    List<DirectedNode> path = ShortestPath(al, al.getNodes().get(From), al.getNodes().get(To));

    System.out.println(path);
    BinaryHeapEdge<DirectedNode> binh = new BinaryHeapEdge<DirectedNode>();

    for (int i = 1; i < path.size(); i++) {
        binh.insert(path.get(i - 1), path.get(i),0);
    }

    DrawDirectedCoveringTree.Display(al, binh);
} catch (Exception e) {
    e.printStackTrace();
}

Screenshots

Dijkstra

Bellman

Prim

Kruskal

Circular

BinaryHeap

BinaryHeapEdge

Build docs

Generate javadoc with mvn javadoc:javadoc

Authors

  • Raphael Painter
  • Maël Lhoutelier