The KnotInfo and LinkInfo databases as lists of dictionaries
Project description
Database KnotInfo
This repository contains a snapshot of the complete content of the KnotInfo and LinkInfo databases. Each database is provided as a Python list of Python dictionaries. The data are from the corresponding Excel spreadsheets available on the KnotInfo and LinkInfo homepages on the date of release.
This repository was created as a part of the SageMath interface to these databases (see Sage Trac ticket #30352) but can also be used independently.
In Python, it can be used as follows:
>>> from database_knotinfo import link_list
>>> k = link_list()
>>> len(k)
2979
>>> names_k = k[0]
>>> type(names_k)
<type 'dict'>
>>> names_k['braid_index']
'Braid Index'
>>> k2 = k[2]
>>> k2['name']
'3_1'
>>> k2['braid_index']
'2'
>>> k2['homfly_polynomial']
'(2*v^2-v^4)+(v^2)*z^2'
>>> l = link_list(proper_links=True)
>>> len(l)
4189
>>> names_l = l[0]
>>> type(names_l)
<type 'dict'>
>>> names_l['braid_notation']
'Braid Notation'
>>> l2 = l[2]
>>> l2['name']
'L2a1{1}'
>>> l2['homflypt_polynomial']
'v/z-v^3/z + v*z'
To build a new release, the CSV
files can be upgraded with the
create_knotinfo_csv.py
script. A cronjob
executes it on the first day of every month and creates a new
release if differences are detected.
Installation
Python
pip install database_knotinfo
SageMath
Once ticket #30352 is released, the database can be installed in Sage by:
sage -i database_knotinfo
This will contain integration with the knot and link functionality of Sage. Of course the flat Python functionality is already available by:
sage -pip install database_knotinfo
Versioning
Version numbers are automatically generated every month if differences to the original databases are detected. They follow the scheme
<year>.<month>.<day>
Help
If you note a divergence between this repository and the original data in case the current release is older than a month please create an issue about that.
Credits
Many thanks to Chuck Livingston and Allison Moore for making the data available. For further acknowledgments see the corresponding homepages.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for database_knotinfo-2021.9.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6b4f73a7d49b7651e67f3a1d425f4ee1acfd521dc3600ed11581e47f14af7326 |
|
MD5 | c6487321cd2e0fd6b9f9ee7bdfa19993 |
|
BLAKE2b-256 | 5dfb2248c221cd3333d3728b5b082f76aadb5eb305c7ec5bfa3f85e2460bf69a |
Hashes for database_knotinfo-2021.9.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b2990a2b133f76eab02eb0b8eb4d0bd9dfcf8ebebab126b006e5857fc588863f |
|
MD5 | 329fd663d72f185fb0bb085e27cab1aa |
|
BLAKE2b-256 | 60110cc3fd3af259752fcf81cbd10c5eaac50f243b14ac679fa3a7ad6f9da46a |