Skip to content

Chamuditha000/Beam-deflection-Analysis--Numerical-methods-vs-Machine-learning

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

13 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Beam-deflection-Analysis--Numerical-methods-vs-Machine-learning

The project is about finding beam deflection using numerical methods and machine learning approach to compare the results

Overview

This project demonstrates how numerical methods and machine learning can be applied to solve real-world engineering problems. Specifically, it focuses on solving the beam deflection equation:

where represents the deflection (in meters). This equation models the deflection of a beam under load, accounting for stiffness, material resistance, and external forces.

Motivation

In structural engineering, predicting and analyzing beam deflection is critical to ensure safety and optimal design. While numerical methods have been the standard for such calculations, machine learning offers a modern approach to predict solutions efficiently based on prior data, making it suitable for more complex cases.

Objectives

Solve the beam deflection equation using:

Bisection Method

False Position Method

Fixed Point Iteration Method

Newton-Raphson Method

Train a machine learning model to predict deflection based on load parameters.

Compare the results from numerical methods and machine learning predictions with the exact solution.

Methods

  1. Bisection Method

Divides the interval into two halves and iteratively narrows the range containing the root.

Guarantees convergence if .

  1. False Position Method

Uses a straight-line approximation between two points to estimate the root.

  1. Fixed Point Iteration Method

Transforms the equation into and iteratively converges to the root.

  1. Newton-Raphson Method

Uses the tangent at a current guess to rapidly converge to the root.

  1. Machine Learning Model

Implements a regression model to predict deflection using data generated from the equation.

Dependencies

Python 3.8+

Libraries:

πŸ”Έ numpy

πŸ”Έ matplotlib

πŸ”Έ scipy

πŸ”Έ sklearn

πŸ”Έ tensorflow (or pytorch, optional for ML)

Install dependencies using:

pip install numpy matplotlib scipy scikit-learn tensorflow

How to Run

Clone the repository:

git clone https://github.com/yourusername/beam-deflection-analysis.git cd beam-deflection-analysis

Run numerical methods:

python numerical_methods.py

Train and test the machine learning model:

python ml_model.py

Project Structure

# beam-deflection-analysis/
β”‚
β”œβ”€β”€ numerical_methods.py     # Contains Python implementations of 4 numerical methods
β”œβ”€β”€ ml_model.py              # Machine learning model for deflection prediction
β”œβ”€β”€ README.md                # Project documentation
β”œβ”€β”€ requirements.txt         # Dependencies
└── results/                 # Results and comparison plots

Results

The project compares the following aspects:

Accuracy of numerical methods vs. machine learning.

Convergence speed for numerical methods.

Prediction error for machine learning.

Future Work

Expand the project to handle more complex equations, e.g., higher-order beam models.

Integrate neural networks for predicting deflection under varying material properties.

Contributors

(https://github.com/Chamuditha000)

About

The project is about finding beam deflection using numerical methods and machine learning approach to compare the results

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors