3pc-sandfreq
3pc-sandfreq is a Python library for free vibration analysis of shear deformable anisotropic sandwich plates. It provides a Sandfreq class to calculate natural frequencies and mode shapes, considering shear deformation effects in composite sandwich construction.
Installation
Use the package manager pip to install 3pc-sandfreq. Since the package and its dependencies are available on PyPI, you can install them directly:
pip install 3pc-sandfreq
Alternatively, you can install it from the local source directory:
pip install .
API Reference
Sandfreq Class
The primary component of this package is the Sandfreq class, which takes a panel, a load case, and analysis grid settings to compute natural frequencies and mode shapes.
from sandfreq.sandfreq import Sandfreq
Required Parameters
When initializing Sandfreq, the following parameters are required:
panel(Panel): An instance of thePanelclass (from3pc-panel) representing the sandwich plate panel.loads(Loads): An instance of theLoadsclass (from3pc-loads) containing the applied in-plane loads ($N_{xx}$, $N_{yy}$, $N_{xy}$).number_of_terms(int): The number of terms to use in the Ritz/analytical solver.number_of_points_x(int): Number of reporting points along the length (x-axis).number_of_points_y(int): Number of reporting points along the width (y-axis).
Calculated Properties
The class calculates the following properties:
pairs: List of $(m, n)$ pairs for all $i, j = 1, 2, \dots, M$, where $M$ is the number of terms in the analysis.K33: Loads dependent part of the stiffness matrix $K_{33}$ for all pairs.lambdaEV: Right eigenvalues of the generalized eigenvalue problem: $K = \lambda_{EV} \cdot M$.vr: Right eigenvectors of the generalized eigenvalue problem.lambda_cr: Critical eigenvalue.vr_cr: Critical right eigenvector.mn_cr: Critical $(m, n)$ pair.lambdaP: Sorted list of positive eigenvalues.lambda1tolambda5: First to fifth critical (lowest positive) eigenvalues (natural frequencies in Hz).mn1tomn5: Dominant $(m, n)$ mode shapes corresponding to natural frequencieslambda1tolambda5.
Methods
Sandfreq.fromDict(**kwargs)
Initializes a Sandfreq instance using a dictionary of keyword arguments.
Usage Examples
Basic Initialization
Below is an example of performing a sandwich free vibration analysis.
from panel.panel import Panel
from loads.loads import Loads
from sandfreq.sandfreq import Sandfreq
# Assuming pnl (Panel) and ld (Loads) are already defined
sf = Sandfreq(
panel=pnl,
loads=ld,
number_of_terms=4,
number_of_points_x=11,
number_of_points_y=11
)
# Access natural frequencies and their dominant mode shapes
print("First Natural Frequency (Hz):", sf.lambda1)
print("Dominant (m, n) for lambda1:", sf.mn1)
Commands
The package provides a command-line interface entry point. After installing, you can run the application using:
sandfreq input.cfg
(This entry point is defined in sandfreq.__main__:main)
Options
config(positional): Specify the configuration file (.cfg) to run the analysis.-h, --help: Show the help message and exit.-v, --version: Show the version number.-s, --sample: Copy example files (materials, plies, cores, laminates, panels, loads, config) to the current directory.
Configuration File (sandfreq.cfg)
The sandfreq command requires a configuration file (typically named sandfreq.cfg). Below is an example based on sandfreq/examples/example001/sandfreq.cfg:
[files]
materials = materials.json
plies = plies.json
cores = cores.json
laminates = laminates.json
panels = panels.json
loads = loads.json
output = output.txt
[analysis]
number_of_terms = 4
number_of_points_x = 11
number_of_points_y = 11
[files] Section
This section defines the paths to the required input JSON files and the desired output file:
materials: Path to the materials JSON file. Follows the format expected by3pc-material.plies: Path to the plies JSON file. Follows the format expected by3pc-ply.cores: Path to the cores JSON file.laminates: Path to the laminates JSON file. Follows the format expected by3pc-laminate.panels: Path to the panels JSON file. Follows the format expected by3pc-panel.loads: Path to the loads JSON file. Follows the format expected by3pc-loads.output: Path to the text file where the sandwich free vibration analysis results will be written.
[analysis] Section
This section specifies the analysis settings:
number_of_terms: The number of terms to use in the Ritz/analytical solver.number_of_points_x: Number of reporting points along the length (x-axis).number_of_points_y: Number of reporting points along the width (y-axis).
Citation
If you use this library in your research or work, please cite it as follows:
APA Format:
Rastogi, N., & Seresta, O. (2026). 3pc-sandfreq: Python library for free vibration analysis of shear deformable anisotropic sandwich plates. PyPI. https://pypi.org/project/3pc-sandfreq/
BibTeX:
@software{3pc_sandfreq,
author = {Rastogi, Naveen and Seresta, Omprakash},
title = {3pc-sandfreq: Python library for free vibration analysis of shear deformable anisotropic sandwich plates},
year = {2026},
url = {https://pypi.org/project/3pc-sandfreq/}
}
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file 3pc_sandfreq-1.0.0.tar.gz.
File metadata
- Download URL: 3pc_sandfreq-1.0.0.tar.gz
- Upload date:
- Size: 23.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8bd78242bbb4d0a0aafc0810fd84dd8097a186e658ae2e799a7024741b15ab54
|
|
| MD5 |
719984528c6ddc9c2fb428d746fa573c
|
|
| BLAKE2b-256 |
c73efd644c262419e0ca9f6295018e8ace79baec3086d888e0ac78a40375f2aa
|
File details
Details for the file 3pc_sandfreq-1.0.0-py3-none-any.whl.
File metadata
- Download URL: 3pc_sandfreq-1.0.0-py3-none-any.whl
- Upload date:
- Size: 27.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e94b14569ca11b34607c78b7e197cb712ecb47d2a174fbc4e3b2b641670c0d34
|
|
| MD5 |
f2da44820615333920f60a270b067d1e
|
|
| BLAKE2b-256 |
34e5844f3c11164141766fa8b99818e86729eb147d54e1fa9a7700fcf30489a2
|