A related program can be found below.
Exact calculation and visualization of pH in monoprotic acid and base solutions
https://community.wolfram.com/groups/-/m/t/3313737
Taweetham Limpanuparb, Junming Ho. Visualization of Validity Ranges for Acid Approximations: Error Contour Plots as a Function of Concentration and Ka. Journal of Chemical Education 2023, 100 (12) , 4884-4889. https://doi.org/10.1021/acs.jchemed.3c00751