Softpedia
 


LINUX CATEGORIES:



GLOBAL PAGES >>
NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Linux Kernel 3.9.3 / 3....
  • LibreOffice 3.6.6 / 4.0.3
  • MPlayer 1.1.1
  • systemd 204
  • Arch Linux 2013.05.01
  • Blender 2.67a
  • KDE Software Compilatio...
  • CrunchBang Linux Stable...
  • Elementary OS 0.1 / 0.2...
  • SystemRescueCd 3.6.0
  • Home > Linux > Programming > Libraries

    Graph::Weighted 0.1301

    Download button

    No screenshots available
    Downloads: 524  View global page NEW!  Tell us about an update
    User Rating:
    Rated by:
    Very Good (4.0/5)
    1 user(s)
    Developer:

    License / Price:

    Last Updated:

    Category:
    Gene Boggs | More programs
    Perl Artistic License / FREE
    August 7th, 2007, 12:05 GMT
    ROOT / Programming / Libraries

     Read user reviews (0)  Refer to a friend  Subscribe

    Graph::Weighted description

    Graph::Weighted is an abstract, weighted graph implementation.

    Graph::Weighted is an abstract, weighted graph implementation.

    SYNOPSIS

    use Graph::Weighted;

    $g = Graph::Weighted->new(
    data => [
    [ 0, 1, 2, 0, 0 ], # A vertex with two edges.
    [ 1, 0, 3, 0, 0 ], # "
    [ 2, 3, 0, 0, 0 ], # "
    [ 0, 0, 1, 0, 0 ], # A vertex with one edge.
    [ 0, 0, 0, 0, 0 ] # A vertex with no edges.
    ]
    );

    $g = Graph::Weighted->new(
    data => {
    weight => {
    a => { b => 1, c => 2 }, # A vertex with two edges.
    b => { a => 1, c => 3 }, # "
    c => { a => 2, b => 3 }, # "
    d => { c => 1 }, # A vertex with one edge.
    e => {} # A vertex with no edges.
    }
    foo => [
    [ 1, 2, 3 ],
    [ 4, 5, 6 ],
    [ 7, 8, 9 ]
    ],
    }
    );

    $g = Graph::Weighted->new(
    data => $Math_Matrix_object,
    retrieve_as => 'ARRAY',
    );

    $data = $g->weight_data;

    $w = $g->graph_weight;

    $w = $g->vertex_weight($v1);
    $w = $g->vertex_weight($v1, $w + 1);

    $w = $g->edge_weight($v1, $v2);
    $w = $g->edge_weight($v1, $v2, $w + 1);

    $vertices = $g->heaviest_vertices;
    $vertices = $g->lightest_vertices;

    $w = $g->max_weight; # Weight of the largest vertices.
    $w = $g->min_weight; # Weight of the smallest vertices.

    # Call the weight methods of the inherited Graph module.
    $x = $g->MST_Kruskal;
    $x = $g->APSP_Floyd_Warshall;
    $x = $g->MST_Prim($p);

    Requirements:

    · Perl



    Product's homepage

      


    TAGS:

    graph implementation | weighted graph | Perl module | weighted | graph | implementation

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM