The Binding of Two Types of Symmetric Ligands to an Isotropic Linear Lattice by Alan R. Wolfe

This Mathematica  notebook calculates and plots the Scatchard plot, neighbor-effect parameters, and conditional probabilities for the binding of two types of symmetric ligands to an isotropic lattice. It can only be used after the appropriate initialization notebook has been evaluated.  To perform the calculations, simply set the input variables to the desired values and execute the Action-Evaluate Notebook command.  This may be repeated with different values for the input variables.

INPUT VARIABLES for all types of isotherm:

points = 10; kL1 = 1; kL2 = 1; nL1 = 2; nL2 = 1; 
wL1 = 1.1; wL2 = 2; wL12 = 0.5; type = 3;

"type" indicates which type of isotherm is desired.  
type = 1 -> a constant concentration of bound ligand 2; 
type = 2 -> a constant concentration of free ligand 2; 
type = 3 -> a constant total concentration of ligand 2.

INPUT VARIABLES for 1 type of isotherm:

(* type 1 *)  fracR2Sat = 0.2; 
(* type 2 *)  freeL2 = 2; 
(* type 3 *)  totalL2 = 2; polymer = 0.1;

fracR2Sat is the fraction of the maximum possible ratio of bound 
ligand 2 to lattice residues that is present on the lattice.  

freeL2 is the concentration of free ligand 2 expressed in the same 
units used for kL2.  

totalL2 is the total concentration of ligand 2; polymer is the total 
lattice residue concentration.  Both concentrations are expressed in 
the same units used for kL2.

(* CALCULATE THE NEIGHBOR-EFFECT PARAMETERS AND 
SCATCHARD PLOT *)  scroll = 1

(*  Determine initial value of r2.  
(Note - if the first data point on the plots is calculated 
incorrectly for type 2 or 3 isotherms, it may help to increase the 
value of the variable loopNumber.  This data point may be checked 
by calculating a type 1 isotherm at the calculated r2 of the initial 
point of the type 2 or 3 isotherm; if correct, the initial 
neighbor-effect values will be the same.)  *)

(* Initialize program parameters and calculate binding of
ligand 2 at r1 = 0 for type 2 or type 3 isotherms *)  scroll = 1

flag = False ; 
r1 = 0 ; EL1 = 1 ; 
If [ wL2 == 0, r2Sat = 1/(nL2 + 1), r2Sat = 1/nL2 ] ; 
setLimits ; 
If [ type==1, r2 = fracR2Sat r2Sat ] ; 
If [ type==3, FreeL2 := TotalL2-R2 polymer ] ; 
loopNumber = 10 ; 
If [ type==2, loopArray = Range [1, loopNumber] ; 
     X2 = 0.01 ; EL2 = 1 ; 
     Map [ Function [ zz, 
          FreeL2 = freeL2 zz/loopNumber ; neL2a ], loopArray ]  ] ; 
If [ type==3, loopArray = Range [1, loopNumber] ; 
     X2 = 0.01 ; r2 = 0.01 ; EL2 = 1 ; 
     Map [ Function [ zz, 
          TotalL2 = totalL2 zz/loopNumber ; neL2b ], loopArray ]  ] ; 
r2initial = r2 ; 
f = 1 - nL1 r1 - nL2 r2 ; 
x1 = r1/f ; x2 = r2/f ; 
If [ type==1, EL2 = ( 1-x2 + Sqrt [ (1-x2)^2 + 4 x2 wL2 ] )/2 ] ; 
If [ !wL12==1, EL1 = ( EL2 + x2 wL12 )/( EL2 + x2 ) ] ; 
checkLimits ; 
If [ flag, printWarning3 ; r1ZeroError = True; dropPoints = 1, 
     r1ZeroError = False ; dropPoints = 0 ] ;

