亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? graph.pod

?? nasm早期的源代碼,比較簡單是學習匯編和編譯原理的好例子
?? POD
?? 第 1 頁 / 共 5 頁
字號:
=pod

=head1 NAME

Graph - graph data structures and algorithms

=head1 SYNOPSIS

	use Graph;
	my $g0 = Graph->new;             # A directed graph.

	use Graph::Directed;
	my $g1 = Graph::Directed->new;   # A directed graph.

	use Graph::Undirected;
	my $g2 = Graph::Undirected->new; # An undirected graph.

        $g->add_edge(...);
        $g->has_edge(...)
        $g->delete_edge(...);

        $g->add_vertex(...);
        $g->has_vertex(...);
        $g->delete_vertex(...);

        $g->vertices(...)
        $g->edges(...)

        # And many, many more, see below.

=head1 DESCRIPTION

=head2 Non-Description

This module is not for B<drawing> any sort of I<graphics>, business or
otherwise.

=head2 Description

Instead, this module is for creating I<abstract data structures>
called graphs, and for doing various operations on those.

=head2 Perl 5.6.0 minimum

The implementation depends on a Perl feature called "weak references"
and Perl 5.6.0 was the first to have those.

=head2 Constructors

=over 4

=item new

Create an empty graph.

=item Graph->new(%options)

The options are a hash with option names as the hash keys and the option
values as the hash values.

The following options are available:

=over 8

=item *

directed

A boolean option telling that a directed graph should be created.
Often somewhat redundant because a directed graph is the default
for the Graph class or one could simply use the C<new()> constructor
of the Graph::Directed class.

You can test the directness of a graph with $g->is_directed() and
$g->is_undirected().

=item *

undirected

A boolean option telling that an undirected graph should be created.
One could also use the C<new()> constructor the Graph::Undirected class
instead.

Note that while often it is possible to think undirected graphs as
bidirectional graphs, or as directed graphs with edges going both ways,
in this module directed graphs and undirected graphs are two different
things that often behave differently.

You can test the directness of a graph with $g->is_directed() and
$g->is_undirected().

=item *

refvertexed

If you want to use references (including Perl objects) as vertices.

=item *

unionfind

If the graph is undirected, you can specify the C<unionfind> parameter
to use the so-called union-find scheme to speed up the computation of
I<connected components> of the graph (see L</is_connected>,
L</connected_components>, L</connected_component_by_vertex>,
L</connected_component_by_index>, and L</same_connected_components>).
If C<unionfind> is used, adding edges (and vertices) becomes slower,
but connectedness queries become faster.  You can test a graph for
"union-findness" with

=over 8

=item has_union_find

    has_union_find

=back

=item *

vertices

An array reference of vertices to add.

=item *

edges

An array reference of array references of edge vertices to add.

=back

=item copy

=item copy_graph

    my $c = $g->copy_graph;

Create a shallow copy of the structure (vertices and edges) of the graph.
If you want a deep copy that includes attributes, see L</deep_copy>.
The copy will have the same directedness as the original.

=item deep_copy

=item deep_copy_graph

    my $c = $g->deep_copy_graph;

Create a deep copy of the graph (vertices, edges, and attributes) of
the graph.  If you want a shallow copy that does not include attributes,
see L</copy>.  (Uses Data::Dumper behind the scenes.  Note that copying
code references only works with Perls 5.8 or later, and even then only
if B::Deparse can reconstruct your code.)

=item undirected_copy

=item undirected_copy_graph

    my $c = $g->undirected_copy_graph;

Create an undirected shallow copy (vertices and edges) of the directed graph
so that for any directed edge (u, v) there is an undirected edge (u, v).

=item directed_copy

=item directed_copy_graph

    my $c = $g->directed_copy_graph;

Create a directed shallow copy (vertices and edges) of the undirected graph
so that for any undirected edge (u, v) there are two directed edges (u, v)
and (v, u).

=item transpose

=item transpose_graph

    my $t = $g->transpose_graph;

Create a directed shallow transposed copy (vertices and edges) of the
directed graph so that for any directed edge (u, v) there is a directed
edge (v, u).

You can also transpose a single edge with

=over 8

=item transpose_edge

    $g->transpose_edge($u, $v)

=back

=item complete_graph

=item complete

    my $c = $g->complete_graph;

Create a complete graph that has the same vertices as the original graph.
A complete graph has an edge between every pair of vertices.

=item complement_graph

=item complement

    my $c = $g->complement_graph;

