Contents

Overview

docs Documentation Status
tests
Travis-CI Build Status
Coverage Status
package
PyPI Package latest release PyPI Wheel Supported versions Supported implementations
Commits since latest release

Smooth interpolation on scattered data with levels and slopes.

  • Free software: MIT license

Installation

pip install chlamys

Development

To run the all tests run:

tox

Note, to combine the coverage data from all the tox environments run:

Windows
set PYTEST_ADDOPTS=--cov-append
tox
Other
PYTEST_ADDOPTS=--cov-append tox

User guide

Reference

chlamys

chlamys.plane(xi, points, values)[source]

Planar interpolation on a simplex

Interpolation via an D-dimensional plane given D+1 points of a simplex.

Parameters:
  • xi (tuple of 1-D array, shape (M, D)) – Points at which to interpolate data.
  • points (ndarray of floats, shape (D+1, D)) – Data point coordinates.
  • values (ndarray of floats, shape (D+1,)) – Data values.
Returns:

ndarray – Array of interpolated values.

chlamys.cubic_patch(xi, points, values, grad)[source]

Cubic patch interpolation on a simplex

Interpolation via an D-dimensional cubic polynomial given D+1 points of a simplex and their gradients.

Parameters:
  • xi (tuple of 1-D array, shape (M, D)) – Points at which to interpolate data.
  • points (ndarray of floats, shape (D+1, D)) – Data point coordinates.
  • values (ndarray of floats, shape (D+1,)) – Data values.
  • grad (ndarray of floats, shape (D+1, D)) – Data gradients.
Returns:

ndarray – Array of interpolated values.

chlamys.interp_levels(points, values, xi)[source]

Linear Delaunay interpolation

Interpolation on D-dimensional scattered points via Delaunay triangulation and planar interpolation.

Parameters:
  • points (ndarray of floats, shape (N, D)) – Data point coordinates.
  • values (ndarray of floats, shape (N,)) – Data values.
  • xi (tuple of 1-D array, shape (M, D)) – Points at which to interpolate data.
Returns:

ndarray – Array of interpolated values.

chlamys.interp_1st_order(points, values, grads, xi)[source]

1st-order cubic Delaunay interpolation

Interpolation on D-dimensional scattered points via Delaunay triangulation and cubic interpolation with gradient information.

Parameters:
  • points (ndarray of floats, shape (N, D)) – Data point coordinates.
  • values (ndarray of floats, shape (N,)) – Data values.
  • grads (ndarray of floats, shape (N, D)) – Data gradients.
  • xi (tuple of 1-D array, shape (M, D)) – Points at which to interpolate data.
Returns:

ndarray – Array of interpolated values.

Indices and tables