badic


Namebadic JSON
Version 0.0.9 PyPI version JSON
download
home_pagehttps://gitlab.com/mercatp/badic
SummaryBeta-adics and automata tools
upload_time2024-01-02 17:35:00
maintainer
docs_urlNone
authorPaul Mercat, Dominique Benielli
requires_python
licenseGPLv3+
keywords sagemath beta-adic automata multidimensional continued fraction algorithms
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ============================
Beta-adic tools and automata
============================

The badic package for SageMath add functionalities related to beta-adic sets, i.e. sets of the form
{ a_0 + a_1*b + a_2*b^2 + ... + a_n*b^n | n in N, a_0 a_1 ... a_n in L }
where b is a number, and L is a regular language (over an alphabet in the same ring as b).
This permits to do computation and drawing with Rauzy fractals and many other fractals.
It also permits to manipulate efficiently automata written in C language (mainly deterministic automata).
It installs on top of an existing Sage installation (tested on versions 8.1 and 8.8).

This package is based on `SageMath <http://www.sagemath.org>`_

Prerequisites
-------------

Installing the package badic requires a working Sage installation (with Cython and gcc).

It is recommanded (but not necessary) to install the dot command of Graphiz, in order to
have nice plots of automata.
If you want to use the functions draw_zoom() and user_draw() of BetaAdicSet, you need to
install the SDL2 library (developpement version) in your system before installing the badic package.
Both library can be installed in Linux with the command line

	$ sudo apt install libsdl2-dev graphviz

Installation
------------

The module is distributed on PyPI. You just need to run the following command::

    $ sage -pip install badic [--user]

The --user option is optional and allows to install the module in your user space
(and does not require administrator rights).

Remark: If you don't have SSL installed, the previous command may not work.
If it is the case, you can download the file badic-x.x.x.tar.gz from https://pypi.org/project/badic/#files
Then, extract the files (you will get a folder badic-x.x.x), and then use the command

	$ sage -pip install badic-x.x.x/ --user
	
(replace badic-x.x.x/ by the location of the folder extracted)

Documentation
-------------

* examples of Sage worksheets using the package badic:
	http://www.i2m.univ-amu.fr/perso/paul.mercat/RauzyFractals/

* tutorial about beta-adic sets (not up-to-date, functions names may have changed):
	http://www.i2m.univ-amu.fr/perso/paul.mercat/RauzyFractals/html/beta_adic_set.html

* tutorial about automata and regular languages (not up-to-date, functions names may have changed):
	http://www.i2m.univ-amu.fr/perso/paul.mercat/RauzyFractals/html/language_automaton.html

Check
-----

After installing badic, check that it works by launching Sage
and typing the following commands. You should get the same
output as below.::

    sage: from badic import *
    sage: m = BetaAdicSet(1/(1+I), [0,1])
    sage: m.plot()                  # this should plot the dragon fractal
    
    sage: mi = m.intersection_words([0], [1]); mi
    b-adic set with b root of x^2 - x + 1/2, and an automaton of 21 states and 2 letters
    sage: mi.plot(nprec=8)          # this should plot a part of the boundary of the dragon fractal
    sage: mi.critical_exponent()    # compute the Hausdorff dimension of the boundary of the dragon fractal
    log(y)/log(1.414213562373095?) where y is the max root of x^3 - x^2 - 2, and 1.414213562373095? is root of x^2 - 2.
    1.523627086202492
    
    sage: from badic.beta_adic import *
    sage: s = WordMorphism('a->ab,b->ca,c->a')  # define a substitution
    sage: m = DumontThomas(s).mirror(); m    # take the corresponding beta-adic set
    b-adic set with b root of x^3 - x^2 - x - 1, and an automaton of 3 states and 2 letters
    sage: m.plot()      # should plot the Rauzy fractal of the substitution s
    sage: m.draw_zoom() # permits to zoom in the Rauzy fractal (works only if SDL2 was installed)
    
    sage: a = dag.AnyWord(['a','b']).concat(dag.Word('abca')); a    # define an automaton
    DetAutomaton with 5 states and an alphabet of 3 letters
    sage: a.plot()  # plot the automaton (to have a nice picture drawn with Graphviz,
                    #                      install the dot command on your system before
                    #                      installing the package badic)

