September 2020

Cut and Fill Volume for given GL and FL profile, using Python Code

Hi, So you have a numerical problem to solve, to find the cut and fill volume on a given profile of ground with a certain width given. The problem at hand will be processed into a section as given below in the image. If there is a cut or fill, between any particular chainage, can […]

Cut and Fill Volume for given GL and FL profile, using Python Code Read More »

Python Code – Section Areas ( of Level Section, Two-Level Section, and Three-Level Sections ) and Cut and Fill Volume using Prismoidal Formula

In order to find the Cut and Fill Volume of soil for a given profile, the first step is to calculate the section areas at a specified interval. End areas are calculated for a level trapezoid differently than for a two-level and three-level section. The following Python code contains all the formulas at the right

Python Code – Section Areas ( of Level Section, Two-Level Section, and Three-Level Sections ) and Cut and Fill Volume using Prismoidal Formula Read More »

Python Code for Drawing BMD and SFD (Bending Moment and Shear Force) for a SSB with Point Load

 Hi, Introducing Two Programs for Shear Force and Bending Moment Diagrams In this article, I am excited to share with you two programs that I have developed for drawing Shear Force and Bending Moment Diagrams. One of these programs is available here for free! The first program is a simple yet effective code that specifically

Python Code for Drawing BMD and SFD (Bending Moment and Shear Force) for a SSB with Point Load Read More »

USCS and AASHTO Soil Classification, using a Python Program Code

 Hi, The following code is written in Python language, so to run the code you must have Python installed in your computer. Also, make sure to have ‘math’ library installed.  When you run the code, it will ask you to enter the inputs related to the soil properties such as #200 sieve % finer, #4

USCS and AASHTO Soil Classification, using a Python Program Code Read More »

Python Code for Mohr’s Circle, – Stresses at a given angle theta, Principal stresses and their Planes, Maximum Shear Stress and its Plane

Hi, You can use the Python to draw Mohr’s Circle. In Structure Mechanics, taught to Civil Engineering and Mechanical engineering students, one has to find the stresses at given oblique planes. Principal stresses and maximum shear stresses are important to find, and also their corresponding planes. One can use the stress transformation equations or Mohr’s

Python Code for Mohr’s Circle, – Stresses at a given angle theta, Principal stresses and their Planes, Maximum Shear Stress and its Plane Read More »

Solve Linear Equations in Three Variables – Using Python, Numpy and Sympy , Using the Given Code

 Hi, In the series of posts about Python for Civil Engineers, I have come with something from linear algebra. While dealing with statics problems, such as finding unknown forces in space truss members, one has to deal with the system of linear equations in three variables.  One can use the ‘Sympy’ and ‘Numpy’ libraries in

Solve Linear Equations in Three Variables – Using Python, Numpy and Sympy , Using the Given Code Read More »

Python Code to Find out the Dot Product of Vectors and Angle between them (Using end Point Co-ordinates too)

Hi,  Sometimes you are given with the endpoints’ co-ordinates of vectors, and sometimes you are directly given the vectors. For both conditions, the code given below will work. You have to input them as and when asked. End results will give the vectors, their magnitudes, their dot product and the angle between the two vectors. 

Python Code to Find out the Dot Product of Vectors and Angle between them (Using end Point Co-ordinates too) Read More »

Python Code – Discharge in Rectangular Channel using Manning’s Formula

 Hi, Next in the series ‘Python for Civil Engineers’ is the code for Manning’s formula for the rectangular channel. One has to provide the needed inputs to get the discharge, in the given rectangular channel, as the output. The Manning’s formula for discharge calculations can be used for various channels such as rectangular, trapezoidal etc.

Python Code – Discharge in Rectangular Channel using Manning’s Formula Read More »

Vertical Equal Tangent Parabolic Curve – Solution Code in Python (Computer Program)

 Hi, Now solving the vertical parabolic curve for the stations and elevations at the full stations is easier with the coding. A computer program that I have coded for you runs on Pycharm (Python). Pycharm is a software that is used for offline coding on your personal computer. If you have a good Internet connection,

Vertical Equal Tangent Parabolic Curve – Solution Code in Python (Computer Program) Read More »

PHP Code Snippets Powered By : XYZScripts.com