Results 1 to 4 of 4
  1. #1
    jessie is offline Member
    Join Date
    Nov 2010
    Posts
    29
    Rep Power
    0

    Default Creating Bipartite Graphs

    Hello,

    Does anybody know how to create bipartite graphs with Java. I have a text file containing nodes and edges and i want to visualize it as a bipartite graph. i found a java class called Bipartite.java from the web, but i couldn't get a graph out of it.


    Thanks
    Jessie

  2. #2
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    14,048
    Blog Entries
    7
    Rep Power
    23

    Default

    Quote Originally Posted by jessie View Post
    Does anybody know how to create bipartite graphs with Java. I have a text file containing nodes and edges and i want to visualize it as a bipartite graph. i found a java class called Bipartite.java from the web, but i couldn't get a graph out of it.
    The vertexes of a bipartite graph can be divided in two sets A and B such that no vertex a_i and a_j in set A have a connecting edge. Same goes for vertexes b_i and b_j in set B. You have to construct sets A and B from your graph. If a graph isn't bipartite you can't construct those sets A and B.

    kind regards,

    Jos
    The only person who got everything done by Friday was Robinson Crusoe.

  3. #3
    jessie is offline Member
    Join Date
    Nov 2010
    Posts
    29
    Rep Power
    0

    Default

    if i have the two sets A and B how can i generate a bipartite graph from it?

  4. #4
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    14,048
    Blog Entries
    7
    Rep Power
    23

    Default

    Quote Originally Posted by jessie View Post
    if i have the two sets A and B how can i generate a bipartite graph from it?
    Create an edge from each a_i in A to b_j in B. This creates a connected bipartite graph. You can remove edges at will, the graph stays bipartite.

    kind regards,

    Jos
    The only person who got everything done by Friday was Robinson Crusoe.

Similar Threads

  1. Graphs and if else statement
    By MapleLeafRag in forum New To Java
    Replies: 1
    Last Post: 12-03-2009, 11:56 PM
  2. Creating 3D graphs
    By idanfast in forum Advanced Java
    Replies: 1
    Last Post: 09-06-2009, 04:42 PM
  3. Graphs
    By siddharth_s_b in forum NetBeans
    Replies: 1
    Last Post: 05-22-2008, 04:12 AM
  4. Graphs
    By javaplus in forum Advanced Java
    Replies: 1
    Last Post: 12-07-2007, 10:17 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •