Numsol Hardcopy Hydrostatic Calcu

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 16

PAMANTASAN NG LUNGSOD NG VALENZUELA

Tongco St., Maysan, Valenzuela City


College of Engineering and Information Technology

HyCalc: A Calculator for Hydrostatic Force Acting on


Vertical, Inclined, and Curved Surface

A Project Report as partial fulfillment of the requirements for the subject

EM8: Numerical Solution for Civil Engineering Problems

Submitted By:

Caluag, Lance Aaron

Petalio, Aaron V.

Sipat, Ryan Justin M.

Submitted To:

Engr. Jayef P. Doblado

December 19, 2023


PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

I. Introduction
Gates and barriers, among other water control structures, are essential to regulate fluid flow in
a variety of engineering applications. Understanding the hydrostatic forces acting on these
structures is essential for their design, stability, and overall effectiveness. This MATLAB program
examines the hydrostatic forces acting on gates of varying forms and orientations. Our focus
extends to gates with diverse shapes, involving rectangular, triangular, circular, and semi-circular
gates positioned vertically, inclined, or in curved configurations. It provides a thorough analysis
of the principles defining these forces as well as the creation of a MATLAB program to calculate
them.

The distribution of pressure that fluids apply to submerged surfaces provides rise to hydrostatic
forces. The calculation involves leveraging the hydrostatic force equation, considering specific
gravity, surface area, and depth of submersion. Understanding force distribution and moments
which are essential for structural stability—is aided by parameters such as centroids, moments of
inertia, eccentricities, and the center of pressure for each type of gate.

A comprehensive MATLAB program has been designed in response to the complexity of


hydrostatic force estimates for various gate configurations. Users can input parameters into this
application, including gate types, their dimensions, various fluid properties, as well as their
orientation. The application utilizes mathematical formulas unique to individual gate types,
ensuring precise and accurate calculation of hydrostatic forces, centroids, and associated
parameters.

The MATLAB program serves as a helpful tool for hydraulic and civil engineers, offering
applications in the analysis of gates for dams, essential for flood control structures. The tool aids
decision-making processes related to gate design and optimization by providing a user-friendly
interface and comprehensive outcomes. This report attempts to clarify methods, explain the
mathematical foundation of hydrostatic force analysis, and highlight practical implications in the
field of engineering as it delves into the specifics of MATLAB software. The main objective is to
equip engineers as well as engineering students with an effective computational tool for hydrostatic
PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

force analysis on gates with different forms and orientations, as well as to make a significant
contribution to the field of engineering.

II. Statement of the Problem


Understanding the hydrostatic forces that act on various gate configurations presents a
difficulty not only for civil engineers but also for civil engineering students in designing structures,
particularly with water control. The complexity of computations, which likely depends on the
dimensions, characteristics of different fluids, and structures of different gates, is challenging. The
objective is to develop a user-interface-friendly MATLAB application that may assist engineers
as well as students.

III. Solution when solved manually


1. Circular Gate (Inclined)

Situation — A circular gate 1.5m in diameter is inclined 45° with the vertical. The center
of the gate is 10m below the water surface.

a) Calculate the total hydrostatic force on the gate.

b) Find the eccentricity.

c) Calculate the distance of the total force from the bottom of the gate.

Problem Figure (Circular Gate - Inclined)


PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

Solution:

a) Determining the total force acting on the gate:

Formula to be used: Wherein the problem:

Fh = γħA γ = (1)(9.81) = 9.81


ħ = 10
𝜋𝜋
Where: ACircle = ( × 1.52 )
4
γ = unit weight of the fluid the object is submerged on Input the values:
ħ = is the depth of the centroid of the submerged surface
below the water surface Fh = (9.81)(9.47)( �𝜋𝜋4 × 1.52 �
A = represents the area of the surface that is submerged
in the fluid
Fh = 173.357 kN
b) Determining the eccentricity:

Formula to be used: Wherein the problem:

𝜋𝜋
𝐼𝐼𝑐𝑐𝑐𝑐 = ( × 1.54 )
𝐼𝐼𝑐𝑐𝑐𝑐 64

𝑒𝑒 = 𝜋𝜋
ACircle = ( × 1.52 )
𝐴𝐴 × ȳ 10
4

