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

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

?? graph.pod

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

The result weights of vertices can be retrieved from the result graph by

	my $w = $sptg->get_vertex_attribute($v, 'weight');

The predecessor vertex of a vertex in the result graph
can be retrieved by

	my $u = $sptg->get_vertex_attribute($v, 'p');

("A successor vertex" cannot be retrieved as simply because a single
vertex can have several successors.  You can first find the
C<neighbors()> vertices and then remove the predecessor vertex.)

If you want to find the shortest path between two vertices,
see L</SP_Dijkstra>.

=item SSSP_Dijkstra

=item single_source_shortest_paths

Aliases for SPT_Dijkstra.

=item SP_Dijkstra

    @path = $g->SP_Dijkstra($u, $v)

Return the vertices in the shortest path in the graph $g between the
two vertices $u, $v.  If no path can be found, an empty list is returned.

Uses SPT_Dijkstra().

=item SPT_Dijkstra_clear_cache

    $g->SPT_Dijkstra_clear_cache

See L</"Clearing cached results">.

=item SPT_Bellman_Ford

    $sptg = $g->SPT_Bellman_Ford(%opt)

Return as a graph the single-source shortest paths of the graph using
Bellman-Ford's algorithm.  The graph can contain negative edges but
not negative cycles (negative cycles cause the algorithm to abort
with an error message C<Graph::SPT_Bellman_Ford: negative cycle exists/>).

You can choose the start vertex of the result with either a single
vertex argument or with $opt{ first_root }, otherwise a random vertex
is chosen.

B<NOTE>: note that all the vertices might not be reachable from the
selected (explicit or random) start vertex.

The start vertex is be available as the graph attribute
C<SPT_Bellman_Ford_root>).

The result weights of vertices can be retrieved from the result graph by

	my $w = $sptg->get_vertex_attribute($v, 'weight');

The predecessor vertex of a vertex in the result graph
can be retrieved by

	my $u = $sptg->get_vertex_attribute($v, 'p');

("A successor vertex" cannot be retrieved as simply because a single
vertex can have several successors.  You can first find the
C<neighbors()> vertices and then remove the predecessor vertex.)

If you want to find the shortes path between two vertices,
see L</SP_Bellman_Ford>.

=item SSSP_Bellman_Ford

Alias for SPT_Bellman_Ford.

=item SP_Bellman_Ford

    @path = $g->SP_Bellman_Ford($u, $v)

Return the vertices in the shortest path in the graph $g between the
two vertices $u, $v.  If no path can be found, an empty list is returned.

Uses SPT_Bellman_Ford().

=item SPT_Bellman_Ford_clear_cache

    $g->SPT_Bellman_Ford_clear_cache

See L</"Clearing cached results">.

=back

=head2 All-Pairs Shortest Paths (APSP)

For either a directed or an undirected graph, return the APSP object
describing all the possible paths between any two vertices of the
graph.  If no weight is defined for an edge, 1 (one) is assumed.

=over 4

=item APSP_Floyd_Warshall

=item all_pairs_shortest_paths

    my $apsp = $g->APSP_Floyd_Warshall(...);

Return the all-pairs shortest path object computed from the graph
using Floyd-Warshall's algorithm.  The length of a path between two
vertices is the sum of weight attribute of the edges along the
shortest path between the two vertices.  If no weight attribute name
is specified explicitly

    $g->APSP_Floyd_Warshall(attribute_name => 'height');

the attribute C<weight> is assumed.

B<If an edge has no defined weight attribute, the value of one is
assumed when getting the attribute.>

Once computed, you can query the APSP object with

=over 8

=item path_length

    my $l = $apsp->path_length($u, $v);

Return the length of the shortest path between the two vertices.

=item path_vertices

    my @v = $apsp->path_vertices($u, $v);

Return the list of vertices along the shortest path.

=item path_predecessor

   my $u = $apsp->path_predecessor($v);

Returns the predecessor of vertex $v in the all-pairs shortest paths.

=back

=over 8

