In [1]:

```
# Variables
weight = 10. #weight of NaCl in grams
volume = 1. #volume of water in litres
weight_water = 1000. # weight of water in grams (Weight = Volume*Density, density of water = 1g/cc = 1g/ml = 1000g/l)
molwt_NaCl = 58.5 #molecular weight of NaCl in grams
molwt_water = 18. #molecular weight of water in grams
hf = 6.002; #enthalpy change of fusion in kJ/mol at 0 degree celsius
P = 101.325; #pressure in kPa
T = 273.15; # freezing point temperature of water at the given pressure in K
R = 8.314; #universal gas constant in J/molK;
# Calculations
x2 = (weight/molwt_NaCl)/((weight/molwt_NaCl)+(weight_water/molwt_water))
delt = (R*T**2*x2)/(hf*10**3)
# Results
print ' The depression in freezing point of water when 10g of NaCl solute is added = %0.2f K'%(delt);
```

In [2]:

```
# Variables
weight = 10.; #weight of NaCl in grams
volume = 1.; #volume of water in litres
weight_water = 1000.; # weight of water in grams (Weight = Volume*Density, density of water = 1g/cc = 1g/ml = 1000g/l)
molwt_NaCl = 58.5; #molecular weight of NaCl in grams
molwt_water = 18; #molecular weight of water in grams
lat_ht = 2256.94; #latent heat of vaporization in kJ/kg at 100 degree celsius (obtained from steam tables)
P = 101.325; #pressure in kPa
T = 373.15; #boiling point temperature of water at the given pressure in K
R = 8.314; #universal gas constant in J/molK
# Calculations
x2 = 0.0031
hv = (lat_ht*molwt_water)/1000
delt = (R*T**2*x2)/(hv*10**3)
# Results
print ' The elevation in boiling point of water when 10g of NaCl solute is added = %0.2f K'%(delt);
```

In [3]:

```
# Variables
weight = 10.; #weight of NaCl in grams
weight_water = 1000.; # weight of water in grams
molwt_NaCl = 58.5; #molecular weight of NaCl in grams
molwt_water = 18.; #molecular weight of water in grams
T = 300.; #prevailing temperature of water in K
R = 8.314; #universal gas constant in (Pa m**3)/(mol K);
v = 18*10**-6; #molar volume in m**3/mol
# Calculations
x2 = 0.0031
pi = ((R*T*x2)/v)*10**-3
# Results
print ' The osmotic pressure of a solution conatining 10g of NaCl in 1000g of water at 300K = %0.2f kPa'%(pi);
```

In [5]:

```
import math
# Variables
temp = 20. # prevailing tempearture in degree celsius
melt_temp = 80.05; # melting point of naphthalene in degree celsius
hf = 18.574 # enthalpy of fusion in kJ/mol
R = 8.314 # universal gas constant in J/molK
# Calculations
t = temp+273.15
melt_t = melt_temp+273.15
x2 = math.exp(((hf*10**3)/R)*((1./melt_t)-(1./t)))
# Results
print ' The ideal solubility of naphthalene at 20 degree celsius = %0.4f'%(x2);
```

In [6]:

```
# Variables
t = 295.43; #prevailing temperature in K
sat_p = 6.05; #Sasturation pressure of carbon dioxide at the prevailing temperature in MPa
p = 0.1; #pressure at which solubility has to be determined in MPa
# Calculations
x2 = p/sat_p
# Results
print ' The solubility of carbon dioxide expressed in mole fraction of carbon dioxide in solution\
at 0.1MPa = %0.4f'%(x2);
```