ȳ=
𝑐𝑐𝑐𝑐𝑐𝑐45°
Where:
e = eccentricity or distance from the centroid to center
Input the values:
of pressure 𝜋𝜋
( × 1.54 )
Icg = centroidal moment of inertia 𝑒𝑒 = 𝜋𝜋 64
10
A = area of the surface that is submerged in the fluid ( × 1.52 )( )
4 𝑐𝑐𝑐𝑐𝑐𝑐45°
ȳ = distance from surface of fluid to the centroid of
body
𝑒𝑒 = 0.009944 𝑚𝑚
PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

c) Calculating the distance of the total force from the bottom of the gate:

Equation to be used: Input the values:

Z = 0.75 - e 𝑧𝑧 = 0.75 − 0.009944

Where:
𝑧𝑧 = 0.74
Z = be the distance of the hydrostatic force from
the bottom of the gate

0.75 = value of the radius of the circle


e = calculated eccentricity

IV. Objectives
i. Input-Process-Output

Figure 1. Input-Process-Output
PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

ii. Application Design

Figure 2. Main Window Figure 3. Vertical Surfaced Circle

Figure 4. Inclined Surface Circle Figure 5. Vertical Surface Rectangle

Figure 6. Inclined Surface Rectangle Figure 7. Vertical Surface Triangle


PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

Figure 8. Inclined Surface Triangle Figure 9. Vertical Surface Inverted Triangle

Figure 10. Inclined Surface Inverted Triangle Figure 11. Vertical Surface Trapezoid

Figure 12. Inclined Surface Trapezoid Figure 13. Curved Surface


PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

V. Code
• For the Main Window

• For the Circle


PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

• For the Rectangle

• For the Triangle


PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

• For the Inverted Triangle

• For the Trapezoid


PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

• For the Curved Surface

VI. Explanation of the code


1. Main Application Menu
• Properties
- Properties are defined to access the other Matlap app program that are set as
private property for specific calculation base on the users given situation.
• Button
- The button component is utilized for its buttonpushed function that enables the
user to be redirected to the Hydrostatic Force calculator for a specific situation.
Every button was assigned for each type of situation and using the syntax
app.PropertyName each calculator can be access.
• Image
- The image component is use to design the User Interface making the application
more pleasing for the user to use.
PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

2. For Circle, Rectangle, Triangle, Inverted Triangle, and Trapezoid


• Tab Group Component
- Acts as container for organizing tabs vertical and inclined for specific
calculations according to the situation.
• Calculate Button Pushed Function
- It is used to execute the calculation of the results using the values inputted in
the numerical edit field.
• Numeric Edit Field Components
- Used for inputting the necessary values for calculation and for displaying the
results.
• Property
- Using the properties syntax, it is set to private and set a property value that
enables the main menu to access the main calculator for the given shapes.
• If else statement syntax
- The if else statement is mainly used to distinguished the value of the specific
gravity. It will be 1 if the input is 0 and when the input is greater than 0 it will
store the value that the user had input.
3. For Curved Surface
• Drop Down Component
- The drop-down component is used for the four different cases of curved surface.
It is used to determine the case under the switch syntax the program will
execute.
• Numerical Edit Field Component
- It is used to input the values needed to calculate the results and also used to
show the values for the results of the execution of the program.
• Calculate Button Pushed Function
- It is used to execute the calculation of the results using the values inputted in
the numerical edit field.
• Switch syntax
PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

- The switch syntax is use to which case with syntax case expression to use
according to what the user pick in the drop-down menu. Each case is for the
four cases with different ways of calculating the results.
• Case
- The case syntax is used to specify the case for the following code for the
calculation.
• Property
- Using the properties syntax,it is set to private and set a property value that
enables the main menu to access the curved surface property.
• If else statement syntax
- The if else statement is mainly used to distinguished the value of the specific
gravity. It will be 1 if the input is 0 and when the input is greater than 0 it will
store the value that the user had input.

VII. User Manual


PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology
PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

VIII. Sample Output


PAMANTASAN NG LUNGSOD NG VALENZUELA
Tongco St., Maysan, Valenzuela City
College of Engineering and Information Technology

You might also like