=item average_path_length

    my $apl = $g->average_path_length; # All vertex pairs.

    my $apl = $g->average_path_length($u); # From $u.
    my $apl = $g->average_path_length($u, undef); # From $u.

    my $apl = $g->average_path_length($u, $v); # From $u to $v.

    my $apl = $g->average_path_length(undef, $v); # To $v.

Return the average (shortest) path length over all the vertex pairs of
the graph, from a vertex, between two vertices, and to a vertex.

=item longest_path

    my @lp = $g->longest_path;
    my $lp = $g->longest_path;

In scalar context return the I<longest shortest> path length over all
the vertex pairs of the graph.  In list context return the vertices
along a I<longest shortest> path.  Note that there might be more than
one such path; this interfaces return a random one of them.

=item diameter

=item graph_diameter

    my $gd = $g->diameter;

The longest path over all the vertex pairs is known as the
I<graph diameter>.

=item shortest_path

    my @sp = $g->shortest_path;
    my $sp = $g->shortest_path;

In scalar context return the shortest length over all the vertex pairs
of the graph.  In list context return the vertices along a shortest
path.  Note that there might be more than one such path; this
interface returns a random one of them.

=item radius

    my $gr = $g->radius;

The I<shortest longest> path over all the vertex pairs is known as the
I<graph radius>.  See also L</diameter>.

=item center_vertices

=item centre_vertices

    my @c = $g->center_vertices;
    my @c = $g->center_vertices($delta);

The I<graph center> is the set of vertices for which the I<vertex
eccentricity> is equal to the I<graph radius>.  The vertices are
returned in random order.  By specifying a delta value you can widen
the criterion from strict equality (handy for non-integer edge weights).

=item vertex_eccentricity

    my $ve = $g->vertex_eccentricity($v);

The longest path to a vertex is known as the I<vertex eccentricity>.
If the graph is unconnected, returns Inf.

=back

You can walk through the matrix of the shortest paths by using

=over 4

=item for_shortest_paths

    $n = $g->for_shortest_paths($callback)

The number of shortest paths is returned (this should be equal to V*V).
The $callback is a sub reference that receives four arguments:
the transitive closure object from Graph::TransitiveClosure, the two
vertices, and the index to the current shortest paths (0..V*V-1).

=back

=back

=head2 Clearing cached results

For many graph algorithms there are several different but equally valid
results.  (Pseudo)Randomness is used internally by the Graph module to
for example pick a random starting vertex, and to select random edges
from a vertex.

For efficiency the computed result is often cached to avoid
recomputing the potentially expensive operation, and this also gives
additional determinism (once a correct result has been computed, the
same result will always be given).

However, sometimes the exact opposite is desireable, and the possible
alternative results are wanted (within the limits of the pseudorandomness:
not all the possible solutions are guaranteed to be returned, usually only
a subset is retuned).  To undo the caching, the following methods are
available:

=over 4

=item *

connectivity_clear_cache

Affects L</connected_components>, L</connected_component_by_vertex>,
L</connected_component_by_index>, L</same_connected_components>,
L</connected_graph>, L</is_connected>, L</is_weakly_connected>,
L</weakly_connected_components>, L</weakly_connected_component_by_vertex>,
L</weakly_connected_component_by_index>, L</same_weakly_connected_components>,
L</weakly_connected_graph>.

=item *

biconnectivity_clear_cache

Affects L</biconnected_components>,
L</biconnected_component_by_vertex>,
L</biconnected_component_by_index>, L</is_edge_connected>,
L</is_edge_separable>, L</articulation_points>, L</cut_vertices>,
L</is_biconnected>, L</biconnected_graph>,
L</same_biconnected_components>, L</bridges>.

=item *

strong_connectivity_clear_cache

Affects L</strongly_connected_components>,
L</strongly_connected_component_by_vertex>,
L</strongly_connected_component_by_index>,
L</same_strongly_connected_components>, L</is_strongly_connected>,
L</strongly_connected>, L</strongly_connected_graph>.

=item *

SPT_Dijkstra_clear_cache

Affects L</SPT_Dijkstra>, L</SSSP_Dijkstra>, L</single_source_shortest_paths>,
L</SP_Dijkstra>.

