FINDING MINIMUM PRESSURE TO BREAK ICE WITH ACV (using NEWTON-RAPHSON METHOD)
AIM:
To find the minimum pressure required to break the ice using Air Cushion Vehicle (ACV) using Newton-Raphson Method
OBJECTIVES:
- To understand the concept of Newton-Raphson Method
- To understand the concept of breaking of ice using the ACV
- To use Python to get the above mentioned results
INTRODUCTION:
The ice breaking mechanism under a slow moving air cushion vehicle is explored. The bending moments which cause the circumferential cracks in the ice are determined for the case where the pressure of the air cushion is sufficient to depress the water and force air below the ice field. References are given to the more difficult case where the pressure is insufficient to form an air cavity.
The formula used for determining the pressure is as follows:
`p^3(1-beta^2) + (0.4hbeta^2-(sigmah^2)/r^2)p^2 +(sigma^2h^4)/(3r^4)p - ((sigmah^2)/(3r^2))^3 = 0`
where `p` = cushion pressure
`h` = thickness of ice field
`r` = size of air cushion
`sigma` = tensile strength of ice
`beta` = function for width of ice wedge
Newton-Raphson Method:
The Newton-Raphson method (also known as Newton's method) is a way to quickly find a good approximation for the root of a real-valued function `f(x) = 0`. It uses the idea that a continuous and differentiable function can be approximated by a straight line tangent to it.
Suppose you need to find the root of a continuous, differentiable function `f(x)`, and you know the root you are looking for is near the point `x = x_0`. Then Newton's method tells us that a better approximation for the root is
`x_1 = x_0 - (f(x_0)/(f'(x_0)))`
This process may be repeated as many times as necessary to get the desired accuracy. In general, for any `x` value `x_n`, the next value is given by
`x_(n+1) = x_n - f(x_n)/(f'(x_n))`
A relaxation factor `alpha` can also be multiplied to the division to either slow down the process or make it faster.
PROCEDURE OF COMPLETION:
- The expression and its derivative were defined in two different functions respectively for easier accessible.
- 'Plotly' module was used to create tabulation according to the data that was created.
- The iteration of Newton-Raphson technique was used by using a while loop.
- Modulus of the function value was taken for relational operator to avoid the negative values that the function can generate.
The following code gives us the minimum pressure required:
# BREAKING ICE WITH AIR CUSHION VEHICLE - FINDING MINIMUM PRESSURE REQUIRED USING NEWTON-RAPHSON METHOD
# Importing modules
import numpy as np
import matplotlib.pyplot as plt
import plotly.graph_objects as pg
# Initializing parameters
beta = 0.5
sigma = 150*144
r = 40
# function
def fx(p, h):
# Expression
f1 = pow(p, 3) * (1 - pow(beta, 2))
f2 = ((0.4 * h * pow(beta, 2)) - (sigma * pow(h, 2)) / (pow(r, 2))) * pow(p, 2)
f3 = ((pow(sigma, 2) * pow(h, 4)) / (3 * pow(r, 4))) * p
f4 = pow(((sigma * pow(h, 2)) / (3 * pow(r, 2))), 3)
expr = f1 + f2 + f3 - f4
return expr
# derivative of the function
def fpx(p, h):
f1 = 3 * pow(p, 2) * (1 - pow(beta, 2))
f2 = ((0.4 * h * pow(beta, 2)) - (sigma * pow(h, 2)) / (pow(r, 2))) * 2 * p
f3 = (pow(sigma, 2) * pow(h, 4)) / (3 * pow(r, 4))
expr1 = f1 + f2 + f3
return expr1
# applying Newton-Raphson method
def pressure(h):
p_guess = 40
# relaxation factor
a = 0.5
i = 0
while abs(fx(p_guess, h)) > 1e-5:
i = i + 1
p_guess = p_guess - a*(fx(p_guess, h)/fpx(p_guess, h))
return p_guess, i
min_press = []
h = np.array([0.6, 1.2, 1.8, 2.4, 3.0, 3.6, 4.2])
n = []
iter1 = []
for j in range(len(h)):
[p1, i1] = pressure(h[j])
min_press.append(p1)
iter1.append(i1)
n.append(j+1)
plt.plot(h, min_press)
plt.grid()
plt.ylabel('Pressure')
plt.xlabel('Thickness of Ice')
plt.show()
fig = pg.Figure(data=[pg.Table(header=dict(values=['Sl.No', 'Pressure', 'Thickness of Ice', 'Iterations']), cells=dict(values=[n, min_press, h, iter1]))])
fig.show()
The code for getting the optimal relaxation factor (considering h to be 0.6) is as follows:
# PROGRAM TO FIND THE OPTIMAL RELAXATION FACTOR
# importing modules
import numpy as np
import matplotlib.pyplot as plt
# initializing parameters
beta = 0.5
sigma = 150*144
r = 40
h = 0.6
# defining functions
def fx(p):
# Expression
f1 = pow(p, 3) * (1 - pow(beta, 2))
f2 = ((0.4 * h * pow(beta, 2)) - (sigma * pow(h, 2)) / (pow(r, 2))) * pow(p, 2)
f3 = ((pow(sigma, 2) * pow(h, 4)) / (3 * pow(r, 4))) * p
f4 = pow(((sigma * pow(h, 2)) / (3 * pow(r, 2))), 3)
expr = f1 + f2 + f3 - f4
return expr
# derivative of the function
def fpx(p):
f1 = 3 * pow(p, 2) * (1 - pow(beta, 2))
f2 = ((0.4 * h * pow(beta, 2)) - (sigma * pow(h, 2)) / (pow(r, 2))) * 2 * p
f3 = (pow(sigma, 2) * pow(h, 4)) / (3 * pow(r, 4))
expr1 = f1 + f2 + f3
return expr1
# range of relaxation factors
a = np.linspace(0.1, 1.9, 1000)
iterations = []
# newton-raphson method
for i in range(len(a)):
p_guess = 30
j = 0
while abs(fx(p_guess)) > 1e-7:
j = j+1
p_guess = p_guess-a[i]*(fx(p_guess)/fpx(p_guess))
iterations.append(j)
iterations = np.array(iterations)
# plotting
plt.figure()
plt.plot(a, iterations)
plt.plot(a, [min(iterations)]*len(a), 'r--')
plt.grid()
plt.xlabel('Relaxation factor')
plt.ylabel('Iterations')
plt.legend(['Actual graph', 'Optimal relaxation factor'])
plt.show()
OBSERVATIONS:
As we can see, increasing the value of h, the iterations to get to the relaxation varies a lot as it depends on the value of relaxation factor taken in to account.
The optimal relaxation factor was found in the following figure for h = 0.6:
Here, we can see that for slightly different relaxation factors, the iteration numbers increase or decrease in a huge number. Here, the optimal relaxation factor is around 1.00
CONCLUSION:
Newton-Raphson Method is used fot optimizing constraint minimization problems where the formula is kind of very compelling and confusing. For relatively easier formulas, differentiability is still a very good method.