Calculating the pH of buffer solution made of two salts of a polyprotic acid

When we are making a buffer solution by solutions of a weak acid and its salt like $$\ce{CH3COOH}$$ and $$\ce{CH3COONa}$$, or by a weak base and its salt like $$\ce{NH3}$$ and $$\ce{NH4Cl}$$, we can use the Henderson equation to determine its $$\mathrm{pH}$$. But, when we are making a buffer solution by two salts of a polyprotic acid like $$\ce{Na2HPO4}$$ and $$\ce{NaH2PO4}$$, how can we calculate the resulting $$\mathrm{pH}$$? Can Henderson's equation still be used? Or, is there any other formula?

For example, the pH of a solution of $$\ce{NaHCO3}$$ is given by the formula $$\frac{1}{2}(\mathrm{p}K_\mathrm{a1} + \mathrm{p}K_\mathrm{a2})$$. But what would be the formula if the salt is from a triprotic acid? Again, what will be the formula if the solution is a mixture of salts?

I need a theoretical calculation of the $$\mathrm{pH}$$, and this is not for any laboratory type experiment.

• You can use Henderson-Hasselbach. The equations will independently hold for both equilibria. You use use the total amount in solution to compute the actual amounts. – Zhe Nov 21 '16 at 18:25
• A useful internet search for this type of problem is 'systematic calculation of pH'. These calculations can get messy pretty quickly, so take it slow. – BiggChemT Nov 21 '16 at 21:48
• @Zhe How can I use the equation? – Shoubhik Raj Maiti Nov 23 '16 at 9:02
• chemistry.stackexchange.com/questions/8254/… – Satwik Pasani Nov 25 '16 at 6:05