Create a complement graph that has the same vertices as the original graph.
A complement graph has an edge (u,v) if and only if the original
graph does not have edge (u,v).

=back

See also L</random_graph> for a random constructor.

=head2 Basics

=over 4

=item add_vertex

    $g->add_vertex($v)

Add the vertex to the graph.  Returns the graph.

By default idempotent, but a graph can be created I<countvertexed>.

A vertex is also known as a I<node>.

Adding C<undef> as vertex is not allowed.

Note that unless you have isolated vertices (or I<countvertexed>
vertices), you do not need to explicitly use C<add_vertex> since
L</add_edge> will implicitly add its vertices.

=item add_edge

    $g->add_edge($u, $v)

Add the edge to the graph.  Implicitly first adds the vertices if the
graph does not have them.  Returns the graph.

By default idempotent, but a graph can be created I<countedged>.

An edge is also known as an I<arc>.

=item has_vertex

    $g->has_vertex($v)

Return true if the vertex exists in the graph, false otherwise.

=item has_edge

    $g->has_edge($u, $v)

Return true if the edge exists in the graph, false otherwise.

=item delete_vertex

    $g->delete_vertex($v)

Delete the vertex from the graph.  Returns the graph, even
if the vertex did not exist in the graph.

If the graph has been created I<multivertexed> or I<countvertexed>
and a vertex has been added multiple times, the vertex will require
at least an equal number of deletions to become completely deleted.

=item delete_vertices

    $g->delete_vertices($v1, $v2, ...)

Delete the vertices from the graph.  Returns the graph.

If the graph has been created I<multivertexed> or I<countvertexed>
and a vertex has been added multiple times, the vertex will require
at least an equal number of deletions to become completely deleteted.

=item delete_edge

    $g->delete_edge($u, $v)

Delete the edge from the graph.  Returns the graph, even
if the edge did not exist in the graph.

If the graph has been created I<multivertexed> or I<countedged>
and an edge has been added multiple times, the edge will require
at least an equal number of deletions to become completely deleted.

=item delete_edges

    $g->delete_edges($u1, $v1, $u2, $v2, ...)

Delete the edges from the graph.  Returns the graph.

If the graph has been created I<multivertexed> or I<countedged>
and an edge has been added multiple times, the edge will require
at least an equal number of deletions to become completely deleted.

=back

=head2 Displaying

Graphs have stringification overload, so you can do things like

    print "The graph is $g\n"

One-way (directed, unidirected) edges are shown as '-', two-way
(undirected, bidirected) edges are shown as '='.  If you want to,
you can call the stringification via the method

=over 4

=item stringify

=back

=head2 Comparing

Testing for equality can be done either by the overloaded C<eq>
operator

    $g eq "a-b,a-c,d"

or by the method

=over 4

=item eq

    $g->eq("a-b,a-c,d")

=back

The equality testing compares the stringified forms, and therefore it
assumes total equality, not isomorphism: all the vertices must be
named the same, and they must have identical edges between them.

For unequality there are correspondingly the overloaded C<ne>
operator and the method

=over 4

=item ne

    $g->ne("a-b,a-c,d")

=back

See also L</Isomorphism>.

=head2 Paths and Cycles

Paths and cycles are simple extensions of edges: paths are edges
starting from where the previous edge ended, and cycles are paths
returning back to the start vertex of the first edge.

=over 4

=item add_path

   $g->add_path($a, $b, $c, ..., $x, $y, $z)

Add the edges $a-$b, $b-$c, ..., $x-$y, $y-$z to the graph.
Returns the graph.

=item has_path

   $g->has_path($a, $b, $c, ..., $x, $y, $z)

Return true if the graph has all the edges $a-$b, $b-$c, ..., $x-$y, $y-$z,
false otherwise.

=item delete_path

   $g->delete_path($a, $b, $c, ..., $x, $y, $z)

Delete all the edges edges $a-$b, $b-$c, ..., $x-$y, $y-$z
(regardless of whether they exist or not).  Returns the graph.

=item add_cycle

   $g->add_cycle($a, $b, $c, ..., $x, $y, $z)

Add the edges $a-$b, $b-$c, ..., $x-$y, $y-$z, and $z-$a to the graph.
Returns the graph.

=item has_cycle

   $g->has_cycle($a, $b, $c, ..., $x, $y, $z)

Return true if the graph has all the edges $a-$b, $b-$c, ..., $x-$y, $y-$z,
and $z-$a, false otherwise.

B<NOTE:> This does not I<detect> cycles, see L</has_a_cycle> and
L</find_a_cycle>.