Installing development version. Source code
-------------------------------------------

The development webpage is https://gitlab.com/mercatp/badic

Assuming you have the program git on your computer, you can install the
development version with the command::

    $ sage -pip install git+https://gitlab.com/mercatp/badic [--user]

Contact
-------

Your comments and help are welcome: paul.mercat@univ-amu.fr

Authors
-------

* Paul Mercat
* Dominique Benielli (PEP8 and doc)
* Vincent Delecroix (helped to make a package)

Versions
--------

* badic 0.0.5 was released on 2020-05-17 (as a Python package on PyPI)
* badic 0.0.4 was released on 2019-07-26 (as a Python package on PyPI)
* badic 0.0.3 was released on 2019-07-26 (as a Python package on PyPI)
* badic 0.0.2 was released on 2019-07-26 (as a Python package on PyPI)
* badic 0.0.1 was released on 2019-07-26 (as a Python package on PyPI)

            

Raw data

            {
    "_id": null,
    "home_page": "https://gitlab.com/mercatp/badic",
    "name": "badic",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "SageMath beta-adic automata multidimensional continued fraction algorithms",
    "author": "Paul Mercat, Dominique Benielli",
    "author_email": "paul.mercat@univ-amu.fr",
    "download_url": "https://files.pythonhosted.org/packages/f9/fc/692ce799f299a1315669ea04c4b4ac58f419d84dd14f469894a87e900c13/badic-0.0.9.tar.gz",
    "platform": null,
    "description": "============================\nBeta-adic tools and automata\n============================\n\nThe badic package for SageMath add functionalities related to beta-adic sets, i.e. sets of the form\n{ a_0 + a_1*b + a_2*b^2 + ... + a_n*b^n | n in N, a_0 a_1 ... a_n in L }\nwhere b is a number, and L is a regular language (over an alphabet in the same ring as b).\nThis permits to do computation and drawing with Rauzy fractals and many other fractals.\nIt also permits to manipulate efficiently automata written in C language (mainly deterministic automata).\nIt installs on top of an existing Sage installation (tested on versions 8.1 and 8.8).\n\nThis package is based on `SageMath <http://www.sagemath.org>`_\n\nPrerequisites\n-------------\n\nInstalling the package badic requires a working Sage installation (with Cython and gcc).\n\nIt is recommanded (but not necessary) to install the dot command of Graphiz, in order to\nhave nice plots of automata.\nIf you want to use the functions draw_zoom() and user_draw() of BetaAdicSet, you need to\ninstall the SDL2 library (developpement version) in your system before installing the badic package.\nBoth library can be installed in Linux with the command line\n\n\t$ sudo apt install libsdl2-dev graphviz\n\nInstallation\n------------\n\nThe module is distributed on PyPI. You just need to run the following command::\n\n    $ sage -pip install badic [--user]\n\nThe --user option is optional and allows to install the module in your user space\n(and does not require administrator rights).\n\nRemark: If you don't have SSL installed, the previous command may not work.\nIf it is the case, you can download the file badic-x.x.x.tar.gz from https://pypi.org/project/badic/#files\nThen, extract the files (you will get a folder badic-x.x.x), and then use the command\n\n\t$ sage -pip install badic-x.x.x/ --user\n\t\n(replace badic-x.x.x/ by the location of the folder extracted)\n\nDocumentation\n-------------\n\n* examples of Sage worksheets using the package badic:\n\thttp://www.i2m.univ-amu.fr/perso/paul.mercat/RauzyFractals/\n\n* tutorial about beta-adic sets (not up-to-date, functions names may have changed):\n\thttp://www.i2m.univ-amu.fr/perso/paul.mercat/RauzyFractals/html/beta_adic_set.html\n\n* tutorial about automata and regular languages (not up-to-date, functions names may have changed):\n\thttp://www.i2m.univ-amu.fr/perso/paul.mercat/RauzyFractals/html/language_automaton.html\n\nCheck\n-----\n\nAfter installing badic, check that it works by launching Sage\nand typing the following commands. You should get the same\noutput as below.::\n\n    sage: from badic import *\n    sage: m = BetaAdicSet(1/(1+I), [0,1])\n    sage: m.plot()                  # this should plot the dragon fractal\n    \n    sage: mi = m.intersection_words([0], [1]); mi\n    b-adic set with b root of x^2 - x + 1/2, and an automaton of 21 states and 2 letters\n    sage: mi.plot(nprec=8)          # this should plot a part of the boundary of the dragon fractal\n    sage: mi.critical_exponent()    # compute the Hausdorff dimension of the boundary of the dragon fractal\n    log(y)/log(1.414213562373095?) where y is the max root of x^3 - x^2 - 2, and 1.414213562373095? is root of x^2 - 2.\n    1.523627086202492\n    \n    sage: from badic.beta_adic import *\n    sage: s = WordMorphism('a->ab,b->ca,c->a')  # define a substitution\n    sage: m = DumontThomas(s).mirror(); m    # take the corresponding beta-adic set\n    b-adic set with b root of x^3 - x^2 - x - 1, and an automaton of 3 states and 2 letters\n    sage: m.plot()      # should plot the Rauzy fractal of the substitution s\n    sage: m.draw_zoom() # permits to zoom in the Rauzy fractal (works only if SDL2 was installed)\n    \n    sage: a = dag.AnyWord(['a','b']).concat(dag.Word('abca')); a    # define an automaton\n    DetAutomaton with 5 states and an alphabet of 3 letters\n    sage: a.plot()  # plot the automaton (to have a nice picture drawn with Graphviz,\n                    #                      install the dot command on your system before\n                    #                      installing the package badic)\n\nInstalling development version. Source code\n-------------------------------------------\n\nThe development webpage is https://gitlab.com/mercatp/badic\n\nAssuming you have the program git on your computer, you can install the\ndevelopment version with the command::\n\n    $ sage -pip install git+https://gitlab.com/mercatp/badic [--user]\n\nContact\n-------\n\nYour comments and help are welcome: paul.mercat@univ-amu.fr\n\nAuthors\n-------\n\n* Paul Mercat\n* Dominique Benielli (PEP8 and doc)\n* Vincent Delecroix (helped to make a package)\n\nVersions\n--------\n\n* badic 0.0.5 was released on 2020-05-17 (as a Python package on PyPI)\n* badic 0.0.4 was released on 2019-07-26 (as a Python package on PyPI)\n* badic 0.0.3 was released on 2019-07-26 (as a Python package on PyPI)\n* badic 0.0.2 was released on 2019-07-26 (as a Python package on PyPI)\n* badic 0.0.1 was released on 2019-07-26 (as a Python package on PyPI)\n",
    "bugtrack_url": null,
    "license": "GPLv3+",
    "summary": "Beta-adics and automata tools",
    "version": "0.0.9",
    "project_urls": {
        "Homepage": "https://gitlab.com/mercatp/badic"
    },
    "split_keywords": [
        "sagemath",
        "beta-adic",
        "automata",
        "multidimensional",
        "continued",
        "fraction",
        "algorithms"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f9fc692ce799f299a1315669ea04c4b4ac58f419d84dd14f469894a87e900c13",
                "md5": "b81543287f23bcfa305926db103b48e7",
                "sha256": "14a9ac3b33a0b72a0676b124352073a6e737c9cd4f92fae843f72577b8e6a9f0"
            },
            "downloads": -1,
            "filename": "badic-0.0.9.tar.gz",
            "has_sig": false,
            "md5_digest": "b81543287f23bcfa305926db103b48e7",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 186045,
            "upload_time": "2024-01-02T17:35:00",
            "upload_time_iso_8601": "2024-01-02T17:35:00.372938Z",
            "url": "https://files.pythonhosted.org/packages/f9/fc/692ce799f299a1315669ea04c4b4ac58f419d84dd14f469894a87e900c13/badic-0.0.9.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-02 17:35:00",
    "github": false,
    "gitlab": true,
    "bitbucket": false,
    "codeberg": false,
    "gitlab_user": "mercatp",
    "gitlab_project": "badic",
    "lcname": "badic"
}
        
Elapsed time: 0.17533s