Amrita Vishwa Vidyapeetham
Physics-Informed Neural Networks for Structural Mechanics
2nd Semester Group Project β GROUP 17
| Course | Code |
|---|---|
| Introduction to Materials Informatics | 23CHY115 |
| Computational Mechanics 2 | 23PHY114 |
| Mathematics for Intelligent Systems 2 | 23MAT112 |
This project explores the use of Physics-Informed Neural Networks (PINNs) to model how a mechanical structure β like a beam or a plate β deforms under a known load. By embedding the physics of the problem directly into the neural network, we predict displacement across the structure without relying on a traditional mesh.
To ensure accuracy, we compare predictions with ANSYS Mechanical 2025 R1 (a well-established FEM tool). This approach blends machine learning with classical physics for faster, mesh-free structural analysis.
DEFINE PROBLEM SET INITIAL & DESIGN NEURAL TRAIN THE PINN
DOMAIN & GEOMETRY β BOUNDARY β NETWORK β USING OPTIMIZER
CONDITIONS ARCHITECTURE
β
VALIDATE OBTAIN ANALYSIS & RUN SIMULATION
PREDICTIONS β SOLUTION β VISUALIZATION β IN ANSYS
WITH ANSYS RESULT
Governing Equation:
Where w(x) = transverse deflection, E = Young's Modulus (70 GPa for aluminum), I = bhΒ³/12 = moment of inertia.
Beam Setup:
| Parameter | Value |
|---|---|
| Length L | 1.0 m |
| Width b | 0.02 m |
| Thickness h | 0.005 m |
| Material | Aluminum (E = 70 GPa) |
| Support | Fixed-Fixed |
| Load | Central point load (Gaussian approximation) |
ANSYS Result:
PINN Results:
Governing Equation:
Where w(x,y) = transverse deflection, D = flexural rigidity, Ξ½ = Poisson's ratio.
Plate Setup:
| Parameter | Value |
|---|---|
| Length L | 1.0 m |
| Width b | 1.0 m |
| Thickness t | 0.005 m |
| Material | Aluminum |
| Support | Fixed at all edges |
| Load | Central point load (Gaussian) |
ANSYS Result:
PINN Results:
Validation Metrics:
| Metric | Value |
|---|---|
| Validation MSE | 4.09e-08 |
| Validation RΒ² Score | 0.94691 |
Governing Equation:
With sinusoidal transverse body force:
Beam Setup:
| Parameter | Symbol | Value |
|---|---|---|
| Length | L | 1.0 m |
| Width | W | 0.2 m |
| Height | H | 0.2 m |
| First LamΓ© constant | Ξ» | 1.0 Pa |
| Shear modulus | ΞΌ | 1.0 Pa |
| Force amplitude | Fβ | 1.0 N/mΒ³ |
| Support | β | Fixed at x=0 and x=L |
PINN Results:
Input β [x] or [x, y] or [x, y, z] (1β3 neurons)
β
Hidden β 4 Γ 32 neurons (tanh activation, Glorot normal init)
β
Output β w(x) or w(x,y) or [u, v, w]
| Case | Input | Output | Optimizer | Epochs |
|---|---|---|---|---|
| 1D Beam | x | w | Adam + L-BFGS-B | 8000+ |
| 2D Plate | x, y | w | Adam + L-BFGS-B | 8000+ |
| 3D Beam | x, y, z | u, v, w | Adam | 10,000 |
beam-elasticity-pinn/
β
βββ 1d_beam/
β βββ simulation_1d.py # 1D Euler-Bernoulli PINN
β
βββ 2d_plate/
β βββ simulation_2d.py # 2D Kirchhoff plate PINN
β
βββ 3d_beam/
β βββ simulation_3d.py # 3D Navier-Cauchy PINN
β
βββ results/ # Generated PINN output plots
β βββ 1d_pinn_deflection.png
β βββ 1d_pinn_vs_ansys.png
β βββ 1d_loss_history.png
β βββ 2d_pinn_deflection.png
β βββ 2d_pinn_vs_ansys.png
β βββ 3d_displacement_3d.png
β βββ 3d_displacement_xy.png
β
βββ ansys/ # ANSYS validation screenshots
β βββ 1d_ansys_deformation.png
β βββ 2d_ansys_deformation.png
β βββ comparison_notes.md
β
βββ requirements.txt
βββ .gitignore
βββ README.md
git clone https://github.com/sasmxtha/beam-elasticity-pinn.git
cd beam-elasticity-pinnpython -m venv venv source venv/bin/activate # Linux / macOS venv\Scripts\activate # Windows
pip install -r requirements.txt
# Case 1 β 1D Aluminum Beam python 1d_beam/simulation_1d.py # Case 2 β 2D Aluminum Plate python 2d_plate/simulation_2d.py # Case 3 β 3D Elastic Beam python 3d_beam/simulation_3d.py
β GPU is automatically detected and used if available via TensorFlow.
| Case | PINN Max Deflection | ANSYS Max Deflection | RΒ² Score |
|---|---|---|---|
| 1D Beam | ~β0.035 m | β0.034985 m | ~0.99 |
| 2D Plate | β0.01727 m | 0.0026818 m (Z-dir) | 0.947 |
| 3D Beam | Full field (u,v,w) | β | β |
- Raissi, M., Perdikaris, P., & Karniadakis, G. E. (2019). Physics-informed neural networks. Journal of Computational Physics, 378, 686β707.
- Lu, L., et al. (2021). DeepXDE: A deep learning library for solving differential equations. SIAM Review, 63(1), 208β228.
- ANSYS Mechanical 2025 R1, Student Edition.
This project is licensed under the MIT License.








