Giter Club home page Giter Club logo

bella's Introduction

bella: a computational package for Kleinian groups

This is a computational package for dealing with Kleinian groups, particularly aspects related to visualisation and moduli spaces.

Note: This package superceeds the earlier Riley computational package.

Features of this package include:

  • implementation of a wide variety of algorithms to iterate over 2x2 matrix groups as well as various related number theoretic and combinatorial algorithms
  • close integration with pandas and related visualisation tools, especially HoloViews
  • support of $p$-adic groups, for which we use the pyadic library; see also the interesting work of Ari Markowitz
  • a reasonably large zoo of examples

Future features may include, time-permitting:

  • general tools for 2- and 3-dimensional hyperbolic geometry
  • integration with https://www.math.uic.edu/t3m/SnapPy/
  • approximation of related functions including Riemann functions and meromorphic forms
  • implementation of discreteness algorithms for groups with smaller numbers of generators

a parabolic Riley slice generated by slice.py

Background material on Kleinian groups

A Kleinian group is a discrete subgroup of $\mathrm{PSL}(2,\mathbb{C})$. These groups are the holonomy groups of complete hyperbolic 3-orbifolds, so every complete hyperbolic 3-orbifold is of the form $\mathbb{H}^3/G$ for $G$ a Kleinian group. For background material in Kleinian groups, see [B83,M87].

