|
D.4.6.1 makeGraph
Procedure from library ellipticcovers.lib (see ellipticcovers_lib).
- Usage:
- makeGraph(v,e); v list, e list
- Assume:
- v is a list of integers, e is a list of two element lists of v.
- Return:
- graph with vertices v and edges e
- Theory:
- Creates a graph from a list of vertices and edges. The vertices can be any type.
Example:
| LIB "ellipticcovers.lib";
ring R=(0,x1,x2,x3,x4),(q1,q2,q3,q4,q5,q6),dp;
graph G = makeGraph(list(1,2,3,4),list(list(1,3),list(1,2),list(1,2),list(2,4),list(3,4),list(3,4)));
G;
==> [[1, 3], [1, 2], [1, 2], [2, 4], [3, 4], [3, 4]]
==> Graph with 4 vertices and 6 edges
==>
|
|