=item *

SPT_Bellman_Ford_clear_cache

Affects L</SPT_Bellman_Ford>, L</SSSP_Bellman_Ford>, L</SP_Bellman_Ford>.

=back

Note that any such computed and cached results are of course always
automatically discarded whenever the graph is modified.

=head2 Random

You can either ask for random elements of existing graphs or create
random graphs.

=over 4

=item random_vertex

    my $v = $g->random_vertex;

Return a random vertex of the graph, or undef if there are no vertices.

=item random_edge

    my $e = $g->random_edge;

Return a random edge of the graph as an array reference having the
vertices as elements, or undef if there are no edges.

=item random_successor

    my $v = $g->random_successor($v);

Return a random successor of the vertex in the graph, or undef if there
are no successors.

=item random_predecessor

    my $u = $g->random_predecessor($v);

Return a random predecessor of the vertex in the graph, or undef if there
are no predecessors.

=item random_graph

    my $g = Graph->random_graph(%opt);

Construct a random graph.  The I<%opt> B<must> contain the C<vertices>
argument

    vertices => vertices_def

where the I<vertices_def> is one of

=over 8

=item *

an array reference where the elements of the array reference are the
vertices

=item *

a number N in which case the vertices will be integers 0..N-1

=back

=back

The %opt may have either of the argument C<edges> or the argument
C<edges_fill>.  Both are used to define how many random edges to
add to the graph; C<edges> is an absolute number, while C<edges_fill>
is a relative number (relative to the number of edges in a complete
graph, C).  The number of edges can be larger than C, but only if the
graph is countedged.  The random edges will not include self-loops.
If neither C<edges> nor C<edges_fill> is specified, an C<edges_fill>
of 0.5 is assumed.

If you want repeatable randomness (what is an oxymoron?)
you can use the C<random_seed> option:

    $g = Graph->random_graph(vertices => 10, random_seed => 1234);

As this uses the standard Perl srand(), the usual caveat applies:
use it sparingly, and consider instead using a single srand() call
at the top level of your application.

The default random distribution of edges is flat, that is, any pair of
vertices is equally likely to appear.  To define your own distribution,
use the C<random_edge> option:

    $g = Graph->random_graph(vertices => 10, random_edge => \&d);

where C<d> is a code reference receiving I<($g, $u, $v, $p)> as
parameters, where the I<$g> is the random graph, I<$u> and I<$v> are
the vertices, and the I<$p> is the probability ([0,1]) for a flat
distribution.  It must return a probability ([0,1]) that the vertices
I<$u> and I<$v> have an edge between them.  Note that returning one
for a particular pair of vertices doesn't guarantee that the edge will
be present in the resulting graph because the required number of edges
might be reached before that particular pair is tested for the
possibility of an edge.  Be very careful to adjust also C<edges>
or C<edges_fill> so that there is a possibility of the filling process
terminating.

=head2 Attributes

You can attach free-form attributes (key-value pairs, in effect a full
Perl hash) to each vertex, edge, and the graph itself.

Note that attaching attributes does slow down some other operations
on the graph by a factor of three to ten.  For example adding edge
attributes does slow down anything that walks through all the edges.

For vertex attributes:

=over 4

=item set_vertex_attribute

    $g->set_vertex_attribute($v, $name, $value)

Set the named vertex attribute.

If the vertex does not exist, the set_...() will create it, and the
other vertex attribute methods will return false or empty.

B<NOTE: any attributes beginning with an underscore/underline (_)
are reserved for the internal use of the Graph module.>

=item get_vertex_attribute

    $value = $g->get_vertex_attribute($v, $name)

Return the named vertex attribute.

=item has_vertex_attribute

    $g->has_vertex_attribute($v, $name)

Return true if the vertex has an attribute, false if not.

=item delete_vertex_attribute

    $g->delete_vertex_attribute($v, $name)

Delete the named vertex attribute.

=item set_vertex_attributes

    $g->set_vertex_attributes($v, $attr)

Set all the attributes of the vertex from the anonymous hash $attr.

