import math
# Input data
T = 5. # Time taken for a liquid to cool from 80 to 50 degree centigrade in minutes
t11 = 80. # The initial temperature of the liquid in degree centigrade
t12 = 50. # The final temperature of the liquid in degree centigrade
t21 = 60. # If the initial temperature of the liquid in degree centigrade
t22 = 30. # If the final temperature of the liquid in degree centigrade
ts = 20. # The temperature of the surrounding in degree centigrade
# Calculations
# The time taken for the liquid to cool from 60 to 30 degree centigrade in
# minutes
T1 = ((math.log((t22 - ts) / (t21 - ts))) /
(math.log((t12 - ts) / (t11 - ts)))) * T
# Output
print 'The time taken for a liquid to cool from 60 to 30 degree centigrade is t = %3.0f minutes ' % (T1)
# Input data
dw = 1. # The density of water in g/cm**3
da = 0.8 # The density of alcohol in g/cm**3
t1 = 100. # The time taken for the water to cool from 50 to 40 degree centigrade in seconds
t2 = 74. # The time taken for the alcohol to cool from 50 to 40 degree centigrade in seconds
V = 1. # Let the volume of either liquid be in cm**3
# Calculations
m = V * dw # The mass of water in g
M = V * da # The mass of alcohol in g
w = V # Water equivalent of each calorimeter in cm**3
# The specific heat of alcohol in calorie/g-K
C = ((((m + w) * t2) / (M * t1)) - (w / M))
# Output
print 'The specific heat of alcohol is C = %3.1f calorie/g-K' % (C)
import math
# Input data
t = 5. # Time taken for a body to cool from 60 to 40 degree centigrade in minutes
t11 = 60. # The initial temperature of the body in degree centigrade
t12 = 40. # The final temperature of the body in degree centigrade
ts = 10. # The temperature of the surrounding in degree centigrade
# Calculations
# The constant value for the first case at ts
K = math.log((t12 - ts) / (t11 - ts))
# The temperature after the next 5 minutes in degree centigrade
x = ((math.exp(K)) * (t12 - ts)) + ts
# Output
print 'The temperature after the next 5 minutes is x = %3.0f degree centigrade ' % (x)
import math
# Input data
T = 4. # Time taken for a liquid to cool from 70 to 50 degree centigrade in minutes
t11 = 70. # The initial temperature of the liquid in degree centigrade
t12 = 50. # The final temperature of the liquid in degree centigrade
t21 = 50. # If the initial temperature of the liquid in degree centigrade
t22 = 40. # If the final temperature of the liquid in degree centigrade
ts = 25. # The temperature of the surrounding in degree centigrade
# Calculations
# The time taken for the liquid to cool from 50 to 40 degree centigrade in
# minutes
T1 = ((math.log((t22 - ts) / (t21 - ts))) /
(math.log((t12 - ts) / (t11 - ts)))) * T
# Output
print 'The time taken for a liquid to cool from 50 to 40 degree centigrade is t = %3.3f minutes ' % (T1)
import math
# Input data
t = 6. # Time taken for a liquid to cool from 80 to 60 degree centigrade in minutes
T = 10. # To find the temperature after the time in minutes
t11 = 80. # The initial temperature of the liquid in degree centigrade
t12 = 60. # The final temperature of the liquid in degree centigrade
ts = 30. # The temperature of the surrounding in degree centigrade
# Calculations
# The constant value for the first case at ts
K = (math.log((t12 - ts) / (t11 - ts))) / (-t)
# The temperature after the next 10 minutes in degree centigrade
x = ((math.exp(-T * K)) * (t12 - ts)) + ts
# Output
print 'The temperature after the next 10 minutes is x = %3.2f degree centigrade ' % (x)
import math
# Input data
t = 5. # The time taken for a body to cool from 80 to 64 degree centigrade in minutes
t11 = 80. # The initial temperature of the body in degree centigrade
t12 = 64. # The final temperature of the body in degree centigrade
t21 = 52. # The temperature of the body after 10 minutes in degree centigrade
T = 10. # The time taken for a body to cool from 80 to 52 degree centigrade in minutes
T1 = 15. # To find the temperature after the time in minutes
# Calculations
# The temperature of the surroundings in degree centigrade
ts = ((t21 * t11) - (t12**2)) / (t11 + t21 - (2 * t12))
# The constant value for the first case at ts
K = (math.log((t21 - ts) / (t12 - ts)))
# The temperature after the next 15 minutes in degree centigrade
x = ((math.exp(K)) * (t21 - ts)) + ts
# Output
print '(1)The temperature of the surroundings is %3.0f degree centigrade \n (2)The temperature after the 15 minutes is %3.0f degree centigrade ' % (ts, x)
# Input data
t2 = 2. # The time taken for the liquid to cool from 50 to 40 degree centigrade in minutes
t11 = 50. # The initial temperature of the liquid in degree centigrade
t12 = 40. # The final temperature of the liquid in degree centigrade
t1 = 5. # The time taken for the water to cool from 50 to 40 degree centigrade in minutes
m = 100. # The mass of water in gms
M = 85. # The mass of liquid in gms
w = 10. # Water equivalent of the vessel in gms
# Calculations
# The specific heat of a liquid in calories/g-K
C = (((m + w) * (t2 * 60)) / (M * (t1 * 60))) - (w / M)
# Output
print 'The specific heat of a liquid is C = %3.1f calories/g-K' % (C)
# Input data
V = 22400. # The volume of One gram molecule of a gas at N.T.P in cm**3
p = 76. # The pressure in cm of Hg
T = 273. # The temperature in K
# Calculations
P = p * 13.6 * 981 # The pressure in dynes/cm**2
# The universal gas constant for one gram molecule of a gas in ergs/mole-K
R = (P * V) / T
# Output
print 'The universal gas constant for one gram molecule of a gas is R = %3.4g ergs/mole-K' % (R)
# Input data
Cp = 0.23 # Specific heat of air at constant pressure
J = 4.2 * 10**7 # The amount of energy in ergs/cal
d = 1.293 # The density of air at N.T.P in g/litre
p = 76. # The pressure in cm of Hg
T = 273. # The temperature in K
# Calculations
P = p * 13.6 * 980 # The pressure in dynes/cm**2
V = (1000 / d) # Volume of one gram of air at N.T.P in cm**3
r = (P * V) / T # The gas constant for one gram of a gas in ergs/g-K
Cv = Cp - (r / J) # Specific heat of air at constant volume
# Output
print 'The specific heat of air at constant volume is Cv = %3.4f ' % (Cv)
# Input data
w = 4. # The Molecular weight of helium
v = 22400. # The volume of one gram molecule of a gas at N.T.P in cm**3
p = 76. # The pressure in cm of Hg
T = 273. # The temperature in K
J = 4.2 * 10**7 # The amount of energy in ergs/cal
# Calculations
V = (v / w) # The volume of one gram of helium at N.T.P in cm**3
P = p * 13.6 * 980 # The pressure in dynes/cm**2
r = (P * V) / T # The gas constant for one gram of a gas in ergs/g-K
C = r / J # The difference in the two specific heats of one gram of helium
# Output
print 'The difference in the two specific heats of one gram of helium is Cp-Cv = %3.4f' % (C)
# Input data
V = 25. # Volume of gasoline consumed by an engine in litres/hour
cv = 6. * 10**6 # The calorific value of gasoline in calories/litre
P = 35. # The output of the engine in kilowatts
# Calculations
h = V * cv # Total heat produced by gasoline in one hour in calories
H = h / 3600 # Heat produced per second in cal/s
I = H * 4.2 # Heat produced per second in joules/s or watts
E = ((P * 1000) / I) * 100 # The efficiency in percent
# Output
print 'The efficiency of the engine is %3.0f percent ' % (E)