Graph::Matrix3pm
Create and manipulate a v x v matrix of graph g
Usage
use Graph::Matrix;use Graph::Directed;my $g = Graph::Directed->new;$g->add_...(); # build $gmy $m = Graph::Matrix->new($g);$m->get($u, $v)$s->get($u, $v, $val)
Overview
This module is meant for internal use by the Graph module.
Class Methods
- new($g)
-
Construct a new Matrix from the Graph
$g.
Object Methods
- get($u, $v)
-
Return the value at the edge from
$uto$v.
- set($u, $v, $val)
-
Set the edge from
$uto$vto value$val.
- stringify
-
Returns a string roughly representing the matrix, with the
$udown the left-hand side, and$vacross the top.
Author and copyright
Jarkko Hietaniemi [email protected]
Releases
10 releases since Debian 4.0 (Etch); the text changed 7 times.