Numerical pricing in AMMs and bonding curves