(* Initialize loop parameters and output arrays *) 
r1SatDetermine ; neChoose ; 
xAxisInterval = r1Sat/(points) ; 
abscissa = Range [1, points-1] ; abscissa2 = {} ; 
points2 = points ; 
AppendTo [ abscissa2, points2 - 1/2] ; points = points+1 ; 
AppendTo [ abscissa2, points2 - 1/4] ; points = points+1 ; 
abscissa = xAxisInterval Join [ abscissa, abscissa2 ] ; 
r1L1finitial = r1L1f ; EL1initial = EL1 ; EL2initial = EL2 ; 
r2L2finitial = r2L2f ; 
x2initial = x2 ; 
ffinitial = ff ;

(* Evaluate neighbor-effect parameters for r1 < r1Sat *)  scroll = 1

startPrint ; 
ordinate = Map [ Function [ zz, r1 = zz ; 
     f = 1 - nL1 r1 - nL2 r2 ; 
     x1 = r1/f ; 
     x2 = r2/f ; 
     If [ needCheck, 
          If [ flag==True, 
               {EL1,EL2} = {1,1} ; 
               dropPoints = dropPoints + 1 ] ; 
          If [ flag==False, ne ; checkLimits ; 
               If [ flag==True, dropPoints = dropPoints + 1 ] ] , 
          ne ] ; 
     If [ flag==False, Print [ r1//N, "     ", r1L1f//N ] ] ; 
     {r1L1f, EL1, EL2, r2, r2L2f,x1,x2,ff} ], abscissa ] ; 
Print [ r1Sat//N,"         0" ] ;

(* Evaluate NE parameters & conditional probabilities at r1 = r1Sat *)  scroll = 1

PrependTo [ ordinate, 
     {r1L1finitial,EL1initial,EL2initial,r2initial,
          r2L2finitial,0,x2initial,ffinitial} ] ; 
chooseNEandCP ; 
AppendTo [ ordinate, {0, EL1, EL2, r2, finalr2L2f,0,0,0} ] ;

(* Indicate which equations were used in the calculations *)  scroll = 1

Print [ "ne = ", neChoice, " ; NE = ", NEchoice, 
     " ; CP = ", CPchoice] ; 
Print [ "r1Sat = ", r1Sat//N, " ; r2 at r1Sat = ", r2//N ] ;

(* DISPLAY THE SCATCHARD PLOT FOR LIGAND 1 *)  scroll = 1

makePlot [ 1, 0, "r1/L1f", "        Scatchard plot - ligand 1" ] ;

(* PLOT THE NEIGHBOR-EFFECT PARAMETERS *)  scroll = 1

makePlot [ 2, EL1initial, "eL1","NE for free L1 sites" ]

makePlot [ 3, EL2initial, "eL2", "NE for free L2 sites" ]

(* PLOT THE BINDING DATA FOR LIGAND 2 *)  scroll = 1

If [ wL1==0 && !wL12==0 && nL2==1 && (type==2 || type==3), 
     makePlot [ 4, r2initial, "r2", "  [bound ligand 2]/[polymer]" ], 
     makePlot [ 4, 0, "r2", "  [bound ligand2]/[polymer]" ]  ]

If [ wL1==0 && !wL12==0 && nL2==1 && N [ r2//N ] < r1, 
     makePlot [ 5, r2L2finitial, "r2/free L2", 
          "              Scatchard plot for ligand 2" ], 
     makePlot [ 5, 0, "r2/free L2", "              Scatchard plot - ligand 2" ]  ]

(* CALCULATE AND PLOT THE CONDITIONAL PROBABILITIES *)  scroll = 1

(* ff *)

makePlot [ 8, 0, "ff", "" ]

(* bL1f *)

makeCPplot [ bL1f, "     bL1f" ]

(* bL2f *)

makeCPplot [ bL2f, "     bL2f" ]

(* fbL1 *)

makeCPplot [ fbL1, "     fbL1" ]

(* fbL2 *)

makeCPplot [ fbL2, "     fbL2" ]

(* bL1bL1 *)

makeCPplot [ bL1bL1, "          bL1bL1" ]

(* bL2bL2 *)

makeCPplot [ bL2bL2, "          bL2bL2" ]

(* bL1bL2 *)

makeCPplot [ bL1bL2, "          bL1bL2" ]

(* bL2bL1 *)

makeCPplot [ bL2bL1, "          bL2bL1" ]