
Function: R2_DIMER
******************
  Description: R2obs = fM * R2M + 2 * fD * R2D
  Parameters: Kdimer R2dimer R2monomer

  Notes:
    Fit of R2 relaxation data or chemical shift data to a
    monomer-dimer equilibrium as a function of total protein
    concentration where:
      P + P  <-> P:P; [P][P]/[P:P] = Kdimer
      R2obs = fM * R2M + 2 * fD * R2D
  
    Function is undefined at x=0.
    Olga's derivation of the function is available as a ms word document.


  C-code:
    answer =  a*x*x*x + b*x*x + c*x + d;

  C-code:
    b = R2dimer - R2monomer;
    c = 4.0 * R2dimer * x;
    d = sqrt(Kdimer) * (R2monomer - R2dimer) * sqrt(Kdimer + 8.0 * x);
    answer = ((Kdimer * b) + c + d) / (4.0 * x);
