NAME

Graph::Line - generate line graphs

SYNOPSIS

    use Graph::Line;
    use Graph::Undirected;

    my $G = Graph::Undirected->new;

    # Greate graph here

    # Get line graph for $G:
    my $L = Graph::Line->new( $G );

DESCRIPTION

Graph::Line generates line graphs for Graph::Undirected objects. Constructor new is the only overridden method, constructing (nondestructively) a line graph for input graph. Both simple and multiedged graphs are supported.

Constructor new accepts additional options hash. Currently only one option is supported, loop_end_vertices, which treats the input graph as having self-loops on pendant vertices, that is, increasing the degrees of vertices having degrees of 1. Thus they are not "lost" during line graph construction. In the resulting line graph these self-loops are represented as instances of Graph::Line::SelfLoopVertex.

SEE ALSO

perl(1)

AUTHORS

Andrius Merkys, <merkys@cpan.org>