Continue execution in case of derivative error

Thanks to David Gay for the fix.
Continue execution in case of derivative error