Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
hypergraph.cpp
Go to the documentation of this file.
3
4using namespace ogdf;
5
6int main()
7{
9
10 H.readBenchHypergraph("c17.bench");
11
12 HypergraphAttributesES HA(H, EdgeStandardType::tree);
14
15 hlES.setProfile(HypergraphLayoutES::Profile::Normal);
16 hlES.call(HA);
17
18 GraphIO::write(HA.repGA(), "output-c17.gml", GraphIO::writeGML);
19 GraphIO::write(HA.repGA(), "output-c17.svg", GraphIO::drawSVG);
20
21 return 0;
22}
Declares class GraphIO which provides access to all graph read and write functionality.
Layout algorithms for hypergraph based on edge standard representations (clique / star / tree) - Hype...
static bool write(const Graph &G, const string &filename, WriterFunc writer=nullptr)
Writes graph G to a file with name filename and infers the format to use from the file's extension.
static bool writeGML(const Graph &G, std::ostream &os)
Writes graph G in GML format to output stream os.
static bool drawSVG(const GraphAttributes &A, std::ostream &os, const SVGSettings &settings)
Stores additional attributes of edge standard representation of a hypergraph.
const GraphAttributes & repGA() const
void readBenchHypergraph(std::istream &is)
Reads hypergraph in bench format from the input stream.
void setProfile(Profile pProfile)
Sets the layout profile.
virtual void call(HypergraphAttributes &HA) override
Computes a layout of hypergraph given by HA.
int main()
Definition hypergraph.cpp:6
The namespace for all OGDF objects.