This is the source code for Section 3 of 

J. Barkley, T. Budd, "Precision measurements of Hausdorff dimensions in two-dimensional quantum gravity" (2019).

=== Requirements ===

* C++ compiler supporting c++11 standard (tested with gcc version 5.4.0)
* Boost library (tested with version 1.58)

=== Compilation ===

g++ disthist.cpp schnyder.cpp -std=c++11 -lboost_program_options -lpthread -O3 -Wall -o randgeom

=== Usage ===

Overview of input options: 
$ ./randgeom --help

Save a single uniform quadrangulation with 100 faces to map.txt (See https://hef.ru.nl/~tbudd/randgeom/ for an explanation of the planar map encoding): 
$ ./randgeom -c quadrangulation -f 100 > map.txt

Produce a histogram of the graph distance from a random initial vertex to all other vertices in 1000 samples of a Schnyder-wood-decorated triangulation with 400 faces, and save the result to hist.txt:
$ ./randgeom -c schnyder -m vert -f 400 -n 1000 --histogram > hist.txt

Produce a histogram of the dual graph distance from a random initial face to all other faces in 1000 samples of a bipolar-oriented triangulation with 400 faces, and save the result to hist.txt:
$ ./randgeom -c bipolar -m tri -f 400 -n 1000 --histogram > hist.txt

=== Histogram format ===

Each line of hist.txt consists of five space-separated numerical values:

1) The distance r.
2) The number #(r) of vertices or faces that have been encountered at distance r.
3) The size N of the planar map, which is the number of vertices in case of the graph distance or the number of faces in case of the dual graph distance.
4) #(r) / (N * n), the estimate for rho_N(r) (See Section 3 of the paper).
5) The number n of planar map configurations that have been generated in the simulation. 

=== License ===

This source code may be reused without limitations according to the MIT license. If used in a scientific context, please cite the accompanying paper:

J. Barkley, T. Budd, "Precision measurements of Hausdorff dimensions in two-dimensional quantum gravity" (2019).



