Generalized cylindrical shell library for Python.
Project description
gcs
is a Python library for creating generalized cylindrical shells (GCS).
GCS are parameterized by 11 values:
Syntax | Description |
---|---|
c1_base |
The base $4$-lobe parameter. |
c2_base |
The base $8$-lobe parameter. |
c1_top |
The top $4$-lobe parameter. |
c2_top |
The top $8$-lobe parameter. |
twist_linear |
The linear twist. |
twist_amplitude |
The oscillating twist amplitude. |
twist_period |
The oscillating twist period. |
perimeter_ratio |
The ratio between the top and base perimeters. |
height |
The height (mm). |
mass |
The mass (g). |
thickness |
The wall thickness (mm). |
c1
and c2
Relationship
- Adopted from Overvelde and Bertoldi, 2014
twist_linear
, twist_amplitude
, and twist_period
Relationship
Download
pip install gcs-shape
Requirements
- bentley-ottmann (version: 7.3.0)
- numpy (version: 1.21.5 or higher)
- numpy-stl (version: 2.17.1 or higher)
- pandas (version: 1.4.1 or higher)
- scipy (version: 1.7.3 or higher)
Quickstart
import gcs
# Create a generalized cylindrical shell
shape = gcs.GCS(c1_base=0.3,
c2_base=-0.2,
c1_top=0.4,
c2_top=-0.3,
twist_linear=2,
twist_amplitude=0.05,
twist_period=3,
perimeter_ratio=1.5,
height=20,
mass=2.1,
thickness=0.48)
# Assert the shape is valid
print(shape.valid)
# Save shape to STL file
gcs.io.save_mesh(file='shape.stl', shape=shape)
Contributing
The contribution guidelines can be found in CONTRIBUTING.md.
Maintainers
Citation
@misc{Snapp2023,
title = {Autonomous Discovery of Tough Structures},
author = {Kelsey L. Snapp and Benjamin Verdier and
Aldair Gongora and Samuel Silverman and
Adedire D. Adesiji and Elise F. Morgan and
Timothy J. Lawton and Emily Whiting and
Keith A. Brown},
year={2023},
eprint={2308.02315},
archivePrefix={arXiv},
}
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 Distribution
gcs-shape-1.0.2.tar.gz
(14.2 kB
view hashes)
Built Distribution
gcs_shape-1.0.2-py3-none-any.whl
(14.6 kB
view hashes)
Close
Hashes for gcs_shape-1.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c03b9d210d5342ea28252c76484f400a483bc52c9a4bebd6134e2bae06f9cf10 |
|
MD5 | cf1b87db780b89df20f50709391a5672 |
|
BLAKE2b-256 | c2cc58aa277be27c0a3913de89e9bd177901aaabb121479d41f454c7ab1a3d78 |