function calls and derivatives checked