added option to find z_dec using quad, instead of the taylor series