#Calculate the hydraulic conductivity in cm/sec.
import math
##initialisation of variables
L= 30. ##cm
A= 177. ##cm^2
h= 50. ##cm
Q= 350. ##cm^3
t= 300. ##sec
##claculations
k=Q*L/(A*h*t)
##results
print'%s %.4f %s'% ('hydraulic conductivity = ',k,' cm/sec ')
#Determine the hydraulic conductivity of the soil in in./sec.
import math
##initialisation of variables
L= 203. ##mm
A= 10.3 ##cm^2
a= 0.39 ##cm^2
h0= 508. ##mm
h180= 305. ##mm
t= 180. ##sec
##calculations
k= 2.303*a*L*math.log10(h0/h180)/(A*t)
##results
print'%s %.2f %s'% ('hydraulic conductivity of sand = ',k,' in/sec ')
#The hydraulic conductivity of a clayey soil is 3 107 cm/sec. The viscosity of water at 25°C is 0.0911 104 g # sec/cm2
#Calculate the absolute permeability of the soil.
import math
##initialisation of varilables
k= 3e-7 ##cm/sec
n= 0.0911e-4 ##g*sec/cm^2
dw= 1. ##g/cc
##calculations
K= k*n/dw
##results
print'%s %.2e %s'% ('absolute premeability = ',K,' cm^2 ')
#With k 5.3 105 m/sec for the permeable layer, calculate the rate of seepage through it in m3 /hr/m width if H 3 m and a 8°.
import math
##initialisation of variables
k= 5.3e-5 ##m/sec
H= 3 ##m
a= 0.139 ##radians
##calculations
A= H*math.cos(a)
i= math.sin(a)
q= k*i*A*3600
##results
print'%s %.4f %s'% ('rate of seepage = ',q,' m^3/hr/m ')
import math
#calculate flow rate
##initialisation of variables
L= 50. ##m
k= 0.08e-2##m/sec
h= 4. ##m
H1= 3. ##m
H= 8. ##m
a= 0.139 ##radians
##calculations
i= h*math.cos(a)/L
A= H1*math.cos(a)
q= k*i*A
##results
print'%s %.5f %s'% ('flow rate = ',q,' m^3/sec/m ')
#calculate hydraulic conductivity at void ratio of 0.65
##initialisation of variables
k1= 0.02 ##cm/sec
e1= 0.5
e2= 0.65
##calculations
k2= k1*(e2**3/(1.+e2))/(e1**3/(1.+e1))
##results
print'%s %.2f %s'% ('hydraulic conductivity at void ratio of 0.65 =',k2,'cm/sec ')
#calculate the value of grain size and plot the graph
import math
%matplotlib inline
import warnings
warnings.filterwarnings('ignore')
from math import log
import numpy
from math import tan
import matplotlib
from matplotlib import pyplot
#given
e=numpy.array([100,96,84,50,0])
p=numpy.array([0.06,0.0425,0.02,0.015,0.0075])
#calculations
#results
pyplot.plot(p,e)
pyplot.xlabel('Percent passing')
pyplot.ylabel('grain size,mm')
pyplot.title('Graph of percent passinge vs grain size')
pyplot.show()
print('look at the axis reverse in text book')
#calculate hydraulic conductivity
##initialisation of variables
e= 0.6
D10= 0.09 ##mm
##calculations
k= 2.4622*(D10**2*(e**3/(1+e)))**0.7825
##results
print'%s %.4f %s'% ('hydraulic conductivity = ',k,' cm/sec ')
#calculate hydraulic conductivity
##initialisation of variables
e= 0.6
D10= 0.09 ##mm
D60= 0.16 ##mm
##calculations
Cu=D60/D10
k= 35*(e**3/(1+e))*(Cu**0.6)*(D10**2.32)
##results
print'%s %.3f %s'% ('hydraulic conductivity =',k,'cm/sec ')
import math
#calculate hydraulic conductivity
##initialisation of variables
k1= 0.302e-7 ##cm/sec
k2= 0.12e-7 ##cm/sec
e1= 1.1
e2= 0.9
e= 0.75
##calcualtions
n= (math.log10((k1/k2)*((1+e1)/(1+e2))))/math.log10(e1/e2)
C= k1/(e1**n/(1+e1))
k= C*(e**n/(1+e))
##results
print'%s %.e %s'% ('hydraulic conductivity =',k,'cm/sec')
#calculate ration of equivalent hydraulic conductivity
##initialisation of variables
H1= 2. ##m
H2= 3. ##m
H3= 4. ##m
k1= 1e-4 ##cm/sec
k2= 3.2e-2 ##cm/sec
k3= 4.1e-5 ##cm/sec
##calculations
H= H1+H2+H3
Kh= (1./H)*((k1*H1)+(k2*H2)+(k3*H3))
Kv= H/((H1/k1)+(H2/k2)+(H3/k3))
P= Kh/Kv
##results
print'%s %.2f %s'% ('ration of equivalent hydraulic conductivity =',P,' ')
import math
#calculate rate of water supply
##initialisation of variables
H= 450. ##mm
h= 150. ##mm
k1= 1e-2 ##cm/sec
k2= 3e-3 ##cm/sec
k3= 4.9e-4 ##cm/sec
h1= 300. ##mm
##calculations
Kv= H/(h*(1./k1+1./k2+1./k3))
i= h1/H
q= Kv*i*100.*3600.
##results
print'%s %.2f %s'% ('rate of water supply =',q,' cm/hr ')