Skip to main content

Utilities to perform stat mech analysis of pair potentials

Project description

Repo Docs PyPI license PyPI version Conda (channel only) Code style: black

analphipy

Utilities to perform metric analysis on fluid pair potentials. The main features of analphipy as follows:

Overview

analphipy is a python package to calculate metrics for classical models for pair potentials. It provides a simple and extendable api for pair potentials creation. Several routines to calculate metrics are included in the package.

Features

  • Pre-defined spherically symmetric potentials
  • Simple interface to extended to user defined pair potentials
  • Routines to calculate Noro-Frenkel effective parameters.
  • Routines to calculate Jensen-Shannon divergence

Status

This package is actively used by the author. Please feel free to create a pull request for wanted features and suggestions!

Quick start

Use one of the following to install analphipy

pip install analphipy

or

conda install -c conda-forge analphipy

Example usage

# Create a Lennard-Jones potential
>>> import analphipy
>>> p = analphipy.potential.LennardJones(sig=1.0, eps=1.0)

# Get a Noro-Frenekl analysis object
>>> n = p.to_nf()

# Get effective parameters at inverse temperature beta
>>> n.sig(beta=1.0)
1.01560...

>>> n.eps(beta=1.0)
-1.0

>>> n.lam(beta=1.0)
1.44097...

Documentation

See the documentation for a look at analphipy in action.

License

This is free software. See LICENSE.

Contact

The author can be reached at wpk@nist.gov.

Credits

This package was created with Cookiecutter and the wpk-nist-gov/cookiecutter-pypackage Project template forked from audreyr/cookiecutter-pypackage.

TODO

  • remove # type: ignore from potentials.py, base_potentials.py
  • add back check_untyped_defs to pyproject.toml mypy config
  • remove use of custom_inherit

Changelog

Changelog for analphipy

Unreleased

See the fragment files in changelog.d

v0.3.0 — 2023-08-04

Added

  • Package now available on conda-forge

Changed

  • Added better support for mypy/pyright type checking.

v0.2.0 — 2023-05-04

Removed

  • Removed cached_decorator module.
  • Removed docfiller module.

Added

v0.1.0 — 2023-04-24

Changed

  • Update package layout
  • New linters via pre-commit
  • Development env now handled by tox

v0.0.6 - 2023-03-22

Full set of changes: v0.0.5...v0.0.6

v0.0.5 - 2023-03-22

Full set of changes: v0.0.4...v0.0.5

v0.0.4 - 2022-09-27

Full set of changes: v0.0.3...v0.0.4

v0.0.3 - 2022-09-26

Full set of changes: v0.0.2...v0.0.3

v0.0.2 - 2022-09-26

Full set of changes: v0.0.1...v0.0.2

v0.0.1 - 2022-09-26

This software was developed by employees of the National Institute of Standards and Technology (NIST), an agency of the Federal Government. Pursuant to title 17 United States Code Section 105, works of NIST employees are not subject to copyright protection in the United States and are considered to be in the public domain. Permission to freely use, copy, modify, and distribute this software and its documentation without fee is hereby granted, provided that this notice and disclaimer of warranty appears in all copies.

THE SOFTWARE IS PROVIDED 'AS IS' WITHOUT ANY WARRANTY OF ANY KIND, EITHER EXPRESSED, IMPLIED, OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, ANY WARRANTY THAT THE SOFTWARE WILL CONFORM TO SPECIFICATIONS, ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND FREEDOM FROM INFRINGEMENT, AND ANY WARRANTY THAT THE DOCUMENTATION WILL CONFORM TO THE SOFTWARE, OR ANY WARRANTY THAT THE SOFTWARE WILL BE ERROR FREE. IN NO EVENT SHALL NIST BE LIABLE FOR ANY DAMAGES, INCLUDING, BUT NOT LIMITED TO, DIRECT, INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES, ARISING OUT OF, RESULTING FROM, OR IN ANY WAY CONNECTED WITH THIS SOFTWARE, WHETHER OR NOT BASED UPON WARRANTY, CONTRACT, TORT, OR OTHERWISE, WHETHER OR NOT INJURY WAS SUSTAINED BY PERSONS OR PROPERTY OR OTHERWISE, AND WHETHER OR NOT LOSS WAS SUSTAINED FROM, OR AROSE OUT OF THE RESULTS OF, OR USE OF, THE SOFTWARE OR SERVICES PROVIDED HEREUNDER.

Distributions of NIST software should also include copyright and licensing statements of any third-party software that are legally bundled with the code in compliance with the conditions of those licenses.

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

analphipy-0.3.0.tar.gz (325.3 kB view hashes)

Uploaded Source

Built Distribution

analphipy-0.3.0-py3-none-any.whl (28.0 kB view hashes)

Uploaded Python 3

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