The concentration of the diprotic acid (tartaric acid) will be constant at $\pu{ 0.1 M}$. I want to find the concentration of its double salt (potassium sodium tartrate) needed to create a buffer of $\pu{ pH }$=x (for example,x= 4.0). How would I do this? Do I have to use the Henderson-Hasselbalch equation? Make certain assumptions?
I tried to set up two equilibrium expressions with $K_\mathrm{a1}$ and $K_\mathrm{a2}$ as follows:
$$K_\mathrm{a1} =\frac{[\ce{C4H5O6-}][\ce{H+}]}{[\ce{C4H6O6}]}$$ and
$$K_\mathrm{a2} =\frac{[\ce{C4H4O6^{2-}}][\ce{H+}]}{[\ce{C4H5O6-}]}$$
Can I multiply $K_\mathrm{a1}$ and $K_\mathrm{a1}$ to eliminate$[\ce{C4H5O6-}]$, and then get the concentration of $\ce{C4H4O6^{2-}}$ necessary by plugging in $\pu{0.1M}$ for$[\ce{C4H6O6}]$ and the target $\pu{pH}$ in the appropriate form in $[\ce{H+}$]? I feel like I'm making some big assumptions here, though.
(Also, please forgive me; I don't know how to use LaTeX or Tex.)
If I try to make the assumption that the second dissociation does not occur as it is too weak (which it isn't) I wouldn't have the concentration of $\ce{C4H4O6^{2-}}$ in my equation, which is what I'm trying to find.