=item delete_cycle

   $g->delete_cycle($a, $b, $c, ..., $x, $y, $z)

Delete all the edges edges $a-$b, $b-$c, ..., $x-$y, $y-$z, and $z-$a
(regardless of whether they exist or not).  Returns the graph.

=item has_a_cycle

   $g->has_a_cycle

Returns true if the graph has a cycle, false if not.

=item find_a_cycle

   $g->find_a_cycle

Returns a cycle if the graph has one (as a list of vertices), an empty
list if no cycle can be found.

Note that this just returns the vertices of I<a cycle>: not any
particular cycle, just the first one it finds.  A repeated call
might find the same cycle, or it might find a different one, and
you cannot call this repeatedly to find all the cycles.

=back

=head2 Graph Types

=over 4

=item is_simple_graph

    $g->is_simple_graph

Return true if the graph has no multiedges, false otherwise.

=item is_pseudo_graph

    $g->is_pseudo_graph

Return true if the graph has any multiedges or any self-loops,
false otherwise.

=item is_multi_graph

    $g->is_multi_graph

Return true if the graph has any multiedges but no self-loops,
false otherwise.

=item is_directed_acyclic_graph

=item is_dag

    $g->is_directed_acyclic_graph
    $g->is_dag

Return true if the graph is directed and acyclic, false otherwise.

=item is_cyclic

    $g->is_cyclic

Return true if the graph is cyclic (contains at least one cycle).
(This is identical to C<has_a_cycle>.)

To find at least that one cycle, see L</find_a_cycle>.

=item is_acyclic

Return true if the graph is acyclic (does not contain any cycles).

=back

To find a cycle, use L<find_a_cycle>.

=head2 Transitivity

=over 4

=item is_transitive

    $g->is_transitive

Return true if the graph is transitive, false otherwise.

=item TransitiveClosure_Floyd_Warshall

=item transitive_closure

    $tcg = $g->TransitiveClosure_Floyd_Warshall

Return the transitive closure graph of the graph.

=back

You can query the reachability from $u to $v with

=over 4

=item is_reachable

    $tcg->is_reachable($u, $v)

=back

