https://github.com/vitordmarchiori/flappingbeamsimulation
Dynamic simulation of a flexible UAV flapping wing with solar energy harvesting using FEM techniques. Includes deformation and irradiance animations, energy efficiency analysis, and parameter studies.
https://github.com/vitordmarchiori/flappingbeamsimulation
dynamic-simulation energy-harvesting finite-element-method flapping-wing python solar-energy structural-simulation uav
Last synced: 5 months ago
JSON representation
Dynamic simulation of a flexible UAV flapping wing with solar energy harvesting using FEM techniques. Includes deformation and irradiance animations, energy efficiency analysis, and parameter studies.
- Host: GitHub
- URL: https://github.com/vitordmarchiori/flappingbeamsimulation
- Owner: vitordmarchiori
- License: mit
- Created: 2025-04-28T17:36:16.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2025-05-13T19:05:08.000Z (6 months ago)
- Last Synced: 2025-06-01T22:38:08.923Z (6 months ago)
- Topics: dynamic-simulation, energy-harvesting, finite-element-method, flapping-wing, python, solar-energy, structural-simulation, uav
- Language: Python
- Homepage:
- Size: 29 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# đŠī¸ Flapping Beam Simulation with Solar Energy Harvesting â Flapping-Wing UAV
This project simulates, analyzes, and visualizes the structural behavior of a flapping-wing UAV (Unmanned Aerial Vehicle) wing equipped with solar panels along its surface.
It uses a **dynamic Euler-Bernoulli beam model**, discretized via the **1D Finite Element Method (FEM)**, and integrates real-time **solar irradiance calculation** during the flapping motion.
---
## đĻ Project Structure
- `simulate_beam()` â Performs the time-domain simulation of beam deflection, rotation, and irradiance capture.
- `animate_beam()` â Animates the flapping deformation with Hermitian interpolation and node tracking.
- `animate_irradiance()` â Animates and compares irradiance distributions across multiple configurations.
- **Automatic CSV/PNG/MP4 generation** for all key outputs.
---
## đ§ Requirements
- Python 3.8+
- Required Libraries:
- `numpy`
- `matplotlib`
- `pandas`
Optional:
- `Pillow` or `ffmpeg` (for enhanced animation rendering)
---
## đ Features and Functionality
Upon running the main script:
â
Performs transient simulation using Newmark-beta integration
â
Visualizes beam deflection (with Hermite interpolation) and irradiance over time
â
Saves high-resolution `.mp4` animations and `.png` snapshots
â
Exports full simulation data to `.csv` for post-processing
---
## đ Outputs Generated
| Output | Description |
|--------|-------------|
| `beam_animation.mp4` | Beam flapping with real node motion and interpolation |
| `irradiance_animation.mp4` | Time-evolving irradiance distribution (comparative) |
| `energy_per_panel.png` | Energy harvested by each panel |
| `irradiance_final_step.png` | Irradiance snapshot at final time step |
| `nodal_displacements.csv` | Displacement time-history of each node |
| `irradiance.csv` | Irradiance time-history per element |
| `power.csv` | Instantaneous power received by each panel |
---
## đ¯ Objectives
- Quantify the effect of **beam flexibility and motion** on energy harvesting.
- Evaluate **parametric changes** (amplitude, area, frequency) and their outcomes.
- Enable **visual analysis** of physical and energetic behavior of flapping wings.
---
## đ§ Possible Extensions
- Implement spatially varying **EI(x)** profiles
- Include **aerodynamic forces and damping**
- Add **solar incidence angle modeling** and sun tracking
- Use **optimization or ML** for performance tuning
---
## đ ī¸ Customization
You can easily adjust:
| Parameter | Description |
|------------------|----------------------------------------|
| `amplitude` | Vertical motion at the driven node |
| `E`, `I_default` | Beam stiffness |
| `freq`, `amp_alt` | Frequency and amplitude of flapping |
| `A`, `A_alt` | Area of each solar panel |
| `T`, `dt` | Simulation time and time step |
These are defined in the **Global Parameters** section of the script.
---
## đ Final Notes
- The model is modular and expandable.
- All simulations are fully **offline and deterministic**.
- Graphics are **publication-quality**, saved in high-resolution.
- Built for clarity, analysis, and educational exploration.