# Variables
T = 40 #C
R = 0.0820 #lit-atm deg**-1 mol**-1
v = 0.381 #lit
b = 0.043 #lit
a = 3.6
# Calculations
P = (R*(273+T)/(v-b))-(a/v**2)
# Results
print 'Pressure = %.1f atm'%(P)
# Variables
T = 0 #C
R = 0.0820 #lit-atm deg**-1 mol**-1
p = 400. #atm
# Calculations
V = R*(273+T)/p
# Results
print 'Volume of the ideal gas = %.4f lit mol**-1'%(V)
# Variables
p = 400. #atm
T = 273 #K
R = 0.0820 #lit-atm deg**-1 mol**-1
k = 1.27
# Calculations
V = k*R*T/p
# Results
print 'Volume of the ideal gas = %.3f lit mol**-1'%(V)
# Variables
V = 0.381 #lit
T = 313. #K
R = 0.0820 #lit-atm deg**-1 mol**-1
pc = 72.9 #atm
# Calculations
p = R*T/V
r = p/pc
# Results
print 'Pressure of carbon dioxide gas = %.1f atm'%(p)
print ' ratio = %.3f '%(r)
# Variables
n1 = 0.25 #mole
n2 = 0.75 #mole
l = 0.0832 #lit
T = 50 #C
p1 = 404 #atm
p2 = 390 #atm
# Calculations
P = n1*p1+n2*p2
# Results
print 'Total Pressure = %.f atm'%(P)
# Variables
n1 = 0.25 #mole
nh = 0.75 #mole
p = 400. #atm
T = 50. #C
vn = 0.083 #lit
vh = 0.081 #lit
# Calculations
V = n1*vn+vh*nh
# Results
print 'Volume of given mixture is = %.3f lit'%(V)