Python library for spin wave calculations
Project description
pySpinW
This is an intial release of pySpinW as a pip
installable wheel for python >= 3.8 and MATLAB >= R2021a
Installation
Please install with
pip install pyspinw*.whl
This package can now be used in python if you have a version of MATLAB or MCR available on the machine. The package will try to automatically detect your installation, however if it is in a non-standard location, the path and version will have to be specified.
m = Matlab(matlab_version='R2023a', matlab_path='/usr/local/MATLAB/R2023a/')
Example
An example would be:
import numpy as np
from pyspinw import Matlab
m = Matlab()
# Create a spinw model, in this case a triangular antiferromagnet
s = m.sw_model('triAF', 1)
# Specify the start and end points of the q grid and the number of points
q_start = [0, 0, 0]
q_end = [1, 1, 0]
pts = 501
# Calculate the spin wave spectrum
spec = m.spinwave(s, [q_start, q_end, pts])
Known limitations
At the moment graphics will not work on macOS systems and is disabled.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
spinw-4.0.0-py3-none-any.whl
(18.7 MB
view details)
File details
Details for the file spinw-4.0.0-py3-none-any.whl
.
File metadata
- Download URL: spinw-4.0.0-py3-none-any.whl
- Upload date:
- Size: 18.7 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.0.0 CPython/3.12.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a3a1ef8889ae17e13164488f3e84e97471c08697f418781ae7f3635d18bba205 |
|
MD5 | c8163f31622ac74445c5ea76aca3bc0b |
|
BLAKE2b-256 | 9cafbb54f251dc6eb7d5565815cb9a48597bf55bd5d4fd9be7e95003f69d188e |