See L<Graph::TransitiveClosure> for more information about creating
and querying transitive closures.

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产欧美一区二区在线| 国产日韩欧美a| 色综合天天综合网国产成人综合天 | 99精品热视频| 91婷婷韩国欧美一区二区| 成人一区二区三区| 成人精品鲁一区一区二区| 国产激情精品久久久第一区二区| 久久er精品视频| 加勒比av一区二区| 成人黄色a**站在线观看| 91视频91自| 3d动漫精品啪啪1区2区免费 | 狠狠色丁香久久婷婷综| 国产一区在线观看视频| 成人午夜伦理影院| 欧美在线999| 日韩一区二区麻豆国产| 久久久精品天堂| 国产精品麻豆久久久| 亚洲一区二区三区在线播放| 日本一不卡视频| 国产成人精品1024| 欧美性xxxxxx少妇| ww亚洲ww在线观看国产| 亚洲欧美日韩国产综合在线| 日韩精品欧美成人高清一区二区| 精品一区二区三区久久久| 国产乱妇无码大片在线观看| 欧洲精品一区二区| wwwwxxxxx欧美| 亚洲成人免费视频| 国产成人99久久亚洲综合精品| 91久久人澡人人添人人爽欧美 | 成人妖精视频yjsp地址| 欧美主播一区二区三区| 国产日产精品1区| 天天综合色天天综合| 成人动漫在线一区| 欧美一区二区三区播放老司机| 中文字幕第一区第二区| 日韩中文字幕av电影| 99久久精品国产毛片| 欧美电影精品一区二区| 亚洲午夜在线视频| av激情综合网| 欧美精品一区二区精品网| 亚洲综合久久久久| 成人av在线网| 国产偷国产偷精品高清尤物| 青青草伊人久久| 欧美日韩一区二区三区不卡| 自拍偷拍亚洲激情| 成人丝袜高跟foot| 亚洲精品一区二区三区精华液| 亚洲在线视频免费观看| 一本久道中文字幕精品亚洲嫩 | 成人a级免费电影| 日韩一区二区免费电影| 天天影视色香欲综合网老头| 一本色道久久综合精品竹菊| 日本一区二区动态图| 国产在线一区二区| 日韩欧美激情在线| 久久成人精品无人区| 91精品国产综合久久婷婷香蕉| 亚洲动漫第一页| 欧美日韩高清一区二区三区| 一区二区三区波多野结衣在线观看| 成人激情黄色小说| 国产精品久久精品日日| 暴力调教一区二区三区| 欧美国产激情二区三区| 成人av电影在线| 国产精品你懂的| eeuss鲁片一区二区三区在线看| 国产精品久久久久一区二区三区 | 欧美男女性生活在线直播观看| 亚洲精品国产视频| 在线亚洲免费视频| 亚洲一区二区精品久久av| 欧美日韩亚洲不卡| 日欧美一区二区| 欧美成人在线直播| 狠狠色丁香婷综合久久| 国产欧美一区二区三区鸳鸯浴 | 亚洲韩国一区二区三区| 欧美最猛性xxxxx直播| 首页国产欧美久久| 精品国产免费久久| 丰满少妇在线播放bd日韩电影| 成人免费在线观看入口| 欧美主播一区二区三区| 久久精品国产77777蜜臀| 2021中文字幕一区亚洲| 成人av动漫网站| 午夜精品久久久久久久久| 精品女同一区二区| 97se亚洲国产综合在线| 三级一区在线视频先锋 | 欧美性受极品xxxx喷水| 全国精品久久少妇| 中文字幕一区二区三区av| 欧美乱熟臀69xxxxxx| 国产精品91xxx| 亚洲成人资源在线| 日本一区二区免费在线观看视频| 91精品91久久久中77777| 日韩精品1区2区3区| 国产色一区二区| 正在播放亚洲一区| 成人免费视频国产在线观看| 性做久久久久久免费观看| 国产日韩欧美综合在线| 欧美三级资源在线| 福利一区二区在线| 人人爽香蕉精品| 一区二区三区丝袜| 国产精品日韩成人| 日韩视频一区在线观看| 一本一道久久a久久精品综合蜜臀| 六月丁香综合在线视频| 亚洲午夜久久久久| 国产精品国产自产拍高清av| 欧美精品一区二| 欧美群妇大交群中文字幕| 97超碰欧美中文字幕| 国产精品一二二区| 九九热在线视频观看这里只有精品| 亚洲自拍偷拍网站| 亚洲欧洲中文日韩久久av乱码| 久久精品在线观看| 精品国产1区二区| 日韩欧美卡一卡二| 91精品国产欧美一区二区| 欧美色精品在线视频| 色婷婷精品大视频在线蜜桃视频| 国产一区二区三区在线观看精品 | 久久免费精品国产久精品久久久久 | 99国产欧美久久久精品| 国产.精品.日韩.另类.中文.在线.播放| 亚洲高清视频的网址| 亚洲精品成人悠悠色影视| 亚洲视频免费观看| 综合激情网...| 亚洲欧美成人一区二区三区| 亚洲视频一区二区免费在线观看| 欧美国产成人精品| 国产精品私人影院| 中文字幕一区二区三区视频| 国产精品九色蝌蚪自拍| 自拍偷拍国产亚洲| 亚洲三级在线播放| 亚洲精品久久久蜜桃| 一区二区三区四区高清精品免费观看| 亚洲色图一区二区| 亚洲第一福利一区| 日韩国产精品久久久久久亚洲| 奇米色777欧美一区二区| 久久精品国产精品亚洲精品| 国产又黄又大久久| 菠萝蜜视频在线观看一区| 91在线免费播放| 91蝌蚪porny九色| 欧美影院一区二区三区| 这里是久久伊人| 久久亚洲综合色| 亚洲欧洲色图综合| 图片区日韩欧美亚洲| 国产一区二区三区电影在线观看 | 色成人在线视频| 欧美一区二区黄色| 中文一区二区完整视频在线观看| 国产精品久久久久天堂| 亚洲国产综合色| 久久精品国产一区二区三区免费看| 国产精品18久久久久久vr | 亚洲午夜三级在线| 狠狠色丁香久久婷婷综合_中| 成人av免费在线播放| 欧美在线视频全部完| 精品久久久久一区二区国产| 亚洲特黄一级片| 美美哒免费高清在线观看视频一区二区| 国产福利电影一区二区三区| 色哟哟日韩精品| 久久久久免费观看| 亚洲午夜影视影院在线观看| 国产麻豆精品theporn| 欧洲国产伦久久久久久久| 久久精品人人爽人人爽| 亚洲成人久久影院| 波多野结衣中文字幕一区| 欧美一区二区国产| 夜夜嗨av一区二区三区中文字幕 | 不卡一区二区中文字幕| 日韩精品一区二区三区swag | 日本亚洲一区二区| 91麻豆自制传媒国产之光| 国产午夜亚洲精品不卡|