We are particularly interested in studying a particular moduli space of Kleinian groups, the Riley slice of Schottky space [KS94, KS98], together with its elliptic generalisations. Background specific to the Riley slice may be found in the proceedings article [EMS22b] and in my MSc thesis [Elz22]. For a more practical introduction to some of the computational geometry and some very nice pictures, see [MSW02] and its associated website. Many of the computations in this direction are done using the results obtained in our paper [EMS22a]. We also have some further recent results on the Riley slice which are of interest from a computational point of view [EMS21]; our construction of pleating ray neighbourhoods is used by the function `riley.RileyGroup.guess_radial_coordinate' to approximate the pleating coordinate of an input Riley group.

The visualisation software was inspired by the schottky software written by Danny Calegari and Alden Walker.

Installation

We use the setuptools package for ease of installation. Simply run pip install . to install.

Remark: sagemath is not a formal dependency, but some people find that it improves the performance of mpmath.

The software included

Python library

The library is called bella (so after installing run from bella import [module] in Python). It includes the following modules:

  • cayley.py -- methods for computing with general matrix groups via their Cayley graph (e.g. reducing words, computing limit sets)
  • farey.py -- methods for working with Farey words and polynomials
  • riley.py -- methods for working with individual Riley groups
  • slices.py -- methods for computing approximations of slice exteriors
  • chistyakov.py -- methods for embedding elements of $\mathbb{Q}_p$ into $\mathbb{C}$ [C96]

Examples

Examples are in the examples/ directory; see the readme file.

Now included is an up-to-date version of the graphical_limits.py software from riley that allows the user to click-and-drag around to view different limit sets around the Riley slices. To run this, run

panel serve examples/riley_limits.py

and click the link that appears in your terminal.

References

[B83] Alan F. Beardon. The geometry of discrete groups. Graduate Texts in Mathematics 91. Springer-Verlag, 1983.

[C96] D.V. Chistyakov, “Fractal geometry for images of continuous embeddings of p-adic numbers and solenoids into Euclidean spaces”. In: Theoretical and Mathematical Physics (109 1996), pp.1495–1507.

[Elz22] Alex Elzenaar. “Deformation spaces of Kleinian groups”. MSc thesis. The University of Auckland, 2022.

[EMS21] Alex Elzenaar, Gaven Martin, and Jeroen Schillewaert. “Approximations of the Riley slice”. November 2021. arXiv:2111.03230 [math.GT].

[EMS22a] Alex Elzenaar, Gaven Martin, and Jeroen Schillewaert. “The combinatorics of Farey words and their traces”. April 2022. arXiv:2204.08076 [math.GT]. A version with minor corrections is on my website.

[EMS22b] Alex Elzenaar, Gaven Martin, and Jeroen Schillewaert. “Concrete one complex dimensional moduli spaces of hyperbolic manifolds and orbifolds”. In: 2021-22 MATRIX annals. Ed. by David R. Wood, Jan de Gier, Cheryl E. Prager, and Terrence Tao. MATRIX Book Series 5. Springer, to appear.

[KS94] Linda Keen and Caroline Series. “The Riley slice of Schottky space”. In: Proceedings of the London Mathematics Society 3.1 (69 1994), pp. 72–90.

[KS98] Yohei Komori and Caroline Series. “The Riley slice revisited”. In: The Epstein birthday schrift. Vol. 1. Geometry and Topology Monographs. 1998, pp. 303–316.

[M87] Bernard Maskit. Kleinian groups. Grundlehren der mathematischen Wissenshaften 287. Springer-Verlag, 1987.

[MSW02] David Mumford, Caroline Series, and David Wright. Indra’s pearls: The vision of Felix Klein. Cambridge University Press, 2002.

bella's People

Contributors

aelzenaar avatar vascosch92 avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Forkers

vascosch92

bella's Issues

Make clearer examples

Right now the examples are kind of messy. Write specific well-documented examples to showcase particular features, or at least document the existing ones clearer.

Write tests

  • unit test that 4*i lies on the 1/2 pleating ray and 37 lies on the 0/1 pleating ray and -43 lies on the 1/1 pleating ray (parabolic/parabolic case)
  • unit test that riley_string * X * riley_string^-1 Y = farey_string
  • unit test fixed points and words are equal to finite initial list
  • verify trace of farey words equals value of farey polynomials

GroupCache.subgroup() should take a list of words

GroupCache.subgroup() should take a list of words, i.e. [(0,), (3,),...]; instead it takes just matrices so is essentially useless.

RileyGroup should also expose a subgroup method that takes XY strings.

Hyperbolic geometry functions

Add functions to:

  • construct regular polygons
  • compute geometry of pairs of geodesics [B, section starting p.162]
  • Find pencils fixed by mobius transforms and (inversely) find the mobius transform fixing a pencil

`slices.elliptic_slice_exterior` computes the wrong polynomials

MWE:

from bella import slices

# Compute a whole bunch of level sets, and stick them into one pandas dataframe
depth = 20
p = 3
q = 6
elliptic_slice = slices.elliptic_exterior(p, q, depth)

print(elliptic_slice[43])

The polynomial solver fails to converge, and we see:

bella.slices.ConvergenceFailedException: Convergence failed at r/s = 2/3, polynomial 3.0 -
12.12435565298214105469212439054110656859963677667266439639064885616353111836160025956802330730074003·x +
15.0·x² -
5.196152422706631880582339024517617100828415761431141884167420938355799050726400111243438560271745727·x³

But:

>>> print(farey.farey_polynomial_classic(2,3,3,6)+2)
3.732050807568877293527446341505872366942805253810380628055806979451933016908800037081146186757248576 -
1.0·x +
1.732050807568877293527446341505872366942805253810380628055806979451933016908800037081146186757248576·x² -
1.0·x³

so the wrong Farey polynomial is computed by slices.elliptic_exterior. (It even fails to be monic!)

Revamp Farey polynomial API

  • Use trX,trY,trXY not alpha and beta
  • Remove all but numpy polynomial generators
  • Add utility functions to convert <-> numpy and mpmath representations
  • Add utility function to solve polynomials

Compute peripheral subwords of Riley words

In farey.py implement:

  • function to check if a word is a conjugate of some generator
  • cyclic permutation generator
  • combination of the above to compute the two splittings of the Farey word producing peripheral groups
  • update the peripherals.py example to use this.

Integration with sagemath

I often wish to do computations of the following form:-

  1. Find parameter values for a group such that there exist words satisfying certain trace relations;
  2. Compute the limit set of the resulting group.

See e.g. the example "dunfield_tiozzo".

Part (2) is easy to do in bella, if the generators are available in numerical form. Part (1) requires a computer algebra system such as Sage. However it is nontrivial to plug bella into sage.

We must do the following things, at least (https://doc.sagemath.org/html/en/developer/coding_in_python.html):

  1. Ensure no features newer than Python 3.9 are used
  2. Implement various sage functions like _latex_
  3. Allow for named generators/relations (in progress, f33262c)
  4. Allow arbitrary sage numeric types instead of requiring mpmath.

Part 4 is fairly nontrivial, as since early versions we have fairly strong dependencies on mpmath (e.g. mp.inf is used a lot).

Error running atom.py

Traceback (most recent call last):
  File "/Users/amar630/anaconda3/envs/py3-11/lib/python3.11/site-packages/dask/backends.py", line 136, in wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/Users/amar630/anaconda3/envs/py3-11/lib/python3.11/site-packages/dask/dataframe/io/csv.py", line 760, in read
    return read_pandas(
           ^^^^^^^^^^^^
  File "/Users/amar630/anaconda3/envs/py3-11/lib/python3.11/site-packages/dask/dataframe/io/csv.py", line 533, in read_pandas
    raise OSError(f"{urlpath} resolved to no files")
OSError: atom/*.csv resolved to no files

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/Users/amar630/Downloads/bella-main/examples/atom.py", line 70, in <module>
    df = dd.read_csv("atom/*.csv")
         ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/amar630/anaconda3/envs/py3-11/lib/python3.11/site-packages/dask/backends.py", line 138, in wrapper
    raise type(e)(
OSError: An error occurred while calling the read_csv method registered to the pandas backend.

I tried uncommenting the commented code, but then I get an error that G is not defined.

I am running Python 3.11.

Add holoviews helper functions

  • draw circles fast using isometric_circles.py method but tweaked to make thinner circles
  • for non-dynamic groups add global switch (e.g. command line parameter) to swap between panel serve or png output

coloured_limit_set_mc come back please

Add back in this function removed in de0855b and add a new "left-to-right" mode. This is of interest in computing zooms of limit sets and cannot be done in the "fast" way so it is worth having the function back even though it is slow at "normal" limit sets.

Farey fractions

Add functions to:

  • approximate arbitrary numbers with continued fractions
  • convert continued fraction expansions to and from rational numbers

Pleating ray API

  • generator walking down r/s pleating ray from -10 to -2 (say) with a step either uniform in [-10,2] or in the moduli space (general for all polynomials)
  • selection of correct cusp from roots of Farey polynomial
  • continued fraction approximation of cusp groups
  • add subclass CuspGroup of ClassicalRileyGroup

Conduct convergence study on mpmath

Currently riley.riley_slice_exterior is very slow. This is a factor of three variables:

  • mp.dps = 100 (__init__.py)
  • maxsteps = 500 (in farey.solve_polynomial)
  • extraprec = 1000 (in farey.solve_polynomial)

First of all, we should have an internal mpmath context to avoid setting the dps globally. We should then choose maxsteps and extraprec to be minimal to ensure convergence. This could be done as follows:

  1. Try with maxsteps = 20, extraprec = 20
  2. If no convergence:
    1. Increase maxsteps by (say) 1.5x and extraprec by 2x
    2. try again
  3. Store minimal working maxsteps and extraprec in global context and use them as starting point next time solve_polynomial is called.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.