An extension to the Magpylib library, providing force computation
Project description
Magpylib-Force
This package provides force and torque computation for Magpylib objects. Its work in progress and will finally be integrate into the Magpylib package.
Installation
pip install magpylib-force
Example code:
import magpylib as magpy
from mforce import getFTcube
# all inputs and output in SI units
cube1 = magpy.magnet.Cuboid(
dimension=(1,1,1),
polarization=(1,1,1),
)
cube2 = cube1.copy(position=(1,0,2))
cube2.mesh = (10,10,10)
F,T = getFTcube(cube1, [cube2, cube2.copy()], anchor=(0,0,0))
print(F)
print(T)
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
magpylib_force-0.1.6.tar.gz
(9.9 kB
view hashes)
Built Distribution
Close
Hashes for magpylib_force-0.1.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 55895ef165e5217a0e9ba7b9ff4cfb7b8e70e79c243cbd2678af06ce5d7cfdc2 |
|
MD5 | fbb89b1a7415212c424f9c07619bbf39 |
|
BLAKE2b-256 | 982b81c8d1e6e4137bff97d6d2e805c300026ff1ee8b0669f8bec1193040f796 |