Building a Shear Force and Bending Moment Diagram Calculator in Python

Building a Shear Force and Bending Moment Diagram Calculator in Python

In this short Python Project, build a simple calculator for statically determinate beams

⏰ 2 h 44 min | 9 lessons
Published: July 2021
4.59
After completing this course, you will...
understand how to analytically determine the shear force and bending moment diagram for a simply supported beam
understand how to build a Python script to automate the calculation
be comfortable building data visualisations using the plotting library Plotly
be able to apply what you learn to automate other routine engineering calculations
PROJECT OVERVIEW

In this project we’re going to build a Shear Force and Bending Moment Diagram calculator using Python in the Jupyter Notebook development environment.

Generating the shear force and bending moment diagram for a simple beam with anything other than basic loading can be a tedious and time-consuming process. Once you finish this project, you’ll have a calculator that can produce shear force and bending moment diagrams like the ones below, at the push of a button.

Shear and Moment Calculator output | EngineeringSkills.com

Typical output from our shear force and bending moment diagram calculator.

Whether you’re an engineering student or a working engineer, this shear and moment calculator is going to make life a little bit easier for you. For engineering students in particular who are learning how to build shear force and bending moment diagrams, your calculator gives you unlimited examples to test yourself against. The frequent request for ‘example questions’ from students was actually the main motivation to build this calculator in the first place.

This Python mini-project is accompanied by a complete HD video series. You can access the full playlist for free, by enrolling in the project. In the video series, we’ll walk through the build process line by line. So you can build along with me or if you prefer, just download the finished Python code after you enrol in the project.

🚨 For this project I’m working on the assumption that you’re familiar with the concepts of internal shear force and bending moment as stress resultants that arise within a structure due to external loading. If you need a refresher on the basics of shear forces and bending moments, check out my Ultimate Guide to Shear and Moment Diagrams.

As I always say at the start of a new EngineeringSkills project or course – you don’t need to be a Python programmer to complete this project! Complete beginners can work through this project and pick up the programming basics along the way. If you need help getting your coding environment setup, check out this lecture (part of another course but covers what you need to get up and running).

Section 1
Shear and Moment Calculator Project
1. Introduction and project setup
17:15
2. Reactions due to point loads
22:16
3. Shear and moment due to point loads
16:46
4. Shear and moment diagrams with Plotly
22:55
5. Dealing with applied moments
17:10
6. Dealing with uniformly distributed loads
23:59
7. Reactions due to linearly varying distributed loads
13:31
8. Shear and moments due to linearly distributed loads
21:44
9. Testing our shear force and bending moment calculator 📂
9:09
getting-started
Dr Seán Carroll
BEng (Hons), MSc, PhD, CEng MIEI, FHEA
Hi, I’m Seán, the founder of EngineeringSkills.com (formerly DegreeTutors.com). I hope you found this tutorial helpful. After spending 10 years as a university lecturer in structural engineering, I started this site to help more people understand engineering and get as much enjoyment from studying it as I do. Feel free to get in touch or follow me on any of the social accounts.

Do you have some knowledge or expertise you'd like to share with the EngineeringSkills community?
Check out our guest writer programme - we pay for every article we publish.
TRY THIS NEXT
The Direct Stiffness Method for Truss Analysis with Python
The Direct Stiffness Method for Truss Analysis with Python
Build your own finite element truss analysis software using Python and tackle large scale structures.