This release is a pre-release and may not be stable for production use.
Neuber Correction 💥
A Python tool that corrects elastic FEA results for plastic yielding using Neuber's rule. No more manual iterations or Excel spreadsheets - just plug in your material properties and get accurate stress corrections.
🚀 Quick Start
from neuber_correction import NeuberCorrection, MaterialForNeuberCorrection
# Set up your material (Aluminum 6061-T6 example)
material = MaterialForNeuberCorrection(
yield_strength=240, # MPa
sigma_u=290, # MPa
elastic_mod=68900, # MPa (69 GPa)
eps_u=0.10 # 10%
)
neuber = NeuberCorrection(material)
# Get your corrected stress
elastic_stress = 500 # MPa
corrected_stress = neuber.correct_stress_values([elastic_stress])[0]
print(f"Elastic: {elastic_stress} MPa → Corrected: {corrected_stress:.1f} MPa")
# Output: Elastic: 500 MPa → Corrected: 260.0 MPa
📖 What's the Deal?
When your elastic FEA gives you stresses above the yield strength, those values are unrealistic because they don't account for plastic yielding. Neuber correction fixes that by finding the intersection between the Neuber hyperbola and your material's actual stress-strain curve.
Example: Aluminum 6061-T6 with 500 MPa elastic stress → 260 MPa corrected stress (48% reduction!)
✨ What You Get
✅ Accurate stress corrections - No more overestimating elastic stresses
✅ Material-specific calculations - Uses Ramberg-Osgood model
✅ Visual analysis - Plot the curves and see what's happening
✅ Batch processing - Handle multiple stress values at once
✅ Robust convergence - Newton-Raphson with fallback methods
✅ Performance optimized - Caching and memoization for repeated calculations
🎯 Perfect For
- FEA result correction when stresses exceed yield
- Fatigue analysis with plastic yielding
- Material testing data analysis
- Design validation and optimization
📦 Installation
pip install neuber-correction
Or if you're using uv (recommended):
uv add neuber-correction
🔧 Usage Examples
Basic Stress Correction
from neuber_correction import NeuberCorrection, MaterialForNeuberCorrection
# Steel S355
material = MaterialForNeuberCorrection(
yield_strength=315,
sigma_u=470,
elastic_mod=210000,
eps_u=0.12
)
neuber = NeuberCorrection(material)
# Correct your FEA results
elastic_stresses = [400, 500, 600] # MPa
corrected_stresses = neuber.correct_stress_values(elastic_stresses)
Visual Analysis
# Create a plot showing the correction
fig, ax = neuber.plot_neuber_diagram(500, show_plot=True)
Advanced Settings
from neuber_correction import NeuberSolverSettings
# Custom convergence settings
settings = NeuberSolverSettings(
tolerance=1e-8, # More precise
max_iterations=1000 # More iterations
)
neuber = NeuberCorrection(material, settings)
Performance Features
# Automatic caching for repeated calculations
result1 = neuber.correct_stress_values([500])[0] # Computes
result2 = neuber.correct_stress_values([500])[0] # Uses cache (fast!)
# Clear cache if needed
NeuberCorrection.clear_all_instances()
📚 Documentation
- Quick Start Guide - Get up and running fast
- Theory - The math behind the magic
- FAQ - Common questions and answers
🔬 Theory
Neuber's rule states that the product of stress and strain remains constant:
$$\sigma \cdot \varepsilon = \frac{\sigma_e^2}{E}$$
Where:
- $\sigma$ = actual (corrected) stress
- $\varepsilon$ = actual strain
- $\sigma_e$ = elastic stress (from FEA)
- $E$ = Young's modulus
The tool finds the intersection between the Neuber hyperbola and the Ramberg-Osgood material curve to determine the corrected stress.
🛠️ Development
Setup
git clone https://github.com/manuel1618/neuber-correction.git
cd neuber-correction
uv sync
Testing
uv run pytest
Linting
uv run task lint
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🤝 Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
📖 Sources
This tool is based on Neuber's rule for stress concentration analysis
Made with ❤️ for engineers who need accurate stress analysis
Metadata
Release files for neuber-correction 0.1.19a0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| neuber_correction-0.1.19a0.tar.gz | 21.5 kB | Without provenance | Details for neuber_correction-0.1.19a0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| neuber_correction-0.1.19a0-py3-none-any.whl | Python 3 | none | any | Details for neuber_correction-0.1.19a0-py3-none-any.whl |
Total release size: 43.2 kB
Release files / neuber_correction-0.1.19a0.tar.gz
| Download URL | neuber_correction-0.1.19a0.tar.gz |
|---|---|
| Size | 21.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8d01f99c43f5e32e0ee3913f46a69ca60967c72db3c6606341afbe27b924e524
|
|
BLAKE2b-256 checksum How to use checksums |
223fa0df804af0cb62ff8d91dd79bdf472cdf0491560834f52f57c224be6bf04
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / neuber_correction-0.1.19a0-py3-none-any.whl
| Download URL | neuber_correction-0.1.19a0-py3-none-any.whl |
|---|---|
| Size | 21.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
34a74ec087bc1537db90fd2ccc8d5cce89f14c13550d9997f8940c110233d4d3
|
|
BLAKE2b-256 checksum How to use checksums |
f5da29c8a59b22963b8a9e82962f6e486cc33a302d9ba08ed74eacd2b13458a0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Security for neuber-correction 0.1.19a0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.