Chapter 3: Ultrasonics

Example 3.1, Page 74

In [1]:
#Variable Declaration
t=1.6*1e-3 #thickness in meter
v=5760. #velocity in m/s

#Calculations
lemda=2*t#wavelength
f=v/lemda#fundamental frequency 

#Result
print 'fundamental frequency =',f/1e6,'MHz'
fundamental frequency = 1.8 MHz

Example 3.2, Page 75

In [2]:
#Variable Declaration
t=40*1e-2;
#pulse covers 2x distance in arriving back
#so,  30*1e-6=2*x/v
#and, 2nd pulse will cover a distance of 2*40 cm in 80*1e-6 seconds
#therfore,  80*1e-6=(2*40*1e-2)/v
#compare both equation
e1=30;
e2=40*2

#Calculation
x=e1*t*2/(2*e2);

#Result
print 'distance of the flow from near end =',x/1e-2,'cm' 
distance of the flow from near end = 15.0 cm

Example 3.3, Page 76

In [3]:
#Variable Declaration
f_diff=50*1e3 #in Hz
v=5000 #in m/s

#Calculations
#f1=v/2*t
#f2=2v/2t
#f2-f1=v/2t
t=v/(2*f_diff)

#Result
print 'Thickness of steel plate =',t,'m'
Thickness of steel plate = 0.05 m

Example 3.4, Page 77

In [4]:
from math import pi

#Variable Declaration
f=1e6 #frequency in Hz
L=1 #inductance in henry

#Calculation
#f=(1/2*pi)*(sqrt(1/(L*C)))
c=1/(4*pi**2*f**2*L);#capacitance

#Result
print 'capacitance =',round(c/1e-12,3),'pF'
capacitance = 0.025 pF