Dissociation Constant (Ka) and pH calculation