Giter VIP home page Giter VIP logo

graphdrawer's Introduction

GraphDrawer

Java application that draws a graph from an input text file containing an adjacency matrix. The application can also check whether the graph is bipartite or not.

##Open File This function displays a file choosing window control that enables the user to select a text file as an input for the application. The text file should represent an adjacency matrix of a graph using one spaced characters in between the integers. The other buttons will not be available until an input file is selected. Once the input file is selected, the application will begin to construct the Graph object from the adjacency matrix, creating it's nodes and edges and storing them in

##Print Input This function simply prints the adjacency matrix that was read from the input file into the console window.

##Draw Graph This function will display a new window with a white background. A drawing algorithm will then be called to begin drawing the Graph based on the nodes and edges that were constructed. This drawing algorithm uses random x and y coordinates to place the nodes. Because of this, some nodes and edges might overlap, meaning that this algorithm does not create a planar graph. However, since points are randomly chosen, planar graph drawings can occur.

##Check Bipartite This function calls an algorithm that checks whether the graph is bipartite or not and returns a true or false value. If the graph is bipartite then it will call the drawing algorithm previously mentioned, this time however it will draw the graph in a bipartite fashion, meaning that it will separate and draw the two sets with no edges between the same set.

graphdrawer's People

Contributors

aalvrz avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.