library(pipenostics)
# \donttest{
# Let's consider a pipe in district heating network with
diameter <- 762 # [mm]
wall_thickness <- 10 # [mm]
UTS <- 434.3697 # [MPa]
# which transfers heat-carrier (water) at
operating_pressure <- 0.588399 # [MPa].
temperature <- 95 # [°C]
# During inline inspection four corroded areas (defects) are detected with:
depth <- c(2.45, 7.86, 7.93, 8.15) # [mm]
# whereas the length of all defects is not greater 200 mm:
length <- rep(200, 4) # [mm]
# Corrosion rates in radial and in longitudinal directions are not well-known and
# may vary in range .01 - .30 mm/year:
rar = function(n) stats::runif(n, .01, .30) / 365
ral = function(n) stats::runif(n, .01, .30) / 365
# Then POFs related to each corroded area are near:
pof <- mepof(depth, length, rep(diameter, 4), rep(wall_thickness, 4),
rep(UTS, 4), rep(operating_pressure, 4), rep(temperature, 4),
rar, ral, method = "dnv")
print(pof)
# 0.000000 0.252510 0.368275 0.771595
# So, the POF of pipe is near
print(max(pof))
# 0.771595
# The value of POF changes in time. So, in a year after inline inspection of
# the pipe we can get something near
pof <- mepof(depth, length, rep(diameter, 4), rep(wall_thickness, 4),
rep(UTS, 4), rep(operating_pressure, 4), rep(temperature, 4),
rar, ral, method = "dnv", days = 365)
print(pof)
# 0.000000 0.525539 0.648359 0.929099
# for entire pipe we get something near:
print(max(pof))
# 0.929099
# Two years ago before inline inspection the pipe state was rather good:
pof <- mepof(depth, length, rep(diameter, 4), rep(wall_thickness, 4),
rep(UTS, 4), rep(operating_pressure, 4), rep(temperature, 4),
rar, ral, method = "dnv", days = -2 * 365)
print(pof)
# 0.000000 0.040780 0.072923 0.271751
# for entire pipe we get something near:
print(max(pof))
# 0.271751
# }
Run the code above in your browser using DataLab