Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Java standard library - graph?

Tags:

java

graph

Is there a representation of a graph in Java standard libraries, like there is in the boost library in C++? Is there a graph representation which is a standard in the business?

Edit: by graph, I mean of course the mathematical concept in computer science - graph theory

like image 946
Amir Rachum Avatar asked May 16 '10 22:05

Amir Rachum


People also ask

Does Java have a graph library?

JGraphT is a free Java graph library that provides mathematical graph-theory objects and algorithms. JGraphT supports various types of graphs including: * directed and undirected graphs. * graphs with weighted / unweighted / labeled or any user-defined edges.

Does Java have a graph class?

The Java Graph class relies on an underlying Vertex class with the following behaviors: a constructor that sets data to the passed in inputData and sets edges to an empty ArrayList. an . addEdge() method that takes a vertex and weight and adds an edge to edges.

How do you show graphs in Java?

In Java, plotting of graph is done by using several topics of core Java. For plotting, we use swing, awt, and awt. geom. We use Swing package to use Jlabel, JButtons, and JPanel in our program.

What is a graph library?

A graph is a mathematical concept consisting of nodes and edges. Graphs are used throughout computer science and especially machine learning. The Infer.Net graph library provides data structures for representing graphs and algorithms for operating on graphs.


2 Answers

JUNG

like image 170
mr popo Avatar answered Sep 27 '22 17:09

mr popo


Not in the standard libraries, but there are lots of open source options. JGraphT looks like it probably has what you need.

like image 45
Bill the Lizard Avatar answered Sep 27 '22 18:09

Bill the Lizard