Skip to main content

Finite-size scaling analysis at phase transitions

Project description

pyfss is a scientific Python package for finite-size scaling analysis at phase transitions.

Usage

The fssa package expects finite-size data in the following setting.

\begin{equation*} A_L(\varrho) = L^{\zeta/\nu} \tilde{f}\left(L^{1/\nu} (\varrho - \varrho_c)\right), \qquad (L \to \infty, \varrho \to \varrho_c), \end{equation*}

l is like a 1-D numpy array which contains the finite system sizes \(L\). rho is like a 1-D numpy array which contains the parameter values \(\varrho\). a is like a 2-D numpy array which contains the observations (the data) \(A_L(\varrho)\), where a[i, j] is the data at the i-th system size and the j-th parameter value. da is like a 2-D numpy array which contains the standard errors in the observations.

The fssa.autoscale function attempts to determine the critical parameter and exponents which entail an optimal data collapse. The initial guesses for \(\varrho_c, \nu, \zeta\) are rho_c0, nu0, and zeta0.

>>> import fssa
>>> fssa.autoscale(l, rho, a, da, rho_c0, nu0, zeta0)

Package maintainer

The author and maintainer of the pyfss package is Andreas Sorge <as@asorge.de>.

Python 2/3 compatibility

This project uses python-future. It is written in standard Python 3 code, with python-future providing support for running the code on Python 2.7 mostly unchanged.

Building the documentation

This project uses sphinx, sphinx_rtd_theme, sphinxcontrib-bibtex and numpydoc. A CiteULike group manages the bibliography. We configure a custom style in docs/conf.py which suppresses URLs in the bibliography output. We employ the numpy docstring conventions.

To update the local bibliography, run

cd docs; make bib

in the working directory of the repository.

To build the documentation, run

cd docs; make html

in the working directory of the repository, or run

cd docs; make

to list other output formats.

To automatically build the documentation, run

cd docs; ./automake.sh

in the working directory of the repository.

Developing

Deployment and Packaging

This project uses setuptools. The Development Mode deploys the project locally without copying any files. Run

python setup.py develop

in the working directory root of the repository.

Versioning

This project calculates the current package version number based on git tags.

Testing

This project uses unittest.

Run

python setup.py test

to build the package and run the tests.

Run

python -m unittest discover

from the working directory root of the repository to discover and run the tests.

For automatic test runs upon file changes run

./autotest.sh

from the working directory of the repository.

License

This is the license information for the pyfss package excluding its separate documentation (the source of which lives under the docs directory in the package source).

Copyright 2014 Max Planck Society, Andreas Sorge

Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Documentation license

This is the license information for the pyfss package Documentation (the source of which lives under the docs directory in the package source).

Creative Commons License

pyfss Documentation by Andreas Sorge is licensed under a Creative Commons Attribution 4.0 International License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fssa-0.1.6.tar.gz (44.8 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page