{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Chapter 16: Acid Base Equilibria and Solubility Equilibria" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.10: Predicting_precipitation_reactions.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "// Predicting precipitation reactions\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.10\n');\n", "\n", "Ksp=1.1*10^-10;//solubility product of BaSO4\n", "\n", "//for Ba2+ ion\n", "N=0.004;//normality, M\n", "V=200;//vol in mL\n", "n=N*V/1000;//moles\n", "\n", "//for K2SO4sol\n", "N1=0.008;//normality, M\n", "V1=600;//vol in mL\n", "n1=N1*V1/1000;//moles\n", "\n", "Nnew=n*1000/(V+V1);//conc of Ba2+ ions in final sol\n", "N1new=n1*1000/(V+V1);//conc of SO4 2- ions in final sol\n", "\n", "Q=Nnew*N1new;//as Q=[Ba2+][SO4 2-]\n", "if(Q>Ksp) then//determination of precipitation\n", " printf('\t the solution is supersaturated and hence a precipitate will form\n');\n", " else \n", " printf('\t the solution is not supersaturated and hence a precipitate will not form\n');\n", " end;\n", "//End" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.11: separation_by_fractional_precipitation.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "//separation by fractional precipitation\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.11\n');\n", "\n", "//for Br\n", "Br=0.02;//conc of Ag+ ions, M\n", "Ksp1=7.7*10^-13;//solubility product of AgBr\n", "Ag1=Ksp1/Br;//conc of Ag+ ions at saturated state, M\n", "\n", "//for Cl\n", "Ksp2=1.6*10^-10;//solubility product of AgCl\n", "Cl=0.02;//conc of Cl- ions, M\n", "Ag2=Ksp2/Cl;//conc of Ag+ ions at saturated state, M\n", " \n", "printf('\t to precipitate Br- without precipitating Cl- the concentration of Ag must be greater than %2.1f *10^-11 M but less than %2.1f *10^-9 M\n',Ag1*10^11,Ag2*10^9);\n", " \n", "//End" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.12: common_ion_effect_and_solubility.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "//common ion effect and solubility\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.12\n');\n", "\n", "N_AgNO3=6.5*10^-3;//normality of AgNO3, M\n", "AgCl=143.4;//mol mass of AgCl, g\n", "//Let 's' be the molar solubility of AgCl in AgBr solution, M\n", "Ksp=1.6*10^-10;//solubility product of AgCl\n", "//Now Ag+ ion conc is AgNO3 conc + s and Cl- ion conc is 's', Now Ksp=[Ag+][Cl-]=(s+6.5*10^-3)*(s)=6.5*10^-3*s(approx as s<<6.5*10^-3)\n", "\n", "Ag=N_AgNO3;//conc of Ag+ ions as 's' is negligible, M\n", "s=Ksp/Ag;//as Ksp=[Ag+][Cl-], molar solubility of AgCl, M\n", "\n", "solubility=s*AgCl;//solubility of AgCl in AgBr solution, g/L\n", "\n", "printf('\t the solubility of AgCl in AgBr solution is : %2.2f *10^-6 g/L\n',solubility*10^6);\n", " \n", "//End" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.14: calculation_of_Concentration_for_precipitation.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "// calculation of Concentration for precipitation\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.14\n');\n", "\n", "FeCl2=0.003;//normality of FeCl2, M\n", "Fe=FeCl2;//as Fe2+ is strong electrolyte, conc of Fe2+=conc of FeCl2, M\n", "Ksp=1.6*10^-14;//solubility product of FeCl2\n", "\n", "OH=sqrt(Ksp/Fe);//as Ksp=[Fe2+][OH-]^2, conc of OH- ions, M\n", "\n", "//Let 'x' be the initial concentration of the NH3, M\n", "//conc of NH3 at equilibrium is 'x-OH' as NH3 hydrolyses to give OH- ions\n", "Kb=1.8*10^-5;//ionisation constant of base\n", "\n", "x=(OH^2)/Kb+OH;//as Kb=[NH4+][OH-]/[NH3]\n", "\n", "printf('\t to initiate precipitation the conc of NH3 must be slightly greater than : %2.1f *10^-6 M\n',x*10^6);\n", " \n", "//End" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.15: Computation_of_concentration_at_complex_ion_equilibrium.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "//Computation of concentration at complex ion equilibrium\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.15\n');\n", "\n", "CuSO4=0.2;//normality of CuSO4, M\n", "NH3=1.2;//initial conc of NH3, M\n", "VNH3=1;//volume of NH3, L\n", "Kf=5*10^13;//formation constant\n", "CuNH34=CuSO4;//conc of Cu(NH3)4 2+, M\n", "NH3=NH3-4*CuNH34;//conc of NH3 after formation of complex, as 4 moles of NH3 react to form 1 mole complex, M\n", "\n", "//let 'x' be the conc of Cu2+ ions\n", "x=CuNH34/(NH3^4*Kf);//as Kf=[Cu(SO4)3 2+]/[Cu2+][NH3]^4\n", "\n", "printf('\t the conc of Cu2+ ions in equilibrium is : %2.1f *10^-13 M\n',x*10^13);\n", " \n", "//End" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.16: Computation_of_molar_solubility_in_complex_ion_solution.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "//Computation of molar solubility in complex ion solution\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.16\n');\n", "\n", "InitNH3=1;//initial conc of NH3, M\n", "Ksp=1.6*10^-10;//solubility product of AgCl\n", "Kf=1.5*10^7;//formation constant of complex\n", "K=Ksp*Kf;//overall equilibrium constant\n", "\n", "//let 's' be the molar solubility of AgCl, hence conc of [Ag(NH3)2+] and [Cl-] is 's' and hence conc of NH3 = InitNH3-2s\n", "//K=[Ag(NH3)2+][Cl-]/[NH3]^2=s*s/(InitNH3-2s)^2, taking square root s/(InitNH3-2s)=sqrt(K)\n", "s=sqrt(K)/(1+2*InitNH3*sqrt(K));//molar solubility of AgCl, M\n", "\n", "printf('\t amount of AgCl which can be dissolved in 1 L of 1 M NH3 sol in equilibrium is : %2.3f M\n',s);\n", " \n", "//End" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.1: Computation_of_pH_using_common_ion_effect.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "// Computation of pH using common ion effect\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.1\n');\n", "\n", "//(a)\n", "InitCH3COOH=0.2;//Initial concentration of CH3COOH solution, M\n", "\n", "//Let 'x' be the equilibrium concentration of the [H+] and [CH3COO-] ions after dissociation of [CH3COOH], M\n", "\n", "Ka=1.8*10^-5;//equilibrium constant of acid, M\n", "\n", "x=sqrt(Ka*InitCH3COOH);//from the definition of ionisation constant Ka=[H+]*[CH3COO-]/[CH3COOH]=x*x/(0.2-x), which reduces to x*x/0.2, as x<<0.2 (approximation)\n", "\n", "pH=-log10(x);//since x is the conc. of [H+] ions\n", "\n", "printf('\t (a) the pH of CH3COOH solution is : %4.2f \n',pH);\n", "\n", "//(b)\n", "InitCH3COONa=0.3;//Initial concentration of CH3COONa solution and is equal to conc of Na+ and CH3COO- as it completely dissociates, M\n", "\n", "InitCH3COOH=0.2;//Initial concentration of CH3COOH solution, M\n", "//Let 'x' be the equilibrium concentration of the [H+] and hence conc of [CH3COO-] ions is '0.3 + x', M\n", "\n", "x=Ka*InitCH3COOH/InitCH3COONa;//from the definition of ionisation constant Ka=[H+]*[CH3COO-]/[CH3COOH]=x*(0.3+x)/(0.2-x), which reduces to x*0.3/0.2(approximation)\n", "\n", "pH=-log10(x);//since x is the conc. of [H+] ions\n", "\n", "printf('\t (b) the pH of CH3COOH and CH3COONa solution is : %4.2f \n',pH);\n", "\n", "//End" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.3: Computation_of_pH_using_common_ion_effect.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "// Computation of pH using common ion effect\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.3\n');\n", "\n", "Ka=1.8*10^-5;//ionisation constant of acid\n", "\n", "//(a)\n", "InitCH3COONa=1;//Initial concentration of CH3COONa solution and is equal to conc of Na+ and CH3COO- as it completely dissociates, M\n", "\n", "InitCH3COOH=1;//Initial concentration of CH3COOH solution, M\n", "//Let 'x' be the equilibrium concentration of the [H+] and hence conc of [CH3COO-] ions is '0.3 + x', M\n", "\n", "x=Ka*InitCH3COOH/InitCH3COONa;//from the definition of ionisation constant Ka=[H+]*[CH3COO-]/[CH3COOH]=x*(1+x)/(1-x), which reduces to x(approximation)\n", "\n", "pH=-log10(x);//since x is the conc. of [H+] ions\n", "\n", "printf('\t (a) the pH of CH3COOH and CH3COONa solution is : %4.2f \n',pH);\n", "\n", "//(b)\n", "HCl=0.1;//moles of HCl added to 1L solution\n", "//as H+ reacts completely with CH3COO- ions to move the reaction forward\n", "CH3COO=InitCH3COONa-HCl;//conc of CH3COO- ions, M\n", "CH3COOH=InitCH3COOH+HCl;//conc of CH3COOH, M\n", "\n", "//now for the equilibrium of CH3COOH and its ions, Let 'x' be the equilibrium concentration of the [H+] and hence conc of [CH3COO-] ions is 'CH3COO + x', M\n", "x=Ka*CH3COOH/CH3COO;//from the definition of ionisation constant Ka=[H+]*[CH3COO-]/[CH3COOH]=x*(0.9+x)/(1.1-x), which reduces to x*0.9/1.1(approximation)\n", "\n", "pH=-log10(x);//since x is the conc. of [H+] ions\n", "\n", "printf('\t (b) the pH of solution after adding HCl is : %4.2f \n',pH);\n", "\n", "//End" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.5: Computation_of_pH_in_a_titration_of_weak_acid_and_strong_base.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "// Computation of pH in a titration of weak acid and strong base\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.5\n');\n", "\n", "InitCH3COOH=0.1;//Initial concentration of CH3COOH solution, M\n", "VCH3COOH=25;//volumeof CH3COOH, mL\n", "nCH3COOH=InitCH3COOH*VCH3COOH/1000;\n", "Ka=1.8*10^-5;//equilibrium constant of acid, M\n", "Kb=5.6*10^-10;//equilibrium constant of base, M\n", "\n", "//(a)\n", "N=0.1;//Initial concentration of NaOH solution, M\n", "V=10;//Initial volume of NaOH solution, mL\n", "n=N*V/1000;//Initial moles of NaOH solution\n", "\n", "nCH3COOH_tit=nCH3COOH-n;//moles of CH3COOH after titration\n", "nCH3COO=n;//moles of CH3COO after titration\n", "\n", "H=nCH3COOH_tit*Ka/nCH3COO;//conc of H+ ions, M\n", "\n", "pH=-log10(H);//since H is the conc. of [H+] ions\n", "\n", "printf('\t (a) the pH of the solution is : %4.2f \n',pH);\n", "\n", "//(b)\n", "N=0.1;//Initial concentration of NaOH solution, M\n", "V=25;//Initial volume of NaOH solution, mL\n", "n=N*V/1000;//Initial moles of NaOH solution\n", "\n", "nCH3COOH_tit=nCH3COOH-n;//moles of CH3COOH after titration\n", "nCH3COO=n;//moles of CH3COO- ions after titration\n", "V_total=V+VCH3COOH;//total volume after titration\n", "\n", "CH3COO=nCH3COO/V_total*1000;//conc of CH3COO- ions, M\n", "//Let 'x' be the equilibrium concentration of the [OH-] and [CH3COOH] ions after hydrolysis of [CH3COO-], M\n", "x=sqrt(Kb*CH3COO);//from the definition of ionisation constant Kb=[OH-]*[CH3COOH]/[CH3COO-]=x*x/(0.05-x), which reduces to x*x/0.05, as x<<0.05 (approximation)\n", "\n", "pOH=-log10(x);//since x is the conc. of [OH-] ions\n", "pH=14-pOH;\n", "\n", "printf('\t (b) the pH of the solution is : %4.2f \n',pH);\n", "\n", "//(c)\n", "N=0.1;//Initial concentration of NaOH solution, M\n", "V=35;//Initial volume of NaOH solution, mL\n", "n=N*V/1000;//Initial moles of NaOH solution\n", "\n", "n_tit=n-nCH3COOH;//moles of NaOH after titration\n", "nCH3COO=nCH3COOH;//moles of CH3COO- ions after titration\n", "V_total=V+VCH3COOH;//total volume\n", "\n", "OH=n_tit/V_total*1000;//conc of OH- ions, M\n", "pOH=-log10(OH);//since OH is the conc. of [OH-] ions\n", "pH=14-pOH;\n", "\n", "printf('\t (c) the pH of the solution is : %4.2f \n',pH);\n", "\n", "//End" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 16.6: EX16_6.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "// Computation of pH in a titration of weak base and strong acid at equivalence point\n", "\n", "clear;\n", "clc;\n", "\n", "printf('\t Example 16.6\n');\n", "\n", "InitNH3=0.1;//Initial concentration of NH3 solution, M\n", "VNH3=25;//volume of NH3, mL\n", "nNH3=InitNH3*VNH3/1000;\n", "Ka=5.6*10^-10;//equilibrium constant of acid, M\n", "\n", "N=0.1;//Initial concentration, M\n", "V=VNH3/InitNH3*N;//Initial volume, mL\n", "\n", "V_total=V+VNH3;//total volume of the mixture, mL\n", "\n", "n_NH4Cl=nNH3;//moles of NH4Cl\n", "NH4Cl=n_NH4Cl/V_total*1000;//conc of NH4+ ions formed, M\n", "\n", "//Let 'x' be the equilibrium concentration of the [H+] and [NH3] ions, M\n", "x=sqrt(Ka*NH4Cl);//from the definition of ionisation constant Ka=[H+]*[NH3]/[NH4+]=x*x/(NH4+-x), which reduces to x*x/NH4+, as x<