mdsuite.utils.calculator_helper_methods module¶
MDSuite: A Zincwarecode package.
License¶
This program and the accompanying materials are made available under the terms of the Eclipse Public License v2.0 which accompanies this distribution, and is available at https://www.eclipse.org/legal/epl-v20.html
SPDX-License-Identifier: EPL-2.0
Copyright Contributors to the Zincwarecode Project.
Contact Information¶
email: zincwarecode@gmail.com github: https://github.com/zincware web: https://zincwarecode.com/
Citation¶
If you use this module please cite us with:
Summary¶
Static methods used in calculators are kept here rather than polluting the parent class.
- mdsuite.utils.calculator_helper_methods.correlate(ds_a: ndarray, ds_b: ndarray) ndarray [source]¶
Compute a simple correlation computation mapped over the spatial dimension of the array.
- Parameters:
ds_a (np.ndarray (n_configurations, dimension)) – Tensor of the first set of data for a single particle.
ds_b (np.ndarray (n_configurations, dimension)) – Tensor of the second set of data for a single particle.
- Returns:
Computes the correlation between the two data sets and averages over the spatial
dimension.
- mdsuite.utils.calculator_helper_methods.fit_einstein_curve(x_data: ndarray, y_data: ndarray, fit_max_index: int) Tuple[Union[ndarray, Iterable, int, float], Any, list, list] [source]¶
Fit operation for Einstein calculations.
- Parameters:
x_data (np.ndarray) – x data to use in the fitting.
y_data (np.ndarray) – y_data to use in the fitting.
fit_max_index (int) – Range at which to store values.
- Returns:
popt (list) – List of fit values
pcov (list) – Covariance matrix of the fit values.