This script calculates the species concentration, buffer index, titration curve and endpoint sharpness for acids, bases and zwitterions with up to 5 pKa's. Besides the pKa's, the required inputs are the compound name, the total anaytical concentration of the compound and the number of base groups in the compound.
As an aid and example, a database of 42 selected compounds is included. A semilog plot of the concentration of all species over the pH range 0 to 14 is produced with a superimposed buffering index curve showing the regions of high buffering.
A separate plot shows the titration curve of the compound with strong acid or base as appropriate. The titrant is assumed to have the same analytical concentration as the sample. A final plot shows the endpoint sharpness index (SI) curve. A SI >=1000 indicates the titration endpoint can be determined precisely. Values less than 10 do not provide good endpoint precision. The pH of the various free, salt and neutral forms are computed along with the isoelectric point of the zwitterions.