B<NOTE>: any attributes beginning with an underscore (C<_>) are
reserved for the internal use of the Graph module.

=item get_vertex_attributes

    $attr = $g->get_vertex_attributes($v)

Return all the attributes of the vertex as an anonymous hash.

=item get_vertex_attribute_names

    @name = $g->get_vertex_attribute_names($v)

Return the names of vertex attributes.

=item get_vertex_attribute_values

    @value = $g->get_vertex_attribute_values($v)

Return the values of vertex attributes.

=item has_vertex_attributes

    $g->has_vertex_attributes($v)

Return true if the vertex has any attributes, false if not.

=item delete_vertex_attributes

    $g->delete_vertex_attributes($v)

Delete all the attributes of the named vertex.

=back

If you are using multivertices, use the I<by_id> variants:

=over 4

=item set_vertex_attribute_by_id

=item get_vertex_attribute_by_id

=item has_vertex_attribute_by_id

=item delete_vertex_attribute_by_id

=item set_vertex_attributes_by_id

=item get_vertex_attributes_by_id

=item get_vertex_attribute_names_by_id

=item get_vertex_attribute_values_by_id

=item has_vertex_attributes_by_id

=item delete_vertex_attributes_by_id

    $g->set_vertex_attribute_by_id($v, $id, $name, $value)

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产一区不卡视频| 色综合色狠狠综合色| 日日嗨av一区二区三区四区| 日韩经典中文字幕一区| 成人深夜福利app| 日韩一级完整毛片| 亚洲欧美电影一区二区| 国产毛片精品视频| 欧美人xxxx| 亚洲精品一二三| 国产一区二区女| 91精品国产综合久久精品| 1024国产精品| 国产成人一级电影| 久久婷婷综合激情| 日韩电影在线免费看| 色94色欧美sute亚洲线路一ni| 国产精品久久久一本精品| 日韩精品视频网站| 欧美三级电影在线观看| 国产精品乱码一区二三区小蝌蚪| 午夜精品一区二区三区三上悠亚| 成人av片在线观看| 欧美激情一区二区三区在线| 日韩国产精品久久久久久亚洲| 日本丶国产丶欧美色综合| 国产精品美女久久久久aⅴ| 国产一区二区主播在线| 欧美日韩成人高清| 亚洲一区二区欧美激情| 91丝袜呻吟高潮美腿白嫩在线观看| 欧美一级日韩不卡播放免费| 亚洲一级二级在线| a美女胸又www黄视频久久| 久久亚洲综合色一区二区三区| 麻豆视频观看网址久久| 日韩精品一区国产麻豆| 六月丁香婷婷久久| 久久久久九九视频| 丁香激情综合国产| 久久精品欧美日韩| jizzjizzjizz欧美| 中文字幕精品一区二区精品绿巨人| 丁香婷婷综合网| 成人免费在线播放视频| 一本大道久久a久久精二百| 亚洲美女偷拍久久| 欧美日韩夫妻久久| 视频一区中文字幕| 精品免费日韩av| 国产精品18久久久久久久久| 久久免费看少妇高潮| 不卡的电影网站| 亚洲国产一区二区三区| 制服丝袜激情欧洲亚洲| 欧美a一区二区| 精品少妇一区二区三区免费观看 | 国产精品一区二区在线观看不卡| 国产欧美精品日韩区二区麻豆天美| 成人午夜电影网站| 一区av在线播放| 日韩一级免费观看| 成人免费电影视频| 亚欧色一区w666天堂| 久久日韩精品一区二区五区| 99久久国产综合精品麻豆| 亚洲国产一区二区在线播放| 91麻豆精品国产自产在线观看一区| 久久成人久久鬼色| 亚洲欧美乱综合| 欧美精品一区二| 91小宝寻花一区二区三区| 蜜臀久久99精品久久久久久9 | 麻豆成人91精品二区三区| 国产91精品在线观看| 欧美色图天堂网| 欧美影院午夜播放| 久久精品人人做| 樱桃国产成人精品视频| 蓝色福利精品导航| 69久久夜色精品国产69蝌蚪网| 精品不卡在线视频| 成人午夜av影视| 首页亚洲欧美制服丝腿| 久久久另类综合| 欧美日韩日日夜夜| 粉嫩av一区二区三区在线播放| 亚洲一二三四在线观看| wwwwxxxxx欧美| 欧美理论片在线| 97精品久久久久中文字幕| 久久av中文字幕片| 91黄色在线观看| 亚洲男女毛片无遮挡| 日韩手机在线导航| 日本黄色一区二区| 成人毛片视频在线观看| 激情亚洲综合在线| 日本不卡视频在线| 一个色综合av| 亚洲美女精品一区| 亚洲私人影院在线观看| 国产欧美一区二区精品忘忧草| 日韩一区二区三区视频| 欧美手机在线视频| 91国内精品野花午夜精品| 国产成人综合视频| 国产激情一区二区三区四区| 国产做a爰片久久毛片| 久久精品免费观看| 美女视频一区二区三区| 免费精品视频在线| 日本在线不卡视频一二三区| 午夜视频在线观看一区| 亚洲午夜精品在线| 亚洲精品视频一区| 亚洲va欧美va人人爽| 欧美午夜精品一区二区蜜桃| 国产精品一区二区三区99| 精品一区二区三区日韩| 午夜日韩在线电影| 一区二区三区四区乱视频| 欧美日韩国产在线观看| 国产欧美一区二区三区沐欲| 国产主播一区二区| 激情综合亚洲精品| 国产激情视频一区二区在线观看 | 国产午夜一区二区三区| 久久久久久久久岛国免费| 久久综合网色—综合色88| 亚洲人成影院在线观看| 亚洲一区视频在线观看视频| 五月婷婷综合网| 99精品欧美一区二区三区小说 | 久久免费精品国产久精品久久久久| 精品国产免费视频| 亚洲国产日日夜夜| 国产福利一区二区三区视频在线| 91一区二区三区在线观看| 欧美日韩精品高清| 亚洲国产精品黑人久久久| 美女尤物国产一区| 蜜桃久久精品一区二区| 成人在线视频一区| 欧美乱熟臀69xxxxxx| 亚洲色图欧美偷拍| 成人黄色免费短视频| 26uuu色噜噜精品一区二区| 亚洲综合在线电影| av电影在线观看完整版一区二区| 欧亚一区二区三区| 亚洲另类中文字| 国产福利一区二区三区视频| 成人av电影免费在线播放| 亚洲国产精华液网站w| 国产精品一区二区免费不卡| 国产精品美女久久久久av爽李琼| 精品一区二区三区视频在线观看| 日韩精品一区二| 国产精品一色哟哟哟| 日韩欧美国产一二三区| 三级在线观看一区二区| 日韩欧美电影一二三| 日本亚洲一区二区| 北条麻妃一区二区三区| 国产精品麻豆视频| 日本韩国欧美在线| 日本一区二区三区dvd视频在线| 亚洲精品一区二区三区蜜桃下载 | 日韩电影免费在线| 久久久久久亚洲综合| 欧美自拍偷拍午夜视频| 波多野结衣在线一区| 国产一区二区在线看| 亚洲h精品动漫在线观看| 欧美日高清视频| 国产老肥熟一区二区三区| 麻豆精品一区二区| 久久精品噜噜噜成人88aⅴ| 丝袜a∨在线一区二区三区不卡 | 亚洲电影第三页| 亚洲天天做日日做天天谢日日欢| 精品国产一区二区三区忘忧草| 欧美三级午夜理伦三级中视频| 99这里只有久久精品视频| 成人精品国产福利| 国产99久久久国产精品潘金| 亚洲日本电影在线| 欧美激情一区二区三区全黄| 日韩午夜激情av| 精品乱人伦小说| 精品久久国产老人久久综合| 欧美日韩免费一区二区三区视频 | 成人午夜视频福利| 99精品国产99久久久久久白柏| 欧美色图12p| 亚洲欧美电影院| 国产麻豆9l精品三级站| 丁香啪啪综合成人亚洲小说| 国产麻豆午夜三级精品|